From e5a2290c4b81a87d7e17bd5421ce7568dffe1296 Mon Sep 17 00:00:00 2001 From: phochste Date: Mon, 16 Sep 2024 08:25:57 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20pages=20from=20@=20MellonSchol?= =?UTF-8?q?arlyCommunication/scholarly-browser@832c5775c2cfcf86d258083f100?= =?UTF-8?q?2abc275de23ba=20=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- assets/index-67ac0650.js | 216 ++++++++++++++++++ ...{index-9c895cd1.css => index-7a57bc8d.css} | 2 +- assets/index-e9594049.js | 216 ------------------ index.html | 4 +- 4 files changed, 219 insertions(+), 219 deletions(-) create mode 100644 assets/index-67ac0650.js rename assets/{index-9c895cd1.css => index-7a57bc8d.css} (99%) delete mode 100644 assets/index-e9594049.js diff --git a/assets/index-67ac0650.js b/assets/index-67ac0650.js new file mode 100644 index 0000000..b2c2686 --- /dev/null +++ b/assets/index-67ac0650.js @@ -0,0 +1,216 @@ +var hU=Object.defineProperty;var pU=(t,e,u)=>e in t?hU(t,e,{enumerable:!0,configurable:!0,writable:!0,value:u}):t[e]=u;var wr=(t,e,u)=>(pU(t,typeof e!="symbol"?e+"":e,u),u),Rm=(t,e,u)=>{if(!e.has(t))throw TypeError("Cannot "+u)};var _e=(t,e,u)=>(Rm(t,e,"read from private field"),u?u.call(t):e.get(t)),xt=(t,e,u)=>{if(e.has(t))throw TypeError("Cannot add the same private member more than once");e instanceof WeakSet?e.add(t):e.set(t,u)},_t=(t,e,u,s)=>(Rm(t,e,"write to private field"),s?s.call(t,u):e.set(t,u),u);var Jy=(t,e,u,s)=>({set _(n){_t(t,e,n,u)},get _(){return _e(t,e,s)}}),ct=(t,e,u)=>(Rm(t,e,"access private method"),u);(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const n of document.querySelectorAll('link[rel="modulepreload"]'))s(n);new MutationObserver(n=>{for(const r of n)if(r.type==="childList")for(const a of r.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&s(a)}).observe(document,{childList:!0,subtree:!0});function u(n){const r={};return n.integrity&&(r.integrity=n.integrity),n.referrerPolicy&&(r.referrerPolicy=n.referrerPolicy),n.crossOrigin==="use-credentials"?r.credentials="include":n.crossOrigin==="anonymous"?r.credentials="omit":r.credentials="same-origin",r}function s(n){if(n.ep)return;n.ep=!0;const r=u(n);fetch(n.href,r)}})();function F3(t,e){const u=Object.create(null),s=t.split(",");for(let n=0;n!!u[n.toLowerCase()]:n=>!!u[n]}const yr={},Oo=[],Si=()=>{},yU=()=>!1,bU=/^on[^a-z]/,fb=t=>bU.test(t),q3=t=>t.startsWith("onUpdate:"),Wr=Object.assign,B3=(t,e)=>{const u=t.indexOf(e);u>-1&&t.splice(u,1)},mU=Object.prototype.hasOwnProperty,$t=(t,e)=>mU.call(t,e),Rt=Array.isArray,Ro=t=>hb(t)==="[object Map]",YM=t=>hb(t)==="[object Set]",Pt=t=>typeof t=="function",qr=t=>typeof t=="string",U3=t=>typeof t=="symbol",Sr=t=>t!==null&&typeof t=="object",ZM=t=>Sr(t)&&Pt(t.then)&&Pt(t.catch),e9=Object.prototype.toString,hb=t=>e9.call(t),gU=t=>hb(t).slice(8,-1),t9=t=>hb(t)==="[object Object]",Q3=t=>qr(t)&&t!=="NaN"&&t[0]!=="-"&&""+parseInt(t,10)===t,M1=F3(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),pb=t=>{const e=Object.create(null);return u=>e[u]||(e[u]=t(u))},_U=/-(\w)/g,$i=pb(t=>t.replace(_U,(e,u)=>u?u.toUpperCase():"")),vU=/\B([A-Z])/g,ko=pb(t=>t.replace(vU,"-$1").toLowerCase()),yb=pb(t=>t.charAt(0).toUpperCase()+t.slice(1)),xm=pb(t=>t?`on${yb(t)}`:""),$0=(t,e)=>!Object.is(t,e),Im=(t,e)=>{for(let u=0;u{Object.defineProperty(t,e,{configurable:!0,enumerable:!1,value:u})},wU=t=>{const e=parseFloat(t);return isNaN(e)?t:e};let UA;const GS=()=>UA||(UA=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Ua(t){if(Rt(t)){const e={};for(let u=0;u{if(u){const s=u.split(TU);s.length>1&&(e[s[0].trim()]=s[1].trim())}}),e}function rn(t){let e="";if(qr(t))e=t;else if(Rt(t))for(let u=0;uqr(t)?t:t==null?"":Rt(t)||Sr(t)&&(t.toString===e9||!Pt(t.toString))?JSON.stringify(t,n9,2):String(t),n9=(t,e)=>e&&e.__v_isRef?n9(t,e.value):Ro(e)?{[`Map(${e.size})`]:[...e.entries()].reduce((u,[s,n])=>(u[`${s} =>`]=n,u),{})}:YM(e)?{[`Set(${e.size})`]:[...e.values()]}:Sr(e)&&!Rt(e)&&!t9(e)?String(e):e;let gi;class xU{constructor(e=!1){this.detached=e,this._active=!0,this.effects=[],this.cleanups=[],this.parent=gi,!e&&gi&&(this.index=(gi.scopes||(gi.scopes=[])).push(this)-1)}get active(){return this._active}run(e){if(this._active){const u=gi;try{return gi=this,e()}finally{gi=u}}}on(){gi=this}off(){gi=this.parent}stop(e){if(this._active){let u,s;for(u=0,s=this.effects.length;u{const e=new Set(t);return e.w=0,e.n=0,e},i9=t=>(t.w&za)>0,a9=t=>(t.n&za)>0,DU=({deps:t})=>{if(t.length)for(let e=0;e{const{deps:e}=t;if(e.length){let u=0;for(let s=0;s{(d==="length"||d>=l)&&o.push(c)})}else switch(u!==void 0&&o.push(a.get(u)),e){case"add":Rt(t)?Q3(u)&&o.push(a.get("length")):(o.push(a.get(ks)),Ro(t)&&o.push(a.get(XS)));break;case"delete":Rt(t)||(o.push(a.get(ks)),Ro(t)&&o.push(a.get(XS)));break;case"set":Ro(t)&&o.push(a.get(ks));break}if(o.length===1)o[0]&&KS(o[0]);else{const l=[];for(const c of o)c&&l.push(...c);KS(H3(l))}}function KS(t,e){const u=Rt(t)?t:[...t];for(const s of u)s.computed&&HA(s);for(const s of u)s.computed||HA(s)}function HA(t,e){(t!==_i||t.allowRecurse)&&(t.scheduler?t.scheduler():t.run())}const CU=F3("__proto__,__v_isRef,__isVue"),u9=new Set(Object.getOwnPropertyNames(Symbol).filter(t=>t!=="arguments"&&t!=="caller").map(t=>Symbol[t]).filter(U3)),jU=V3(),LU=V3(!1,!0),MU=V3(!0),$A=FU();function FU(){const t={};return["includes","indexOf","lastIndexOf"].forEach(e=>{t[e]=function(...u){const s=Gt(this);for(let r=0,a=this.length;r{t[e]=function(...u){zo();const s=Gt(this)[e].apply(this,u);return Go(),s}}),t}function qU(t){const e=Gt(this);return Bn(e,"has",t),e.hasOwnProperty(t)}function V3(t=!1,e=!1){return function(s,n,r){if(n==="__v_isReactive")return!t;if(n==="__v_isReadonly")return t;if(n==="__v_isShallow")return e;if(n==="__v_raw"&&r===(t?e?eQ:h9:e?f9:d9).get(s))return s;const a=Rt(s);if(!t){if(a&&$t($A,n))return Reflect.get($A,n,r);if(n==="hasOwnProperty")return qU}const o=Reflect.get(s,n,r);return(U3(n)?u9.has(n):CU(n))||(t||Bn(s,"get",n),e)?o:fn(o)?a&&Q3(n)?o:o.value:Sr(o)?t?y9(o):mb(o):o}}const BU=c9(),UU=c9(!0);function c9(t=!1){return function(u,s,n,r){let a=u[s];if(Do(a)&&fn(a)&&!fn(n))return!1;if(!t&&(!Z1(n)&&!Do(n)&&(a=Gt(a),n=Gt(n)),!Rt(u)&&fn(a)&&!fn(n)))return a.value=n,!0;const o=Rt(u)&&Q3(s)?Number(s)t,bb=t=>Reflect.getPrototypeOf(t);function Xy(t,e,u=!1,s=!1){t=t.__v_raw;const n=Gt(t),r=Gt(e);u||(e!==r&&Bn(n,"get",e),Bn(n,"get",r));const{has:a}=bb(n),o=s?k3:u?W3:V0;if(a.call(n,e))return o(t.get(e));if(a.call(n,r))return o(t.get(r));t!==n&&t.get(e)}function Ky(t,e=!1){const u=this.__v_raw,s=Gt(u),n=Gt(t);return e||(t!==n&&Bn(s,"has",t),Bn(s,"has",n)),t===n?u.has(t):u.has(t)||u.has(n)}function Yy(t,e=!1){return t=t.__v_raw,!e&&Bn(Gt(t),"iterate",ks),Reflect.get(t,"size",t)}function VA(t){t=Gt(t);const e=Gt(this);return bb(e).has.call(e,t)||(e.add(t),ga(e,"add",t,t)),this}function kA(t,e){e=Gt(e);const u=Gt(this),{has:s,get:n}=bb(u);let r=s.call(u,t);r||(t=Gt(t),r=s.call(u,t));const a=n.call(u,t);return u.set(t,e),r?$0(e,a)&&ga(u,"set",t,e):ga(u,"add",t,e),this}function zA(t){const e=Gt(this),{has:u,get:s}=bb(e);let n=u.call(e,t);n||(t=Gt(t),n=u.call(e,t)),s&&s.call(e,t);const r=e.delete(t);return n&&ga(e,"delete",t,void 0),r}function GA(){const t=Gt(this),e=t.size!==0,u=t.clear();return e&&ga(t,"clear",void 0,void 0),u}function Zy(t,e){return function(s,n){const r=this,a=r.__v_raw,o=Gt(a),l=e?k3:t?W3:V0;return!t&&Bn(o,"iterate",ks),a.forEach((c,d)=>s.call(n,l(c),l(d),r))}}function e1(t,e,u){return function(...s){const n=this.__v_raw,r=Gt(n),a=Ro(r),o=t==="entries"||t===Symbol.iterator&&a,l=t==="keys"&&a,c=n[t](...s),d=u?k3:e?W3:V0;return!e&&Bn(r,"iterate",l?XS:ks),{next(){const{value:h,done:f}=c.next();return f?{value:h,done:f}:{value:o?[d(h[0]),d(h[1])]:d(h),done:f}},[Symbol.iterator](){return this}}}}function Ra(t){return function(...e){return t==="delete"?!1:this}}function zU(){const t={get(r){return Xy(this,r)},get size(){return Yy(this)},has:Ky,add:VA,set:kA,delete:zA,clear:GA,forEach:Zy(!1,!1)},e={get(r){return Xy(this,r,!1,!0)},get size(){return Yy(this)},has:Ky,add:VA,set:kA,delete:zA,clear:GA,forEach:Zy(!1,!0)},u={get(r){return Xy(this,r,!0)},get size(){return Yy(this,!0)},has(r){return Ky.call(this,r,!0)},add:Ra("add"),set:Ra("set"),delete:Ra("delete"),clear:Ra("clear"),forEach:Zy(!0,!1)},s={get(r){return Xy(this,r,!0,!0)},get size(){return Yy(this,!0)},has(r){return Ky.call(this,r,!0)},add:Ra("add"),set:Ra("set"),delete:Ra("delete"),clear:Ra("clear"),forEach:Zy(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(r=>{t[r]=e1(r,!1,!1),u[r]=e1(r,!0,!1),e[r]=e1(r,!1,!0),s[r]=e1(r,!0,!0)}),[t,u,e,s]}const[GU,WU,JU,XU]=zU();function z3(t,e){const u=e?t?XU:JU:t?WU:GU;return(s,n,r)=>n==="__v_isReactive"?!t:n==="__v_isReadonly"?t:n==="__v_raw"?s:Reflect.get($t(u,n)&&n in s?u:s,n,r)}const KU={get:z3(!1,!1)},YU={get:z3(!1,!0)},ZU={get:z3(!0,!1)},d9=new WeakMap,f9=new WeakMap,h9=new WeakMap,eQ=new WeakMap;function tQ(t){switch(t){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function rQ(t){return t.__v_skip||!Object.isExtensible(t)?0:tQ(gU(t))}function mb(t){return Do(t)?t:G3(t,!1,l9,KU,d9)}function p9(t){return G3(t,!1,kU,YU,f9)}function y9(t){return G3(t,!0,VU,ZU,h9)}function G3(t,e,u,s,n){if(!Sr(t)||t.__v_raw&&!(e&&t.__v_isReactive))return t;const r=n.get(t);if(r)return r;const a=rQ(t);if(a===0)return t;const o=new Proxy(t,a===2?s:u);return n.set(t,o),o}function xo(t){return Do(t)?xo(t.__v_raw):!!(t&&t.__v_isReactive)}function Do(t){return!!(t&&t.__v_isReadonly)}function Z1(t){return!!(t&&t.__v_isShallow)}function b9(t){return xo(t)||Do(t)}function Gt(t){const e=t&&t.__v_raw;return e?Gt(e):t}function m9(t){return Y1(t,"__v_skip",!0),t}const V0=t=>Sr(t)?mb(t):t,W3=t=>Sr(t)?y9(t):t;function g9(t){Ha&&_i&&(t=Gt(t),o9(t.dep||(t.dep=H3())))}function _9(t,e){t=Gt(t);const u=t.dep;u&&KS(u)}function fn(t){return!!(t&&t.__v_isRef===!0)}function En(t){return v9(t,!1)}function nQ(t){return v9(t,!0)}function v9(t,e){return fn(t)?t:new iQ(t,e)}class iQ{constructor(e,u){this.__v_isShallow=u,this.dep=void 0,this.__v_isRef=!0,this._rawValue=u?e:Gt(e),this._value=u?e:V0(e)}get value(){return g9(this),this._value}set value(e){const u=this.__v_isShallow||Z1(e)||Do(e);e=u?e:Gt(e),$0(e,this._rawValue)&&(this._rawValue=e,this._value=u?e:V0(e),_9(this))}}function qt(t){return fn(t)?t.value:t}const aQ={get:(t,e,u)=>qt(Reflect.get(t,e,u)),set:(t,e,u,s)=>{const n=t[e];return fn(n)&&!fn(u)?(n.value=u,!0):Reflect.set(t,e,u,s)}};function w9(t){return xo(t)?t:new Proxy(t,aQ)}class sQ{constructor(e,u,s,n){this._setter=u,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this._dirty=!0,this.effect=new $3(e,()=>{this._dirty||(this._dirty=!0,_9(this))}),this.effect.computed=this,this.effect.active=this._cacheable=!n,this.__v_isReadonly=s}get value(){const e=Gt(this);return g9(e),(e._dirty||!e._cacheable)&&(e._dirty=!1,e._value=e.effect.run()),e._value}set value(e){this._setter(e)}}function oQ(t,e,u=!1){let s,n;const r=Pt(t);return r?(s=t,n=Si):(s=t.get,n=t.set),new sQ(s,n,r||!n,u)}function $a(t,e,u,s){let n;try{n=s?t(...s):t()}catch(r){gb(r,e,u)}return n}function Ti(t,e,u,s){if(Pt(t)){const r=$a(t,e,u,s);return r&&ZM(r)&&r.catch(a=>{gb(a,e,u)}),r}const n=[];for(let r=0;r>>1;z0(dn[s])Ui&&dn.splice(e,1)}function dQ(t){Rt(t)?Io.push(...t):(!ba||!ba.includes(t,t.allowRecurse?Bs+1:Bs))&&Io.push(t),A9()}function WA(t,e=k0?Ui+1:0){for(;ez0(u)-z0(s)),Bs=0;Bst.id==null?1/0:t.id,fQ=(t,e)=>{const u=z0(t)-z0(e);if(u===0){if(t.pre&&!e.pre)return-1;if(e.pre&&!t.pre)return 1}return u};function O9(t){YS=!1,k0=!0,dn.sort(fQ);const e=Si;try{for(Ui=0;Uiqr(p)?p.trim():p)),h&&(n=u.map(wU))}let o,l=s[o=xm(e)]||s[o=xm($i(e))];!l&&r&&(l=s[o=xm(ko(e))]),l&&Ti(l,t,6,n);const c=s[o+"Once"];if(c){if(!t.emitted)t.emitted={};else if(t.emitted[o])return;t.emitted[o]=!0,Ti(c,t,6,n)}}function R9(t,e,u=!1){const s=e.emitsCache,n=s.get(t);if(n!==void 0)return n;const r=t.emits;let a={},o=!1;if(!Pt(t)){const l=c=>{const d=R9(c,e,!0);d&&(o=!0,Wr(a,d))};!u&&e.mixins.length&&e.mixins.forEach(l),t.extends&&l(t.extends),t.mixins&&t.mixins.forEach(l)}return!r&&!o?(Sr(t)&&s.set(t,null),null):(Rt(r)?r.forEach(l=>a[l]=null):Wr(a,r),Sr(t)&&s.set(t,a),a)}function _b(t,e){return!t||!fb(e)?!1:(e=e.slice(2).replace(/Once$/,""),$t(t,e[0].toLowerCase()+e.slice(1))||$t(t,ko(e))||$t(t,e))}let nn=null,vb=null;function eb(t){const e=nn;return nn=t,vb=t&&t.type.__scopeId||null,e}function pQ(t){vb=t}function yQ(){vb=null}function Lr(t,e=nn,u){if(!e||t._n)return t;const s=(...n)=>{s._d&&sE(-1);const r=eb(e);let a;try{a=t(...n)}finally{eb(r),s._d&&sE(1)}return a};return s._n=!0,s._c=!0,s._d=!0,s}function Pm(t){const{type:e,vnode:u,proxy:s,withProxy:n,props:r,propsOptions:[a],slots:o,attrs:l,emit:c,render:d,renderCache:h,data:f,setupState:p,ctx:y,inheritAttrs:b}=t;let g,m;const v=eb(t);try{if(u.shapeFlag&4){const w=n||s;g=Bi(d.call(w,w,h,r,p,f,y)),m=l}else{const w=e;g=Bi(w.length>1?w(r,{attrs:l,slots:o,emit:c}):w(r,null)),m=e.props?l:bQ(l)}}catch(w){B0.length=0,gb(w,t,1),g=ar(Ga)}let _=g;if(m&&b!==!1){const w=Object.keys(m),{shapeFlag:S}=_;w.length&&S&7&&(a&&w.some(q3)&&(m=mQ(m,a)),_=No(_,m))}return u.dirs&&(_=No(_),_.dirs=_.dirs?_.dirs.concat(u.dirs):u.dirs),u.transition&&(_.transition=u.transition),g=_,eb(v),g}const bQ=t=>{let e;for(const u in t)(u==="class"||u==="style"||fb(u))&&((e||(e={}))[u]=t[u]);return e},mQ=(t,e)=>{const u={};for(const s in t)(!q3(s)||!(s.slice(9)in e))&&(u[s]=t[s]);return u};function gQ(t,e,u){const{props:s,children:n,component:r}=t,{props:a,children:o,patchFlag:l}=e,c=r.emitsOptions;if(e.dirs||e.transition)return!0;if(u&&l>=0){if(l&1024)return!0;if(l&16)return s?JA(s,a,c):!!a;if(l&8){const d=e.dynamicProps;for(let h=0;ht.__isSuspense;function wQ(t,e){e&&e.pendingBranch?Rt(t)?e.effects.push(...t):e.effects.push(t):dQ(t)}function x9(t,e){return K3(t,null,e)}const t1={};function Po(t,e,u){return K3(t,e,u)}function K3(t,e,{immediate:u,deep:s,flush:n,onTrack:r,onTrigger:a}=yr){var o;const l=PU()===((o=Gr)==null?void 0:o.scope)?Gr:null;let c,d=!1,h=!1;if(fn(t)?(c=()=>t.value,d=Z1(t)):xo(t)?(c=()=>t,s=!0):Rt(t)?(h=!0,d=t.some(w=>xo(w)||Z1(w)),c=()=>t.map(w=>{if(fn(w))return w.value;if(xo(w))return $s(w);if(Pt(w))return $a(w,l,2)})):Pt(t)?e?c=()=>$a(t,l,2):c=()=>{if(!(l&&l.isUnmounted))return f&&f(),Ti(t,l,3,[p])}:c=Si,e&&s){const w=c;c=()=>$s(w())}let f,p=w=>{f=v.onStop=()=>{$a(w,l,4)}},y;if(W0)if(p=Si,e?u&&Ti(e,l,3,[c(),h?[]:void 0,p]):c(),n==="sync"){const w=dH();y=w.__watcherHandles||(w.__watcherHandles=[])}else return Si;let b=h?new Array(t.length).fill(t1):t1;const g=()=>{if(v.active)if(e){const w=v.run();(s||d||(h?w.some((S,A)=>$0(S,b[A])):$0(w,b)))&&(f&&f(),Ti(e,l,3,[w,b===t1?void 0:h&&b[0]===t1?[]:b,p]),b=w)}else v.run()};g.allowRecurse=!!e;let m;n==="sync"?m=g:n==="post"?m=()=>Fn(g,l&&l.suspense):(g.pre=!0,l&&(g.id=l.uid),m=()=>X3(g));const v=new $3(c,m);e?u?g():b=v.run():n==="post"?Fn(v.run.bind(v),l&&l.suspense):v.run();const _=()=>{v.stop(),l&&l.scope&&B3(l.scope.effects,v)};return y&&y.push(_),_}function SQ(t,e,u){const s=this.proxy,n=qr(t)?t.includes(".")?I9(s,t):()=>s[t]:t.bind(s,s);let r;Pt(e)?r=e:(r=e.handler,u=e);const a=Gr;Co(this);const o=K3(n,r.bind(s),u);return a?Co(a):zs(),o}function I9(t,e){const u=e.split(".");return()=>{let s=t;for(let n=0;n{$s(u,e)});else if(t9(t))for(const u in t)$s(t[u],e);return t}function tb(t,e){const u=nn;if(u===null)return t;const s=Ab(u)||u.proxy,n=t.dirs||(t.dirs=[]);for(let r=0;rWr({name:t.name},e,{setup:t}))():t}const F0=t=>!!t.type.__asyncLoader,P9=t=>t.type.__isKeepAlive;function TQ(t,e){D9(t,"a",e)}function AQ(t,e){D9(t,"da",e)}function D9(t,e,u=Gr){const s=t.__wdc||(t.__wdc=()=>{let n=u;for(;n;){if(n.isDeactivated)return;n=n.parent}return t()});if(wb(e,s,u),u){let n=u.parent;for(;n&&n.parent;)P9(n.parent.vnode)&&EQ(s,e,u,n),n=n.parent}}function EQ(t,e,u,s){const n=wb(e,t,s,!0);Y3(()=>{B3(s[e],n)},u)}function wb(t,e,u=Gr,s=!1){if(u){const n=u[t]||(u[t]=[]),r=e.__weh||(e.__weh=(...a)=>{if(u.isUnmounted)return;zo(),Co(u);const o=Ti(e,u,t,a);return zs(),Go(),o});return s?n.unshift(r):n.push(r),r}}const Sa=t=>(e,u=Gr)=>(!W0||t==="sp")&&wb(t,(...s)=>e(...s),u),OQ=Sa("bm"),N9=Sa("m"),RQ=Sa("bu"),C9=Sa("u"),xQ=Sa("bum"),Y3=Sa("um"),IQ=Sa("sp"),PQ=Sa("rtg"),DQ=Sa("rtc");function NQ(t,e=Gr){wb("ec",t,e)}const Z3="components";function yo(t,e){return L9(Z3,t,!0,e)||t}const j9=Symbol.for("v-ndc");function Ka(t){return qr(t)?L9(Z3,t,!1)||t:t||j9}function L9(t,e,u=!0,s=!1){const n=nn||Gr;if(n){const r=n.type;if(t===Z3){const o=uH(r,!1);if(o&&(o===e||o===$i(e)||o===yb($i(e))))return r}const a=XA(n[t]||r[t],e)||XA(n.appContext[t],e);return!a&&s?r:a}}function XA(t,e){return t&&(t[e]||t[$i(e)]||t[yb($i(e))])}function KA(t,e,u,s){let n;const r=u&&u[s];if(Rt(t)||qr(t)){n=new Array(t.length);for(let a=0,o=t.length;ae(a,o,void 0,r&&r[o]));else{const a=Object.keys(t);n=new Array(a.length);for(let o=0,l=a.length;oib(e)?!(e.type===Ga||e.type===On&&!M9(e.children)):!0)?t:null}const ZS=t=>t?G9(t)?Ab(t)||t.proxy:ZS(t.parent):null,q0=Wr(Object.create(null),{$:t=>t,$el:t=>t.vnode.el,$data:t=>t.data,$props:t=>t.props,$attrs:t=>t.attrs,$slots:t=>t.slots,$refs:t=>t.refs,$parent:t=>ZS(t.parent),$root:t=>ZS(t.root),$emit:t=>t.emit,$options:t=>eT(t),$forceUpdate:t=>t.f||(t.f=()=>X3(t.update)),$nextTick:t=>t.n||(t.n=T9.bind(t.proxy)),$watch:t=>SQ.bind(t)}),Dm=(t,e)=>t!==yr&&!t.__isScriptSetup&&$t(t,e),CQ={get({_:t},e){const{ctx:u,setupState:s,data:n,props:r,accessCache:a,type:o,appContext:l}=t;let c;if(e[0]!=="$"){const p=a[e];if(p!==void 0)switch(p){case 1:return s[e];case 2:return n[e];case 4:return u[e];case 3:return r[e]}else{if(Dm(s,e))return a[e]=1,s[e];if(n!==yr&&$t(n,e))return a[e]=2,n[e];if((c=t.propsOptions[0])&&$t(c,e))return a[e]=3,r[e];if(u!==yr&&$t(u,e))return a[e]=4,u[e];e3&&(a[e]=0)}}const d=q0[e];let h,f;if(d)return e==="$attrs"&&Bn(t,"get",e),d(t);if((h=o.__cssModules)&&(h=h[e]))return h;if(u!==yr&&$t(u,e))return a[e]=4,u[e];if(f=l.config.globalProperties,$t(f,e))return f[e]},set({_:t},e,u){const{data:s,setupState:n,ctx:r}=t;return Dm(n,e)?(n[e]=u,!0):s!==yr&&$t(s,e)?(s[e]=u,!0):$t(t.props,e)||e[0]==="$"&&e.slice(1)in t?!1:(r[e]=u,!0)},has({_:{data:t,setupState:e,accessCache:u,ctx:s,appContext:n,propsOptions:r}},a){let o;return!!u[a]||t!==yr&&$t(t,a)||Dm(e,a)||(o=r[0])&&$t(o,a)||$t(s,a)||$t(q0,a)||$t(n.config.globalProperties,a)},defineProperty(t,e,u){return u.get!=null?t._.accessCache[e]=0:$t(u,"value")&&this.set(t,e,u.value,null),Reflect.defineProperty(t,e,u)}};function jQ(){return LQ().attrs}function LQ(){const t=iH();return t.setupContext||(t.setupContext=J9(t))}function YA(t){return Rt(t)?t.reduce((e,u)=>(e[u]=null,e),{}):t}let e3=!0;function MQ(t){const e=eT(t),u=t.proxy,s=t.ctx;e3=!1,e.beforeCreate&&ZA(e.beforeCreate,t,"bc");const{data:n,computed:r,methods:a,watch:o,provide:l,inject:c,created:d,beforeMount:h,mounted:f,beforeUpdate:p,updated:y,activated:b,deactivated:g,beforeDestroy:m,beforeUnmount:v,destroyed:_,unmounted:w,render:S,renderTracked:A,renderTriggered:D,errorCaptured:L,serverPrefetch:O,expose:E,inheritAttrs:P,components:M,directives:U,filters:j}=e;if(c&&FQ(c,s,null),a)for(const Z in a){const X=a[Z];Pt(X)&&(s[Z]=X.bind(u))}if(n){const Z=n.call(u,u);Sr(Z)&&(t.data=mb(Z))}if(e3=!0,r)for(const Z in r){const X=r[Z],le=Pt(X)?X.bind(u,u):Pt(X.get)?X.get.bind(u,u):Si,K=!Pt(X)&&Pt(X.set)?X.set.bind(u):Si,he=sr({get:le,set:K});Object.defineProperty(s,Z,{enumerable:!0,configurable:!0,get:()=>he.value,set:Re=>he.value=Re})}if(o)for(const Z in o)F9(o[Z],s,u,Z);if(l){const Z=Pt(l)?l.call(u):l;Reflect.ownKeys(Z).forEach(X=>{F1(X,Z[X])})}d&&ZA(d,t,"c");function $(Z,X){Rt(X)?X.forEach(le=>Z(le.bind(u))):X&&Z(X.bind(u))}if($(OQ,h),$(N9,f),$(RQ,p),$(C9,y),$(TQ,b),$(AQ,g),$(NQ,L),$(DQ,A),$(PQ,D),$(xQ,v),$(Y3,w),$(IQ,O),Rt(E))if(E.length){const Z=t.exposed||(t.exposed={});E.forEach(X=>{Object.defineProperty(Z,X,{get:()=>u[X],set:le=>u[X]=le})})}else t.exposed||(t.exposed={});S&&t.render===Si&&(t.render=S),P!=null&&(t.inheritAttrs=P),M&&(t.components=M),U&&(t.directives=U)}function FQ(t,e,u=Si){Rt(t)&&(t=t3(t));for(const s in t){const n=t[s];let r;Sr(n)?"default"in n?r=Ai(n.from||s,n.default,!0):r=Ai(n.from||s):r=Ai(n),fn(r)?Object.defineProperty(e,s,{enumerable:!0,configurable:!0,get:()=>r.value,set:a=>r.value=a}):e[s]=r}}function ZA(t,e,u){Ti(Rt(t)?t.map(s=>s.bind(e.proxy)):t.bind(e.proxy),e,u)}function F9(t,e,u,s){const n=s.includes(".")?I9(u,s):()=>u[s];if(qr(t)){const r=e[t];Pt(r)&&Po(n,r)}else if(Pt(t))Po(n,t.bind(u));else if(Sr(t))if(Rt(t))t.forEach(r=>F9(r,e,u,s));else{const r=Pt(t.handler)?t.handler.bind(u):e[t.handler];Pt(r)&&Po(n,r,t)}}function eT(t){const e=t.type,{mixins:u,extends:s}=e,{mixins:n,optionsCache:r,config:{optionMergeStrategies:a}}=t.appContext,o=r.get(e);let l;return o?l=o:!n.length&&!u&&!s?l=e:(l={},n.length&&n.forEach(c=>rb(l,c,a,!0)),rb(l,e,a)),Sr(e)&&r.set(e,l),l}function rb(t,e,u,s=!1){const{mixins:n,extends:r}=e;r&&rb(t,r,u,!0),n&&n.forEach(a=>rb(t,a,u,!0));for(const a in e)if(!(s&&a==="expose")){const o=qQ[a]||u&&u[a];t[a]=o?o(t[a],e[a]):e[a]}return t}const qQ={data:eE,props:tE,emits:tE,methods:S0,computed:S0,beforeCreate:Tn,created:Tn,beforeMount:Tn,mounted:Tn,beforeUpdate:Tn,updated:Tn,beforeDestroy:Tn,beforeUnmount:Tn,destroyed:Tn,unmounted:Tn,activated:Tn,deactivated:Tn,errorCaptured:Tn,serverPrefetch:Tn,components:S0,directives:S0,watch:UQ,provide:eE,inject:BQ};function eE(t,e){return e?t?function(){return Wr(Pt(t)?t.call(this,this):t,Pt(e)?e.call(this,this):e)}:e:t}function BQ(t,e){return S0(t3(t),t3(e))}function t3(t){if(Rt(t)){const e={};for(let u=0;u1)return u&&Pt(e)?e.call(s&&s.proxy):e}}function $Q(t,e,u,s=!1){const n={},r={};Y1(r,Tb,1),t.propsDefaults=Object.create(null),B9(t,e,n,r);for(const a in t.propsOptions[0])a in n||(n[a]=void 0);u?t.props=s?n:p9(n):t.type.props?t.props=n:t.props=r,t.attrs=r}function VQ(t,e,u,s){const{props:n,attrs:r,vnode:{patchFlag:a}}=t,o=Gt(n),[l]=t.propsOptions;let c=!1;if((s||a>0)&&!(a&16)){if(a&8){const d=t.vnode.dynamicProps;for(let h=0;h{l=!0;const[f,p]=U9(h,e,!0);Wr(a,f),p&&o.push(...p)};!u&&e.mixins.length&&e.mixins.forEach(d),t.extends&&d(t.extends),t.mixins&&t.mixins.forEach(d)}if(!r&&!l)return Sr(t)&&s.set(t,Oo),Oo;if(Rt(r))for(let d=0;d-1,p[1]=b<0||y-1||$t(p,"default"))&&o.push(h)}}}const c=[a,o];return Sr(t)&&s.set(t,c),c}function rE(t){return t[0]!=="$"}function nE(t){const e=t&&t.toString().match(/^\s*(function|class) (\w+)/);return e?e[2]:t===null?"null":""}function iE(t,e){return nE(t)===nE(e)}function aE(t,e){return Rt(e)?e.findIndex(u=>iE(u,t)):Pt(e)&&iE(e,t)?0:-1}const Q9=t=>t[0]==="_"||t==="$stable",tT=t=>Rt(t)?t.map(Bi):[Bi(t)],kQ=(t,e,u)=>{if(e._n)return e;const s=Lr((...n)=>tT(e(...n)),u);return s._c=!1,s},H9=(t,e,u)=>{const s=t._ctx;for(const n in t){if(Q9(n))continue;const r=t[n];if(Pt(r))e[n]=kQ(n,r,s);else if(r!=null){const a=tT(r);e[n]=()=>a}}},$9=(t,e)=>{const u=tT(e);t.slots.default=()=>u},zQ=(t,e)=>{if(t.vnode.shapeFlag&32){const u=e._;u?(t.slots=Gt(e),Y1(e,"_",u)):H9(e,t.slots={})}else t.slots={},e&&$9(t,e);Y1(t.slots,Tb,1)},GQ=(t,e,u)=>{const{vnode:s,slots:n}=t;let r=!0,a=yr;if(s.shapeFlag&32){const o=e._;o?u&&o===1?r=!1:(Wr(n,e),!u&&o===1&&delete n._):(r=!e.$stable,H9(e,n)),a=e}else e&&($9(t,e),a={default:1});if(r)for(const o in n)!Q9(o)&&!(o in a)&&delete n[o]};function n3(t,e,u,s,n=!1){if(Rt(t)){t.forEach((f,p)=>n3(f,e&&(Rt(e)?e[p]:e),u,s,n));return}if(F0(s)&&!n)return;const r=s.shapeFlag&4?Ab(s.component)||s.component.proxy:s.el,a=n?null:r,{i:o,r:l}=t,c=e&&e.r,d=o.refs===yr?o.refs={}:o.refs,h=o.setupState;if(c!=null&&c!==l&&(qr(c)?(d[c]=null,$t(h,c)&&(h[c]=null)):fn(c)&&(c.value=null)),Pt(l))$a(l,o,12,[a,d]);else{const f=qr(l),p=fn(l);if(f||p){const y=()=>{if(t.f){const b=f?$t(h,l)?h[l]:d[l]:l.value;n?Rt(b)&&B3(b,r):Rt(b)?b.includes(r)||b.push(r):f?(d[l]=[r],$t(h,l)&&(h[l]=d[l])):(l.value=[r],t.k&&(d[t.k]=l.value))}else f?(d[l]=a,$t(h,l)&&(h[l]=a)):p&&(l.value=a,t.k&&(d[t.k]=a))};a?(y.id=-1,Fn(y,u)):y()}}}const Fn=wQ;function WQ(t){return JQ(t)}function JQ(t,e){const u=GS();u.__VUE__=!0;const{insert:s,remove:n,patchProp:r,createElement:a,createText:o,createComment:l,setText:c,setElementText:d,parentNode:h,nextSibling:f,setScopeId:p=Si,insertStaticContent:y}=t,b=(R,T,x,B=null,k=null,V=null,J=!1,z=null,Y=!!T.dynamicChildren)=>{if(R===T)return;R&&!pu(R,T)&&(B=ge(R),Re(R,k,V,!0),R=null),T.patchFlag===-2&&(Y=!1,T.dynamicChildren=null);const{type:re,ref:ce,shapeFlag:Te}=T;switch(re){case Sb:g(R,T,x,B);break;case Ga:m(R,T,x,B);break;case Nm:R==null&&v(T,x,B,J);break;case On:M(R,T,x,B,k,V,J,z,Y);break;default:Te&1?S(R,T,x,B,k,V,J,z,Y):Te&6?U(R,T,x,B,k,V,J,z,Y):(Te&64||Te&128)&&re.process(R,T,x,B,k,V,J,z,Y,fe)}ce!=null&&k&&n3(ce,R&&R.ref,V,T||R,!T)},g=(R,T,x,B)=>{if(R==null)s(T.el=o(T.children),x,B);else{const k=T.el=R.el;T.children!==R.children&&c(k,T.children)}},m=(R,T,x,B)=>{R==null?s(T.el=l(T.children||""),x,B):T.el=R.el},v=(R,T,x,B)=>{[R.el,R.anchor]=y(R.children,T,x,B,R.el,R.anchor)},_=({el:R,anchor:T},x,B)=>{let k;for(;R&&R!==T;)k=f(R),s(R,x,B),R=k;s(T,x,B)},w=({el:R,anchor:T})=>{let x;for(;R&&R!==T;)x=f(R),n(R),R=x;n(T)},S=(R,T,x,B,k,V,J,z,Y)=>{J=J||T.type==="svg",R==null?A(T,x,B,k,V,J,z,Y):O(R,T,k,V,J,z,Y)},A=(R,T,x,B,k,V,J,z)=>{let Y,re;const{type:ce,props:Te,shapeFlag:xe,transition:Le,dirs:qe}=R;if(Y=R.el=a(R.type,V,Te&&Te.is,Te),xe&8?d(Y,R.children):xe&16&&L(R.children,Y,null,B,k,V&&ce!=="foreignObject",J,z),qe&&bs(R,null,B,"created"),D(Y,R,R.scopeId,J,B),Te){for(const F in Te)F!=="value"&&!M1(F)&&r(Y,F,null,Te[F],V,R.children,B,k,De);"value"in Te&&r(Y,"value",null,Te.value),(re=Te.onVnodeBeforeMount)&&Mi(re,B,R)}qe&&bs(R,null,B,"beforeMount");const G=(!k||k&&!k.pendingBranch)&&Le&&!Le.persisted;G&&Le.beforeEnter(Y),s(Y,T,x),((re=Te&&Te.onVnodeMounted)||G||qe)&&Fn(()=>{re&&Mi(re,B,R),G&&Le.enter(Y),qe&&bs(R,null,B,"mounted")},k)},D=(R,T,x,B,k)=>{if(x&&p(R,x),B)for(let V=0;V{for(let re=Y;re{const z=T.el=R.el;let{patchFlag:Y,dynamicChildren:re,dirs:ce}=T;Y|=R.patchFlag&16;const Te=R.props||yr,xe=T.props||yr;let Le;x&&ms(x,!1),(Le=xe.onVnodeBeforeUpdate)&&Mi(Le,x,T,R),ce&&bs(T,R,x,"beforeUpdate"),x&&ms(x,!0);const qe=k&&T.type!=="foreignObject";if(re?E(R.dynamicChildren,re,z,x,B,qe,V):J||X(R,T,z,null,x,B,qe,V,!1),Y>0){if(Y&16)P(z,T,Te,xe,x,B,k);else if(Y&2&&Te.class!==xe.class&&r(z,"class",null,xe.class,k),Y&4&&r(z,"style",Te.style,xe.style,k),Y&8){const G=T.dynamicProps;for(let F=0;F{Le&&Mi(Le,x,T,R),ce&&bs(T,R,x,"updated")},B)},E=(R,T,x,B,k,V,J)=>{for(let z=0;z{if(x!==B){if(x!==yr)for(const z in x)!M1(z)&&!(z in B)&&r(R,z,x[z],null,J,T.children,k,V,De);for(const z in B){if(M1(z))continue;const Y=B[z],re=x[z];Y!==re&&z!=="value"&&r(R,z,re,Y,J,T.children,k,V,De)}"value"in B&&r(R,"value",x.value,B.value)}},M=(R,T,x,B,k,V,J,z,Y)=>{const re=T.el=R?R.el:o(""),ce=T.anchor=R?R.anchor:o("");let{patchFlag:Te,dynamicChildren:xe,slotScopeIds:Le}=T;Le&&(z=z?z.concat(Le):Le),R==null?(s(re,x,B),s(ce,x,B),L(T.children,x,ce,k,V,J,z,Y)):Te>0&&Te&64&&xe&&R.dynamicChildren?(E(R.dynamicChildren,xe,x,k,V,J,z),(T.key!=null||k&&T===k.subTree)&&V9(R,T,!0)):X(R,T,x,ce,k,V,J,z,Y)},U=(R,T,x,B,k,V,J,z,Y)=>{T.slotScopeIds=z,R==null?T.shapeFlag&512?k.ctx.activate(T,x,B,J,Y):j(T,x,B,k,V,J,Y):q(R,T,Y)},j=(R,T,x,B,k,V,J)=>{const z=R.component=nH(R,B,k);if(P9(R)&&(z.ctx.renderer=fe),aH(z),z.asyncDep){if(k&&k.registerDep(z,$),!R.el){const Y=z.subTree=ar(Ga);m(null,Y,T,x)}return}$(z,R,T,x,k,V,J)},q=(R,T,x)=>{const B=T.component=R.component;if(gQ(R,T,x))if(B.asyncDep&&!B.asyncResolved){Z(B,T,x);return}else B.next=T,lQ(B.update),B.update();else T.el=R.el,B.vnode=T},$=(R,T,x,B,k,V,J)=>{const z=()=>{if(R.isMounted){let{next:ce,bu:Te,u:xe,parent:Le,vnode:qe}=R,G=ce,F;ms(R,!1),ce?(ce.el=qe.el,Z(R,ce,J)):ce=qe,Te&&Im(Te),(F=ce.props&&ce.props.onVnodeBeforeUpdate)&&Mi(F,Le,ce,qe),ms(R,!0);const Q=Pm(R),te=R.subTree;R.subTree=Q,b(te,Q,h(te.el),ge(te),R,k,V),ce.el=Q.el,G===null&&_Q(R,Q.el),xe&&Fn(xe,k),(F=ce.props&&ce.props.onVnodeUpdated)&&Fn(()=>Mi(F,Le,ce,qe),k)}else{let ce;const{el:Te,props:xe}=T,{bm:Le,m:qe,parent:G}=R,F=F0(T);if(ms(R,!1),Le&&Im(Le),!F&&(ce=xe&&xe.onVnodeBeforeMount)&&Mi(ce,G,T),ms(R,!0),Te&&N){const Q=()=>{R.subTree=Pm(R),N(Te,R.subTree,R,k,null)};F?T.type.__asyncLoader().then(()=>!R.isUnmounted&&Q()):Q()}else{const Q=R.subTree=Pm(R);b(null,Q,x,B,R,k,V),T.el=Q.el}if(qe&&Fn(qe,k),!F&&(ce=xe&&xe.onVnodeMounted)){const Q=T;Fn(()=>Mi(ce,G,Q),k)}(T.shapeFlag&256||G&&F0(G.vnode)&&G.vnode.shapeFlag&256)&&R.a&&Fn(R.a,k),R.isMounted=!0,T=x=B=null}},Y=R.effect=new $3(z,()=>X3(re),R.scope),re=R.update=()=>Y.run();re.id=R.uid,ms(R,!0),re()},Z=(R,T,x)=>{T.component=R;const B=R.vnode.props;R.vnode=T,R.next=null,VQ(R,T.props,B,x),GQ(R,T.children,x),zo(),WA(),Go()},X=(R,T,x,B,k,V,J,z,Y=!1)=>{const re=R&&R.children,ce=R?R.shapeFlag:0,Te=T.children,{patchFlag:xe,shapeFlag:Le}=T;if(xe>0){if(xe&128){K(re,Te,x,B,k,V,J,z,Y);return}else if(xe&256){le(re,Te,x,B,k,V,J,z,Y);return}}Le&8?(ce&16&&De(re,k,V),Te!==re&&d(x,Te)):ce&16?Le&16?K(re,Te,x,B,k,V,J,z,Y):De(re,k,V,!0):(ce&8&&d(x,""),Le&16&&L(Te,x,B,k,V,J,z,Y))},le=(R,T,x,B,k,V,J,z,Y)=>{R=R||Oo,T=T||Oo;const re=R.length,ce=T.length,Te=Math.min(re,ce);let xe;for(xe=0;xece?De(R,k,V,!0,!1,Te):L(T,x,B,k,V,J,z,Y,Te)},K=(R,T,x,B,k,V,J,z,Y)=>{let re=0;const ce=T.length;let Te=R.length-1,xe=ce-1;for(;re<=Te&&re<=xe;){const Le=R[re],qe=T[re]=Y?Ma(T[re]):Bi(T[re]);if(pu(Le,qe))b(Le,qe,x,null,k,V,J,z,Y);else break;re++}for(;re<=Te&&re<=xe;){const Le=R[Te],qe=T[xe]=Y?Ma(T[xe]):Bi(T[xe]);if(pu(Le,qe))b(Le,qe,x,null,k,V,J,z,Y);else break;Te--,xe--}if(re>Te){if(re<=xe){const Le=xe+1,qe=Lexe)for(;re<=Te;)Re(R[re],k,V,!0),re++;else{const Le=re,qe=re,G=new Map;for(re=qe;re<=xe;re++){const Ve=T[re]=Y?Ma(T[re]):Bi(T[re]);Ve.key!=null&&G.set(Ve.key,re)}let F,Q=0;const te=xe-qe+1;let me=!1,Oe=0;const Ne=new Array(te);for(re=0;re=te){Re(Ve,k,V,!0);continue}let pe;if(Ve.key!=null)pe=G.get(Ve.key);else for(F=qe;F<=xe;F++)if(Ne[F-qe]===0&&pu(Ve,T[F])){pe=F;break}pe===void 0?Re(Ve,k,V,!0):(Ne[pe-qe]=re+1,pe>=Oe?Oe=pe:me=!0,b(Ve,T[pe],x,null,k,V,J,z,Y),Q++)}const We=me?XQ(Ne):Oo;for(F=We.length-1,re=te-1;re>=0;re--){const Ve=qe+re,pe=T[Ve],we=Ve+1{const{el:V,type:J,transition:z,children:Y,shapeFlag:re}=R;if(re&6){he(R.component.subTree,T,x,B);return}if(re&128){R.suspense.move(T,x,B);return}if(re&64){J.move(R,T,x,fe);return}if(J===On){s(V,T,x);for(let Te=0;Tez.enter(V),k);else{const{leave:Te,delayLeave:xe,afterLeave:Le}=z,qe=()=>s(V,T,x),G=()=>{Te(V,()=>{qe(),Le&&Le()})};xe?xe(V,qe,G):G()}else s(V,T,x)},Re=(R,T,x,B=!1,k=!1)=>{const{type:V,props:J,ref:z,children:Y,dynamicChildren:re,shapeFlag:ce,patchFlag:Te,dirs:xe}=R;if(z!=null&&n3(z,null,x,R,!0),ce&256){T.ctx.deactivate(R);return}const Le=ce&1&&xe,qe=!F0(R);let G;if(qe&&(G=J&&J.onVnodeBeforeUnmount)&&Mi(G,T,R),ce&6)Ee(R.component,x,B);else{if(ce&128){R.suspense.unmount(x,B);return}Le&&bs(R,null,T,"beforeUnmount"),ce&64?R.type.remove(R,T,x,k,fe,B):re&&(V!==On||Te>0&&Te&64)?De(re,T,x,!1,!0):(V===On&&Te&384||!k&&ce&16)&&De(Y,T,x),B&&ie(R)}(qe&&(G=J&&J.onVnodeUnmounted)||Le)&&Fn(()=>{G&&Mi(G,T,R),Le&&bs(R,null,T,"unmounted")},x)},ie=R=>{const{type:T,el:x,anchor:B,transition:k}=R;if(T===On){ae(x,B);return}if(T===Nm){w(R);return}const V=()=>{n(x),k&&!k.persisted&&k.afterLeave&&k.afterLeave()};if(R.shapeFlag&1&&k&&!k.persisted){const{leave:J,delayLeave:z}=k,Y=()=>J(x,V);z?z(R.el,V,Y):Y()}else V()},ae=(R,T)=>{let x;for(;R!==T;)x=f(R),n(R),R=x;n(T)},Ee=(R,T,x)=>{const{bum:B,scope:k,update:V,subTree:J,um:z}=R;B&&Im(B),k.stop(),V&&(V.active=!1,Re(J,R,T,x)),z&&Fn(z,T),Fn(()=>{R.isUnmounted=!0},T),T&&T.pendingBranch&&!T.isUnmounted&&R.asyncDep&&!R.asyncResolved&&R.suspenseId===T.pendingId&&(T.deps--,T.deps===0&&T.resolve())},De=(R,T,x,B=!1,k=!1,V=0)=>{for(let J=V;JR.shapeFlag&6?ge(R.component.subTree):R.shapeFlag&128?R.suspense.next():f(R.anchor||R.el),de=(R,T,x)=>{R==null?T._vnode&&Re(T._vnode,null,null,!0):b(T._vnode||null,R,T,null,null,null,x),WA(),E9(),T._vnode=R},fe={p:b,um:Re,m:he,r:ie,mt:j,mc:L,pc:X,pbc:E,n:ge,o:t};let H,N;return e&&([H,N]=e(fe)),{render:de,hydrate:H,createApp:HQ(de,H)}}function ms({effect:t,update:e},u){t.allowRecurse=e.allowRecurse=u}function V9(t,e,u=!1){const s=t.children,n=e.children;if(Rt(s)&&Rt(n))for(let r=0;r>1,t[u[o]]0&&(e[s]=u[r-1]),u[r]=s)}}for(r=u.length,a=u[r-1];r-- >0;)u[r]=a,a=e[a];return u}const KQ=t=>t.__isTeleport,On=Symbol.for("v-fgt"),Sb=Symbol.for("v-txt"),Ga=Symbol.for("v-cmt"),Nm=Symbol.for("v-stc"),B0=[];let wi=null;function jt(t=!1){B0.push(wi=t?null:[])}function YQ(){B0.pop(),wi=B0[B0.length-1]||null}let G0=1;function sE(t){G0+=t}function k9(t){return t.dynamicChildren=G0>0?wi||Oo:null,YQ(),G0>0&&wi&&wi.push(t),t}function ir(t,e,u,s,n,r){return k9(Bt(t,e,u,s,n,r,!0))}function Ii(t,e,u,s,n){return k9(ar(t,e,u,s,n,!0))}function ib(t){return t?t.__v_isVNode===!0:!1}function pu(t,e){return t.type===e.type&&t.key===e.key}const Tb="__vInternal",z9=({key:t})=>t??null,q1=({ref:t,ref_key:e,ref_for:u})=>(typeof t=="number"&&(t=""+t),t!=null?qr(t)||fn(t)||Pt(t)?{i:nn,r:t,k:e,f:!!u}:t:null);function Bt(t,e=null,u=null,s=0,n=null,r=t===On?0:1,a=!1,o=!1){const l={__v_isVNode:!0,__v_skip:!0,type:t,props:e,key:e&&z9(e),ref:e&&q1(e),scopeId:vb,slotScopeIds:null,children:u,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:r,patchFlag:s,dynamicProps:n,dynamicChildren:null,appContext:null,ctx:nn};return o?(rT(l,u),r&128&&t.normalize(l)):u&&(l.shapeFlag|=qr(u)?8:16),G0>0&&!a&&wi&&(l.patchFlag>0||r&6)&&l.patchFlag!==32&&wi.push(l),l}const ar=ZQ;function ZQ(t,e=null,u=null,s=0,n=null,r=!1){if((!t||t===j9)&&(t=Ga),ib(t)){const o=No(t,e,!0);return u&&rT(o,u),G0>0&&!r&&wi&&(o.shapeFlag&6?wi[wi.indexOf(t)]=o:wi.push(o)),o.patchFlag|=-2,o}if(cH(t)&&(t=t.__vccOpts),e){e=eH(e);let{class:o,style:l}=e;o&&!qr(o)&&(e.class=rn(o)),Sr(l)&&(b9(l)&&!Rt(l)&&(l=Wr({},l)),e.style=Ua(l))}const a=qr(t)?1:vQ(t)?128:KQ(t)?64:Sr(t)?4:Pt(t)?2:0;return Bt(t,e,u,s,n,a,r,!0)}function eH(t){return t?b9(t)||Tb in t?Wr({},t):t:null}function No(t,e,u=!1){const{props:s,ref:n,patchFlag:r,children:a}=t,o=e?i3(s||{},e):s;return{__v_isVNode:!0,__v_skip:!0,type:t.type,props:o,key:o&&z9(o),ref:e&&e.ref?u&&n?Rt(n)?n.concat(q1(e)):[n,q1(e)]:q1(e):n,scopeId:t.scopeId,slotScopeIds:t.slotScopeIds,children:a,target:t.target,targetAnchor:t.targetAnchor,staticCount:t.staticCount,shapeFlag:t.shapeFlag,patchFlag:e&&t.type!==On?r===-1?16:r|16:r,dynamicProps:t.dynamicProps,dynamicChildren:t.dynamicChildren,appContext:t.appContext,dirs:t.dirs,transition:t.transition,component:t.component,suspense:t.suspense,ssContent:t.ssContent&&No(t.ssContent),ssFallback:t.ssFallback&&No(t.ssFallback),el:t.el,anchor:t.anchor,ctx:t.ctx,ce:t.ce}}function T0(t=" ",e=0){return ar(Sb,null,t,e)}function Vr(t="",e=!1){return e?(jt(),Ii(Ga,null,t)):ar(Ga,null,t)}function Bi(t){return t==null||typeof t=="boolean"?ar(Ga):Rt(t)?ar(On,null,t.slice()):typeof t=="object"?Ma(t):ar(Sb,null,String(t))}function Ma(t){return t.el===null&&t.patchFlag!==-1||t.memo?t:No(t)}function rT(t,e){let u=0;const{shapeFlag:s}=t;if(e==null)e=null;else if(Rt(e))u=16;else if(typeof e=="object")if(s&65){const n=e.default;n&&(n._c&&(n._d=!1),rT(t,n()),n._c&&(n._d=!0));return}else{u=32;const n=e._;!n&&!(Tb in e)?e._ctx=nn:n===3&&nn&&(nn.slots._===1?e._=1:(e._=2,t.patchFlag|=1024))}else Pt(e)?(e={default:e,_ctx:nn},u=32):(e=String(e),s&64?(u=16,e=[T0(e)]):u=8);t.children=e,t.shapeFlag|=u}function i3(...t){const e={};for(let u=0;uGr||nn;let nT,bo,oE="__VUE_INSTANCE_SETTERS__";(bo=GS()[oE])||(bo=GS()[oE]=[]),bo.push(t=>Gr=t),nT=t=>{bo.length>1?bo.forEach(e=>e(t)):bo[0](t)};const Co=t=>{nT(t),t.scope.on()},zs=()=>{Gr&&Gr.scope.off(),nT(null)};function G9(t){return t.vnode.shapeFlag&4}let W0=!1;function aH(t,e=!1){W0=e;const{props:u,children:s}=t.vnode,n=G9(t);$Q(t,u,n,e),zQ(t,s);const r=n?sH(t,e):void 0;return W0=!1,r}function sH(t,e){const u=t.type;t.accessCache=Object.create(null),t.proxy=m9(new Proxy(t.ctx,CQ));const{setup:s}=u;if(s){const n=t.setupContext=s.length>1?J9(t):null;Co(t),zo();const r=$a(s,t,0,[t.props,n]);if(Go(),zs(),ZM(r)){if(r.then(zs,zs),e)return r.then(a=>{uE(t,a,e)}).catch(a=>{gb(a,t,0)});t.asyncDep=r}else uE(t,r,e)}else W9(t,e)}function uE(t,e,u){Pt(e)?t.type.__ssrInlineRender?t.ssrRender=e:t.render=e:Sr(e)&&(t.setupState=w9(e)),W9(t,u)}let cE;function W9(t,e,u){const s=t.type;if(!t.render){if(!e&&cE&&!s.render){const n=s.template||eT(t).template;if(n){const{isCustomElement:r,compilerOptions:a}=t.appContext.config,{delimiters:o,compilerOptions:l}=s,c=Wr(Wr({isCustomElement:r,delimiters:o},a),l);s.render=cE(n,c)}}t.render=s.render||Si}Co(t),zo(),MQ(t),Go(),zs()}function oH(t){return t.attrsProxy||(t.attrsProxy=new Proxy(t.attrs,{get(e,u){return Bn(t,"get","$attrs"),e[u]}}))}function J9(t){const e=u=>{t.exposed=u||{}};return{get attrs(){return oH(t)},slots:t.slots,emit:t.emit,expose:e}}function Ab(t){if(t.exposed)return t.exposeProxy||(t.exposeProxy=new Proxy(w9(m9(t.exposed)),{get(e,u){if(u in e)return e[u];if(u in q0)return q0[u](t)},has(e,u){return u in e||u in q0}}))}function uH(t,e=!0){return Pt(t)?t.displayName||t.name:t.name||e&&t.__name}function cH(t){return Pt(t)&&"__vccOpts"in t}const sr=(t,e)=>oQ(t,e,W0);function X9(t,e,u){const s=arguments.length;return s===2?Sr(e)&&!Rt(e)?ib(e)?ar(t,null,[e]):ar(t,e):ar(t,null,e):(s>3?u=Array.prototype.slice.call(arguments,2):s===3&&ib(u)&&(u=[u]),ar(t,e,u))}const lH=Symbol.for("v-scx"),dH=()=>Ai(lH),fH="3.3.4",hH="http://www.w3.org/2000/svg",Us=typeof document<"u"?document:null,lE=Us&&Us.createElement("template"),pH={insert:(t,e,u)=>{e.insertBefore(t,u||null)},remove:t=>{const e=t.parentNode;e&&e.removeChild(t)},createElement:(t,e,u,s)=>{const n=e?Us.createElementNS(hH,t):Us.createElement(t,u?{is:u}:void 0);return t==="select"&&s&&s.multiple!=null&&n.setAttribute("multiple",s.multiple),n},createText:t=>Us.createTextNode(t),createComment:t=>Us.createComment(t),setText:(t,e)=>{t.nodeValue=e},setElementText:(t,e)=>{t.textContent=e},parentNode:t=>t.parentNode,nextSibling:t=>t.nextSibling,querySelector:t=>Us.querySelector(t),setScopeId(t,e){t.setAttribute(e,"")},insertStaticContent(t,e,u,s,n,r){const a=u?u.previousSibling:e.lastChild;if(n&&(n===r||n.nextSibling))for(;e.insertBefore(n.cloneNode(!0),u),!(n===r||!(n=n.nextSibling)););else{lE.innerHTML=s?`${t}`:t;const o=lE.content;if(s){const l=o.firstChild;for(;l.firstChild;)o.appendChild(l.firstChild);o.removeChild(l)}e.insertBefore(o,u)}return[a?a.nextSibling:e.firstChild,u?u.previousSibling:e.lastChild]}};function yH(t,e,u){const s=t._vtc;s&&(e=(e?[e,...s]:[...s]).join(" ")),e==null?t.removeAttribute("class"):u?t.setAttribute("class",e):t.className=e}function bH(t,e,u){const s=t.style,n=qr(u);if(u&&!n){if(e&&!qr(e))for(const r in e)u[r]==null&&a3(s,r,"");for(const r in u)a3(s,r,u[r])}else{const r=s.display;n?e!==u&&(s.cssText=u):e&&t.removeAttribute("style"),"_vod"in t&&(s.display=r)}}const dE=/\s*!important$/;function a3(t,e,u){if(Rt(u))u.forEach(s=>a3(t,e,s));else if(u==null&&(u=""),e.startsWith("--"))t.setProperty(e,u);else{const s=mH(t,e);dE.test(u)?t.setProperty(ko(s),u.replace(dE,""),"important"):t[s]=u}}const fE=["Webkit","Moz","ms"],Cm={};function mH(t,e){const u=Cm[e];if(u)return u;let s=$i(e);if(s!=="filter"&&s in t)return Cm[e]=s;s=yb(s);for(let n=0;njm||(AH.then(()=>jm=0),jm=Date.now());function OH(t,e){const u=s=>{if(!s._vts)s._vts=Date.now();else if(s._vts<=u.attached)return;Ti(RH(s,u.value),e,5,[s])};return u.value=t,u.attached=EH(),u}function RH(t,e){if(Rt(e)){const u=t.stopImmediatePropagation;return t.stopImmediatePropagation=()=>{u.call(t),t._stopped=!0},e.map(s=>n=>!n._stopped&&s&&s(n))}else return e}const yE=/^on[a-z]/,xH=(t,e,u,s,n=!1,r,a,o,l)=>{e==="class"?yH(t,s,n):e==="style"?bH(t,u,s):fb(e)?q3(e)||SH(t,e,u,s,a):(e[0]==="."?(e=e.slice(1),!0):e[0]==="^"?(e=e.slice(1),!1):IH(t,e,s,n))?_H(t,e,s,r,a,o,l):(e==="true-value"?t._trueValue=s:e==="false-value"&&(t._falseValue=s),gH(t,e,s,n))};function IH(t,e,u,s){return s?!!(e==="innerHTML"||e==="textContent"||e in t&&yE.test(e)&&Pt(u)):e==="spellcheck"||e==="draggable"||e==="translate"||e==="form"||e==="list"&&t.tagName==="INPUT"||e==="type"&&t.tagName==="TEXTAREA"||yE.test(e)&&qr(u)?!1:e in t}const PH=Wr({patchProp:xH},pH);let bE;function DH(){return bE||(bE=WQ(PH))}const NH=(...t)=>{const e=DH().createApp(...t),{mount:u}=e;return e.mount=s=>{const n=CH(s);if(!n)return;const r=e._component;!Pt(r)&&!r.render&&!r.template&&(r.template=n.innerHTML),n.innerHTML="";const a=u(n,!1,n instanceof SVGElement);return n instanceof Element&&(n.removeAttribute("v-cloak"),n.setAttribute("data-v-app","")),a},e};function CH(t){return qr(t)?document.querySelector(t):t}const jH=["primary","secondary","success","danger","warning","info","light","dark"],LH="rgba({{color}}, 0.2) 0, rgba({{color}}, 0.3) 40%, rgba({{color}}, 0.4) 50%, rgba({{color}}, 0.5) 60%, rgba({{color}}, 0) 70%",MH=[0,0,0],mE=.5,FH=t=>t&&jH.includes(t.toLowerCase()),qH=(t,e)=>{const u=r=>(r.length<7&&(r=`#${r[1]}${r[1]}${r[2]}${r[2]}${r[3]}${r[3]}`),[parseInt(r.substr(1,2),16),parseInt(r.substr(3,2),16),parseInt(r.substr(5,2),16)]),s=r=>{const a=document.body.appendChild(document.createElement("fictum")),o="rgb(1, 2, 3)";return a.style.color=o,a.style.color!==o||(a.style.color=r,a.style.color===o||a.style.color==="")?e:(r=getComputedStyle(a).color,document.body.removeChild(a),r)},n=r=>{const a=r.match(/[.\d]+/g);if(a===null)return;const o=a.map(l=>+Number(l));return o.length=3,o};return typeof t=="string"&&t.toLowerCase()==="transparent"?e:typeof t=="string"&&t[0]==="#"?u(t):(typeof t=="string"&&t.indexOf("rgb")===-1&&(t=s(t)),typeof t=="string"&&t.indexOf("rgb")===0?n(t):e)},BH=({offsetX:t,offsetY:e,height:u,width:s})=>{const n=e<=u/2,r=t<=s/2,a=(h,f)=>Math.sqrt(h**2+f**2),o=e===u/2&&t===s/2,l={first:n===!0&&r===!1,second:n===!0&&r===!0,third:n===!1&&r===!0,fourth:n===!1&&r===!1},c={topLeft:a(t,e),topRight:a(s-t,e),bottomLeft:a(t,u-e),bottomRight:a(s-t,u-e)};let d=0;return o||l.fourth?d=c.topLeft:l.third?d=c.topRight:l.second?d=c.bottomRight:l.first&&(d=c.bottomLeft),d*2},UH=(t,e)=>{for(const u in e)t.style[u]=e[u]},QH=t=>{const e=qH(t,MH);if(t!==""&&e){const u=e.join(",");return`radial-gradient(circle, ${LH.split("{{color}}").join(`${u}`)})`}},HH=(t,e,u)=>{const s=document.createElement("div");s.classList.add("ripple-wave");const n={offsetX:u.centered?e.height/2:e.left,offsetY:u.centered?e.width/2:e.top,height:e.height,width:e.width},r=BH(n),a=u.radius||r/2,o={delay:u.duration&&u.duration*mE,duration:u.duration&&u.duration-u.duration*mE},l={left:u.centered?`${Math.round(e.width/2-a)}px`:`${Math.round(e.left-a)}px`,top:u.centered?`${Math.round(e.height/2-a)}px`:`${Math.round(e.top-a)}px`,height:`${Math.round(u.radius&&u.radius*2||r)}px`,width:`${Math.round(u.radius&&u.radius*2||r)}px`,transitionDelay:`0s, ${o.delay}ms`,transitionDuration:`${u.duration}ms, ${o.duration}ms`};u.unbound&&t.classList.add("ripple-surface-unbound"),FH(u.color)?t.classList.add(`ripple-surface-${u.color}`):l.backgroundImage=QH(u.color),UH(s,l),t.appendChild(s),setTimeout(()=>{s.classList.add("active")},50),setTimeout(()=>{t.removeChild(s)},u.duration?u.duration+1e3:1e3)},K9={mounted(t,e){if(e.value===!1)return;const u={centered:e.value&&e.value.centered||!1,color:e.value&&e.value.color||"",duration:e.value&&e.value.duration||500,radius:e.value&&e.value.radius||0,unbound:e.value&&e.value.unbound||!1};t.classList.add("ripple-surface"),t.waves=s=>{const n={top:s.layerY,left:s.layerX,height:t.offsetHeight,width:t.offsetWidth};HH(t,n,u)},t.addEventListener("click",s=>t.waves(s))},updated(t){t.classList.contains("ripple-surface")||t.classList.add("ripple-surface")},unmounted(t){t.removeEventListener("click",e=>t.waves(e))}},$H={name:"MDBBtn"},VH=xi({...$H,props:{color:String,size:String,outline:String,rounded:Boolean,floating:Boolean,toggler:Boolean,toggle:Boolean,role:{type:String,default:"button"},type:{type:String,default:"button"},tag:{type:String,default:"button"},block:{type:Boolean,default:!1},ripple:{type:[Object,Boolean],default:t=>t.outline||t.color==="light"||t.color==="link"?{color:"dark"}:!0},picker:Boolean},emits:["update:toggle"],setup(t,{emit:e}){const u=t,s=En(u.toggle),n=sr(()=>[!u.picker&&"btn",u.color&&`btn-${u.color}`,u.size&&`btn-${u.size}`,u.outline&&`btn-outline-${u.outline}`,u.rounded&&"btn-rounded",u.floating&&"btn-floating",u.block&&"btn-block",s.value&&"active"]),r=()=>{u.toggler&&(s.value=!s.value,e("update:toggle",s.value))};return(a,o)=>tb((jt(),Ii(Ka(t.tag),{type:t.type,role:t.role,class:rn(qt(n)),onClick:r},{default:Lr(()=>[Hi(a.$slots,"default")]),_:3},8,["type","role","class"])),[[qt(K9),t.ripple]])}}),kH={name:"MDBCard"},zH=xi({...kH,props:{tag:{type:String,default:"div"},border:String,bg:String,text:[String,Array],shadow:String},setup(t){const e=t,u=sr(()=>{const n=e.text;return["card",e.border&&`border border-${e.border}`,e.bg&&`bg-${e.bg}`,e.shadow&&`shadow-${e.shadow}`,e.text&&s(n)]}),s=n=>typeof n=="string"?`text-${n}`:n.map(r=>`text-${r}`.trim()).join(" ");return(n,r)=>(jt(),Ii(Ka(t.tag),{class:rn(qt(u))},{default:Lr(()=>[Hi(n.$slots,"default")]),_:3},8,["class"]))}}),GH={name:"MDBCardBody"},WH=xi({...GH,props:{tag:{type:String,default:"div"},text:{type:[String,Array]}},setup(t){const e=t,u=sr(()=>{const n=e.text;return["card-body",e.text&&s(n)]}),s=n=>typeof n=="string"?`text-${n}`:n.map(r=>`text-${r}`.trim()).join(" ");return(n,r)=>(jt(),Ii(Ka(t.tag),{class:rn(qt(u))},{default:Lr(()=>[Hi(n.$slots,"default")]),_:3},8,["class"]))}}),JH={name:"MDBCardTitle"},XH=xi({...JH,props:{tag:{type:String,default:"h5"},subtitle:{type:Boolean,default:!1}},setup(t){const e=t,u=sr(()=>e.subtitle?e.tag!=="h5"?e.tag:"h6":e.tag),s=sr(()=>[e.subtitle?"card-subtitle":"card-title"]);return(n,r)=>(jt(),Ii(Ka(qt(u)),{class:rn(qt(s))},{default:Lr(()=>[Hi(n.$slots,"default")]),_:3},8,["class"]))}}),KH={name:"MDBCardText"},YH=xi({...KH,props:{tag:{type:String,default:"p"}},setup(t){const e=sr(()=>["card-text"]);return(u,s)=>(jt(),Ii(Ka(t.tag),{class:rn(qt(e))},{default:Lr(()=>[Hi(u.$slots,"default")]),_:3},8,["class"]))}}),ZH=1e6,e$=t=>{do t+=Math.floor(Math.random()*ZH);while(document.getElementById(t));return t},t$=/\..*/,r$={mouseenter:"mouseover",mouseleave:"mouseout"},n$=["click","dblclick","mouseup","mousedown","contextmenu","mousewheel","DOMMouseScroll","mouseover","mouseout","mousemove","selectstart","selectend","keydown","keypress","keyup","orientationchange","touchstart","touchmove","touchend","touchcancel","pointerdown","pointermove","pointerup","pointerleave","pointercancel","gesturestart","gesturechange","gestureend","focus","blur","change","reset","select","submit","focusin","focusout","load","unload","beforeunload","resize","move","DOMContentLoaded","readystatechange","error","abort","scroll"];function Y9(t,e,u){const s=typeof e=="string",n=s?u:e;let r=t.replace(t$,"");const a=r$[r];return a&&(r=a),n$.indexOf(r)>-1||(r=t),[s,n,r]}function i$(t,e,u,s){if(typeof e!="string"||!t)return;u||(u=s,s=null);const[n,r,a]=Y9(e,u,s);t.addEventListener(a,r,n)}function a$(t,e,u,s){t.removeEventListener(e,u,!!s)}const s$=function(t,e,u,s=void 0){i$(t,e,u,s)},o$=function(t,e,u,s=void 0){if(typeof e!="string"||!t)return;const[n,r,a]=Y9(e,u,s);a$(t,a,r,n?u:null)};var s3={stopProp(t){t.stopPropagation()},mounted(t,e){const u=n=>{const r=n.target;!t.contains(r)&&t!==r&&e.value(n)};t.clickOutside=u;const s=e.modifiers.mousedown?"mousedown":"click";document.addEventListener(s,n=>{var r;return(r=t.clickOutside)==null?void 0:r.call(t,n)}),document.addEventListener("touchstart",n=>{var r;return(r=t.clickOutside)==null?void 0:r.call(t,n)})},unmounted(t,e){if(!t.clickOutside)return;const u=e.modifiers.mousedown?"mousedown":"click";document.removeEventListener(u,s=>{var n;return(n=t.clickOutside)==null?void 0:n.call(t,s)}),document.removeEventListener("touchstart",s=>{var n;return(n=t.clickOutside)==null?void 0:n.call(t,s)}),delete t.clickOutside}};const u$={key:1,class:"visually-hidden"},c$={name:"MDBDropdownToggle"};({...c$,props:{...VH.props}});const l$={name:"MDBContainer"},d$=xi({...l$,props:{tag:{type:String,default:"div"},sm:{type:Boolean,default:!1},md:{type:Boolean,default:!1},lg:{type:Boolean,default:!1},xl:{type:Boolean,default:!1},xxl:{type:Boolean,default:!1},fluid:{type:Boolean,default:!1}},setup(t){const e=t,u=sr(()=>[e.fluid?"container-fluid":"",e.sm?"container-sm":"",e.md?"container-md":"",e.lg?"container-lg":"",e.xl?"container-xl":"",e.xxl?"container-xxl":"",!e.fluid&&!e.sm&&!e.md&&!e.lg&&!e.xl&&!e.xxl?"container":""]);return(s,n)=>(jt(),Ii(Ka(t.tag),{class:rn(qt(u))},{default:Lr(()=>[Hi(s.$slots,"default")]),_:3},8,["class"]))}}),f$=["id","value"],h$=["for"],p$={key:2,class:"form-helper"},y$={key:3,class:"form-helper"},b$={class:"form-counter"},m$=Bt("div",{class:"form-notch-trailing"},null,-1),g$=["id","value"],_$=["for"],v$={key:1,class:"form-helper"},w$={key:2,class:"form-helper"},S$={class:"form-counter"},T$=Bt("div",{class:"form-notch-trailing"},null,-1),A$={key:9,class:"form-text"},E$={name:"MDBInput",inheritAttrs:!1},O$=xi({...E$,props:{id:String,label:String,labelClass:String,modelValue:[String,Number,Date],size:String,formOutline:{type:Boolean,default:!0},wrapperClass:String,inputGroup:{type:[Boolean,String],default:!1},wrap:{type:Boolean,default:!0},formText:String,white:Boolean,validationEvent:String,isValidated:Boolean,isValid:Boolean,validFeedback:String,invalidFeedback:String,tooltipFeedback:{type:Boolean,default:!1},tag:{type:String,default:"div"},helper:String,counter:Boolean,maxlength:{type:Number,default:0}},emits:["update:modelValue","click-outside","on-validate"],setup(t,{expose:e,emit:u}){const s=t,n=jQ(),r=En(null),a=En(s.modelValue),o=En(null),l=En(!1),c=En(9),d=En(0),h=s.id||e$("MDBInput-"),f=sr(()=>[s.formOutline&&"form-outline",b.value,s.white&&"form-white",s.wrapperClass]),p=sr(()=>["form-control",s.size?`form-control-${s.size}`:s.inputGroup&&s.inputGroup!==!0&&`form-control-${s.inputGroup}`,(a.value||a.value===0)&&"active",l.value&&"placeholder-active",_.value&&w.value&&"is-valid",_.value&&!w.value&&"is-invalid"]),y=sr(()=>["form-label",s.labelClass]),b=sr(()=>{if(s.inputGroup)return s.inputGroup!==!0?`input-group input-group-${s.inputGroup}`:"input-group"}),g=sr(()=>s.inputGroup&&_.value?{marginBottom:"1rem"}:""),m=sr(()=>s.tooltipFeedback?"valid-tooltip":"valid-feedback"),v=sr(()=>s.tooltipFeedback?"invalid-tooltip":"invalid-feedback"),_=En(s.isValidated),w=En(s.isValid),S=En(""),A=sr(()=>_.value&&!w.value&&s.validationEvent?S.value:s.invalidFeedback),D=K=>{const he=K.target;w.value=he.checkValidity(),w.value||(S.value=he.validationMessage),_.value=!0,u("on-validate",w.value)},L=()=>{s.validationEvent!=="submit"&&typeof r.value!="string"&&s$(r.value,s.validationEvent,D)};function O(){o.value&&(d.value=o.value.clientWidth*.8+8)}function E(){n.placeholder&&!o.value?l.value=!0:l.value=!1}const P=En(null);P.value=typeof a.value=="string"&&a.value?a.value.length:0;function M(K){const he=K.target;if(s.counter){if(he.value.length>s.maxlength){typeof a.value=="string"&&(he.value=a.value);return}P.value=he.value.length}a.value=he.value,u("update:modelValue",a.value)}function U(){u("click-outside")}const j=En(null),q=En(),$=K=>{q.value.forEach(he=>he.style.opacity=K?"0":"1"),K&&(j.value.style.opacity="1")},Z=n.type&&n.type==="date",X=(K=!1)=>{var he;s.label&&s.formOutline&&((he=q.value)==null?void 0:he.length)>1&&$(K),Z&&typeof r.value!="string"&&(r.value.type=K?"date":"text")},le=K=>![...K.parentNode.children].findIndex(he=>he===K);return N9(()=>{if(O(),E(),X(),s.label&&s.formOutline&&(q.value=r.value.parentNode.querySelectorAll(".form-notch")),s.label&&s.formOutline&&!le(r.value)){const K=parseFloat(getComputedStyle(o.value).left);o.value.style.left=`${K+r.value.offsetLeft}px`,c.value+=r.value.offsetLeft}s.validationEvent&&L()}),C9(()=>{O(),E()}),Y3(()=>{typeof r.value!="string"&&o$(r.value,s.validationEvent,D)}),x9(()=>{var K,he;if(s.counter&&typeof s.modelValue=="string"){if(((K=s.modelValue)==null?void 0:K.length)>s.maxlength){a.value=s.modelValue.slice(0,s.maxlength),P.value=s.maxlength;return}P.value=((he=s.modelValue)==null?void 0:he.length)||0}a.value=s.modelValue}),Po(()=>s.isValidated,K=>_.value=K),Po(()=>s.isValid,K=>w.value=K),e({inputRef:r}),(K,he)=>(jt(),ir(On,null,[t.wrap?Vr("",!0):tb((jt(),ir("input",i3({key:0,class:qt(p),id:qt(h),value:a.value},K.$attrs,{onInput:M,ref_key:"inputRef",ref:r,onFocus:he[0]||(he[0]=Re=>X(!0)),onBlur:he[1]||(he[1]=Re=>X())}),null,16,f$)),[[qt(s3),U]]),t.label&&!t.wrap?(jt(),ir("label",{key:1,ref_key:"labelRef",ref:o,class:rn(qt(y)),for:qt(h)},Or(t.label),11,h$)):Vr("",!0),!t.wrap&&t.helper?(jt(),ir("div",p$,Or(t.helper),1)):Vr("",!0),!t.wrap&&t.counter?(jt(),ir("div",y$,[Bt("div",b$,Or(P.value)+" / "+Or(t.maxlength),1)])):Vr("",!0),t.wrap?Vr("",!0):Hi(K.$slots,"default",{key:4}),!t.wrap&&t.validFeedback?(jt(),ir("div",{key:5,class:rn(qt(m))},Or(t.validFeedback),3)):Vr("",!0),!t.wrap&&qt(A)?(jt(),ir("div",{key:6,class:rn(qt(v))},Or(qt(A)),3)):Vr("",!0),!t.wrap&&t.formOutline?(jt(),ir("div",{key:7,class:"form-notch",ref_key:"notchRef",ref:j},[Bt("div",{class:"form-notch-leading",style:Ua({width:`${c.value}px`})},null,4),Bt("div",{class:"form-notch-middle",style:Ua({width:`${d.value}px`})},null,4),m$],512)):Vr("",!0),t.wrap?tb((jt(),Ii(Ka(t.tag),{key:8,class:rn(qt(f)),style:Ua(qt(g))},{default:Lr(()=>[Hi(K.$slots,"prepend"),Bt("input",i3({class:qt(p)},K.$attrs,{id:qt(h),value:a.value,onInput:M,ref_key:"inputRef",ref:r,onFocus:he[2]||(he[2]=Re=>X(!0)),onBlur:he[3]||(he[3]=Re=>X())}),null,16,g$),t.label?(jt(),ir("label",{key:0,ref_key:"labelRef",ref:o,class:rn(qt(y)),for:qt(h)},Or(t.label),11,_$)):Vr("",!0),t.helper?(jt(),ir("div",v$,Or(t.helper),1)):Vr("",!0),t.counter?(jt(),ir("div",w$,[Bt("div",S$,Or(P.value)+" / "+Or(t.maxlength),1)])):Vr("",!0),Hi(K.$slots,"default"),t.validFeedback?(jt(),ir("div",{key:3,class:rn(qt(m))},Or(t.validFeedback),3)):Vr("",!0),qt(A)?(jt(),ir("div",{key:4,class:rn(qt(v))},Or(qt(A)),3)):Vr("",!0),t.formOutline?(jt(),ir("div",{key:5,class:"form-notch",ref_key:"notchRef",ref:j},[Bt("div",{class:"form-notch-leading",style:Ua({width:`${c.value}px`})},null,4),Bt("div",{class:"form-notch-middle",style:Ua({width:`${d.value}px`})},null,4),T$],512)):Vr("",!0)]),_:3},8,["class","style"])),[[qt(s3),U]]):Vr("",!0),t.formText?(jt(),ir("div",A$,Or(t.formText),1)):Vr("",!0)],64))}});var I=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function R$(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function iT(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var u=function s(){return this instanceof s?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};u.prototype=e.prototype}else u={};return Object.defineProperty(u,"__esModule",{value:!0}),Object.keys(t).forEach(function(s){var n=Object.getOwnPropertyDescriptor(t,s);Object.defineProperty(u,s,n.get?n:{enumerable:!0,get:function(){return t[s]}})}),u}var Z9={},Eb={},aT={},sy={},eF={},Ob={},ot={},Gs={},oy="delete",br=5,ai=1<>>0;if(""+u!==e||u===4294967295)return NaN;e=u}return e<0?jo(t)+e:e}function tF(){return!0}function uy(t,e,u){return(t===0&&!nF(t)||u!==void 0&&t<=-u)&&(e===void 0||u!==void 0&&e>=u)}function Wo(t,e){return rF(t,e,0)}function cy(t,e){return rF(t,e,e)}function rF(t,e,u){return t===void 0?u:nF(t)?e===1/0?e:Math.max(0,e+t)|0:e===void 0||e===t?t:Math.min(e,t)|0}function nF(t){return t<0||t===0&&1/t===-1/0}var iF="@@__IMMUTABLE_ITERABLE__@@";function hn(t){return!!(t&&t[iF])}var aF="@@__IMMUTABLE_KEYED__@@";function cr(t){return!!(t&&t[aF])}var sF="@@__IMMUTABLE_INDEXED__@@";function an(t){return!!(t&&t[sF])}function Jo(t){return cr(t)||an(t)}var mr=function(e){return hn(e)?e:pn(e)},ci=function(t){function e(u){return cr(u)?u:Za(u)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e}(mr),Ys=function(t){function e(u){return an(u)?u:li(u)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e}(mr),Xo=function(t){function e(u){return hn(u)&&!Jo(u)?u:Zo(u)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e}(mr);mr.Keyed=ci;mr.Indexed=Ys;mr.Set=Xo;var oF="@@__IMMUTABLE_SEQ__@@";function ly(t){return!!(t&&t[oF])}var uF="@@__IMMUTABLE_RECORD__@@";function Ya(t){return!!(t&&t[uF])}function Yn(t){return hn(t)||Ya(t)}var Ko="@@__IMMUTABLE_ORDERED__@@";function Xn(t){return!!(t&&t[Ko])}var dy=0,Ei=1,oi=2,u3=typeof Symbol=="function"&&Symbol.iterator,cF="@@iterator",Rb=u3||cF,kt=function(e){this.next=e};kt.prototype.toString=function(){return"[Iterator]"};kt.KEYS=dy;kt.VALUES=Ei;kt.ENTRIES=oi;kt.prototype.inspect=kt.prototype.toSource=function(){return this.toString()};kt.prototype[Rb]=function(){return this};function gr(t,e,u,s){var n=t===0?e:t===1?u:[e,u];return s?s.value=n:s={value:n,done:!1},s}function Pn(){return{value:void 0,done:!0}}function oT(t){return Array.isArray(t)?!0:!!xb(t)}function gE(t){return t&&typeof t.next=="function"}function c3(t){var e=xb(t);return e&&e.call(t)}function xb(t){var e=t&&(u3&&t[u3]||t[cF]);if(typeof e=="function")return e}function x$(t){var e=xb(t);return e&&e===t.entries}function I$(t){var e=xb(t);return e&&e===t.keys}var Yo=Object.prototype.hasOwnProperty;function uT(t){return Array.isArray(t)||typeof t=="string"?!0:t&&typeof t=="object"&&Number.isInteger(t.length)&&t.length>=0&&(t.length===0?Object.keys(t).length===1:t.hasOwnProperty(t.length-1))}var pn=function(t){function e(u){return u==null?lT():Yn(u)?u.toSeq():D$(u)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.toSeq=function(){return this},e.prototype.toString=function(){return this.__toString("Seq {","}")},e.prototype.cacheResult=function(){return!this._cache&&this.__iterateUncached&&(this._cache=this.entrySeq().toArray(),this.size=this._cache.length),this},e.prototype.__iterate=function(s,n){var r=this._cache;if(r){for(var a=r.length,o=0;o!==a;){var l=r[n?a-++o:o++];if(s(l[1],l[0],this)===!1)break}return o}return this.__iterateUncached(s,n)},e.prototype.__iterator=function(s,n){var r=this._cache;if(r){var a=r.length,o=0;return new kt(function(){if(o===a)return Pn();var l=r[n?a-++o:o++];return gr(s,l[0],l[1])})}return this.__iteratorUncached(s,n)},e}(mr),Za=function(t){function e(u){return u==null?lT().toKeyedSeq():hn(u)?cr(u)?u.toSeq():u.fromEntrySeq():Ya(u)?u.toSeq():dT(u)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.toKeyedSeq=function(){return this},e}(pn),li=function(t){function e(u){return u==null?lT():hn(u)?cr(u)?u.entrySeq():u.toIndexedSeq():Ya(u)?u.toSeq().entrySeq():lF(u)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.of=function(){return e(arguments)},e.prototype.toIndexedSeq=function(){return this},e.prototype.toString=function(){return this.__toString("Seq [","]")},e}(pn),Zo=function(t){function e(u){return(hn(u)&&!Jo(u)?u:li(u)).toSetSeq()}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.of=function(){return e(arguments)},e.prototype.toSetSeq=function(){return this},e}(pn);pn.isSeq=ly;pn.Keyed=Za;pn.Set=Zo;pn.Indexed=li;pn.prototype[oF]=!0;var Ws=function(t){function e(u){this._array=u,this.size=u.length}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.get=function(s,n){return this.has(s)?this._array[Wa(this,s)]:n},e.prototype.__iterate=function(s,n){for(var r=this._array,a=r.length,o=0;o!==a;){var l=n?a-++o:o++;if(s(r[l],l,this)===!1)break}return o},e.prototype.__iterator=function(s,n){var r=this._array,a=r.length,o=0;return new kt(function(){if(o===a)return Pn();var l=n?a-++o:o++;return gr(s,l,r[l])})},e}(li),cT=function(t){function e(u){var s=Object.keys(u).concat(Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(u):[]);this._object=u,this._keys=s,this.size=s.length}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.get=function(s,n){return n!==void 0&&!this.has(s)?n:this._object[s]},e.prototype.has=function(s){return Yo.call(this._object,s)},e.prototype.__iterate=function(s,n){for(var r=this._object,a=this._keys,o=a.length,l=0;l!==o;){var c=a[n?o-++l:l++];if(s(r[c],c,this)===!1)break}return l},e.prototype.__iterator=function(s,n){var r=this._object,a=this._keys,o=a.length,l=0;return new kt(function(){if(l===o)return Pn();var c=a[n?o-++l:l++];return gr(s,c,r[c])})},e}(Za);cT.prototype[Ko]=!0;var P$=function(t){function e(u){this._collection=u,this.size=u.length||u.size}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.__iterateUncached=function(s,n){if(n)return this.cacheResult().__iterate(s,n);var r=this._collection,a=c3(r),o=0;if(gE(a))for(var l;!(l=a.next()).done&&s(l.value,o++,this)!==!1;);return o},e.prototype.__iteratorUncached=function(s,n){if(n)return this.cacheResult().__iterator(s,n);var r=this._collection,a=c3(r);if(!gE(a))return new kt(Pn);var o=0;return new kt(function(){var l=a.next();return l.done?l:gr(s,o++,l.value)})},e}(li),_E;function lT(){return _E||(_E=new Ws([]))}function dT(t){var e=fT(t);if(e)return e.fromEntrySeq();if(typeof t=="object")return new cT(t);throw new TypeError("Expected Array or collection object of [k, v] entries, or keyed object: "+t)}function lF(t){var e=fT(t);if(e)return e;throw new TypeError("Expected Array or collection object of values: "+t)}function D$(t){var e=fT(t);if(e)return x$(t)?e.fromEntrySeq():I$(t)?e.toSetSeq():e;if(typeof t=="object")return new cT(t);throw new TypeError("Expected Array or collection object of values, or keyed object: "+t)}function fT(t){return uT(t)?new Ws(t):oT(t)?new P$(t):void 0}var dF="@@__IMMUTABLE_MAP__@@";function fy(t){return!!(t&&t[dF])}function Ib(t){return fy(t)&&Xn(t)}function ab(t){return!!(t&&typeof t.equals=="function"&&typeof t.hashCode=="function")}function kr(t,e){if(t===e||t!==t&&e!==e)return!0;if(!t||!e)return!1;if(typeof t.valueOf=="function"&&typeof e.valueOf=="function"){if(t=t.valueOf(),e=e.valueOf(),t===e||t!==t&&e!==e)return!0;if(!t||!e)return!1}return!!(ab(t)&&ab(e)&&t.equals(e))}var yu=typeof Math.imul=="function"&&Math.imul(4294967295,2)===-2?Math.imul:function(e,u){e|=0,u|=0;var s=e&65535,n=u&65535;return s*n+((e>>>16)*n+s*(u>>>16)<<16>>>0)|0};function Pb(t){return t>>>1&1073741824|t&3221225471}var N$=Object.prototype.valueOf;function Rn(t){if(t==null)return vE(t);if(typeof t.hashCode=="function")return Pb(t.hashCode(t));var e=q$(t);if(e==null)return vE(e);switch(typeof e){case"boolean":return e?1108378657:1108378656;case"number":return C$(e);case"string":return e.length>B$?j$(e):l3(e);case"object":case"function":return M$(e);case"symbol":return L$(e);default:if(typeof e.toString=="function")return l3(e.toString());throw new Error("Value type "+typeof e+" cannot be hashed.")}}function vE(t){return t===null?1108378658:1108378659}function C$(t){if(t!==t||t===1/0)return 0;var e=t|0;for(e!==t&&(e^=t*4294967295);t>4294967295;)t/=4294967295,e^=t;return Pb(e)}function j$(t){var e=Fm[t];return e===void 0&&(e=l3(t),Mm===U$&&(Mm=0,Fm={}),Mm++,Fm[t]=e),e}function l3(t){for(var e=0,u=0;u0)switch(t.nodeType){case 1:return t.uniqueID;case 9:return t.documentElement&&t.documentElement.uniqueID}}function q$(t){return t.valueOf!==N$&&typeof t.valueOf=="function"?t.valueOf(t):t}function fF(){var t=++Lm;return Lm&1073741824&&(Lm=0),t}var d3=typeof WeakMap=="function",f3;d3&&(f3=new WeakMap);var TE=Object.create(null),Lm=0,Qs="__immutablehash__";typeof Symbol=="function"&&(Qs=Symbol(Qs));var B$=16,U$=255,Mm=0,Fm={},Db=function(t){function e(u,s){this._iter=u,this._useKeys=s,this.size=u.size}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.get=function(s,n){return this._iter.get(s,n)},e.prototype.has=function(s){return this._iter.has(s)},e.prototype.valueSeq=function(){return this._iter.valueSeq()},e.prototype.reverse=function(){var s=this,n=hT(this,!0);return this._useKeys||(n.valueSeq=function(){return s._iter.toSeq().reverse()}),n},e.prototype.map=function(s,n){var r=this,a=mF(this,s,n);return this._useKeys||(a.valueSeq=function(){return r._iter.toSeq().map(s,n)}),a},e.prototype.__iterate=function(s,n){var r=this;return this._iter.__iterate(function(a,o){return s(a,o,r)},n)},e.prototype.__iterator=function(s,n){return this._iter.__iterator(s,n)},e}(Za);Db.prototype[Ko]=!0;var hF=function(t){function e(u){this._iter=u,this.size=u.size}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.includes=function(s){return this._iter.includes(s)},e.prototype.__iterate=function(s,n){var r=this,a=0;return n&&jo(this),this._iter.__iterate(function(o){return s(o,n?r.size-++a:a++,r)},n)},e.prototype.__iterator=function(s,n){var r=this,a=this._iter.__iterator(Ei,n),o=0;return n&&jo(this),new kt(function(){var l=a.next();return l.done?l:gr(s,n?r.size-++o:o++,l.value,l)})},e}(li),pF=function(t){function e(u){this._iter=u,this.size=u.size}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.has=function(s){return this._iter.includes(s)},e.prototype.__iterate=function(s,n){var r=this;return this._iter.__iterate(function(a){return s(a,a,r)},n)},e.prototype.__iterator=function(s,n){var r=this._iter.__iterator(Ei,n);return new kt(function(){var a=r.next();return a.done?a:gr(s,a.value,a.value,a)})},e}(Zo),yF=function(t){function e(u){this._iter=u,this.size=u.size}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.entrySeq=function(){return this._iter.toSeq()},e.prototype.__iterate=function(s,n){var r=this;return this._iter.__iterate(function(a){if(a){EE(a);var o=hn(a);return s(o?a.get(1):a[1],o?a.get(0):a[0],r)}},n)},e.prototype.__iterator=function(s,n){var r=this._iter.__iterator(Ei,n);return new kt(function(){for(;;){var a=r.next();if(a.done)return a;var o=a.value;if(o){EE(o);var l=hn(o);return gr(s,l?o.get(0):o[0],l?o.get(1):o[1],a)}}})},e}(Za);hF.prototype.cacheResult=Db.prototype.cacheResult=pF.prototype.cacheResult=yF.prototype.cacheResult=bT;function bF(t){var e=Vi(t);return e._iter=t,e.size=t.size,e.flip=function(){return t},e.reverse=function(){var u=t.reverse.apply(this);return u.flip=function(){return t.reverse()},u},e.has=function(u){return t.includes(u)},e.includes=function(u){return t.has(u)},e.cacheResult=bT,e.__iterateUncached=function(u,s){var n=this;return t.__iterate(function(r,a){return u(a,r,n)!==!1},s)},e.__iteratorUncached=function(u,s){if(u===oi){var n=t.__iterator(u,s);return new kt(function(){var r=n.next();if(!r.done){var a=r.value[0];r.value[0]=r.value[1],r.value[1]=a}return r})}return t.__iterator(u===Ei?dy:Ei,s)},e}function mF(t,e,u){var s=Vi(t);return s.size=t.size,s.has=function(n){return t.has(n)},s.get=function(n,r){var a=t.get(n,Ut);return a===Ut?r:e.call(u,a,n,t)},s.__iterateUncached=function(n,r){var a=this;return t.__iterate(function(o,l,c){return n(e.call(u,o,l,c),l,a)!==!1},r)},s.__iteratorUncached=function(n,r){var a=t.__iterator(oi,r);return new kt(function(){var o=a.next();if(o.done)return o;var l=o.value,c=l[0];return gr(n,c,e.call(u,l[1],c,t),o)})},s}function hT(t,e){var u=this,s=Vi(t);return s._iter=t,s.size=t.size,s.reverse=function(){return t},t.flip&&(s.flip=function(){var n=bF(t);return n.reverse=function(){return t.flip()},n}),s.get=function(n,r){return t.get(e?n:-1-n,r)},s.has=function(n){return t.has(e?n:-1-n)},s.includes=function(n){return t.includes(n)},s.cacheResult=bT,s.__iterate=function(n,r){var a=this,o=0;return r&&jo(t),t.__iterate(function(l,c){return n(l,e?c:r?a.size-++o:o++,a)},!r)},s.__iterator=function(n,r){var a=0;r&&jo(t);var o=t.__iterator(oi,!r);return new kt(function(){var l=o.next();if(l.done)return l;var c=l.value;return gr(n,e?c[0]:r?u.size-++a:a++,c[1],l)})},s}function gF(t,e,u,s){var n=Vi(t);return s&&(n.has=function(r){var a=t.get(r,Ut);return a!==Ut&&!!e.call(u,a,r,t)},n.get=function(r,a){var o=t.get(r,Ut);return o!==Ut&&e.call(u,o,r,t)?o:a}),n.__iterateUncached=function(r,a){var o=this,l=0;return t.__iterate(function(c,d,h){if(e.call(u,c,d,h))return l++,r(c,s?d:l-1,o)},a),l},n.__iteratorUncached=function(r,a){var o=t.__iterator(oi,a),l=0;return new kt(function(){for(;;){var c=o.next();if(c.done)return c;var d=c.value,h=d[0],f=d[1];if(e.call(u,f,h,t))return gr(r,s?h:l++,f,c)}})},n}function Q$(t,e,u){var s=ts().asMutable();return t.__iterate(function(n,r){s.update(e.call(u,n,r,t),0,function(a){return a+1})}),s.asImmutable()}function H$(t,e,u){var s=cr(t),n=(Xn(t)?Oi():ts()).asMutable();t.__iterate(function(a,o){n.update(e.call(u,a,o,t),function(l){return l=l||[],l.push(s?[o,a]:a),l})});var r=yT(t);return n.map(function(a){return ur(t,r(a))}).asImmutable()}function $$(t,e,u){var s=cr(t),n=[[],[]];t.__iterate(function(a,o){n[e.call(u,a,o,t)?1:0].push(s?[o,a]:a)});var r=yT(t);return n.map(function(a){return ur(t,r(a))})}function pT(t,e,u,s){var n=t.size;if(uy(e,u,n))return t;if(typeof n>"u"&&(e<0||u<0))return pT(t.toSeq().cacheResult(),e,u,s);var r=Wo(e,n),a=cy(u,n),o=a-r,l;o===o&&(l=o<0?0:o);var c=Vi(t);return c.size=l===0?l:t.size&&l||void 0,!s&&ly(t)&&l>=0&&(c.get=function(d,h){return d=Wa(this,d),d>=0&&dl)return Pn();var b=f.next();return s||d===Ei||b.done?b:d===dy?gr(d,y-1,void 0,b):gr(d,y-1,b.value[1],b)})},c}function V$(t,e,u){var s=Vi(t);return s.__iterateUncached=function(n,r){var a=this;if(r)return this.cacheResult().__iterate(n,r);var o=0;return t.__iterate(function(l,c,d){return e.call(u,l,c,d)&&++o&&n(l,c,a)}),o},s.__iteratorUncached=function(n,r){var a=this;if(r)return this.cacheResult().__iterator(n,r);var o=t.__iterator(oi,r),l=!0;return new kt(function(){if(!l)return Pn();var c=o.next();if(c.done)return c;var d=c.value,h=d[0],f=d[1];return e.call(u,f,h,a)?n===oi?c:gr(n,h,f,c):(l=!1,Pn())})},s}function _F(t,e,u,s){var n=Vi(t);return n.__iterateUncached=function(r,a){var o=this;if(a)return this.cacheResult().__iterate(r,a);var l=!0,c=0;return t.__iterate(function(d,h,f){if(!(l&&(l=e.call(u,d,h,f))))return c++,r(d,s?h:c-1,o)}),c},n.__iteratorUncached=function(r,a){var o=this;if(a)return this.cacheResult().__iterator(r,a);var l=t.__iterator(oi,a),c=!0,d=0;return new kt(function(){var h,f,p;do{if(h=l.next(),h.done)return s||r===Ei?h:r===dy?gr(r,d++,void 0,h):gr(r,d++,h.value[1],h);var y=h.value;f=y[0],p=y[1],c&&(c=e.call(u,p,f,o))}while(c);return r===oi?h:gr(r,f,p,h)})},n}function k$(t,e){var u=cr(t),s=[t].concat(e).map(function(a){return hn(a)?u&&(a=ci(a)):a=u?dT(a):lF(Array.isArray(a)?a:[a]),a}).filter(function(a){return a.size!==0});if(s.length===0)return t;if(s.length===1){var n=s[0];if(n===t||u&&cr(n)||an(t)&&an(n))return n}var r=new Ws(s);return u?r=r.toKeyedSeq():an(t)||(r=r.toSetSeq()),r=r.flatten(!0),r.size=s.reduce(function(a,o){if(a!==void 0){var l=o.size;if(l!==void 0)return a+l}},0),r}function vF(t,e,u){var s=Vi(t);return s.__iterateUncached=function(n,r){if(r)return this.cacheResult().__iterate(n,r);var a=0,o=!1;function l(c,d){c.__iterate(function(h,f){return(!e||d0}function n1(t,e,u,s){var n=Vi(t),r=new Ws(u).map(function(a){return a.size});return n.size=s?r.max():r.min(),n.__iterate=function(a,o){for(var l=this.__iterator(Ei,o),c,d=0;!(c=l.next()).done&&a(c.value,d++,this)!==!1;);return d},n.__iteratorUncached=function(a,o){var l=u.map(function(h){return h=mr(h),c3(o?h.reverse():h)}),c=0,d=!1;return new kt(function(){var h;return d||(h=l.map(function(f){return f.next()}),d=s?h.every(function(f){return f.done}):h.some(function(f){return f.done})),d?Pn():gr(a,c++,e.apply(null,h.map(function(f){return f.value})))})},n}function ur(t,e){return t===e?t:ly(t)?e:t.constructor(e)}function EE(t){if(t!==Object(t))throw new TypeError("Expected [K, V] tuple: "+t)}function yT(t){return cr(t)?ci:an(t)?Ys:Xo}function Vi(t){return Object.create((cr(t)?Za:an(t)?li:Zo).prototype)}function bT(){return this._iter.cacheResult?(this._iter.cacheResult(),this.size=this._iter.size,this):pn.prototype.cacheResult.call(this)}function wF(t,e){return t===void 0&&e===void 0?0:t===void 0?1:e===void 0?-1:t>e?1:t0;)e[u]=arguments[u+1];if(typeof t!="function")throw new TypeError("Invalid merger function: "+t);return OF(this,e,t)}function OF(t,e,u){for(var s=[],n=0;n0;)e[u]=arguments[u+1];return py(t,e)}function xF(t,e){for(var u=[],s=arguments.length-2;s-- >0;)u[s]=arguments[s+2];return py(e,u,t)}function IF(t){for(var e=[],u=arguments.length-1;u-- >0;)e[u]=arguments[u+1];return hy(t,e)}function PF(t,e){for(var u=[],s=arguments.length-2;s-- >0;)u[s]=arguments[s+2];return hy(e,u,t)}function hy(t,e,u){return py(t,e,J$(u))}function py(t,e,u){if(!Ja(t))throw new TypeError("Cannot merge into non-data-structure value: "+t);if(Yn(t))return typeof u=="function"&&t.mergeWith?t.mergeWith.apply(t,[u].concat(e)):t.merge?t.merge.apply(t,e):t.concat.apply(t,e);for(var s=Array.isArray(t),n=t,r=s?Ys:ci,a=s?function(l){n===t&&(n=sb(n)),n.push(l)}:function(l,c){var d=Yo.call(n,c),h=d&&u?u(n[c],l,c):l;(!d||h!==n[c])&&(n===t&&(n=sb(n)),n[c]=h)},o=0;o0;)e[u]=arguments[u+1];return hy(this,e,t)}function RT(t){for(var e=[],u=arguments.length-1;u-- >0;)e[u]=arguments[u+1];return es(this,t,vi(),function(s){return py(s,e)})}function xT(t){for(var e=[],u=arguments.length-1;u-- >0;)e[u]=arguments[u+1];return es(this,t,vi(),function(s){return hy(s,e)})}function yy(t){var e=this.asMutable();return t(e),e.wasAltered()?e.__ensureOwner(this.__ownerID):this}function by(){return this.__ownerID?this:this.__ensureOwner(new sT)}function my(){return this.__ensureOwner()}function IT(){return this.__altered}var ts=function(t){function e(u){return u==null?vi():fy(u)&&!Xn(u)?u:vi().withMutations(function(s){var n=t(u);Wn(n.size),n.forEach(function(r,a){return s.set(a,r)})})}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.of=function(){for(var s=[],n=arguments.length;n--;)s[n]=arguments[n];return vi().withMutations(function(r){for(var a=0;a=s.length)throw new Error("Missing value for key: "+s[a]);r.set(s[a],s[a+1])}})},e.prototype.toString=function(){return this.__toString("Map {","}")},e.prototype.get=function(s,n){return this._root?this._root.get(0,void 0,s,n):n},e.prototype.set=function(s,n){return xE(this,s,n)},e.prototype.remove=function(s){return xE(this,s,Ut)},e.prototype.deleteAll=function(s){var n=mr(s);return n.size===0?this:this.withMutations(function(r){n.forEach(function(a){return r.remove(a)})})},e.prototype.clear=function(){return this.size===0?this:this.__ownerID?(this.size=0,this._root=null,this.__hash=void 0,this.__altered=!0,this):vi()},e.prototype.sort=function(s){return Oi(Lo(this,s))},e.prototype.sortBy=function(s,n){return Oi(Lo(this,n,s))},e.prototype.map=function(s,n){var r=this;return this.withMutations(function(a){a.forEach(function(o,l){a.set(l,s.call(n,o,l,r))})})},e.prototype.__iterator=function(s,n){return new K$(this,s,n)},e.prototype.__iterate=function(s,n){var r=this,a=0;return this._root&&this._root.iterate(function(o){return a++,s(o[1],o[0],r)},n),a},e.prototype.__ensureOwner=function(s){return s===this.__ownerID?this:s?PT(this.size,this._root,s,this.__hash):this.size===0?vi():(this.__ownerID=s,this.__altered=!1,this)},e}(ci);ts.isMap=fy;var _r=ts.prototype;_r[dF]=!0;_r[oy]=_r.remove;_r.removeAll=_r.deleteAll;_r.setIn=ST;_r.removeIn=_r.deleteIn=AT;_r.update=ET;_r.updateIn=OT;_r.merge=_r.concat=AF;_r.mergeWith=EF;_r.mergeDeep=DF;_r.mergeDeepWith=NF;_r.mergeIn=RT;_r.mergeDeepIn=xT;_r.withMutations=yy;_r.wasAltered=IT;_r.asImmutable=my;_r["@@transducer/init"]=_r.asMutable=by;_r["@@transducer/step"]=function(t,e){return t.set(e[0],e[1])};_r["@@transducer/result"]=function(t){return t.asImmutable()};var X0=function(e,u){this.ownerID=e,this.entries=u};X0.prototype.get=function(e,u,s,n){for(var r=this.entries,a=0,o=r.length;a=nV)return Y$(e,c,n,r);var p=e&&e===this.ownerID,y=p?c:Qi(c);return f?l?d===h-1?y.pop():y[d]=y.pop():y[d]=[n,r]:y.push([n,r]),p?(this.entries=y,this):new X0(e,y)}};var Mo=function(e,u,s){this.ownerID=e,this.bitmap=u,this.nodes=s};Mo.prototype.get=function(e,u,s,n){u===void 0&&(u=Rn(s));var r=1<<((e===0?u:u>>>e)&xn),a=this.bitmap;return a&r?this.nodes[CF(a&r-1)].get(e+br,u,s,n):n};Mo.prototype.update=function(e,u,s,n,r,a,o){s===void 0&&(s=Rn(n));var l=(u===0?s:s>>>u)&xn,c=1<=iV)return eV(e,p,d,l,b);if(h&&!b&&p.length===2&&IE(p[f^1]))return p[f^1];if(h&&b&&p.length===1&&IE(b))return b;var g=e&&e===this.ownerID,m=h?b?d:d^c:d|c,v=h?b?jF(p,f,b,g):rV(p,f,g):tV(p,f,b,g);return g?(this.bitmap=m,this.nodes=v,this):new Mo(e,m,v)};var K0=function(e,u,s){this.ownerID=e,this.count=u,this.nodes=s};K0.prototype.get=function(e,u,s,n){u===void 0&&(u=Rn(s));var r=(e===0?u:u>>>e)&xn,a=this.nodes[r];return a?a.get(e+br,u,s,n):n};K0.prototype.update=function(e,u,s,n,r,a,o){s===void 0&&(s=Rn(n));var l=(u===0?s:s>>>u)&xn,c=r===Ut,d=this.nodes,h=d[l];if(c&&!h)return this;var f=DT(h,e,u+br,s,n,r,a,o);if(f===h)return this;var p=this.count;if(!h)p++;else if(!f&&(p--,p>>u)&xn,a=(u===0?s:s>>>u)&xn,o,l=r===a?[NT(t,e,u+br,s,n)]:(o=new _a(e,s,n),r>>=1)a[o]=u&1?e[r++]:void 0;return a[s]=n,new K0(t,r+1,a)}function CF(t){return t-=t>>1&1431655765,t=(t&858993459)+(t>>2&858993459),t=t+(t>>4)&252645135,t+=t>>8,t+=t>>16,t&127}function jF(t,e,u,s){var n=s?t:Qi(t);return n[e]=u,n}function tV(t,e,u,s){var n=t.length+1;if(s&&e+1===n)return t[e]=u,t;for(var r=new Array(n),a=0,o=0;o0&&r=0&&s>>u&xn;if(n>=this.array.length)return new Va([],e);var r=n===0,a;if(u>0){var o=this.array[n];if(a=o&&o.removeBefore(e,u-br,s),a===o&&r)return this}if(r&&!a)return this;var l=qo(this,e);if(!r)for(var c=0;c>>u&xn;if(n>=this.array.length)return this;var r;if(u>0){var a=this.array[n];if(r=a&&a.removeAfter(e,u-br,s),r===a&&n===this.array.length-1)return this}var o=qo(this,e);return o.array.splice(n+1),r&&(o.array[n]=r),o};var U0={};function PE(t,e){var u=t._origin,s=t._capacity,n=Z0(s),r=t._tail;return a(t._root,t._level,0);function a(c,d,h){return d===0?o(c,h):l(c,d,h)}function o(c,d){var h=d===n?r&&r.array:c&&c.array,f=d>u?0:u-d,p=s-d;return p>ai&&(p=ai),function(){if(f===p)return U0;var y=e?--p:f++;return h&&h[y]}}function l(c,d,h){var f,p=c&&c.array,y=h>u?0:u-h>>d,b=(s-h>>d)+1;return b>ai&&(b=ai),function(){for(;;){if(f){var g=f();if(g!==U0)return g;f=null}if(y===b)return U0;var m=e?--b:y++;f=a(p&&p[m],d-br,h+(m<=t.size||e<0)return t.withMutations(function(a){e<0?Fa(a,e).set(0,u):Fa(a,0,e+1).set(e,u)});e+=t._origin;var s=t._tail,n=t._root,r=o3();return e>=Z0(t._capacity)?s=h3(s,t.__ownerID,0,e,u,r):n=h3(n,t.__ownerID,t._level,e,u,r),r.value?t.__ownerID?(t._root=n,t._tail=s,t.__hash=void 0,t.__altered=!0,t):Y0(t._origin,t._capacity,t._level,n,s):t}function h3(t,e,u,s,n,r){var a=s>>>u&xn,o=t&&a0){var c=t&&t.array[a],d=h3(c,e,u-br,s,n,r);return d===c?t:(l=qo(t,e),l.array[a]=d,l)}return o&&t.array[a]===n?t:(r&&si(r),l=qo(t,e),n===void 0&&a===l.array.length-1?l.array.pop():l.array[a]=n,l)}function qo(t,e){return e&&t&&e===t.ownerID?t:new Va(t?t.array.slice():[],e)}function MF(t,e){if(e>=Z0(t._capacity))return t._tail;if(e<1<0;)u=u.array[e>>>s&xn],s-=br;return u}}function Fa(t,e,u){e!==void 0&&(e|=0),u!==void 0&&(u|=0);var s=t.__ownerID||new sT,n=t._origin,r=t._capacity,a=n+e,o=u===void 0?r:u<0?r+u:n+u;if(a===n&&o===r)return t;if(a>=o)return t.clear();for(var l=t._level,c=t._root,d=0;a+d<0;)c=new Va(c&&c.array.length?[void 0,c]:[],s),l+=br,d+=1<=1<h?new Va([],s):p;if(p&&f>h&&abr;g-=br){var m=h>>>g&xn;b=b.array[m]=qo(b.array[m],s)}b.array[h>>>br&xn]=p}if(o=f)a-=f,o-=f,l=br,c=null,y=y&&y.removeBefore(s,0,a);else if(a>n||f>>l&xn;if(v!==f>>>l&xn)break;v&&(d+=(1<n&&(c=c.removeBefore(s,l,a-d)),c&&f>>br<=ai&&n.size>=s.size*2?(l=n.filter(function(c,d){return c!==void 0&&r!==d}),o=l.toKeyedSeq().map(function(c){return c[0]}).flip().toMap(),t.__ownerID&&(o.__ownerID=l.__ownerID=t.__ownerID)):(o=s.remove(e),l=r===n.size-1?n.pop():n.set(r,void 0))}else if(a){if(u===n.get(r)[1])return t;o=s,l=n.set(r,[e,u])}else o=s.set(e,n.size),l=n.set(n.size,[e,u]);return t.__ownerID?(t.size=o.size,t._map=o,t._list=l,t.__hash=void 0,t.__altered=!0,t):CT(o,l)}var FF="@@__IMMUTABLE_STACK__@@";function ey(t){return!!(t&&t[FF])}var gy=function(t){function e(u){return u==null?i1():ey(u)?u:i1().pushAll(u)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.of=function(){return this(arguments)},e.prototype.toString=function(){return this.__toString("Stack [","]")},e.prototype.get=function(s,n){var r=this._head;for(s=Wa(this,s);r&&s--;)r=r.next;return r?r.value:n},e.prototype.peek=function(){return this._head&&this._head.value},e.prototype.push=function(){var s=arguments;if(arguments.length===0)return this;for(var n=this.size+arguments.length,r=this._head,a=arguments.length-1;a>=0;a--)r={value:s[a],next:r};return this.__ownerID?(this.size=n,this._head=r,this.__hash=void 0,this.__altered=!0,this):E0(n,r)},e.prototype.pushAll=function(s){if(s=t(s),s.size===0)return this;if(this.size===0&&ey(s))return s;Wn(s.size);var n=this.size,r=this._head;return s.__iterate(function(a){n++,r={value:a,next:r}},!0),this.__ownerID?(this.size=n,this._head=r,this.__hash=void 0,this.__altered=!0,this):E0(n,r)},e.prototype.pop=function(){return this.slice(1)},e.prototype.clear=function(){return this.size===0?this:this.__ownerID?(this.size=0,this._head=void 0,this.__hash=void 0,this.__altered=!0,this):i1()},e.prototype.slice=function(s,n){if(uy(s,n,this.size))return this;var r=Wo(s,this.size),a=cy(n,this.size);if(a!==this.size)return t.prototype.slice.call(this,s,n);for(var o=this.size-r,l=this._head;r--;)l=l.next;return this.__ownerID?(this.size=o,this._head=l,this.__hash=void 0,this.__altered=!0,this):E0(o,l)},e.prototype.__ensureOwner=function(s){return s===this.__ownerID?this:s?E0(this.size,this._head,s,this.__hash):this.size===0?i1():(this.__ownerID=s,this.__altered=!1,this)},e.prototype.__iterate=function(s,n){var r=this;if(n)return new Ws(this.toArray()).__iterate(function(l,c){return s(l,c,r)},n);for(var a=0,o=this._head;o&&s(o.value,a++,this)!==!1;)o=o.next;return a},e.prototype.__iterator=function(s,n){if(n)return new Ws(this.toArray()).__iterator(s,n);var r=0,a=this._head;return new kt(function(){if(a){var o=a.value;return a=a.next,gr(s,r++,o)}return Pn()})},e}(Ys);gy.isStack=ey;var Dn=gy.prototype;Dn[FF]=!0;Dn.shift=Dn.pop;Dn.unshift=Dn.push;Dn.unshiftAll=Dn.pushAll;Dn.withMutations=yy;Dn.wasAltered=IT;Dn.asImmutable=my;Dn["@@transducer/init"]=Dn.asMutable=by;Dn["@@transducer/step"]=function(t,e){return t.unshift(e)};Dn["@@transducer/result"]=function(t){return t.asImmutable()};function E0(t,e,u,s){var n=Object.create(Dn);return n.size=t,n._head=e,n.__ownerID=u,n.__hash=s,n.__altered=!1,n}var jE;function i1(){return jE||(jE=E0(0))}var qF="@@__IMMUTABLE_SET__@@";function _y(t){return!!(t&&t[qF])}function Mb(t){return _y(t)&&Xn(t)}function jT(t,e){if(t===e)return!0;if(!hn(e)||t.size!==void 0&&e.size!==void 0&&t.size!==e.size||t.__hash!==void 0&&e.__hash!==void 0&&t.__hash!==e.__hash||cr(t)!==cr(e)||an(t)!==an(e)||Xn(t)!==Xn(e))return!1;if(t.size===0&&e.size===0)return!0;var u=!Jo(t);if(Xn(t)){var s=t.entries();return e.every(function(l,c){var d=s.next().value;return d&&kr(d[1],l)&&(u||kr(d[0],c))})&&s.next().done}var n=!1;if(t.size===void 0)if(e.size===void 0)typeof t.cacheResult=="function"&&t.cacheResult();else{n=!0;var r=t;t=e,e=r}var a=!0,o=e.__iterate(function(l,c){if(u?!t.has(l):n?!kr(l,t.get(c,Ut)):!kr(t.get(c,Ut),l))return a=!1,!1});return a&&t.size===o}function Zs(t,e){var u=function(s){t.prototype[s]=e[s]};return Object.keys(e).forEach(u),Object.getOwnPropertySymbols&&Object.getOwnPropertySymbols(e).forEach(u),t}function ob(t){if(!t||typeof t!="object")return t;if(!hn(t)){if(!Ja(t))return t;t=pn(t)}if(cr(t)){var e={};return t.__iterate(function(s,n){e[n]=ob(s)}),e}var u=[];return t.__iterate(function(s){u.push(ob(s))}),u}var tu=function(t){function e(u){return u==null?O0():_y(u)&&!Xn(u)?u:O0().withMutations(function(s){var n=t(u);Wn(n.size),n.forEach(function(r){return s.add(r)})})}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.of=function(){return this(arguments)},e.fromKeys=function(s){return this(ci(s).keySeq())},e.intersect=function(s){return s=mr(s).toArray(),s.length?sn.intersect.apply(e(s.pop()),s):O0()},e.union=function(s){return s=mr(s).toArray(),s.length?sn.union.apply(e(s.pop()),s):O0()},e.prototype.toString=function(){return this.__toString("Set {","}")},e.prototype.has=function(s){return this._map.has(s)},e.prototype.add=function(s){return a1(this,this._map.set(s,s))},e.prototype.remove=function(s){return a1(this,this._map.remove(s))},e.prototype.clear=function(){return a1(this,this._map.clear())},e.prototype.map=function(s,n){var r=this,a=!1,o=a1(this,this._map.mapEntries(function(l){var c=l[1],d=s.call(n,c,c,r);return d!==c&&(a=!0),[d,d]},n));return a?o:this},e.prototype.union=function(){for(var s=[],n=arguments.length;n--;)s[n]=arguments[n];return s=s.filter(function(r){return r.size!==0}),s.length===0?this:this.size===0&&!this.__ownerID&&s.length===1?this.constructor(s[0]):this.withMutations(function(r){for(var a=0;a=0&&n=0&&rthis.size?u:this.find(function(s,n){return n===e},void 0,u)},has:function(e){return e=Wa(this,e),e>=0&&(this.size!==void 0?this.size===1/0||ee?-1:0}function lV(t){if(t.size===1/0)return 0;var e=Xn(t),u=cr(t),s=e?1:0,n=t.__iterate(u?e?function(r,a){s=31*s+UE(Rn(r),Rn(a))|0}:function(r,a){s=s+UE(Rn(r),Rn(a))|0}:e?function(r){s=31*s+Rn(r)|0}:function(r){s=s+Rn(r)|0});return dV(n,s)}function dV(t,e){return e=yu(e,3432918353),e=yu(e<<15|e>>>-15,461845907),e=yu(e<<13|e>>>-13,5),e=(e+3864292196|0)^t,e=yu(e^e>>>16,2246822507),e=yu(e^e>>>13,3266489909),e=Pb(e^e>>>16),e}function UE(t,e){return t^e+2654435769+(t<<6)+(t>>2)|0}var Js=function(t){function e(u){return u==null?p3():Mb(u)?u:p3().withMutations(function(s){var n=Xo(u);Wn(n.size),n.forEach(function(r){return s.add(r)})})}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.of=function(){return this(arguments)},e.fromKeys=function(s){return this(ci(s).keySeq())},e.prototype.toString=function(){return this.__toString("OrderedSet {","}")},e}(tu);Js.isOrderedSet=Mb;var eo=Js.prototype;eo[Ko]=!0;eo.zip=ru.zip;eo.zipWith=ru.zipWith;eo.zipAll=ru.zipAll;eo.__empty=p3;eo.__make=HF;function HF(t,e){var u=Object.create(eo);return u.size=t?t.size:0,u._map=t,u.__ownerID=e,u}var QE;function p3(){return QE||(QE=HF(A0()))}var $F={LeftThenRight:-1,RightThenLeft:1};function fV(t){if(Ya(t))throw new Error("Can not call `Record` with an immutable Record as default values. Use a plain javascript object instead.");if(Yn(t))throw new Error("Can not call `Record` with an immutable Collection as default values. Use a plain javascript object instead.");if(t===null||typeof t!="object")throw new Error("Can not call `Record` with a non-object as default values. Use a plain javascript object instead.")}var Ur=function(e,u){var s;fV(e);var n=function(o){var l=this;if(o instanceof n)return o;if(!(this instanceof n))return new n(o);if(!s){s=!0;var c=Object.keys(e),d=r._indices={};r._name=u,r._keys=c,r._defaultValues=e;for(var h=0;h2?[]:void 0,{"":t})}function zF(t,e,u,s,n,r){if(typeof u!="string"&&!Yn(u)&&(uT(u)||oT(u)||Nb(u))){if(~t.indexOf(u))throw new TypeError("Cannot convert circular structure to Immutable");t.push(u),n&&s!==""&&n.push(s);var a=e.call(r,s,pn(u).map(function(o,l){return zF(t,e,o,l,n,u)}),n&&n.slice());return t.pop(),n&&n.pop(),a}return u}function pV(t,e){return an(e)?e.toList():cr(e)?e.toMap():e.toSet()}var GF="4.3.7",yV={version:GF,Collection:mr,Iterable:mr,Seq:pn,Map:ts,OrderedMap:Oi,List:eu,Stack:gy,Set:tu,OrderedSet:Js,PairSorting:$F,Record:Ur,Range:LT,Repeat:VF,is:kr,fromJS:kF,hash:Rn,isImmutable:Yn,isCollection:hn,isKeyed:cr,isIndexed:an,isAssociative:Jo,isOrdered:Xn,isValueObject:ab,isPlainObject:Nb,isSeq:ly,isList:Lb,isMap:fy,isOrderedMap:Ib,isStack:ey,isSet:_y,isOrderedSet:Mb,isRecord:Ya,get:Cb,getIn:Fb,has:gT,hasIn:MT,merge:RF,mergeDeep:IF,mergeWith:xF,mergeDeepWith:PF,remove:_T,removeIn:TT,set:vT,setIn:wT,update:jb,updateIn:es},bV=mr;const mV=Object.freeze(Object.defineProperty({__proto__:null,Collection:mr,Iterable:bV,List:eu,Map:ts,OrderedMap:Oi,OrderedSet:Js,PairSorting:$F,Range:LT,Record:Ur,Repeat:VF,Seq:pn,Set:tu,Stack:gy,default:yV,fromJS:kF,get:Cb,getIn:Fb,has:gT,hasIn:MT,hash:Rn,is:kr,isAssociative:Jo,isCollection:hn,isImmutable:Yn,isIndexed:an,isKeyed:cr,isList:Lb,isMap:fy,isOrdered:Xn,isOrderedMap:Ib,isOrderedSet:Mb,isPlainObject:Nb,isRecord:Ya,isSeq:ly,isSet:_y,isStack:ey,isValueObject:ab,merge:RF,mergeDeep:IF,mergeDeepWith:PF,mergeWith:xF,remove:_T,removeIn:TT,set:vT,setIn:wT,update:jb,updateIn:es,version:GF},Symbol.toStringTag,{value:"Module"})),BT=iT(mV);Object.defineProperty(Gs,"__esModule",{value:!0});Gs.ActionContextKey=Gs.ActionContext=void 0;const HE=BT;class Ao{constructor(e={}){this.map=(0,HE.Map)(e)}setDefault(e,u){return this.has(e)?this:this.set(e,u)}set(e,u){return this.setRaw(e.name,u)}setRaw(e,u){return new Ao(this.map.set(e,u))}delete(e){return new Ao(this.map.delete(e.name))}get(e){return this.getRaw(e.name)}getRaw(e){return this.map.get(e)}getSafe(e){if(!this.has(e))throw new Error(`Context entry ${e.name} is required but not available`);return this.get(e)}has(e){return this.hasRaw(e.name)}hasRaw(e){return this.map.has(e)}merge(...e){let u=this;for(const s of e)for(const n of s.keys())u=u.set(n,s.get(n));return u}keys(){return[...this.map.keys()].map(e=>new WF(e))}toJS(){return this.map.toJS()}toString(){return`ActionContext(${JSON.stringify(this.map.toJS())})`}[Symbol.for("nodejs.util.inspect.custom")](){return`ActionContext(${JSON.stringify(this.map.toJS(),null," ")})`}static ensureActionContext(e){return e instanceof Ao?e:new Ao((0,HE.Map)(e??{}))}}Gs.ActionContext=Ao;class WF{constructor(e){this.name=e}}Gs.ActionContextKey=WF;var wy={};Object.defineProperty(wy,"__esModule",{value:!0});wy.Bus=void 0;class gV{constructor(e){this.actors=[],this.observers=[],this.dependencyLinks=new Map,Object.assign(this,e)}subscribe(e){this.actors.push(e),this.reorderForDependencies()}subscribeObserver(e){this.observers.push(e)}unsubscribe(e){const u=this.actors.indexOf(e);return u>=0?(this.actors.splice(u,1),!0):!1}unsubscribeObserver(e){const u=this.observers.indexOf(e);return u>=0?(this.observers.splice(u,1),!0):!1}publish(e){return this.actors.map(u=>({actor:u,reply:u.test(e)}))}onRun(e,u,s){for(const n of this.observers)n.onRun(e,u,s)}addDependencies(e,u){for(const s of u){let n=this.dependencyLinks.get(s);n||(n=[],this.dependencyLinks.set(s,n)),n.push(e)}this.reorderForDependencies()}reorderForDependencies(){if(this.dependencyLinks.size>0){const e=[];for(const u of this.dependencyLinks.keys()){const s=this.actors.indexOf(u);s>=0&&(this.actors.splice(s,1),e.push(u))}for(;e.length>0;){let u=-1;for(let n=0;n=0&&s.splice(n,1),s.length===0&&delete this.actorsIndex[u]}return super.unsubscribe(e)}publish(e){const u=this.getActionIdentifier(e);return u?[...this.actorsIndex[u]||[],...this.actorsIndex._undefined_||[]].map(n=>({actor:n,reply:n.test(e)})):super.publish(e)}getActorIdentifier(e){return this.actorIdentifierFields.reduce((u,s)=>u[s],e)}getActionIdentifier(e){return this.actionIdentifierFields.reduce((u,s)=>u[s],e)}}qb.BusIndexed=vV;var Sy={};Object.defineProperty(Sy,"__esModule",{value:!0});Sy.CONTEXT_KEY_LOGGER=void 0;const wV=Gs;Sy.CONTEXT_KEY_LOGGER=new wV.ActionContextKey("@comunica/core:log");var Bb={};Object.defineProperty(Bb,"__esModule",{value:!0});Bb.ActionObserver=void 0;class SV{constructor(e){Object.assign(this,e)}}Bb.ActionObserver=SV;var Ub={};Object.defineProperty(Ub,"__esModule",{value:!0});Ub.Actor=void 0;const TV=Sy;class qa{constructor(e){this.beforeActors=[],Object.assign(this,e),this.bus.subscribe(this),this.beforeActors.length>0&&this.bus.addDependencies(this,this.beforeActors)}static getContextLogger(e){return e.get(TV.CONTEXT_KEY_LOGGER)}runObservable(e){const u=this.run(e);return this.bus.onRun(this,e,u),u}async initialize(){return!0}async deinitialize(){return!0}getDefaultLogData(e,u){const s=u?u():{};return s.actor=this.name,s}logTrace(e,u,s){const n=qa.getContextLogger(e);n&&n.trace(u,this.getDefaultLogData(e,s))}logDebug(e,u,s){const n=qa.getContextLogger(e);n&&n.debug(u,this.getDefaultLogData(e,s))}logInfo(e,u,s){const n=qa.getContextLogger(e);n&&n.info(u,this.getDefaultLogData(e,s))}logWarn(e,u,s){const n=qa.getContextLogger(e);n&&n.warn(u,this.getDefaultLogData(e,s))}logError(e,u,s){const n=qa.getContextLogger(e);n&&n.error(u,this.getDefaultLogData(e,s))}logFatal(e,u,s){const n=qa.getContextLogger(e);n&&n.fatal(u,this.getDefaultLogData(e,s))}}Ub.Actor=qa;var Qb={};Object.defineProperty(Qb,"__esModule",{value:!0});Qb.Mediator=void 0;class AV{constructor(e){Object.assign(this,e)}publish(e){const u=this.bus.publish(e);if(u.length===0)throw new Error(`No actors are able to reply to a message in the bus ${this.bus.name}`);return u}async mediateActor(e){return await this.mediateWith(e,this.publish(e))}async mediate(e){return(await this.mediateActor(e)).runObservable(e)}}Qb.Mediator=AV;(function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Gs,t),u(wy,t),u(qb,t),u(Sy,t),u(Bb,t),u(Ub,t),u(Qb,t)})(ot);Object.defineProperty(Ob,"__esModule",{value:!0});Ob.ActorInit=void 0;const EV=ot;class OV extends EV.Actor{constructor(e){super(e)}}Ob.ActorInit=OV;(function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Ob,t)})(eF);Object.defineProperty(sy,"__esModule",{value:!0});sy.ActorInitQueryBase=void 0;const RV=eF;class xV extends RV.ActorInit{async test(e){return!0}async run(e){throw new Error("ActorInitSparql#run is not supported in the browser.")}}sy.ActorInitQueryBase=xV;var Hb={},Hm={exports:{}},$E;function Ta(){if($E)return Hm.exports;$E=1;var t=Hm.exports={},e,u;function s(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?e=setTimeout:e=s}catch{e=s}try{typeof clearTimeout=="function"?u=clearTimeout:u=n}catch{u=n}})();function r(b){if(e===setTimeout)return setTimeout(b,0);if((e===s||!e)&&setTimeout)return e=setTimeout,setTimeout(b,0);try{return e(b,0)}catch{try{return e.call(null,b,0)}catch{return e.call(this,b,0)}}}function a(b){if(u===clearTimeout)return clearTimeout(b);if((u===n||!u)&&clearTimeout)return u=clearTimeout,clearTimeout(b);try{return u(b)}catch{try{return u.call(null,b)}catch{return u.call(this,b)}}}var o=[],l=!1,c,d=-1;function h(){!l||!c||(l=!1,c.length?o=c.concat(o):d=-1,o.length&&f())}function f(){if(!l){var b=r(h);l=!0;for(var g=o.length;g;){for(c=o,o=[];++d1)for(var m=1;m"u"&&(globalThis.process=Ta());class PV extends IV.ActorInitQueryBase{}Hb.ActorInitQuery=PV;var $b={},Lt={},tr={};Object.defineProperty(tr,"__esModule",{value:!0});tr.KeysRdfJoin=tr.KeysMergeBindingsContext=tr.KeysRdfUpdateQuads=tr.KeysQuerySourceIdentify=tr.KeysRdfParseHtmlScript=tr.KeysRdfParseJsonLd=tr.KeysQueryOperation=tr.KeysInitQuery=tr.KeysHttpProxy=tr.KeysHttpMemento=tr.KeysHttpWayback=tr.KeysHttp=tr.KeysCore=void 0;const vt=ot;tr.KeysCore={log:vt.CONTEXT_KEY_LOGGER};tr.KeysHttp={includeCredentials:new vt.ActionContextKey("@comunica/bus-http:include-credentials"),auth:new vt.ActionContextKey("@comunica/bus-http:auth"),fetch:new vt.ActionContextKey("@comunica/bus-http:fetch"),httpTimeout:new vt.ActionContextKey("@comunica/bus-http:http-timeout"),httpBodyTimeout:new vt.ActionContextKey("@comunica/bus-http:http-body-timeout"),httpRetryCount:new vt.ActionContextKey("@comunica/bus-http:http-retry-count"),httpRetryDelay:new vt.ActionContextKey("@comunica/bus-http:http-retry-delay"),httpRetryOnServerError:new vt.ActionContextKey("@comunica/bus-http:http-retry-on-server-error")};tr.KeysHttpWayback={recoverBrokenLinks:new vt.ActionContextKey("@comunica/bus-http:recover-broken-links")};tr.KeysHttpMemento={datetime:new vt.ActionContextKey("@comunica/actor-http-memento:datetime")};tr.KeysHttpProxy={httpProxyHandler:new vt.ActionContextKey("@comunica/actor-http-proxy:httpProxyHandler")};tr.KeysInitQuery={querySourcesUnidentified:new vt.ActionContextKey("@comunica/actor-init-query:querySourcesUnidentified"),initialBindings:new vt.ActionContextKey("@comunica/actor-init-query:initialBindings"),queryFormat:new vt.ActionContextKey("@comunica/actor-init-query:queryFormat"),graphqlSingularizeVariables:new vt.ActionContextKey("@comunica/actor-init-query:singularizeVariables"),lenient:new vt.ActionContextKey("@comunica/actor-init-query:lenient"),queryString:new vt.ActionContextKey("@comunica/actor-init-query:queryString"),query:new vt.ActionContextKey("@comunica/actor-init-query:query"),baseIRI:new vt.ActionContextKey("@comunica/actor-init-query:baseIRI"),functionArgumentsCache:new vt.ActionContextKey("@comunica/actor-init-query:functionArgumentsCache"),queryTimestamp:new vt.ActionContextKey("@comunica/actor-init-query:queryTimestamp"),extensionFunctionCreator:new vt.ActionContextKey("@comunica/actor-init-query:extensionFunctionCreator"),extensionFunctions:new vt.ActionContextKey("@comunica/actor-init-query:extensionFunctions"),cliArgsHandlers:new vt.ActionContextKey("@comunica/actor-init-query:cliArgsHandlers"),explain:new vt.ActionContextKey("@comunica/actor-init-query:explain"),physicalQueryPlanLogger:new vt.ActionContextKey("@comunica/actor-init-query:physicalQueryPlanLogger"),physicalQueryPlanNode:new vt.ActionContextKey("@comunica/actor-init-query:physicalQueryPlanNode"),jsonLdContext:new vt.ActionContextKey("@context"),noCache:new vt.ActionContextKey("@comunica/actor-init-query:noCache"),distinctConstruct:new vt.ActionContextKey("@comunica/actor-init-query:distinctConstruct")};tr.KeysQueryOperation={operation:new vt.ActionContextKey("@comunica/bus-query-operation:operation"),joinLeftMetadata:new vt.ActionContextKey("@comunica/bus-query-operation:joinLeftMetadata"),joinRightMetadatas:new vt.ActionContextKey("@comunica/bus-query-operation:joinRightMetadatas"),joinBindings:new vt.ActionContextKey("@comunica/bus-query-operation:joinBindings"),readOnly:new vt.ActionContextKey("@comunica/bus-query-operation:readOnly"),isPathArbitraryLengthDistinctKey:new vt.ActionContextKey("@comunica/bus-query-operation:isPathArbitraryLengthDistinct"),limitIndicator:new vt.ActionContextKey("@comunica/bus-query-operation:limitIndicator"),unionDefaultGraph:new vt.ActionContextKey("@comunica/bus-query-operation:unionDefaultGraph"),querySources:new vt.ActionContextKey("@comunica/bus-query-operation:querySources")};tr.KeysRdfParseJsonLd={documentLoader:new vt.ActionContextKey("@comunica/actor-rdf-parse-jsonld:documentLoader"),strictValues:new vt.ActionContextKey("@comunica/actor-rdf-parse-jsonld:strictValues"),parserOptions:new vt.ActionContextKey("@comunica/actor-rdf-parse-jsonld:parserOptions")};tr.KeysRdfParseHtmlScript={processingHtmlScript:new vt.ActionContextKey("@comunica/actor-rdf-parse-html-script:processingHtmlScript"),extractAllScripts:new vt.ActionContextKey("extractAllScripts")};tr.KeysQuerySourceIdentify={sourceIds:new vt.ActionContextKey("@comunica/bus-query-source-identify:sourceIds"),hypermediaSourcesAggregatedStores:new vt.ActionContextKey("@comunica/bus-query-source-identify:hypermediaSourcesAggregatedStores"),traverse:new vt.ActionContextKey("@comunica/bus-query-source-identify:traverse")};tr.KeysRdfUpdateQuads={destination:new vt.ActionContextKey("@comunica/bus-rdf-update-quads:destination")};tr.KeysMergeBindingsContext={sourcesBinding:new vt.ActionContextKey("@comunica/bus-merge-bindings-context:sourcesBinding")};tr.KeysRdfJoin={lastPhysicalJoin:new vt.ActionContextKey("@comunica/bus-rdf-join:lastPhysicalJoin")};(function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(tr,t)})(Lt);Object.defineProperty($b,"__esModule",{value:!0});$b.QueryEngineBase=void 0;const DV=Lt,bu=ot;class ub{constructor(e){this.actorInitQuery=e}async queryBindings(e,u){return this.queryOfType(e,u,"bindings")}async queryQuads(e,u){return this.queryOfType(e,u,"quads")}async queryBoolean(e,u){return this.queryOfType(e,u,"boolean")}async queryVoid(e,u){return this.queryOfType(e,u,"void")}async queryOfType(e,u,s){const n=await this.query(e,u);if(n.resultType===s)return await n.execute();throw new Error(`Query result type '${s}' was expected, while '${n.resultType}' was found.`)}async query(e,u){const s=await this.queryOrExplain(e,u);if("explain"in s)throw new Error("Tried to explain a query when in query-only mode");return s}async explain(e,u,s){return u.explain=s,await this.queryOrExplain(e,u)}async queryOrExplain(e,u){const s=bu.ActionContext.ensureActionContext(u);s.get(DV.KeysInitQuery.noCache)&&await this.invalidateHttpCache();const{result:n}=await this.actorInitQuery.mediatorQueryProcess.mediate({query:e,context:s});return"explain"in n?n:ub.internalToFinalResult(n)}async getResultMediaTypes(e){return e=bu.ActionContext.ensureActionContext(e),(await this.actorInitQuery.mediatorQueryResultSerializeMediaTypeCombiner.mediate({context:e,mediaTypes:!0})).mediaTypes}async getResultMediaTypeFormats(e){return e=bu.ActionContext.ensureActionContext(e),(await this.actorInitQuery.mediatorQueryResultSerializeMediaTypeFormatCombiner.mediate({context:e,mediaTypeFormats:!0})).mediaTypeFormats}async resultToString(e,u,s){if(s=bu.ActionContext.ensureActionContext(s),!u)switch(e.resultType){case"bindings":u="application/json";break;case"quads":u="application/trig";break;default:u="simple";break}const n={...await ub.finalToInternalResult(e),context:s};return(await this.actorInitQuery.mediatorQueryResultSerialize.mediate({context:s,handle:n,handleMediaType:u})).handle}invalidateHttpCache(e,u){return u=bu.ActionContext.ensureActionContext(u),this.actorInitQuery.mediatorHttpInvalidate.mediate({url:e,context:u})}static internalToFinalResult(e){switch(e.type){case"bindings":return{resultType:"bindings",execute:async()=>e.bindingsStream,metadata:async()=>await e.metadata(),context:e.context};case"quads":return{resultType:"quads",execute:async()=>e.quadStream,metadata:async()=>await e.metadata(),context:e.context};case"boolean":return{resultType:"boolean",execute:async()=>e.execute(),context:e.context};case"void":return{resultType:"void",execute:async()=>e.execute(),context:e.context}}}static async finalToInternalResult(e){switch(e.resultType){case"bindings":return{type:"bindings",bindingsStream:await e.execute(),metadata:async()=>await e.metadata()};case"quads":return{type:"quads",quadStream:await e.execute(),metadata:async()=>await e.metadata()};case"boolean":return{type:"boolean",execute:()=>e.execute()};case"void":return{type:"void",execute:()=>e.execute()}}}}$b.QueryEngineBase=ub;(function(t){var e=I&&I.__createBinding||(Object.create?function(n,r,a,o){o===void 0&&(o=a);var l=Object.getOwnPropertyDescriptor(r,a);(!l||("get"in l?!r.__esModule:l.writable||l.configurable))&&(l={enumerable:!0,get:function(){return r[a]}}),Object.defineProperty(n,o,l)}:function(n,r,a,o){o===void 0&&(o=a),n[o]=r[a]}),u=I&&I.__exportStar||function(n,r){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(r,a)&&e(r,n,a)};Object.defineProperty(t,"__esModule",{value:!0}),t.QueryEngineBase=void 0,u(sy,t),u(Hb,t);var s=$b;Object.defineProperty(t,"QueryEngineBase",{enumerable:!0,get:function(){return s.QueryEngineBase}})})(aT);var $m={},mu={},Vm={},km={},VE;function NV(){return VE||(VE=1,Object.defineProperty(km,"__esModule",{value:!0})),km}var zm={},kE;function CV(){return kE||(kE=1,Object.defineProperty(zm,"__esModule",{value:!0})),zm}var Gm={},zE;function jV(){return zE||(zE=1,Object.defineProperty(Gm,"__esModule",{value:!0})),Gm}var Wm={},GE;function LV(){return GE||(GE=1,Object.defineProperty(Wm,"__esModule",{value:!0})),Wm}var Jm={},WE;function MV(){return WE||(WE=1,Object.defineProperty(Jm,"__esModule",{value:!0})),Jm}var Xm={},JE;function FV(){return JE||(JE=1,Object.defineProperty(Xm,"__esModule",{value:!0})),Xm}var Km={},XE;function qV(){return XE||(XE=1,Object.defineProperty(Km,"__esModule",{value:!0})),Km}var Ym={},KE;function BV(){return KE||(KE=1,Object.defineProperty(Ym,"__esModule",{value:!0})),Ym}var Zm={},YE;function UV(){return YE||(YE=1,Object.defineProperty(Zm,"__esModule",{value:!0})),Zm}var eg={},ZE;function QV(){return ZE||(ZE=1,Object.defineProperty(eg,"__esModule",{value:!0})),eg}var tg={},eO;function HV(){return eO||(eO=1,Object.defineProperty(tg,"__esModule",{value:!0})),tg}var rg={},tO;function $V(){return tO||(tO=1,Object.defineProperty(rg,"__esModule",{value:!0})),rg}var ng={},rO;function VV(){return rO||(rO=1,Object.defineProperty(ng,"__esModule",{value:!0})),ng}var gu={},nO;function kV(){if(nO)return gu;nO=1,Object.defineProperty(gu,"__esModule",{value:!0}),gu.Logger=void 0;let t=class JF{static getLevelOrdinal(u){return JF.LEVELS[u]}};return gu.Logger=t,t.LEVELS={trace:0,debug:1,info:2,warn:3,error:4,fatal:5},gu}var iO;function zV(){return iO||(iO=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(NV(),t),u(CV(),t),u(jV(),t),u(LV(),t),u(MV(),t),u(FV(),t),u(qV(),t),u(BV(),t),u(UV(),t),u(QV(),t),u(HV(),t),u($V(),t),u(VV(),t),u(kV(),t)}(Vm)),Vm}var aO;function GV(){if(aO)return mu;aO=1,Object.defineProperty(mu,"__esModule",{value:!0}),mu.LoggerVoid=void 0;const t=zV();let e=class extends t.Logger{debug(){}error(){}fatal(){}info(){}trace(){}warn(){}};return mu.LoggerVoid=e,mu}var sO;function WV(){return sO||(sO=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(GV(),t)}($m)),$m}var ig={},_u={},ag={},vu={},oO;function JV(){if(oO)return vu;oO=1,Object.defineProperty(vu,"__esModule",{value:!0}),vu.BlankNodeScoped=void 0;let t=class{constructor(u,s){this.termType="BlankNode",this.value=u,this.skolemized=s}equals(u){return!!u&&u.termType==="BlankNode"&&u.value===this.value}};return vu.BlankNodeScoped=t,vu}var wu={},uO;function XV(){if(uO)return wu;uO=1,Object.defineProperty(wu,"__esModule",{value:!0}),wu.BlankNodeBindingsScoped=void 0;let t=class{constructor(u){this.termType="BlankNode",this.singleBindingsScope=!0,this.value=u}equals(u){return!!u&&u.termType==="BlankNode"&&u.value===this.value}};return wu.BlankNodeBindingsScoped=t,wu}var cO;function UT(){return cO||(cO=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(JV(),t),u(XV(),t)}(ag)),ag}var gs={},sg={},Su={},lO;function XF(){if(lO)return Su;lO=1,Object.defineProperty(Su,"__esModule",{value:!0}),Su.BlankNode=void 0;class t{constructor(u){this.termType="BlankNode",this.value=u}equals(u){return!!u&&u.termType==="BlankNode"&&u.value===this.value}}return Su.BlankNode=t,Su}var Tu={},Au={},dO;function KF(){if(dO)return Au;dO=1,Object.defineProperty(Au,"__esModule",{value:!0}),Au.DefaultGraph=void 0;class t{constructor(){this.termType="DefaultGraph",this.value=""}equals(u){return!!u&&u.termType==="DefaultGraph"}}return Au.DefaultGraph=t,t.INSTANCE=new t,Au}var Eu={},Ou={},fO;function QT(){if(fO)return Ou;fO=1,Object.defineProperty(Ou,"__esModule",{value:!0}),Ou.NamedNode=void 0;class t{constructor(u){this.termType="NamedNode",this.value=u}equals(u){return!!u&&u.termType==="NamedNode"&&u.value===this.value}}return Ou.NamedNode=t,Ou}var hO;function YF(){if(hO)return Eu;hO=1,Object.defineProperty(Eu,"__esModule",{value:!0}),Eu.Literal=void 0;const t=QT();class e{constructor(s,n){this.termType="Literal",this.value=s,typeof n=="string"?(this.language=n,this.datatype=e.RDF_LANGUAGE_STRING):n?(this.language="",this.datatype=n):(this.language="",this.datatype=e.XSD_STRING)}equals(s){return!!s&&s.termType==="Literal"&&s.value===this.value&&s.language===this.language&&this.datatype.equals(s.datatype)}}return Eu.Literal=e,e.RDF_LANGUAGE_STRING=new t.NamedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#langString"),e.XSD_STRING=new t.NamedNode("http://www.w3.org/2001/XMLSchema#string"),Eu}var Ru={},pO;function ZF(){if(pO)return Ru;pO=1,Object.defineProperty(Ru,"__esModule",{value:!0}),Ru.Quad=void 0;class t{constructor(u,s,n,r){this.termType="Quad",this.value="",this.subject=u,this.predicate=s,this.object=n,this.graph=r}equals(u){return!!u&&(u.termType==="Quad"||!u.termType)&&this.subject.equals(u.subject)&&this.predicate.equals(u.predicate)&&this.object.equals(u.object)&&this.graph.equals(u.graph)}}return Ru.Quad=t,Ru}var xu={},yO;function eq(){if(yO)return xu;yO=1,Object.defineProperty(xu,"__esModule",{value:!0}),xu.Variable=void 0;class t{constructor(u){this.termType="Variable",this.value=u}equals(u){return!!u&&u.termType==="Variable"&&u.value===this.value}}return xu.Variable=t,xu}var bO;function KV(){if(bO)return Tu;bO=1,Object.defineProperty(Tu,"__esModule",{value:!0}),Tu.DataFactory=void 0;const t=XF(),e=KF(),u=YF(),s=QT(),n=ZF(),r=eq();let a=0;class o{constructor(c){this.blankNodeCounter=0,c=c||{},this.blankNodePrefix=c.blankNodePrefix||`df_${a++}_`}namedNode(c){return new s.NamedNode(c)}blankNode(c){return new t.BlankNode(c||`${this.blankNodePrefix}${this.blankNodeCounter++}`)}literal(c,d){return new u.Literal(c,d)}variable(c){return new r.Variable(c)}defaultGraph(){return e.DefaultGraph.INSTANCE}quad(c,d,h,f){return new n.Quad(c,d,h,f||this.defaultGraph())}fromTerm(c){switch(c.termType){case"NamedNode":return this.namedNode(c.value);case"BlankNode":return this.blankNode(c.value);case"Literal":return c.language?this.literal(c.value,c.language):c.datatype.equals(u.Literal.XSD_STRING)?this.literal(c.value):this.literal(c.value,this.fromTerm(c.datatype));case"Variable":return this.variable(c.value);case"DefaultGraph":return this.defaultGraph();case"Quad":return this.quad(this.fromTerm(c.subject),this.fromTerm(c.predicate),this.fromTerm(c.object),this.fromTerm(c.graph))}}fromQuad(c){return this.fromTerm(c)}resetBlankNodeCounter(){this.blankNodeCounter=0}}return Tu.DataFactory=o,Tu}var mO;function Et(){return mO||(mO=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(XF(),t),u(KV(),t),u(KF(),t),u(YF(),t),u(QT(),t),u(ZF(),t),u(eq(),t)}(sg)),sg}var og={},en={},gO;function YV(){if(gO)return en;gO=1,Object.defineProperty(en,"__esModule",{value:!0}),en.stringQuadToQuad=en.quadToStringQuad=en.stringToTerm=en.getLiteralLanguage=en.getLiteralType=en.getLiteralValue=en.termToString=void 0;const t=Et(),e=new t.DataFactory;function u(c){if(c)switch(c.termType){case"NamedNode":return c.value;case"BlankNode":return"_:"+c.value;case"Literal":const d=c;return'"'+d.value+'"'+(d.datatype&&d.datatype.value!=="http://www.w3.org/2001/XMLSchema#string"&&d.datatype.value!=="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString"?"^^"+d.datatype.value:"")+(d.language?"@"+d.language:"");case"Quad":return`<<${u(c.subject)} ${u(c.predicate)} ${u(c.object)}${c.graph.termType==="DefaultGraph"?"":" "+u(c.graph)}>>`;case"Variable":return"?"+c.value;case"DefaultGraph":return c.value}}en.termToString=u;function s(c){const d=/^"([^]*)"/.exec(c);if(!d)throw new Error(c+" is not a literal");return d[1]}en.getLiteralValue=s;function n(c){const d=/^"[^]*"(?:\^\^([^"]+)|(@)[^@"]+)?$/.exec(c);if(!d)throw new Error(c+" is not a literal");return d[1]||(d[2]?"http://www.w3.org/1999/02/22-rdf-syntax-ns#langString":"http://www.w3.org/2001/XMLSchema#string")}en.getLiteralType=n;function r(c){const d=/^"[^]*"(?:@([^@"]+)|\^\^[^"]+)?$/.exec(c);if(!d)throw new Error(c+" is not a literal");return d[1]?d[1].toLowerCase():""}en.getLiteralLanguage=r;function a(c,d){if(d=d||e,!c||!c.length)return d.defaultGraph();switch(c[0]){case"_":return d.blankNode(c.substr(2));case"?":if(!d.variable)throw new Error("Missing 'variable()' method on the given DataFactory");return d.variable(c.substr(1));case'"':const h=r(c),f=d.namedNode(n(c));return d.literal(s(c),h||f);case"<":default:if(c[0]==="<"&&c.length>4&&c[1]==="<"&&c[c.length-1]===">"&&c[c.length-2]===">"){const p=c.slice(2,-2).trim();let y=[],b=0,g=0,m=!1;for(let v=0;v"){if(b===0)throw new Error("Found closing tag without opening tag in "+c);b--}if(_==='"'){let w=!1,S=v;for(;S-- >0&&p[S]==="\\";)w=!w;w||(m=!m)}if(_===" "&&!m&&b===0){for(y.push(p.slice(g,v));p[v+1]===" ";)v+=1;g=v+1}}if(b!==0)throw new Error("Found opening tag without closing tag in "+c);if(y.push(p.slice(g,p.length)),y.length!==3&&y.length!==4)throw new Error("Nested quad syntax error "+c);return y=y.map(v=>v.startsWith("<")&&!v.includes(" ")?v.slice(1,-1):v),d.quad(a(y[0]),a(y[1]),a(y[2]),y[3]?a(y[3]):void 0)}return d.namedNode(c)}}en.stringToTerm=a;function o(c){return{subject:u(c.subject),predicate:u(c.predicate),object:u(c.object),graph:u(c.graph)}}en.quadToStringQuad=o;function l(c,d){return d=d||e,d.quad(a(c.subject,d),a(c.predicate,d),a(c.object,d),a(c.graph,d))}return en.stringQuadToQuad=l,en}var _O;function Xt(){return _O||(_O=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.termToString=t.stringToTerm=t.stringQuadToQuad=t.quadToStringQuad=t.getLiteralValue=t.getLiteralType=t.getLiteralLanguage=void 0;const e=YV();Object.defineProperty(t,"getLiteralLanguage",{enumerable:!0,get:function(){return e.getLiteralLanguage}}),Object.defineProperty(t,"getLiteralType",{enumerable:!0,get:function(){return e.getLiteralType}}),Object.defineProperty(t,"getLiteralValue",{enumerable:!0,get:function(){return e.getLiteralValue}}),Object.defineProperty(t,"quadToStringQuad",{enumerable:!0,get:function(){return e.quadToStringQuad}}),Object.defineProperty(t,"stringQuadToQuad",{enumerable:!0,get:function(){return e.stringQuadToQuad}}),Object.defineProperty(t,"stringToTerm",{enumerable:!0,get:function(){return e.stringToTerm}}),Object.defineProperty(t,"termToString",{enumerable:!0,get:function(){return e.termToString}})}(og)),og}var ug={},bt={},vO;function tq(){if(vO)return bt;vO=1,Object.defineProperty(bt,"__esModule",{value:!0}),bt.matchPatternMappings=bt.matchPatternComplete=bt.matchPattern=bt.matchTerm=bt.getValueNestedPath=bt.someTermsNested=bt.someTerms=bt.everyTermsNested=bt.everyTerms=bt.reduceTermsNested=bt.reduceTerms=bt.mapTermsNested=bt.mapTerms=bt.filterQuadTermNamesNested=bt.filterQuadTermNames=bt.filterTermsNested=bt.filterTerms=bt.forEachTermsNested=bt.forEachTerms=bt.collectNamedTerms=bt.getNamedTerms=bt.getTermsNested=bt.getTerms=bt.TRIPLE_TERM_NAMES=bt.QUAD_TERM_NAMES=void 0;const t=Et(),e=new t.DataFactory;bt.QUAD_TERM_NAMES=["subject","predicate","object","graph"],bt.TRIPLE_TERM_NAMES=["subject","predicate","object"];function u(O,E){return E&&O.graph.termType==="DefaultGraph"?[O.subject,O.predicate,O.object]:[O.subject,O.predicate,O.object,O.graph]}bt.getTerms=u;function s(O,E){const P=[];for(const M of u(O,E))M.termType==="Quad"?s(M,E).forEach(U=>P.push(U)):P.push(M);return P}bt.getTermsNested=s;function n(O){return[{key:"subject",value:O.subject},{key:"predicate",value:O.predicate},{key:"object",value:O.object},{key:"graph",value:O.graph}]}bt.getNamedTerms=n;function r(O,E,P){const M={};return O.forEach(U=>M[U.key]=U.value),E&&(M.subject=M.subject||E("subject"),M.predicate=M.predicate||E("predicate"),M.object=M.object||E("object"),M.graph=M.graph||E("graph")),(P||e).quad(M.subject,M.predicate,M.object,M.graph)}bt.collectNamedTerms=r;function a(O,E){E(O.subject,"subject"),E(O.predicate,"predicate"),E(O.object,"object"),E(O.graph,"graph")}bt.forEachTerms=a;function o(O,E,P=[]){O.subject.termType==="Quad"?o(O.subject,E,[...P,"subject"]):E(O.subject,[...P,"subject"]),O.predicate.termType==="Quad"?o(O.predicate,E,[...P,"predicate"]):E(O.predicate,[...P,"predicate"]),O.object.termType==="Quad"?o(O.object,E,[...P,"object"]):E(O.object,[...P,"object"]),O.graph.termType==="Quad"?o(O.graph,E,[...P,"graph"]):E(O.graph,[...P,"graph"])}bt.forEachTermsNested=o;function l(O,E){const P=[];return E(O.subject,"subject")&&P.push(O.subject),E(O.predicate,"predicate")&&P.push(O.predicate),E(O.object,"object")&&P.push(O.object),E(O.graph,"graph")&&P.push(O.graph),P}bt.filterTerms=l;function c(O,E,P=[]){let M=[];return O.subject.termType==="Quad"?M=[...M,...c(O.subject,E,[...P,"subject"])]:E(O.subject,[...P,"subject"])&&M.push(O.subject),O.predicate.termType==="Quad"?M=[...M,...c(O.predicate,E,[...P,"predicate"])]:E(O.predicate,[...P,"predicate"])&&M.push(O.predicate),O.object.termType==="Quad"?M=[...M,...c(O.object,E,[...P,"object"])]:E(O.object,[...P,"object"])&&M.push(O.object),O.graph.termType==="Quad"?M=[...M,...c(O.graph,E,[...P,"graph"])]:E(O.graph,[...P,"graph"])&&M.push(O.graph),M}bt.filterTermsNested=c;function d(O,E){const P=[];return E(O.subject,"subject")&&P.push("subject"),E(O.predicate,"predicate")&&P.push("predicate"),E(O.object,"object")&&P.push("object"),E(O.graph,"graph")&&P.push("graph"),P}bt.filterQuadTermNames=d;function h(O,E,P=[]){let M=[];const U=[...P,"subject"];O.subject.termType==="Quad"?M=[...M,...h(O.subject,E,U)]:E(O.subject,U)&&M.push(U);const j=[...P,"predicate"];O.predicate.termType==="Quad"?M=[...M,...h(O.predicate,E,j)]:E(O.predicate,j)&&M.push(j);const q=[...P,"object"];O.object.termType==="Quad"?M=[...M,...h(O.object,E,q)]:E(O.object,q)&&M.push(q);const $=[...P,"graph"];return O.graph.termType==="Quad"?M=[...M,...h(O.graph,E,$)]:E(O.graph,$)&&M.push($),M}bt.filterQuadTermNamesNested=h;function f(O,E,P){return(P||e).quad(E(O.subject,"subject"),E(O.predicate,"predicate"),E(O.object,"object"),E(O.graph,"graph"))}bt.mapTerms=f;function p(O,E,P,M=[]){return(P||e).quad(O.subject.termType==="Quad"?p(O.subject,E,P,[...M,"subject"]):E(O.subject,[...M,"subject"]),O.predicate.termType==="Quad"?p(O.predicate,E,P,[...M,"predicate"]):E(O.predicate,[...M,"predicate"]),O.object.termType==="Quad"?p(O.object,E,P,[...M,"object"]):E(O.object,[...M,"object"]),O.graph.termType==="Quad"?p(O.graph,E,P,[...M,"graph"]):E(O.graph,[...M,"graph"]))}bt.mapTermsNested=p;function y(O,E,P){let M=P;return M=E(M,O.subject,"subject"),M=E(M,O.predicate,"predicate"),M=E(M,O.object,"object"),E(M,O.graph,"graph")}bt.reduceTerms=y;function b(O,E,P,M=[]){let U=P;return O.subject.termType==="Quad"?U=b(O.subject,E,U,[...M,"subject"]):U=E(U,O.subject,[...M,"subject"]),O.predicate.termType==="Quad"?U=b(O.predicate,E,U,[...M,"predicate"]):U=E(U,O.predicate,[...M,"predicate"]),O.object.termType==="Quad"?U=b(O.object,E,U,[...M,"object"]):U=E(U,O.object,[...M,"object"]),O.graph.termType==="Quad"?U=b(O.graph,E,U,[...M,"graph"]):U=E(U,O.graph,[...M,"graph"]),U}bt.reduceTermsNested=b;function g(O,E){return E(O.subject,"subject")&&E(O.predicate,"predicate")&&E(O.object,"object")&&E(O.graph,"graph")}bt.everyTerms=g;function m(O,E,P=[]){return(O.subject.termType==="Quad"?m(O.subject,E,[...P,"subject"]):E(O.subject,[...P,"subject"]))&&(O.predicate.termType==="Quad"?m(O.predicate,E,[...P,"predicate"]):E(O.predicate,[...P,"predicate"]))&&(O.object.termType==="Quad"?m(O.object,E,[...P,"object"]):E(O.object,[...P,"object"]))&&(O.graph.termType==="Quad"?m(O.graph,E,[...P,"graph"]):E(O.graph,[...P,"graph"]))}bt.everyTermsNested=m;function v(O,E){return E(O.subject,"subject")||E(O.predicate,"predicate")||E(O.object,"object")||E(O.graph,"graph")}bt.someTerms=v;function _(O,E,P=[]){return(O.subject.termType==="Quad"?_(O.subject,E,[...P,"subject"]):E(O.subject,[...P,"subject"]))||(O.predicate.termType==="Quad"?_(O.predicate,E,[...P,"predicate"]):E(O.predicate,[...P,"predicate"]))||(O.object.termType==="Quad"?_(O.object,E,[...P,"object"]):E(O.object,[...P,"object"]))||(O.graph.termType==="Quad"?_(O.graph,E,[...P,"graph"]):E(O.graph,[...P,"graph"]))}bt.someTermsNested=_;function w(O,E){if(E.length===0)return O;if(O.termType==="Quad")return w(O[E[0]],E.slice(1));throw new Error(`Tried to get ${E[0]} from term of type ${O.termType}`)}bt.getValueNestedPath=w;function S(O,E){return!E||E.termType==="Variable"||E.termType==="Quad"&&O.termType==="Quad"&&D(O,E)||E.equals(O)}bt.matchTerm=S;function A(O,E,P,M,U){return S(O.subject,E)&&S(O.predicate,P)&&S(O.object,M)&&S(O.graph,U)}bt.matchPattern=A;function D(O,E){return A(O,E.subject,E.predicate,E.object,E.graph)}bt.matchPatternComplete=D;function L(O,E,P={}){const M={};function U(j,q){return g(j,($,Z)=>{var X,le;const K=q[Z];switch($.termType){case"Variable":return P.skipVarMapping&&K.termType==="Variable"||((le=(X=M[$.value])===null||X===void 0?void 0:X.equals(K))!==null&&le!==void 0?le:(M[$.value]=K,!0));case"Quad":return K.termType==="Quad"&&U($,K);default:return $.equals(K)}})}return U(E,O)&&(P.returnMappings?M:!0)}return bt.matchPatternMappings=L,bt}var Cr={},wO;function ZV(){if(wO)return Cr;wO=1,Object.defineProperty(Cr,"__esModule",{value:!0}),Cr.getQuads=Cr.getDefaultGraphs=Cr.getVariables=Cr.getLiterals=Cr.getBlankNodes=Cr.getNamedNodes=Cr.getTermsOfType=Cr.uniqTerms=Cr.TERM_TYPES=void 0;const t=Xt();Cr.TERM_TYPES=["NamedNode","BlankNode","Literal","Variable","DefaultGraph","Quad"];function e(c){const d={};return c.filter(h=>{const f=(0,t.termToString)(h);return!(f in d)&&(d[f]=!0)})}Cr.uniqTerms=e;function u(c,d){return c.filter(h=>h.termType===d)}Cr.getTermsOfType=u;function s(c){return u(c,"NamedNode")}Cr.getNamedNodes=s;function n(c){return u(c,"BlankNode")}Cr.getBlankNodes=n;function r(c){return u(c,"Literal")}Cr.getLiterals=r;function a(c){return u(c,"Variable")}Cr.getVariables=a;function o(c){return u(c,"DefaultGraph")}Cr.getDefaultGraphs=o;function l(c){return u(c,"Quad")}return Cr.getQuads=l,Cr}var SO;function un(){return SO||(SO=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(tq(),t),u(ZV(),t)}(ug)),ug}var cg={},s1={},lg,TO;function ek(){return TO||(TO=1,lg=function t(e,u){if(e===u)return!0;if(e&&u&&typeof e=="object"&&typeof u=="object"){if(e.constructor!==u.constructor)return!1;var s,n,r;if(Array.isArray(e)){if(s=e.length,s!=u.length)return!1;for(n=s;n--!==0;)if(!t(e[n],u[n]))return!1;return!0}if(e instanceof Map&&u instanceof Map){if(e.size!==u.size)return!1;for(n of e.entries())if(!u.has(n[0]))return!1;for(n of e.entries())if(!t(n[1],u.get(n[0])))return!1;return!0}if(e instanceof Set&&u instanceof Set){if(e.size!==u.size)return!1;for(n of e.entries())if(!u.has(n[0]))return!1;return!0}if(ArrayBuffer.isView(e)&&ArrayBuffer.isView(u)){if(s=e.length,s!=u.length)return!1;for(n=s;n--!==0;)if(e[n]!==u[n])return!1;return!0}if(e.constructor===RegExp)return e.source===u.source&&e.flags===u.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===u.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===u.toString();if(r=Object.keys(e),s=r.length,s!==Object.keys(u).length)return!1;for(n=s;n--!==0;)if(!Object.prototype.hasOwnProperty.call(u,r[n]))return!1;for(n=s;n--!==0;){var a=r[n];if(!t(e[a],u[a]))return!1}return!0}return e!==e&&u!==u}),lg}var dg={},AO;function Ty(){return AO||(AO=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.expressionTypes=t.types=void 0,function(e){e.ALT="alt",e.ASK="ask",e.BGP="bgp",e.CONSTRUCT="construct",e.DESCRIBE="describe",e.DISTINCT="distinct",e.EXPRESSION="expression",e.EXTEND="extend",e.FILTER="filter",e.FROM="from",e.GRAPH="graph",e.GROUP="group",e.INV="inv",e.JOIN="join",e.LEFT_JOIN="leftjoin",e.LINK="link",e.MINUS="minus",e.NOP="nop",e.NPS="nps",e.ONE_OR_MORE_PATH="OneOrMorePath",e.ORDER_BY="orderby",e.PATH="path",e.PATTERN="pattern",e.PROJECT="project",e.REDUCED="reduced",e.SEQ="seq",e.SERVICE="service",e.SLICE="slice",e.UNION="union",e.VALUES="values",e.ZERO_OR_MORE_PATH="ZeroOrMorePath",e.ZERO_OR_ONE_PATH="ZeroOrOnePath",e.COMPOSITE_UPDATE="compositeupdate",e.DELETE_INSERT="deleteinsert",e.LOAD="load",e.CLEAR="clear",e.CREATE="create",e.DROP="drop",e.ADD="add",e.MOVE="move",e.COPY="copy"}(t.types||(t.types={})),function(e){e.AGGREGATE="aggregate",e.EXISTENCE="existence",e.NAMED="named",e.OPERATOR="operator",e.TERM="term",e.WILDCARD="wildcard"}(t.expressionTypes||(t.expressionTypes={}))}(dg)),dg}var o1={},fg={},EO;function rq(){if(EO)return fg;EO=1;let t=class{constructor(){return e||this}equals(s){return s&&this.termType===s.termType}};Object.defineProperty(t.prototype,"value",{enumerable:!0,value:"*"}),Object.defineProperty(t.prototype,"termType",{enumerable:!0,value:"Wildcard"});var e=new t;return fg.Wildcard=t,fg}var hg,OO;function tk(){if(OO)return hg;OO=1;var t=function(){var e=function(Qe,Be,ze,Ze){for(ze=ze||{},Ze=Qe.length;Ze--;ze[Qe[Ze]]=Be);return ze},u=[6,12,13,15,16,24,32,36,41,45,100,110,113,115,116,123,126,131,197,224,229,308,329,330,331,332,333],s=[2,247],n=[100,110,113,115,116,123,126,131,329,330,331,332,333],r=[2,409],a=[1,18],o=[1,27],l=[13,16,45,197,224,229,308],c=[28,29,53],d=[28,53],h=[1,42],f=[1,45],p=[1,41],y=[1,44],b=[123,126],g=[1,67],m=[39,45,87],v=[13,16,45,197,224,308],_=[1,87],w=[2,281],S=[1,86],A=[13,16,45,82,87,89,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312],D=[6,28,29,53,63,70,73,81,83,85],L=[6,13,16,28,29,53,63,70,73,81,83,85,87,308],O=[6,13,16,28,29,45,53,63,70,73,81,82,83,85,87,89,197,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,314],E=[6,13,16,28,29,31,39,45,47,48,53,63,70,73,81,82,83,85,87,89,109,112,121,123,126,128,159,160,161,163,164,174,193,197,224,229,231,232,242,246,250,263,265,272,290,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,314,317,318,335,337,338,340,341,342,343,344,345,346],P=[13,16,308],M=[112,132,327,334],U=[13,16,112,132,308],j=[1,111],q=[1,117],$=[112,132,327,328,334],Z=[13,16,112,132,308,328],X=[28,29,45,53,87],le=[1,138],K=[1,151],he=[1,128],Re=[1,127],ie=[1,129],ae=[1,140],Ee=[1,141],De=[1,142],ge=[1,143],de=[1,144],fe=[1,145],H=[1,147],N=[1,148],R=[2,457],T=[1,158],x=[1,159],B=[1,160],k=[1,152],V=[1,153],J=[1,156],z=[1,171],Y=[1,172],re=[1,173],ce=[1,174],Te=[1,175],xe=[1,176],Le=[1,167],qe=[1,168],G=[1,169],F=[1,170],Q=[1,157],te=[1,166],me=[1,161],Oe=[1,162],Ne=[1,163],We=[1,164],Ve=[1,165],pe=[6,13,16,29,31,45,82,85,87,89,112,159,160,161,163,164,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,335],we=[1,195],W=[6,31,73,81,83,85],Se=[2,285],Ae=[1,199],je=[1,201],He=[6,31,70,73,81,83,85],Ge=[2,283],tt=[1,207],lt=[1,218],ut=[1,223],oe=[1,219],C=[1,225],ee=[1,226],ye=[1,224],Pe=[6,63,70,73,81,83,85],Ue=[1,236],Fe=[2,334],Ye=[1,243],$e=[1,241],Je=[6,193],nt=[2,349],yt=[2,339],ft=[28,128],et=[47,48,193,272],Ir=[47,48,193,242,272],Ke=[47,48,193,242,246,272],be=[47,48,193,242,246,250,263,265,272,290,297,298,299,300,301,302,341,342,343,344,345,346],Ie=[39,47,48,193,242,246,250,263,265,272,290,297,298,299,300,301,302,338,341,342,343,344,345,346],Me=[1,271],it=[1,270],at=[6,13,16,29,31,39,45,47,48,70,73,76,78,81,82,83,85,87,89,112,159,160,161,163,164,193,231,242,246,250,263,265,268,269,270,271,272,273,274,276,277,279,280,283,285,290,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,335,338,341,342,343,344,345,346,347,348,349,350,351],Tt=[1,281],Vt=[1,280],rr=[13,16,29,31,39,45,47,48,82,85,87,89,112,159,160,161,163,164,174,193,197,224,229,231,232,242,246,250,263,265,272,290,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,314,317,318,335,338,341,342,343,344,345,346],fi=[45,89],bn=[13,16,29,31,39,45,47,48,82,85,87,89,112,159,160,161,163,164,174,193,197,224,229,231,232,242,246,250,263,265,272,290,292,293,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,314,317,318,335,338,341,342,343,344,345,346],or=[13,16,31,82,174,294,295,296,297,298,299,300,301,302,303,304,305,306,308,312],Ln=[31,89],Qr=[48,87],Qn=[6,13,16,45,48,82,87,89,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,337,338],Pr=[6,13,16,39,45,48,82,87,89,231,263,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,337,338,340],hi=[1,313],Mr=[6,85],Ni=[6,31,81,83,85],Zi=[2,361],mn=[2,353],Xr=[1,343],ls=[31,112,335],Zn=[13,16,29,31,45,48,82,85,87,89,112,159,160,161,163,164,193,197,224,229,231,232,272,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,317,318,335],ue=[13,16,29,31,45,48,82,85,87,89,112,159,160,161,163,164,193,197,224,229,231,232,272,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,314,317,318,335],ve=[6,109,193],Ce=[31,112],Xe=[13,16,45,82,87,224,263,265,268,269,270,271,273,274,276,277,279,280,283,285,294,295,296,297,298,299,300,301,302,303,304,305,306,308,312,346,347,348,349,350,351],st=[1,390],ht=[1,391],St=[13,16,87,197,308,314],Qt=[13,16,39,45,82,87,224,263,265,268,269,270,271,273,274,276,277,279,280,283,285,294,295,296,297,298,299,300,301,302,303,304,305,306,308,312,346,347,348,349,350,351],Kt=[1,417],lr=[1,418],vr=[13,16,48,197,229,308],zt=[6,31,85],Mn=[6,13,16,31,45,73,81,83,85,268,269,270,271,273,274,276,277,279,280,283,285,308,346,347,348,349,350,351],ei=[6,13,16,29,31,45,73,76,78,81,82,83,85,87,89,112,159,160,161,163,164,231,268,269,270,271,273,274,276,277,279,280,283,285,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,335,346,347,348,349,350,351],Fr=[29,31,85,112,159,160,161,163,164],gn=[1,443],Hn=[1,444],$n=[1,449],ti=[31,112,193,232,318,335],ea=[13,16,45,48,82,87,89,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312],io=[13,16,31,45,48,82,87,89,112,193,231,232,272,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,317,318,335],Yt=[13,16,29,31,45,48,82,85,87,89,112,159,160,161,163,164,193,231,232,272,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,317,318,335],zr=[13,16,31,48,82,174,294,295,296,297,298,299,300,301,302,303,304,305,306,308,312],ri=[31,45],Ea=[1,507],My=[1,508],_A=[6,13,16,29,31,39,45,47,48,63,70,73,76,78,81,82,83,85,87,89,112,159,160,161,163,164,193,231,242,246,250,263,265,268,269,270,271,272,273,274,276,277,279,280,283,285,290,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,335,336,338,341,342,343,344,345,346,347,348,349,350,351],Fy=[29,31,85,112,159,160,161,163,164,335],ds=[6,13,16,31,45,70,73,81,83,85,87,268,269,270,271,273,274,276,277,279,280,283,285,308,346,347,348,349,350,351],vA=[13,16,31,45,48,82,87,89,112,193,197,231,232,272,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,317,318,335],wA=[2,352],fm=[13,16,197,308,314],SA=[1,565],ao=[6,13,16,31,45,76,78,81,83,85,87,268,269,270,271,273,274,276,277,279,280,283,285,308,346,347,348,349,350,351],TA=[13,16,29,31,45,82,85,87,89,112,159,160,161,163,164,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312],ta=[13,16,29,31,45,82,85,87,89,112,159,160,161,163,164,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,335],AA=[13,16,87,308],ra=[2,364],so=[29,31,85,112,159,160,161,163,164,193,232,318,335],qy=[31,112,193,232,272,318,335],na=[2,359],EA=[13,16,48,82,174,294,295,296,297,298,299,300,301,302,303,304,305,306,308,312],By=[29,31,85,112,159,160,161,163,164,193,232,272,318,335],OA=[13,16,31,45,82,87,89,112,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312],RA=[2,347],hm={trace:function(){},yy:{},symbols_:{error:2,QueryOrUpdate:3,Prologue:4,QueryOrUpdate_group0:5,EOF:6,Query:7,Qry:8,Query_option0:9,Prologue_repetition0:10,BaseDecl:11,BASE:12,IRIREF:13,PrefixDecl:14,PREFIX:15,PNAME_NS:16,SelectClauseWildcard:17,Qry_repetition0:18,WhereClause:19,SolutionModifierNoGroup:20,SelectClauseVars:21,Qry_repetition1:22,SolutionModifier:23,CONSTRUCT:24,ConstructTemplate:25,Qry_repetition2:26,Qry_repetition3:27,WHERE:28,"{":29,Qry_option0:30,"}":31,DESCRIBE:32,Qry_group0:33,Qry_repetition4:34,Qry_option1:35,ASK:36,Qry_repetition5:37,SelectClauseBase:38,"*":39,SelectClauseVars_repetition_plus0:40,SELECT:41,SelectClauseBase_option0:42,SelectClauseItem:43,Var:44,"(":45,Expression:46,AS:47,")":48,SubSelect:49,SubSelect_option0:50,SubSelect_option1:51,DatasetClause:52,FROM:53,DatasetClause_option0:54,iri:55,WhereClause_option0:56,GroupGraphPattern:57,SolutionModifier_option0:58,SolutionModifierNoGroup_option0:59,SolutionModifierNoGroup_option1:60,SolutionModifierNoGroup_option2:61,GroupClause:62,GROUP:63,BY:64,GroupClause_repetition_plus0:65,GroupCondition:66,BuiltInCall:67,FunctionCall:68,HavingClause:69,HAVING:70,HavingClause_repetition_plus0:71,OrderClause:72,ORDER:73,OrderClause_repetition_plus0:74,OrderCondition:75,ASC:76,BrackettedExpression:77,DESC:78,Constraint:79,LimitOffsetClauses:80,LIMIT:81,INTEGER:82,OFFSET:83,ValuesClause:84,VALUES:85,InlineData:86,VAR:87,InlineData_repetition0:88,NIL:89,InlineData_repetition1:90,InlineData_repetition_plus2:91,InlineData_repetition3:92,DataBlock:93,DataBlockValueList:94,DataBlockValueList_repetition_plus0:95,Update:96,Update_repetition0:97,Update1:98,Update_option0:99,LOAD:100,Update1_option0:101,Update1_option1:102,Update1_group0:103,Update1_option2:104,GraphRefAll:105,Update1_group1:106,Update1_option3:107,GraphOrDefault:108,TO:109,CREATE:110,Update1_option4:111,GRAPH:112,INSERTDATA:113,QuadPattern:114,DELETEDATA:115,DELETEWHERE:116,Update1_option5:117,InsertDeleteClause:118,Update1_repetition0:119,IntoGraphClause:120,INTO:121,GraphRef:122,DELETE:123,InsertDeleteClause_option0:124,InsertClause:125,INSERT:126,UsingClause:127,USING:128,UsingClause_option0:129,WithClause:130,WITH:131,DEFAULT:132,GraphOrDefault_option0:133,GraphRefAll_group0:134,Quads:135,Quads_option0:136,Quads_repetition0:137,QuadsNotTriples:138,VarOrIri:139,QuadsNotTriples_option0:140,QuadsNotTriples_option1:141,QuadsNotTriples_option2:142,TriplesTemplate:143,TriplesTemplate_repetition0:144,TriplesSameSubject:145,TriplesTemplate_option0:146,GroupGraphPatternSub:147,GroupGraphPatternSub_option0:148,GroupGraphPatternSub_repetition0:149,GroupGraphPatternSubTail:150,GraphPatternNotTriples:151,GroupGraphPatternSubTail_option0:152,GroupGraphPatternSubTail_option1:153,TriplesBlock:154,TriplesBlock_repetition0:155,TriplesSameSubjectPath:156,TriplesBlock_option0:157,GroupOrUnionGraphPattern:158,OPTIONAL:159,MINUS:160,SERVICE:161,GraphPatternNotTriples_option0:162,FILTER:163,BIND:164,InlineDataOneVar:165,InlineDataFull:166,InlineDataOneVar_repetition0:167,InlineDataFull_repetition0:168,InlineDataFull_repetition_plus1:169,InlineDataFull_repetition2:170,DataBlockValue:171,Literal:172,QuotedTriple:173,UNDEF:174,GroupOrUnionGraphPattern_repetition0:175,ArgList:176,ArgList_option0:177,ArgList_repetition0:178,ExpressionList:179,ExpressionList_repetition0:180,ConstructTemplate_option0:181,ConstructTriples:182,ConstructTriples_repetition0:183,ConstructTriples_option0:184,VarOrTermOrQuotedTP:185,PropertyListNotEmpty:186,TriplesNode:187,PropertyList:188,PropertyList_option0:189,VerbObjectList:190,PropertyListNotEmpty_repetition0:191,SemiOptionalVerbObjectList:192,";":193,SemiOptionalVerbObjectList_option0:194,Verb:195,ObjectList:196,a:197,ObjectList_repetition0:198,Object:199,GraphNode:200,Object_option0:201,PropertyListPathNotEmpty:202,TriplesNodePath:203,TriplesSameSubjectPath_option0:204,O:205,PropertyListPathNotEmpty_repetition0:206,PropertyListPathNotEmptyTail:207,O_group0:208,ObjectListPath:209,ObjectListPath_repetition0:210,ObjectPath:211,GraphNodePath:212,ObjectPath_option0:213,Path:214,Path_repetition0:215,PathSequence:216,PathSequence_repetition0:217,PathEltOrInverse:218,PathElt:219,PathPrimary:220,PathElt_option0:221,PathEltOrInverse_option0:222,IriOrA:223,"!":224,PathNegatedPropertySet:225,PathOneInPropertySet:226,PathNegatedPropertySet_repetition0:227,PathNegatedPropertySet_option0:228,"^":229,TriplesNode_repetition_plus0:230,"[":231,"]":232,TriplesNodePath_repetition_plus0:233,VarOrTermOrQuotedTPExpr:234,VarOrTerm:235,GraphTerm:236,BlankNode:237,ConditionalOrExpression:238,ConditionalAndExpression:239,ConditionalOrExpression_repetition0:240,ConditionalOrExpressionTail:241,"||":242,RelationalExpression:243,ConditionalAndExpression_repetition0:244,ConditionalAndExpressionTail:245,"&&":246,NumericExpression:247,RelationalExpression_group0:248,RelationalExpression_option0:249,IN:250,MultiplicativeExpression:251,NumericExpression_repetition0:252,AdditiveExpressionTail:253,AdditiveExpressionTail_group0:254,NumericLiteralPositive:255,AdditiveExpressionTail_repetition0:256,NumericLiteralNegative:257,AdditiveExpressionTail_repetition1:258,UnaryExpression:259,MultiplicativeExpression_repetition0:260,MultiplicativeExpressionTail:261,MultiplicativeExpressionTail_group0:262,"+":263,PrimaryExpression:264,"-":265,ExprQuotedTP:266,Aggregate:267,FUNC_ARITY0:268,FUNC_ARITY1:269,FUNC_ARITY1_SPARQL_STAR:270,FUNC_ARITY2:271,",":272,FUNC_ARITY3:273,FUNC_ARITY3_SPARQL_STAR:274,BuiltInCall_group0:275,BOUND:276,BNODE:277,BuiltInCall_option0:278,EXISTS:279,COUNT:280,Aggregate_option0:281,Aggregate_group0:282,FUNC_AGGREGATE:283,Aggregate_option1:284,GROUP_CONCAT:285,Aggregate_option2:286,Aggregate_option3:287,GroupConcatSeparator:288,SEPARATOR:289,"=":290,String:291,LANGTAG:292,"^^":293,DECIMAL:294,DOUBLE:295,BOOLEAN:296,INTEGER_POSITIVE:297,DECIMAL_POSITIVE:298,DOUBLE_POSITIVE:299,INTEGER_NEGATIVE:300,DECIMAL_NEGATIVE:301,DOUBLE_NEGATIVE:302,STRING_LITERAL1:303,STRING_LITERAL2:304,STRING_LITERAL_LONG1:305,STRING_LITERAL_LONG2:306,PrefixedName:307,PNAME_LN:308,BLANK_NODE_LABEL:309,ANON:310,QuotedTP:311,"<<":312,qtSubjectOrObject:313,">>":314,DataValueTerm:315,AnnotationPattern:316,"{|":317,"|}":318,AnnotationPatternPath:319,ExprVarOrTerm:320,QueryOrUpdate_group0_option0:321,Prologue_repetition0_group0:322,Qry_group0_repetition_plus0:323,SelectClauseBase_option0_group0:324,DISTINCT:325,REDUCED:326,NAMED:327,SILENT:328,CLEAR:329,DROP:330,ADD:331,MOVE:332,COPY:333,ALL:334,".":335,UNION:336,"|":337,"/":338,PathElt_option0_group0:339,"?":340,"!=":341,"<":342,">":343,"<=":344,">=":345,NOT:346,CONCAT:347,COALESCE:348,SUBSTR:349,REGEX:350,REPLACE:351,$accept:0,$end:1},terminals_:{2:"error",6:"EOF",12:"BASE",13:"IRIREF",15:"PREFIX",16:"PNAME_NS",24:"CONSTRUCT",28:"WHERE",29:"{",31:"}",32:"DESCRIBE",36:"ASK",39:"*",41:"SELECT",45:"(",47:"AS",48:")",53:"FROM",63:"GROUP",64:"BY",70:"HAVING",73:"ORDER",76:"ASC",78:"DESC",81:"LIMIT",82:"INTEGER",83:"OFFSET",85:"VALUES",87:"VAR",89:"NIL",100:"LOAD",109:"TO",110:"CREATE",112:"GRAPH",113:"INSERTDATA",115:"DELETEDATA",116:"DELETEWHERE",121:"INTO",123:"DELETE",126:"INSERT",128:"USING",131:"WITH",132:"DEFAULT",159:"OPTIONAL",160:"MINUS",161:"SERVICE",163:"FILTER",164:"BIND",174:"UNDEF",193:";",197:"a",224:"!",229:"^",231:"[",232:"]",242:"||",246:"&&",250:"IN",263:"+",265:"-",268:"FUNC_ARITY0",269:"FUNC_ARITY1",270:"FUNC_ARITY1_SPARQL_STAR",271:"FUNC_ARITY2",272:",",273:"FUNC_ARITY3",274:"FUNC_ARITY3_SPARQL_STAR",276:"BOUND",277:"BNODE",279:"EXISTS",280:"COUNT",283:"FUNC_AGGREGATE",285:"GROUP_CONCAT",289:"SEPARATOR",290:"=",292:"LANGTAG",293:"^^",294:"DECIMAL",295:"DOUBLE",296:"BOOLEAN",297:"INTEGER_POSITIVE",298:"DECIMAL_POSITIVE",299:"DOUBLE_POSITIVE",300:"INTEGER_NEGATIVE",301:"DECIMAL_NEGATIVE",302:"DOUBLE_NEGATIVE",303:"STRING_LITERAL1",304:"STRING_LITERAL2",305:"STRING_LITERAL_LONG1",306:"STRING_LITERAL_LONG2",308:"PNAME_LN",309:"BLANK_NODE_LABEL",310:"ANON",312:"<<",314:">>",317:"{|",318:"|}",325:"DISTINCT",326:"REDUCED",327:"NAMED",328:"SILENT",329:"CLEAR",330:"DROP",331:"ADD",332:"MOVE",333:"COPY",334:"ALL",335:".",336:"UNION",337:"|",338:"/",340:"?",341:"!=",342:"<",343:">",344:"<=",345:">=",346:"NOT",347:"CONCAT",348:"COALESCE",349:"SUBSTR",350:"REGEX",351:"REPLACE"},productions_:[0,[3,3],[7,2],[4,1],[11,2],[14,3],[8,4],[8,4],[8,5],[8,7],[8,5],[8,4],[17,2],[21,2],[38,2],[43,1],[43,5],[49,4],[49,4],[52,3],[19,2],[23,2],[20,3],[62,3],[66,1],[66,1],[66,3],[66,5],[66,1],[69,2],[72,3],[75,2],[75,2],[75,1],[75,1],[80,2],[80,2],[80,4],[80,4],[84,2],[86,4],[86,4],[86,6],[86,2],[94,3],[96,3],[98,4],[98,3],[98,5],[98,4],[98,2],[98,2],[98,2],[98,5],[120,2],[118,3],[118,1],[125,2],[127,3],[130,2],[108,1],[108,2],[122,2],[105,1],[105,1],[114,3],[135,2],[138,7],[143,3],[57,3],[57,3],[147,2],[150,3],[154,3],[151,1],[151,2],[151,2],[151,3],[151,4],[151,2],[151,6],[151,1],[93,1],[93,1],[165,4],[166,4],[166,6],[171,1],[171,1],[171,1],[171,1],[158,2],[79,1],[79,1],[79,1],[68,2],[176,1],[176,5],[179,1],[179,4],[25,3],[182,3],[145,2],[145,2],[188,1],[186,2],[192,2],[190,2],[195,1],[195,1],[196,2],[199,2],[156,2],[156,2],[202,2],[207,1],[207,2],[205,2],[209,2],[211,2],[214,2],[216,2],[219,2],[218,2],[220,1],[220,2],[220,3],[225,1],[225,1],[225,4],[226,1],[226,2],[187,3],[187,3],[203,3],[203,3],[200,1],[200,1],[212,1],[212,1],[234,1],[235,1],[235,1],[139,1],[139,1],[44,1],[236,1],[236,1],[236,1],[236,1],[46,1],[238,2],[241,2],[239,2],[245,2],[243,1],[243,3],[243,4],[247,2],[253,2],[253,2],[253,2],[251,2],[261,2],[259,2],[259,2],[259,2],[259,1],[264,1],[264,1],[264,1],[264,1],[264,1],[264,1],[264,1],[77,3],[67,1],[67,2],[67,4],[67,4],[67,6],[67,8],[67,8],[67,2],[67,4],[67,2],[67,4],[67,3],[267,5],[267,5],[267,6],[288,4],[172,1],[172,2],[172,3],[172,1],[172,1],[172,1],[172,1],[172,1],[172,1],[255,1],[255,1],[255,1],[257,1],[257,1],[257,1],[291,1],[291,1],[291,1],[291,1],[55,1],[55,1],[307,1],[307,1],[237,1],[237,1],[311,5],[173,5],[313,1],[313,1],[313,1],[313,1],[313,1],[315,1],[315,1],[315,1],[185,1],[185,1],[185,1],[316,3],[319,3],[266,5],[320,1],[320,1],[320,1],[223,1],[223,1],[321,0],[321,1],[5,1],[5,1],[5,1],[9,0],[9,1],[322,1],[322,1],[10,0],[10,2],[18,0],[18,2],[22,0],[22,2],[26,0],[26,2],[27,0],[27,2],[30,0],[30,1],[323,1],[323,2],[33,1],[33,1],[34,0],[34,2],[35,0],[35,1],[37,0],[37,2],[40,1],[40,2],[324,1],[324,1],[42,0],[42,1],[50,0],[50,1],[51,0],[51,1],[54,0],[54,1],[56,0],[56,1],[58,0],[58,1],[59,0],[59,1],[60,0],[60,1],[61,0],[61,1],[65,1],[65,2],[71,1],[71,2],[74,1],[74,2],[88,0],[88,2],[90,0],[90,2],[91,1],[91,2],[92,0],[92,2],[95,1],[95,2],[97,0],[97,4],[99,0],[99,2],[101,0],[101,1],[102,0],[102,1],[103,1],[103,1],[104,0],[104,1],[106,1],[106,1],[106,1],[107,0],[107,1],[111,0],[111,1],[117,0],[117,1],[119,0],[119,2],[124,0],[124,1],[129,0],[129,1],[133,0],[133,1],[134,1],[134,1],[134,1],[136,0],[136,1],[137,0],[137,2],[140,0],[140,1],[141,0],[141,1],[142,0],[142,1],[144,0],[144,3],[146,0],[146,1],[148,0],[148,1],[149,0],[149,2],[152,0],[152,1],[153,0],[153,1],[155,0],[155,3],[157,0],[157,1],[162,0],[162,1],[167,0],[167,2],[168,0],[168,2],[169,1],[169,2],[170,0],[170,2],[175,0],[175,3],[177,0],[177,1],[178,0],[178,3],[180,0],[180,3],[181,0],[181,1],[183,0],[183,3],[184,0],[184,1],[189,0],[189,1],[191,0],[191,2],[194,0],[194,1],[198,0],[198,3],[201,0],[201,1],[204,0],[204,1],[206,0],[206,2],[208,1],[208,1],[210,0],[210,3],[213,0],[213,1],[215,0],[215,3],[217,0],[217,3],[339,1],[339,1],[339,1],[221,0],[221,1],[222,0],[222,1],[227,0],[227,3],[228,0],[228,1],[230,1],[230,2],[233,1],[233,2],[240,0],[240,2],[244,0],[244,2],[248,1],[248,1],[248,1],[248,1],[248,1],[248,1],[249,0],[249,1],[252,0],[252,2],[254,1],[254,1],[256,0],[256,2],[258,0],[258,2],[260,0],[260,2],[262,1],[262,1],[275,1],[275,1],[275,1],[275,1],[275,1],[278,0],[278,1],[281,0],[281,1],[282,1],[282,1],[284,0],[284,1],[286,0],[286,1],[287,0],[287,1]],performAction:function(Be,ze,Ze,pt,gt,ne,Vn){var se=ne.length-1;switch(gt){case 1:if(ne[se-1]=ne[se-1]||{},Ct.base&&(ne[se-1].base=Ct.base),Ct.base="",ne[se-1].prefixes=Ct.prefixes,Ct.prefixes=null,Ct.pathOnly){if(ne[se-1].type==="path"||"termType"in ne[se-1])return ne[se-1];throw new Error("Received full SPARQL query in path only mode")}else if(ne[se-1].type==="path"||"termType"in ne[se-1])throw new Error("Received only path in full SPARQL mode");if(ne[se-1].type==="update"){const Nt={};for(const Jt of ne[se-1].updates)if(Jt.updateType==="insert"){const It={};for(const Yr of Jt.insert)if(Yr.type==="bgp"||Yr.type==="graph")for(const Zr of Yr.triples)Zr.subject.termType==="BlankNode"&&(It[Zr.subject.value]=!0),Zr.predicate.termType==="BlankNode"&&(It[Zr.predicate.value]=!0),Zr.object.termType==="BlankNode"&&(It[Zr.object.value]=!0);for(const Yr of Object.keys(It)){if(Nt[Yr])throw new Error("Detected reuse blank node across different INSERT DATA clauses");Nt[Yr]=!0}}}return ne[se-1];case 2:this.$={...ne[se-1],...ne[se],type:"query"};break;case 4:Ct.base=du(ne[se]);break;case 5:Ct.prefixes||(Ct.prefixes={}),ne[se-1]=ne[se-1].substr(0,ne[se-1].length-1),ne[se]=du(ne[se]),Ct.prefixes[ne[se-1]]=ne[se];break;case 6:this.$={...ne[se-3],...ps(ne[se-2]),...ne[se-1],...ne[se]};break;case 7:if(!Ct.skipValidation&&(wm(ne[se-3].variables.map(Jt=>vm(Jt.expression))).some(Jt=>Jt.aggregation==="count"&&!(Jt.expression instanceof Uy))||ne[se].group)){for(const Jt of ne[se-3].variables)if(Jt.termType==="Variable"){if(!ne[se].group||!ne[se].group.map(It=>fo(It)).includes(fo(Jt)))throw Error("Projection of ungrouped variable (?"+fo(Jt)+")")}else if(vm(Jt.expression).length===0){const It=lU(Jt.expression);for(const Yr of It)if(!ne[se].group||!ne[se].group.map||!ne[se].group.map(Zr=>fo(Zr)).includes(fo(Yr)))throw Error("Use of ungrouped variable in projection of operation (?"+fo(Yr)+")")}}const ho=ne[se-1].where.filter(Nt=>Nt.type==="query");if(ho.length>0){const Nt=ne[se-3].variables.filter(It=>It.variable&&It.variable.value).map(It=>It.variable.value),Jt=wm(ho.map(It=>It.variables)).map(It=>It.value||It.variable.value);for(const It of Nt)if(Jt.indexOf(It)>=0)throw Error("Target id of 'AS' (?"+It+") already used in subquery")}this.$=Dr(ne[se-3],ps(ne[se-2]),ne[se-1],ne[se]);break;case 8:this.$=Dr({queryType:"CONSTRUCT",template:ne[se-3]},ps(ne[se-2]),ne[se-1],ne[se]);break;case 9:this.$=Dr({queryType:"CONSTRUCT",template:ne[se-2]=ne[se-2]?ne[se-2].triples:[]},ps(ne[se-5]),{where:[{type:"bgp",triples:oo([],ne[se-2])}]},ne[se]);break;case 10:this.$=Dr({queryType:"DESCRIBE",variables:ne[se-3]==="*"?[new Uy]:ne[se-3]},ps(ne[se-2]),ne[se-1],ne[se]);break;case 11:this.$=Dr({queryType:"ASK"},ps(ne[se-2]),ne[se-1],ne[se]);break;case 12:this.$=Dr(ne[se-1],{variables:[new Uy]});break;case 13:const Em=ne[se].map(Nt=>Nt.value||Nt.variable.value),zy=dU(Em);if(zy.length>0)throw Error("Two or more of the resulting columns have the same name (?"+zy[0]+")");this.$=Dr(ne[se-1],{variables:ne[se]});break;case 14:this.$=Dr({queryType:"SELECT"},ne[se]&&(ne[se-1]=_n(ne[se]),ne[se]={},ne[se][ne[se-1]]=!0,ne[se]));break;case 16:case 27:this.$=uo(ne[se-3],{variable:ne[se-1]});break;case 17:case 18:this.$=Dr(ne[se-3],ne[se-2],ne[se-1],ne[se],{type:"query"});break;case 19:case 58:this.$={iri:ne[se],named:!!ne[se-1]};break;case 20:this.$={where:ne[se].patterns};break;case 21:this.$=Dr(ne[se-1],ne[se]);break;case 22:this.$=Dr(ne[se-2],ne[se-1],ne[se]);break;case 23:this.$={group:ne[se]};break;case 24:case 25:case 28:case 31:case 33:case 34:this.$=uo(ne[se]);break;case 26:this.$=uo(ne[se-1]);break;case 29:this.$={having:ne[se]};break;case 30:this.$={order:ne[se]};break;case 32:this.$=uo(ne[se],{descending:!0});break;case 35:this.$={limit:lo(ne[se])};break;case 36:this.$={offset:lo(ne[se])};break;case 37:this.$={limit:lo(ne[se-2]),offset:lo(ne[se])};break;case 38:this.$={limit:lo(ne[se]),offset:lo(ne[se-2])};break;case 39:case 43:this.$={type:"values",values:ne[se]};break;case 40:case 84:this.$=ne[se-1].map(Nt=>({[ne[se-3]]:Nt}));break;case 41:case 85:this.$=ne[se-1].map(()=>({}));break;case 42:case 86:var Oa=ne[se-4].length;ne[se-4]=ne[se-4].map(pm),this.$=ne[se-1].map(function(Nt){if(Nt.length!==Oa)throw Error("Inconsistent VALUES length");for(var Jt={},It=0;ItJt.type==="bind")){const Jt=ne[se-1].indexOf(Nt),It=new Set;for(const Yr of ne[se-1].slice(0,Jt))(Yr.type==="group"||Yr.type==="bgp")&&MA(Yr).forEach(Zr=>It.add(Zr));if(It.has(Nt.variable.value))throw Error("Variable used to bind is already bound (?"+Nt.variable.value+")")}this.$={type:"group",patterns:ne[se-1]};break;case 71:this.$=ne[se-1]?Ci([ne[se-1]],ne[se]):Ci(ne[se]);break;case 72:this.$=ne[se]?[ne[se-2],ne[se]]:ne[se-2];break;case 75:this.$=Dr(ne[se],{type:"optional"});break;case 76:this.$=Dr(ne[se],{type:"minus"});break;case 77:this.$=Dr(ne[se],{type:"graph",name:ne[se-1]});break;case 78:this.$=Dr(ne[se],{type:"service",name:ne[se-1],silent:!!ne[se-2]});break;case 79:this.$={type:"filter",expression:ne[se]};break;case 80:this.$={type:"bind",variable:ne[se-1],expression:ne[se-3]};break;case 89:this.$=hu(ne[se]);break;case 90:this.$=void 0;break;case 91:this.$=ne[se-1].length?{type:"union",patterns:Ci(ne[se-1].map(bm),[bm(ne[se])])}:ne[se];break;case 95:this.$={...ne[se],function:ne[se-1]};break;case 96:this.$={type:"functionCall",args:[]};break;case 97:this.$={type:"functionCall",args:hs(ne[se-2],ne[se-1]),distinct:!!ne[se-3]};break;case 98:case 115:case 128:case 247:case 249:case 251:case 253:case 255:case 263:case 267:case 297:case 299:case 303:case 307:case 328:case 341:case 349:case 355:case 361:case 367:case 369:case 373:case 375:case 379:case 381:case 385:case 391:case 395:case 401:case 405:case 409:case 411:case 420:case 428:case 430:case 440:case 444:case 446:case 448:this.$=[];break;case 99:this.$=hs(ne[se-2],ne[se-1]);break;case 101:this.$=Ci(ne[se-2],[ne[se-1]]);break;case 102:case 112:this.$=Tm(ne[se].map(Nt=>Dr(ia(ne[se-1]),Nt)));break;case 103:this.$=Tm(oo(ne[se].map(Nt=>Dr(ia(ne[se-1].entity),Nt)),ne[se-1].triples));break;case 105:this.$=Ci([ne[se-1]],ne[se]);break;case 106:this.$=Ci(ne[se]);break;case 107:this.$=_m(ne[se-1],ne[se]);break;case 109:case 237:this.$=Ct.factory.namedNode(eU);break;case 110:case 118:this.$=hs(ne[se-1],ne[se]);break;case 111:this.$=ne[se]?{annotation:ne[se],object:ne[se-1]}:ne[se-1];break;case 113:this.$=ne[se]?Tm(oo(ne[se].map(Nt=>Dr(ia(ne[se-1].entity),Nt)),ne[se-1].triples)):ne[se-1].triples;break;case 114:this.$=_m(...ne[se-1],ne[se]);break;case 116:this.$=_m(...ne[se]);break;case 117:case 159:case 163:this.$=[ne[se-1],ne[se]];break;case 119:this.$=ne[se]?{object:ne[se-1],annotation:ne[se]}:ne[se-1];break;case 120:this.$=ne[se-1].length?co("|",hs(ne[se-1],ne[se])):ne[se];break;case 121:this.$=ne[se-1].length?co("/",hs(ne[se-1],ne[se])):ne[se];break;case 122:this.$=ne[se]?co(ne[se],[ne[se-1]]):ne[se-1];break;case 123:this.$=ne[se-1]?co(ne[se-1],[ne[se]]):ne[se];break;case 125:case 131:this.$=co(ne[se-1],[ne[se]]);break;case 129:this.$=co("|",hs(ne[se-2],ne[se-1]));break;case 132:case 134:this.$=uU(ne[se-1]);break;case 133:case 135:this.$=cU(ne[se-1]);break;case 140:this.$={entity:ne[se],triples:[]};break;case 145:this.$=pm(ne[se]);break;case 149:this.$=Ct.factory.namedNode(xA);break;case 151:case 153:case 158:case 162:this.$=ym(ne[se-1],ne[se]);break;case 152:this.$=["||",ne[se]];break;case 154:this.$=["&&",ne[se]];break;case 156:this.$=Kr(ne[se-1],[ne[se-2],ne[se]]);break;case 157:this.$=Kr(ne[se-2]?"notin":"in",[ne[se-3],ne[se]]);break;case 160:this.$=["+",ym(ne[se-1],ne[se])];break;case 161:var Vy=ji(ne[se-1].value.replace("-",""),ne[se-1].datatype);this.$=["-",ym(Vy,ne[se])];break;case 164:this.$=Kr("UPLUS",[ne[se]]);break;case 165:this.$=Kr(ne[se-1],[ne[se]]);break;case 166:this.$=Kr("UMINUS",[ne[se]]);break;case 177:this.$=Kr(_n(ne[se-1]));break;case 178:this.$=Kr(_n(ne[se-3]),[ne[se-1]]);break;case 179:this.$=hu(Kr(_n(ne[se-3]),[ne[se-1]]));break;case 180:this.$=Kr(_n(ne[se-5]),[ne[se-3],ne[se-1]]);break;case 181:this.$=Kr(_n(ne[se-7]),[ne[se-5],ne[se-3],ne[se-1]]);break;case 182:this.$=hu(Kr(_n(ne[se-7]),[ne[se-5],ne[se-3],ne[se-1]]));break;case 183:this.$=Kr(_n(ne[se-1]),ne[se]);break;case 184:this.$=Kr("bound",[pm(ne[se-1])]);break;case 185:this.$=Kr(ne[se-1],[]);break;case 186:this.$=Kr(ne[se-3],[ne[se-1]]);break;case 187:this.$=Kr(ne[se-2]?"notexists":"exists",[bm(ne[se])]);break;case 188:case 189:this.$=uo(ne[se-1],{type:"aggregate",aggregation:_n(ne[se-4]),distinct:!!ne[se-2]});break;case 190:this.$=uo(ne[se-2],{type:"aggregate",aggregation:_n(ne[se-5]),distinct:!!ne[se-3],separator:typeof ne[se-1]=="string"?ne[se-1]:" "});break;case 192:this.$=ji(ne[se]);break;case 193:this.$=iU(ne[se-1],_n(ne[se].substr(1)));break;case 194:this.$=ji(ne[se-2],ne[se]);break;case 195:case 204:this.$=ji(ne[se],IA);break;case 196:case 205:this.$=ji(ne[se],PA);break;case 197:case 206:this.$=ji(_n(ne[se]),DA);break;case 200:this.$=ji(ne[se].toLowerCase(),nU);break;case 201:this.$=ji(ne[se].substr(1),IA);break;case 202:this.$=ji(ne[se].substr(1),PA);break;case 203:this.$=ji(ne[se].substr(1).toLowerCase(),DA);break;case 207:case 208:this.$=LA(ne[se],1);break;case 209:case 210:this.$=LA(ne[se],3);break;case 211:this.$=Ct.factory.namedNode(du(ne[se]));break;case 213:var ky=ne[se].indexOf(":"),Nr=ne[se].substr(0,ky),Li=Ct.prefixes[Nr];if(!Li)throw new Error("Unknown prefix: "+Nr);var ys=du(Li+ne[se].substr(ky+1));this.$=Ct.factory.namedNode(ys);break;case 214:if(ne[se]=ne[se].substr(0,ne[se].length-1),!(ne[se]in Ct.prefixes))throw new Error("Unknown prefix: "+ne[se]);var ys=du(Ct.prefixes[ne[se]]);this.$=Ct.factory.namedNode(ys);break;case 215:this.$=fu(ne[se].replace(/^(_:)/,""));break;case 216:this.$=fu();break;case 217:case 218:case 232:this.$=hu(mm(ne[se-3],ne[se-2],ne[se-1]));break;case 230:case 231:this.$=hu(ne[se-1]);break;case 248:case 250:case 252:case 254:case 256:case 260:case 264:case 268:case 270:case 292:case 294:case 296:case 298:case 300:case 302:case 304:case 306:case 329:case 342:case 356:case 368:case 370:case 372:case 374:case 392:case 402:case 425:case 427:case 429:case 431:case 441:case 445:case 447:case 449:ne[se-1].push(ne[se]);break;case 259:case 269:case 291:case 293:case 295:case 301:case 305:case 371:case 424:case 426:this.$=[ne[se]];break;case 308:ne[se-3].push(ne[se-2]);break;case 350:case 362:case 376:case 380:case 382:case 386:case 396:case 406:case 410:case 412:case 421:ne[se-2].push(ne[se-1]);break}},table:[e(u,s,{3:1,4:2,10:3}),{1:[3]},e(n,[2,307],{5:4,7:5,321:6,214:7,8:8,96:9,215:10,17:11,21:12,97:16,38:17,6:[2,238],13:r,16:r,45:r,197:r,224:r,229:r,308:r,24:[1,13],32:[1,14],36:[1,15],41:a}),e([6,13,16,24,32,36,41,45,100,110,113,115,116,123,126,131,197,224,229,308,329,330,331,332,333],[2,3],{322:19,11:20,14:21,12:[1,22],15:[1,23]}),{6:[1,24]},{6:[2,240]},{6:[2,241]},{6:[2,242]},{6:[2,243],9:25,84:26,85:o},{6:[2,239]},e(l,[2,411],{216:28,217:29}),e(c,[2,249],{18:30}),e(c,[2,251],{22:31}),e(d,[2,255],{25:32,27:33,29:[1,34]}),{13:h,16:f,33:35,39:[1,37],44:39,55:40,87:p,139:38,307:43,308:y,323:36},e(c,[2,267],{37:46}),e(b,[2,326],{98:47,103:49,106:50,117:55,130:61,100:[1,48],110:[1,51],113:[1,52],115:[1,53],116:[1,54],131:[1,62],329:[1,56],330:[1,57],331:[1,58],332:[1,59],333:[1,60]}),{39:[1,63],40:64,43:65,44:66,45:g,87:p},e(m,[2,273],{42:68,324:69,325:[1,70],326:[1,71]}),e(u,[2,248]),e(u,[2,245]),e(u,[2,246]),{13:[1,72]},{16:[1,73]},{1:[2,1]},{6:[2,2]},{6:[2,244]},{45:[1,77],85:[1,78],86:74,87:[1,75],89:[1,76]},e([6,13,16,45,48,82,87,89,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312],[2,120],{337:[1,79]}),e(v,[2,418],{218:80,222:81,229:[1,82]}),{19:83,28:_,29:w,52:84,53:S,56:85},{19:88,28:_,29:w,52:89,53:S,56:85},e(c,[2,253],{26:90}),{28:[1,91],52:92,53:S},e(A,[2,385],{181:93,182:94,183:95,31:[2,383]}),e(D,[2,263],{34:96}),e(D,[2,261],{44:39,55:40,307:43,139:97,13:h,16:f,87:p,308:y}),e(D,[2,262]),e(L,[2,259]),e(O,[2,143]),e(O,[2,144]),e([6,13,16,28,29,31,39,45,47,48,53,63,70,73,76,78,81,82,83,85,87,89,112,159,160,161,163,164,193,197,224,229,231,232,242,246,250,263,265,268,269,270,271,272,273,274,276,277,279,280,283,285,290,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,314,317,318,335,338,341,342,343,344,345,346,347,348,349,350,351],[2,145]),e(E,[2,211]),e(E,[2,212]),e(E,[2,213]),e(E,[2,214]),{19:98,28:_,29:w,52:99,53:S,56:85},{6:[2,309],99:100,193:[1,101]},e(P,[2,311],{101:102,328:[1,103]}),e(M,[2,317],{104:104,328:[1,105]}),e(U,[2,322],{107:106,328:[1,107]}),{111:108,112:[2,324],328:[1,109]},{29:j,114:110},{29:j,114:112},{29:j,114:113},{118:114,123:[1,115],125:116,126:q},e($,[2,315]),e($,[2,316]),e(Z,[2,319]),e(Z,[2,320]),e(Z,[2,321]),e(b,[2,327]),{13:h,16:f,55:118,307:43,308:y},e(c,[2,12]),e(c,[2,13],{44:66,43:119,45:g,87:p}),e(X,[2,269]),e(X,[2,15]),{13:h,16:f,44:136,45:le,46:120,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(m,[2,14]),e(m,[2,274]),e(m,[2,271]),e(m,[2,272]),e(u,[2,4]),{13:[1,177]},e(pe,[2,39]),{29:[1,178]},{29:[1,179]},{87:[1,181],91:180},{45:[1,187],87:[1,185],89:[1,186],93:182,165:183,166:184},e(l,[2,410]),e([6,13,16,45,48,82,87,89,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,337],[2,121],{338:[1,188]}),{13:h,16:f,45:[1,193],55:194,197:we,219:189,220:190,223:191,224:[1,192],307:43,308:y},e(v,[2,419]),e(W,Se,{20:196,59:197,69:198,70:Ae}),e(c,[2,250]),{29:je,57:200},e(P,[2,279],{54:202,327:[1,203]}),{29:[2,282]},e(He,Ge,{23:204,58:205,62:206,63:tt}),e(c,[2,252]),{19:208,28:_,29:w,52:209,53:S,56:85},{29:[1,210]},e(d,[2,256]),{31:[1,211]},{31:[2,384]},{13:h,16:f,44:215,45:lt,55:220,82:K,87:p,89:ut,145:212,172:221,185:213,187:214,231:oe,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:ye},e(Pe,[2,265],{56:85,35:227,52:228,19:229,28:_,29:w,53:S}),e(L,[2,260]),e(He,Ge,{58:205,62:206,23:230,63:tt}),e(c,[2,268]),{6:[2,45]},e(u,s,{10:3,4:231}),{13:h,16:f,55:232,307:43,308:y},e(P,[2,312]),{105:233,112:Ue,122:234,132:[1,237],134:235,327:[1,238],334:[1,239]},e(M,[2,318]),e(P,Fe,{108:240,133:242,112:Ye,132:$e}),e(U,[2,323]),{112:[1,244]},{112:[2,325]},e(Je,[2,50]),e(A,nt,{135:245,136:246,143:247,144:248,31:yt,112:yt}),e(Je,[2,51]),e(Je,[2,52]),e(ft,[2,328],{119:249}),{29:j,114:250},e(ft,[2,56]),{29:j,114:251},e(b,[2,59]),e(X,[2,270]),{47:[1,252]},e(et,[2,150]),e(Ir,[2,428],{240:253}),e(Ke,[2,430],{244:254}),e(Ke,[2,155],{248:255,249:256,250:[2,438],290:[1,257],341:[1,258],342:[1,259],343:[1,260],344:[1,261],345:[1,262],346:[1,263]}),e(be,[2,440],{252:264}),e(Ie,[2,448],{260:265}),{13:h,16:f,44:136,45:le,55:133,67:132,68:134,77:131,82:K,87:p,172:135,255:154,257:155,264:266,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},{13:h,16:f,44:136,45:le,55:133,67:132,68:134,77:131,82:K,87:p,172:135,255:154,257:155,264:267,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},{13:h,16:f,44:136,45:le,55:133,67:132,68:134,77:131,82:K,87:p,172:135,255:154,257:155,264:268,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(Ie,[2,167]),e(Ie,[2,168]),e(Ie,[2,169]),e(Ie,[2,170],{176:269,45:Me,89:it}),e(Ie,[2,171]),e(Ie,[2,172]),e(Ie,[2,173]),e(Ie,[2,174]),{13:h,16:f,44:136,45:le,46:272,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(at,[2,176]),{89:[1,273]},{45:[1,274]},{45:[1,275]},{45:[1,276]},{45:[1,277]},{45:[1,278]},{45:Tt,89:Vt,179:279},{45:[1,282]},{45:[1,284],89:[1,283]},{279:[1,285]},e(rr,[2,192],{292:[1,286],293:[1,287]}),e(rr,[2,195]),e(rr,[2,196]),e(rr,[2,197]),e(rr,[2,198]),e(rr,[2,199]),e(rr,[2,200]),{13:h,16:f,44:39,55:40,82:K,87:p,139:289,172:291,255:154,257:155,266:290,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,320:288},{45:[1,292]},{45:[1,293]},{45:[1,294]},e(fi,[2,452]),e(fi,[2,453]),e(fi,[2,454]),e(fi,[2,455]),e(fi,[2,456]),{279:[2,458]},e(bn,[2,207]),e(bn,[2,208]),e(bn,[2,209]),e(bn,[2,210]),e(rr,[2,201]),e(rr,[2,202]),e(rr,[2,203]),e(rr,[2,204]),e(rr,[2,205]),e(rr,[2,206]),e(u,[2,5]),e(or,[2,297],{88:295}),e(Ln,[2,299],{90:296}),{48:[1,297],87:[1,298]},e(Qr,[2,301]),e(pe,[2,43]),e(pe,[2,82]),e(pe,[2,83]),{29:[1,299]},{29:[1,300]},{87:[1,302],169:301},e(l,[2,412]),e(Qn,[2,123]),e(Qn,[2,416],{221:303,339:304,39:[1,306],263:[1,307],340:[1,305]}),e(Pr,[2,124]),{13:h,16:f,45:[1,311],55:194,89:[1,310],197:we,223:312,225:308,226:309,229:hi,307:43,308:y},e(l,r,{215:10,214:314}),e(Pr,[2,236]),e(Pr,[2,237]),e(Mr,[2,6]),e(Ni,[2,287],{60:315,72:316,73:[1,317]}),e(W,[2,286]),{13:h,16:f,45:le,55:323,67:321,68:322,71:318,77:320,79:319,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,307:43,308:y,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e([6,31,63,70,73,81,83,85],[2,20]),e(A,Zi,{38:17,49:324,147:325,17:326,21:327,148:328,154:329,155:330,29:mn,31:mn,85:mn,112:mn,159:mn,160:mn,161:mn,163:mn,164:mn,41:a}),{13:h,16:f,55:331,307:43,308:y},e(P,[2,280]),e(Mr,[2,7]),e(W,Se,{59:197,69:198,20:332,70:Ae}),e(He,[2,284]),{64:[1,333]},e(He,Ge,{58:205,62:206,23:334,63:tt}),e(c,[2,254]),e(A,nt,{144:248,30:335,143:336,31:[2,257]}),e(c,[2,100]),{31:[2,387],184:337,335:[1,338]},{13:h,16:f,44:39,55:40,87:p,139:342,186:339,190:340,195:341,197:Xr,307:43,308:y},e(ls,[2,389],{44:39,55:40,307:43,190:340,195:341,139:342,188:344,189:345,186:346,13:h,16:f,87:p,197:Xr,308:y}),e(Zn,[2,227]),e(Zn,[2,228]),e(Zn,[2,229]),{13:h,16:f,44:215,45:lt,55:220,82:K,87:p,89:ut,172:221,185:351,187:350,200:348,230:347,231:oe,234:349,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:ye},{13:h,16:f,44:39,55:40,87:p,139:342,186:352,190:340,195:341,197:Xr,307:43,308:y},e(Zn,[2,146]),e(Zn,[2,147]),e(Zn,[2,148]),e(Zn,[2,149]),{13:h,16:f,44:354,55:355,82:K,87:p,172:357,237:356,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:358,312:ye,313:353},e(ue,[2,215]),e(ue,[2,216]),e(He,Ge,{58:205,62:206,23:359,63:tt}),e(D,[2,264]),e(Pe,[2,266]),e(Mr,[2,11]),e(n,[2,308],{6:[2,310]}),e(Je,[2,313],{102:360,120:361,121:[1,362]}),e(Je,[2,47]),e(Je,[2,63]),e(Je,[2,64]),{13:h,16:f,55:363,307:43,308:y},e(Je,[2,336]),e(Je,[2,337]),e(Je,[2,338]),{109:[1,364]},e(ve,[2,60]),{13:h,16:f,55:365,307:43,308:y},e(P,[2,335]),{13:h,16:f,55:366,307:43,308:y},{31:[1,367]},e(Ce,[2,341],{137:368}),e(Ce,[2,340]),{13:h,16:f,44:215,45:lt,55:220,82:K,87:p,89:ut,145:369,172:221,185:213,187:214,231:oe,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:ye},{28:[1,370],127:371,128:[1,372]},e(ft,[2,330],{124:373,125:374,126:q}),e(ft,[2,57]),{44:375,87:p},e(et,[2,151],{241:376,242:[1,377]}),e(Ir,[2,153],{245:378,246:[1,379]}),{13:h,16:f,44:136,45:le,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,247:380,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},{250:[1,381]},e(Xe,[2,432]),e(Xe,[2,433]),e(Xe,[2,434]),e(Xe,[2,435]),e(Xe,[2,436]),e(Xe,[2,437]),{250:[2,439]},e([47,48,193,242,246,250,272,290,341,342,343,344,345,346],[2,158],{253:382,254:383,255:384,257:385,263:[1,386],265:[1,387],297:z,298:Y,299:re,300:ce,301:Te,302:xe}),e(be,[2,162],{261:388,262:389,39:st,338:ht}),e(Ie,[2,164]),e(Ie,[2,165]),e(Ie,[2,166]),e(at,[2,95]),e(at,[2,96]),e(Xe,[2,377],{177:392,325:[1,393]}),{48:[1,394]},e(at,[2,177]),{13:h,16:f,44:136,45:le,46:395,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},{13:h,16:f,44:136,45:le,46:396,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},{13:h,16:f,44:136,45:le,46:397,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},{13:h,16:f,44:136,45:le,46:398,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},{13:h,16:f,44:136,45:le,46:399,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(at,[2,183]),e(at,[2,98]),e(Xe,[2,381],{180:400}),{87:[1,401]},e(at,[2,185]),{13:h,16:f,44:136,45:le,46:402,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},{29:je,57:403},e(rr,[2,193]),{13:h,16:f,55:404,307:43,308:y},{13:h,16:f,44:39,55:40,87:p,139:342,195:405,197:Xr,307:43,308:y},e(St,[2,233]),e(St,[2,234]),e(St,[2,235]),e(Qt,[2,459],{281:406,325:[1,407]}),e(Xe,[2,463],{284:408,325:[1,409]}),e(Xe,[2,465],{286:410,325:[1,411]}),{13:h,16:f,31:[1,412],55:414,82:K,171:413,172:415,173:416,174:Kt,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:lr},{31:[1,419],89:[1,420]},{29:[1,421]},e(Qr,[2,302]),e(or,[2,367],{167:422}),e(Ln,[2,369],{168:423}),{48:[1,424],87:[1,425]},e(Qr,[2,371]),e(Qn,[2,122]),e(Qn,[2,417]),e(Qn,[2,413]),e(Qn,[2,414]),e(Qn,[2,415]),e(Pr,[2,125]),e(Pr,[2,127]),e(Pr,[2,128]),e(vr,[2,420],{227:426}),e(Pr,[2,130]),{13:h,16:f,55:194,197:we,223:427,307:43,308:y},{48:[1,428]},e(zt,[2,289],{61:429,80:430,81:[1,431],83:[1,432]}),e(Ni,[2,288]),{64:[1,433]},e(W,[2,29],{307:43,267:139,275:146,278:149,77:320,67:321,68:322,55:323,79:434,13:h,16:f,45:le,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,276:H,277:N,279:R,280:T,283:x,285:B,308:y,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve}),e(Mn,[2,293]),e(ei,[2,92]),e(ei,[2,93]),e(ei,[2,94]),{45:Me,89:it,176:269},{31:[1,435]},{31:[1,436]},{19:437,28:_,29:w,56:85},{19:438,28:_,29:w,56:85},e(Fr,[2,355],{149:439}),e(Fr,[2,354]),{13:h,16:f,44:215,45:gn,55:220,82:K,87:p,89:ut,156:440,172:221,185:441,203:442,231:Hn,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:ye},e(D,[2,19]),e(zt,[2,21]),{13:h,16:f,44:450,45:$n,55:323,65:445,66:446,67:447,68:448,87:p,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,307:43,308:y,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(Mr,[2,8]),{31:[1,451]},{31:[2,258]},{31:[2,101]},e(A,[2,386],{31:[2,388]}),e(ls,[2,102]),e(ti,[2,391],{191:452}),e(A,[2,395],{196:453,198:454}),e(A,[2,108]),e(A,[2,109]),e(ls,[2,103]),e(ls,[2,104]),e(ls,[2,390]),{13:h,16:f,44:215,45:lt,48:[1,455],55:220,82:K,87:p,89:ut,172:221,185:351,187:350,200:456,231:oe,234:349,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:ye},e(ea,[2,424]),e(io,[2,136]),e(io,[2,137]),e(Yt,[2,140]),{232:[1,457]},{13:h,16:f,44:39,55:40,87:p,139:342,195:458,197:Xr,307:43,308:y},e(St,[2,219]),e(St,[2,220]),e(St,[2,221]),e(St,[2,222]),e(St,[2,223]),e(Mr,[2,10]),e(Je,[2,46]),e(Je,[2,314]),{112:Ue,122:459},e(Je,[2,62]),e(P,Fe,{133:242,108:460,112:Ye,132:$e}),e(ve,[2,61]),e(Je,[2,49]),e([6,28,126,128,193],[2,65]),{31:[2,66],112:[1,462],138:461},e(Ce,[2,351],{146:463,335:[1,464]}),{29:je,57:465},e(ft,[2,329]),e(P,[2,332],{129:466,327:[1,467]}),e(ft,[2,55]),e(ft,[2,331]),{48:[1,468]},e(Ir,[2,429]),{13:h,16:f,44:136,45:le,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,239:469,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(Ke,[2,431]),{13:h,16:f,44:136,45:le,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,243:470,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(Ke,[2,156]),{45:Tt,89:Vt,179:471},e(be,[2,441]),{13:h,16:f,44:136,45:le,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,251:472,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(Ie,[2,444],{256:473}),e(Ie,[2,446],{258:474}),e(Xe,[2,442]),e(Xe,[2,443]),e(Ie,[2,449]),{13:h,16:f,44:136,45:le,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,255:154,257:155,259:475,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(Xe,[2,450]),e(Xe,[2,451]),e(Xe,[2,379],{178:476}),e(Xe,[2,378]),e([6,13,16,29,31,39,45,47,48,73,76,78,81,82,83,85,87,89,112,159,160,161,163,164,193,231,242,246,250,263,265,268,269,270,271,272,273,274,276,277,279,280,283,285,290,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,335,338,341,342,343,344,345,346,347,348,349,350,351],[2,175]),{48:[1,477]},{48:[1,478]},{272:[1,479]},{272:[1,480]},{272:[1,481]},{13:h,16:f,44:136,45:le,46:482,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},{48:[1,483]},{48:[1,484]},e(at,[2,187]),e(rr,[2,194]),{13:h,16:f,44:39,55:40,82:K,87:p,139:289,172:291,255:154,257:155,266:290,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,320:485},{13:h,16:f,39:[1,487],44:136,45:le,46:488,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,282:486,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(Qt,[2,460]),{13:h,16:f,44:136,45:le,46:489,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(Xe,[2,464]),{13:h,16:f,44:136,45:le,46:490,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(Xe,[2,466]),e(pe,[2,40]),e(or,[2,298]),e(zr,[2,87]),e(zr,[2,88]),e(zr,[2,89]),e(zr,[2,90]),{13:h,16:f,55:492,82:K,172:493,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,311:494,312:ye,315:491},e(pe,[2,41]),e(Ln,[2,300]),e(ri,[2,303],{92:495}),{13:h,16:f,31:[1,496],55:414,82:K,171:497,172:415,173:416,174:Kt,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:lr},{31:[1,498],89:[1,499]},{29:[1,500]},e(Qr,[2,372]),{13:h,16:f,48:[2,422],55:194,197:we,223:312,226:502,228:501,229:hi,307:43,308:y},e(Pr,[2,131]),e(Pr,[2,126]),e(zt,[2,22]),e(zt,[2,290]),{82:[1,503]},{82:[1,504]},{13:h,16:f,44:510,45:le,55:323,67:321,68:322,74:505,75:506,76:Ea,77:320,78:My,79:509,87:p,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,307:43,308:y,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(Mn,[2,294]),e(_A,[2,69]),e(_A,[2,70]),e(W,Se,{59:197,69:198,20:511,70:Ae}),e(He,Ge,{58:205,62:206,23:512,63:tt}),{29:[2,375],31:[2,71],84:522,85:o,112:[1,518],150:513,151:514,158:515,159:[1,516],160:[1,517],161:[1,519],163:[1,520],164:[1,521],175:523},e(Fr,[2,363],{157:524,335:[1,525]}),e(l,r,{215:10,202:526,205:527,208:528,214:529,44:530,87:p}),e(Fy,[2,399],{215:10,205:527,208:528,214:529,44:530,204:531,202:532,13:r,16:r,45:r,197:r,224:r,229:r,308:r,87:p}),{13:h,16:f,44:215,45:gn,55:220,82:K,87:p,89:ut,172:221,185:351,203:536,212:534,231:Hn,233:533,234:535,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:ye},e(l,r,{215:10,205:527,208:528,214:529,44:530,202:537,87:p}),e(He,[2,23],{307:43,267:139,275:146,278:149,55:323,67:447,68:448,44:450,66:538,13:h,16:f,45:$n,87:p,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,276:H,277:N,279:R,280:T,283:x,285:B,308:y,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve}),e(ds,[2,291]),e(ds,[2,24]),e(ds,[2,25]),{13:h,16:f,44:136,45:le,46:539,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(ds,[2,28]),e(He,Ge,{58:205,62:206,23:540,63:tt}),e([31,112,232,318,335],[2,105],{192:541,193:[1,542]}),e(ti,[2,107]),{13:h,16:f,44:215,45:lt,55:220,82:K,87:p,89:ut,172:221,185:351,187:350,199:543,200:544,231:oe,234:349,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:ye},e(vA,[2,132]),e(ea,[2,425]),e(vA,[2,133]),{13:h,16:f,44:354,55:355,82:K,87:p,172:357,237:356,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:358,312:ye,313:545},e(Je,[2,54]),e(Je,[2,48]),e(Ce,[2,342]),{13:h,16:f,44:39,55:40,87:p,139:546,307:43,308:y},e(Ce,[2,68]),e(A,[2,350],{31:wA,112:wA}),e(Je,[2,53]),{13:h,16:f,55:547,307:43,308:y},e(P,[2,333]),e(X,[2,16]),e(Ir,[2,152]),e(Ke,[2,154]),e(Ke,[2,157]),e(be,[2,159]),e(be,[2,160],{262:389,261:548,39:st,338:ht}),e(be,[2,161],{262:389,261:549,39:st,338:ht}),e(Ie,[2,163]),{13:h,16:f,44:136,45:le,46:550,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(at,[2,178]),e(at,[2,179]),{13:h,16:f,44:136,45:le,46:551,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},{13:h,16:f,44:136,45:le,46:552,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},{13:h,16:f,44:136,45:le,46:553,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},{48:[1,554],272:[1,555]},e(at,[2,184]),e(at,[2,186]),{314:[1,556]},{48:[1,557]},{48:[2,461]},{48:[2,462]},{48:[1,558]},{48:[2,467],193:[1,561],287:559,288:560},{13:h,16:f,55:194,197:we,223:562,307:43,308:y},e(fm,[2,224]),e(fm,[2,225]),e(fm,[2,226]),{31:[1,563],45:SA,94:564},e(pe,[2,84]),e(or,[2,368]),e(pe,[2,85]),e(Ln,[2,370]),e(ri,[2,373],{170:566}),{48:[1,567]},{48:[2,423],337:[1,568]},e(zt,[2,35],{83:[1,569]}),e(zt,[2,36],{81:[1,570]}),e(Ni,[2,30],{307:43,267:139,275:146,278:149,77:320,67:321,68:322,55:323,79:509,44:510,75:571,13:h,16:f,45:le,76:Ea,78:My,87:p,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,276:H,277:N,279:R,280:T,283:x,285:B,308:y,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve}),e(ao,[2,295]),{45:le,77:572},{45:le,77:573},e(ao,[2,33]),e(ao,[2,34]),{31:[2,275],50:574,84:575,85:o},{31:[2,277],51:576,84:577,85:o},e(Fr,[2,356]),e(TA,[2,357],{152:578,335:[1,579]}),e(ta,[2,74]),{29:je,57:580},{29:je,57:581},{13:h,16:f,44:39,55:40,87:p,139:582,307:43,308:y},e(AA,[2,365],{162:583,328:[1,584]}),{13:h,16:f,45:le,55:323,67:321,68:322,77:320,79:585,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,307:43,308:y,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},{45:[1,586]},e(ta,[2,81]),{29:je,57:587},e(Fr,[2,73]),e(A,[2,362],{29:ra,31:ra,85:ra,112:ra,159:ra,160:ra,161:ra,163:ra,164:ra}),e(Fy,[2,112]),e(so,[2,401],{206:588}),e(A,[2,405],{209:589,210:590}),e(A,[2,403]),e(A,[2,404]),e(Fy,[2,113]),e(Fy,[2,400]),{13:h,16:f,44:215,45:gn,48:[1,591],55:220,82:K,87:p,89:ut,172:221,185:351,203:536,212:592,231:Hn,234:535,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:ye},e(ea,[2,426]),e(Yt,[2,138]),e(Yt,[2,139]),{232:[1,593]},e(ds,[2,292]),{47:[1,595],48:[1,594]},e(Mr,[2,9]),e(ti,[2,392]),e(ti,[2,393],{44:39,55:40,307:43,195:341,139:342,194:596,190:597,13:h,16:f,87:p,197:Xr,308:y}),e(ti,[2,110],{272:[1,598]}),e(qy,[2,397],{201:599,316:600,317:[1,601]}),{314:[1,602]},{29:[1,603]},e(ft,[2,58]),e(Ie,[2,445]),e(Ie,[2,447]),{48:[1,604],272:[1,605]},{48:[1,606]},{272:[1,607]},{272:[1,608]},e(at,[2,99]),e(Xe,[2,382]),e([13,16,39,47,48,87,193,197,242,246,250,263,265,272,290,297,298,299,300,301,302,308,314,338,341,342,343,344,345,346],[2,232]),e(at,[2,188]),e(at,[2,189]),{48:[1,609]},{48:[2,468]},{289:[1,610]},{13:h,16:f,55:492,82:K,172:493,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,311:494,312:ye,315:611},e(pe,[2,42]),e(ri,[2,304]),{13:h,16:f,55:414,82:K,95:612,171:613,172:415,173:416,174:Kt,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:lr},{31:[1,614],45:SA,94:615},e(Pr,[2,129]),e(vr,[2,421]),{82:[1,616]},{82:[1,617]},e(ao,[2,296]),e(ao,[2,31]),e(ao,[2,32]),{31:[2,17]},{31:[2,276]},{31:[2,18]},{31:[2,278]},e(A,Zi,{155:330,153:618,154:619,29:na,31:na,85:na,112:na,159:na,160:na,161:na,163:na,164:na}),e(TA,[2,358]),e(ta,[2,75]),e(ta,[2,76]),{29:je,57:620},{13:h,16:f,44:39,55:40,87:p,139:621,307:43,308:y},e(AA,[2,366]),e(ta,[2,79]),{13:h,16:f,44:136,45:le,46:622,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(ta,[2,91],{336:[1,623]}),e([29,31,85,112,159,160,161,163,164,232,318,335],[2,114],{207:624,193:[1,625]}),e(so,[2,117]),{13:h,16:f,44:215,45:gn,55:220,82:K,87:p,89:ut,172:221,185:351,203:536,211:626,212:627,231:Hn,234:535,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:ye},e(Zn,[2,134]),e(ea,[2,427]),e(Zn,[2,135]),e(ds,[2,26]),{44:628,87:p},e(ti,[2,106]),e(ti,[2,394]),e(A,[2,396]),e(qy,[2,111]),e(qy,[2,398]),{13:h,16:f,44:39,55:40,87:p,139:342,186:629,190:340,195:341,197:Xr,307:43,308:y},e(ue,[2,217]),e(A,nt,{144:248,140:630,143:631,31:[2,343]}),e(at,[2,97]),e(Xe,[2,380]),e(at,[2,180]),{13:h,16:f,44:136,45:le,46:632,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},{13:h,16:f,44:136,45:le,46:633,55:133,67:132,68:134,77:131,82:K,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:Re,264:130,265:ie,266:137,267:139,268:ae,269:Ee,270:De,271:ge,273:de,274:fe,275:146,276:H,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:Q,346:te,347:me,348:Oe,349:Ne,350:We,351:Ve},e(at,[2,190]),{290:[1,634]},{314:[1,635]},{13:h,16:f,48:[1,636],55:414,82:K,171:637,172:415,173:416,174:Kt,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:re,300:ce,301:Te,302:xe,303:Le,304:qe,305:G,306:F,307:43,308:y,312:lr},e(EA,[2,305]),e(pe,[2,86]),e(ri,[2,374]),e(zt,[2,37]),e(zt,[2,38]),e(Fr,[2,72]),e(Fr,[2,360]),e(ta,[2,77]),{29:je,57:638},{47:[1,639]},{29:[2,376]},e(so,[2,402]),e(so,[2,115],{215:10,208:528,214:529,44:530,205:640,13:r,16:r,45:r,197:r,224:r,229:r,308:r,87:p}),e(so,[2,118],{272:[1,641]}),e(By,[2,407],{213:642,319:643,317:[1,644]}),{48:[1,645]},{318:[1,646]},{31:[1,647]},{31:[2,344]},{48:[1,648]},{48:[1,649]},{291:650,303:Le,304:qe,305:G,306:F},e(zr,[2,218]),e(ri,[2,44]),e(EA,[2,306]),e(ta,[2,78]),{44:651,87:p},e(so,[2,116]),e(A,[2,406]),e(By,[2,119]),e(By,[2,408]),e(l,r,{215:10,205:527,208:528,214:529,44:530,202:652,87:p}),e(ds,[2,27]),e(qy,[2,230]),e(OA,[2,345],{141:653,335:[1,654]}),e(at,[2,181]),e(at,[2,182]),{48:[2,191]},{48:[1,655]},{318:[1,656]},e(A,nt,{144:248,142:657,143:658,31:RA,112:RA}),e(OA,[2,346]),e(ta,[2,80]),e(By,[2,231]),e(Ce,[2,67]),e(Ce,[2,348])],defaultActions:{5:[2,240],6:[2,241],7:[2,242],9:[2,239],24:[2,1],25:[2,2],26:[2,244],87:[2,282],94:[2,384],100:[2,45],109:[2,325],166:[2,458],263:[2,439],336:[2,258],337:[2,101],487:[2,461],488:[2,462],560:[2,468],574:[2,17],575:[2,276],576:[2,18],577:[2,278],623:[2,376],631:[2,344],650:[2,191]},parseError:function(Be,ze){if(ze.recoverable)this.trace(Be);else{var Ze=new Error(Be);throw Ze.hash=ze,Ze}},parse:function(Be){var ze=this,Ze=[0],pt=[null],gt=[],ne=this.table,Vn="",se=0,Oa=0,$y=2,Vy=1,ky=gt.slice.call(arguments,1),Nr=Object.create(this.lexer),Li={yy:{}};for(var ys in this.yy)Object.prototype.hasOwnProperty.call(this.yy,ys)&&(Li.yy[ys]=this.yy[ys]);Nr.setInput(Be,Li.yy),Li.yy.lexer=Nr,Li.yy.parser=this,typeof Nr.yylloc>"u"&&(Nr.yylloc={});var ho=Nr.yylloc;gt.push(ho);var Em=Nr.options&&Nr.options.ranges;typeof Li.yy.parseError=="function"?this.parseError=Li.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var zy=function(){var po;return po=Nr.lex()||Vy,typeof po!="number"&&(po=ze.symbols_[po]||po),po},Nt,Jt,It,Yr,Zr={},Gy,aa,BA,Wy;;){if(Jt=Ze[Ze.length-1],this.defaultActions[Jt]?It=this.defaultActions[Jt]:((Nt===null||typeof Nt>"u")&&(Nt=zy()),It=ne[Jt]&&ne[Jt][Nt]),typeof It>"u"||!It.length||!It[0]){var Om="";Wy=[];for(Gy in ne[Jt])this.terminals_[Gy]&&Gy>$y&&Wy.push("'"+this.terminals_[Gy]+"'");Nr.showPosition?Om="Parse error on line "+(se+1)+`: +`+Nr.showPosition()+` +Expecting `+Wy.join(", ")+", got '"+(this.terminals_[Nt]||Nt)+"'":Om="Parse error on line "+(se+1)+": Unexpected "+(Nt==Vy?"end of input":"'"+(this.terminals_[Nt]||Nt)+"'"),this.parseError(Om,{text:Nr.match,token:this.terminals_[Nt]||Nt,line:Nr.yylineno,loc:ho,expected:Wy})}if(It[0]instanceof Array&&It.length>1)throw new Error("Parse Error: multiple actions possible at state: "+Jt+", token: "+Nt);switch(It[0]){case 1:Ze.push(Nt),pt.push(Nr.yytext),gt.push(Nr.yylloc),Ze.push(It[1]),Nt=null,Oa=Nr.yyleng,Vn=Nr.yytext,se=Nr.yylineno,ho=Nr.yylloc;break;case 2:if(aa=this.productions_[It[1]][1],Zr.$=pt[pt.length-aa],Zr._$={first_line:gt[gt.length-(aa||1)].first_line,last_line:gt[gt.length-1].last_line,first_column:gt[gt.length-(aa||1)].first_column,last_column:gt[gt.length-1].last_column},Em&&(Zr._$.range=[gt[gt.length-(aa||1)].range[0],gt[gt.length-1].range[1]]),Yr=this.performAction.apply(Zr,[Vn,Oa,se,Li.yy,It[1],pt,gt].concat(ky)),typeof Yr<"u")return Yr;aa&&(Ze=Ze.slice(0,-1*aa*2),pt=pt.slice(0,-1*aa),gt=gt.slice(0,-1*aa)),Ze.push(this.productions_[It[1]][0]),pt.push(Zr.$),gt.push(Zr._$),BA=ne[Ze[Ze.length-2]][Ze[Ze.length-1]],Ze.push(BA);break;case 3:return!0}}return!0}},Uy=rq().Wildcard,Qy="http://www.w3.org/1999/02/22-rdf-syntax-ns#",eU=Qy+"type",tU=Qy+"first",rU=Qy+"rest",xA=Qy+"nil",Hy="http://www.w3.org/2001/XMLSchema#",IA=Hy+"integer",PA=Hy+"decimal",DA=Hy+"double",nU=Hy+"boolean",fs="",NA="",CA="";function _n(Qe){return Qe.toLowerCase()}function hs(Qe,Be){return Qe.push(Be),Qe}function oo(Qe,Be){return Qe.push.apply(Qe,Be),Qe}function Dr(Qe){Qe||(Qe={});for(var Be=1,ze=arguments.length,Ze;Be>10),56320+(ne&1023))}else{var Vn=sU[gt];if(!Vn)throw new Error;return Vn}})}catch{return""}if(oU.exec(Qe))throw new Error("Invalid unicode codepoint of surrogate pair without corresponding codepoint in "+Qe);return Qe}function uU(Qe){var Be=fu(),ze=Be,Ze=[],pt,gt=[];Qe.forEach(function(Oa){Ze.push(Oa.entity),oo(gt,Oa.triples)});for(var ne=0,Vn=0,se=Ze.length,pt=Array(se*2);ne0&&Ze instanceof Array?wm(Ze,Be-1,ze):ze.push(Ze);return ze}function Sm(Qe){return Qe.termType==="Variable"}function MA(Qe){if(Qe.triples){const Be=[];for(const ze of Qe.triples)Sm(ze.subject)&&Be.push(ze.subject.value),Sm(ze.predicate)&&Be.push(ze.predicate.value),Sm(ze.object)&&Be.push(ze.object.value);return Be}else if(Qe.patterns){const Be=[];for(const ze of Qe.patterns)Be.push(...MA(ze));return Be}return[]}function dU(Qe){const Be=Qe.slice().sort(),ze=[];for(let Ze=0;Ze{const Ze=ia(ze.subject,ze.predicate,ze.object);Be.push(Ze),ze.annotations&&FA(mm(ze.subject,ze.predicate,ze.object),ze.annotations,Be)}),Be}return Qe}function qA(Qe){for(const Be of Qe){if(Be.type==="graph"&&Be.name.termType==="Variable")throw new Error("Detected illegal variable in GRAPH");if(Be.type==="bgp"||Be.type==="graph"){for(const ze of Be.triples)if(ze.subject.termType==="Variable"||ze.predicate.termType==="Variable"||ze.object.termType==="Variable")throw new Error("Detected illegal variable in BGP")}}return Qe}function Am(Qe){for(const Be of Qe)if(Be.type==="bgp"){for(const ze of Be.triples)if(ze.subject.termType==="BlankNode"||ze.predicate.termType==="BlankNode"||ze.object.termType==="BlankNode")throw new Error("Detected illegal blank node in BGP")}return Qe}var fU=function(){var Qe={EOF:1,parseError:function(ze,Ze){if(this.yy.parser)this.yy.parser.parseError(ze,Ze);else throw new Error(ze)},setInput:function(Be,ze){return this.yy=ze||this.yy||{},this._input=Be,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var Be=this._input[0];this.yytext+=Be,this.yyleng++,this.offset++,this.match+=Be,this.matched+=Be;var ze=Be.match(/(?:\r\n?|\n).*/g);return ze?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),Be},unput:function(Be){var ze=Be.length,Ze=Be.split(/(?:\r\n?|\n)/g);this._input=Be+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-ze),this.offset-=ze;var pt=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),Ze.length-1&&(this.yylineno-=Ze.length-1);var gt=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:Ze?(Ze.length===pt.length?this.yylloc.first_column:0)+pt[pt.length-Ze.length].length-Ze[0].length:this.yylloc.first_column-ze},this.options.ranges&&(this.yylloc.range=[gt[0],gt[0]+this.yyleng-ze]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},less:function(Be){this.unput(this.match.slice(Be))},pastInput:function(){var Be=this.matched.substr(0,this.matched.length-this.match.length);return(Be.length>20?"...":"")+Be.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var Be=this.match;return Be.length<20&&(Be+=this._input.substr(0,20-Be.length)),(Be.substr(0,20)+(Be.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var Be=this.pastInput(),ze=new Array(Be.length+1).join("-");return Be+this.upcomingInput()+` +`+ze+"^"},test_match:function(Be,ze){var Ze,pt,gt;if(this.options.backtrack_lexer&&(gt={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(gt.yylloc.range=this.yylloc.range.slice(0))),pt=Be[0].match(/(?:\r\n?|\n).*/g),pt&&(this.yylineno+=pt.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:pt?pt[pt.length-1].length-pt[pt.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+Be[0].length},this.yytext+=Be[0],this.match+=Be[0],this.matches=Be,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(Be[0].length),this.matched+=Be[0],Ze=this.performAction.call(this,this.yy,this,ze,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),Ze)return Ze;if(this._backtrack){for(var ne in gt)this[ne]=gt[ne];return!1}return!1},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var Be,ze,Ze,pt;this._more||(this.yytext="",this.match="");for(var gt=this._currentRules(),ne=0;neze[0].length)){if(ze=Ze,pt=ne,this.options.backtrack_lexer){if(Be=this.test_match(Ze,gt[ne]),Be!==!1)return Be;if(this._backtrack){ze=!1;continue}else return!1}else if(!this.options.flex)break}return ze?(Be=this.test_match(ze,gt[pt]),Be!==!1?Be:!1):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var ze=this.next();return ze||this.lex()},begin:function(ze){this.conditionStack.push(ze)},popState:function(){var ze=this.conditionStack.length-1;return ze>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(ze){return ze=this.conditionStack.length-1-Math.abs(ze||0),ze>=0?this.conditionStack[ze]:"INITIAL"},pushState:function(ze){this.begin(ze)},stateStackSize:function(){return this.conditionStack.length},options:{flex:!0,"case-insensitive":!0},performAction:function(ze,Ze,pt,gt){switch(pt){case 0:break;case 1:return 12;case 2:return 15;case 3:return 41;case 4:return 325;case 5:return 326;case 6:return 45;case 7:return 47;case 8:return 48;case 9:return 39;case 10:return 24;case 11:return 28;case 12:return 29;case 13:return 31;case 14:return 32;case 15:return 36;case 16:return 53;case 17:return 327;case 18:return 63;case 19:return 64;case 20:return 70;case 21:return 73;case 22:return 76;case 23:return 78;case 24:return 81;case 25:return 83;case 26:return 85;case 27:return 193;case 28:return 100;case 29:return 328;case 30:return 121;case 31:return 329;case 32:return 330;case 33:return 110;case 34:return 331;case 35:return 109;case 36:return 332;case 37:return 333;case 38:return 113;case 39:return 115;case 40:return 116;case 41:return 131;case 42:return 123;case 43:return 126;case 44:return 128;case 45:return 132;case 46:return 112;case 47:return 334;case 48:return 335;case 49:return 159;case 50:return 161;case 51:return 164;case 52:return 174;case 53:return 160;case 54:return 336;case 55:return 163;case 56:return 312;case 57:return 314;case 58:return 317;case 59:return 318;case 60:return 272;case 61:return 197;case 62:return 337;case 63:return 338;case 64:return 229;case 65:return 340;case 66:return 263;case 67:return 224;case 68:return 231;case 69:return 232;case 70:return 242;case 71:return 246;case 72:return 290;case 73:return 341;case 74:return 342;case 75:return 343;case 76:return 344;case 77:return 345;case 78:return 250;case 79:return 346;case 80:return 265;case 81:return 276;case 82:return 277;case 83:return 268;case 84:return 269;case 85:return 270;case 86:return 271;case 87:return 347;case 88:return 348;case 89:return 273;case 90:return 274;case 91:return 350;case 92:return 349;case 93:return 351;case 94:return 279;case 95:return 280;case 96:return 283;case 97:return 285;case 98:return 289;case 99:return 293;case 100:return 296;case 101:return 13;case 102:return 16;case 103:return 308;case 104:return 309;case 105:return 87;case 106:return 292;case 107:return 82;case 108:return 294;case 109:return 295;case 110:return 297;case 111:return 298;case 112:return 299;case 113:return 300;case 114:return 301;case 115:return 302;case 116:return"EXPONENT";case 117:return 303;case 118:return 304;case 119:return 305;case 120:return 306;case 121:return 89;case 122:return 310;case 123:return 6;case 124:return"INVALID";case 125:console.log(Ze.yytext);break}},rules:[/^(?:\s+|(#[^\n\r]*))/i,/^(?:BASE)/i,/^(?:PREFIX)/i,/^(?:SELECT)/i,/^(?:DISTINCT)/i,/^(?:REDUCED)/i,/^(?:\()/i,/^(?:AS)/i,/^(?:\))/i,/^(?:\*)/i,/^(?:CONSTRUCT)/i,/^(?:WHERE)/i,/^(?:\{)/i,/^(?:\})/i,/^(?:DESCRIBE)/i,/^(?:ASK)/i,/^(?:FROM)/i,/^(?:NAMED)/i,/^(?:GROUP)/i,/^(?:BY)/i,/^(?:HAVING)/i,/^(?:ORDER)/i,/^(?:ASC)/i,/^(?:DESC)/i,/^(?:LIMIT)/i,/^(?:OFFSET)/i,/^(?:VALUES)/i,/^(?:;)/i,/^(?:LOAD)/i,/^(?:SILENT)/i,/^(?:INTO)/i,/^(?:CLEAR)/i,/^(?:DROP)/i,/^(?:CREATE)/i,/^(?:ADD)/i,/^(?:TO)/i,/^(?:MOVE)/i,/^(?:COPY)/i,/^(?:INSERT((\s+|(#[^\n\r]*)\n\r?)+)DATA)/i,/^(?:DELETE((\s+|(#[^\n\r]*)\n\r?)+)DATA)/i,/^(?:DELETE((\s+|(#[^\n\r]*)\n\r?)+)WHERE)/i,/^(?:WITH)/i,/^(?:DELETE)/i,/^(?:INSERT)/i,/^(?:USING)/i,/^(?:DEFAULT)/i,/^(?:GRAPH)/i,/^(?:ALL)/i,/^(?:\.)/i,/^(?:OPTIONAL)/i,/^(?:SERVICE)/i,/^(?:BIND)/i,/^(?:UNDEF)/i,/^(?:MINUS)/i,/^(?:UNION)/i,/^(?:FILTER)/i,/^(?:<<)/i,/^(?:>>)/i,/^(?:\{\|)/i,/^(?:\|\})/i,/^(?:,)/i,/^(?:a)/i,/^(?:\|)/i,/^(?:\/)/i,/^(?:\^)/i,/^(?:\?)/i,/^(?:\+)/i,/^(?:!)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:\|\|)/i,/^(?:&&)/i,/^(?:=)/i,/^(?:!=)/i,/^(?:<)/i,/^(?:>)/i,/^(?:<=)/i,/^(?:>=)/i,/^(?:IN)/i,/^(?:NOT)/i,/^(?:-)/i,/^(?:BOUND)/i,/^(?:BNODE)/i,/^(?:(RAND|NOW|UUID|STRUUID))/i,/^(?:(LANG|DATATYPE|IRI|URI|ABS|CEIL|FLOOR|ROUND|STRLEN|STR|UCASE|LCASE|ENCODE_FOR_URI|YEAR|MONTH|DAY|HOURS|MINUTES|SECONDS|TIMEZONE|TZ|MD5|SHA1|SHA256|SHA384|SHA512|isIRI|isURI|isBLANK|isLITERAL|isNUMERIC))/i,/^(?:(SUBJECT|PREDICATE|OBJECT|isTRIPLE))/i,/^(?:(LANGMATCHES|CONTAINS|STRSTARTS|STRENDS|STRBEFORE|STRAFTER|STRLANG|STRDT|sameTerm))/i,/^(?:CONCAT)/i,/^(?:COALESCE)/i,/^(?:IF)/i,/^(?:TRIPLE)/i,/^(?:REGEX)/i,/^(?:SUBSTR)/i,/^(?:REPLACE)/i,/^(?:EXISTS)/i,/^(?:COUNT)/i,/^(?:SUM|MIN|MAX|AVG|SAMPLE)/i,/^(?:GROUP_CONCAT)/i,/^(?:SEPARATOR)/i,/^(?:\^\^)/i,/^(?:true|false)/i,/^(?:(<(?:[^<>\"\{\}\|\^`\\\u0000-\u0020])*>))/i,/^(?:((([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])(?:(?:(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040])|\.)*(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040]))?)?:))/i,/^(?:(((([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])(?:(?:(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040])|\.)*(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040]))?)?:)((?:((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|:|[0-9]|((%([0-9A-Fa-f])([0-9A-Fa-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%))))(?:(?:(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040])|\.|:|((%([0-9A-Fa-f])([0-9A-Fa-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%))))*(?:(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040])|:|((%([0-9A-Fa-f])([0-9A-Fa-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%)))))?)))/i,/^(?:(_:(?:((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|[0-9])(?:(?:(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040])|\.)*(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040]))?))/i,/^(?:([\?\$]((?:((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|[0-9])(?:((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040])*)))/i,/^(?:(@[a-zA-Z]+(?:-[a-zA-Z0-9]+)*))/i,/^(?:([0-9]+))/i,/^(?:([0-9]*\.[0-9]+))/i,/^(?:([0-9]+\.[0-9]*([eE][+-]?[0-9]+)|\.([0-9])+([eE][+-]?[0-9]+)|([0-9])+([eE][+-]?[0-9]+)))/i,/^(?:(\+([0-9]+)))/i,/^(?:(\+([0-9]*\.[0-9]+)))/i,/^(?:(\+([0-9]+\.[0-9]*([eE][+-]?[0-9]+)|\.([0-9])+([eE][+-]?[0-9]+)|([0-9])+([eE][+-]?[0-9]+))))/i,/^(?:(-([0-9]+)))/i,/^(?:(-([0-9]*\.[0-9]+)))/i,/^(?:(-([0-9]+\.[0-9]*([eE][+-]?[0-9]+)|\.([0-9])+([eE][+-]?[0-9]+)|([0-9])+([eE][+-]?[0-9]+))))/i,/^(?:([eE][+-]?[0-9]+))/i,/^(?:('(?:(?:[^\u0027\u005C\u000A\u000D])|(\\[tbnrf\\\"']|\\u([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])|\\U([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])))*'))/i,/^(?:("(?:(?:[^\u0022\u005C\u000A\u000D])|(\\[tbnrf\\\"']|\\u([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])|\\U([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])))*"))/i,/^(?:('''(?:(?:'|'')?(?:[^'\\]|(\\[tbnrf\\\"']|\\u([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])|\\U([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f]))))*'''))/i,/^(?:("""(?:(?:"|"")?(?:[^\"\\]|(\\[tbnrf\\\"']|\\u([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])|\\U([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f]))))*"""))/i,/^(?:(\((\u0020|\u0009|\u000D|\u000A)*\)))/i,/^(?:(\[(\u0020|\u0009|\u000D|\u000A)*\]))/i,/^(?:$)/i,/^(?:.)/i,/^(?:.)/i],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125],inclusive:!0}}};return Qe}();hm.lexer=fU;function Ct(){this.yy={}}return Ct.prototype=hm,hm.Parser=Ct,new Ct}();return hg=t,hg}var pg,RO;function rk(){if(RO)return pg;RO=1;var t="http://www.w3.org/2001/XMLSchema#integer",e="http://www.w3.org/2001/XMLSchema#string";function u(f){this._options=f=f||{};var p=f.prefixes||{};this._prefixByIri={};var y=[];for(var b in p){var g=p[b];o(g)&&(this._prefixByIri[g]=b,y.push(g))}var m=y.join("|").replace(/[\]\/\(\)\*\+\?\.\\\$]/g,"\\$&");this._prefixRegex=new RegExp("^("+m+")([a-zA-Z][\\-_a-zA-Z0-9]*)$"),this._usedPrefixes={},this._sparqlStar=f.sparqlStar,this._indent=o(f.indent)?f.indent:" ",this._newline=o(f.newline)?f.newline:` +`,this._explicitDatatype=!!f.explicitDatatype}u.prototype.toQuery=function(f){var p="";return f.queryType&&(p+=f.queryType.toUpperCase()+" "),f.reduced&&(p+="REDUCED "),f.distinct&&(p+="DISTINCT "),f.variables?p+=d(f.variables,void 0,function(y){return/^[?$]/.test(y)?y:l(y)?this.toEntity(y):"("+this.toExpression(y.expression)+" AS "+a(y.variable)+")"},this)+" ":f.template&&(p+=this.group(f.template,!0)+this._newline),f.from&&(p+=this.graphs("FROM ",f.from.default)+this.graphs("FROM NAMED ",f.from.named)),f.where&&(p+="WHERE "+this.group(f.where,!0)+this._newline),f.updates&&(p+=d(f.updates,";"+this._newline,this.toUpdate,this)),f.group&&(p+="GROUP BY "+d(f.group,void 0,function(y){var b=l(y.expression)?this.toEntity(y.expression):"("+this.toExpression(y.expression)+")";return y.variable?"("+b+" AS "+a(y.variable)+")":b},this)+this._newline),f.having&&(p+="HAVING ("+d(f.having,void 0,this.toExpression,this)+")"+this._newline),f.order&&(p+="ORDER BY "+d(f.order,void 0,function(y){var b="("+this.toExpression(y.expression)+")";return y.descending?"DESC "+b:b},this)+this._newline),f.offset&&(p+="OFFSET "+f.offset+this._newline),f.limit&&(p+="LIMIT "+f.limit+this._newline),f.values&&(p+=this.values(f)),p=this.baseAndPrefixes(f)+p,p.trim()},u.prototype.baseAndPrefixes=function(f){var p=f.base?"BASE <"+f.base+">"+this._newline:"",y="";for(var b in f.prefixes)(this._options.allPrefixes||this._usedPrefixes[b])&&(y+="PREFIX "+b+": <"+f.prefixes[b]+">"+this._newline);return p+y},u.prototype.toPattern=function(f){var p=f.type||f instanceof Array&&"array"||(f.subject&&f.predicate&&f.object?"triple":"");if(!(p in this))throw new Error("Unknown entry type: "+p);return this[p](f)},u.prototype.triple=function(f){return this.toEntity(f.subject)+" "+this.toEntity(f.predicate)+" "+this.toEntity(f.object)+"."},u.prototype.array=function(f){return d(f,this._newline,this.toPattern,this)},u.prototype.bgp=function(f){return this.encodeTriples(f.triples)},u.prototype.encodeTriples=function(f){if(!f.length)return"";for(var p=[],y=void 0,b=void 0,g=0;g":case">=":case"<=":case"&&":case"||":case"=":case"!=":case"+":case"-":case"*":case"/":return(l(y[0])?this.toEntity(y[0]):"("+this.toExpression(y[0])+")")+" "+p+" "+(l(y[1])?this.toEntity(y[1]):"("+this.toExpression(y[1])+")");case"!":return"!("+this.toExpression(y[0])+")";case"uplus":return"+("+this.toExpression(y[0])+")";case"uminus":return"-("+this.toExpression(y[0])+")";case"notin":p="NOT IN";case"in":return this.toExpression(y[0])+" "+p+"("+(o(y[1])?y[1]:d(y[1],", ",this.toExpression,this))+")";case"notexists":p="NOT EXISTS";case"exists":return p+" "+this.group(y[0],!0);default:return p+"("+d(y,", ",this.toExpression,this)+")"}default:throw new Error("Unknown expression type: "+f.type)}},u.prototype.toEntity=function(f){if(l(f))switch(f.termType){case"Wildcard":return"*";case"Variable":return a(f);case"BlankNode":return"_:"+f.value;case"Literal":var p=f.value||"",y=f.language||"",b=f.datatype;if(f='"'+p.replace(s,n)+'"',y)f+="@"+y;else if(b){if(!this._explicitDatatype)switch(b.value){case e:return f;case t:if(/^\d+$/.test(p))return p+" "}f+="^^"+this.encodeIRI(b.value)}return f;case"Quad":if(!this._sparqlStar)throw new Error("SPARQL* support is not enabled");return f.graph&&f.graph.termType!=="DefaultGraph"?"<< GRAPH "+this.toEntity(f.graph)+" { "+this.toEntity(f.subject)+" "+this.toEntity(f.predicate)+" "+this.toEntity(f.object)+" } >>":"<< "+this.toEntity(f.subject)+" "+this.toEntity(f.predicate)+" "+this.toEntity(f.object)+" >>";default:return this.encodeIRI(f.value)}else{var g=f.items.map(this.toEntity,this),m=f.pathType;switch(m){case"^":case"!":return m+g[0];case"*":case"+":case"?":return"("+g[0]+m+")";default:return"("+g.join(m)+")"}}};var s=/["\\\t\n\r\b\f]/g,n=function(f){return r[f]},r={"\\":"\\\\",'"':'\\"'," ":"\\t","\n":"\\n","\r":"\\r","\b":"\\b","\f":"\\f"};u.prototype.encodeIRI=function(f){var p=this._prefixRegex.exec(f);if(p){var y=this._prefixByIri[p[1]];return this._usedPrefixes[y]=!0,y+":"+p[2]}return"<"+f+">"},u.prototype.toUpdate=function(f){switch(f.type||f.updateType){case"load":return"LOAD"+(f.source?" "+this.toEntity(f.source):"")+(f.destination?" INTO GRAPH "+this.toEntity(f.destination):"");case"insert":return"INSERT DATA "+this.group(f.insert,!0);case"delete":return"DELETE DATA "+this.group(f.delete,!0);case"deletewhere":return"DELETE WHERE "+this.group(f.delete,!0);case"insertdelete":return(f.graph?"WITH "+this.toEntity(f.graph)+this._newline:"")+(f.delete.length?"DELETE "+this.group(f.delete,!0)+this._newline:"")+(f.insert.length?"INSERT "+this.group(f.insert,!0)+this._newline:"")+(f.using?this.graphs("USING ",f.using.default):"")+(f.using?this.graphs("USING NAMED ",f.using.named):"")+"WHERE "+this.group(f.where,!0);case"add":case"copy":case"move":return f.type.toUpperCase()+" "+(f.silent?"SILENT ":"")+(f.source.default?"DEFAULT":this.toEntity(f.source.name))+" TO "+this.toEntity(f.destination.name);case"create":case"clear":case"drop":return f.type.toUpperCase()+(f.silent?" SILENT ":" ")+(f.graph.default?"DEFAULT":f.graph.named?"NAMED":f.graph.all?"ALL":"GRAPH "+this.toEntity(f.graph.name));default:throw new Error("Unknown update query type: "+f.type)}},u.prototype.indent=function(f){return f.replace(/^/gm,this._indent)};function a(f){return"?"+f.value}function o(f){return typeof f=="string"}function l(f){return typeof f.termType=="string"}function c(f,p){if(!f||!l(f)||!p||!l(p)||f.termType!==p.termType)return!1;switch(f.termType){case"Literal":return f.value===p.value&&f.language===p.language&&c(f.datatype,p.datatype);case"Quad":return c(f.subject,p.subject)&&c(f.predicate,p.predicate)&&c(f.object,p.object)&&c(f.graph,p.graph);default:return f.value===p.value}}function d(f,p,y,b){return f.map(y,b).join(o(p)?p:" ")}function h(f={}){return{stringify:function(p){var y=Object.create(f);return y.prefixes=p.prefixes,new u(y).toQuery(p)},createGenerator:function(){return new u(f)}}}return pg={Generator:h},pg}var yg,xO;function Ay(){if(xO)return yg;xO=1;const{Parser:t}=tk(),{Generator:e}=rk(),{Wildcard:u}=rq(),{DataFactory:s}=Et();function n({prefixes:r,baseIRI:a,factory:o,pathOnly:l,sparqlStar:c,skipValidation:d,skipUngroupedVariableCheck:h}={}){const f={};for(const y in r??{})f[y]=r[y];const p=new t;return p.parse=function(){return t.base=a||"",t.prefixes=Object.create(f),t.factory=o||new s,t.sparqlStar=!!c,t.pathOnly=!!l,t.skipValidation=!!d||!!h,t.prototype.parse.apply(p,arguments)},p._resetBlanks=t._resetBlanks,p}return yg={Parser:n,Generator:e,Wildcard:u},yg}var IO;function Vb(){if(IO)return o1;IO=1;var t=I&&I.__createBinding||(Object.create?function(l,c,d,h){h===void 0&&(h=d);var f=Object.getOwnPropertyDescriptor(c,d);(!f||("get"in f?!c.__esModule:f.writable||f.configurable))&&(f={enumerable:!0,get:function(){return c[d]}}),Object.defineProperty(l,h,f)}:function(l,c,d,h){h===void 0&&(h=d),l[h]=c[d]}),e=I&&I.__setModuleDefault||(Object.create?function(l,c){Object.defineProperty(l,"default",{enumerable:!0,value:c})}:function(l,c){l.default=c}),u=I&&I.__importStar||function(l){if(l&&l.__esModule)return l;var c={};if(l!=null)for(var d in l)d!=="default"&&Object.prototype.hasOwnProperty.call(l,d)&&t(c,l,d);return e(c,l),c};Object.defineProperty(o1,"__esModule",{value:!0});const s=u(Ty()),n=Et(),r=Xt(),a=Ay();class o{constructor(c){this.dataFactory=c||new n.DataFactory,this.stringType=this.createTerm("http://www.w3.org/2001/XMLSchema#string")}createAlt(c,d=!0){return this.flattenMulti({type:s.types.ALT,input:c},d)}createAsk(c){return{type:s.types.ASK,input:c}}createBoundAggregate(c,d,h,f,p){const y=this.createAggregateExpression(d,h,f,p);return y.variable=c,y}createBgp(c){return{type:s.types.BGP,patterns:c}}createConstruct(c,d){return{type:s.types.CONSTRUCT,input:c,template:d}}createDescribe(c,d){return{type:s.types.DESCRIBE,input:c,terms:d}}createDistinct(c){return{type:s.types.DISTINCT,input:c}}createExtend(c,d,h){return{type:s.types.EXTEND,input:c,variable:d,expression:h}}createFrom(c,d,h){return{type:s.types.FROM,input:c,default:d,named:h}}createFilter(c,d){return{type:s.types.FILTER,input:c,expression:d}}createGraph(c,d){return{type:s.types.GRAPH,input:c,name:d}}createGroup(c,d,h){return{type:s.types.GROUP,input:c,variables:d,aggregates:h}}createInv(c){return{type:s.types.INV,path:c}}createJoin(c,d=!0){return this.flattenMulti({type:s.types.JOIN,input:c},d)}createLeftJoin(c,d,h){return h?{type:s.types.LEFT_JOIN,input:[c,d],expression:h}:{type:s.types.LEFT_JOIN,input:[c,d]}}createLink(c){return{type:s.types.LINK,iri:c}}createMinus(c,d){return{type:s.types.MINUS,input:[c,d]}}createNop(){return{type:s.types.NOP}}createNps(c){return{type:s.types.NPS,iris:c}}createOneOrMorePath(c){return{type:s.types.ONE_OR_MORE_PATH,path:c}}createOrderBy(c,d){return{type:s.types.ORDER_BY,input:c,expressions:d}}createPath(c,d,h,f){return f?{type:s.types.PATH,subject:c,predicate:d,object:h,graph:f}:{type:s.types.PATH,subject:c,predicate:d,object:h,graph:this.dataFactory.defaultGraph()}}createPattern(c,d,h,f){const p=this.dataFactory.quad(c,d,h,f);return p.type=s.types.PATTERN,p}createProject(c,d){return{type:s.types.PROJECT,input:c,variables:d}}createReduced(c){return{type:s.types.REDUCED,input:c}}createSeq(c,d=!0){return this.flattenMulti({type:s.types.SEQ,input:c},d)}createService(c,d,h){return{type:s.types.SERVICE,input:c,name:d,silent:!!h}}createSlice(c,d,h){return d=d||0,h!==void 0?{type:s.types.SLICE,input:c,start:d,length:h}:{type:s.types.SLICE,input:c,start:d}}createUnion(c,d=!0){return this.flattenMulti({type:s.types.UNION,input:c},d)}createValues(c,d){return{type:s.types.VALUES,variables:c,bindings:d}}createZeroOrMorePath(c){return{type:s.types.ZERO_OR_MORE_PATH,path:c}}createZeroOrOnePath(c){return{type:s.types.ZERO_OR_ONE_PATH,path:c}}createAggregateExpression(c,d,h,f){return f?{type:s.types.EXPRESSION,expressionType:s.expressionTypes.AGGREGATE,aggregator:c,expression:d,separator:f,distinct:h}:{type:s.types.EXPRESSION,expressionType:s.expressionTypes.AGGREGATE,aggregator:c,expression:d,distinct:h}}createExistenceExpression(c,d){return{type:s.types.EXPRESSION,expressionType:s.expressionTypes.EXISTENCE,not:c,input:d}}createNamedExpression(c,d){return{type:s.types.EXPRESSION,expressionType:s.expressionTypes.NAMED,name:c,args:d}}createOperatorExpression(c,d){return{type:s.types.EXPRESSION,expressionType:s.expressionTypes.OPERATOR,operator:c,args:d}}createTermExpression(c){return{type:s.types.EXPRESSION,expressionType:s.expressionTypes.TERM,term:c}}createWildcardExpression(){return{type:s.types.EXPRESSION,expressionType:s.expressionTypes.WILDCARD,wildcard:new a.Wildcard}}createTerm(c){return c[0]==="$"&&(c=c.replace("$","?")),(0,r.stringToTerm)(c,this.dataFactory)}createCompositeUpdate(c){return{type:s.types.COMPOSITE_UPDATE,updates:c}}createDeleteInsert(c,d,h){const f={type:s.types.DELETE_INSERT};return c&&(f.delete=c),d&&(f.insert=d),h&&(f.where=h),f}createLoad(c,d,h){const f={type:s.types.LOAD,source:c};return d&&(f.destination=d),this.addSilent(f,!!h)}createClear(c,d){return this.addSilent({type:s.types.CLEAR,source:c},!!d)}createCreate(c,d){return this.addSilent({type:s.types.CREATE,source:c},!!d)}createDrop(c,d){return this.addSilent({type:s.types.DROP,source:c},!!d)}createAdd(c,d,h){return this.addSilent({type:s.types.ADD,source:c,destination:d},!!h)}createMove(c,d,h){return this.addSilent({type:s.types.MOVE,source:c,destination:d},!!h)}createCopy(c,d,h){return this.addSilent({type:s.types.COPY,source:c,destination:d},!!h)}addSilent(c,d){return d&&(c.silent=d),c}flattenMulti(c,d){if(!d)return c;const h=c.type,f=c.input;let p=[];for(const y of f)y.type===h?p.push(...y.input):p.push(y);return c.input=p,c}}return o1.default=o,o1}var u1={},PO;function HT(){if(PO)return u1;PO=1;var t=I&&I.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(u1,"__esModule",{value:!0});const e=Ty(),u=t(Vb()),s=un();class n{static flatten(a){return Array.prototype.concat(...a).filter(o=>o)}static objectify(a){if(a.termType){if(a.termType==="Quad")return{type:"pattern",termType:"Quad",subject:n.objectify(a.subject),predicate:n.objectify(a.predicate),object:n.objectify(a.object),graph:n.objectify(a.graph)};{let o={termType:a.termType,value:a.value};return a.language&&(o.language=a.language),a.datatype&&(o.datatype=n.objectify(a.datatype)),o}}if(Array.isArray(a))return a.map(o=>n.objectify(o));if(a===Object(a)){let o={};for(let l of Object.keys(a))o[l]=n.objectify(a[l]);return o}return a}static inScopeVariables(a){const o=[];function l(d){o.find(h=>d.value===h.value)||o.push(d)}function c(d){d.subject.termType==="Variable"&&l(d.subject),d.predicate.termType==="Variable"&&l(d.predicate),d.object.termType==="Variable"&&l(d.object),d.graph.termType==="Variable"&&l(d.graph),d.subject.termType==="Quad"&&c(d.subject),d.predicate.termType==="Quad"&&c(d.predicate),d.object.termType==="Quad"&&c(d.object),d.graph.termType==="Quad"&&c(d.graph)}return n.recurseOperation(a,{[e.types.EXPRESSION]:d=>(d.expressionType===e.expressionTypes.AGGREGATE&&d.variable&&l(d.variable),!0),[e.types.EXTEND]:d=>(l(d.variable),!0),[e.types.GRAPH]:d=>(d.name.termType==="Variable"&&l(d.name),!0),[e.types.GROUP]:d=>(d.variables.forEach(l),!0),[e.types.PATH]:d=>(d.subject.termType==="Variable"&&l(d.subject),d.object.termType==="Variable"&&l(d.object),d.graph.termType==="Variable"&&l(d.graph),d.subject.termType==="Quad"&&c(d.subject),d.object.termType==="Quad"&&c(d.object),d.graph.termType==="Quad"&&c(d.graph),!0),[e.types.PATTERN]:d=>(c(d),!0),[e.types.PROJECT]:d=>(d.variables.forEach(l),!1),[e.types.SERVICE]:d=>(d.name.termType==="Variable"&&l(d.name),!0),[e.types.VALUES]:d=>(d.variables.forEach(l),!0)}),o}static recurseOperation(a,o){let l=a,c=!0;const d=o[a.type];if(d&&(c=d(a)),!c)return;let h=f=>n.recurseOperation(f,o);switch(l.type){case e.types.ALT:l.input.map(h);break;case e.types.ASK:h(l.input);break;case e.types.BGP:l.patterns.forEach(h);break;case e.types.CONSTRUCT:h(l.input),l.template.map(h);break;case e.types.DESCRIBE:h(l.input);break;case e.types.DISTINCT:h(l.input);break;case e.types.EXPRESSION:l.expressionType===e.expressionTypes.EXISTENCE&&h(l.input);break;case e.types.EXTEND:h(l.input),h(l.expression);break;case e.types.FILTER:h(l.input),h(l.expression);break;case e.types.FROM:h(l.input);break;case e.types.GRAPH:h(l.input);break;case e.types.GROUP:h(l.input),l.aggregates.forEach(h);break;case e.types.INV:h(l.path);break;case e.types.JOIN:l.input.map(h);break;case e.types.LEFT_JOIN:l.input.map(h),l.expression&&h(l.expression);break;case e.types.LINK:break;case e.types.MINUS:l.input.map(h);break;case e.types.NOP:break;case e.types.NPS:break;case e.types.ONE_OR_MORE_PATH:h(l.path);break;case e.types.ORDER_BY:h(l.input),l.expressions.forEach(h);break;case e.types.PATH:h(l.predicate);break;case e.types.PATTERN:break;case e.types.PROJECT:h(l.input);break;case e.types.REDUCED:h(l.input);break;case e.types.SEQ:l.input.map(h);break;case e.types.SERVICE:h(l.input);break;case e.types.SLICE:h(l.input);break;case e.types.UNION:l.input.map(h);break;case e.types.VALUES:break;case e.types.ZERO_OR_MORE_PATH:h(l.path);break;case e.types.ZERO_OR_ONE_PATH:h(l.path);break;case e.types.COMPOSITE_UPDATE:l.updates.forEach(f=>h(f));break;case e.types.DELETE_INSERT:l.delete&&l.delete.forEach(f=>h(f)),l.insert&&l.insert.forEach(f=>h(f)),l.where&&h(l.where);break;case e.types.LOAD:break;case e.types.CLEAR:break;case e.types.CREATE:break;case e.types.DROP:break;case e.types.ADD:break;case e.types.MOVE:break;case e.types.COPY:break;default:throw new Error(`Unknown Operation type ${l.type}`)}}static mapOperation(a,o,l){let c=a,d=!0,h=!0;l=l||new u.default;const f=o[a.type];if(f){const b=f(a,l);c=b.result,d=b.recurse,h=b.copyMetadata!==!1}let p;if(h&&(c.metadata||a.metadata)&&(p={...c.metadata,...a.metadata}),!d)return p&&(c.metadata=p),c;let y=b=>n.mapOperation(b,o,l);switch(c.type){case e.types.ALT:c=l.createAlt(c.input.map(y));break;case e.types.ASK:c=l.createAsk(y(c.input));break;case e.types.BGP:c=l.createBgp(c.patterns.map(y));break;case e.types.CONSTRUCT:c=l.createConstruct(y(c.input),c.template.map(y));break;case e.types.DESCRIBE:c=l.createDescribe(y(c.input),c.terms);break;case e.types.DISTINCT:c=l.createDistinct(y(c.input));break;case e.types.EXPRESSION:c=n.mapExpression(c,o,l);break;case e.types.EXTEND:c=l.createExtend(y(c.input),c.variable,y(c.expression));break;case e.types.FILTER:c=l.createFilter(y(c.input),y(c.expression));break;case e.types.FROM:c=l.createFrom(y(c.input),[...c.default],[...c.named]);break;case e.types.GRAPH:c=l.createGraph(y(c.input),c.name);break;case e.types.GROUP:c=l.createGroup(y(c.input),[].concat(c.variables),c.aggregates.map(y));break;case e.types.INV:c=l.createInv(y(c.path));break;case e.types.JOIN:c=l.createJoin(c.input.map(y));break;case e.types.LEFT_JOIN:c=l.createLeftJoin(y(c.input[0]),y(c.input[1]),c.expression?y(c.expression):void 0);break;case e.types.LINK:c=l.createLink(c.iri);break;case e.types.MINUS:c=l.createMinus(y(c.input[0]),y(c.input[1]));break;case e.types.NOP:c=l.createNop();break;case e.types.NPS:c=l.createNps([].concat(c.iris));break;case e.types.ONE_OR_MORE_PATH:c=l.createOneOrMorePath(y(c.path));break;case e.types.ORDER_BY:c=l.createOrderBy(y(c.input),c.expressions.map(y));break;case e.types.PATH:c=l.createPath(c.subject,y(c.predicate),c.object,c.graph);break;case e.types.PATTERN:c=l.createPattern(c.subject,c.predicate,c.object,c.graph);break;case e.types.PROJECT:c=l.createProject(y(c.input),[...c.variables]);break;case e.types.REDUCED:c=l.createReduced(y(c.input));break;case e.types.SEQ:c=l.createSeq(c.input.map(y));break;case e.types.SERVICE:c=l.createService(y(c.input),c.name,c.silent);break;case e.types.SLICE:c=l.createSlice(y(c.input),c.start,c.length);break;case e.types.UNION:c=l.createUnion(c.input.map(y));break;case e.types.VALUES:c=l.createValues([].concat(c.variables),c.bindings.map(b=>Object.assign({},b)));break;case e.types.ZERO_OR_MORE_PATH:c=l.createZeroOrMorePath(y(c.path));break;case e.types.ZERO_OR_ONE_PATH:c=l.createZeroOrOnePath(y(c.path));break;case e.types.COMPOSITE_UPDATE:c=l.createCompositeUpdate(c.updates.map(y));break;case e.types.DELETE_INSERT:c=l.createDeleteInsert(c.delete?c.delete.map(y):void 0,c.insert?c.insert.map(y):void 0,c.where?y(c.where):void 0);break;case e.types.LOAD:c=l.createLoad(c.source,c.destination,c.silent);break;case e.types.CLEAR:c=l.createClear(c.source,c.silent);break;case e.types.CREATE:c=l.createCreate(c.source,c.silent);break;case e.types.DROP:c=l.createDrop(c.source,c.silent);break;case e.types.ADD:c=l.createAdd(c.source,c.destination);break;case e.types.MOVE:c=l.createMove(c.source,c.destination);break;case e.types.COPY:c=l.createCopy(c.source,c.destination);break;default:throw new Error(`Unknown Operation type ${c.type}`)}return p&&(c.metadata=p),c}static mapExpression(a,o,l){let c=a,d=!0;l=l||new u.default;const h=o[a.expressionType];if(h&&({result:c,recurse:d}=h(a,l)),!d)return c;let f=p=>n.mapOperation(p,o,l);switch(a.expressionType){case e.expressionTypes.AGGREGATE:return a.variable?l.createBoundAggregate(a.variable,a.aggregator,f(a.expression),a.distinct,a.separator):l.createAggregateExpression(a.aggregator,f(a.expression),a.distinct,a.separator);case e.expressionTypes.EXISTENCE:return l.createExistenceExpression(a.not,f(a.input));case e.expressionTypes.NAMED:return l.createNamedExpression(a.name,a.args.map(f));case e.expressionTypes.OPERATOR:return l.createOperatorExpression(a.operator,a.args.map(f));case e.expressionTypes.TERM:return l.createTermExpression(a.term);case e.expressionTypes.WILDCARD:return l.createWildcardExpression();default:throw new Error(`Unknown Expression type ${a.expressionType}`)}}static cloneOperation(a){return n.mapOperation(a,{})}static cloneExpression(a){return n.mapExpression(a,{})}static createUniqueVariable(a,o,l){let c=0,d=a;for(;o[d];)d=`${a}${c++}`;return l.variable(d)}static isSimpleTerm(a){return a.termType!==void 0&&a.termType!=="Quad"&&a.termType!=="Wildcard"}static isQuad(a){return a.termType==="Quad"}static hasQuadVariables(a){return(0,s.someTermsNested)(a,o=>o.termType==="Variable")}static isWildcard(a){return a.termType==="Wildcard"}}return u1.default=n,u1}var DO;function nk(){if(DO)return s1;DO=1;var t=I&&I.__createBinding||(Object.create?function(N,R,T,x){x===void 0&&(x=T);var B=Object.getOwnPropertyDescriptor(R,T);(!B||("get"in B?!R.__esModule:B.writable||B.configurable))&&(B={enumerable:!0,get:function(){return R[T]}}),Object.defineProperty(N,x,B)}:function(N,R,T,x){x===void 0&&(x=T),N[x]=R[T]}),e=I&&I.__setModuleDefault||(Object.create?function(N,R){Object.defineProperty(N,"default",{enumerable:!0,value:R})}:function(N,R){N.default=R}),u=I&&I.__importStar||function(N){if(N&&N.__esModule)return N;var R={};if(N!=null)for(var T in N)T!=="default"&&Object.prototype.hasOwnProperty.call(N,T)&&t(R,N,T);return e(R,N),R},s=I&&I.__importDefault||function(N){return N&&N.__esModule?N:{default:N}};Object.defineProperty(s1,"__esModule",{value:!0});const n=ek(),r=Xt(),a=u(Ty()),o=s(Vb()),l=s(HT()),c=Ay().Parser,d=a.types;let h=new Set,f=0,p=!1,y;function b(N,R){R=R||{},y=new o.default(R.dataFactory);let T;if(m(N)){let x=new c(R);x._resetBlanks(),T=x.parse(N)}else T=N;return g(T,R.quads,R.blankToVariable)}s1.default=b;function g(N,R,T){if(h=new Set,f=0,p=!!R,!N.type)return y.createNop();if(N.type!=="query"&&N.type!=="update")throw new Error("Translate only works on complete query or update objects.");let x;if(S(N),N.type==="query"){const B={type:"group",patterns:N.where||[]};x=D(B),x=K(N,x)}else N.type==="update"&&(x=ie(N));return T&&(x=H(x)),x}function m(N){return typeof N=="string"}function v(N){return!!(N!=null&&N.termType)}function _(N){return N.subject&&N.predicate&&N.object}function w(N){return(N==null?void 0:N.termType)==="Variable"}function S(N){if(v(N))w(N)&&h.add(`?${N.value}`);else if(Array.isArray(N))for(const R of N)S(R);else if(N&&typeof N=="object")for(let R of Object.keys(N))R.startsWith("?")?h.add(R):R.startsWith("$")&&h.add(`?${R.slice(1)}`),S(N[R])}function A(N){let R={};if(_(N)){const T=[A(N.subject),A(N.predicate),A(N.object),N.graph?A(N.graph):{}];Object.assign(R,...T)}else if(v(N))w(N)&&(R[N.value]=N);else if(N.type==="bgp"){const T=N.triples;Object.assign(R,...T.map(A))}else if(N.type==="path")Object.assign(R,...N.items.map(A));else if(N.type==="group"||N.type==="union"||N.type==="optional")Object.assign(R,...N.patterns.map(A));else if(N.type==="service"||N.type==="graph")Object.assign(R,A(N.name)),Object.assign(R,...N.patterns.map(A));else if(N.type==="bind")Object.assign(R,A(N.variable));else if(N.type==="values"){if(N.values.length>0){const T=Object.keys(N.values[0]).map(x=>y.createTerm(x));Object.assign(R,...T.map(A))}}else if(N.type==="query"&&(N.queryType==="SELECT"||N.queryType==="DESCRIBE")){N.where&&N.variables.some(l.default.isWildcard)&&Object.assign(R,...N.where.map(A));for(const T of N.variables)w(T)?Object.assign(R,A(T)):T.variable&&Object.assign(R,A(T.variable));if(N.queryType==="SELECT"){if(N.group)for(const T of N.group)T.variable&&Object.assign(R,A(T.variable));if(N.values){const T={type:"values",values:N.values};Object.assign(R,A(T))}}}return R}function D(N){if(N.type==="bgp")return O(N);if(N.type==="union")return y.createUnion(N.patterns.map(R=>(R.type!=="group"&&(R={type:"group",patterns:[R]}),D(R))));if(N.type==="graph"){const R={type:"group",patterns:N.patterns};let T=D(R);return p?T=$(T,N.name):T=y.createGraph(T,N.name),T}if(N.type==="values")return le(N);if(N.type==="query")return g(N,p,!1);if(N.type==="group"){let R=[],T=[];for(let k of N.patterns)(k.type==="filter"?R:T).push(k);let x=T.reduce(Z,y.createBgp([])),B=R.map(k=>L(k.expression));return B.length>0&&(x=y.createFilter(x,B.reduce((k,V)=>y.createOperatorExpression("&&",[k,V])))),x}throw new Error(`Unexpected type: ${N.type}`)}function L(N){if(l.default.isSimpleTerm(N))return y.createTermExpression(N);if(l.default.isQuad(N))return l.default.hasQuadVariables(N)?y.createOperatorExpression("triple",[L(N.subject),L(N.predicate),L(N.object)]):y.createTermExpression(N);if(l.default.isWildcard(N))return y.createWildcardExpression();if("aggregation"in N)return y.createAggregateExpression(N.aggregation,L(N.expression),!!N.distinct,N.separator);if("function"in N)return y.createNamedExpression(N.function,N.args.map(L));if("operator"in N)return N.operator==="exists"||N.operator==="notexists"?y.createExistenceExpression(N.operator==="notexists",D(N.args[0])):((N.operator==="in"||N.operator==="notin")&&(N.args=[N.args[0]].concat(N.args[1])),y.createOperatorExpression(N.operator,N.args.map(L)));throw new Error(`Unknown expression: ${JSON.stringify(N)}`)}function O(N){let R=[],T=[];for(let x of N.triples)if("pathType"in x.predicate){let B=E(x);for(let k of B)k.type===d.PATH?(R.length>0&&T.push(y.createBgp(R)),R=[],T.push(k)):R.push(k)}else R.push(j(x));return R.length>0&&T.push(y.createBgp(R)),T.length===1?T[0]:y.createJoin(T)}function E(N){let R=N.subject,T=P(N.predicate),x=N.object;return M(R,T,x)}function P(N){if(l.default.isSimpleTerm(N)){if(N.termType==="NamedNode")return y.createLink(N);throw new Error(`Path predicate should be a NamedNode, got ${JSON.stringify(N)}`)}if(N.pathType==="^")return y.createInv(P(N.items[0]));if(N.pathType==="!"){let R=[],T=[],x;"pathType"in N.items[0]&&N.items[0].pathType==="|"?x=N.items[0].items:x=N.items;for(let V of x)if(l.default.isSimpleTerm(V))R.push(V);else if(V.pathType==="^")T.push(V.items[0]);else throw new Error(`Unexpected item: ${JSON.stringify(V)}`);let B=y.createNps(R),k=y.createInv(y.createNps(T));return T.length===0?B:R.length===0?k:y.createAlt([B,k])}if(N.pathType==="/")return y.createSeq(N.items.map(P));if(N.pathType==="|")return y.createAlt(N.items.map(P));if(N.pathType==="*")return y.createZeroOrMorePath(P(N.items[0]));if(N.pathType==="+")return y.createOneOrMorePath(P(N.items[0]));if(N.pathType==="?")return y.createZeroOrOnePath(P(N.items[0]));throw new Error(`Unable to translate path expression ${JSON.stringify(N)}`)}function M(N,R,T){if(R.type===d.LINK)return[y.createPattern(N,R.iri,T)];if(R.type===d.INV)return M(T,R.path,N);if(R.type===d.SEQ){let x=N;return l.default.flatten(R.input.map((B,k)=>{const V=k===R.input.length-1?T:U(),J=M(x,B,V);return V.termType==="Variable"&&(x=V),J}))}return[y.createPath(N,R,T)]}function U(){let N=`?var${f++}`;return h.has(N)?U():(h.add(N),y.createTerm(N))}function j(N){if("pathType"in N.predicate)throw new Error("Trying to translate property path to quad.");return y.createPattern(N.subject,N.predicate,N.object,N.graph)}let q=Object.values(d);function $(N,R,T){if(N.type===d.GRAPH){if(T)throw new Error("Recursing through nested GRAPH statements with a replacement is impossible.");N=$(N.input,N.name)}else if(N.type!==d.SERVICE)if(N.type===d.BGP)N.patterns=N.patterns.map(x=>(T&&(x.subject.equals(R)&&(x.subject=T),x.predicate.equals(R)&&(x.predicate=T),x.object.equals(R)&&(x.object=T)),x.graph.termType==="DefaultGraph"&&(x.graph=R),x));else if(N.type===d.PATH)T&&(N.subject.equals(R)&&(N.subject=T),N.object.equals(R)&&(N.object=T)),N.graph.termType==="DefaultGraph"&&(N.graph=R);else if(N.type===d.PROJECT&&!T)N.variables.some(x=>x.equals(R))||(T=U()),N.input=$(N.input,R,T);else if(N.type===d.EXTEND&&!T)N.variable.equals(R)&&(T=U()),N.input=$(N.input,R,T);else for(let x of Object.keys(N))Array.isArray(N[x])?N[x]=N[x].map(B=>$(B,R,T)):q.indexOf(N[x].type)>=0?N[x]=$(N[x],R,T):T&&w(N[x])&&N[x].equals(R)&&(N[x]=T);return N}function Z(N,R){if(R.type==="optional"){const T=D({type:"group",patterns:R.patterns});T.type===d.FILTER?N=y.createLeftJoin(N,T.input,T.expression):N=y.createLeftJoin(N,T)}else if(R.type==="minus"){const T=D({type:"group",patterns:R.patterns});N=y.createMinus(N,T)}else if(R.type==="bind")N=y.createExtend(N,R.variable,L(R.expression));else if(R.type==="service"){const T={type:"group",patterns:R.patterns},x=y.createService(D(T),R.name,R.silent);N=X(N,x)}else{const T=D(R);N=X(N,T)}return N}function X(N,R){return N.type===d.BGP&&R.type===d.BGP?N=y.createBgp([...N.patterns,...R.patterns]):N.type===d.BGP&&N.patterns.length===0?N=R:R.type===d.BGP&&R.patterns.length===0||(N=y.createJoin([N,R])),N}function le(N){let R=(N.values.length===0?[]:Object.keys(N.values[0])).map(y.createTerm.bind(y)),T=N.values.map(x=>{let B=Object.keys(x);B=B.filter(V=>x[V]!==void 0);let k={};for(let V of B)k[V]=x[V];return k});return y.createValues(R,T)}function K(N,R){const T=N,x=[],B={};if(T.variables=T.variables&&T.variables.map(V=>he(V,B)),T.having=T.having&&T.having.map(V=>he(V,B)),T.order=T.order&&T.order.map(V=>he(V,B)),T.group||Object.keys(B).length>0){const V=Object.keys(B).map(z=>Re(B[z],y.createTerm(z))),J=[];if(T.group)for(const z of T.group)if(l.default.isSimpleTerm(z.expression))J.push(z.expression);else{const Y="variable"in z?z.variable:U();R=y.createExtend(R,Y,L(z.expression)),J.push(Y)}R=y.createGroup(R,J,V)}if(T.having)for(let V of T.having)R=y.createFilter(R,L(V));N.values&&(R=y.createJoin([R,le(N)]));let k=[];if(N.queryType==="SELECT"||N.queryType==="DESCRIBE")if(N.variables.some(V=>V&&l.default.isWildcard(V)))k=Object.values(A(N)).sort((V,J)=>V.value.localeCompare(J.value));else for(let V of N.variables)w(V)||!("variable"in V)?k.push(V):V.variable&&(k.push(V.variable),x.push(V));for(let V of x)R=y.createExtend(R,V.variable,L(V.expression));return T.order&&(R=y.createOrderBy(R,T.order.map(V=>{let J=L(V.expression);return V.descending&&(J=y.createOperatorExpression("desc",[J])),J}))),N.queryType==="SELECT"&&(R=y.createProject(R,k)),T.distinct&&(R=y.createDistinct(R)),T.reduced&&(R=y.createReduced(R)),N.queryType==="CONSTRUCT"?R=y.createConstruct(R,(N.template||[]).map(j)):N.queryType==="ASK"?R=y.createAsk(R):N.queryType==="DESCRIBE"&&(R=y.createDescribe(R,k)),(T.offset||T.limit)&&(R=y.createSlice(R,T.offset||0,T.limit)),T.from&&(R=y.createFrom(R,T.from.default,T.from.named)),R}function he(N,R){if("type"in N&&N.type==="aggregate"){let T=!1,x;for(let B of Object.keys(R))if(n(R[B],N)){x=y.createTerm(B),T=!0;break}return T||(x=U(),R[(0,r.termToString)(x)]=N),x}return"expression"in N&&N.expression?{...N,expression:he(N.expression,R)}:"args"in N&&N.args?{...N,args:N.args.map(T=>he(T,R))}:N}function Re(N,R){if(N.type!=="aggregate"||!N.aggregation)throw new Error(`Unexpected input: ${JSON.stringify(N)}`);const T=L(N);return T.variable=R,T}function ie(N){return N.updates.length===1?ae(N.updates[0]):y.createCompositeUpdate(N.updates.map(ae))}function ae(N){if("type"in N){if(N.type==="load")return de(N);if(N.type==="clear"||N.type==="create"||N.type==="drop")return ge(N);if(N.type==="add"||N.type==="copy"||N.type==="move")return fe(N)}else if(N.updateType==="insertdelete"||N.updateType==="deletewhere"||N.updateType==="delete"||N.updateType==="insert")return Ee(N);throw new Error(`Unknown update type ${JSON.stringify(N)}`)}function Ee(N){if(!p)throw new Error("INSERT/DELETE operations are only supported with quads option enabled");let R=[],T=[],x;if(N.delete&&(R=l.default.flatten(N.delete.map(B=>De(B,N.graph)))),N.insert&&(T=l.default.flatten(N.insert.map(B=>De(B,N.graph)))),N.where&&N.where.length>0){x=D({type:"group",patterns:N.where});const B=N.using;B?x=y.createFrom(x,B.default,B.named):N.graph&&(x=$(x,N.graph))}else N.updateType==="deletewhere"&&R.length>0&&(x=y.createBgp(R));return y.createDeleteInsert(R.length>0?R:void 0,T.length>0?T:void 0,x)}function De(N,R){let T=R;N.type==="graph"&&(T=N.name);let x=N.triples;return T&&(x=x.map(B=>Object.assign(B,{graph:T}))),x.map(j)}function ge(N){let R;switch(l.default.isSimpleTerm(N.graph)?R=N.graph:N.graph.all?R="ALL":N.graph.default?R="DEFAULT":N.graph.named?R="NAMED":R=N.graph.name,N.type){case"clear":return y.createClear(R,N.silent);case"create":return y.createCreate(R,N.silent);case"drop":return y.createDrop(R,N.silent)}}function de(N){return y.createLoad(N.source,N.destination,N.silent)}function fe(N){const R=N.source.default?"DEFAULT":N.source.name,T=N.destination.default?"DEFAULT":N.destination.name;switch(N.type){case"copy":return y.createCopy(R,T,N.silent);case"move":return y.createMove(R,T,N.silent);case"add":return y.createAdd(R,T,N.silent)}}function H(N){const R={},T=Array.from(h).reduce((B,k)=>(B[k]=!0,B),{});return l.default.mapOperation(N,{[a.types.DELETE_INSERT]:B=>({result:y.createDeleteInsert(B.delete,B.insert,B.where&&H(B.where)),recurse:!1}),[a.types.PATH]:(B,k)=>({result:k.createPath(x(B.subject),B.predicate,x(B.object),x(B.graph)),recurse:!1}),[a.types.PATTERN]:(B,k)=>({result:k.createPattern(x(B.subject),x(B.predicate),x(B.object),x(B.graph)),recurse:!1}),[a.types.CONSTRUCT]:B=>({result:y.createConstruct(H(B.input),B.template),recurse:!1})});function x(B){if(B.termType==="BlankNode"){let k=R[B.value];return k||(k=l.default.createUniqueVariable(B.value,T,y.dataFactory),T[k.value]=!0,R[B.value]=k),k}return B}}return s1}var _s={},bg={},Mt={},mg={},nr={},gg,NO;function Ey(){if(NO)return gg;NO=1,gg=t;function t(e,u){if(!e)throw new Error(u||"Assertion failed")}return t.equal=function(u,s,n){if(u!=s)throw new Error(n||"Assertion failed: "+u+" != "+s)},gg}var c1={exports:{}},CO;function ik(){return CO||(CO=1,typeof Object.create=="function"?c1.exports=function(e,u){u&&(e.super_=u,e.prototype=Object.create(u.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:c1.exports=function(e,u){if(u){e.super_=u;var s=function(){};s.prototype=u.prototype,e.prototype=new s,e.prototype.constructor=e}}),c1.exports}var jO;function ki(){if(jO)return nr;jO=1;var t=Ey(),e=ik();nr.inherits=e;function u(M,U){return(M.charCodeAt(U)&64512)!==55296||U<0||U+1>=M.length?!1:(M.charCodeAt(U+1)&64512)===56320}function s(M,U){if(Array.isArray(M))return M.slice();if(!M)return[];var j=[];if(typeof M=="string")if(U){if(U==="hex")for(M=M.replace(/[^a-z0-9]+/ig,""),M.length%2!==0&&(M="0"+M),$=0;$>6|192,j[q++]=Z&63|128):u(M,$)?(Z=65536+((Z&1023)<<10)+(M.charCodeAt(++$)&1023),j[q++]=Z>>18|240,j[q++]=Z>>12&63|128,j[q++]=Z>>6&63|128,j[q++]=Z&63|128):(j[q++]=Z>>12|224,j[q++]=Z>>6&63|128,j[q++]=Z&63|128)}else for($=0;$>>24|M>>>8&65280|M<<8&16711680|(M&255)<<24;return U>>>0}nr.htonl=r;function a(M,U){for(var j="",q=0;q>>0}return Z}nr.join32=c;function d(M,U){for(var j=new Array(M.length*4),q=0,$=0;q>>24,j[$+1]=Z>>>16&255,j[$+2]=Z>>>8&255,j[$+3]=Z&255):(j[$+3]=Z>>>24,j[$+2]=Z>>>16&255,j[$+1]=Z>>>8&255,j[$]=Z&255)}return j}nr.split32=d;function h(M,U){return M>>>U|M<<32-U}nr.rotr32=h;function f(M,U){return M<>>32-U}nr.rotl32=f;function p(M,U){return M+U>>>0}nr.sum32=p;function y(M,U,j){return M+U+j>>>0}nr.sum32_3=y;function b(M,U,j,q){return M+U+j+q>>>0}nr.sum32_4=b;function g(M,U,j,q,$){return M+U+j+q+$>>>0}nr.sum32_5=g;function m(M,U,j,q){var $=M[U],Z=M[U+1],X=q+Z>>>0,le=(X>>0,M[U+1]=X}nr.sum64=m;function v(M,U,j,q){var $=U+q>>>0,Z=($>>0}nr.sum64_hi=v;function _(M,U,j,q){var $=U+q;return $>>>0}nr.sum64_lo=_;function w(M,U,j,q,$,Z,X,le){var K=0,he=U;he=he+q>>>0,K+=he>>0,K+=he>>0,K+=he>>0}nr.sum64_4_hi=w;function S(M,U,j,q,$,Z,X,le){var K=U+q+Z+le;return K>>>0}nr.sum64_4_lo=S;function A(M,U,j,q,$,Z,X,le,K,he){var Re=0,ie=U;ie=ie+q>>>0,Re+=ie>>0,Re+=ie>>0,Re+=ie>>0,Re+=ie>>0}nr.sum64_5_hi=A;function D(M,U,j,q,$,Z,X,le,K,he){var Re=U+q+Z+le+he;return Re>>>0}nr.sum64_5_lo=D;function L(M,U,j){var q=U<<32-j|M>>>j;return q>>>0}nr.rotr64_hi=L;function O(M,U,j){var q=M<<32-j|U>>>j;return q>>>0}nr.rotr64_lo=O;function E(M,U,j){return M>>>j}nr.shr64_hi=E;function P(M,U,j){var q=M<<32-j|U>>>j;return q>>>0}return nr.shr64_lo=P,nr}var _g={},LO;function Oy(){if(LO)return _g;LO=1;var t=ki(),e=Ey();function u(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}return _g.BlockHash=u,u.prototype.update=function(n,r){if(n=t.toArray(n,r),this.pending?this.pending=this.pending.concat(n):this.pending=n,this.pendingTotal+=n.length,this.pending.length>=this._delta8){n=this.pending;var a=n.length%this._delta8;this.pending=n.slice(n.length-a,n.length),this.pending.length===0&&(this.pending=null),n=t.join32(n,0,n.length-a,this.endian);for(var o=0;o>>24&255,o[l++]=n>>>16&255,o[l++]=n>>>8&255,o[l++]=n&255}else for(o[l++]=n&255,o[l++]=n>>>8&255,o[l++]=n>>>16&255,o[l++]=n>>>24&255,o[l++]=0,o[l++]=0,o[l++]=0,o[l++]=0,c=8;c>>3}Fi.g0_256=l;function c(d){return e(d,17)^e(d,19)^d>>>10}return Fi.g1_256=c,Fi}var vg,FO;function ak(){if(FO)return vg;FO=1;var t=ki(),e=Oy(),u=nq(),s=t.rotl32,n=t.sum32,r=t.sum32_5,a=u.ft_1,o=e.BlockHash,l=[1518500249,1859775393,2400959708,3395469782];function c(){if(!(this instanceof c))return new c;o.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}return t.inherits(c,o),vg=c,c.blockSize=512,c.outSize=160,c.hmacStrength=80,c.padLength=64,c.prototype._update=function(h,f){for(var p=this.W,y=0;y<16;y++)p[y]=h[f+y];for(;ythis.blockSize&&(n=new this.Hash().update(n).digest()),e(n.length<=this.blockSize);for(var r=n.length;ru.someTerms(A,D=>D.termType==="BlankNode"||D.termType==="Quad"&&u.getTermsNested(D).some(L=>L.termType==="BlankNode")))}Mt.getQuadsWithBlankNodes=c;function d(S){return S.filter(A=>u.everyTerms(A,D=>D.termType!=="BlankNode"&&!(D.termType==="Quad"&&u.getTermsNested(D).some(L=>L.termType==="BlankNode"))))}Mt.getQuadsWithoutBlankNodes=d;function h(S){const A={};for(const D of S)A[JSON.stringify(e.quadToStringQuad(D))]=!0;return A}Mt.indexGraph=h;function f(S){return Object.keys(S).map(A=>e.stringQuadToQuad(JSON.parse(A)))}Mt.deindexGraph=f;function p(S){return f(h(S))}Mt.uniqGraph=p;function y(S){return u.uniqTerms(S.map(A=>u.getBlankNodes(u.getTermsNested(A))).reduce((A,D)=>A.concat(D),[]))}Mt.getGraphBlankNodes=y;function b(S,A,D){const L=Object.assign({},D),O={};let E=!0;for(;E;){const P=Object.keys(L).length;for(const U of A){const j=e.termToString(U);if(!L[j]){const[q,$]=g(U,S,L);q&&(L[j]=$),O[j]=$}}const M={};for(const U in O){const j=O[U];M[j]===void 0?M[j]=U:M[j]=!1}for(const U in M){const j=M[U];j&&(L[j]=U)}E=P!==Object.keys(L).length}return[L,O]}Mt.hashTerms=b;function g(S,A,D){const L=[];let O=!0;for(const P of A){const M=u.getTermsNested(P);if(M.some(U=>U.equals(S))){L.push(v(P,D,S));for(const U of M)!w(U,D)&&!U.equals(S)&&(O=!1)}}const E=m(L.sort().join(""));return[O,E]}Mt.hashTerm=g;function m(S){return t.sha1().update(S).digest("hex")}Mt.sha1hex=m;function v(S,A,D){return u.getTerms(S).map(L=>_(L,A,D)).join("|")}Mt.quadToSignature=v;function _(S,A,D){return S.equals(D)?"@self":S.termType==="BlankNode"?A[e.termToString(S)]||"@blank":S.termType==="Quad"?`<${v(S,A,D)}>`:e.termToString(S)}Mt.termToSignature=_;function w(S,A){return S.termType!=="BlankNode"&&!(S.termType==="Quad"&&u.getTermsNested(S).some(D=>!w(D,A)))||!!A[e.termToString(S)]}return Mt.isTermGrounded=w,Mt}var GO;function fk(){return GO||(GO=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(dk(),t)}(bg)),bg}var WO;function hk(){if(WO)return _s;WO=1;var t=I&&I.__createBinding||(Object.create?function(W,Se,Ae,je){je===void 0&&(je=Ae);var He=Object.getOwnPropertyDescriptor(Se,Ae);(!He||("get"in He?!Se.__esModule:He.writable||He.configurable))&&(He={enumerable:!0,get:function(){return Se[Ae]}}),Object.defineProperty(W,je,He)}:function(W,Se,Ae,je){je===void 0&&(je=Ae),W[je]=Se[Ae]}),e=I&&I.__setModuleDefault||(Object.create?function(W,Se){Object.defineProperty(W,"default",{enumerable:!0,value:Se})}:function(W,Se){W.default=Se}),u=I&&I.__importStar||function(W){if(W&&W.__esModule)return W;var Se={};if(W!=null)for(var Ae in W)Ae!=="default"&&Object.prototype.hasOwnProperty.call(W,Ae)&&t(Se,W,Ae);return e(Se,W),Se},s=I&&I.__importDefault||function(W){return W&&W.__esModule?W:{default:W}};Object.defineProperty(_s,"__esModule",{value:!0}),_s.toSparqlJs=_s.toSparql=void 0;const n=fk(),r=Xt(),a=Ay(),o=u(Ty()),l=s(Vb()),c=s(HT()),d=o.types,h=o.expressionTypes;let f;const p=new l.default;function y(W,Se={}){return new a.Generator(Se).stringify(b(W))}_s.toSparql=y;function b(W){g(),W=Ve(W);let Se=m(W);return Se.type==="group"?Se.patterns[0]:Se}_s.toSparqlJs=b;function g(){f={project:!1,extend:[],group:[],aggregates:[],order:[]}}function m(W){switch(W.type!==d.EXTEND&&W.type!==d.ORDER_BY&&W.type!==d.GRAPH&&(f.project=!1),W.type){case d.EXPRESSION:return v(W);case d.ASK:return de(W,d.ASK);case d.BGP:return U(W);case d.CONSTRUCT:return j(W);case d.DESCRIBE:return de(W,d.DESCRIBE);case d.DISTINCT:return q(W);case d.EXTEND:return $(W);case d.FROM:return Z(W);case d.FILTER:return X(W);case d.GRAPH:return le(W);case d.GROUP:return K(W);case d.JOIN:return he(W);case d.LEFT_JOIN:return Re(W);case d.MINUS:return ie(W);case d.NOP:return{};case d.ORDER_BY:return ae(W);case d.PATH:return Ee(W);case d.PATTERN:return De(W);case d.PROJECT:return de(W,d.PROJECT);case d.REDUCED:return H(W);case d.SERVICE:return N(W);case d.SLICE:return R(W);case d.UNION:return T(W);case d.VALUES:return x(W);case d.COMPOSITE_UPDATE:return Te(W);case d.DELETE_INSERT:return xe(W);case d.LOAD:return Le(W);case d.CLEAR:return qe(W);case d.CREATE:return G(W);case d.DROP:return F(W);case d.ADD:return te(W);case d.MOVE:return me(W);case d.COPY:return Oe(W)}throw new Error(`Unknown Operation type ${W.type}`)}function v(W){switch(W.expressionType){case h.AGGREGATE:return S(W);case h.EXISTENCE:return A(W);case h.NAMED:return D(W);case h.OPERATOR:return L(W);case h.TERM:return O(W);case h.WILDCARD:return E(W)}throw new Error(`Unknown Expression Operation type ${W.expressionType}`)}function _(W){switch(W.type){case d.ALT:return B(W);case d.INV:return k(W);case d.LINK:return V(W);case d.NPS:return J(W);case d.ONE_OR_MORE_PATH:return z(W);case d.SEQ:return Y(W);case d.ZERO_OR_MORE_PATH:return re(W);case d.ZERO_OR_ONE_PATH:return ce(W)}throw new Error(`Unknown Path type ${W.type}`)}function w(W){return(0,r.termToString)(W)}function S(W){const Se={expression:v(W.expression),type:"aggregate",aggregation:W.aggregator,distinct:W.distinct};return W.separator&&(Se.separator=W.separator),Se}function A(W){return{type:"operation",operator:W.not?"notexists":"exists",args:[{type:"group",patterns:c.default.flatten([m(W.input)])}]}}function D(W){return{type:"functionCall",function:W.name,args:W.args.map(v)}}function L(W){if(W.operator==="desc"){const Ae={expression:v(W.args[0])};return Ae.descending=!0,Ae}const Se={type:"operation",operator:W.operator,args:W.args.map(v)};return(Se.operator==="in"||Se.operator==="notin")&&(Se.args=[Se.args[0]].concat([Se.args.slice(1)])),Se}function O(W){return W.term}function E(W){return W.wildcard}function P(W){return Array.isArray(W)?W.length===1?W[0]:{type:"group",patterns:W}:W}function M(W){return W}function U(W){let Se=W.patterns.map(De);return Se.length===0?null:{type:"bgp",triples:Se}}function j(W){return{type:"query",prefixes:{},queryType:"CONSTRUCT",template:W.template.map(De),where:c.default.flatten([m(W.input)])}}function q(W){let Se=m(W.input);return Se.patterns[0].distinct=!0,Se}function $(W){return f.project?(f.extend.push(W),m(W.input)):c.default.flatten([m(W.input),{type:"bind",variable:W.variable,expression:v(W.expression)}])}function Z(W){const Se=m(W.input);let Ae=Se;return Se.type==="group"&&(Ae=Se.patterns[0]),Ae.from={default:W.default,named:W.named},Se}function X(W){return{type:"group",patterns:c.default.flatten([m(W.input),{type:"filter",expression:v(W.expression)}])}}function le(W){return{type:"graph",patterns:c.default.flatten([m(W.input)]),name:W.name}}function K(W){const Se=m(W.input),Ae=W.aggregates.map(M);return f.aggregates.push(...Ae),f.group.push(...W.variables),Se}function he(W){return c.default.flatten(W.input.map(m)).reduce((Ae,je)=>(je.type!=="bgp"||Ae.length==0||Ae[Ae.length-1].type!=="bgp"?Ae.push(je):Ae[Ae.length-1].triples.push(...je.triples),Ae),[])}function Re(W){const Se={type:"optional",patterns:[m(W.input[1])]};return W.expression&&Se.patterns.push({type:"filter",expression:v(W.expression)}),Se.patterns=c.default.flatten(Se.patterns),c.default.flatten([m(W.input[0]),Se])}function ie(W){let Se=m(W.input[1]);return Se.type==="group"&&(Se=Se.patterns),Array.isArray(Se)||(Se=[Se]),c.default.flatten([m(W.input[0]),{type:"minus",patterns:Se}])}function ae(W){return f.order.push(...W.expressions),m(W.input)}function Ee(W){return{type:"bgp",triples:[{subject:W.subject,predicate:_(W.predicate),object:W.object}]}}function De(W){return{subject:W.subject,predicate:W.predicate,object:W.object}}function ge(W,Se){let Ae=c.default.isSimpleTerm(W)?w(W):W;if(typeof Ae=="string"){if(Se[Ae])return Se[Ae]}else if(Array.isArray(W))W=W.map(je=>ge(je,Se));else for(let je of Object.keys(W))W[je]=ge(W[je],Se);return W}function de(W,Se){const Ae={type:"query",prefixes:{}},je=Ae;let He;Se===d.PROJECT?(Ae.queryType="SELECT",He=W.variables):Se===d.ASK?Ae.queryType="ASK":Se===d.DESCRIBE&&(Ae.queryType="DESCRIBE",He=W.terms);const Ge=f.extend,tt=f.group,lt=f.aggregates,ut=f.order;g(),f.project=!0;let oe=c.default.flatten([m(W.input)]);oe.length===1&&oe[0].type==="group"&&(oe=oe[0].patterns),Ae.where=oe;let C={};for(let Pe of f.aggregates)C[w(Pe.variable)]=v(Pe);let ee={};for(let Pe=f.extend.length-1;Pe>=0;--Pe){let Ue=f.extend[Pe];ee[w(Ue.variable)]=ge(v(Ue.expression),C)}f.group.length>0&&(je.group=f.group.map(Pe=>{let Ue=w(Pe);if(ee[Ue]){let Fe=ee[Ue];return delete ee[Ue],{variable:Pe,expression:Fe}}return{expression:Pe}})),f.order.length>0&&(je.order=f.order.map(m).map(Pe=>Pe.descending?Pe:{expression:Pe})),He&&(je.variables=He.map(Pe=>{let Ue=w(Pe);if(ee[Ue]){let Fe=ee[Ue];return delete ee[Ue],{variable:Pe,expression:Fe}}return Pe}),je.variables.length===0&&(je.variables=[new a.Wildcard]));const ye=Object.entries(ee);if(ye.length>0){je.where=je.where||[];for(const[Pe,Ue]of ye)je.where.push({type:"bind",variable:(0,r.stringToTerm)(Pe),expression:Ue})}if(Ae.where.length>0&&Ae.where[Ae.where.length-1].type==="filter"){const Pe=Ae.where[Ae.where.length-1];fe(Pe,Object.keys(C))&&(je.having=c.default.flatten([ge(Pe.expression,C)]),Ae.where.splice(-1))}return f.extend=Ge,f.group=tt,f.aggregates=lt,f.order=ut,{type:"group",patterns:[je]}}function fe(W,Se){return c.default.isSimpleTerm(W)?Se.indexOf(w(W))>=0:Array.isArray(W)?W.some(Ae=>fe(Ae,Se)):W===Object(W)?Object.keys(W).some(Ae=>fe(W[Ae],Se)):Se.indexOf(W)>=0}function H(W){let Se=m(W.input);return Se.patterns[0].reduced=!0,Se}function N(W){let Se=m(W.input);return Se.type==="group"&&(Se=Se.patterns),Array.isArray(Se)||(Se=[Se]),{type:"service",name:W.name,silent:W.silent,patterns:Se}}function R(W){let Se=m(W.input),Ae=Se;return Se.type&&Se.type==="group"&&(Ae=Se.patterns[0]),W.start!==0&&(Ae.offset=W.start),W.length!==void 0&&(Ae.limit=W.length),Se}function T(W){return{type:"union",patterns:W.input.map(m).map(P)}}function x(W){return{type:"values",values:W.bindings.map(Se=>{let Ae={};for(let je of W.variables){let He=`?${je.value}`;Se[He]?Ae[He]=Se[He]:Ae[He]=void 0}return Ae})}}function B(W){const Se=W.input.map(_);return Se.every(Ae=>"pathType"in Ae&&Ae.pathType==="!")?{type:"path",pathType:"!",items:[{type:"path",pathType:"|",items:c.default.flatten(Se.map(Ae=>Ae.items))}]}:{type:"path",pathType:"|",items:Se}}function k(W){if(W.path.type===d.NPS){const Se=W.path.iris.map(Ae=>({type:"path",pathType:"^",items:[Ae]}));return Se.length<=1?{type:"path",pathType:"!",items:Se}:{type:"path",pathType:"!",items:[{type:"path",pathType:"|",items:Se}]}}return{type:"path",pathType:"^",items:[_(W.path)]}}function V(W){return W.iri}function J(W){return W.iris.length<=1?{type:"path",pathType:"!",items:W.iris}:{type:"path",pathType:"!",items:[{type:"path",pathType:"|",items:W.iris}]}}function z(W){return{type:"path",pathType:"+",items:[_(W.path)]}}function Y(W){return{type:"path",pathType:"/",items:W.input.map(_)}}function re(W){return{type:"path",pathType:"*",items:[_(W.path)]}}function ce(W){return{type:"path",pathType:"?",items:[_(W.path)]}}function Te(W){const Se=W.updates.map(Ae=>m(Ae).updates[0]);return{prefixes:{},type:"update",updates:Se}}function xe(W){var Se;let Ae=W.where,je;if(Ae&&Ae.type===d.FROM){let Ge=Ae;Ae=Ge.input,je={default:Ge.default,named:Ge.named}}const He=[{updateType:"insertdelete",delete:We(W.delete||[]),insert:We(W.insert||[])}];if(je&&(He[0].using=je),!Ae||Ae.type===d.BGP&&Ae.patterns.length===0)He[0].where=[];else{const Ge=[];let tt=m(pe(Ae,Ge));if(tt.type==="group"?He[0].where=tt.patterns:He[0].where=[tt],Ge.length>0){if(Ge.length!==1)throw new Error("This is unexpected and might indicate an error in graph handling for updates.");((Se=Ge[0])===null||Se===void 0?void 0:Se.value)!==""&&(He[0].where=[{type:"graph",patterns:He[0].where,name:Ge[0]}])}}return!W.delete&&!W.where?(He[0].updateType="insert",delete He[0].delete,delete He[0].where):!W.insert&&!W.where?(delete He[0].insert,delete He[0].where,W.delete.some(Ge=>Ge.subject.termType==="Variable"||Ge.predicate.termType==="Variable"||Ge.object.termType==="Variable")?He[0].updateType="deletewhere":He[0].updateType="delete"):!W.insert&&W.where&&W.where.type==="bgp"&&(0,n.isomorphic)(W.delete,W.where.patterns)&&(delete He[0].where,He[0].updateType="deletewhere"),{prefixes:{},type:"update",updates:He}}function Le(W){const Se=[{type:"load",silent:!!W.silent,source:W.source}];return W.destination&&(Se[0].destination=W.destination),{prefixes:{},type:"update",updates:Se}}function qe(W){return Q(W,"clear")}function G(W){return Q(W,"create")}function F(W){return Q(W,"drop")}function Q(W,Se){const Ae=[{type:Se,silent:!!W.silent}];return W.source==="DEFAULT"?Ae[0].graph={default:!0}:W.source==="NAMED"?Ae[0].graph={named:!0}:W.source==="ALL"?Ae[0].graph={all:!0}:Ae[0].graph={type:"graph",name:W.source},{prefixes:{},type:"update",updates:Ae}}function te(W){return Ne(W,"add")}function me(W){return Ne(W,"move")}function Oe(W){return Ne(W,"copy")}function Ne(W,Se){const Ae=[{type:Se,silent:!!W.silent}];return Ae[0].source=W.source==="DEFAULT"?{type:"graph",default:!0}:{type:"graph",name:W.source},Ae[0].destination=W.destination==="DEFAULT"?{type:"graph",default:!0}:{type:"graph",name:W.destination},{prefixes:{},type:"update",updates:Ae}}function We(W){if(!W)return[];const Se={};return W.forEach(Ae=>{const je=Ae.graph.value;Se[je]||(Se[je]=[]),Se[je].push(Ae)}),Object.keys(Se).map(Ae=>Ae===""?{type:"bgp",triples:Se[Ae].map(De)}:{type:"graph",triples:Se[Ae].map(De),name:Se[Ae][0].graph})}function Ve(W){return pe(W,[])}function pe(W,Se){if(Array.isArray(W))return W.map(tt=>pe(tt,Se));if(!W.type||W.type===d.DELETE_INSERT)return W;if((W.type===d.PATTERN||W.type===d.PATH)&&W.graph)return Se.push(W.graph),W.graph.name!==""?W.type===d.PATTERN?p.createPattern(W.subject,W.predicate,W.object):p.createPath(W.subject,W.predicate,W.object):W;const Ae={},je={},He={};for(let tt of Object.keys(W)){const lt=[];if(Ae[tt]=pe(W[tt],lt),lt.length>0){je[tt]=lt;for(const ut of lt)He[ut.value]=ut}}const Ge=Object.keys(He);if(Ge.length>0)if(Ge.length===1&&![d.PROJECT,d.SERVICE].includes(W.type))Se.push(He[Ge[0]]);else{if(W.type===d.BGP)return we(W,je.patterns);for(let tt of Object.keys(je)){const lt=Ae[tt];Array.isArray(lt)?Ae[tt]=lt.map((ut,oe)=>je[tt][0].value===""?ut:p.createGraph(ut,je[tt][oe])):je[tt][0].value!==""&&(Ae[tt]=p.createGraph(lt,je[tt][0]))}}return Ae}function we(W,Se){var Ae;const je={};for(let tt=0;tth.termType==="Variable")?(0,u.mapTermsNested)(c,h=>a(h,d)):c}gs.materializeTerm=a;function o(c,d,h,f={}){return f={strictTargetVariables:"strictTargetVariables"in f?f.strictTargetVariables:!1,bindFilter:"bindFilter"in f?f.bindFilter:!0,originalBindings:"originalBindings"in f?f.originalBindings:d},s.Util.mapOperation(c,{path(p,y){return{recurse:!1,result:Object.assign(y.createPath(a(p.subject,d),p.predicate,a(p.object,d),a(p.graph,d)),{metadata:p.metadata})}},pattern(p,y){return{recurse:!1,result:Object.assign(y.createPattern(a(p.subject,d),a(p.predicate,d),a(p.object,d),a(p.graph,d)),{metadata:p.metadata})}},extend(p){if(d.has(p.variable)){if(f.strictTargetVariables)throw new Error(`Tried to bind variable ${(0,e.termToString)(p.variable)} in a BIND operator.`);return{recurse:!0,result:o(p.input,d,h,f)}}return{recurse:!0,result:p}},group(p,y){if(f.strictTargetVariables){for(const g of p.variables)if(d.has(g))throw new Error(`Tried to bind variable ${(0,e.termToString)(g)} in a GROUP BY operator.`);return{recurse:!0,result:p}}const b=p.variables.filter(g=>!d.has(g));return{recurse:!0,result:y.createGroup(p.input,b,p.aggregates)}},project(p,y){if(f.strictTargetVariables){for(const m of p.variables)if(d.has(m))throw new Error(`Tried to bind variable ${(0,e.termToString)(m)} in a SELECT operator.`);return{recurse:!0,result:p}}for(const m of d.keys())for(const v of p.variables)if(v.equals(m)){d=d.delete(m);break}const b=l(y,f.originalBindings,p.variables);let g=o(p.input,d,h,f);return b.length>0&&(g=y.createJoin([...b,g])),{recurse:!1,result:y.createProject(g,p.variables)}},filter(p,y){const b=f.originalBindings;if(p.expression.expressionType!=="operator"||b.size===0)return{recurse:!1,result:p};const g=l(y,b),m=o(p.expression,d,h,f);let v=o(p.input,d,h,f);return g.length>0&&(v=y.createJoin([...g,v])),{recurse:!1,result:y.createFilter(v,m)}},values(p,y){if(f.strictTargetVariables){for(const b of p.variables)if(d.has(b))throw new Error(`Tried to bind variable ${(0,e.termToString)(b)} in a VALUES operator.`)}else{const b=p.variables.filter(m=>!d.has(m)),g=p.bindings.map(m=>{const v={...m};let _=!0;return d.forEach((w,S)=>{const A=(0,e.termToString)(S);A in v&&(w.equals(v[A])||(_=!1),delete v[A])}),_?v:void 0}).filter(Boolean);return{recurse:!0,result:y.createValues(b,g)}}return{recurse:!1,result:p}},expression(p,y){if(!f.bindFilter)return{recurse:!1,result:p};if(p.expressionType==="term")return{recurse:!1,result:y.createTermExpression(a(p.term,d))};if(p.expressionType==="operator")return p.operator==="bound"&&p.args.length===1&&p.args[0].expressionType==="term"&&[...d.keys()].some(b=>p.args[0].term.equals(b))?{recurse:!1,result:y.createTermExpression(r)}:{recurse:!0,result:p};if(p.expressionType==="aggregate"&&"variable"in p&&d.has(p.variable)){if(f.strictTargetVariables)throw new Error(`Tried to bind ${(0,e.termToString)(p.variable)} in a ${p.aggregator} aggregate.`);return{recurse:!0,result:p}}return{recurse:!0,result:p}}})}gs.materializeOperation=o;function l(c,d,h){const f=[];for(const[p,y]of d)if(!h||h.some(b=>b.equals(p))){const b={[(0,e.termToString)(p)]:y};f.push(c.createValues([p],[b]))}return f}return gs}var KO;function oq(){if(KO)return _u;KO=1,Object.defineProperty(_u,"__esModule",{value:!0}),_u.ActorQueryOperation=void 0;const t=Lt,e=ot,u=UT(),s=sq();let n=0,r=class qi extends e.Actor{constructor(o){super(o)}static getSafeBindings(o){return qi.validateQueryOutput(o,"bindings"),o}static getSafeQuads(o){return qi.validateQueryOutput(o,"quads"),o}static getSafeBoolean(o){return qi.validateQueryOutput(o,"boolean"),o}static getSafeVoid(o){return qi.validateQueryOutput(o,"void"),o}static validateQueryOutput(o,l){if(o.type!==l)throw new Error(`Invalid query output type: Expected '${l}' but got '${o.type}'`)}static getBaseExpressionContext(o){const l=o.get(t.KeysInitQuery.queryTimestamp),c=o.get(t.KeysInitQuery.baseIRI),d=o.get(t.KeysInitQuery.functionArgumentsCache)??{};if(o.has(t.KeysInitQuery.extensionFunctionCreator)&&o.has(t.KeysInitQuery.extensionFunctions))throw new Error("Illegal simultaneous usage of extensionFunctionCreator and extensionFunctions in context");let h=o.get(t.KeysInitQuery.extensionFunctionCreator);const f=o.get(t.KeysInitQuery.extensionFunctions);return f&&(h=p=>f[p.value]),{now:l,baseIRI:c,extensionFunctionCreator:h,functionArgumentsCache:d}}static getExpressionContext(o,l){return{...this.getBaseExpressionContext(o),bnode:c=>new u.BlankNodeBindingsScoped(c??`BNODE_${n++}`)}}static getAsyncExpressionContext(o,l,c){return{...this.getBaseExpressionContext(o),bnode:d=>Promise.resolve(new u.BlankNodeBindingsScoped(d??`BNODE_${n++}`)),exists:qi.createExistenceResolver(o,l,c)}}static createExistenceResolver(o,l,c){return async(d,h)=>{const f=(0,s.materializeOperation)(d.input,h,c),p=await l.mediate({operation:f,context:o}),y=qi.getSafeBindings(p);return d.not!==((await y.bindingsStream.take(1).toArray()).length===1)}}static throwOnReadOnly(o){if(o.get(t.KeysQueryOperation.readOnly))throw new Error("Attempted a write operation in read-only mode")}static getOperationSource(o){var l;return(l=o.metadata)==null?void 0:l.scopedSource}static assignOperationSource(o,l){return o={...o},o.metadata=o.metadata?{...o.metadata}:{},o.metadata.scopedSource=l,o}static removeOperationSource(o){var l;(l=o.metadata)==null||delete l.scopedSource,o.metadata&&Object.keys(o.metadata).length===0&&delete o.metadata}static doesShapeAcceptOperation(o,l,c){return o.type==="conjunction"?o.children.every(d=>qi.doesShapeAcceptOperation(d,l,c)):o.type==="disjunction"?o.children.some(d=>qi.doesShapeAcceptOperation(d,l,c)):o.type==="arity"?qi.doesShapeAcceptOperation(o.child,l,c):((c==null?void 0:c.joinBindings)&&!o.joinBindings)??((c==null?void 0:c.filterBindings)&&!o.filterBindings)?!1:o.operation.operationType==="type"?o.operation.type==="project"||o.operation.type===l.type:o.operation.pattern.type===l.type}};return _u.ActorQueryOperation=r,_u}var Iu={},Rg={},Pu={},YO;function pk(){if(YO)return Pu;YO=1,Object.defineProperty(Pu,"__esModule",{value:!0}),Pu.MetadataValidationState=void 0;let t=class{constructor(){this.invalidateListeners=[],this.valid=!0}addInvalidateListener(u){this.invalidateListeners.push(u)}invalidate(){if(this.valid){this.valid=!1;for(const u of this.invalidateListeners)u()}}};return Pu.MetadataValidationState=t,Pu}var kn={},ZO;function yk(){if(ZO)return kn;ZO=1,Object.defineProperty(kn,"__esModule",{value:!0}),kn.cachifyMetadata=kn.validateMetadataBindings=kn.validateMetadataQuads=kn.getMetadataBindings=kn.getMetadataQuads=void 0;function t(r){return n(()=>new Promise((a,o)=>{r.getProperty("metadata",l=>a(l)),r.on("error",o)}).then(a=>u(a)))}kn.getMetadataQuads=t;function e(r){return n(()=>new Promise((a,o)=>{r.getProperty("metadata",l=>a(l)),r.on("error",o)}).then(a=>("canContainUndefs"in a||(a.canContainUndefs=!1),s(a))))}kn.getMetadataBindings=e;function u(r){for(const a of["cardinality"])if(!(a in r))throw new Error(`Invalid metadata: missing ${a} in ${JSON.stringify(r)}`);return r}kn.validateMetadataQuads=u;function s(r){for(const a of["cardinality","canContainUndefs","variables"])if(!(a in r))throw new Error(`Invalid metadata: missing ${a} in ${JSON.stringify(r)}`);return r}kn.validateMetadataBindings=s;function n(r){let a;return()=>(a||(a=r(),a.then(o=>o.state.addInvalidateListener(()=>{a=void 0})).catch(()=>{})),a)}return kn.cachifyMetadata=n,kn}var eR;function Cn(){return eR||(eR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(pk(),t),u(yk(),t)}(Rg)),Rg}var tR;function uq(){if(tR)return Iu;tR=1,Object.defineProperty(Iu,"__esModule",{value:!0}),Iu.ActorQueryOperationTyped=void 0;const t=Lt,e=Cn(),u=oq();let s=class extends u.ActorQueryOperation{constructor(r,a){if(super({...r,operationName:a}),!this.operationName)throw new Error('A valid "operationName" argument must be provided.')}async test(r){if(!r.operation)throw new Error("Missing field 'operation' in a query operation action.");if(r.operation.type!==this.operationName)throw new Error(`Actor ${this.name} only supports ${this.operationName} operations, but got ${r.operation.type}`);const a=r.operation;return this.testOperation(a,r.context)}async run(r){const a=r.context.get(t.KeysInitQuery.physicalQueryPlanLogger);a&&(a.logOperation(r.operation.type,void 0,r.operation,r.context.get(t.KeysInitQuery.physicalQueryPlanNode),this.name,{}),r.context=r.context.set(t.KeysInitQuery.physicalQueryPlanNode,r.operation));const o=r.operation,l=r.context.set(t.KeysQueryOperation.operation,o),c=await this.runOperation(o,l);return"metadata"in c&&(c.metadata=(0,e.cachifyMetadata)(c.metadata)),c}};return Iu.ActorQueryOperationTyped=s,Iu}var Du={},rR;function bk(){if(rR)return Du;rR=1,Object.defineProperty(Du,"__esModule",{value:!0}),Du.ActorQueryOperationTypedMediated=void 0;const t=uq();let e=class extends t.ActorQueryOperationTyped{constructor(s,n){super(s,n)}};return Du.ActorQueryOperationTypedMediated=e,Du}var Nu={},nR;function mk(){if(nR)return Nu;nR=1,Object.defineProperty(Nu,"__esModule",{value:!0}),Nu.BusQueryOperation=void 0;const t=ot;let e=class extends t.BusIndexed{constructor(s){super({...s,actorIdentifierFields:["operationName"],actionIdentifierFields:["operation","type"]})}};return Nu.BusQueryOperation=e,Nu}var Cu={},xg={},l1={exports:{}},iR;function Ry(){if(iR)return l1.exports;iR=1;var t=typeof Reflect=="object"?Reflect:null,e=t&&typeof t.apply=="function"?t.apply:function(S,A,D){return Function.prototype.apply.call(S,A,D)},u;t&&typeof t.ownKeys=="function"?u=t.ownKeys:Object.getOwnPropertySymbols?u=function(S){return Object.getOwnPropertyNames(S).concat(Object.getOwnPropertySymbols(S))}:u=function(S){return Object.getOwnPropertyNames(S)};function s(w){console&&console.warn&&console.warn(w)}var n=Number.isNaN||function(S){return S!==S};function r(){r.init.call(this)}l1.exports=r,l1.exports.once=m,r.EventEmitter=r,r.prototype._events=void 0,r.prototype._eventsCount=0,r.prototype._maxListeners=void 0;var a=10;function o(w){if(typeof w!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof w)}Object.defineProperty(r,"defaultMaxListeners",{enumerable:!0,get:function(){return a},set:function(w){if(typeof w!="number"||w<0||n(w))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+w+".");a=w}}),r.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},r.prototype.setMaxListeners=function(S){if(typeof S!="number"||S<0||n(S))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+S+".");return this._maxListeners=S,this};function l(w){return w._maxListeners===void 0?r.defaultMaxListeners:w._maxListeners}r.prototype.getMaxListeners=function(){return l(this)},r.prototype.emit=function(S){for(var A=[],D=1;D0&&(E=A[0]),E instanceof Error)throw E;var P=new Error("Unhandled error."+(E?" ("+E.message+")":""));throw P.context=E,P}var M=O[S];if(M===void 0)return!1;if(typeof M=="function")e(M,this,A);else for(var U=M.length,j=y(M,U),D=0;D0&&E.length>L&&!E.warned){E.warned=!0;var P=new Error("Possible EventEmitter memory leak detected. "+E.length+" "+String(S)+" listeners added. Use emitter.setMaxListeners() to increase limit");P.name="MaxListenersExceededWarning",P.emitter=w,P.type=S,P.count=E.length,s(P)}return w}r.prototype.addListener=function(S,A){return c(this,S,A,!1)},r.prototype.on=r.prototype.addListener,r.prototype.prependListener=function(S,A){return c(this,S,A,!0)};function d(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function h(w,S,A){var D={fired:!1,wrapFn:void 0,target:w,type:S,listener:A},L=d.bind(D);return L.listener=A,D.wrapFn=L,L}r.prototype.once=function(S,A){return o(A),this.on(S,h(this,S,A)),this},r.prototype.prependOnceListener=function(S,A){return o(A),this.prependListener(S,h(this,S,A)),this},r.prototype.removeListener=function(S,A){var D,L,O,E,P;if(o(A),L=this._events,L===void 0)return this;if(D=L[S],D===void 0)return this;if(D===A||D.listener===A)--this._eventsCount===0?this._events=Object.create(null):(delete L[S],L.removeListener&&this.emit("removeListener",S,D.listener||A));else if(typeof D!="function"){for(O=-1,E=D.length-1;E>=0;E--)if(D[E]===A||D[E].listener===A){P=D[E].listener,O=E;break}if(O<0)return this;O===0?D.shift():b(D,O),D.length===1&&(L[S]=D[0]),L.removeListener!==void 0&&this.emit("removeListener",S,P||A)}return this},r.prototype.off=r.prototype.removeListener,r.prototype.removeAllListeners=function(S){var A,D,L;if(D=this._events,D===void 0)return this;if(D.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):D[S]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete D[S]),this;if(arguments.length===0){var O=Object.keys(D),E;for(L=0;L=0;L--)this.removeListener(S,A[L]);return this};function f(w,S,A){var D=w._events;if(D===void 0)return[];var L=D[S];return L===void 0?[]:typeof L=="function"?A?[L.listener||L]:[L]:A?g(L):y(L,L.length)}r.prototype.listeners=function(S){return f(this,S,!0)},r.prototype.rawListeners=function(S){return f(this,S,!1)},r.listenerCount=function(w,S){return typeof w.listenerCount=="function"?w.listenerCount(S):p.call(w,S)},r.prototype.listenerCount=p;function p(w){var S=this._events;if(S!==void 0){var A=S[w];if(typeof A=="function")return 1;if(A!==void 0)return A.length}return 0}r.prototype.eventNames=function(){return this._eventsCount>0?u(this._events):[]};function y(w,S){for(var A=new Array(S),D=0;Dt.then(a),s=typeof setImmediate=="function"?setImmediate:a=>setTimeout(a,0);let n=0,r=null;return a=>{r!==null?r.push(a):++n<100?u(a):(r=[a],s(()=>{for(const o of r)u(o);r=null,n=0}))}}return Lu.createTaskScheduler=e,Lu}var oR;function Dt(){return oR||(oR=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.isIterator=t.isIterable=t.isSourceExpression=t.isPromise=t.isEventEmitter=t.isFunction=t.range=t.union=t.fromIterable=t.fromIterator=t.fromArray=t.single=t.empty=t.wrap=t.WrappingIterator=t.ClonedIterator=t.UnionIterator=t.MultiTransformIterator=t.SimpleTransformIterator=t.TransformIterator=t.BufferedIterator=t.MappingIterator=t.DESTINATION=t.identity=t.IntegerIterator=t.ArrayIterator=t.SingletonIterator=t.EmptyIterator=t.AsyncIterator=t.DESTROYED=t.ENDED=t.CLOSED=t.CLOSING=t.OPEN=t.INIT=t.setTaskScheduler=t.getTaskScheduler=t.scheduleTask=t.LinkedList=void 0;const e=Ry(),u=gk();Object.defineProperty(t,"LinkedList",{enumerable:!0,get:function(){return u.LinkedList}});let n=_k().createTaskScheduler();function r(R){n(R)}t.scheduleTask=r;function a(){return n}t.getTaskScheduler=a;function o(R){n=R}t.setTaskScheduler=o,t.INIT=1,t.OPEN=2,t.CLOSING=4,t.CLOSED=8,t.ENDED=16,t.DESTROYED=32;class l extends e.EventEmitter{constructor(T=t.OPEN){super(),this._readable=!1,this._state=T,this.on("newListener",c)}_changeState(T,x=!1){const B=T>this._state&&this._statethis.emit("end")):this.emit("end"))),B}read(){return null}forEach(T,x){this.on("data",Ee(T,x))}close(){this._changeState(t.CLOSED)&&this._endAsync()}destroy(T){this.done||this._destroy(T,x=>{T=T||x,T&&this.emit("error",T),this._end(!0)})}_destroy(T,x){x()}_end(T=!1){this._changeState(T?t.DESTROYED:t.ENDED)&&(this._readable=!1,this.removeAllListeners("readable"),this.removeAllListeners("data"),this.removeAllListeners("end"))}_endAsync(){n(()=>this._end())}get readable(){return this._readable}set readable(T){T=!!T&&!this.done,this._readable!==T&&(this._readable=T,T&&n(()=>this.emit("readable")))}get closed(){return this._state>=t.CLOSING}get ended(){return this._state===t.ENDED}get destroyed(){return this._state===t.DESTROYED}get done(){return this._state>=t.ENDED}toString(){const T=this._toStringDetails();return`[${this.constructor.name}${T?` ${T}`:""}]`}_toStringDetails(){return""}toArray(T){const x=[],B=typeof(T==null?void 0:T.limit)=="number"?T.limit:1/0;return this.ended||B<=0?Promise.resolve(x):new Promise((k,V)=>{const J=()=>k(x),z=Y=>{x.push(Y),x.length>=B&&(this.removeListener("error",V),this.removeListener("data",z),this.removeListener("end",J),k(x))};this.on("error",V),this.on("data",z),this.on("end",J)})}getProperty(T,x){const B=this._properties;if(!x)return B&&B[T];if(B&&T in B)n(()=>x(B[T]));else{let k;(k=this._propertyCallbacks)||(this._propertyCallbacks=k=Object.create(null)),T in k?k[T].push(x):k[T]=[x]}}setProperty(T,x){const B=this._properties||(this._properties=Object.create(null));B[T]=x;const k=this._propertyCallbacks||{},V=k[T];if(V){delete k[T],n(()=>{for(const J of V)J(x)});for(T in k)return;delete this._propertyCallbacks}}getProperties(){const T=this._properties,x={};for(const B in T)x[B]=T[B];return x}setProperties(T){for(const x in T)this.setProperty(x,T[x])}copyProperties(T,x){for(const B of x)T.getProperty(B,k=>this.setProperty(B,k))}transform(T){return new E(this,T)}map(T,x){return new m(this,Ee(T,x))}filter(T,x){return this.map(function(B){return T.call(x||this,B)?B:null})}uniq(T=g){const x=new Set;return this.filter(function(B){const k=T.call(this,B);return x.has(k)?!1:(x.add(k),!0)})}prepend(T){return this.transform({prepend:T})}append(T){return this.transform({append:T})}surround(T,x){return this.transform({prepend:T,append:x})}skip(T){return this.map(x=>T-- >0?null:x)}take(T){return this.transform({limit:T})}range(T,x){return this.transform({offset:T,limit:Math.max(x-T+1,0)})}clone(){return new j(this)}[Symbol.asyncIterator](){const T=this;let x=null,B=null,k=null;T.addListener("readable",V),T.addListener("end",V),T.addListener("error",J);function V(){if(x!==null)if(k!==null)J(k);else if(T.done)x({done:!0,value:void 0}),x=B=null,z();else{const Y=T.read();Y!==null&&(x({done:!1,value:Y}),x=B=null)}}function J(Y){B!==null?(B(Y),x=B=k=null,z()):k===null&&(k=Y)}function z(){T.removeListener("readable",V),T.removeListener("end",V),T.removeListener("error",J)}return{next(){return new Promise((Y,re)=>{x=Y,B=re,V()})}}}}t.AsyncIterator=l;function c(R){R==="data"&&(this.removeListener("newListener",c),h(this,"readable",d),this.readable&&n(()=>d.call(this)))}function d(){let R;for(;this.listenerCount("data")!==0&&(R=this.read())!==null;)this.emit("data",R);this.listenerCount("data")===0&&!this.done&&(this.removeListener("readable",d),h(this,"newListener",c))}function h(R,T,x){R.listeners(T).includes(x)||R.on(T,x)}class f extends l{constructor(){super(),this._changeState(t.ENDED,!0)}}t.EmptyIterator=f;class p extends l{constructor(T){super(),this._item=T,T===null?this.close():this.readable=!0}read(){const T=this._item;return this._item=null,this.close(),T}_toStringDetails(){return this._item===null?"":`(${this._item})`}}t.SingletonIterator=p;class y extends l{constructor(T=[],{autoStart:x=!0,preserve:B=!0}={}){super();const k=B||!Array.isArray(T)?[...T]:T;this._index=0,this._sourceStarted=x!==!1,this._truncateThreshold=B?-1:64,this._sourceStarted&&k.length===0?this.close():this._buffer=k,this.readable=!0}read(){this._sourceStarted||(this._sourceStarted=!0);let T=null;return this._buffer&&(this._index=x&&this.close(),Promise.resolve(V)}}t.ArrayIterator=y;class b extends l{constructor({start:T=0,step:x=1,end:B}={}){super(),Number.isFinite(T)&&(T=Math.trunc(T)),this._next=T,Number.isFinite(x)&&(x=Math.trunc(x)),this._step=x;const k=x>=0,V=k?1/0:-1/0;Number.isFinite(B)?B=Math.trunc(B):B!==-V&&(B=V),this._last=B,!Number.isFinite(T)||(k?T>B:T=0?k>B:kthis._init(x)),this._sourceStarted=x!==!1}get maxBufferSize(){return this._maxBufferSize}set maxBufferSize(T){T!==1/0&&(T=Number.isFinite(T)?Math.max(Math.trunc(T),1):4),this._maxBufferSize!==T&&(this._maxBufferSize=T,this._state===t.OPEN&&this._fillBuffer())}_init(T){let x=!1;this._reading=!0,this._begin(()=>{if(x)throw new Error("done callback called multiple times");x=!0,this._reading=!1,this._changeState(t.OPEN),T?this._fillBufferAsync():this.readable=!0})}_begin(T){T()}read(){if(this.done)return null;this._sourceStarted||(this._sourceStarted=!0);const T=this._buffer;let x;return T.empty?(x=null,this.readable=!1):x=T.shift(),!this._reading&&T.length0&&(this._pushedCount=0,this._reading=!0,this._read(T,()=>{if(!T)throw new Error("done callback called multiple times");T=0,this._reading=!1,this.closed?this._completeClose():this._pushedCount&&(this.readable=!0,this._buffer.length{this._reading=!1,this._fillBuffer()}))}close(){this._reading?this._changeState(t.CLOSING):this._completeClose()}_completeClose(){this._changeState(t.CLOSED)&&(this._reading=!0,this._flush(()=>{if(!this._reading)throw new Error("done callback called multiple times");this._reading=!1,this._buffer.empty&&this._endAsync()}))}_destroy(T,x){this._buffer.clear(),x()}_flush(T){T()}_toStringDetails(){const T=this._buffer;return`{${T.empty?"":`next: ${T.first}, `}buffer: ${T.length}}`}}t.BufferedIterator=_;class w extends _{constructor(T,x=T||{}){super(x),this._boundPush=B=>this._push(B),fe(T)||(T=x.source),ge(T)?this.source=T:T&&(this._createSource=de(T)?()=>T:T,this._sourceStarted&&this._loadSourceAsync()),this._optional=!!x.optional,this._destroySource=x.destroySource!==!1}get source(){return De(this._createSource)&&this._loadSourceAsync(),this._source}set source(T){const x=this._source=this._validateSource(T);x[t.DESTINATION]=this,this.done?this._destroySource&&x.destroy():x.done?this.close():(x.on("end",L),x.on("readable",O),x.on("error",A))}_loadSourceAsync(){De(this._createSource)&&(Promise.resolve(this._createSource()).then(T=>{delete this._createSource,this.source=T,this._fillBuffer()},T=>this.emit("error",T)),this._createSource=null)}_validateSource(T,x=!1){if(this._source||typeof this._createSource<"u")throw new Error("The source cannot be changed after it has been set");return v(T,x)}_read(T,x){const B=()=>{this._pushedCountthis._readAndTransform(B,x)):x()};this._readAndTransform(B,x)}_readAndTransform(T,x){let B;const k=this.source;!k||k.done||(B=k.read())===null?x():this._optional?this._optionalTransform(B,T):this._transform(B,T,this._boundPush)}_optionalTransform(T,x){const B=this._pushedCount;this._transform(T,()=>{B===this._pushedCount&&this._push(T),x()},this._boundPush)}_transform(T,x,B){B(T),x()}_closeWhenDone(){this.close()}_end(T){const x=this._source;x&&(x.removeListener("end",L),x.removeListener("error",A),x.removeListener("readable",O),delete x[t.DESTINATION],this._destroySource&&x.destroy()),super._end(T)}}t.TransformIterator=w;function S(){this[t.DESTINATION].readable=!0}function A(R){this[t.DESTINATION].emit("error",R)}function D(){this[t.DESTINATION].close()}function L(){this[t.DESTINATION]._closeWhenDone()}function O(){this[t.DESTINATION]._sourceStarted!==!1&&this[t.DESTINATION]._fillBuffer()}class E extends w{constructor(T,x){if(super(T,x),this._offset=0,this._limit=1/0,this._filter=B=>!0,x=x||(fe(T)?null:T),x){const B=De(x)?x:x.transform,{limit:k,offset:V,filter:J,map:z,prepend:Y,append:re}=x;V===1/0||k===-1/0?this._limit=0:(Number.isFinite(V)&&(this._offset=Math.max(Math.trunc(V),0)),Number.isFinite(k)&&(this._limit=Math.max(Math.trunc(k),0)),De(J)&&(this._filter=J),De(z)&&(this._map=z),this._transform=De(B)?B:null),Y&&(this._prepender=ge(Y)?Y:K(Y)),re&&(this._appender=ge(re)?re:K(re))}}_read(T,x){const B=()=>this._readAndTransformSimple(T,k,x);this._readAndTransformSimple(T,k,x);function k(){n(B)}}_readAndTransformSimple(T,x,B){let k;const{source:V}=this;if(!V||V.done){B();return}for(this._limit===0&&this.close();!this.closed&&this._pushedCount"u"?k:this._map(k);if(J===null)this._optional&&this._push(k);else if(!De(this._transform))this._push(J);else{this._optional?this._optionalTransform(J,x):this._transform(J,x,this._boundPush);return}--this._limit===0&&this.close()}B()}_begin(T){this._insert(this._prepender,T),delete this._prepender}_flush(T){this._insert(this._appender,T),delete this._appender}_insert(T,x){const B=V=>this._push(V);!T||T.done?x():(T.on("data",B),T.on("end",k));function k(){T.removeListener("data",B),T.removeListener("end",k),x()}}}t.SimpleTransformIterator=E;class P extends w{constructor(T,x){if(super(T,x),this._transformerQueue=[],x){const B=De(x)?x:x.multiTransform;B&&(this._createTransformer=B)}}_read(T,x){const B=this._transformerQueue,k=this._optional;let V,J;for(;(V=B[0])&&V.transformer.done;){k&&V.item!==null&&(T--,this._push(V.item)),B.shift();const{transformer:Y}=V;Y.removeListener("end",O),Y.removeListener("readable",O),Y.removeListener("error",A)}const{source:z}=this;for(;z&&!z.done&&B.length0&&(J=Y.read())!==null;)this._push(J),k&&(V.item=null)}else z&&z.done&&this.close();x()}_createTransformer(T){return new p(T)}_closeWhenDone(){this._transformerQueue.length||this.close()}_end(T){if(super._end(T),this._destroySource)for(const x of this._transformerQueue)x.transformer.destroy()}}t.MultiTransformIterator=P;class M extends _{constructor(T,x={}){super(x),this._sources=[],this._currentSource=-1;const B=x.autoStart!==!1;if(ge(T))T.on("error",k=>this.emit("error",k)),this._pending={loading:!1,sources:T},B&&this._loadSources();else if(Array.isArray(T)&&T.length>0)for(const k of T)this._addSource(k);else B&&this.close();this._destroySources=x.destroySources!==!1}_loadSources(){const T=this._pending.sources;this._pending.loading=!0,T.done?(delete this._pending,this.close()):(T.on("data",x=>{this._addSource(x),this._fillBufferAsync()}),T.on("end",()=>{delete this._pending,this._fillBuffer()}))}_addSource(T){de(T)&&(T=Z(T)),T.done||(this._sources.push(T),T[t.DESTINATION]=this,T.on("error",A),T.on("readable",O),T.on("end",U))}_removeEmptySources(){this._sources=this._sources.filter((T,x)=>(T.done&&x<=this._currentSource&&this._currentSource--,!T.done)),this._fillBuffer()}_read(T,x){var B;((B=this._pending)===null||B===void 0?void 0:B.loading)===!1&&this._loadSources();let k=0,V;for(;k!==(k=T);)for(let J=0;J0;J++)this._currentSource=(this._currentSource+1)%this._sources.length,(V=this._sources[this._currentSource].read())!==null&&(T--,this._push(V));!this._pending&&this._sources.length===0&&this.close(),x()}_end(T=!1){if(super._end(T),this._destroySources){for(const x of this._sources)x.destroy();this._pending&&(this._pending.sources.destroy(),delete this._pending)}}}t.UnionIterator=M;function U(){this[t.DESTINATION]._removeEmptySources()}class j extends w{constructor(T){super(T,{autoStart:!1}),this._readPosition=0,this._reading=!1,T&&(this.readable=!0)}_init(){}close(){l.prototype.close.call(this)}get source(){return super.source}set source(T){const x=this._source=this._validateSource(T),B=x&&x[t.DESTINATION]||(x[t.DESTINATION]=new q(x));this.done?this._destroySource&&x.destroy():B.endsAt(0)?this.close():(B.register(this),(x._sourceStarted===!1||B.readAt(0)!==null)&&(this.readable=!0));const k=this._propertyCallbacks;for(const V in k){const J=k[V];for(const z of J)this._getSourceProperty(V,z)}}_validateSource(T,x=!1){const B=T&&T[t.DESTINATION];return super._validateSource(T,!B||B instanceof q)}getProperty(T,x){const{source:B}=this,k=this._properties,V=k&&T in k;if(!x)return V?k&&k[T]:B&&B.getProperty(T);super.getProperty(T,x),B&&!V&&this._getSourceProperty(T,x)}_getSourceProperty(T,x){this.source.getProperty(T,B=>{(!this._properties||!(T in this._properties))&&x(B)})}getProperties(){const T=this.source?this.source.getProperties():{},x=this._properties;for(const B in x)T[B]=x[B];return T}_toStringDetails(){return`{source: ${this.source?this.source.toString():"none"}}`}read(){this._sourceStarted||(this._sourceStarted=!0);const T=this.source;let x=null;if(!this.done&&T){const B=T[t.DESTINATION];(x=B.readAt(this._readPosition))!==null?this._readPosition++:this.readable=!1,B.endsAt(this._readPosition)&&this.close()}return x}_end(T){const x=this.source,B=x==null?void 0:x[t.DESTINATION];B&&B.unregister(this),_.prototype._end.call(this,T)}}t.ClonedIterator=j;class q{constructor(T){if(this._history=[],this._trackers=new Set,this._source=T,!T.done){const x=()=>{for(const V of this._trackers)V.readable=!0},B=V=>{for(const J of this._trackers)J.emit("error",V)},k=()=>{for(const V of this._trackers)V._sourceStarted!==!1&&V._readPosition===this._history.length&&V.close();this._trackers.clear(),T.removeListener("end",k),T.removeListener("error",B),T.removeListener("readable",x)};T.on("end",k),T.on("error",B),T.on("readable",x)}}register(T){this._source.done||this._trackers.add(T)}unregister(T){this._trackers.delete(T)}readAt(T){let x=null;return T{this._source=null,this.source=B}).catch(B=>this.emit("error",B))):T&&(this.source=T)}set source(T){let x=T;if(this._source!==null)throw new Error("The source cannot be changed after it has been set");if(H(x)&&(x=x[Symbol.iterator]()),N(x)){let B=x;x=new e.EventEmitter,x.read=()=>{if(B!==null){let k;for(;!(k=B.next()).done;)if(k.value!==null)return k.value;B=null,this.close()}return null}}else x=v(x);if(this.done){this._destroySource&&De(x.destroy)&&x.destroy();return}x[t.DESTINATION]=this,x.on("end",D),x.on("error",A),x.on("readable",S),this._source=x,this.readable=x.readable!==!1}read(){if(this._source!==null&&this._source.readable!==!1){const T=this._source.read();if(T!==null)return T;this.readable=!1}return null}_end(T=!1){this._source!==null&&(this._source.removeListener("end",D),this._source.removeListener("error",A),this._source.removeListener("readable",S),delete this._source[t.DESTINATION],this._destroySource&&De(this._source.destroy)&&this._source.destroy(),this._source=null),super._end(T)}}t.WrappingIterator=$;function Z(R,T){if(T&&("autoStart"in T||"optional"in T||"source"in T||"maxBufferSize"in T))return R&&!ge(R)&&(R=new $(R)),new w(R,T);if(!R)return X();if(de(R))return new $(R,T);if(R instanceof l)return R;if(Array.isArray(R))return K(R);if(H(R)||N(R)||ge(R))return new $(R,T);throw new TypeError(`Invalid source: ${R}`)}t.wrap=Z;function X(){return new f}t.empty=X;function le(R){return new p(R)}t.single=le;function K(R){return new y(R)}t.fromArray=K;function he(R){return new $(R)}t.fromIterator=he;function Re(R){return new $(R)}t.fromIterable=Re;function ie(R){return new M(R)}t.union=ie;function ae(R,T,x){return new b({start:R,end:T,step:x})}t.range=ae;function Ee(R,T){return T?R.bind(T):R}function De(R){return typeof R=="function"}t.isFunction=De;function ge(R){return De(R==null?void 0:R.on)}t.isEventEmitter=ge;function de(R){return De(R==null?void 0:R.then)}t.isPromise=de;function fe(R){return R&&(ge(R)||de(R)||De(R))}t.isSourceExpression=fe;function H(R){return R&&Symbol.iterator in R}t.isIterable=H;function N(R){return De(R==null?void 0:R.next)}t.isIterator=N}(xg)),xg}var uR;function vk(){if(uR)return Cu;uR=1,Object.defineProperty(Cu,"__esModule",{value:!0}),Cu.ClosableIterator=void 0;const t=Dt();let e=class extends t.AsyncIterator{constructor(a,o){super(),this.onClose=o.onClose,this._source=a,this._source[t.DESTINATION]=this,this._source.on("end",n),this._source.on("error",s),this._source.on("readable",u),this.readable=this._source.readable}read(){const a=this._source.read();return a||(this.readable=!1,this._source.done&&this.close()),a}_end(a){this.onClose(),this._source.removeListener("end",n),this._source.removeListener("error",s),this._source.removeListener("readable",u),delete this._source[t.DESTINATION],this._source.destroy(),super._end(a)}};Cu.ClosableIterator=e;function u(){this[t.DESTINATION].readable=!0}function s(r){this[t.DESTINATION].emit("error",r)}function n(){this[t.DESTINATION].close()}return Cu}var Mu={},cR;function wk(){if(cR)return Mu;cR=1,Object.defineProperty(Mu,"__esModule",{value:!0}),Mu.ClosableTransformIterator=void 0;const t=Dt();let e=class extends t.TransformIterator{constructor(s,n){super(s,n),this.onClose=n.onClose}_end(s){this.onClose(),super._end(s)}};return Mu.ClosableTransformIterator=e,Mu}var lR;function wt(){return lR||(lR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(oq(),t),u(uq(),t),u(bk(),t),u(sq(),t),u(mk(),t),u(vk(),t),u(wk(),t)}(ig)),ig}var Ig={},Fu={},Pg={},qu={},dR;function Sk(){if(dR)return qu;dR=1,Object.defineProperty(qu,"__esModule",{value:!0}),qu.ActorContextPreprocess=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return qu.ActorContextPreprocess=e,qu}var fR;function xy(){return fR||(fR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Sk(),t)}(Pg)),Pg}var hR;function Tk(){if(hR)return Fu;hR=1,Object.defineProperty(Fu,"__esModule",{value:!0}),Fu.ActorContextPreprocessConvertShortcuts=void 0;const t=xy(),e=ot;let u=class cq extends t.ActorContextPreprocess{constructor(n){super(n)}async test(n){return!0}async run(n){return{context:cq.expandShortcuts(n.context,this.contextKeyShortcuts)}}static expandShortcuts(n,r){for(const a of n.keys())r[a.name]&&(n=n.set(new e.ActionContextKey(r[a.name]),n.get(a)).delete(a));return n}};return Fu.ActorContextPreprocessConvertShortcuts=u,Fu}var pR;function Ak(){return pR||(pR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Tk(),t)}(Ig)),Ig}var Dg={},Bu={},yR;function Ek(){if(yR)return Bu;yR=1,Object.defineProperty(Bu,"__esModule",{value:!0}),Bu.ActorContextPreprocessSetDefaults=void 0;const t=xy(),e=Lt;let u=class extends t.ActorContextPreprocess{constructor(n){super(n),this.defaultFunctionArgumentsCache={}}async test(n){return!0}async run(n){let r=n.context;if(n.initialize){r=r.setDefault(e.KeysInitQuery.queryTimestamp,new Date).setDefault(e.KeysQuerySourceIdentify.sourceIds,new Map).setDefault(e.KeysCore.log,this.logger).setDefault(e.KeysInitQuery.functionArgumentsCache,this.defaultFunctionArgumentsCache).setDefault(e.KeysQuerySourceIdentify.hypermediaSourcesAggregatedStores,new Map);let a={language:"sparql",version:"1.1"};r.has(e.KeysInitQuery.queryFormat)?(a=r.get(e.KeysInitQuery.queryFormat),a.language==="graphql"&&(r=r.setDefault(e.KeysInitQuery.graphqlSingularizeVariables,{}))):r=r.set(e.KeysInitQuery.queryFormat,a)}return{context:r}}};return Bu.ActorContextPreprocessSetDefaults=u,Bu}var bR;function Ok(){return bR||(bR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Ek(),t)}(Dg)),Dg}var Ng={},Uu={},mR;function Rk(){if(mR)return Uu;mR=1,Object.defineProperty(Uu,"__esModule",{value:!0}),Uu.ActorContextPreprocessSourceToDestination=void 0;const t=xy(),e=Lt;let u=class extends t.ActorContextPreprocess{constructor(n){super(n)}async test(n){return!0}async run(n){if(n.context.get(e.KeysInitQuery.querySourcesUnidentified)&&!n.context.get(e.KeysRdfUpdateQuads.destination)){const r=n.context.get(e.KeysInitQuery.querySourcesUnidentified);if(r.length===1)return{context:n.context.set(e.KeysRdfUpdateQuads.destination,r[0])}}return n}};return Uu.ActorContextPreprocessSourceToDestination=u,Uu}var gR;function xk(){return gR||(gR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Rk(),t)}(Ng)),Ng}var Cg={},Qu={},Hu={},jg={},_R;function $T(){return _R||(_R=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.deskolemizeOperation=t.deskolemizeQuad=t.deskolemizeTermNestedThrowing=t.deskolemizeTerm=t.skolemizeBindingsStream=t.skolemizeQuadStream=t.skolemizeBindings=t.skolemizeQuad=t.skolemizeTerm=t.getSourceId=t.SKOLEM_PREFIX=void 0;const e=UT(),u=Et(),s=un(),n=Ot(),r=new u.DataFactory;t.SKOLEM_PREFIX="urn:comunica_skolem:source_";function a(g,m){let v=g.get(m.referenceValue);return v===void 0&&(v=`${g.size}`,g.set(m.referenceValue,v)),v}t.getSourceId=a;function o(g,m){return g.termType==="BlankNode"?new e.BlankNodeScoped(`bc_${m}_${g.value}`,r.namedNode(`${t.SKOLEM_PREFIX}${m}:${g.value}`)):g}t.skolemizeTerm=o;function l(g,m){return(0,s.mapTermsNested)(g,v=>o(v,m))}t.skolemizeQuad=l;function c(g,m){return g.map(v=>v.termType==="Quad"?l(v,m):o(v,m))}t.skolemizeBindings=c;function d(g,m){const v=g.map(w=>l(w,m));function _(){g.getProperty("metadata",w=>{v.setProperty("metadata",w),w.state.addInvalidateListener(_)})}return _(),v}t.skolemizeQuadStream=d;function h(g,m){const v=g.map(w=>c(w,m));function _(){g.getProperty("metadata",w=>{v.setProperty("metadata",w),w.state.addInvalidateListener(_)})}return _(),v}t.skolemizeBindingsStream=h;function f(g,m){if(g.termType==="BlankNode"&&"skolemized"in g&&(g=g.skolemized),g.termType==="NamedNode"&&g.value.startsWith(t.SKOLEM_PREFIX)){const v=g.value.indexOf(":",t.SKOLEM_PREFIX.length);if(g.value.slice(t.SKOLEM_PREFIX.length,v)===m){const w=g.value.slice(v+1,g.value.length);return r.blankNode(w)}return null}return g}t.deskolemizeTerm=f;function p(g,m){if(g.termType==="Quad")return(0,s.mapTermsNested)(g,_=>{const w=f(_,m);if(!w)throw new Error("Skolemized term is not in scope for this source");return w});const v=f(g,m);if(v===null)throw new Error("Skolemized term is not in scope for this source");return v}t.deskolemizeTermNestedThrowing=p;function y(g,m){return(0,s.mapTermsNested)(g,v=>f(v,m)??v)}t.deskolemizeQuad=y;function b(g,m){try{return n.Util.mapOperation(g,{[n.Algebra.types.PATTERN](v,_){return{result:Object.assign(_.createPattern(p(v.subject,m),p(v.predicate,m),p(v.object,m),p(v.graph,m)),{metadata:v.metadata}),recurse:!1}},[n.Algebra.types.PATH](v,_){return{result:Object.assign(_.createPath(p(v.subject,m),v.predicate,p(v.object,m),p(v.graph,m)),{metadata:v.metadata}),recurse:!1}}})}catch{}}t.deskolemizeOperation=b}(jg)),jg}var vR;function lq(){if(vR)return Hu;vR=1,Object.defineProperty(Hu,"__esModule",{value:!0}),Hu.QuerySourceSkolemized=void 0;const t=Cn(),e=Dt(),u=$T();let s=class{constructor(r,a){this.innerSource=r,this.sourceId=a}async getSelectorShape(r){return this.innerSource.getSelectorShape(r)}queryBindings(r,a,o){const l=(0,u.deskolemizeOperation)(r,this.sourceId);if(!l){const c=new e.ArrayIterator([],{autoStart:!1});return c.setProperty("metadata",{state:new t.MetadataValidationState,cardinality:{type:"exact",value:0},canContainUndefs:!1,variables:[]}),c}return(0,u.skolemizeBindingsStream)(this.innerSource.queryBindings(l,a,o),this.sourceId)}queryBoolean(r,a){return this.innerSource.queryBoolean(r,a)}queryQuads(r,a){const o=(0,u.deskolemizeOperation)(r,this.sourceId);if(!o){const l=new e.ArrayIterator([],{autoStart:!1});return l.setProperty("metadata",{state:new t.MetadataValidationState,cardinality:{type:"exact",value:0}}),l}return(0,u.skolemizeQuadStream)(this.innerSource.queryQuads(o,a),this.sourceId)}queryVoid(r,a){return this.innerSource.queryVoid(r,a)}get referenceValue(){return this.innerSource.referenceValue}toString(){return`${this.innerSource.toString()}(SkolemID:${this.sourceId})`}};return Hu.QuerySourceSkolemized=s,Hu}var wR;function Ik(){if(wR)return Qu;wR=1,Object.defineProperty(Qu,"__esModule",{value:!0}),Qu.ActorContextPreprocessQuerySourceSkolemize=void 0;const t=xy(),e=Lt,u=lq(),s=$T();let n=class extends t.ActorContextPreprocess{constructor(a){super(a)}async test(a){return!0}async run(a){let o=a.context;if(o.has(e.KeysQueryOperation.querySources)){o.has(e.KeysQuerySourceIdentify.sourceIds)||(o=o.set(e.KeysQuerySourceIdentify.sourceIds,new Map));const l=o.getSafe(e.KeysQuerySourceIdentify.sourceIds);let c=o.getSafe(e.KeysQueryOperation.querySources);c=c.map(d=>({source:new u.QuerySourceSkolemized(d.source,(0,s.getSourceId)(l,d.source)),context:d.context})),o=o.set(e.KeysQueryOperation.querySources,c)}return{context:o}}};return Qu.ActorContextPreprocessQuerySourceSkolemize=n,Qu}var SR;function dq(){return SR||(SR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Ik(),t),u(lq(),t),u($T(),t)}(Cg)),Cg}var Lg={},$u={},TR;function Pk(){if(TR)return $u;TR=1,Object.defineProperty($u,"__esModule",{value:!0}),$u.MediatorCombinePipeline=void 0;const t=ot;let e=class extends t.Mediator{constructor(s){super(s)}async mediate(s){let n;try{n=this.publish(s)}catch{return s}if(this.filterErrors){const a=[];for(const o of n)try{await o.reply,a.push(o)}catch{}n=a}if(n=await Promise.all(n.map(async({actor:a,reply:o})=>({actor:a,reply:await o}))),this.order){const a=o=>{const l=this.field?o[this.field]:o;if(typeof l!="number")throw new TypeError("Cannot order elements that are not numbers.");return l};n=n.sort((o,l)=>(this.order==="increasing"?1:-1)*(a(o.reply)-a(l.reply)))}let r=s;for(const{actor:a}of n)r={...r,...await a.runObservable(r)};return r}mediateWith(){throw new Error("Method not supported.")}};return $u.MediatorCombinePipeline=e,$u}var AR;function ER(){return AR||(AR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Pk(),t)}(Lg)),Lg}var Mg={},Vu={},Fg={},ku={},OR;function Dk(){if(OR)return ku;OR=1,Object.defineProperty(ku,"__esModule",{value:!0}),ku.ActorHashBindings=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return ku.ActorHashBindings=e,ku}var RR;function Nk(){return RR||(RR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Dk(),t)}(Fg)),Fg}var qg,xR;function Ck(){return xR||(xR=1,qg=function t(e){if(typeof e=="number"&&isNaN(e))throw new Error("NaN is not allowed");if(typeof e=="number"&&!isFinite(e))throw new Error("Infinity is not allowed");return e===null||typeof e!="object"?JSON.stringify(e):e.toJSON instanceof Function?t(e.toJSON()):Array.isArray(e)?`[${e.reduce((n,r,a)=>`${n}${a===0?"":","}${t(r===void 0||typeof r=="symbol"?null:r)}`,"")}]`:`{${Object.keys(e).sort().reduce((s,n)=>{if(e[n]===void 0||typeof e[n]=="symbol")return s;const r=s.length===0?"":",";return`${s}${r}${t(n)}:${t(e[n])}`},"")}}`}),qg}var IR;function jk(){if(IR)return Vu;IR=1,Object.defineProperty(Vu,"__esModule",{value:!0}),Vu.ActorHashBindingsSha1=void 0;const t=Nk(),e=kb(),u=Xt(),s=Ck();let n=class extends t.ActorHashBindings{async test(a){if(!a.allowHashCollisions)throw new Error(`Actor ${this.name} can not provide hash functions without hash collisions`);return!0}async run(a){return{hashFunction:o=>(0,e.sha1)().update(s(Object.fromEntries([...o].map(([l,c])=>[(0,u.termToString)(l),(0,u.termToString)(c)])))).digest("hex"),hashCollisions:!0}}};return Vu.ActorHashBindingsSha1=n,Vu}var PR;function Lk(){return PR||(PR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(jk(),t)}(Mg)),Mg}var Bg={},zu={},DR;function Mk(){if(DR)return zu;DR=1,Object.defineProperty(zu,"__esModule",{value:!0}),zu.MediatorRace=void 0;const t=ot;let e=class extends t.Mediator{constructor(s){super(s)}mediateWith(s,n){return new Promise((r,a)=>{const o=[];for(const l of n)l.reply.then(()=>{r(l.actor)}).catch(c=>{o.push(c),o.length===n.length&&a(new Error(`${this.name} mediated over all rejecting actors: +${o.map(d=>d.message).join(` +`)}`))})})}};return zu.MediatorRace=e,zu}var NR;function cn(){return NR||(NR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Mk(),t)}(Bg)),Bg}var Ug={},Gu={},Qg={},Wu={},CR;function Fk(){if(CR)return Wu;CR=1,Object.defineProperty(Wu,"__esModule",{value:!0}),Wu.ActorHashQuads=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return Wu.ActorHashQuads=e,Wu}var jR;function qk(){return jR||(jR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Fk(),t)}(Qg)),Qg}var LR;function Bk(){if(LR)return Gu;LR=1,Object.defineProperty(Gu,"__esModule",{value:!0}),Gu.ActorHashQuadsSha1=void 0;const t=qk(),e=kb(),u=Xt();let s=class extends t.ActorHashQuads{async test(r){if(!r.allowHashCollisions)throw new Error(`Actor ${this.name} can not provide hash functions without hash collisions`);return!0}async run(r){return{hashFunction:a=>(0,e.sha1)().update(JSON.stringify((0,u.quadToStringQuad)(a))).digest("hex"),hashCollisions:!0}}};return Gu.ActorHashQuadsSha1=s,Gu}var MR;function Uk(){return MR||(MR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Bk(),t)}(Ug)),Ug}var Hg={},Ju={},$g={},Xu={},FR;function Qk(){if(FR)return Xu;FR=1,Object.defineProperty(Xu,"__esModule",{value:!0}),Xu.ActorOptimizeQueryOperation=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return Xu.ActorOptimizeQueryOperation=e,Xu}var qR;function di(){return qR||(qR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Qk(),t)}($g)),$g}var BR;function Hk(){if(BR)return Ju;BR=1,Object.defineProperty(Ju,"__esModule",{value:!0}),Ju.ActorOptimizeQueryOperationRewriteCopy=void 0;const t=di(),e=Ot();let u=class extends t.ActorOptimizeQueryOperation{constructor(n){super(n)}async test(n){return!0}async run(n){return{operation:e.Util.mapOperation(n.operation,{[e.Algebra.types.COPY](a,o){let l;return typeof a.destination=="string"&&typeof a.source=="string"&&a.destination===a.source||typeof a.destination!="string"&&typeof a.source!="string"&&a.destination.equals(a.source)?l=o.createCompositeUpdate([]):l=o.createCompositeUpdate([o.createDrop(a.destination,!0),o.createAdd(a.source,a.destination,a.silent)]),{result:l,recurse:!1}}}),context:n.context}}};return Ju.ActorOptimizeQueryOperationRewriteCopy=u,Ju}var UR;function $k(){return UR||(UR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Hk(),t)}(Hg)),Hg}var Vg={},Ku={},QR;function Vk(){if(QR)return Ku;QR=1,Object.defineProperty(Ku,"__esModule",{value:!0}),Ku.ActorOptimizeQueryOperationRewriteMove=void 0;const t=di(),e=Ot();let u=class extends t.ActorOptimizeQueryOperation{constructor(n){super(n)}async test(n){return!0}async run(n){return{operation:e.Util.mapOperation(n.operation,{[e.Algebra.types.MOVE](a,o){let l;if(typeof a.destination=="string"&&typeof a.source=="string"&&a.destination===a.source||typeof a.destination!="string"&&typeof a.source!="string"&&a.destination.equals(a.source))l=o.createCompositeUpdate([]);else{const c=[o.createDrop(a.destination,!0),o.createAdd(a.source,a.destination,a.silent),o.createDrop(a.source)];l=o.createCompositeUpdate(c)}return{result:l,recurse:!1}}}),context:n.context}}};return Ku.ActorOptimizeQueryOperationRewriteMove=u,Ku}var HR;function kk(){return HR||(HR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Vk(),t)}(Vg)),Vg}var kg={},Yu={},$R;function zk(){if($R)return Yu;$R=1,Object.defineProperty(Yu,"__esModule",{value:!0}),Yu.ActorOptimizeQueryOperationRewriteAdd=void 0;const t=di(),e=Et(),u=Ot(),s=new e.DataFactory;let n=class extends t.ActorOptimizeQueryOperation{constructor(a){super(a)}async test(a){return!0}async run(a){return{operation:u.Util.mapOperation(a.operation,{[u.Algebra.types.ADD](l,c){const d=l.destination==="DEFAULT"?s.defaultGraph():l.destination,h=l.source==="DEFAULT"?s.defaultGraph():l.source;return{result:c.createDeleteInsert(void 0,[c.createPattern(s.variable("s"),s.variable("p"),s.variable("o"),d)],c.createPattern(s.variable("s"),s.variable("p"),s.variable("o"),h)),recurse:!1}}}),context:a.context}}};return Yu.ActorOptimizeQueryOperationRewriteAdd=n,Yu}var VR;function Gk(){return VR||(VR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(zk(),t)}(kg)),kg}var zg={},Zu={},kR;function Wk(){if(kR)return Zu;kR=1,Object.defineProperty(Zu,"__esModule",{value:!0}),Zu.ActorOptimizeQueryOperationGroupSources=void 0;const t=di(),e=wt(),u=Ot(),s=new u.Factory;let n=class extends t.ActorOptimizeQueryOperation{constructor(a){super(a)}async test(a){if(e.ActorQueryOperation.getOperationSource(a.operation))throw new Error(`Actor ${this.name} does not work with top-level operation sources.`);return!0}async run(a){return{operation:await this.groupOperation(a.operation,a.context),context:a.context}}async groupOperation(a,o){var h;if(e.ActorQueryOperation.getOperationSource(a)??!("input"in a))return a;if(!Array.isArray(a.input)){const f=await this.groupOperation(a.input,o);if((h=f.metadata)!=null&&h.scopedSource){const p=e.ActorQueryOperation.getOperationSource(f);e.ActorQueryOperation.doesShapeAcceptOperation(await p.source.getSelectorShape(o),a)&&(this.logDebug(o,`Hoist 1 source-specific operation into a single ${a.type} operation for ${p.source.toString()}`),e.ActorQueryOperation.removeOperationSource(f),a=e.ActorQueryOperation.assignOperationSource(a,p))}return{...a,input:f}}const l=await Promise.all(a.input.map(f=>this.groupOperation(f,o))),c=this.clusterOperationsWithEqualSources(l);if(c.length===1){const f=c[0],p=e.ActorQueryOperation.getOperationSource(c[0][0]);return{...await this.moveSourceAnnotationUpwardsIfPossible(a,f,p,o),input:f}}if(c.length===l.length)return{...a,input:l};let d;switch(a.type){case u.Algebra.types.JOIN:d=s.createJoin.bind(s);break;case u.Algebra.types.UNION:d=s.createUnion.bind(s);break;case u.Algebra.types.ALT:d=s.createAlt.bind(s);break;case u.Algebra.types.SEQ:d=s.createSeq.bind(s);break;default:throw new Error(`Unsupported operation '${a.type}' detected while grouping sources`)}return await this.groupOperationMulti(c,d,o)}async groupOperationMulti(a,o,l){let c=!0;const d=await Promise.all(a.map(async h=>{const f=e.ActorQueryOperation.getOperationSource(h[0]),p=await this.moveSourceAnnotationUpwardsIfPossible(o(h,!0),h,f,l);return e.ActorQueryOperation.getOperationSource(p)&&(c=!1),p}));return o(d,c)}clusterOperationsWithEqualSources(a){const o=new Map,l=[];for(const d of a){const h=e.ActorQueryOperation.getOperationSource(d);h?(o.has(h)||o.set(h,[]),o.get(h).push(d)):l.push(d)}const c=[];l.length>0&&c.push(l);for(const[d,h]of o.entries())c.push(h.map(f=>e.ActorQueryOperation.assignOperationSource(f,d)));return c}async moveSourceAnnotationUpwardsIfPossible(a,o,l,c){if(l&&e.ActorQueryOperation.doesShapeAcceptOperation(await l.source.getSelectorShape(c),a)){this.logDebug(c,`Hoist ${o.length} source-specific operations into a single ${a.type} operation for ${l.source.toString()}`),a=e.ActorQueryOperation.assignOperationSource(a,l);for(const d of o)e.ActorQueryOperation.removeOperationSource(d)}return a}};return Zu.ActorOptimizeQueryOperationGroupSources=n,Zu}var zR;function Jk(){return zR||(zR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Wk(),t)}(zg)),zg}var Gg={},ec={},GR;function Xk(){if(GR)return ec;GR=1,Object.defineProperty(ec,"__esModule",{value:!0}),ec.ActorOptimizeQueryOperationConstructDistinct=void 0;const t=di(),e=tr,u=Ot();let s=class extends t.ActorOptimizeQueryOperation{constructor(r){super(r)}async test(r){if(!r.context.has(e.KeysInitQuery.distinctConstruct))throw new Error(`${this.name} was not enabled by the query.`);return!0}async run(r){return{operation:u.Util.mapOperation(r.operation,{construct(o,l){return{recurse:!1,result:l.createDistinct(l.createConstruct(o.input,o.template))}}}),context:r.context.delete(e.KeysInitQuery.distinctConstruct)}}};return ec.ActorOptimizeQueryOperationConstructDistinct=s,ec}var WR;function Kk(){return WR||(WR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Xk(),t)}(Gg)),Gg}var Wg={},tc={},Jg={},rc={},JR;function Yk(){if(JR)return rc;JR=1,Object.defineProperty(rc,"__esModule",{value:!0}),rc.ActorQueryParse=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return rc.ActorQueryParse=e,rc}var XR;function fq(){return XR||(XR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Yk(),t)}(Jg)),Jg}var KR;function Zk(){if(KR)return tc;KR=1,Object.defineProperty(tc,"__esModule",{value:!0}),tc.ActorQueryParseSparql=void 0;const t=fq(),e=Ot(),u=Ay();let s=class extends t.ActorQueryParse{constructor(r){super(r),this.prefixes=Object.freeze(this.prefixes)}async test(r){if(r.queryFormat&&r.queryFormat.language!=="sparql")throw new Error("This actor can only parse SPARQL queries");return!0}async run(r){const o=new u.Parser({prefixes:this.prefixes,baseIRI:r.baseIRI,sparqlStar:!0}).parse(r.query);return{baseIRI:o.type==="query"?o.base:void 0,operation:(0,e.translate)(o,{quads:!0,prefixes:this.prefixes,blankToVariable:!0,baseIRI:r.baseIRI})}}};return tc.ActorQueryParseSparql=s,tc}var YR;function ez(){return YR||(YR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Zk(),t)}(Wg)),Wg}var Xg={},nc={},Kg={},Yg={},Zg={},ic={},ZR;function nu(){if(ZR)return ic;ZR=1,Object.defineProperty(ic,"__esModule",{value:!0}),ic.DirectiveNodeHandlerAdapter=void 0;let t=class{constructor(u,s,n){this.targetKind=u,this.util=s,this.settings=n}getDirectiveConditionalValue(u,s){const n=this.util.getArgument(u.arguments,"if");if(!n)throw new Error(`The directive ${u.name.value} is missing an if-argument.`);const r=this.util.handleNodeValue(n.value,n.name.value,s);if(r.terms.length!==1)throw new Error(`Can not apply the directive ${u.name.value} with a list.`);return r.terms[0]}isDirectiveScopeAll(u){const s=this.util.getArgument(u.arguments,"scope");return s&&s.value.kind==="EnumValue"&&s.value.value==="all"}};return ic.DirectiveNodeHandlerAdapter=t,ic}var ac={},ex;function tz(){if(ex)return ac;ex=1,Object.defineProperty(ac,"__esModule",{value:!0}),ac.DirectiveNodeHandlerInclude=void 0;const t=nu();let e=class extends t.DirectiveNodeHandlerAdapter{constructor(s,n){super("include",s,n)}handle(s,n){const r=this.getDirectiveConditionalValue(s.directive,n);return r.termType==="Literal"&&r.value==="false"?{ignore:!0}:{}}};return ac.DirectiveNodeHandlerInclude=e,ac}var sc={},tx;function rz(){if(tx)return sc;tx=1,Object.defineProperty(sc,"__esModule",{value:!0}),sc.DirectiveNodeHandlerOptional=void 0;const t=nu();let e=class extends t.DirectiveNodeHandlerAdapter{constructor(s,n){super("optional",s,n)}handle(s,n){return{operationOverrider:r=>this.util.operationFactory.createLeftJoin(this.util.operationFactory.createBgp([]),r)}}};return sc.DirectiveNodeHandlerOptional=e,sc}var oc={},e_={},rx;function Iy(){return rx||(rx=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.SingularizeState=void 0,function(e){e[e.SINGLE=0]="SINGLE",e[e.PLURAL=1]="PLURAL"}(t.SingularizeState||(t.SingularizeState={}))}(e_)),e_}var nx;function nz(){if(nx)return oc;nx=1,Object.defineProperty(oc,"__esModule",{value:!0}),oc.DirectiveNodeHandlerPlural=void 0;const t=Iy(),e=nu();let u=class extends e.DirectiveNodeHandlerAdapter{constructor(n,r){super("plural",n,r)}handle(n,r){return this.isDirectiveScopeAll(n.directive)&&(r.singularizeState=t.SingularizeState.PLURAL),delete r.singularizeVariables[this.util.nameToVariable(n.fieldLabel,r).value],{}}};return oc.DirectiveNodeHandlerPlural=u,oc}var uc={},ix;function iz(){if(ix)return uc;ix=1,Object.defineProperty(uc,"__esModule",{value:!0}),uc.DirectiveNodeHandlerSingle=void 0;const t=Iy(),e=nu();let u=class extends e.DirectiveNodeHandlerAdapter{constructor(n,r){super("single",n,r)}handle(n,r){return this.isDirectiveScopeAll(n.directive)&&(r.singularizeState=t.SingularizeState.SINGLE),r.singularizeVariables[this.util.nameToVariable(n.fieldLabel,r).value]=!0,{}}};return uc.DirectiveNodeHandlerSingle=u,uc}var cc={},ax;function az(){if(ax)return cc;ax=1,Object.defineProperty(cc,"__esModule",{value:!0}),cc.DirectiveNodeHandlerSkip=void 0;const t=nu();let e=class extends t.DirectiveNodeHandlerAdapter{constructor(s,n){super("skip",s,n)}handle(s,n){const r=this.getDirectiveConditionalValue(s.directive,n);return r.termType==="Literal"&&r.value==="true"?{ignore:!0}:{}}};return cc.DirectiveNodeHandlerSkip=e,cc}var sx;function hq(){return sx||(sx=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(nu(),t),u(tz(),t),u(rz(),t),u(nz(),t),u(iz(),t),u(az(),t)}(Zg)),Zg}var t_={},lc={},ox;function zi(){if(ox)return lc;ox=1,Object.defineProperty(lc,"__esModule",{value:!0}),lc.NodeValueHandlerAdapter=void 0;let t=class{constructor(u,s,n){this.targetKind=u,this.util=s,this.settings=n}};return lc.NodeValueHandlerAdapter=t,lc}var dc={},ux;function sz(){if(ux)return dc;ux=1,Object.defineProperty(dc,"__esModule",{value:!0}),dc.NodeValueHandlerBoolean=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("BooleanValue",s,n),this.datatype=this.util.dataFactory.namedNode("http://www.w3.org/2001/XMLSchema#boolean")}handle(s,n,r){return{terms:[this.util.dataFactory.literal(s.value?"true":"false",this.datatype)]}}};return dc.NodeValueHandlerBoolean=e,dc}var fc={},cx;function oz(){if(cx)return fc;cx=1,Object.defineProperty(fc,"__esModule",{value:!0}),fc.NodeValueHandlerEnum=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("EnumValue",s,n)}handle(s,n,r){return{terms:[this.util.valueToNamedNode(s.value,r.context)]}}};return fc.NodeValueHandlerEnum=e,fc}var hc={},lx;function uz(){if(lx)return hc;lx=1,Object.defineProperty(hc,"__esModule",{value:!0}),hc.NodeValueHandlerFloat=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("FloatValue",s,n),this.datatype=this.util.dataFactory.namedNode("http://www.w3.org/2001/XMLSchema#float")}handle(s,n,r){return{terms:[this.util.dataFactory.literal(s.value,this.datatype)]}}};return hc.NodeValueHandlerFloat=e,hc}var pc={},dx;function cz(){if(dx)return pc;dx=1,Object.defineProperty(pc,"__esModule",{value:!0}),pc.NodeValueHandlerInt=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("IntValue",s,n),this.datatype=this.util.dataFactory.namedNode("http://www.w3.org/2001/XMLSchema#integer")}handle(s,n,r){return{terms:[this.util.dataFactory.literal(s.value,this.datatype)]}}};return pc.NodeValueHandlerInt=e,pc}var yc={},fx;function lz(){if(fx)return yc;fx=1,Object.defineProperty(yc,"__esModule",{value:!0}),yc.NodeValueHandlerList=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("ListValue",s,n),this.nodeFirst=this.util.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#first"),this.nodeRest=this.util.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#rest"),this.nodeNil=this.util.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#nil")}handle(s,n,r){const a=[];let o=[];for(const l of s.values){const c=this.util.handleNodeValue(l,n,r);for(const d of c.terms)a.push(d);c.auxiliaryPatterns&&(o=o.concat(c.auxiliaryPatterns))}if(this.settings.arraysToRdfLists){const l=this.util.dataFactory.blankNode();let c=l,d=a.length;for(const h of a){o.push(this.util.operationFactory.createPattern(c,this.nodeFirst,h,r.graph));const f=--d===0?this.nodeNil:this.util.dataFactory.blankNode();o.push(this.util.operationFactory.createPattern(c,this.nodeRest,f,r.graph)),c=f}return{terms:[l],auxiliaryPatterns:o}}else return{terms:a,auxiliaryPatterns:o}}};return yc.NodeValueHandlerList=e,yc}var bc={},hx;function dz(){if(hx)return bc;hx=1,Object.defineProperty(bc,"__esModule",{value:!0}),bc.NodeValueHandlerNull=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("NullValue",s,n),this.nil=this.util.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#nil")}handle(s,n,r){return{terms:[this.nil]}}};return bc.NodeValueHandlerNull=e,bc}var mc={},px;function fz(){if(px)return mc;px=1,Object.defineProperty(mc,"__esModule",{value:!0}),mc.NodeValueHandlerObject=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("ObjectValue",s,n)}handle(s,n,r){const a=this.util.dataFactory.blankNode();let o=[];for(const l of s.fields){const c=this.util.handleNodeValue(l.value,n,r);for(const d of c.terms)o.push(this.util.createQuadPattern(a,l.name,d,r.graph,r.context));c.auxiliaryPatterns&&(o=o.concat(c.auxiliaryPatterns))}return{terms:[a],auxiliaryPatterns:o}}};return mc.NodeValueHandlerObject=e,mc}var gc={},yx;function hz(){if(yx)return gc;yx=1,Object.defineProperty(gc,"__esModule",{value:!0}),gc.NodeValueHandlerString=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("StringValue",s,n)}handle(s,n,r){const a=r.context.getContextRaw()[n];let o,l;return a&&typeof a!="string"&&(a["@language"]?o=a["@language"]:a["@type"]&&(l=this.util.dataFactory.namedNode(a["@type"]))),{terms:[this.util.dataFactory.literal(s.value,o||l)]}}};return gc.NodeValueHandlerString=e,gc}var _c={},bx;function pz(){if(bx)return _c;bx=1,Object.defineProperty(_c,"__esModule",{value:!0}),_c.NodeValueHandlerVariable=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("Variable",s,n)}handle(s,n,r){const a=s.name.value,o=r.variablesDict[a],l=r.variablesMetaDict[a];if(!o){if(!r.ignoreUnknownVariables&&(!l||l.mandatory))throw new Error(`Undefined variable: ${a}`);{const c=this.util.dataFactory.variable(a);return r.terminalVariables.map(d=>d.value).indexOf(a)<0&&r.terminalVariables.push(c),{terms:[c]}}}if(o.kind==="Variable")throw new Error(`Variable refers to another variable: ${a}`);if(l)if(l.list){if(o.kind!=="ListValue")throw new Error(`Expected a list, but got ${o.kind} for ${a}`);if(l.type){const c=o;for(const d of c.values)if(d.kind!==l.type)throw new Error(`Expected ${l.type}, but got ${d.kind} for ${a}`)}}else l.type;return this.util.handleNodeValue(o,n,r)}};return _c.NodeValueHandlerVariable=e,_c}var mx;function yz(){return mx||(mx=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(zi(),t),u(sz(),t),u(oz(),t),u(uz(),t),u(cz(),t),u(lz(),t),u(dz(),t),u(fz(),t),u(hz(),t),u(pz(),t)}(t_)),t_}var vc={},gx;function zb(){if(gx)return vc;gx=1,Object.defineProperty(vc,"__esModule",{value:!0}),vc.NodeHandlerAdapter=void 0;let t=class{constructor(u,s,n){this.targetKind=u,this.util=s,this.settings=n}getNodeQuadContextSelectionSet(u,s,n){const r={};if(u){for(const a of u.selections)if(a.kind==="Field"){const o=a;this.handleNodeQuadContextField(o,n,r,"id","subject"),this.handleNodeQuadContextField(o,n,r,"graph","graph")}}return r}handleNodeQuadContextField(u,s,n,r,a){if(!n[a]&&u.name.value===r){if(!n[a]){const o=this.util.getArgument(u.arguments,"_");if(o){const l=this.util.handleNodeValue(o.value,u.name.value,s);if(l.terms.length!==1)throw new Error(`Only single values can be set as ${r}, but got ${l.terms.length} at ${u.name.value}`);n[a]=l.terms[0],l.auxiliaryPatterns&&(n.auxiliaryPatterns||(n.auxiliaryPatterns=[]),n.auxiliaryPatterns.concat(l.auxiliaryPatterns))}}if(!n[a]){const o=this.util.nameToVariable(this.util.getFieldLabel(u),s);s.terminalVariables.push(o),n[a]=o}}}getDirectiveOutputs(u,s,n){const r=[];if(u)for(const a of u){const o=this.util.handleDirectiveNode({directive:a,fieldLabel:s},n);if(o){if(o.ignore)return null;r.push(o)}}return r}handleDirectiveOutputs(u,s){for(const n of u){if(n.ignore)return this.util.operationFactory.createBgp([]);n.operationOverrider&&(s=n.operationOverrider(s))}return s}};return vc.NodeHandlerAdapter=t,vc}var wc={},_x;function VT(){if(_x)return wc;_x=1,Object.defineProperty(wc,"__esModule",{value:!0}),wc.NodeHandlerDefinitionAdapter=void 0;const t=zb();let e=class extends t.NodeHandlerAdapter{constructor(s,n,r){super(s,n,r)}};return wc.NodeHandlerDefinitionAdapter=e,wc}var Sc={},vx;function bz(){if(vx)return Sc;vx=1,Object.defineProperty(Sc,"__esModule",{value:!0}),Sc.NodeHandlerDefinitionFragment=void 0;const t=VT();let e=class extends t.NodeHandlerDefinitionAdapter{constructor(s,n){super("FragmentDefinition",s,n)}handle(s,n){throw new Error("Illegal state: fragment definitions must be indexed and removed before processing")}};return Sc.NodeHandlerDefinitionFragment=e,Sc}var Tc={},wx;function mz(){if(wx)return Tc;wx=1,Object.defineProperty(Tc,"__esModule",{value:!0}),Tc.NodeHandlerDefinitionOperation=void 0;const t=VT();let e=class extends t.NodeHandlerDefinitionAdapter{constructor(s,n){super("OperationDefinition",s,n)}handle(s,n){if(s.operation!=="query")throw new Error("Unsupported definition operation: "+s.operation);if(s.variableDefinitions)for(const o of s.variableDefinitions){const l=o.variable.name.value;o.defaultValue&&(n.variablesDict[l]||(n.variablesDict[l]=o.defaultValue));let c=o.type;const d=c.kind==="NonNullType";d&&(c=c.type);const h=c.kind==="ListType";h&&(c=c.type);const f=c.name.value;n.variablesMetaDict[l]={mandatory:d,list:h,type:f}}const r=this.getDirectiveOutputs(s.directives,s.name?s.name.value:"",n);if(!r)return this.util.operationFactory.createBgp([]);const a=this.util.joinOperations(s.selectionSet.selections.map(o=>this.util.handleNode(o,n)));return this.handleDirectiveOutputs(r,a)}};return Tc.NodeHandlerDefinitionOperation=e,Tc}var Ac={},Sx;function gz(){if(Sx)return Ac;Sx=1,Object.defineProperty(Ac,"__esModule",{value:!0}),Ac.NodeHandlerDocument=void 0;const t=Ot(),e=zb();let u=class extends e.NodeHandlerAdapter{constructor(n,r){super("Document",n,r)}handle(n,r){const a=n.definitions.map(l=>{const c=this.getNodeQuadContextDefinitionNode(l,Object.assign(Object.assign({},r),{ignoreUnknownVariables:!0})),d=Object.assign(Object.assign({},r),{graph:c.graph||r.graph,subject:c.subject||this.util.dataFactory.blankNode()});let h=this.util.handleNode(l,d);return c&&c.auxiliaryPatterns&&(h=this.util.joinOperations([h,this.util.operationFactory.createBgp(c.auxiliaryPatterns)])),h}),o=this.util.operationFactory.createProject(a.length===1?a[0]:this.util.operationFactory.createUnion(a),r.terminalVariables);return this.translateBlankNodesToVariables(o)}getNodeQuadContextDefinitionNode(n,r){if(n.kind==="OperationDefinition")return this.getNodeQuadContextSelectionSet(n.selectionSet,n.name?n.name.value:"",r);throw new Error(`Unsupported definition: ${n.kind}`)}translateBlankNodesToVariables(n){const r=this,a={},o=Array.from(n.variables).reduce((c,d)=>(c[d.value]=!0,c),{});return t.Util.mapOperation(n,{path:(c,d)=>({recurse:!1,result:d.createPath(l(c.subject),c.predicate,l(c.object),l(c.graph))}),pattern:(c,d)=>({recurse:!1,result:d.createPattern(l(c.subject),l(c.predicate),l(c.object),l(c.graph))})});function l(c){if(c.termType==="BlankNode"){let d=a[c.value];return d||(d=t.Util.createUniqueVariable(c.value,o,r.util.dataFactory),o[d.value]=!0,a[c.value]=d),d}return c}}};return Ac.NodeHandlerDocument=u,Ac}var Ec={},Tx;function Gb(){if(Tx)return Ec;Tx=1,Object.defineProperty(Ec,"__esModule",{value:!0}),Ec.NodeHandlerSelectionAdapter=void 0;const t=Ot(),e=Iy(),u=zb();let s=class extends u.NodeHandlerAdapter{constructor(r,a,o){super(r,a,o)}getNodeQuadContextFieldNode(r,a,o){return this.getNodeQuadContextSelectionSet(r.selectionSet,a,Object.assign(Object.assign({},o),{path:this.util.appendFieldToPath(o.path,a)}))}fieldToOperation(r,a,o,l){const c=o;let d=0,h;if((a.name.value==="id"||a.name.value==="graph")&&(o=!1,a.arguments))for(const S of a.arguments)S.name.value==="_"&&this.util.handleNodeValue(S.value,a.name.value,r);const f=this.util.getFieldLabel(a);if(r.singularizeState===e.SingularizeState.SINGLE&&(r.singularizeVariables[this.util.nameToVariable(f,r).value]=!0),o){const S=this.handleMetaField(r,f,l);if(S)return S}const p=l?[this.util.operationFactory.createBgp(l)]:[],y=this.getNodeQuadContextFieldNode(a,f,r);let b=y.subject||this.util.nameToVariable(f,r),g=y.graph||r.graph;y.auxiliaryPatterns&&p.push(this.util.operationFactory.createBgp(y.auxiliaryPatterns));let m=!0,v=null;if(o&&a.arguments&&a.arguments.length){for(const S of a.arguments)if(S.name.value==="_"){const A=this.util.handleNodeValue(S.value,a.name.value,r);v=A.terms,p.push(this.util.operationFactory.createBgp(A.terms.map(D=>this.util.createQuadPattern(r.subject,a.name,D,r.graph,r.context)))),A.auxiliaryPatterns&&p.push(this.util.operationFactory.createBgp(A.auxiliaryPatterns)),o=!1;break}else if(S.name.value==="graph"){const A=this.util.handleNodeValue(S.value,a.name.value,r);if(A.terms.length!==1)throw new Error(`Only single values can be set as graph, but got ${A.terms.length} at ${a.name.value}`);g=A.terms[0],r=Object.assign(Object.assign({},r),{graph:g}),A.auxiliaryPatterns&&p.push(this.util.operationFactory.createBgp(A.auxiliaryPatterns));break}else if(S.name.value==="alt"){let A=S.value;A.kind!=="ListValue"&&(A={kind:"ListValue",values:[A]}),p.push(this.util.createQuadPath(r.subject,a.name,A,b,r.graph,r.context)),m=!1;break}}if(o&&m&&p.push(this.util.operationFactory.createBgp([this.util.createQuadPattern(r.subject,a.name,b,r.graph,r.context)])),a.arguments&&a.arguments.length){for(const S of a.arguments)if(!(S.name.value==="_"||S.name.value==="graph"||S.name.value==="alt"))if(S.name.value==="first"){if(S.value.kind!=="IntValue")throw new Error("Invalid value type for 'first' argument: "+S.value.kind);h=parseInt(S.value.value,10)}else if(S.name.value==="offset"){if(S.value.kind!=="IntValue")throw new Error("Invalid value type for 'offset' argument: "+S.value.kind);d=parseInt(S.value.value,10)}else{const A=this.util.handleNodeValue(S.value,S.name.value,r);p.push(this.util.operationFactory.createBgp(A.terms.map(D=>this.util.createQuadPattern(b,S.name,D,r.graph,r.context)))),A.auxiliaryPatterns&&p.push(this.util.operationFactory.createBgp(A.auxiliaryPatterns))}}const _=this.getDirectiveOutputs(a.directives,f,r);if(!_)return this.util.operationFactory.createBgp([]);let w=this.util.joinOperations(p);if(a.selectionSet&&a.selectionSet.selections.length){if(v){if(v.length!==1)throw new Error(`Only single values can be set as id, but got ${v.length} at ${a.name.value}`);b=v[0]}const S=Object.assign(Object.assign(Object.assign({},r),c?{path:this.util.appendFieldToPath(r.path,f)}:{}),{graph:g,subject:c?b:r.subject});let A=!1;const D=a.selectionSet.selections.filter(O=>O.kind==="Field"&&O.name.value==="totalCount"?(A=!0,!1):!0);let L=this.util.joinOperations(p.concat(D.map(O=>this.util.handleNode(O,S))));if(A){const O=this.util.dataFactory.variable("var"+this.settings.expressionVariableCounter++),E=this.util.dataFactory.variable(b.value+this.settings.variableDelimiter+"totalCount"),P=this.util.operationFactory.createBoundAggregate(O,"count",this.util.operationFactory.createTermExpression(b),!1),M=this.util.operationFactory.createProject(this.util.operationFactory.createExtend(this.util.operationFactory.createGroup(w,[],[P]),E,this.util.operationFactory.createTermExpression(O)),[E]);r.terminalVariables.push(E),D.length?L=this.util.operationFactory.createJoin([this.util.operationFactory.createProject(L,[]),M]):L=M}w=L}else o&&b.termType==="Variable"&&r.terminalVariables.push(b);return(d||h)&&(w=this.util.operationFactory.createSlice(this.util.operationFactory.createProject(w,t.Util.inScopeVariables(w)),d,h)),this.handleDirectiveOutputs(_,w)}handleMetaField(r,a,o){if(a==="__typename"){const l=this.util.nameToVariable(a,r);return r.terminalVariables.push(l),this.util.operationFactory.createBgp([this.util.operationFactory.createPattern(r.subject,this.util.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),this.util.nameToVariable(a,r),r.graph)].concat(o||[]))}}};return Ec.NodeHandlerSelectionAdapter=s,Ec}var Oc={},Ax;function _z(){if(Ax)return Oc;Ax=1,Object.defineProperty(Oc,"__esModule",{value:!0}),Oc.NodeHandlerSelectionField=void 0;const t=Gb();let e=class extends t.NodeHandlerSelectionAdapter{constructor(s,n){super("Field",s,n)}handle(s,n){return this.fieldToOperation(n,s,!0)}};return Oc.NodeHandlerSelectionField=e,Oc}var Rc={},Ex;function vz(){if(Ex)return Rc;Ex=1,Object.defineProperty(Rc,"__esModule",{value:!0}),Rc.NodeHandlerSelectionFragmentSpread=void 0;const t=Gb();let e=class extends t.NodeHandlerSelectionAdapter{constructor(s,n){super("FragmentSpread",s,n)}handle(s,n){const r=n.fragmentDefinitions[s.name.value];if(!r)throw new Error("Undefined fragment definition: "+s.name.value);const a={alias:void 0,arguments:void 0,directives:r.directives,kind:"Field",name:s.name,selectionSet:r.selectionSet},o=[this.util.newTypePattern(n.subject,r.typeCondition,n)];return this.util.operationFactory.createLeftJoin(this.util.operationFactory.createBgp([]),this.fieldToOperation(n,a,!1,o))}};return Rc.NodeHandlerSelectionFragmentSpread=e,Rc}var xc={},Ox;function wz(){if(Ox)return xc;Ox=1,Object.defineProperty(xc,"__esModule",{value:!0}),xc.NodeHandlerSelectionInlineFragment=void 0;const t=Gb();let e=class extends t.NodeHandlerSelectionAdapter{constructor(s,n){super("InlineFragment",s,n)}handle(s,n){const r={alias:void 0,arguments:void 0,directives:s.directives,kind:"Field",name:{kind:"Name",value:n.subject.value},selectionSet:s.selectionSet},a=s.typeCondition?[this.util.newTypePattern(n.subject,s.typeCondition,n)]:[];return this.util.operationFactory.createLeftJoin(this.util.operationFactory.createBgp([]),this.fieldToOperation(n,r,!1,a))}};return xc.NodeHandlerSelectionInlineFragment=e,xc}var Rx;function pq(){return Rx||(Rx=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(hq(),t),u(yz(),t),u(zb(),t),u(VT(),t),u(bz(),t),u(mz(),t),u(gz(),t),u(Gb(),t),u(_z(),t),u(vz(),t),u(wz(),t)}(Yg)),Yg}var Ic={},yq=typeof Symbol=="function"&&Symbol.toStringTag!=null?Symbol.toStringTag:"@@toStringTag",Sz=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):void 0;const y3=Sz;function U1(t){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?U1=function(u){return typeof u}:U1=function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},U1(t)}var Tz=10,bq=2;function mq(t){return Wb(t,[])}function Wb(t,e){switch(U1(t)){case"string":return JSON.stringify(t);case"function":return t.name?"[function ".concat(t.name,"]"):"[function]";case"object":return t===null?"null":Az(t,e);default:return String(t)}}function Az(t,e){if(e.indexOf(t)!==-1)return"[Circular]";var u=[].concat(e,[t]),s=Rz(t);if(s!==void 0){var n=s.call(t);if(n!==t)return typeof n=="string"?n:Wb(n,u)}else if(Array.isArray(t))return Oz(t,u);return Ez(t,u)}function Ez(t,e){var u=Object.keys(t);if(u.length===0)return"{}";if(e.length>bq)return"["+xz(t)+"]";var s=u.map(function(n){var r=Wb(t[n],e);return n+": "+r});return"{ "+s.join(", ")+" }"}function Oz(t,e){if(t.length===0)return"[]";if(e.length>bq)return"[Array]";for(var u=Math.min(Tz,t.length),s=t.length-u,n=[],r=0;r1&&n.push("... ".concat(s," more items")),"["+n.join(", ")+"]"}function Rz(t){var e=t[String(y3)];if(typeof e=="function")return e;if(typeof t.inspect=="function")return t.inspect}function xz(t){var e=Object.prototype.toString.call(t).replace(/^\[object /,"").replace(/]$/,"");if(e==="Object"&&typeof t.constructor=="function"){var u=t.constructor.name;if(typeof u=="string"&&u!=="")return u}return e}function r_(t,e){var u=!!t;if(!u)throw new Error(e)}const Iz=function(e,u){return e instanceof u};function xx(t,e){for(var u=0;u1&&arguments[1]!==void 0?arguments[1]:"GraphQL request",s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{line:1,column:1};typeof e=="string"||r_(0,"Body must be a string. Received: ".concat(mq(e),".")),this.body=e,this.name=u,this.locationOffset=s,this.locationOffset.line>0||r_(0,"line in locationOffset is 1-indexed and must be positive."),this.locationOffset.column>0||r_(0,"column in locationOffset is 1-indexed and must be positive.")}return Pz(t,[{key:yq,get:function(){return"Source"}}]),t}();function Dz(t){return Iz(t,kT)}function cb(t,e){for(var u=/\r\n|[\n\r]/g,s=1,n=e+1,r;(r=u.exec(t.body))&&r.index120){for(var f=Math.floor(l/80),p=l%80,y=[],b=0;b",EOF:"",BANG:"!",DOLLAR:"$",AMP:"&",PAREN_L:"(",PAREN_R:")",SPREAD:"...",COLON:":",EQUALS:"=",AT:"@",BRACKET_L:"[",BRACKET_R:"]",BRACE_L:"{",PIPE:"|",BRACE_R:"}",NAME:"Name",INT:"Int",FLOAT:"Float",STRING:"String",BLOCK_STRING:"BlockString",COMMENT:"Comment"});function H1(t){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?H1=function(u){return typeof u}:H1=function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},H1(t)}function Cz(t){return H1(t)=="object"&&t!==null}function $1(t){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?$1=function(u){return typeof u}:$1=function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},$1(t)}function Px(t,e){var u=Object.keys(t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);e&&(s=s.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),u.push.apply(u,s)}return u}function jz(t){for(var e=1;e"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch{return!1}}function Uz(t){return Function.toString.call(t).indexOf("[native code]")!==-1}function ty(t,e){return ty=Object.setPrototypeOf||function(s,n){return s.__proto__=n,s},ty(t,e)}function ry(t){return ry=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},ry(t)}var Qz=function(t){qz(u,t);var e=Bz(u);function u(s,n,r,a,o,l,c){var d,h,f,p;Mz(this,u),p=e.call(this,s),p.name="GraphQLError",p.originalError=l??void 0,p.nodes=Nx(Array.isArray(n)?n:n?[n]:void 0);for(var y=[],b=0,g=(m=p.nodes)!==null&&m!==void 0?m:[];b0},name:{enumerable:!1},nodes:{enumerable:!1},source:{enumerable:!1},positions:{enumerable:!1},originalError:{enumerable:!1}}),l!=null&&l.stack?(Object.defineProperty(R0(p),"stack",{value:l.stack,writable:!0,configurable:!0}),_q(p)):(Error.captureStackTrace?Error.captureStackTrace(R0(p),u):Object.defineProperty(R0(p),"stack",{value:Error().stack,writable:!0,configurable:!0}),p)}return Fz(u,[{key:"toString",value:function(){return Hz(this)}},{key:yq,get:function(){return"Object"}}]),u}(b3(Error));function Nx(t){return t===void 0||t.length===0?void 0:t}function Hz(t){var e=t.message;if(t.nodes)for(var u=0,s=t.nodes;un&&jx(e[r-1]);)--r;return e.slice(n,r).join(` +`)}function jx(t){for(var e=0;e1&&arguments[1]!==void 0?arguments[1]:"",u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,s=t.indexOf(` +`)===-1,n=t[0]===" "||t[0]===" ",r=t[t.length-1]==='"',a=t[t.length-1]==="\\",o=!s||r||a||u,l="";return o&&!(s&&n)&&(l+=` +`+e),l+=e?t.replace(/\n/g,` +`+e):t,o&&(l+=` +`),'"""'+l.replace(/"""/g,'\\"""')+'"""'}var Sq=function(){function t(u){var s=new Er(ke.SOF,0,0,0,0,null);this.source=u,this.lastToken=s,this.token=s,this.line=1,this.lineStart=0}var e=t.prototype;return e.advance=function(){this.lastToken=this.token;var s=this.token=this.lookahead();return s},e.lookahead=function(){var s=this.token;if(s.kind!==ke.EOF)do{var n;s=(n=s.next)!==null&&n!==void 0?n:s.next=Wz(this,s)}while(s.kind===ke.COMMENT);return s},t}();function Gz(t){return t===ke.BANG||t===ke.DOLLAR||t===ke.AMP||t===ke.PAREN_L||t===ke.PAREN_R||t===ke.SPREAD||t===ke.COLON||t===ke.EQUALS||t===ke.AT||t===ke.BRACKET_L||t===ke.BRACKET_R||t===ke.BRACE_L||t===ke.PIPE||t===ke.BRACE_R}function Xs(t){return isNaN(t)?ke.EOF:t<127?JSON.stringify(String.fromCharCode(t)):'"\\u'.concat(("00"+t.toString(16).toUpperCase()).slice(-4),'"')}function Wz(t,e){for(var u=t.source,s=u.body,n=s.length,r=e.end;r31||a===9));return new Er(ke.COMMENT,e,o,u,s,n,r.slice(e+1,o))}function Kz(t,e,u,s,n,r){var a=t.body,o=u,l=e,c=!1;if(o===45&&(o=a.charCodeAt(++l)),o===48){if(o=a.charCodeAt(++l),o>=48&&o<=57)throw Jn(t,l,"Invalid number, unexpected digit after 0: ".concat(Xs(o),"."))}else l=n_(t,l,o),o=a.charCodeAt(l);if(o===46&&(c=!0,o=a.charCodeAt(++l),l=n_(t,l,o),o=a.charCodeAt(l)),(o===69||o===101)&&(c=!0,o=a.charCodeAt(++l),(o===43||o===45)&&(o=a.charCodeAt(++l)),l=n_(t,l,o),o=a.charCodeAt(l)),o===46||rG(o))throw Jn(t,l,"Invalid number, expected digit but got: ".concat(Xs(o),"."));return new Er(c?ke.FLOAT:ke.INT,e,l,s,n,r,a.slice(e,l))}function n_(t,e,u){var s=t.body,n=e,r=u;if(r>=48&&r<=57){do r=s.charCodeAt(++n);while(r>=48&&r<=57);return n}throw Jn(t,n,"Invalid number, expected digit but got: ".concat(Xs(r),"."))}function Yz(t,e,u,s,n){for(var r=t.body,a=e+1,o=a,l=0,c="";a=48&&t<=57?t-48:t>=65&&t<=70?t-55:t>=97&&t<=102?t-87:-1}function tG(t,e,u,s,n){for(var r=t.body,a=r.length,o=e+1,l=0;o!==a&&!isNaN(l=r.charCodeAt(o))&&(l===95||l>=48&&l<=57||l>=65&&l<=90||l>=97&&l<=122);)++o;return new Er(ke.NAME,e,o,u,s,n,r.slice(e,o))}function rG(t){return t===95||t>=65&&t<=90||t>=97&&t<=122}var Tq=Object.freeze({QUERY:"QUERY",MUTATION:"MUTATION",SUBSCRIPTION:"SUBSCRIPTION",FIELD:"FIELD",FRAGMENT_DEFINITION:"FRAGMENT_DEFINITION",FRAGMENT_SPREAD:"FRAGMENT_SPREAD",INLINE_FRAGMENT:"INLINE_FRAGMENT",VARIABLE_DEFINITION:"VARIABLE_DEFINITION",SCHEMA:"SCHEMA",SCALAR:"SCALAR",OBJECT:"OBJECT",FIELD_DEFINITION:"FIELD_DEFINITION",ARGUMENT_DEFINITION:"ARGUMENT_DEFINITION",INTERFACE:"INTERFACE",UNION:"UNION",ENUM:"ENUM",ENUM_VALUE:"ENUM_VALUE",INPUT_OBJECT:"INPUT_OBJECT",INPUT_FIELD_DEFINITION:"INPUT_FIELD_DEFINITION"});function nG(t,e){var u=new WT(t,e);return u.parseDocument()}function iG(t,e){var u=new WT(t,e);u.expectToken(ke.SOF);var s=u.parseValueLiteral(!1);return u.expectToken(ke.EOF),s}function aG(t,e){var u=new WT(t,e);u.expectToken(ke.SOF);var s=u.parseTypeReference();return u.expectToken(ke.EOF),s}var WT=function(){function t(u,s){var n=Dz(u)?u:new kT(u);this._lexer=new Sq(n),this._options=s}var e=t.prototype;return e.parseName=function(){var s=this.expectToken(ke.NAME);return{kind:rt.NAME,value:s.value,loc:this.loc(s)}},e.parseDocument=function(){var s=this._lexer.token;return{kind:rt.DOCUMENT,definitions:this.many(ke.SOF,this.parseDefinition,ke.EOF),loc:this.loc(s)}},e.parseDefinition=function(){if(this.peek(ke.NAME))switch(this._lexer.token.value){case"query":case"mutation":case"subscription":return this.parseOperationDefinition();case"fragment":return this.parseFragmentDefinition();case"schema":case"scalar":case"type":case"interface":case"union":case"enum":case"input":case"directive":return this.parseTypeSystemDefinition();case"extend":return this.parseTypeSystemExtension()}else{if(this.peek(ke.BRACE_L))return this.parseOperationDefinition();if(this.peekDescription())return this.parseTypeSystemDefinition()}throw this.unexpected()},e.parseOperationDefinition=function(){var s=this._lexer.token;if(this.peek(ke.BRACE_L))return{kind:rt.OPERATION_DEFINITION,operation:"query",name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet(),loc:this.loc(s)};var n=this.parseOperationType(),r;return this.peek(ke.NAME)&&(r=this.parseName()),{kind:rt.OPERATION_DEFINITION,operation:n,name:r,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(s)}},e.parseOperationType=function(){var s=this.expectToken(ke.NAME);switch(s.value){case"query":return"query";case"mutation":return"mutation";case"subscription":return"subscription"}throw this.unexpected(s)},e.parseVariableDefinitions=function(){return this.optionalMany(ke.PAREN_L,this.parseVariableDefinition,ke.PAREN_R)},e.parseVariableDefinition=function(){var s=this._lexer.token;return{kind:rt.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(ke.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(ke.EQUALS)?this.parseValueLiteral(!0):void 0,directives:this.parseDirectives(!0),loc:this.loc(s)}},e.parseVariable=function(){var s=this._lexer.token;return this.expectToken(ke.DOLLAR),{kind:rt.VARIABLE,name:this.parseName(),loc:this.loc(s)}},e.parseSelectionSet=function(){var s=this._lexer.token;return{kind:rt.SELECTION_SET,selections:this.many(ke.BRACE_L,this.parseSelection,ke.BRACE_R),loc:this.loc(s)}},e.parseSelection=function(){return this.peek(ke.SPREAD)?this.parseFragment():this.parseField()},e.parseField=function(){var s=this._lexer.token,n=this.parseName(),r,a;return this.expectOptionalToken(ke.COLON)?(r=n,a=this.parseName()):a=n,{kind:rt.FIELD,alias:r,name:a,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(ke.BRACE_L)?this.parseSelectionSet():void 0,loc:this.loc(s)}},e.parseArguments=function(s){var n=s?this.parseConstArgument:this.parseArgument;return this.optionalMany(ke.PAREN_L,n,ke.PAREN_R)},e.parseArgument=function(){var s=this._lexer.token,n=this.parseName();return this.expectToken(ke.COLON),{kind:rt.ARGUMENT,name:n,value:this.parseValueLiteral(!1),loc:this.loc(s)}},e.parseConstArgument=function(){var s=this._lexer.token;return{kind:rt.ARGUMENT,name:this.parseName(),value:(this.expectToken(ke.COLON),this.parseValueLiteral(!0)),loc:this.loc(s)}},e.parseFragment=function(){var s=this._lexer.token;this.expectToken(ke.SPREAD);var n=this.expectOptionalKeyword("on");return!n&&this.peek(ke.NAME)?{kind:rt.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(!1),loc:this.loc(s)}:{kind:rt.INLINE_FRAGMENT,typeCondition:n?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(s)}},e.parseFragmentDefinition=function(){var s,n=this._lexer.token;return this.expectKeyword("fragment"),((s=this._options)===null||s===void 0?void 0:s.experimentalFragmentVariables)===!0?{kind:rt.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(n)}:{kind:rt.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(n)}},e.parseFragmentName=function(){if(this._lexer.token.value==="on")throw this.unexpected();return this.parseName()},e.parseValueLiteral=function(s){var n=this._lexer.token;switch(n.kind){case ke.BRACKET_L:return this.parseList(s);case ke.BRACE_L:return this.parseObject(s);case ke.INT:return this._lexer.advance(),{kind:rt.INT,value:n.value,loc:this.loc(n)};case ke.FLOAT:return this._lexer.advance(),{kind:rt.FLOAT,value:n.value,loc:this.loc(n)};case ke.STRING:case ke.BLOCK_STRING:return this.parseStringLiteral();case ke.NAME:switch(this._lexer.advance(),n.value){case"true":return{kind:rt.BOOLEAN,value:!0,loc:this.loc(n)};case"false":return{kind:rt.BOOLEAN,value:!1,loc:this.loc(n)};case"null":return{kind:rt.NULL,loc:this.loc(n)};default:return{kind:rt.ENUM,value:n.value,loc:this.loc(n)}}case ke.DOLLAR:if(!s)return this.parseVariable();break}throw this.unexpected()},e.parseStringLiteral=function(){var s=this._lexer.token;return this._lexer.advance(),{kind:rt.STRING,value:s.value,block:s.kind===ke.BLOCK_STRING,loc:this.loc(s)}},e.parseList=function(s){var n=this,r=this._lexer.token,a=function(){return n.parseValueLiteral(s)};return{kind:rt.LIST,values:this.any(ke.BRACKET_L,a,ke.BRACKET_R),loc:this.loc(r)}},e.parseObject=function(s){var n=this,r=this._lexer.token,a=function(){return n.parseObjectField(s)};return{kind:rt.OBJECT,fields:this.any(ke.BRACE_L,a,ke.BRACE_R),loc:this.loc(r)}},e.parseObjectField=function(s){var n=this._lexer.token,r=this.parseName();return this.expectToken(ke.COLON),{kind:rt.OBJECT_FIELD,name:r,value:this.parseValueLiteral(s),loc:this.loc(n)}},e.parseDirectives=function(s){for(var n=[];this.peek(ke.AT);)n.push(this.parseDirective(s));return n},e.parseDirective=function(s){var n=this._lexer.token;return this.expectToken(ke.AT),{kind:rt.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(s),loc:this.loc(n)}},e.parseTypeReference=function(){var s=this._lexer.token,n;return this.expectOptionalToken(ke.BRACKET_L)?(n=this.parseTypeReference(),this.expectToken(ke.BRACKET_R),n={kind:rt.LIST_TYPE,type:n,loc:this.loc(s)}):n=this.parseNamedType(),this.expectOptionalToken(ke.BANG)?{kind:rt.NON_NULL_TYPE,type:n,loc:this.loc(s)}:n},e.parseNamedType=function(){var s=this._lexer.token;return{kind:rt.NAMED_TYPE,name:this.parseName(),loc:this.loc(s)}},e.parseTypeSystemDefinition=function(){var s=this.peekDescription()?this._lexer.lookahead():this._lexer.token;if(s.kind===ke.NAME)switch(s.value){case"schema":return this.parseSchemaDefinition();case"scalar":return this.parseScalarTypeDefinition();case"type":return this.parseObjectTypeDefinition();case"interface":return this.parseInterfaceTypeDefinition();case"union":return this.parseUnionTypeDefinition();case"enum":return this.parseEnumTypeDefinition();case"input":return this.parseInputObjectTypeDefinition();case"directive":return this.parseDirectiveDefinition()}throw this.unexpected(s)},e.peekDescription=function(){return this.peek(ke.STRING)||this.peek(ke.BLOCK_STRING)},e.parseDescription=function(){if(this.peekDescription())return this.parseStringLiteral()},e.parseSchemaDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("schema");var r=this.parseDirectives(!0),a=this.many(ke.BRACE_L,this.parseOperationTypeDefinition,ke.BRACE_R);return{kind:rt.SCHEMA_DEFINITION,description:n,directives:r,operationTypes:a,loc:this.loc(s)}},e.parseOperationTypeDefinition=function(){var s=this._lexer.token,n=this.parseOperationType();this.expectToken(ke.COLON);var r=this.parseNamedType();return{kind:rt.OPERATION_TYPE_DEFINITION,operation:n,type:r,loc:this.loc(s)}},e.parseScalarTypeDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("scalar");var r=this.parseName(),a=this.parseDirectives(!0);return{kind:rt.SCALAR_TYPE_DEFINITION,description:n,name:r,directives:a,loc:this.loc(s)}},e.parseObjectTypeDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("type");var r=this.parseName(),a=this.parseImplementsInterfaces(),o=this.parseDirectives(!0),l=this.parseFieldsDefinition();return{kind:rt.OBJECT_TYPE_DEFINITION,description:n,name:r,interfaces:a,directives:o,fields:l,loc:this.loc(s)}},e.parseImplementsInterfaces=function(){var s;if(!this.expectOptionalKeyword("implements"))return[];if(((s=this._options)===null||s===void 0?void 0:s.allowLegacySDLImplementsInterfaces)===!0){var n=[];this.expectOptionalToken(ke.AMP);do n.push(this.parseNamedType());while(this.expectOptionalToken(ke.AMP)||this.peek(ke.NAME));return n}return this.delimitedMany(ke.AMP,this.parseNamedType)},e.parseFieldsDefinition=function(){var s;return((s=this._options)===null||s===void 0?void 0:s.allowLegacySDLEmptyFields)===!0&&this.peek(ke.BRACE_L)&&this._lexer.lookahead().kind===ke.BRACE_R?(this._lexer.advance(),this._lexer.advance(),[]):this.optionalMany(ke.BRACE_L,this.parseFieldDefinition,ke.BRACE_R)},e.parseFieldDefinition=function(){var s=this._lexer.token,n=this.parseDescription(),r=this.parseName(),a=this.parseArgumentDefs();this.expectToken(ke.COLON);var o=this.parseTypeReference(),l=this.parseDirectives(!0);return{kind:rt.FIELD_DEFINITION,description:n,name:r,arguments:a,type:o,directives:l,loc:this.loc(s)}},e.parseArgumentDefs=function(){return this.optionalMany(ke.PAREN_L,this.parseInputValueDef,ke.PAREN_R)},e.parseInputValueDef=function(){var s=this._lexer.token,n=this.parseDescription(),r=this.parseName();this.expectToken(ke.COLON);var a=this.parseTypeReference(),o;this.expectOptionalToken(ke.EQUALS)&&(o=this.parseValueLiteral(!0));var l=this.parseDirectives(!0);return{kind:rt.INPUT_VALUE_DEFINITION,description:n,name:r,type:a,defaultValue:o,directives:l,loc:this.loc(s)}},e.parseInterfaceTypeDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("interface");var r=this.parseName(),a=this.parseImplementsInterfaces(),o=this.parseDirectives(!0),l=this.parseFieldsDefinition();return{kind:rt.INTERFACE_TYPE_DEFINITION,description:n,name:r,interfaces:a,directives:o,fields:l,loc:this.loc(s)}},e.parseUnionTypeDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("union");var r=this.parseName(),a=this.parseDirectives(!0),o=this.parseUnionMemberTypes();return{kind:rt.UNION_TYPE_DEFINITION,description:n,name:r,directives:a,types:o,loc:this.loc(s)}},e.parseUnionMemberTypes=function(){return this.expectOptionalToken(ke.EQUALS)?this.delimitedMany(ke.PIPE,this.parseNamedType):[]},e.parseEnumTypeDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("enum");var r=this.parseName(),a=this.parseDirectives(!0),o=this.parseEnumValuesDefinition();return{kind:rt.ENUM_TYPE_DEFINITION,description:n,name:r,directives:a,values:o,loc:this.loc(s)}},e.parseEnumValuesDefinition=function(){return this.optionalMany(ke.BRACE_L,this.parseEnumValueDefinition,ke.BRACE_R)},e.parseEnumValueDefinition=function(){var s=this._lexer.token,n=this.parseDescription(),r=this.parseName(),a=this.parseDirectives(!0);return{kind:rt.ENUM_VALUE_DEFINITION,description:n,name:r,directives:a,loc:this.loc(s)}},e.parseInputObjectTypeDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("input");var r=this.parseName(),a=this.parseDirectives(!0),o=this.parseInputFieldsDefinition();return{kind:rt.INPUT_OBJECT_TYPE_DEFINITION,description:n,name:r,directives:a,fields:o,loc:this.loc(s)}},e.parseInputFieldsDefinition=function(){return this.optionalMany(ke.BRACE_L,this.parseInputValueDef,ke.BRACE_R)},e.parseTypeSystemExtension=function(){var s=this._lexer.lookahead();if(s.kind===ke.NAME)switch(s.value){case"schema":return this.parseSchemaExtension();case"scalar":return this.parseScalarTypeExtension();case"type":return this.parseObjectTypeExtension();case"interface":return this.parseInterfaceTypeExtension();case"union":return this.parseUnionTypeExtension();case"enum":return this.parseEnumTypeExtension();case"input":return this.parseInputObjectTypeExtension()}throw this.unexpected(s)},e.parseSchemaExtension=function(){var s=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");var n=this.parseDirectives(!0),r=this.optionalMany(ke.BRACE_L,this.parseOperationTypeDefinition,ke.BRACE_R);if(n.length===0&&r.length===0)throw this.unexpected();return{kind:rt.SCHEMA_EXTENSION,directives:n,operationTypes:r,loc:this.loc(s)}},e.parseScalarTypeExtension=function(){var s=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");var n=this.parseName(),r=this.parseDirectives(!0);if(r.length===0)throw this.unexpected();return{kind:rt.SCALAR_TYPE_EXTENSION,name:n,directives:r,loc:this.loc(s)}},e.parseObjectTypeExtension=function(){var s=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");var n=this.parseName(),r=this.parseImplementsInterfaces(),a=this.parseDirectives(!0),o=this.parseFieldsDefinition();if(r.length===0&&a.length===0&&o.length===0)throw this.unexpected();return{kind:rt.OBJECT_TYPE_EXTENSION,name:n,interfaces:r,directives:a,fields:o,loc:this.loc(s)}},e.parseInterfaceTypeExtension=function(){var s=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");var n=this.parseName(),r=this.parseImplementsInterfaces(),a=this.parseDirectives(!0),o=this.parseFieldsDefinition();if(r.length===0&&a.length===0&&o.length===0)throw this.unexpected();return{kind:rt.INTERFACE_TYPE_EXTENSION,name:n,interfaces:r,directives:a,fields:o,loc:this.loc(s)}},e.parseUnionTypeExtension=function(){var s=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");var n=this.parseName(),r=this.parseDirectives(!0),a=this.parseUnionMemberTypes();if(r.length===0&&a.length===0)throw this.unexpected();return{kind:rt.UNION_TYPE_EXTENSION,name:n,directives:r,types:a,loc:this.loc(s)}},e.parseEnumTypeExtension=function(){var s=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");var n=this.parseName(),r=this.parseDirectives(!0),a=this.parseEnumValuesDefinition();if(r.length===0&&a.length===0)throw this.unexpected();return{kind:rt.ENUM_TYPE_EXTENSION,name:n,directives:r,values:a,loc:this.loc(s)}},e.parseInputObjectTypeExtension=function(){var s=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");var n=this.parseName(),r=this.parseDirectives(!0),a=this.parseInputFieldsDefinition();if(r.length===0&&a.length===0)throw this.unexpected();return{kind:rt.INPUT_OBJECT_TYPE_EXTENSION,name:n,directives:r,fields:a,loc:this.loc(s)}},e.parseDirectiveDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("directive"),this.expectToken(ke.AT);var r=this.parseName(),a=this.parseArgumentDefs(),o=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");var l=this.parseDirectiveLocations();return{kind:rt.DIRECTIVE_DEFINITION,description:n,name:r,arguments:a,repeatable:o,locations:l,loc:this.loc(s)}},e.parseDirectiveLocations=function(){return this.delimitedMany(ke.PIPE,this.parseDirectiveLocation)},e.parseDirectiveLocation=function(){var s=this._lexer.token,n=this.parseName();if(Tq[n.value]!==void 0)return n;throw this.unexpected(s)},e.loc=function(s){var n;if(((n=this._options)===null||n===void 0?void 0:n.noLocation)!==!0)return new GT(s,this._lexer.lastToken,this._lexer.source)},e.peek=function(s){return this._lexer.token.kind===s},e.expectToken=function(s){var n=this._lexer.token;if(n.kind===s)return this._lexer.advance(),n;throw Jn(this._lexer.source,n.start,"Expected ".concat(Aq(s),", found ").concat(i_(n),"."))},e.expectOptionalToken=function(s){var n=this._lexer.token;if(n.kind===s)return this._lexer.advance(),n},e.expectKeyword=function(s){var n=this._lexer.token;if(n.kind===ke.NAME&&n.value===s)this._lexer.advance();else throw Jn(this._lexer.source,n.start,'Expected "'.concat(s,'", found ').concat(i_(n),"."))},e.expectOptionalKeyword=function(s){var n=this._lexer.token;return n.kind===ke.NAME&&n.value===s?(this._lexer.advance(),!0):!1},e.unexpected=function(s){var n=s??this._lexer.token;return Jn(this._lexer.source,n.start,"Unexpected ".concat(i_(n),"."))},e.any=function(s,n,r){this.expectToken(s);for(var a=[];!this.expectOptionalToken(r);)a.push(n.call(this));return a},e.optionalMany=function(s,n,r){if(this.expectOptionalToken(s)){var a=[];do a.push(n.call(this));while(!this.expectOptionalToken(r));return a}return[]},e.many=function(s,n,r){this.expectToken(s);var a=[];do a.push(n.call(this));while(!this.expectOptionalToken(r));return a},e.delimitedMany=function(s,n){this.expectOptionalToken(s);var r=[];do r.push(n.call(this));while(this.expectOptionalToken(s));return r},t}();function i_(t){var e=t.value;return Aq(t.kind)+(e!=null?' "'.concat(e,'"'):"")}function Aq(t){return Gz(t)?'"'.concat(t,'"'):t}var sG={Name:[],Document:["definitions"],OperationDefinition:["name","variableDefinitions","directives","selectionSet"],VariableDefinition:["variable","type","defaultValue","directives"],Variable:["name"],SelectionSet:["selections"],Field:["alias","name","arguments","directives","selectionSet"],Argument:["name","value"],FragmentSpread:["name","directives"],InlineFragment:["typeCondition","directives","selectionSet"],FragmentDefinition:["name","variableDefinitions","typeCondition","directives","selectionSet"],IntValue:[],FloatValue:[],StringValue:[],BooleanValue:[],NullValue:[],EnumValue:[],ListValue:["values"],ObjectValue:["fields"],ObjectField:["name","value"],Directive:["name","arguments"],NamedType:["name"],ListType:["type"],NonNullType:["type"],SchemaDefinition:["description","directives","operationTypes"],OperationTypeDefinition:["type"],ScalarTypeDefinition:["description","name","directives"],ObjectTypeDefinition:["description","name","interfaces","directives","fields"],FieldDefinition:["description","name","arguments","type","directives"],InputValueDefinition:["description","name","type","defaultValue","directives"],InterfaceTypeDefinition:["description","name","interfaces","directives","fields"],UnionTypeDefinition:["description","name","directives","types"],EnumTypeDefinition:["description","name","directives","values"],EnumValueDefinition:["description","name","directives"],InputObjectTypeDefinition:["description","name","directives","fields"],DirectiveDefinition:["description","name","arguments","locations"],SchemaExtension:["directives","operationTypes"],ScalarTypeExtension:["name","directives"],ObjectTypeExtension:["name","interfaces","directives","fields"],InterfaceTypeExtension:["name","interfaces","directives","fields"],UnionTypeExtension:["name","directives","types"],EnumTypeExtension:["name","directives","values"],InputObjectTypeExtension:["name","directives","fields"]},Eo=Object.freeze({});function Eq(t,e){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:sG,s=void 0,n=Array.isArray(t),r=[t],a=-1,o=[],l=void 0,c=void 0,d=void 0,h=[],f=[],p=t;do{a++;var y=a===r.length,b=y&&o.length!==0;if(y){if(c=f.length===0?void 0:h[h.length-1],l=d,d=f.pop(),b){if(n)l=l.slice();else{for(var g={},m=0,v=Object.keys(l);mcG&&(l=o+Ar(`( +`,k1(dt(n,` +`)),` +)`)),dt([l,dt(r," "),a]," ")},Argument:function(e){var u=e.name,s=e.value;return u+": "+s},FragmentSpread:function(e){var u=e.name,s=e.directives;return"..."+u+Ar(" ",dt(s," "))},InlineFragment:function(e){var u=e.typeCondition,s=e.directives,n=e.selectionSet;return dt(["...",Ar("on ",u),dt(s," "),n]," ")},FragmentDefinition:function(e){var u=e.name,s=e.typeCondition,n=e.variableDefinitions,r=e.directives,a=e.selectionSet;return"fragment ".concat(u).concat(Ar("(",dt(n,", "),")")," ")+"on ".concat(s," ").concat(Ar("",dt(r," ")," "))+a},IntValue:function(e){var u=e.value;return u},FloatValue:function(e){var u=e.value;return u},StringValue:function(e,u){var s=e.value,n=e.block;return n?zz(s,u==="description"?"":" "):JSON.stringify(s)},BooleanValue:function(e){var u=e.value;return u?"true":"false"},NullValue:function(){return"null"},EnumValue:function(e){var u=e.value;return u},ListValue:function(e){var u=e.values;return"["+dt(u,", ")+"]"},ObjectValue:function(e){var u=e.fields;return"{"+dt(u,", ")+"}"},ObjectField:function(e){var u=e.name,s=e.value;return u+": "+s},Directive:function(e){var u=e.name,s=e.arguments;return"@"+u+Ar("(",dt(s,", "),")")},NamedType:function(e){var u=e.name;return u},ListType:function(e){var u=e.type;return"["+u+"]"},NonNullType:function(e){var u=e.type;return u+"!"},SchemaDefinition:pi(function(t){var e=t.directives,u=t.operationTypes;return dt(["schema",dt(e," "),yi(u)]," ")}),OperationTypeDefinition:function(e){var u=e.operation,s=e.type;return u+": "+s},ScalarTypeDefinition:pi(function(t){var e=t.name,u=t.directives;return dt(["scalar",e,dt(u," ")]," ")}),ObjectTypeDefinition:pi(function(t){var e=t.name,u=t.interfaces,s=t.directives,n=t.fields;return dt(["type",e,Ar("implements ",dt(u," & ")),dt(s," "),yi(n)]," ")}),FieldDefinition:pi(function(t){var e=t.name,u=t.arguments,s=t.type,n=t.directives;return e+(Lx(u)?Ar(`( +`,k1(dt(u,` +`)),` +)`):Ar("(",dt(u,", "),")"))+": "+s+Ar(" ",dt(n," "))}),InputValueDefinition:pi(function(t){var e=t.name,u=t.type,s=t.defaultValue,n=t.directives;return dt([e+": "+u,Ar("= ",s),dt(n," ")]," ")}),InterfaceTypeDefinition:pi(function(t){var e=t.name,u=t.interfaces,s=t.directives,n=t.fields;return dt(["interface",e,Ar("implements ",dt(u," & ")),dt(s," "),yi(n)]," ")}),UnionTypeDefinition:pi(function(t){var e=t.name,u=t.directives,s=t.types;return dt(["union",e,dt(u," "),s&&s.length!==0?"= "+dt(s," | "):""]," ")}),EnumTypeDefinition:pi(function(t){var e=t.name,u=t.directives,s=t.values;return dt(["enum",e,dt(u," "),yi(s)]," ")}),EnumValueDefinition:pi(function(t){var e=t.name,u=t.directives;return dt([e,dt(u," ")]," ")}),InputObjectTypeDefinition:pi(function(t){var e=t.name,u=t.directives,s=t.fields;return dt(["input",e,dt(u," "),yi(s)]," ")}),DirectiveDefinition:pi(function(t){var e=t.name,u=t.arguments,s=t.repeatable,n=t.locations;return"directive @"+e+(Lx(u)?Ar(`( +`,k1(dt(u,` +`)),` +)`):Ar("(",dt(u,", "),")"))+(s?" repeatable":"")+" on "+dt(n," | ")}),SchemaExtension:function(e){var u=e.directives,s=e.operationTypes;return dt(["extend schema",dt(u," "),yi(s)]," ")},ScalarTypeExtension:function(e){var u=e.name,s=e.directives;return dt(["extend scalar",u,dt(s," ")]," ")},ObjectTypeExtension:function(e){var u=e.name,s=e.interfaces,n=e.directives,r=e.fields;return dt(["extend type",u,Ar("implements ",dt(s," & ")),dt(n," "),yi(r)]," ")},InterfaceTypeExtension:function(e){var u=e.name,s=e.interfaces,n=e.directives,r=e.fields;return dt(["extend interface",u,Ar("implements ",dt(s," & ")),dt(n," "),yi(r)]," ")},UnionTypeExtension:function(e){var u=e.name,s=e.directives,n=e.types;return dt(["extend union",u,dt(s," "),n&&n.length!==0?"= "+dt(n," | "):""]," ")},EnumTypeExtension:function(e){var u=e.name,s=e.directives,n=e.values;return dt(["extend enum",u,dt(s," "),yi(n)]," ")},InputObjectTypeExtension:function(e){var u=e.name,s=e.directives,n=e.fields;return dt(["extend input",u,dt(s," "),yi(n)]," ")}};function pi(t){return function(e){return dt([e.description,t(e)],` +`)}}function dt(t){var e,u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";return(e=t==null?void 0:t.filter(function(s){return s}).join(u))!==null&&e!==void 0?e:""}function yi(t){return Ar(`{ +`,k1(dt(t,` +`)),` +}`)}function Ar(t,e){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"";return e!=null&&e!==""?t+e+u:""}function k1(t){return Ar(" ",t.replace(/\n/g,` + `))}function dG(t){return t.indexOf(` +`)!==-1}function Lx(t){return t!=null&&t.some(dG)}function fG(t){return Oq(t)||Rq(t)||Iq(t)}function Oq(t){return t.kind===rt.OPERATION_DEFINITION||t.kind===rt.FRAGMENT_DEFINITION}function hG(t){return t.kind===rt.FIELD||t.kind===rt.FRAGMENT_SPREAD||t.kind===rt.INLINE_FRAGMENT}function pG(t){return t.kind===rt.VARIABLE||t.kind===rt.INT||t.kind===rt.FLOAT||t.kind===rt.STRING||t.kind===rt.BOOLEAN||t.kind===rt.NULL||t.kind===rt.ENUM||t.kind===rt.LIST||t.kind===rt.OBJECT}function yG(t){return t.kind===rt.NAMED_TYPE||t.kind===rt.LIST_TYPE||t.kind===rt.NON_NULL_TYPE}function Rq(t){return t.kind===rt.SCHEMA_DEFINITION||xq(t)||t.kind===rt.DIRECTIVE_DEFINITION}function xq(t){return t.kind===rt.SCALAR_TYPE_DEFINITION||t.kind===rt.OBJECT_TYPE_DEFINITION||t.kind===rt.INTERFACE_TYPE_DEFINITION||t.kind===rt.UNION_TYPE_DEFINITION||t.kind===rt.ENUM_TYPE_DEFINITION||t.kind===rt.INPUT_OBJECT_TYPE_DEFINITION}function Iq(t){return t.kind===rt.SCHEMA_EXTENSION||Pq(t)}function Pq(t){return t.kind===rt.SCALAR_TYPE_EXTENSION||t.kind===rt.OBJECT_TYPE_EXTENSION||t.kind===rt.INTERFACE_TYPE_EXTENSION||t.kind===rt.UNION_TYPE_EXTENSION||t.kind===rt.ENUM_TYPE_EXTENSION||t.kind===rt.INPUT_OBJECT_TYPE_EXTENSION}const bG=Object.freeze(Object.defineProperty({__proto__:null,BREAK:Eo,DirectiveLocation:Tq,Kind:rt,Lexer:Sq,Location:GT,Source:kT,Token:Er,TokenKind:ke,getLocation:cb,getVisitFn:lb,isDefinitionNode:fG,isExecutableDefinitionNode:Oq,isSelectionNode:hG,isTypeDefinitionNode:xq,isTypeExtensionNode:Pq,isTypeNode:yG,isTypeSystemDefinitionNode:Rq,isTypeSystemExtensionNode:Iq,isValueNode:pG,parse:nG,parseType:aG,parseValue:iG,print:uG,printLocation:gq,printSourceLocation:zT,visit:Eq,visitInParallel:oG},Symbol.toStringTag,{value:"Module"})),mG=iT(bG);var Pc={},a_={},Dc={},Mx={},Fx;function Dq(){return Fx||(Fx=1,function(){(function(t){(function(e){var u={searchParams:"URLSearchParams"in t,iterable:"Symbol"in t&&"iterator"in Symbol,blob:"FileReader"in t&&"Blob"in t&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in t,arrayBuffer:"ArrayBuffer"in t};function s(O){return O&&DataView.prototype.isPrototypeOf(O)}if(u.arrayBuffer)var n=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],r=ArrayBuffer.isView||function(O){return O&&n.indexOf(Object.prototype.toString.call(O))>-1};function a(O){if(typeof O!="string"&&(O=String(O)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(O))throw new TypeError("Invalid character in header field name");return O.toLowerCase()}function o(O){return typeof O!="string"&&(O=String(O)),O}function l(O){var E={next:function(){var P=O.shift();return{done:P===void 0,value:P}}};return u.iterable&&(E[Symbol.iterator]=function(){return E}),E}function c(O){this.map={},O instanceof c?O.forEach(function(E,P){this.append(P,E)},this):Array.isArray(O)?O.forEach(function(E){this.append(E[0],E[1])},this):O&&Object.getOwnPropertyNames(O).forEach(function(E){this.append(E,O[E])},this)}c.prototype.append=function(O,E){O=a(O),E=o(E);var P=this.map[O];this.map[O]=P?P+", "+E:E},c.prototype.delete=function(O){delete this.map[a(O)]},c.prototype.get=function(O){return O=a(O),this.has(O)?this.map[O]:null},c.prototype.has=function(O){return this.map.hasOwnProperty(a(O))},c.prototype.set=function(O,E){this.map[a(O)]=o(E)},c.prototype.forEach=function(O,E){for(var P in this.map)this.map.hasOwnProperty(P)&&O.call(E,this.map[P],P,this)},c.prototype.keys=function(){var O=[];return this.forEach(function(E,P){O.push(P)}),l(O)},c.prototype.values=function(){var O=[];return this.forEach(function(E){O.push(E)}),l(O)},c.prototype.entries=function(){var O=[];return this.forEach(function(E,P){O.push([P,E])}),l(O)},u.iterable&&(c.prototype[Symbol.iterator]=c.prototype.entries);function d(O){if(O.bodyUsed)return Promise.reject(new TypeError("Already read"));O.bodyUsed=!0}function h(O){return new Promise(function(E,P){O.onload=function(){E(O.result)},O.onerror=function(){P(O.error)}})}function f(O){var E=new FileReader,P=h(E);return E.readAsArrayBuffer(O),P}function p(O){var E=new FileReader,P=h(E);return E.readAsText(O),P}function y(O){for(var E=new Uint8Array(O),P=new Array(E.length),M=0;M-1?E:O}function _(O,E){E=E||{};var P=E.body;if(O instanceof _){if(O.bodyUsed)throw new TypeError("Already read");this.url=O.url,this.credentials=O.credentials,E.headers||(this.headers=new c(O.headers)),this.method=O.method,this.mode=O.mode,this.signal=O.signal,!P&&O._bodyInit!=null&&(P=O._bodyInit,O.bodyUsed=!0)}else this.url=String(O);if(this.credentials=E.credentials||this.credentials||"same-origin",(E.headers||!this.headers)&&(this.headers=new c(E.headers)),this.method=v(E.method||this.method||"GET"),this.mode=E.mode||this.mode||null,this.signal=E.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&P)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(P)}_.prototype.clone=function(){return new _(this,{body:this._bodyInit})};function w(O){var E=new FormData;return O.trim().split("&").forEach(function(P){if(P){var M=P.split("="),U=M.shift().replace(/\+/g," "),j=M.join("=").replace(/\+/g," ");E.append(decodeURIComponent(U),decodeURIComponent(j))}}),E}function S(O){var E=new c,P=O.replace(/\r?\n[\t ]+/g," ");return P.split(/\r?\n/).forEach(function(M){var U=M.split(":"),j=U.shift().trim();if(j){var q=U.join(":").trim();E.append(j,q)}}),E}g.call(_.prototype);function A(O,E){E||(E={}),this.type="default",this.status=E.status===void 0?200:E.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in E?E.statusText:"OK",this.headers=new c(E.headers),this.url=E.url||"",this._initBody(O)}g.call(A.prototype),A.prototype.clone=function(){return new A(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new c(this.headers),url:this.url})},A.error=function(){var O=new A(null,{status:0,statusText:""});return O.type="error",O};var D=[301,302,303,307,308];A.redirect=function(O,E){if(D.indexOf(E)===-1)throw new RangeError("Invalid status code");return new A(null,{status:E,headers:{location:O}})},e.DOMException=t.DOMException;try{new e.DOMException}catch{e.DOMException=function(E,P){this.message=E,this.name=P;var M=Error(E);this.stack=M.stack},e.DOMException.prototype=Object.create(Error.prototype),e.DOMException.prototype.constructor=e.DOMException}function L(O,E){return new Promise(function(P,M){var U=new _(O,E);if(U.signal&&U.signal.aborted)return M(new e.DOMException("Aborted","AbortError"));var j=new XMLHttpRequest;function q(){j.abort()}j.onload=function(){var $={status:j.status,statusText:j.statusText,headers:S(j.getAllResponseHeaders()||"")};$.url="responseURL"in j?j.responseURL:$.headers.get("X-Request-URL");var Z="response"in j?j.response:j.responseText;P(new A(Z,$))},j.onerror=function(){M(new TypeError("Network request failed"))},j.ontimeout=function(){M(new TypeError("Network request failed"))},j.onabort=function(){M(new e.DOMException("Aborted","AbortError"))},j.open(U.method,U.url,!0),U.credentials==="include"?j.withCredentials=!0:U.credentials==="omit"&&(j.withCredentials=!1),"responseType"in j&&u.blob&&(j.responseType="blob"),U.headers.forEach(function($,Z){j.setRequestHeader(Z,$)}),U.signal&&(U.signal.addEventListener("abort",q),j.onreadystatechange=function(){j.readyState===4&&U.signal.removeEventListener("abort",q)}),j.send(typeof U._bodyInit>"u"?null:U._bodyInit)})}return L.polyfill=!0,t.fetch||(t.fetch=L,t.Headers=c,t.Request=_,t.Response=A),e.Headers=c,e.Request=_,e.Response=A,e.fetch=L,Object.defineProperty(e,"__esModule",{value:!0}),e})({})})(typeof self<"u"?self:I)}()),Mx}var s_={},sa={},qx;function gG(){if(qx)return sa;qx=1,Object.defineProperty(sa,"__esModule",{value:!0}),sa.removeDotSegmentsOfPath=sa.removeDotSegments=sa.resolve=void 0;function t(n,r){r=r||"";const a=r.indexOf("#");if(a>0&&(r=r.substr(0,a)),!n.length){if(r.indexOf(":")<0)throw new Error(`Found invalid baseIRI '${r}' for value '${n}'`);return r}if(n.startsWith("?")){const p=r.indexOf("?");return p>0&&(r=r.substr(0,p)),r+n}if(n.startsWith("#"))return r+n;if(!r.length){const p=n.indexOf(":");if(p<0)throw new Error(`Found invalid relative IRI '${n}' for a missing baseIRI`);return u(n,p)}const o=n.indexOf(":");if(o>=0)return u(n,o);const l=r.indexOf(":");if(l<0)throw new Error(`Found invalid baseIRI '${r}' for value '${n}'`);const c=r.substr(0,l+1);if(n.indexOf("//")===0)return c+u(n,o);let d;if(r.indexOf("//",l)===l+1){if(d=r.indexOf("/",l+3),d<0)return r.length>l+3?r+"/"+u(n,o):c+u(n,o)}else if(d=r.indexOf("/",l+1),d<0)return c+u(n,o);if(n.indexOf("/")===0)return r.substr(0,d)+e(n);let h=r.substr(d);const f=h.lastIndexOf("/");return f>=0&&fo.join("")).join("/")}sa.removeDotSegments=e;function u(n,r){let a=r+1;r>=0?n[r+1]==="/"&&n[r+2]==="/"&&(a=r+3):n[0]==="/"&&n[1]==="/"&&(a=2);const o=n.indexOf("/",a);if(o<0)return n;const l=n.substr(0,o),c=n.substr(o);return l+e(c)}sa.removeDotSegmentsOfPath=u;function s(n){return!n||n==="#"||n==="?"||n==="/"}return sa}var Bx;function Pi(){return Bx||(Bx=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(gG(),t)}(s_)),s_}var o_={},Ux;function Py(){return Ux||(Ux=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ERROR_CODES=t.ErrorCoded=void 0;class e extends Error{constructor(s,n){super(s),this.code=n}}t.ErrorCoded=e,function(u){u.COLLIDING_KEYWORDS="colliding keywords",u.CONFLICTING_INDEXES="conflicting indexes",u.CYCLIC_IRI_MAPPING="cyclic IRI mapping",u.INVALID_ID_VALUE="invalid @id value",u.INVALID_INDEX_VALUE="invalid @index value",u.INVALID_NEST_VALUE="invalid @nest value",u.INVALID_PREFIX_VALUE="invalid @prefix value",u.INVALID_PROPAGATE_VALUE="invalid @propagate value",u.INVALID_REVERSE_VALUE="invalid @reverse value",u.INVALID_IMPORT_VALUE="invalid @import value",u.INVALID_VERSION_VALUE="invalid @version value",u.INVALID_BASE_IRI="invalid base IRI",u.INVALID_CONTAINER_MAPPING="invalid container mapping",u.INVALID_CONTEXT_ENTRY="invalid context entry",u.INVALID_CONTEXT_NULLIFICATION="invalid context nullification",u.INVALID_DEFAULT_LANGUAGE="invalid default language",u.INVALID_INCLUDED_VALUE="invalid @included value",u.INVALID_IRI_MAPPING="invalid IRI mapping",u.INVALID_JSON_LITERAL="invalid JSON literal",u.INVALID_KEYWORD_ALIAS="invalid keyword alias",u.INVALID_LANGUAGE_MAP_VALUE="invalid language map value",u.INVALID_LANGUAGE_MAPPING="invalid language mapping",u.INVALID_LANGUAGE_TAGGED_STRING="invalid language-tagged string",u.INVALID_LANGUAGE_TAGGED_VALUE="invalid language-tagged value",u.INVALID_LOCAL_CONTEXT="invalid local context",u.INVALID_REMOTE_CONTEXT="invalid remote context",u.INVALID_REVERSE_PROPERTY="invalid reverse property",u.INVALID_REVERSE_PROPERTY_MAP="invalid reverse property map",u.INVALID_REVERSE_PROPERTY_VALUE="invalid reverse property value",u.INVALID_SCOPED_CONTEXT="invalid scoped context",u.INVALID_SCRIPT_ELEMENT="invalid script element",u.INVALID_SET_OR_LIST_OBJECT="invalid set or list object",u.INVALID_TERM_DEFINITION="invalid term definition",u.INVALID_TYPE_MAPPING="invalid type mapping",u.INVALID_TYPE_VALUE="invalid type value",u.INVALID_TYPED_VALUE="invalid typed value",u.INVALID_VALUE_OBJECT="invalid value object",u.INVALID_VALUE_OBJECT_VALUE="invalid value object value",u.INVALID_VOCAB_MAPPING="invalid vocab mapping",u.IRI_CONFUSED_WITH_PREFIX="IRI confused with prefix",u.KEYWORD_REDEFINITION="keyword redefinition",u.LOADING_DOCUMENT_FAILED="loading document failed",u.LOADING_REMOTE_CONTEXT_FAILED="loading remote context failed",u.MULTIPLE_CONTEXT_LINK_HEADERS="multiple context link headers",u.PROCESSING_MODE_CONFLICT="processing mode conflict",u.PROTECTED_TERM_REDEFINITION="protected term redefinition",u.CONTEXT_OVERFLOW="context overflow",u.INVALID_BASE_DIRECTION="invalid base direction",u.RECURSIVE_CONTEXT_INCLUSION="recursive context inclusion",u.INVALID_STREAMING_KEY_ORDER="invalid streaming key order",u.INVALID_EMBEDDED_NODE="invalid embedded node",u.INVALID_ANNOTATION="invalid annotation"}(t.ERROR_CODES||(t.ERROR_CODES={}))}(o_)),o_}var Nc={},u_,Qx;function Nq(){if(Qx)return u_;Qx=1;var t=/^utf-?8|ascii|utf-?16-?le|ucs-?2|base-?64|latin-?1$/i,e=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,u=/\s|\uFEFF|\xA0/,s=/\r?\n[\x20\x09]+/g,n=/[;,"]/,r=/[;,"]|\s/,a=/^[!#$%&'*+\-\.^_`|~\da-zA-Z]+$/,o={IDLE:1,URI:2,ATTR:4};function l(y){return y.replace(e,"")}function c(y){return u.test(y)}function d(y,b){for(;c(y[b]);)b++;return b}function h(y){return r.test(y)||!a.test(y)}function f(y,b){return Object.keys(y).length===Object.keys(b).length&&Object.keys(y).every(g=>g in b&&y[g]===b[g])}class p{constructor(b){this.refs=[],b&&this.parse(b)}rel(b){for(var g=[],m=b.toLowerCase(),v=0;vf(g,b))||this.refs.push(b),this}has(b,g){b=b.toLowerCase(),g=g.toLowerCase();for(var m=0;m",_);if(S===-1)throw new Error("Expected end of URI delimiter at offset "+_);w={uri:b.slice(_+1,S)},_=S,m=o.URI}else throw new Error('Unexpected character "'+b[_]+'" at offset '+_);_++}else if(m===o.URI)if(c(b[_])){_++;continue}else if(b[_]===";")m=o.ATTR,_++;else if(b[_]===",")m=o.IDLE,_++;else throw new Error('Unexpected character "'+b[_]+'" at offset '+_);else if(m===o.ATTR){if(b[_]===";"||c(b[_])){_++;continue}var S=b.indexOf("=",_);S===-1&&(S=b.indexOf(";",_)),S===-1&&(S=b.length);var A=l(b.slice(_,S)).toLowerCase(),D="";if(_=S+1,_=d(b,_),b[_]==='"')for(_++;_"),b.push(g);return b.join(", ")}}return p.isCompatibleEncoding=function(y){return t.test(y)},p.parse=function(y,b){return new p().parse(y,b)},p.isSingleOccurenceAttr=function(y){return y==="rel"||y==="type"||y==="media"||y==="title"||y==="title*"},p.isTokenAttr=function(y){return y==="rel"||y==="type"||y==="anchor"},p.escapeQuotes=function(y){return y.replace(/"/g,'\\"')},p.expandRelations=function(y){var b=y.rel.split(" ");return b.map(function(g){var m=Object.assign({},y);return m.rel=g,m})},p.parseExtendedValue=function(y){var b=/([^']+)?(?:'([^']*)')?(.+)/.exec(y);return{language:b[2].toLowerCase(),encoding:p.isCompatibleEncoding(b[1])?null:b[1].toLowerCase(),value:p.isCompatibleEncoding(b[1])?decodeURIComponent(b[3]):b[3]}},p.formatExtendedAttribute=function(y,b){var g=(b.encoding||"utf-8").toUpperCase(),m=b.language||"en",v="";return Buffer.isBuffer(b.value)&&p.isCompatibleEncoding(g)?v=b.value.toString(g):Buffer.isBuffer(b.value)?v=b.value.toString("hex").replace(/[0-9a-f]{2}/gi,"%$1"):v=encodeURIComponent(b.value),y+"="+g+"'"+m+"'"+v},p.formatAttribute=function(y,b){return Array.isArray(b)?b.map(g=>p.formatAttribute(y,g)).join("; "):y[y.length-1]==="*"||typeof b!="string"?p.formatExtendedAttribute(y,b):(p.isTokenAttr(y)?b=h(b)?'"'+p.escapeQuotes(b)+'"':p.escapeQuotes(b):h(b)&&(b=encodeURIComponent(b),b=b.replace(/%20/g," ").replace(/%2C/g,",").replace(/%3B/g,";"),b='"'+b+'"'),y+"="+b)},u_=p,u_}var Hx;function Cq(){if(Hx)return Nc;Hx=1,Object.defineProperty(Nc,"__esModule",{value:!0}),Nc.FetchDocumentLoader=void 0,Dq();const t=Py(),e=Nq(),u=Pi();let s=class{constructor(r){this.fetcher=r}async load(r){const a=await(this.fetcher||fetch)(r,{headers:new Headers({accept:"application/ld+json"})});if(a.ok&&a.headers){let o=a.headers.get("Content-Type");if(o){const l=o.indexOf(";");l>0&&(o=o.substr(0,l))}if(o==="application/ld+json")return await a.json();if(a.headers.has("Link")){let l;if(a.headers.forEach((c,d)=>{if(d==="link"){const h=(0,e.parse)(c);for(const f of h.get("type","application/ld+json"))if(f.rel==="alternate"){if(l)throw new Error("Multiple JSON-LD alternate links were found on "+r);l=(0,u.resolve)(f.uri,r)}}}),l)return this.load(l)}throw new t.ErrorCoded(`Unsupported JSON-LD media type ${o}`,t.ERROR_CODES.LOADING_DOCUMENT_FAILED)}else throw new Error(a.statusText||`Status code: ${a.status}`)}};return Nc.FetchDocumentLoader=s,Nc}var c_={},Cc={},$x;function JT(){if($x)return Cc;$x=1,Object.defineProperty(Cc,"__esModule",{value:!0}),Cc.Util=void 0;class t{static isCompactIri(u){return u.indexOf(":")>0&&!(u&&u[0]==="#")}static getPrefix(u,s){if(u&&u[0]==="#")return null;const n=u.indexOf(":");if(n>=0){if(u.length>n+1&&u.charAt(n+1)==="/"&&u.charAt(n+2)==="/")return null;const r=u.substr(0,n);if(r==="_")return null;if(s[r])return r}return null}static getContextValueId(u){if(u===null||typeof u=="string")return u;const s=u["@id"];return s||null}static isSimpleTermDefinitionPrefix(u,s){return!t.isPotentialKeyword(u)&&(s.allowPrefixNonGenDelims||typeof u=="string"&&(u[0]==="_"||t.isPrefixIriEndingWithGenDelim(u)))}static isPotentialKeyword(u){return typeof u=="string"&&t.KEYWORD_REGEX.test(u)}static isPrefixIriEndingWithGenDelim(u){return t.ENDS_WITH_GEN_DELIM.test(u)}static isPrefixValue(u){return u&&(typeof u=="string"||u&&typeof u=="object")}static isValidIri(u){return!!(u&&t.IRI_REGEX.test(u))}static isValidIriWeak(u){return!!u&&u[0]!==":"&&t.IRI_REGEX_WEAK.test(u)}static isValidKeyword(u){return t.VALID_KEYWORDS[u]}static isTermProtected(u,s){const n=u[s];return typeof n!="string"&&n&&n["@protected"]}static hasProtectedTerms(u){for(const s of Object.keys(u))if(t.isTermProtected(u,s))return!0;return!1}static isReservedInternalKeyword(u){return u.startsWith("@__")}static deepEqual(u,s){const n=Object.keys(u),r=Object.keys(s);return n.length!==r.length?!1:n.every(a=>{const o=u[a],l=s[a];return o===l||o!==null&&l!==null&&typeof o=="object"&&typeof l=="object"&&this.deepEqual(o,l)})}}return t.IRI_REGEX=/^([A-Za-z][A-Za-z0-9+-.]*|_):[^ "<>{}|\\\[\]`#]*(#[^#]*)?$/,t.IRI_REGEX_WEAK=/(?::[^:])|\//,t.KEYWORD_REGEX=/^@[a-z]+$/i,t.ENDS_WITH_GEN_DELIM=/[:/?#\[\]@]$/,t.REGEX_LANGUAGE_TAG=/^[a-zA-Z]+(-[a-zA-Z0-9]+)*$/,t.REGEX_DIRECTION_TAG=/^(ltr)|(rtl)$/,t.VALID_KEYWORDS={"@annotation":!0,"@base":!0,"@container":!0,"@context":!0,"@direction":!0,"@graph":!0,"@id":!0,"@import":!0,"@included":!0,"@index":!0,"@json":!0,"@language":!0,"@list":!0,"@nest":!0,"@none":!0,"@prefix":!0,"@propagate":!0,"@protected":!0,"@reverse":!0,"@set":!0,"@type":!0,"@value":!0,"@version":!0,"@vocab":!0},t.EXPAND_KEYS_BLACKLIST=["@base","@vocab","@language","@version","@direction"],t.ALIAS_DOMAIN_BLACKLIST=["@container","@graph","@id","@index","@list","@nest","@none","@prefix","@reverse","@set","@type","@value","@version"],t.ALIAS_RANGE_BLACKLIST=["@context","@preserve"],t.CONTAINERS=["@list","@set","@index","@language","@graph","@id","@type"],t.CONTAINERS_1_0=["@list","@set","@index"],Cc.Util=t,Cc}var Vx;function jq(){return Vx||(Vx=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.defaultExpandOptions=t.JsonLdContextNormalized=void 0;const e=Pi(),u=Py(),s=JT();class n{constructor(a){this.contextRaw=a}getContextRaw(){return this.contextRaw}expandTerm(a,o,l=t.defaultExpandOptions){const c=this.contextRaw[a];if(c===null||c&&c["@id"]===null)return null;let d=!0;if(c&&o){const g=s.Util.getContextValueId(c);if(g&&g!==a)if(typeof g!="string"||!s.Util.isValidIri(g)&&!s.Util.isValidKeyword(g))s.Util.isPotentialKeyword(g)||(d=!1);else return g}const h=s.Util.getPrefix(a,this.contextRaw),f=this.contextRaw["@vocab"],p=(!!f||f==="")&&f.indexOf(":")<0,y=this.contextRaw["@base"],b=s.Util.isPotentialKeyword(a);if(h){const g=this.contextRaw[h],m=s.Util.getContextValueId(g);if(m){if(typeof g=="string"||!l.allowPrefixForcing){if(!s.Util.isSimpleTermDefinitionPrefix(m,l))return a}else if(m[0]!=="_"&&!b&&!g["@prefix"]&&!(a in this.contextRaw))return a;return m+a.substr(h.length+1)}}else if(o&&(f||f===""||l.allowVocabRelativeToBase&&y&&p)&&!b&&!s.Util.isCompactIri(a))if(p){if(l.allowVocabRelativeToBase)return(f||y?(0,e.resolve)(f,y):"")+a;throw new u.ErrorCoded(`Relative vocab expansion for term '${a}' with vocab '${f}' is not allowed.`,u.ERROR_CODES.INVALID_VOCAB_MAPPING)}else return f+a;else if(!o&&y&&!b&&!s.Util.isCompactIri(a))return(0,e.resolve)(a,y);if(d)return a;throw new u.ErrorCoded(`Invalid IRI mapping found for context entry '${a}': '${JSON.stringify(c)}'`,u.ERROR_CODES.INVALID_IRI_MAPPING)}compactIri(a,o){if(o&&this.contextRaw["@vocab"]&&a.startsWith(this.contextRaw["@vocab"]))return a.substr(this.contextRaw["@vocab"].length);if(!o&&this.contextRaw["@base"]&&a.startsWith(this.contextRaw["@base"]))return a.substr(this.contextRaw["@base"].length);const l={prefix:"",suffix:a};for(const c in this.contextRaw){const d=this.contextRaw[c];if(d&&!s.Util.isPotentialKeyword(c)){const h=s.Util.getContextValueId(d);if(a.startsWith(h)){const f=a.substr(h.length);if(f)f.length=0&&(h!=="@type"||typeof d[h]=="object"&&!(d[h]["@protected"]||d[h]["@container"]==="@set")))throw new e.ErrorCoded(`Keywords can not be aliased to something else. +Tried mapping ${h} to ${JSON.stringify(f)}`,e.ERROR_CODES.KEYWORD_REDEFINITION);if(n.Util.ALIAS_RANGE_BLACKLIST.indexOf(n.Util.getContextValueId(f))>=0)throw new e.ErrorCoded(`Aliasing to certain keywords is not allowed. +Tried mapping ${h} to ${JSON.stringify(f)}`,e.ERROR_CODES.INVALID_KEYWORD_ALIAS);if(f&&n.Util.isPotentialKeyword(n.Util.getContextValueId(f))&&f["@prefix"]===!0)throw new e.ErrorCoded(`Tried to use keyword aliases as prefix: '${h}': '${JSON.stringify(f)}'`,e.ERROR_CODES.INVALID_TERM_DEFINITION);for(;n.Util.isPrefixValue(d[h]);){const p=d[h];let y=!1;if(typeof p=="string")d[h]=o.expandTerm(p,!0),y=y||p!==d[h];else{const b=p["@id"],g=p["@type"],m=!("@prefix"in p)||n.Util.isValidIri(h);if("@id"in p)b!=null&&typeof b=="string"&&(d[h]=Object.assign(Object.assign({},d[h]),{"@id":o.expandTerm(b,!0)}),y=y||b!==d[h]["@id"]);else if(!n.Util.isPotentialKeyword(h)&&m){const v=o.expandTerm(h,!0);v!==h&&(d[h]=Object.assign(Object.assign({},d[h]),{"@id":v}),y=!0)}if(g&&typeof g=="string"&&g!=="@vocab"&&(!p["@container"]||!p["@container"]["@type"])&&m){let v=o.expandTerm(g,!0);l&&g===v&&(v=o.expandTerm(g,!1)),v!==g&&(y=!0,d[h]=Object.assign(Object.assign({},d[h]),{"@type":v}))}}if(!y)break}}}normalize(o,{processingMode:l,normalizeLanguageTags:c}){if(c||l===1)for(const d of Object.keys(o))if(d==="@language"&&typeof o[d]=="string")o[d]=o[d].toLowerCase();else{const h=o[d];if(h&&typeof h=="object"&&typeof h["@language"]=="string"){const f=h["@language"].toLowerCase();f!==h["@language"]&&(o[d]=Object.assign(Object.assign({},h),{"@language":f}))}}}containersToHash(o){for(const l of Object.keys(o)){const c=o[l];if(c&&typeof c=="object"){if(typeof c["@container"]=="string")o[l]=Object.assign(Object.assign({},c),{"@container":{[c["@container"]]:!0}});else if(Array.isArray(c["@container"])){const d={};for(const h of c["@container"])d[h]=!0;o[l]=Object.assign(Object.assign({},c),{"@container":d})}}}}applyScopedProtected(o,{processingMode:l},c){if(l&&l>=1.1&&o["@protected"]){for(const d of Object.keys(o))if(!n.Util.isReservedInternalKeyword(d)&&!n.Util.isPotentialKeyword(d)&&!n.Util.isTermProtected(o,d)){const h=o[d];h&&typeof h=="object"?"@protected"in o[d]||(o[d]=Object.assign(Object.assign({},o[d]),{"@protected":!0})):(o[d]={"@id":h,"@protected":!0},n.Util.isSimpleTermDefinitionPrefix(h,c)&&(o[d]=Object.assign(Object.assign({},o[d]),{"@prefix":!0})))}delete o["@protected"]}}validateKeywordRedefinitions(o,l,c,d){for(const h of d??Object.keys(l))if(n.Util.isTermProtected(o,h)&&(typeof l[h]=="string"?l[h]={"@id":l[h],"@protected":!0}:l[h]=Object.assign(Object.assign({},l[h]),{"@protected":!0}),!n.Util.deepEqual(o[h],l[h])))throw new e.ErrorCoded(`Attempted to override the protected keyword ${h} from ${JSON.stringify(n.Util.getContextValueId(o[h]))} to ${JSON.stringify(n.Util.getContextValueId(l[h]))}`,e.ERROR_CODES.PROTECTED_TERM_REDEFINITION)}validate(o,{processingMode:l}){for(const c of Object.keys(o)){if(n.Util.isReservedInternalKeyword(c))continue;if(c==="")throw new e.ErrorCoded(`The empty term is not allowed, got: '${c}': '${JSON.stringify(o[c])}'`,e.ERROR_CODES.INVALID_TERM_DEFINITION);const d=o[c],h=typeof d;if(n.Util.isPotentialKeyword(c)){switch(c.substr(1)){case"vocab":if(d!==null&&h!=="string")throw new e.ErrorCoded(`Found an invalid @vocab IRI: ${d}`,e.ERROR_CODES.INVALID_VOCAB_MAPPING);break;case"base":if(d!==null&&h!=="string")throw new e.ErrorCoded(`Found an invalid @base IRI: ${o[c]}`,e.ERROR_CODES.INVALID_BASE_IRI);break;case"language":d!==null&&js.validateLanguage(d,!0,e.ERROR_CODES.INVALID_DEFAULT_LANGUAGE);break;case"version":if(d!==null&&h!=="number")throw new e.ErrorCoded(`Found an invalid @version number: ${d}`,e.ERROR_CODES.INVALID_VERSION_VALUE);break;case"direction":d!==null&&js.validateDirection(d,!0);break;case"propagate":if(l===1)throw new e.ErrorCoded(`Found an illegal @propagate keyword: ${d}`,e.ERROR_CODES.INVALID_CONTEXT_ENTRY);if(d!==null&&h!=="boolean")throw new e.ErrorCoded(`Found an invalid @propagate value: ${d}`,e.ERROR_CODES.INVALID_PROPAGATE_VALUE);break}if(n.Util.isValidKeyword(c)&&n.Util.isValidKeyword(n.Util.getContextValueId(d)))throw new e.ErrorCoded(`Illegal keyword alias in term value, found: '${c}': '${n.Util.getContextValueId(d)}'`,e.ERROR_CODES.KEYWORD_REDEFINITION);continue}if(d!==null)switch(h){case"string":if(n.Util.getPrefix(d,o)===c)throw new e.ErrorCoded(`Detected cyclical IRI mapping in context entry: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.CYCLIC_IRI_MAPPING);if(n.Util.isValidIriWeak(c)){if(d==="@type")throw new e.ErrorCoded(`IRIs can not be mapped to @type, found: '${c}': '${d}'`,e.ERROR_CODES.INVALID_IRI_MAPPING);if(n.Util.isValidIri(d)&&d!==new s.JsonLdContextNormalized(o).expandTerm(c))throw new e.ErrorCoded(`IRIs can not be mapped to other IRIs, found: '${c}': '${d}'`,e.ERROR_CODES.INVALID_IRI_MAPPING)}break;case"object":if(!n.Util.isCompactIri(c)&&!("@id"in d)&&(d["@type"]==="@id"?!o["@base"]:!o["@vocab"]))throw new e.ErrorCoded(`Missing @id in context entry: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_IRI_MAPPING);for(const f of Object.keys(d)){const p=d[f];if(p)switch(f){case"@id":if(n.Util.isValidKeyword(p)&&p!=="@type"&&p!=="@id"&&p!=="@graph"&&p!=="@nest")throw new e.ErrorCoded(`Illegal keyword alias in term value, found: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_IRI_MAPPING);if(n.Util.isValidIriWeak(c)){if(p==="@type")throw new e.ErrorCoded(`IRIs can not be mapped to @type, found: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_IRI_MAPPING);if(n.Util.isValidIri(p)&&p!==new s.JsonLdContextNormalized(o).expandTerm(c))throw new e.ErrorCoded(`IRIs can not be mapped to other IRIs, found: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_IRI_MAPPING)}if(typeof p!="string")throw new e.ErrorCoded(`Detected non-string @id in context entry: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_IRI_MAPPING);if(n.Util.getPrefix(p,o)===c)throw new e.ErrorCoded(`Detected cyclical IRI mapping in context entry: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.CYCLIC_IRI_MAPPING);break;case"@type":if(d["@container"]==="@type"&&p!=="@id"&&p!=="@vocab")throw new e.ErrorCoded(`@container: @type only allows @type: @id or @vocab, but got: '${c}': '${p}'`,e.ERROR_CODES.INVALID_TYPE_MAPPING);if(typeof p!="string")throw new e.ErrorCoded(`The value of an '@type' must be a string, got '${JSON.stringify(h)}'`,e.ERROR_CODES.INVALID_TYPE_MAPPING);if(p!=="@id"&&p!=="@vocab"&&(l===1||p!=="@json")&&(l===1||p!=="@none")&&(p[0]==="_"||!n.Util.isValidIri(p)))throw new e.ErrorCoded(`A context @type must be an absolute IRI, found: '${c}': '${p}'`,e.ERROR_CODES.INVALID_TYPE_MAPPING);break;case"@reverse":if(typeof p=="string"&&d["@id"]&&d["@id"]!==p)throw new e.ErrorCoded(`Found non-matching @id and @reverse term values in '${c}':'${p}' and '${d["@id"]}'`,e.ERROR_CODES.INVALID_REVERSE_PROPERTY);if("@nest"in d)throw new e.ErrorCoded(`@nest is not allowed in the reverse property '${c}'`,e.ERROR_CODES.INVALID_REVERSE_PROPERTY);break;case"@container":if(l===1&&(Object.keys(p).length>1||n.Util.CONTAINERS_1_0.indexOf(Object.keys(p)[0])<0))throw new e.ErrorCoded(`Invalid term @container for '${c}' ('${Object.keys(p)}') in 1.0, must be only one of ${n.Util.CONTAINERS_1_0.join(", ")}`,e.ERROR_CODES.INVALID_CONTAINER_MAPPING);for(const y of Object.keys(p)){if(y==="@list"&&d["@reverse"])throw new e.ErrorCoded(`Term value can not be @container: @list and @reverse at the same time on '${c}'`,e.ERROR_CODES.INVALID_REVERSE_PROPERTY);if(n.Util.CONTAINERS.indexOf(y)<0)throw new e.ErrorCoded(`Invalid term @container for '${c}' ('${y}'), must be one of ${n.Util.CONTAINERS.join(", ")}`,e.ERROR_CODES.INVALID_CONTAINER_MAPPING)}break;case"@language":js.validateLanguage(p,!0,e.ERROR_CODES.INVALID_LANGUAGE_MAPPING);break;case"@direction":js.validateDirection(p,!0);break;case"@prefix":if(p!==null&&typeof p!="boolean")throw new e.ErrorCoded(`Found an invalid term @prefix boolean in: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_PREFIX_VALUE);if(!("@id"in d)&&!n.Util.isValidIri(c))throw new e.ErrorCoded(`Invalid @prefix definition for '${c}' ('${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_TERM_DEFINITION);break;case"@index":if(l===1||!d["@container"]||!d["@container"]["@index"])throw new e.ErrorCoded(`Attempt to add illegal key to value object: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_TERM_DEFINITION);break;case"@nest":if(n.Util.isPotentialKeyword(p)&&p!=="@nest")throw new e.ErrorCoded(`Found an invalid term @nest value in: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_NEST_VALUE)}}break;default:throw new e.ErrorCoded(`Found an invalid term value: '${c}': '${d}'`,e.ERROR_CODES.INVALID_TERM_DEFINITION)}}}applyBaseEntry(o,l,c){return typeof o=="string"||(c&&!("@base"in o)&&l.parentContext&&typeof l.parentContext=="object"&&"@base"in l.parentContext&&(o["@base"]=l.parentContext["@base"],l.parentContext["@__baseDocument"]&&(o["@__baseDocument"]=!0)),l.baseIRI&&!l.external&&("@base"in o?o["@base"]!==null&&typeof o["@base"]=="string"&&!n.Util.isValidIri(o["@base"])&&(o["@base"]=(0,t.resolve)(o["@base"],l.parentContext&&l.parentContext["@base"]||l.baseIRI)):(o["@base"]=l.baseIRI,o["@__baseDocument"]=!0))),o}normalizeContextIri(o,l){if(!n.Util.isValidIri(o))try{o=(0,t.resolve)(o,l)}catch{throw new Error(`Invalid context IRI: ${o}`)}return this.redirectSchemaOrgHttps&&o.startsWith("http://schema.org")&&(o="https://schema.org/"),o}async parseInnerContexts(o,l,c){for(const d of c??Object.keys(o)){const h=o[d];if(h&&typeof h=="object"&&"@context"in h&&h["@context"]!==null&&!l.ignoreScopedContexts){if(this.validateContext)try{const f=Object.assign(Object.assign({},o),{[d]:Object.assign({},o[d])});delete f[d]["@context"],await this.parse(h["@context"],Object.assign(Object.assign({},l),{external:!1,parentContext:f,ignoreProtection:!0,ignoreRemoteScopedContexts:!0,ignoreScopedContexts:!0}))}catch(f){throw new e.ErrorCoded(f.message,e.ERROR_CODES.INVALID_SCOPED_CONTEXT)}o[d]=Object.assign(Object.assign({},h),{"@context":(await this.parse(h["@context"],Object.assign(Object.assign({},l),{external:!1,minimalProcessing:!0,ignoreRemoteScopedContexts:!0,parentContext:o}))).getContextRaw()})}}return o}async parse(o,l={},c={}){const{baseIRI:d,parentContext:h,external:f,processingMode:p=js.DEFAULT_PROCESSING_MODE,normalizeLanguageTags:y,ignoreProtection:b,minimalProcessing:g}=l,m=l.remoteContexts||{};if(Object.keys(m).length>=this.remoteContextsDepthLimit)throw new e.ErrorCoded("Detected an overflow in remote context inclusions: "+Object.keys(m),e.ERROR_CODES.CONTEXT_OVERFLOW);if(o==null){if(!b&&h&&n.Util.hasProtectedTerms(h))throw new e.ErrorCoded("Illegal context nullification when terms are protected",e.ERROR_CODES.INVALID_CONTEXT_NULLIFICATION);return new s.JsonLdContextNormalized(this.applyBaseEntry({},l,!1))}else if(typeof o=="string"){const v=this.normalizeContextIri(o,d),_=this.getOverriddenLoad(v,l);if(_)return new s.JsonLdContextNormalized(_);const w=await this.parse(await this.load(v),Object.assign(Object.assign({},l),{baseIRI:v,external:!0,remoteContexts:Object.assign(Object.assign({},m),{[v]:!0})}));return this.applyBaseEntry(w.getContextRaw(),l,!0),w}else if(Array.isArray(o)){const v=[],_=await Promise.all(o.map((S,A)=>{if(typeof S=="string"){const D=this.normalizeContextIri(S,d);v[A]=D;const L=this.getOverriddenLoad(D,l);return L||this.load(D)}else return S}));if(g)return new s.JsonLdContextNormalized(_);const w=await _.reduce((S,A,D)=>S.then(L=>this.parse(A,Object.assign(Object.assign({},l),{baseIRI:v[D]||l.baseIRI,external:!!v[D]||l.external,parentContext:L.getContextRaw(),remoteContexts:v[D]?Object.assign(Object.assign({},m),{[v[D]]:!0}):m}),{skipValidation:D<_.length-1})),Promise.resolve(new s.JsonLdContextNormalized(h||{})));return this.applyBaseEntry(w.getContextRaw(),l,!0),w}else if(typeof o=="object"){if("@context"in o)return await this.parse(o["@context"],l);if(o=Object.assign({},o),f&&delete o["@base"],this.applyBaseEntry(o,l,!0),this.containersToHash(o),g)return new s.JsonLdContextNormalized(o);let v={};if("@import"in o)if(p>=1.1){if(typeof o["@import"]!="string")throw new e.ErrorCoded("An @import value must be a string, but got "+typeof o["@import"],e.ERROR_CODES.INVALID_IMPORT_VALUE);v=await this.loadImportContext(this.normalizeContextIri(o["@import"],d)),delete o["@import"]}else throw new e.ErrorCoded("Context importing is not supported in JSON-LD 1.0",e.ERROR_CODES.INVALID_CONTEXT_ENTRY);this.applyScopedProtected(v,{processingMode:p},s.defaultExpandOptions);const _=Object.assign(v,o);this.idifyReverseTerms(_),this.normalize(_,{processingMode:p,normalizeLanguageTags:y}),this.applyScopedProtected(_,{processingMode:p},s.defaultExpandOptions);const w=Object.keys(_),S=[];if(typeof h=="object")for(const D in h)D in _?S.push(D):_[D]=h[D];await this.parseInnerContexts(_,l,w);const A=new s.JsonLdContextNormalized(_);return(_&&_["@version"]||js.DEFAULT_PROCESSING_MODE)>=1.1&&(o["@vocab"]&&typeof o["@vocab"]=="string"||o["@vocab"]==="")&&(h&&"@vocab"in h&&o["@vocab"].indexOf(":")<0?_["@vocab"]=h["@vocab"]+o["@vocab"]:(n.Util.isCompactIri(o["@vocab"])||o["@vocab"]in _)&&(_["@vocab"]=A.expandTerm(o["@vocab"],!0))),this.expandPrefixedTerms(A,this.expandContentTypeToBase,w),!b&&h&&p>=1.1&&this.validateKeywordRedefinitions(h,_,s.defaultExpandOptions,S),this.validateContext&&!c.skipValidation&&this.validate(_,{processingMode:p}),A}else throw new e.ErrorCoded(`Tried parsing a context that is not a string, array or object, but got ${o}`,e.ERROR_CODES.INVALID_LOCAL_CONTEXT)}async load(o){const l=this.documentCache[o];if(l)return l;let c;try{c=await this.documentLoader.load(o)}catch(d){throw new e.ErrorCoded(`Failed to load remote context ${o}: ${d.message}`,e.ERROR_CODES.LOADING_REMOTE_CONTEXT_FAILED)}if(!("@context"in c))throw new e.ErrorCoded(`Missing @context in remote context at ${o}`,e.ERROR_CODES.INVALID_REMOTE_CONTEXT);return this.documentCache[o]=c["@context"]}getOverriddenLoad(o,l){if(o in(l.remoteContexts||{})){if(l.ignoreRemoteScopedContexts)return o;throw new e.ErrorCoded("Detected a cyclic context inclusion of "+o,e.ERROR_CODES.RECURSIVE_CONTEXT_INCLUSION)}return null}async loadImportContext(o){let l=await this.load(o);if(typeof l!="object"||Array.isArray(l))throw new e.ErrorCoded("An imported context must be a single object: "+o,e.ERROR_CODES.INVALID_REMOTE_CONTEXT);if("@import"in l)throw new e.ErrorCoded("An imported context can not import another context: "+o,e.ERROR_CODES.INVALID_CONTEXT_ENTRY);return l=Object.assign({},l),this.containersToHash(l),l}};return r.DEFAULT_PROCESSING_MODE=1.1,Dc.ContextParser=r,Dc}var l_={},zx;function vG(){return zx||(zx=1,Object.defineProperty(l_,"__esModule",{value:!0})),l_}var d_={},Gx;function wG(){return Gx||(Gx=1,Object.defineProperty(d_,"__esModule",{value:!0})),d_}var Wx;function Jr(){return Wx||(Wx=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(_G(),t),u(Py(),t),u(Cq(),t),u(vG(),t),u(wG(),t),u(jq(),t),u(JT(),t)}(a_)),a_}var Jx;function Lq(){if(Jx)return Pc;Jx=1,Object.defineProperty(Pc,"__esModule",{value:!0}),Pc.Util=void 0;const t=Et(),e=Jr(),u=Ot();class s{constructor(r){this.nodeHandlers={},this.nodeValueHandlers={},this.directiveNodeHandlers={},this.settings=r,this.dataFactory=r.dataFactory||new t.DataFactory,this.operationFactory=new u.Factory(this.dataFactory),this.contextParser=new e.ContextParser}registerNodeHandler(r){this.nodeHandlers[r.targetKind]=r}registerNodeValueHandler(r){this.nodeValueHandlers[r.targetKind]=r}registerDirectiveNodeHandler(r){this.directiveNodeHandlers[r.targetKind]=r}handleNode(r,a){const o=this.nodeHandlers[r.kind];if(!o)throw new Error(`Unsupported GraphQL node '${r.kind}'`);return o.handle(r,a)}handleNodeValue(r,a,o){const l=this.nodeValueHandlers[r.kind];if(!l)throw new Error(`Unsupported GraphQL value node '${r.kind}'`);return l.handle(r,a,o)}handleDirectiveNode(r,a){const o=this.directiveNodeHandlers[r.directive.name.value];return o?o.handle(r,a):null}joinOperations(r){if(r.length===1)return r[0];const a=[],o=[];for(const l of r)l.type==="bgp"?a.push(l):o.push(l);if(a.length===r.length)return this.joinOperationsAsBgp(a);if(a.length===r.length-1&&o[0].type==="leftjoin"&&o[0].input[0].type==="bgp"){const l=o[0];return a.push(l.input[0]),this.operationFactory.createLeftJoin(this.joinOperationsAsBgp(a),l.input[1])}else return o.length===r.length?this.joinOperationsAsNestedJoin(o):this.joinOperationsAsNestedJoin([this.joinOperationsAsBgp(a),this.joinOperationsAsNestedJoin(o)])}joinOperationsAsBgp(r){return this.operationFactory.createBgp([].concat.apply([],r.map(a=>a.patterns)))}joinOperationsAsNestedJoin(r){return this.operationFactory.createJoin(r)}appendFieldToPath(r,a){return r.concat([a])}getFieldLabel(r){return(r.alias?r.alias:r.name).value}nameToVariable(r,a){return this.dataFactory.variable((a.path.length?a.path.join(this.settings.variableDelimiter)+this.settings.variableDelimiter:"")+r)}valueToNamedNode(r,a){const o=a.expandTerm(r,!0);if(this.settings.requireContext&&!o)throw new Error("No context entry was found for "+r);return this.dataFactory.namedNode(o||r)}getArgument(r,a){if(r){for(const o of r)if(o.name.value===a)return o}}newTypePattern(r,a,o){return this.operationFactory.createPattern(r,this.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),this.valueToNamedNode(a.name.value,o.context),o.graph)}createQuadPattern(r,a,o,l,c){const d=this.valueToNamedNode(a.value,c);return c&&c.getContextRaw()[a.value]&&c.getContextRaw()[a.value]["@reverse"]?this.operationFactory.createPattern(o,d,r,l):this.operationFactory.createPattern(r,d,o,l)}createQuadPath(r,a,o,l,c,d){const h=this.valueToNamedNode(a.value,d);let f=this.operationFactory.createLink(h);for(const p of o.values){if(p.kind!=="EnumValue")throw new Error("Invalid value type for 'alt' argument, must be EnumValue, but got "+p.kind);f=this.operationFactory.createAlt([f,this.operationFactory.createLink(this.valueToNamedNode(p.value,d))])}return d&&d.getContextRaw()[a.value]&&d.getContextRaw()[a.value]["@reverse"]?this.operationFactory.createPath(l,f,r,c):this.operationFactory.createPath(r,f,l,c)}}return Pc.Util=s,Pc}var Xx;function SG(){if(Xx)return Ic;Xx=1;var t=I&&I.__awaiter||function(o,l,c,d){function h(f){return f instanceof c?f:new c(function(p){p(f)})}return new(c||(c=Promise))(function(f,p){function y(m){try{g(d.next(m))}catch(v){p(v)}}function b(m){try{g(d.throw(m))}catch(v){p(v)}}function g(m){m.done?f(m.value):h(m.value).then(y,b)}g((d=d.apply(o,l||[])).next())})};Object.defineProperty(Ic,"__esModule",{value:!0}),Ic.Converter=void 0;const e=mG,u=pq(),s=hq(),n=Iy(),r=Lq();class a{constructor(l){l=l||{},l.variableDelimiter=l.variableDelimiter||"_",l.expressionVariableCounter=l.expressionVariableCounter||0,this.util=new r.Util(l),this.initializeNodeHandlers(l)}static registerNodeHandlers(l,c){l.registerNodeHandler(new u.NodeHandlerDocument(l,c)),l.registerNodeHandler(new u.NodeHandlerDefinitionOperation(l,c)),l.registerNodeHandler(new u.NodeHandlerDefinitionFragment(l,c)),l.registerNodeHandler(new u.NodeHandlerSelectionFragmentSpread(l,c)),l.registerNodeHandler(new u.NodeHandlerSelectionInlineFragment(l,c)),l.registerNodeHandler(new u.NodeHandlerSelectionField(l,c))}static registerNodeValueHandlers(l,c){l.registerNodeValueHandler(new u.NodeValueHandlerVariable(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerInt(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerFloat(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerString(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerBoolean(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerNull(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerEnum(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerList(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerObject(l,c))}static registerDirectiveNodeHandlers(l,c){l.registerDirectiveNodeHandler(new s.DirectiveNodeHandlerInclude(l,c)),l.registerDirectiveNodeHandler(new s.DirectiveNodeHandlerOptional(l,c)),l.registerDirectiveNodeHandler(new s.DirectiveNodeHandlerPlural(l,c)),l.registerDirectiveNodeHandler(new s.DirectiveNodeHandlerSingle(l,c)),l.registerDirectiveNodeHandler(new s.DirectiveNodeHandlerSkip(l,c))}graphqlToSparqlAlgebra(l,c,d){return t(this,void 0,void 0,function*(){return this.graphqlToSparqlAlgebraRawContext(l,yield this.util.contextParser.parse(c),d)})}graphqlToSparqlAlgebraRawContext(l,c,d){d=d||{};const h=typeof l=="string"?(0,e.parse)(l):l,f=this.indexFragments(h),p={context:c,fragmentDefinitions:f,graph:this.util.dataFactory.defaultGraph(),path:[],singularizeState:n.SingularizeState.PLURAL,singularizeVariables:d.singularizeVariables||{},subject:null,terminalVariables:[],variablesDict:d.variablesDict||{},variablesMetaDict:{}};return this.util.handleNode(h,p)}indexFragments(l){const c={},d=[];for(const h of l.definitions)h.kind==="FragmentDefinition"?c[h.name.value]=h:d.push(h);return l.definitions=d,c}initializeNodeHandlers(l){a.registerNodeHandlers(this.util,l),a.registerNodeValueHandlers(this.util,l),a.registerDirectiveNodeHandlers(this.util,l)}}return Ic.Converter=a,Ic}var f_={},Kx;function TG(){return Kx||(Kx=1,Object.defineProperty(f_,"__esModule",{value:!0})),f_}var Yx;function AG(){return Yx||(Yx=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(pq(),t),u(SG(),t),u(Iy(),t),u(TG(),t),u(Lq(),t)}(Kg)),Kg}var Zx;function EG(){if(Zx)return nc;Zx=1,Object.defineProperty(nc,"__esModule",{value:!0}),nc.ActorQueryParseGraphql=void 0;const t=fq(),e=Lt,u=AG();let s=class extends t.ActorQueryParse{constructor(r){super(r),this.graphqlToSparql=new u.Converter({requireContext:!0})}async test(r){var a;if(((a=r.queryFormat)==null?void 0:a.language)!=="graphql")throw new Error("This actor can only parse GraphQL queries");return!0}async run(r){const a=r.context.get(e.KeysInitQuery.jsonLdContext)||{},o={singularizeVariables:r.context.get(e.KeysInitQuery.graphqlSingularizeVariables)};return{operation:await this.graphqlToSparql.graphqlToSparqlAlgebra(r.query,a,o)}}};return nc.ActorQueryParseGraphql=s,nc}var eI;function OG(){return eI||(eI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(EG(),t)}(Xg)),Xg}var h_={},jc={},p_={},Lc={},y_={},Mc={},tI;function Mq(){if(tI)return Mc;tI=1,Object.defineProperty(Mc,"__esModule",{value:!0}),Mc.ActorAbstractMediaTyped=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}async run(s){if("handle"in s){const n=s;return{handle:await this.runHandle(n.handle,n.handleMediaType,s.context)}}if("mediaTypes"in s)return{mediaTypes:await this.getMediaTypes(s.context)};if("mediaTypeFormats"in s)return{mediaTypeFormats:await this.getMediaTypeFormats(s.context)};throw new Error("Either a handle, mediaTypes or mediaTypeFormats action needs to be provided")}async test(s){if("handle"in s){const n=s;return{handle:await this.testHandle(n.handle,n.handleMediaType,s.context)}}if("mediaTypes"in s)return{mediaTypes:await this.testMediaType(s.context)};if("mediaTypeFormats"in s)return{mediaTypeFormats:await this.testMediaTypeFormats(s.context)};throw new Error("Either a handle, mediaTypes or mediaTypeFormats action needs to be provided")}};return Mc.ActorAbstractMediaTyped=e,Mc}var Fc={},rI;function RG(){if(rI)return Fc;rI=1,Object.defineProperty(Fc,"__esModule",{value:!0}),Fc.ActorAbstractMediaTypedFixed=void 0;const t=Mq();let e=class extends t.ActorAbstractMediaTyped{constructor(s){super(s);const n=this.priorityScale||this.priorityScale===0?this.priorityScale:1;if(this.mediaTypePriorities)for(const[r,[a,o]]of Object.entries(this.mediaTypePriorities).entries())this.mediaTypePriorities[a]=n*o;this.mediaTypePriorities=Object.freeze(this.mediaTypePriorities),this.mediaTypeFormats=Object.freeze(this.mediaTypeFormats)}async testHandle(s,n,r){if(!n||!(n in this.mediaTypePriorities))throw new Error(`Unrecognized media type: ${n}`);return await this.testHandleChecked(s,r)}async testMediaType(s){return!0}async getMediaTypes(s){return this.mediaTypePriorities}async testMediaTypeFormats(s){return!0}async getMediaTypeFormats(s){return this.mediaTypeFormats}};return Fc.ActorAbstractMediaTypedFixed=e,Fc}var nI;function iu(){return nI||(nI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Mq(),t),u(RG(),t)}(y_)),y_}var iI;function xG(){if(iI)return Lc;iI=1,Object.defineProperty(Lc,"__esModule",{value:!0}),Lc.ActorQueryResultSerialize=void 0;const t=iu();let e=class extends t.ActorAbstractMediaTyped{constructor(s){super(s)}};return Lc.ActorQueryResultSerialize=e,Lc}var qc={},aI;function IG(){if(aI)return qc;aI=1,Object.defineProperty(qc,"__esModule",{value:!0}),qc.ActorQueryResultSerializeFixedMediaTypes=void 0;const t=iu();let e=class extends t.ActorAbstractMediaTypedFixed{constructor(s){super(s)}async testHandleChecked(s,n){return!0}};return qc.ActorQueryResultSerializeFixedMediaTypes=e,qc}var sI;function Gi(){return sI||(sI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(xG(),t),u(IG(),t)}(p_)),p_}var b_={exports:{}},m_={exports:{}},g_={},Bc={},oI;function PG(){if(oI)return Bc;oI=1,Bc.byteLength=o,Bc.toByteArray=c,Bc.fromByteArray=f;for(var t=[],e=[],u=typeof Uint8Array<"u"?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",n=0,r=s.length;n0)throw new Error("Invalid string. Length must be a multiple of 4");var b=p.indexOf("=");b===-1&&(b=y);var g=b===y?0:4-b%4;return[b,g]}function o(p){var y=a(p),b=y[0],g=y[1];return(b+g)*3/4-g}function l(p,y,b){return(y+b)*3/4-b}function c(p){var y,b=a(p),g=b[0],m=b[1],v=new u(l(p,g,m)),_=0,w=m>0?g-4:g,S;for(S=0;S>16&255,v[_++]=y>>8&255,v[_++]=y&255;return m===2&&(y=e[p.charCodeAt(S)]<<2|e[p.charCodeAt(S+1)]>>4,v[_++]=y&255),m===1&&(y=e[p.charCodeAt(S)]<<10|e[p.charCodeAt(S+1)]<<4|e[p.charCodeAt(S+2)]>>2,v[_++]=y>>8&255,v[_++]=y&255),v}function d(p){return t[p>>18&63]+t[p>>12&63]+t[p>>6&63]+t[p&63]}function h(p,y,b){for(var g,m=[],v=y;vw?w:_+v));return g===1?(y=p[b-1],m.push(t[y>>2]+t[y<<4&63]+"==")):g===2&&(y=(p[b-2]<<8)+p[b-1],m.push(t[y>>10]+t[y>>4&63]+t[y<<2&63]+"=")),m.join("")}return Bc}var f1={};/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh */var uI;function DG(){return uI||(uI=1,f1.read=function(t,e,u,s,n){var r,a,o=n*8-s-1,l=(1<>1,d=-7,h=u?n-1:0,f=u?-1:1,p=t[e+h];for(h+=f,r=p&(1<<-d)-1,p>>=-d,d+=o;d>0;r=r*256+t[e+h],h+=f,d-=8);for(a=r&(1<<-d)-1,r>>=-d,d+=s;d>0;a=a*256+t[e+h],h+=f,d-=8);if(r===0)r=1-c;else{if(r===l)return a?NaN:(p?-1:1)*(1/0);a=a+Math.pow(2,s),r=r-c}return(p?-1:1)*a*Math.pow(2,r-s)},f1.write=function(t,e,u,s,n,r){var a,o,l,c=r*8-n-1,d=(1<>1,f=n===23?Math.pow(2,-24)-Math.pow(2,-77):0,p=s?0:r-1,y=s?1:-1,b=e<0||e===0&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(o=isNaN(e)?1:0,a=d):(a=Math.floor(Math.log(e)/Math.LN2),e*(l=Math.pow(2,-a))<1&&(a--,l*=2),a+h>=1?e+=f/l:e+=f*Math.pow(2,1-h),e*l>=2&&(a++,l/=2),a+h>=d?(o=0,a=d):a+h>=1?(o=(e*l-1)*Math.pow(2,n),a=a+h):(o=e*Math.pow(2,h-1)*Math.pow(2,n),a=0));n>=8;t[u+p]=o&255,p+=y,o/=256,n-=8);for(a=a<0;t[u+p]=a&255,p+=y,a/=256,c-=8);t[u+p-y]|=b*128}),f1}/*! + * The buffer module from node.js, for the browser. + * + * @author Feross Aboukhadijeh + * @license MIT + */var cI;function Wi(){return cI||(cI=1,function(t){const e=PG(),u=DG(),s=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=o,t.SlowBuffer=v,t.INSPECT_MAX_BYTES=50;const n=2147483647;t.kMaxLength=n,o.TYPED_ARRAY_SUPPORT=r(),!o.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function r(){try{const G=new Uint8Array(1),F={foo:function(){return 42}};return Object.setPrototypeOf(F,Uint8Array.prototype),Object.setPrototypeOf(G,F),G.foo()===42}catch{return!1}}Object.defineProperty(o.prototype,"parent",{enumerable:!0,get:function(){if(o.isBuffer(this))return this.buffer}}),Object.defineProperty(o.prototype,"offset",{enumerable:!0,get:function(){if(o.isBuffer(this))return this.byteOffset}});function a(G){if(G>n)throw new RangeError('The value "'+G+'" is invalid for option "size"');const F=new Uint8Array(G);return Object.setPrototypeOf(F,o.prototype),F}function o(G,F,Q){if(typeof G=="number"){if(typeof F=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return h(G)}return l(G,F,Q)}o.poolSize=8192;function l(G,F,Q){if(typeof G=="string")return f(G,F);if(ArrayBuffer.isView(G))return y(G);if(G==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof G);if(ce(G,ArrayBuffer)||G&&ce(G.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(ce(G,SharedArrayBuffer)||G&&ce(G.buffer,SharedArrayBuffer)))return b(G,F,Q);if(typeof G=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const te=G.valueOf&&G.valueOf();if(te!=null&&te!==G)return o.from(te,F,Q);const me=g(G);if(me)return me;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof G[Symbol.toPrimitive]=="function")return o.from(G[Symbol.toPrimitive]("string"),F,Q);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof G)}o.from=function(G,F,Q){return l(G,F,Q)},Object.setPrototypeOf(o.prototype,Uint8Array.prototype),Object.setPrototypeOf(o,Uint8Array);function c(G){if(typeof G!="number")throw new TypeError('"size" argument must be of type number');if(G<0)throw new RangeError('The value "'+G+'" is invalid for option "size"')}function d(G,F,Q){return c(G),G<=0?a(G):F!==void 0?typeof Q=="string"?a(G).fill(F,Q):a(G).fill(F):a(G)}o.alloc=function(G,F,Q){return d(G,F,Q)};function h(G){return c(G),a(G<0?0:m(G)|0)}o.allocUnsafe=function(G){return h(G)},o.allocUnsafeSlow=function(G){return h(G)};function f(G,F){if((typeof F!="string"||F==="")&&(F="utf8"),!o.isEncoding(F))throw new TypeError("Unknown encoding: "+F);const Q=_(G,F)|0;let te=a(Q);const me=te.write(G,F);return me!==Q&&(te=te.slice(0,me)),te}function p(G){const F=G.length<0?0:m(G.length)|0,Q=a(F);for(let te=0;te=n)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+n.toString(16)+" bytes");return G|0}function v(G){return+G!=G&&(G=0),o.alloc(+G)}o.isBuffer=function(F){return F!=null&&F._isBuffer===!0&&F!==o.prototype},o.compare=function(F,Q){if(ce(F,Uint8Array)&&(F=o.from(F,F.offset,F.byteLength)),ce(Q,Uint8Array)&&(Q=o.from(Q,Q.offset,Q.byteLength)),!o.isBuffer(F)||!o.isBuffer(Q))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(F===Q)return 0;let te=F.length,me=Q.length;for(let Oe=0,Ne=Math.min(te,me);Oeme.length?(o.isBuffer(Ne)||(Ne=o.from(Ne)),Ne.copy(me,Oe)):Uint8Array.prototype.set.call(me,Ne,Oe);else if(o.isBuffer(Ne))Ne.copy(me,Oe);else throw new TypeError('"list" argument must be an Array of Buffers');Oe+=Ne.length}return me};function _(G,F){if(o.isBuffer(G))return G.length;if(ArrayBuffer.isView(G)||ce(G,ArrayBuffer))return G.byteLength;if(typeof G!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof G);const Q=G.length,te=arguments.length>2&&arguments[2]===!0;if(!te&&Q===0)return 0;let me=!1;for(;;)switch(F){case"ascii":case"latin1":case"binary":return Q;case"utf8":case"utf-8":return V(G).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Q*2;case"hex":return Q>>>1;case"base64":return Y(G).length;default:if(me)return te?-1:V(G).length;F=(""+F).toLowerCase(),me=!0}}o.byteLength=_;function w(G,F,Q){let te=!1;if((F===void 0||F<0)&&(F=0),F>this.length||((Q===void 0||Q>this.length)&&(Q=this.length),Q<=0)||(Q>>>=0,F>>>=0,Q<=F))return"";for(G||(G="utf8");;)switch(G){case"hex":return le(this,F,Q);case"utf8":case"utf-8":return j(this,F,Q);case"ascii":return Z(this,F,Q);case"latin1":case"binary":return X(this,F,Q);case"base64":return U(this,F,Q);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return K(this,F,Q);default:if(te)throw new TypeError("Unknown encoding: "+G);G=(G+"").toLowerCase(),te=!0}}o.prototype._isBuffer=!0;function S(G,F,Q){const te=G[F];G[F]=G[Q],G[Q]=te}o.prototype.swap16=function(){const F=this.length;if(F%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let Q=0;QQ&&(F+=" ... "),""},s&&(o.prototype[s]=o.prototype.inspect),o.prototype.compare=function(F,Q,te,me,Oe){if(ce(F,Uint8Array)&&(F=o.from(F,F.offset,F.byteLength)),!o.isBuffer(F))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof F);if(Q===void 0&&(Q=0),te===void 0&&(te=F?F.length:0),me===void 0&&(me=0),Oe===void 0&&(Oe=this.length),Q<0||te>F.length||me<0||Oe>this.length)throw new RangeError("out of range index");if(me>=Oe&&Q>=te)return 0;if(me>=Oe)return-1;if(Q>=te)return 1;if(Q>>>=0,te>>>=0,me>>>=0,Oe>>>=0,this===F)return 0;let Ne=Oe-me,We=te-Q;const Ve=Math.min(Ne,We),pe=this.slice(me,Oe),we=F.slice(Q,te);for(let W=0;W2147483647?Q=2147483647:Q<-2147483648&&(Q=-2147483648),Q=+Q,Te(Q)&&(Q=me?0:G.length-1),Q<0&&(Q=G.length+Q),Q>=G.length){if(me)return-1;Q=G.length-1}else if(Q<0)if(me)Q=0;else return-1;if(typeof F=="string"&&(F=o.from(F,te)),o.isBuffer(F))return F.length===0?-1:D(G,F,Q,te,me);if(typeof F=="number")return F=F&255,typeof Uint8Array.prototype.indexOf=="function"?me?Uint8Array.prototype.indexOf.call(G,F,Q):Uint8Array.prototype.lastIndexOf.call(G,F,Q):D(G,[F],Q,te,me);throw new TypeError("val must be string, number or Buffer")}function D(G,F,Q,te,me){let Oe=1,Ne=G.length,We=F.length;if(te!==void 0&&(te=String(te).toLowerCase(),te==="ucs2"||te==="ucs-2"||te==="utf16le"||te==="utf-16le")){if(G.length<2||F.length<2)return-1;Oe=2,Ne/=2,We/=2,Q/=2}function Ve(we,W){return Oe===1?we[W]:we.readUInt16BE(W*Oe)}let pe;if(me){let we=-1;for(pe=Q;peNe&&(Q=Ne-We),pe=Q;pe>=0;pe--){let we=!0;for(let W=0;Wme&&(te=me)):te=me;const Oe=F.length;te>Oe/2&&(te=Oe/2);let Ne;for(Ne=0;Ne>>0,isFinite(te)?(te=te>>>0,me===void 0&&(me="utf8")):(me=te,te=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const Oe=this.length-Q;if((te===void 0||te>Oe)&&(te=Oe),F.length>0&&(te<0||Q<0)||Q>this.length)throw new RangeError("Attempt to write outside buffer bounds");me||(me="utf8");let Ne=!1;for(;;)switch(me){case"hex":return L(this,F,Q,te);case"utf8":case"utf-8":return O(this,F,Q,te);case"ascii":case"latin1":case"binary":return E(this,F,Q,te);case"base64":return P(this,F,Q,te);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return M(this,F,Q,te);default:if(Ne)throw new TypeError("Unknown encoding: "+me);me=(""+me).toLowerCase(),Ne=!0}},o.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function U(G,F,Q){return F===0&&Q===G.length?e.fromByteArray(G):e.fromByteArray(G.slice(F,Q))}function j(G,F,Q){Q=Math.min(G.length,Q);const te=[];let me=F;for(;me239?4:Oe>223?3:Oe>191?2:1;if(me+We<=Q){let Ve,pe,we,W;switch(We){case 1:Oe<128&&(Ne=Oe);break;case 2:Ve=G[me+1],(Ve&192)===128&&(W=(Oe&31)<<6|Ve&63,W>127&&(Ne=W));break;case 3:Ve=G[me+1],pe=G[me+2],(Ve&192)===128&&(pe&192)===128&&(W=(Oe&15)<<12|(Ve&63)<<6|pe&63,W>2047&&(W<55296||W>57343)&&(Ne=W));break;case 4:Ve=G[me+1],pe=G[me+2],we=G[me+3],(Ve&192)===128&&(pe&192)===128&&(we&192)===128&&(W=(Oe&15)<<18|(Ve&63)<<12|(pe&63)<<6|we&63,W>65535&&W<1114112&&(Ne=W))}}Ne===null?(Ne=65533,We=1):Ne>65535&&(Ne-=65536,te.push(Ne>>>10&1023|55296),Ne=56320|Ne&1023),te.push(Ne),me+=We}return $(te)}const q=4096;function $(G){const F=G.length;if(F<=q)return String.fromCharCode.apply(String,G);let Q="",te=0;for(;tete)&&(Q=te);let me="";for(let Oe=F;Oete&&(F=te),Q<0?(Q+=te,Q<0&&(Q=0)):Q>te&&(Q=te),QQ)throw new RangeError("Trying to access beyond buffer length")}o.prototype.readUintLE=o.prototype.readUIntLE=function(F,Q,te){F=F>>>0,Q=Q>>>0,te||he(F,Q,this.length);let me=this[F],Oe=1,Ne=0;for(;++Ne>>0,Q=Q>>>0,te||he(F,Q,this.length);let me=this[F+--Q],Oe=1;for(;Q>0&&(Oe*=256);)me+=this[F+--Q]*Oe;return me},o.prototype.readUint8=o.prototype.readUInt8=function(F,Q){return F=F>>>0,Q||he(F,1,this.length),this[F]},o.prototype.readUint16LE=o.prototype.readUInt16LE=function(F,Q){return F=F>>>0,Q||he(F,2,this.length),this[F]|this[F+1]<<8},o.prototype.readUint16BE=o.prototype.readUInt16BE=function(F,Q){return F=F>>>0,Q||he(F,2,this.length),this[F]<<8|this[F+1]},o.prototype.readUint32LE=o.prototype.readUInt32LE=function(F,Q){return F=F>>>0,Q||he(F,4,this.length),(this[F]|this[F+1]<<8|this[F+2]<<16)+this[F+3]*16777216},o.prototype.readUint32BE=o.prototype.readUInt32BE=function(F,Q){return F=F>>>0,Q||he(F,4,this.length),this[F]*16777216+(this[F+1]<<16|this[F+2]<<8|this[F+3])},o.prototype.readBigUInt64LE=Le(function(F){F=F>>>0,T(F,"offset");const Q=this[F],te=this[F+7];(Q===void 0||te===void 0)&&x(F,this.length-8);const me=Q+this[++F]*2**8+this[++F]*2**16+this[++F]*2**24,Oe=this[++F]+this[++F]*2**8+this[++F]*2**16+te*2**24;return BigInt(me)+(BigInt(Oe)<>>0,T(F,"offset");const Q=this[F],te=this[F+7];(Q===void 0||te===void 0)&&x(F,this.length-8);const me=Q*2**24+this[++F]*2**16+this[++F]*2**8+this[++F],Oe=this[++F]*2**24+this[++F]*2**16+this[++F]*2**8+te;return(BigInt(me)<>>0,Q=Q>>>0,te||he(F,Q,this.length);let me=this[F],Oe=1,Ne=0;for(;++Ne=Oe&&(me-=Math.pow(2,8*Q)),me},o.prototype.readIntBE=function(F,Q,te){F=F>>>0,Q=Q>>>0,te||he(F,Q,this.length);let me=Q,Oe=1,Ne=this[F+--me];for(;me>0&&(Oe*=256);)Ne+=this[F+--me]*Oe;return Oe*=128,Ne>=Oe&&(Ne-=Math.pow(2,8*Q)),Ne},o.prototype.readInt8=function(F,Q){return F=F>>>0,Q||he(F,1,this.length),this[F]&128?(255-this[F]+1)*-1:this[F]},o.prototype.readInt16LE=function(F,Q){F=F>>>0,Q||he(F,2,this.length);const te=this[F]|this[F+1]<<8;return te&32768?te|4294901760:te},o.prototype.readInt16BE=function(F,Q){F=F>>>0,Q||he(F,2,this.length);const te=this[F+1]|this[F]<<8;return te&32768?te|4294901760:te},o.prototype.readInt32LE=function(F,Q){return F=F>>>0,Q||he(F,4,this.length),this[F]|this[F+1]<<8|this[F+2]<<16|this[F+3]<<24},o.prototype.readInt32BE=function(F,Q){return F=F>>>0,Q||he(F,4,this.length),this[F]<<24|this[F+1]<<16|this[F+2]<<8|this[F+3]},o.prototype.readBigInt64LE=Le(function(F){F=F>>>0,T(F,"offset");const Q=this[F],te=this[F+7];(Q===void 0||te===void 0)&&x(F,this.length-8);const me=this[F+4]+this[F+5]*2**8+this[F+6]*2**16+(te<<24);return(BigInt(me)<>>0,T(F,"offset");const Q=this[F],te=this[F+7];(Q===void 0||te===void 0)&&x(F,this.length-8);const me=(Q<<24)+this[++F]*2**16+this[++F]*2**8+this[++F];return(BigInt(me)<>>0,Q||he(F,4,this.length),u.read(this,F,!0,23,4)},o.prototype.readFloatBE=function(F,Q){return F=F>>>0,Q||he(F,4,this.length),u.read(this,F,!1,23,4)},o.prototype.readDoubleLE=function(F,Q){return F=F>>>0,Q||he(F,8,this.length),u.read(this,F,!0,52,8)},o.prototype.readDoubleBE=function(F,Q){return F=F>>>0,Q||he(F,8,this.length),u.read(this,F,!1,52,8)};function Re(G,F,Q,te,me,Oe){if(!o.isBuffer(G))throw new TypeError('"buffer" argument must be a Buffer instance');if(F>me||FG.length)throw new RangeError("Index out of range")}o.prototype.writeUintLE=o.prototype.writeUIntLE=function(F,Q,te,me){if(F=+F,Q=Q>>>0,te=te>>>0,!me){const We=Math.pow(2,8*te)-1;Re(this,F,Q,te,We,0)}let Oe=1,Ne=0;for(this[Q]=F&255;++Ne>>0,te=te>>>0,!me){const We=Math.pow(2,8*te)-1;Re(this,F,Q,te,We,0)}let Oe=te-1,Ne=1;for(this[Q+Oe]=F&255;--Oe>=0&&(Ne*=256);)this[Q+Oe]=F/Ne&255;return Q+te},o.prototype.writeUint8=o.prototype.writeUInt8=function(F,Q,te){return F=+F,Q=Q>>>0,te||Re(this,F,Q,1,255,0),this[Q]=F&255,Q+1},o.prototype.writeUint16LE=o.prototype.writeUInt16LE=function(F,Q,te){return F=+F,Q=Q>>>0,te||Re(this,F,Q,2,65535,0),this[Q]=F&255,this[Q+1]=F>>>8,Q+2},o.prototype.writeUint16BE=o.prototype.writeUInt16BE=function(F,Q,te){return F=+F,Q=Q>>>0,te||Re(this,F,Q,2,65535,0),this[Q]=F>>>8,this[Q+1]=F&255,Q+2},o.prototype.writeUint32LE=o.prototype.writeUInt32LE=function(F,Q,te){return F=+F,Q=Q>>>0,te||Re(this,F,Q,4,4294967295,0),this[Q+3]=F>>>24,this[Q+2]=F>>>16,this[Q+1]=F>>>8,this[Q]=F&255,Q+4},o.prototype.writeUint32BE=o.prototype.writeUInt32BE=function(F,Q,te){return F=+F,Q=Q>>>0,te||Re(this,F,Q,4,4294967295,0),this[Q]=F>>>24,this[Q+1]=F>>>16,this[Q+2]=F>>>8,this[Q+3]=F&255,Q+4};function ie(G,F,Q,te,me){R(F,te,me,G,Q,7);let Oe=Number(F&BigInt(4294967295));G[Q++]=Oe,Oe=Oe>>8,G[Q++]=Oe,Oe=Oe>>8,G[Q++]=Oe,Oe=Oe>>8,G[Q++]=Oe;let Ne=Number(F>>BigInt(32)&BigInt(4294967295));return G[Q++]=Ne,Ne=Ne>>8,G[Q++]=Ne,Ne=Ne>>8,G[Q++]=Ne,Ne=Ne>>8,G[Q++]=Ne,Q}function ae(G,F,Q,te,me){R(F,te,me,G,Q,7);let Oe=Number(F&BigInt(4294967295));G[Q+7]=Oe,Oe=Oe>>8,G[Q+6]=Oe,Oe=Oe>>8,G[Q+5]=Oe,Oe=Oe>>8,G[Q+4]=Oe;let Ne=Number(F>>BigInt(32)&BigInt(4294967295));return G[Q+3]=Ne,Ne=Ne>>8,G[Q+2]=Ne,Ne=Ne>>8,G[Q+1]=Ne,Ne=Ne>>8,G[Q]=Ne,Q+8}o.prototype.writeBigUInt64LE=Le(function(F,Q=0){return ie(this,F,Q,BigInt(0),BigInt("0xffffffffffffffff"))}),o.prototype.writeBigUInt64BE=Le(function(F,Q=0){return ae(this,F,Q,BigInt(0),BigInt("0xffffffffffffffff"))}),o.prototype.writeIntLE=function(F,Q,te,me){if(F=+F,Q=Q>>>0,!me){const Ve=Math.pow(2,8*te-1);Re(this,F,Q,te,Ve-1,-Ve)}let Oe=0,Ne=1,We=0;for(this[Q]=F&255;++Oe>0)-We&255;return Q+te},o.prototype.writeIntBE=function(F,Q,te,me){if(F=+F,Q=Q>>>0,!me){const Ve=Math.pow(2,8*te-1);Re(this,F,Q,te,Ve-1,-Ve)}let Oe=te-1,Ne=1,We=0;for(this[Q+Oe]=F&255;--Oe>=0&&(Ne*=256);)F<0&&We===0&&this[Q+Oe+1]!==0&&(We=1),this[Q+Oe]=(F/Ne>>0)-We&255;return Q+te},o.prototype.writeInt8=function(F,Q,te){return F=+F,Q=Q>>>0,te||Re(this,F,Q,1,127,-128),F<0&&(F=255+F+1),this[Q]=F&255,Q+1},o.prototype.writeInt16LE=function(F,Q,te){return F=+F,Q=Q>>>0,te||Re(this,F,Q,2,32767,-32768),this[Q]=F&255,this[Q+1]=F>>>8,Q+2},o.prototype.writeInt16BE=function(F,Q,te){return F=+F,Q=Q>>>0,te||Re(this,F,Q,2,32767,-32768),this[Q]=F>>>8,this[Q+1]=F&255,Q+2},o.prototype.writeInt32LE=function(F,Q,te){return F=+F,Q=Q>>>0,te||Re(this,F,Q,4,2147483647,-2147483648),this[Q]=F&255,this[Q+1]=F>>>8,this[Q+2]=F>>>16,this[Q+3]=F>>>24,Q+4},o.prototype.writeInt32BE=function(F,Q,te){return F=+F,Q=Q>>>0,te||Re(this,F,Q,4,2147483647,-2147483648),F<0&&(F=4294967295+F+1),this[Q]=F>>>24,this[Q+1]=F>>>16,this[Q+2]=F>>>8,this[Q+3]=F&255,Q+4},o.prototype.writeBigInt64LE=Le(function(F,Q=0){return ie(this,F,Q,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),o.prototype.writeBigInt64BE=Le(function(F,Q=0){return ae(this,F,Q,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function Ee(G,F,Q,te,me,Oe){if(Q+te>G.length)throw new RangeError("Index out of range");if(Q<0)throw new RangeError("Index out of range")}function De(G,F,Q,te,me){return F=+F,Q=Q>>>0,me||Ee(G,F,Q,4),u.write(G,F,Q,te,23,4),Q+4}o.prototype.writeFloatLE=function(F,Q,te){return De(this,F,Q,!0,te)},o.prototype.writeFloatBE=function(F,Q,te){return De(this,F,Q,!1,te)};function ge(G,F,Q,te,me){return F=+F,Q=Q>>>0,me||Ee(G,F,Q,8),u.write(G,F,Q,te,52,8),Q+8}o.prototype.writeDoubleLE=function(F,Q,te){return ge(this,F,Q,!0,te)},o.prototype.writeDoubleBE=function(F,Q,te){return ge(this,F,Q,!1,te)},o.prototype.copy=function(F,Q,te,me){if(!o.isBuffer(F))throw new TypeError("argument should be a Buffer");if(te||(te=0),!me&&me!==0&&(me=this.length),Q>=F.length&&(Q=F.length),Q||(Q=0),me>0&&me=this.length)throw new RangeError("Index out of range");if(me<0)throw new RangeError("sourceEnd out of bounds");me>this.length&&(me=this.length),F.length-Q>>0,te=te===void 0?this.length:te>>>0,F||(F=0);let Oe;if(typeof F=="number")for(Oe=Q;Oe2**32?me=H(String(Q)):typeof Q=="bigint"&&(me=String(Q),(Q>BigInt(2)**BigInt(32)||Q<-(BigInt(2)**BigInt(32)))&&(me=H(me)),me+="n"),te+=` It must be ${F}. Received ${me}`,te},RangeError);function H(G){let F="",Q=G.length;const te=G[0]==="-"?1:0;for(;Q>=te+4;Q-=3)F=`_${G.slice(Q-3,Q)}${F}`;return`${G.slice(0,Q)}${F}`}function N(G,F,Q){T(F,"offset"),(G[F]===void 0||G[F+Q]===void 0)&&x(F,G.length-(Q+1))}function R(G,F,Q,te,me,Oe){if(G>Q||G3?F===0||F===BigInt(0)?We=`>= 0${Ne} and < 2${Ne} ** ${(Oe+1)*8}${Ne}`:We=`>= -(2${Ne} ** ${(Oe+1)*8-1}${Ne}) and < 2 ** ${(Oe+1)*8-1}${Ne}`:We=`>= ${F}${Ne} and <= ${Q}${Ne}`,new de.ERR_OUT_OF_RANGE("value",We,G)}N(te,me,Oe)}function T(G,F){if(typeof G!="number")throw new de.ERR_INVALID_ARG_TYPE(F,"number",G)}function x(G,F,Q){throw Math.floor(G)!==G?(T(G,Q),new de.ERR_OUT_OF_RANGE(Q||"offset","an integer",G)):F<0?new de.ERR_BUFFER_OUT_OF_BOUNDS:new de.ERR_OUT_OF_RANGE(Q||"offset",`>= ${Q?1:0} and <= ${F}`,G)}const B=/[^+/0-9A-Za-z-_]/g;function k(G){if(G=G.split("=")[0],G=G.trim().replace(B,""),G.length<2)return"";for(;G.length%4!==0;)G=G+"=";return G}function V(G,F){F=F||1/0;let Q;const te=G.length;let me=null;const Oe=[];for(let Ne=0;Ne55295&&Q<57344){if(!me){if(Q>56319){(F-=3)>-1&&Oe.push(239,191,189);continue}else if(Ne+1===te){(F-=3)>-1&&Oe.push(239,191,189);continue}me=Q;continue}if(Q<56320){(F-=3)>-1&&Oe.push(239,191,189),me=Q;continue}Q=(me-55296<<10|Q-56320)+65536}else me&&(F-=3)>-1&&Oe.push(239,191,189);if(me=null,Q<128){if((F-=1)<0)break;Oe.push(Q)}else if(Q<2048){if((F-=2)<0)break;Oe.push(Q>>6|192,Q&63|128)}else if(Q<65536){if((F-=3)<0)break;Oe.push(Q>>12|224,Q>>6&63|128,Q&63|128)}else if(Q<1114112){if((F-=4)<0)break;Oe.push(Q>>18|240,Q>>12&63|128,Q>>6&63|128,Q&63|128)}else throw new Error("Invalid code point")}return Oe}function J(G){const F=[];for(let Q=0;Q>8,me=Q%256,Oe.push(me),Oe.push(te);return Oe}function Y(G){return e.toByteArray(k(G))}function re(G,F,Q,te){let me;for(me=0;me=F.length||me>=G.length);++me)F[me+Q]=G[me];return me}function ce(G,F){return G instanceof F||G!=null&&G.constructor!=null&&G.constructor.name!=null&&G.constructor.name===F.name}function Te(G){return G!==G}const xe=function(){const G="0123456789abcdef",F=new Array(256);for(let Q=0;Q<16;++Q){const te=Q*16;for(let me=0;me<16;++me)F[te+me]=G[Q]+G[me]}return F}();function Le(G){return typeof BigInt>"u"?qe:G}function qe(){throw new Error("BigInt not supported")}}(g_)),g_}var __,lI;function Rr(){return lI||(lI=1,__={ArrayIsArray(t){return Array.isArray(t)},ArrayPrototypeIncludes(t,e){return t.includes(e)},ArrayPrototypeIndexOf(t,e){return t.indexOf(e)},ArrayPrototypeJoin(t,e){return t.join(e)},ArrayPrototypeMap(t,e){return t.map(e)},ArrayPrototypePop(t,e){return t.pop(e)},ArrayPrototypePush(t,e){return t.push(e)},ArrayPrototypeSlice(t,e,u){return t.slice(e,u)},Error,FunctionPrototypeCall(t,e,...u){return t.call(e,...u)},FunctionPrototypeSymbolHasInstance(t,e){return Function.prototype[Symbol.hasInstance].call(t,e)},MathFloor:Math.floor,Number,NumberIsInteger:Number.isInteger,NumberIsNaN:Number.isNaN,NumberMAX_SAFE_INTEGER:Number.MAX_SAFE_INTEGER,NumberMIN_SAFE_INTEGER:Number.MIN_SAFE_INTEGER,NumberParseInt:Number.parseInt,ObjectDefineProperties(t,e){return Object.defineProperties(t,e)},ObjectDefineProperty(t,e,u){return Object.defineProperty(t,e,u)},ObjectGetOwnPropertyDescriptor(t,e){return Object.getOwnPropertyDescriptor(t,e)},ObjectKeys(t){return Object.keys(t)},ObjectSetPrototypeOf(t,e){return Object.setPrototypeOf(t,e)},Promise,PromisePrototypeCatch(t,e){return t.catch(e)},PromisePrototypeThen(t,e,u){return t.then(e,u)},PromiseReject(t){return Promise.reject(t)},PromiseResolve(t){return Promise.resolve(t)},ReflectApply:Reflect.apply,RegExpPrototypeTest(t,e){return t.test(e)},SafeSet:Set,String,StringPrototypeSlice(t,e,u){return t.slice(e,u)},StringPrototypeToLowerCase(t){return t.toLowerCase()},StringPrototypeToUpperCase(t){return t.toUpperCase()},StringPrototypeTrim(t){return t.trim()},Symbol,SymbolFor:Symbol.for,SymbolAsyncIterator:Symbol.asyncIterator,SymbolHasInstance:Symbol.hasInstance,SymbolIterator:Symbol.iterator,SymbolDispose:Symbol.dispose||Symbol("Symbol.dispose"),SymbolAsyncDispose:Symbol.asyncDispose||Symbol("Symbol.asyncDispose"),TypedArrayPrototypeSet(t,e,u){return t.set(e,u)},Boolean,Uint8Array}),__}var v_={exports:{}},Uc={exports:{}},dI;function Qo(){if(dI)return Uc.exports;dI=1;const{AbortController:t,AbortSignal:e}=typeof self<"u"?self:typeof window<"u"?window:void 0;return Uc.exports=t,Uc.exports.AbortSignal=e,Uc.exports.default=t,Uc.exports}var fI;function In(){return fI||(fI=1,function(t){const e=Wi(),{kResistStopPropagation:u,SymbolDispose:s}=Rr(),n=globalThis.AbortSignal||Qo().AbortSignal,r=globalThis.AbortController||Qo().AbortController,a=Object.getPrototypeOf(async function(){}).constructor,o=globalThis.Blob||e.Blob,l=typeof o<"u"?function(p){return p instanceof o}:function(p){return!1},c=(f,p)=>{if(f!==void 0&&(f===null||typeof f!="object"||!("aborted"in f)))throw new ERR_INVALID_ARG_TYPE(p,"AbortSignal",f)},d=(f,p)=>{if(typeof f!="function")throw new ERR_INVALID_ARG_TYPE(p,"Function",f)};class h extends Error{constructor(p){if(!Array.isArray(p))throw new TypeError(`Expected input to be an Array, got ${typeof p}`);let y="";for(let b=0;b{f=b,p=g}),resolve:f,reject:p}},promisify(f){return new Promise((p,y)=>{f((b,...g)=>b?y(b):p(...g))})},debuglog(){return function(){}},format(f,...p){return f.replace(/%([sdifj])/g,function(...[y,b]){const g=p.shift();return b==="f"?g.toFixed(6):b==="j"?JSON.stringify(g):b==="s"&&typeof g=="object"?`${g.constructor!==Object?g.constructor.name:""} {}`.trim():g.toString()})},inspect(f){switch(typeof f){case"string":if(f.includes("'"))if(f.includes('"')){if(!f.includes("`")&&!f.includes("${"))return`\`${f}\``}else return`"${f}"`;return`'${f}'`;case"number":return isNaN(f)?"NaN":Object.is(f,-0)?String(f):f;case"bigint":return`${String(f)}n`;case"boolean":case"undefined":return String(f);case"object":return"{}"}},types:{isAsyncFunction(f){return f instanceof a},isArrayBufferView(f){return ArrayBuffer.isView(f)}},isBlob:l,deprecate(f,p){return f},addAbortListener:Ry().addAbortListener||function(p,y){if(p===void 0)throw new ERR_INVALID_ARG_TYPE("signal","AbortSignal",p);c(p,"signal"),d(y,"listener");let b;return p.aborted?queueMicrotask(()=>y()):(p.addEventListener("abort",y,{__proto__:null,once:!0,[u]:!0}),b=()=>{p.removeEventListener("abort",y)}),{__proto__:null,[s](){var g;(g=b)===null||g===void 0||g()}}},AbortSignalAny:n.any||function(p){if(p.length===1)return p[0];const y=new r,b=()=>y.abort();return p.forEach(g=>{c(g,"signals"),g.addEventListener("abort",b,{once:!0})}),y.signal.addEventListener("abort",()=>{p.forEach(g=>g.removeEventListener("abort",b))},{once:!0}),y.signal}},t.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")}(v_)),v_.exports}var h1={},w_,hI;function Un(){if(hI)return w_;hI=1;const{format:t,inspect:e,AggregateError:u}=In(),s=globalThis.AggregateError||u,n=Symbol("kIsNodeError"),r=["string","function","number","object","Function","Object","boolean","bigint","symbol"],a=/^([A-Z][a-z0-9]*)+$/,o="__node_internal_",l={};function c(g,m){if(!g)throw new l.ERR_INTERNAL_ASSERTION(m)}function d(g){let m="",v=g.length;const _=g[0]==="-"?1:0;for(;v>=_+4;v-=3)m=`_${g.slice(v-3,v)}${m}`;return`${g.slice(0,v)}${m}`}function h(g,m,v){if(typeof m=="function")return c(m.length<=v.length,`Code: ${g}; The provided arguments length (${v.length}) does not match the required ones (${m.length}).`),m(...v);const _=(m.match(/%[dfijoOs]/g)||[]).length;return c(_===v.length,`Code: ${g}; The provided arguments length (${v.length}) does not match the required ones (${_}).`),v.length===0?m:t(m,...v)}function f(g,m,v){v||(v=Error);class _ extends v{constructor(...S){super(h(g,m,S))}toString(){return`${this.name} [${g}]: ${this.message}`}}Object.defineProperties(_.prototype,{name:{value:v.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${g}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),_.prototype.code=g,_.prototype[n]=!0,l[g]=_}function p(g){const m=o+g.name;return Object.defineProperty(g,"name",{value:m}),g}function y(g,m){if(g&&m&&g!==m){if(Array.isArray(m.errors))return m.errors.push(g),m;const v=new s([m,g],m.message);return v.code=m.code,v}return g||m}class b extends Error{constructor(m="The operation was aborted",v=void 0){if(v!==void 0&&typeof v!="object")throw new l.ERR_INVALID_ARG_TYPE("options","Object",v);super(m,v),this.code="ABORT_ERR",this.name="AbortError"}}return f("ERR_ASSERTION","%s",Error),f("ERR_INVALID_ARG_TYPE",(g,m,v)=>{c(typeof g=="string","'name' must be a string"),Array.isArray(m)||(m=[m]);let _="The ";g.endsWith(" argument")?_+=`${g} `:_+=`"${g}" ${g.includes(".")?"property":"argument"} `,_+="must be ";const w=[],S=[],A=[];for(const L of m)c(typeof L=="string","All expected entries have to be of type string"),r.includes(L)?w.push(L.toLowerCase()):a.test(L)?S.push(L):(c(L!=="object",'The value "object" should be written as "Object"'),A.push(L));if(S.length>0){const L=w.indexOf("object");L!==-1&&(w.splice(w,L,1),S.push("Object"))}if(w.length>0){switch(w.length){case 1:_+=`of type ${w[0]}`;break;case 2:_+=`one of type ${w[0]} or ${w[1]}`;break;default:{const L=w.pop();_+=`one of type ${w.join(", ")}, or ${L}`}}(S.length>0||A.length>0)&&(_+=" or ")}if(S.length>0){switch(S.length){case 1:_+=`an instance of ${S[0]}`;break;case 2:_+=`an instance of ${S[0]} or ${S[1]}`;break;default:{const L=S.pop();_+=`an instance of ${S.join(", ")}, or ${L}`}}A.length>0&&(_+=" or ")}switch(A.length){case 0:break;case 1:A[0].toLowerCase()!==A[0]&&(_+="an "),_+=`${A[0]}`;break;case 2:_+=`one of ${A[0]} or ${A[1]}`;break;default:{const L=A.pop();_+=`one of ${A.join(", ")}, or ${L}`}}if(v==null)_+=`. Received ${v}`;else if(typeof v=="function"&&v.name)_+=`. Received function ${v.name}`;else if(typeof v=="object"){var D;if((D=v.constructor)!==null&&D!==void 0&&D.name)_+=`. Received an instance of ${v.constructor.name}`;else{const L=e(v,{depth:-1});_+=`. Received ${L}`}}else{let L=e(v,{colors:!1});L.length>25&&(L=`${L.slice(0,25)}...`),_+=`. Received type ${typeof v} (${L})`}return _},TypeError),f("ERR_INVALID_ARG_VALUE",(g,m,v="is invalid")=>{let _=e(m);return _.length>128&&(_=_.slice(0,128)+"..."),`The ${g.includes(".")?"property":"argument"} '${g}' ${v}. Received ${_}`},TypeError),f("ERR_INVALID_RETURN_VALUE",(g,m,v)=>{var _;const w=v!=null&&(_=v.constructor)!==null&&_!==void 0&&_.name?`instance of ${v.constructor.name}`:`type ${typeof v}`;return`Expected ${g} to be returned from the "${m}" function but got ${w}.`},TypeError),f("ERR_MISSING_ARGS",(...g)=>{c(g.length>0,"At least one arg needs to be specified");let m;const v=g.length;switch(g=(Array.isArray(g)?g:[g]).map(_=>`"${_}"`).join(" or "),v){case 1:m+=`The ${g[0]} argument`;break;case 2:m+=`The ${g[0]} and ${g[1]} arguments`;break;default:{const _=g.pop();m+=`The ${g.join(", ")}, and ${_} arguments`}break}return`${m} must be specified`},TypeError),f("ERR_OUT_OF_RANGE",(g,m,v)=>{c(m,'Missing "range" argument');let _;return Number.isInteger(v)&&Math.abs(v)>2**32?_=d(String(v)):typeof v=="bigint"?(_=String(v),(v>2n**32n||v<-(2n**32n))&&(_=d(_)),_+="n"):_=e(v),`The value of "${g}" is out of range. It must be ${m}. Received ${_}`},RangeError),f("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error),f("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error),f("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error),f("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error),f("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error),f("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),f("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error),f("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error),f("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error),f("ERR_STREAM_WRITE_AFTER_END","write after end",Error),f("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError),w_={AbortError:b,aggregateTwoErrors:p(y),hideStackFrames:p,codes:l},w_}var S_,pI;function Dy(){if(pI)return S_;pI=1;const{ArrayIsArray:t,ArrayPrototypeIncludes:e,ArrayPrototypeJoin:u,ArrayPrototypeMap:s,NumberIsInteger:n,NumberIsNaN:r,NumberMAX_SAFE_INTEGER:a,NumberMIN_SAFE_INTEGER:o,NumberParseInt:l,ObjectPrototypeHasOwnProperty:c,RegExpPrototypeExec:d,String:h,StringPrototypeToUpperCase:f,StringPrototypeTrim:p}=Rr(),{hideStackFrames:y,codes:{ERR_SOCKET_BAD_PORT:b,ERR_INVALID_ARG_TYPE:g,ERR_INVALID_ARG_VALUE:m,ERR_OUT_OF_RANGE:v,ERR_UNKNOWN_SIGNAL:_}}=Un(),{normalizeEncoding:w}=In(),{isAsyncFunction:S,isArrayBufferView:A}=In().types,D={};function L(z){return z===(z|0)}function O(z){return z===z>>>0}const E=/^[0-7]+$/,P="must be a 32-bit unsigned integer or an octal string";function M(z,Y,re){if(typeof z>"u"&&(z=re),typeof z=="string"){if(d(E,z)===null)throw new m(Y,z,P);z=l(z,8)}return q(z,Y),z}const U=y((z,Y,re=o,ce=a)=>{if(typeof z!="number")throw new g(Y,"number",z);if(!n(z))throw new v(Y,"an integer",z);if(zce)throw new v(Y,`>= ${re} && <= ${ce}`,z)}),j=y((z,Y,re=-2147483648,ce=2147483647)=>{if(typeof z!="number")throw new g(Y,"number",z);if(!n(z))throw new v(Y,"an integer",z);if(zce)throw new v(Y,`>= ${re} && <= ${ce}`,z)}),q=y((z,Y,re=!1)=>{if(typeof z!="number")throw new g(Y,"number",z);if(!n(z))throw new v(Y,"an integer",z);const ce=re?1:0,Te=4294967295;if(zTe)throw new v(Y,`>= ${ce} && <= ${Te}`,z)});function $(z,Y){if(typeof z!="string")throw new g(Y,"string",z)}function Z(z,Y,re=void 0,ce){if(typeof z!="number")throw new g(Y,"number",z);if(re!=null&&zce||(re!=null||ce!=null)&&r(z))throw new v(Y,`${re!=null?`>= ${re}`:""}${re!=null&&ce!=null?" && ":""}${ce!=null?`<= ${ce}`:""}`,z)}const X=y((z,Y,re)=>{if(!e(re,z)){const Te="must be one of: "+u(s(re,xe=>typeof xe=="string"?`'${xe}'`:h(xe)),", ");throw new m(Y,z,Te)}});function le(z,Y){if(typeof z!="boolean")throw new g(Y,"boolean",z)}function K(z,Y,re){return z==null||!c(z,Y)?re:z[Y]}const he=y((z,Y,re=null)=>{const ce=K(re,"allowArray",!1),Te=K(re,"allowFunction",!1);if(!K(re,"nullable",!1)&&z===null||!ce&&t(z)||typeof z!="object"&&(!Te||typeof z!="function"))throw new g(Y,"Object",z)}),Re=y((z,Y)=>{if(z!=null&&typeof z!="object"&&typeof z!="function")throw new g(Y,"a dictionary",z)}),ie=y((z,Y,re=0)=>{if(!t(z))throw new g(Y,"Array",z);if(z.length{if(!A(z))throw new g(Y,["Buffer","TypedArray","DataView"],z)});function fe(z,Y){const re=w(Y),ce=z.length;if(re==="hex"&&ce%2!==0)throw new m("encoding",Y,`is invalid for data of length ${ce}`)}function H(z,Y="Port",re=!0){if(typeof z!="number"&&typeof z!="string"||typeof z=="string"&&p(z).length===0||+z!==+z>>>0||z>65535||z===0&&!re)throw new b(Y,z,re);return z|0}const N=y((z,Y)=>{if(z!==void 0&&(z===null||typeof z!="object"||!("aborted"in z)))throw new g(Y,"AbortSignal",z)}),R=y((z,Y)=>{if(typeof z!="function")throw new g(Y,"Function",z)}),T=y((z,Y)=>{if(typeof z!="function"||S(z))throw new g(Y,"Function",z)}),x=y((z,Y)=>{if(z!==void 0)throw new g(Y,"undefined",z)});function B(z,Y,re){if(!e(re,z))throw new g(Y,`('${u(re,"|")}')`,z)}const k=/^(?:<[^>]*>)(?:\s*;\s*[^;"\s]+(?:=(")?[^;"\s]*\1)?)*$/;function V(z,Y){if(typeof z>"u"||!d(k,z))throw new m(Y,z,'must be an array or string of format "; rel=preload; as=style"')}function J(z){if(typeof z=="string")return V(z,"hints"),z;if(t(z)){const Y=z.length;let re="";if(Y===0)return re;for(let ce=0;ce; rel=preload; as=style"')}return S_={isInt32:L,isUint32:O,parseFileMode:M,validateArray:ie,validateStringArray:ae,validateBooleanArray:Ee,validateAbortSignalArray:De,validateBoolean:le,validateBuffer:de,validateDictionary:Re,validateEncoding:fe,validateFunction:R,validateInt32:j,validateInteger:U,validateNumber:Z,validateObject:he,validateOneOf:X,validatePlainFunction:T,validatePort:H,validateSignalName:ge,validateString:$,validateUint32:q,validateUndefined:x,validateUnion:B,validateAbortSignal:N,validateLinkHeaderValue:J},S_}var p1={exports:{}},T_,yI;function Aa(){if(yI)return T_;yI=1;const{SymbolAsyncIterator:t,SymbolIterator:e,SymbolFor:u}=Rr(),s=u("nodejs.stream.destroyed"),n=u("nodejs.stream.errored"),r=u("nodejs.stream.readable"),a=u("nodejs.stream.writable"),o=u("nodejs.stream.disturbed"),l=u("nodejs.webstream.isClosedPromise"),c=u("nodejs.webstream.controllerErrorFunction");function d(K,he=!1){var Re;return!!(K&&typeof K.pipe=="function"&&typeof K.on=="function"&&(!he||typeof K.pause=="function"&&typeof K.resume=="function")&&(!K._writableState||((Re=K._readableState)===null||Re===void 0?void 0:Re.readable)!==!1)&&(!K._writableState||K._readableState))}function h(K){var he;return!!(K&&typeof K.write=="function"&&typeof K.on=="function"&&(!K._readableState||((he=K._writableState)===null||he===void 0?void 0:he.writable)!==!1))}function f(K){return!!(K&&typeof K.pipe=="function"&&K._readableState&&typeof K.on=="function"&&typeof K.write=="function")}function p(K){return K&&(K._readableState||K._writableState||typeof K.write=="function"&&typeof K.on=="function"||typeof K.pipe=="function"&&typeof K.on=="function")}function y(K){return!!(K&&!p(K)&&typeof K.pipeThrough=="function"&&typeof K.getReader=="function"&&typeof K.cancel=="function")}function b(K){return!!(K&&!p(K)&&typeof K.getWriter=="function"&&typeof K.abort=="function")}function g(K){return!!(K&&!p(K)&&typeof K.readable=="object"&&typeof K.writable=="object")}function m(K){return y(K)||b(K)||g(K)}function v(K,he){return K==null?!1:he===!0?typeof K[t]=="function":he===!1?typeof K[e]=="function":typeof K[t]=="function"||typeof K[e]=="function"}function _(K){if(!p(K))return null;const he=K._writableState,Re=K._readableState,ie=he||Re;return!!(K.destroyed||K[s]||ie!=null&&ie.destroyed)}function w(K){if(!h(K))return null;if(K.writableEnded===!0)return!0;const he=K._writableState;return he!=null&&he.errored?!1:typeof(he==null?void 0:he.ended)!="boolean"?null:he.ended}function S(K,he){if(!h(K))return null;if(K.writableFinished===!0)return!0;const Re=K._writableState;return Re!=null&&Re.errored?!1:typeof(Re==null?void 0:Re.finished)!="boolean"?null:!!(Re.finished||he===!1&&Re.ended===!0&&Re.length===0)}function A(K){if(!d(K))return null;if(K.readableEnded===!0)return!0;const he=K._readableState;return!he||he.errored?!1:typeof(he==null?void 0:he.ended)!="boolean"?null:he.ended}function D(K,he){if(!d(K))return null;const Re=K._readableState;return Re!=null&&Re.errored?!1:typeof(Re==null?void 0:Re.endEmitted)!="boolean"?null:!!(Re.endEmitted||he===!1&&Re.ended===!0&&Re.length===0)}function L(K){return K&&K[r]!=null?K[r]:typeof(K==null?void 0:K.readable)!="boolean"?null:_(K)?!1:d(K)&&K.readable&&!D(K)}function O(K){return K&&K[a]!=null?K[a]:typeof(K==null?void 0:K.writable)!="boolean"?null:_(K)?!1:h(K)&&K.writable&&!w(K)}function E(K,he){return p(K)?_(K)?!0:!((he==null?void 0:he.readable)!==!1&&L(K)||(he==null?void 0:he.writable)!==!1&&O(K)):null}function P(K){var he,Re;return p(K)?K.writableErrored?K.writableErrored:(he=(Re=K._writableState)===null||Re===void 0?void 0:Re.errored)!==null&&he!==void 0?he:null:null}function M(K){var he,Re;return p(K)?K.readableErrored?K.readableErrored:(he=(Re=K._readableState)===null||Re===void 0?void 0:Re.errored)!==null&&he!==void 0?he:null:null}function U(K){if(!p(K))return null;if(typeof K.closed=="boolean")return K.closed;const he=K._writableState,Re=K._readableState;return typeof(he==null?void 0:he.closed)=="boolean"||typeof(Re==null?void 0:Re.closed)=="boolean"?(he==null?void 0:he.closed)||(Re==null?void 0:Re.closed):typeof K._closed=="boolean"&&j(K)?K._closed:null}function j(K){return typeof K._closed=="boolean"&&typeof K._defaultKeepAlive=="boolean"&&typeof K._removedConnection=="boolean"&&typeof K._removedContLen=="boolean"}function q(K){return typeof K._sent100=="boolean"&&j(K)}function $(K){var he;return typeof K._consuming=="boolean"&&typeof K._dumped=="boolean"&&((he=K.req)===null||he===void 0?void 0:he.upgradeOrConnect)===void 0}function Z(K){if(!p(K))return null;const he=K._writableState,Re=K._readableState,ie=he||Re;return!ie&&q(K)||!!(ie&&ie.autoDestroy&&ie.emitClose&&ie.closed===!1)}function X(K){var he;return!!(K&&((he=K[o])!==null&&he!==void 0?he:K.readableDidRead||K.readableAborted))}function le(K){var he,Re,ie,ae,Ee,De,ge,de,fe,H;return!!(K&&((he=(Re=(ie=(ae=(Ee=(De=K[n])!==null&&De!==void 0?De:K.readableErrored)!==null&&Ee!==void 0?Ee:K.writableErrored)!==null&&ae!==void 0?ae:(ge=K._readableState)===null||ge===void 0?void 0:ge.errorEmitted)!==null&&ie!==void 0?ie:(de=K._writableState)===null||de===void 0?void 0:de.errorEmitted)!==null&&Re!==void 0?Re:(fe=K._readableState)===null||fe===void 0?void 0:fe.errored)!==null&&he!==void 0?he:!((H=K._writableState)===null||H===void 0)&&H.errored))}return T_={isDestroyed:_,kIsDestroyed:s,isDisturbed:X,kIsDisturbed:o,isErrored:le,kIsErrored:n,isReadable:L,kIsReadable:r,kIsClosedPromise:l,kControllerErrorFunction:c,kIsWritable:a,isClosed:U,isDuplexNodeStream:f,isFinished:E,isIterable:v,isReadableNodeStream:d,isReadableStream:y,isReadableEnded:A,isReadableFinished:D,isReadableErrored:M,isNodeStream:p,isWebStream:m,isWritable:O,isWritableNodeStream:h,isWritableStream:b,isWritableEnded:w,isWritableFinished:S,isWritableErrored:P,isServerRequest:$,isServerResponse:q,willEmitClose:Z,isTransformStream:g},T_}var bI;function rs(){if(bI)return p1.exports;bI=1;const t=Ta(),{AbortError:e,codes:u}=Un(),{ERR_INVALID_ARG_TYPE:s,ERR_STREAM_PREMATURE_CLOSE:n}=u,{kEmptyObject:r,once:a}=In(),{validateAbortSignal:o,validateFunction:l,validateObject:c,validateBoolean:d}=Dy(),{Promise:h,PromisePrototypeThen:f,SymbolDispose:p}=Rr(),{isClosed:y,isReadable:b,isReadableNodeStream:g,isReadableStream:m,isReadableFinished:v,isReadableErrored:_,isWritable:w,isWritableNodeStream:S,isWritableStream:A,isWritableFinished:D,isWritableErrored:L,isNodeStream:O,willEmitClose:E,kIsClosedPromise:P}=Aa();let M;function U(X){return X.setHeader&&typeof X.abort=="function"}const j=()=>{};function q(X,le,K){var he,Re;if(arguments.length===2?(K=le,le=r):le==null?le=r:c(le,"options"),l(K,"callback"),o(le.signal,"options.signal"),K=a(K),m(X)||A(X))return $(X,le,K);if(!O(X))throw new s("stream",["ReadableStream","WritableStream","Stream"],X);const ie=(he=le.readable)!==null&&he!==void 0?he:g(X),ae=(Re=le.writable)!==null&&Re!==void 0?Re:S(X),Ee=X._writableState,De=X._readableState,ge=()=>{X.writable||H()};let de=E(X)&&g(X)===ie&&S(X)===ae,fe=D(X,!1);const H=()=>{fe=!0,X.destroyed&&(de=!1),!(de&&(!X.readable||ie))&&(!ie||N)&&K.call(X)};let N=v(X,!1);const R=()=>{N=!0,X.destroyed&&(de=!1),!(de&&(!X.writable||ae))&&(!ae||fe)&&K.call(X)},T=z=>{K.call(X,z)};let x=y(X);const B=()=>{x=!0;const z=L(X)||_(X);if(z&&typeof z!="boolean")return K.call(X,z);if(ie&&!N&&g(X,!0)&&!v(X,!1))return K.call(X,new n);if(ae&&!fe&&!D(X,!1))return K.call(X,new n);K.call(X)},k=()=>{x=!0;const z=L(X)||_(X);if(z&&typeof z!="boolean")return K.call(X,z);K.call(X)},V=()=>{X.req.on("finish",H)};U(X)?(X.on("complete",H),de||X.on("abort",B),X.req?V():X.on("request",V)):ae&&!Ee&&(X.on("end",ge),X.on("close",ge)),!de&&typeof X.aborted=="boolean"&&X.on("aborted",B),X.on("end",R),X.on("finish",H),le.error!==!1&&X.on("error",T),X.on("close",B),x?t.nextTick(B):Ee!=null&&Ee.errorEmitted||De!=null&&De.errorEmitted?de||t.nextTick(k):(!ie&&(!de||b(X))&&(fe||w(X)===!1)||!ae&&(!de||w(X))&&(N||b(X)===!1)||De&&X.req&&X.aborted)&&t.nextTick(k);const J=()=>{K=j,X.removeListener("aborted",B),X.removeListener("complete",H),X.removeListener("abort",B),X.removeListener("request",V),X.req&&X.req.removeListener("finish",H),X.removeListener("end",ge),X.removeListener("close",ge),X.removeListener("finish",H),X.removeListener("end",R),X.removeListener("error",T),X.removeListener("close",B)};if(le.signal&&!x){const z=()=>{const Y=K;J(),Y.call(X,new e(void 0,{cause:le.signal.reason}))};if(le.signal.aborted)t.nextTick(z);else{M=M||In().addAbortListener;const Y=M(le.signal,z),re=K;K=a((...ce)=>{Y[p](),re.apply(X,ce)})}}return J}function $(X,le,K){let he=!1,Re=j;if(le.signal)if(Re=()=>{he=!0,K.call(X,new e(void 0,{cause:le.signal.reason}))},le.signal.aborted)t.nextTick(Re);else{M=M||In().addAbortListener;const ae=M(le.signal,Re),Ee=K;K=a((...De)=>{ae[p](),Ee.apply(X,De)})}const ie=(...ae)=>{he||t.nextTick(()=>K.apply(X,ae))};return f(X[P].promise,ie,ie),j}function Z(X,le){var K;let he=!1;return le===null&&(le=r),(K=le)!==null&&K!==void 0&&K.cleanup&&(d(le.cleanup,"cleanup"),he=le.cleanup),new h((Re,ie)=>{const ae=q(X,le,Ee=>{he&&ae(),Ee?ie(Ee):Re()})})}return p1.exports=q,p1.exports.finished=Z,p1.exports}var A_,mI;function au(){if(mI)return A_;mI=1;const t=Ta(),{aggregateTwoErrors:e,codes:{ERR_MULTIPLE_CALLBACK:u},AbortError:s}=Un(),{Symbol:n}=Rr(),{kIsDestroyed:r,isDestroyed:a,isFinished:o,isServerRequest:l}=Aa(),c=n("kDestroy"),d=n("kConstruct");function h(E,P,M){E&&(E.stack,P&&!P.errored&&(P.errored=E),M&&!M.errored&&(M.errored=E))}function f(E,P){const M=this._readableState,U=this._writableState,j=U||M;return U!=null&&U.destroyed||M!=null&&M.destroyed?(typeof P=="function"&&P(),this):(h(E,U,M),U&&(U.destroyed=!0),M&&(M.destroyed=!0),j.constructed?p(this,E,P):this.once(c,function(q){p(this,e(q,E),P)}),this)}function p(E,P,M){let U=!1;function j(q){if(U)return;U=!0;const $=E._readableState,Z=E._writableState;h(q,Z,$),Z&&(Z.closed=!0),$&&($.closed=!0),typeof M=="function"&&M(q),q?t.nextTick(y,E,q):t.nextTick(b,E)}try{E._destroy(P||null,j)}catch(q){j(q)}}function y(E,P){g(E,P),b(E)}function b(E){const P=E._readableState,M=E._writableState;M&&(M.closeEmitted=!0),P&&(P.closeEmitted=!0),(M!=null&&M.emitClose||P!=null&&P.emitClose)&&E.emit("close")}function g(E,P){const M=E._readableState,U=E._writableState;U!=null&&U.errorEmitted||M!=null&&M.errorEmitted||(U&&(U.errorEmitted=!0),M&&(M.errorEmitted=!0),E.emit("error",P))}function m(){const E=this._readableState,P=this._writableState;E&&(E.constructed=!0,E.closed=!1,E.closeEmitted=!1,E.destroyed=!1,E.errored=null,E.errorEmitted=!1,E.reading=!1,E.ended=E.readable===!1,E.endEmitted=E.readable===!1),P&&(P.constructed=!0,P.destroyed=!1,P.closed=!1,P.closeEmitted=!1,P.errored=null,P.errorEmitted=!1,P.finalCalled=!1,P.prefinished=!1,P.ended=P.writable===!1,P.ending=P.writable===!1,P.finished=P.writable===!1)}function v(E,P,M){const U=E._readableState,j=E._writableState;if(j!=null&&j.destroyed||U!=null&&U.destroyed)return this;U!=null&&U.autoDestroy||j!=null&&j.autoDestroy?E.destroy(P):P&&(P.stack,j&&!j.errored&&(j.errored=P),U&&!U.errored&&(U.errored=P),M?t.nextTick(g,E,P):g(E,P))}function _(E,P){if(typeof E._construct!="function")return;const M=E._readableState,U=E._writableState;M&&(M.constructed=!1),U&&(U.constructed=!1),E.once(d,P),!(E.listenerCount(d)>1)&&t.nextTick(w,E)}function w(E){let P=!1;function M(U){if(P){v(E,U??new u);return}P=!0;const j=E._readableState,q=E._writableState,$=q||j;j&&(j.constructed=!0),q&&(q.constructed=!0),$.destroyed?E.emit(c,U):U?v(E,U,!0):t.nextTick(S,E)}try{E._construct(U=>{t.nextTick(M,U)})}catch(U){t.nextTick(M,U)}}function S(E){E.emit(d)}function A(E){return(E==null?void 0:E.setHeader)&&typeof E.abort=="function"}function D(E){E.emit("close")}function L(E,P){E.emit("error",P),t.nextTick(D,E)}function O(E,P){!E||a(E)||(!P&&!o(E)&&(P=new s),l(E)?(E.socket=null,E.destroy(P)):A(E)?E.abort():A(E.req)?E.req.abort():typeof E.destroy=="function"?E.destroy(P):typeof E.close=="function"?E.close():P?t.nextTick(L,E,P):t.nextTick(D,E),E.destroyed||(E[r]=!0))}return A_={construct:_,destroyer:O,destroy:f,undestroy:m,errorOrDestroy:v},A_}var E_,gI;function XT(){if(gI)return E_;gI=1;const{ArrayIsArray:t,ObjectSetPrototypeOf:e}=Rr(),{EventEmitter:u}=Ry();function s(r){u.call(this,r)}e(s.prototype,u.prototype),e(s,u),s.prototype.pipe=function(r,a){const o=this;function l(b){r.writable&&r.write(b)===!1&&o.pause&&o.pause()}o.on("data",l);function c(){o.readable&&o.resume&&o.resume()}r.on("drain",c),!r._isStdio&&(!a||a.end!==!1)&&(o.on("end",h),o.on("close",f));let d=!1;function h(){d||(d=!0,r.end())}function f(){d||(d=!0,typeof r.destroy=="function"&&r.destroy())}function p(b){y(),u.listenerCount(this,"error")===0&&this.emit("error",b)}n(o,"error",p),n(r,"error",p);function y(){o.removeListener("data",l),r.removeListener("drain",c),o.removeListener("end",h),o.removeListener("close",f),o.removeListener("error",p),r.removeListener("error",p),o.removeListener("end",y),o.removeListener("close",y),r.removeListener("close",y)}return o.on("end",y),o.on("close",y),r.on("close",y),r.emit("pipe",o),r};function n(r,a,o){if(typeof r.prependListener=="function")return r.prependListener(a,o);!r._events||!r._events[a]?r.on(a,o):t(r._events[a])?r._events[a].unshift(o):r._events[a]=[o,r._events[a]]}return E_={Stream:s,prependListener:n},E_}var O_={exports:{}},_I;function Jb(){return _I||(_I=1,function(t){const{SymbolDispose:e}=Rr(),{AbortError:u,codes:s}=Un(),{isNodeStream:n,isWebStream:r,kControllerErrorFunction:a}=Aa(),o=rs(),{ERR_INVALID_ARG_TYPE:l}=s;let c;const d=(h,f)=>{if(typeof h!="object"||!("aborted"in h))throw new l(f,"AbortSignal",h)};t.exports.addAbortSignal=function(f,p){if(d(f,"signal"),!n(p)&&!r(p))throw new l("stream",["ReadableStream","WritableStream","Stream"],p);return t.exports.addAbortSignalNoValidate(f,p)},t.exports.addAbortSignalNoValidate=function(h,f){if(typeof h!="object"||!("aborted"in h))return f;const p=n(f)?()=>{f.destroy(new u(void 0,{cause:h.reason}))}:()=>{f[a](new u(void 0,{cause:h.reason}))};if(h.aborted)p();else{c=c||In().addAbortListener;const y=c(h,p);o(f,y[e])}return f}}(O_)),O_.exports}var R_,vI;function NG(){if(vI)return R_;vI=1;const{StringPrototypeSlice:t,SymbolIterator:e,TypedArrayPrototypeSet:u,Uint8Array:s}=Rr(),{Buffer:n}=Wi(),{inspect:r}=In();return R_=class{constructor(){this.head=null,this.tail=null,this.length=0}push(o){const l={data:o,next:null};this.length>0?this.tail.next=l:this.head=l,this.tail=l,++this.length}unshift(o){const l={data:o,next:this.head};this.length===0&&(this.tail=l),this.head=l,++this.length}shift(){if(this.length===0)return;const o=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,o}clear(){this.head=this.tail=null,this.length=0}join(o){if(this.length===0)return"";let l=this.head,c=""+l.data;for(;(l=l.next)!==null;)c+=o+l.data;return c}concat(o){if(this.length===0)return n.alloc(0);const l=n.allocUnsafe(o>>>0);let c=this.head,d=0;for(;c;)u(l,c.data,d),d+=c.data.length,c=c.next;return l}consume(o,l){const c=this.head.data;if(oh.length)l+=h,o-=h.length;else{o===h.length?(l+=h,++d,c.next?this.head=c.next:this.head=this.tail=null):(l+=t(h,0,o),this.head=c,c.data=t(h,o));break}++d}while((c=c.next)!==null);return this.length-=d,l}_getBuffer(o){const l=n.allocUnsafe(o),c=o;let d=this.head,h=0;do{const f=d.data;if(o>f.length)u(l,f,c-o),o-=f.length;else{o===f.length?(u(l,f,c-o),++h,d.next?this.head=d.next:this.head=this.tail=null):(u(l,new s(f.buffer,f.byteOffset,o),c-o),this.head=d,d.data=f.slice(o));break}++h}while((d=d.next)!==null);return this.length-=h,l}[Symbol.for("nodejs.util.inspect.custom")](o,l){return r(this,{...l,depth:0,customInspect:!1})}},R_}var x_,wI;function Xb(){if(wI)return x_;wI=1;const{MathFloor:t,NumberIsInteger:e}=Rr(),{validateInteger:u}=Dy(),{ERR_INVALID_ARG_VALUE:s}=Un().codes;let n=16*1024,r=16;function a(d,h,f){return d.highWaterMark!=null?d.highWaterMark:h?d[f]:null}function o(d){return d?r:n}function l(d,h){u(h,"value",0),d?r=h:n=h}function c(d,h,f,p){const y=a(h,p,f);if(y!=null){if(!e(y)||y<0){const b=p?`options.${f}`:"options.highWaterMark";throw new s(b,y)}return t(y)}return o(d.objectMode)}return x_={getHighWaterMark:c,getDefaultHighWaterMark:o,setDefaultHighWaterMark:l},x_}var I_={},y1={exports:{}};/*! safe-buffer. MIT License. Feross Aboukhadijeh */var SI;function CG(){return SI||(SI=1,function(t,e){var u=Wi(),s=u.Buffer;function n(a,o){for(var l in a)o[l]=a[l]}s.from&&s.alloc&&s.allocUnsafe&&s.allocUnsafeSlow?t.exports=u:(n(u,e),e.Buffer=r);function r(a,o,l){return s(a,o,l)}r.prototype=Object.create(s.prototype),n(s,r),r.from=function(a,o,l){if(typeof a=="number")throw new TypeError("Argument must not be a number");return s(a,o,l)},r.alloc=function(a,o,l){if(typeof a!="number")throw new TypeError("Argument must be a number");var c=s(a);return o!==void 0?typeof l=="string"?c.fill(o,l):c.fill(o):c.fill(0),c},r.allocUnsafe=function(a){if(typeof a!="number")throw new TypeError("Argument must be a number");return s(a)},r.allocUnsafeSlow=function(a){if(typeof a!="number")throw new TypeError("Argument must be a number");return u.SlowBuffer(a)}}(y1,y1.exports)),y1.exports}var TI;function jG(){if(TI)return I_;TI=1;var t=CG().Buffer,e=t.isEncoding||function(m){switch(m=""+m,m&&m.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function u(m){if(!m)return"utf8";for(var v;;)switch(m){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return m;default:if(v)return;m=(""+m).toLowerCase(),v=!0}}function s(m){var v=u(m);if(typeof v!="string"&&(t.isEncoding===e||!e(m)))throw new Error("Unknown encoding: "+m);return v||m}I_.StringDecoder=n;function n(m){this.encoding=s(m);var v;switch(this.encoding){case"utf16le":this.text=h,this.end=f,v=4;break;case"utf8":this.fillLast=l,v=4;break;case"base64":this.text=p,this.end=y,v=3;break;default:this.write=b,this.end=g;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=t.allocUnsafe(v)}n.prototype.write=function(m){if(m.length===0)return"";var v,_;if(this.lastNeed){if(v=this.fillLast(m),v===void 0)return"";_=this.lastNeed,this.lastNeed=0}else _=0;return _>5===6?2:m>>4===14?3:m>>3===30?4:m>>6===2?-1:-2}function a(m,v,_){var w=v.length-1;if(w<_)return 0;var S=r(v[w]);return S>=0?(S>0&&(m.lastNeed=S-1),S):--w<_||S===-2?0:(S=r(v[w]),S>=0?(S>0&&(m.lastNeed=S-2),S):--w<_||S===-2?0:(S=r(v[w]),S>=0?(S>0&&(S===2?S=0:m.lastNeed=S-3),S):0))}function o(m,v,_){if((v[0]&192)!==128)return m.lastNeed=0,"�";if(m.lastNeed>1&&v.length>1){if((v[1]&192)!==128)return m.lastNeed=1,"�";if(m.lastNeed>2&&v.length>2&&(v[2]&192)!==128)return m.lastNeed=2,"�"}}function l(m){var v=this.lastTotal-this.lastNeed,_=o(this,m);if(_!==void 0)return _;if(this.lastNeed<=m.length)return m.copy(this.lastChar,v,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);m.copy(this.lastChar,v,0,m.length),this.lastNeed-=m.length}function c(m,v){var _=a(this,m,v);if(!this.lastNeed)return m.toString("utf8",v);this.lastTotal=_;var w=m.length-(_-this.lastNeed);return m.copy(this.lastChar,0,w),m.toString("utf8",v,w)}function d(m){var v=m&&m.length?this.write(m):"";return this.lastNeed?v+"�":v}function h(m,v){if((m.length-v)%2===0){var _=m.toString("utf16le",v);if(_){var w=_.charCodeAt(_.length-1);if(w>=55296&&w<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=m[m.length-2],this.lastChar[1]=m[m.length-1],_.slice(0,-1)}return _}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=m[m.length-1],m.toString("utf16le",v,m.length-1)}function f(m){var v=m&&m.length?this.write(m):"";if(this.lastNeed){var _=this.lastTotal-this.lastNeed;return v+this.lastChar.toString("utf16le",0,_)}return v}function p(m,v){var _=(m.length-v)%3;return _===0?m.toString("base64",v):(this.lastNeed=3-_,this.lastTotal=3,_===1?this.lastChar[0]=m[m.length-1]:(this.lastChar[0]=m[m.length-2],this.lastChar[1]=m[m.length-1]),m.toString("base64",v,m.length-_))}function y(m){var v=m&&m.length?this.write(m):"";return this.lastNeed?v+this.lastChar.toString("base64",0,3-this.lastNeed):v}function b(m){return m.toString(this.encoding)}function g(m){return m&&m.length?this.write(m):""}return I_}var P_,AI;function Fq(){if(AI)return P_;AI=1;const t=Ta(),{PromisePrototypeThen:e,SymbolAsyncIterator:u,SymbolIterator:s}=Rr(),{Buffer:n}=Wi(),{ERR_INVALID_ARG_TYPE:r,ERR_STREAM_NULL_VALUES:a}=Un().codes;function o(l,c,d){let h;if(typeof c=="string"||c instanceof n)return new l({objectMode:!0,...d,read(){this.push(c),this.push(null)}});let f;if(c&&c[u])f=!0,h=c[u]();else if(c&&c[s])f=!1,h=c[s]();else throw new r("iterable",["Iterable"],c);const p=new l({objectMode:!0,highWaterMark:1,...d});let y=!1;p._read=function(){y||(y=!0,g())},p._destroy=function(m,v){e(b(m),()=>t.nextTick(v,m),_=>t.nextTick(v,_||m))};async function b(m){const v=m!=null,_=typeof h.throw=="function";if(v&&_){const{value:w,done:S}=await h.throw(m);if(await w,S)return}if(typeof h.return=="function"){const{value:w}=await h.return();await w}}async function g(){for(;;){try{const{value:m,done:v}=f?await h.next():h.next();if(v)p.push(null);else{const _=m&&typeof m.then=="function"?await m:m;if(_===null)throw y=!1,new a;if(p.push(_))continue;y=!1}}catch(m){p.destroy(m)}break}}return p}return P_=o,P_}var D_,EI;function Kb(){if(EI)return D_;EI=1;const t=Ta(),{ArrayPrototypeIndexOf:e,NumberIsInteger:u,NumberIsNaN:s,NumberParseInt:n,ObjectDefineProperties:r,ObjectKeys:a,ObjectSetPrototypeOf:o,Promise:l,SafeSet:c,SymbolAsyncDispose:d,SymbolAsyncIterator:h,Symbol:f}=Rr();D_=ce,ce.ReadableState=re;const{EventEmitter:p}=Ry(),{Stream:y,prependListener:b}=XT(),{Buffer:g}=Wi(),{addAbortSignal:m}=Jb(),v=rs();let _=In().debuglog("stream",oe=>{_=oe});const w=NG(),S=au(),{getHighWaterMark:A,getDefaultHighWaterMark:D}=Xb(),{aggregateTwoErrors:L,codes:{ERR_INVALID_ARG_TYPE:O,ERR_METHOD_NOT_IMPLEMENTED:E,ERR_OUT_OF_RANGE:P,ERR_STREAM_PUSH_AFTER_EOF:M,ERR_STREAM_UNSHIFT_AFTER_END_EVENT:U},AbortError:j}=Un(),{validateObject:q}=Dy(),$=f("kPaused"),{StringDecoder:Z}=jG(),X=Fq();o(ce.prototype,y.prototype),o(ce,y);const le=()=>{},{errorOrDestroy:K}=S,he=1,Re=2,ie=4,ae=8,Ee=16,De=32,ge=64,de=128,fe=256,H=512,N=1024,R=2048,T=4096,x=8192,B=16384,k=32768,V=65536,J=1<<17,z=1<<18;function Y(oe){return{enumerable:!1,get(){return(this.state&oe)!==0},set(C){C?this.state|=oe:this.state&=~oe}}}r(re.prototype,{objectMode:Y(he),ended:Y(Re),endEmitted:Y(ie),reading:Y(ae),constructed:Y(Ee),sync:Y(De),needReadable:Y(ge),emittedReadable:Y(de),readableListening:Y(fe),resumeScheduled:Y(H),errorEmitted:Y(N),emitClose:Y(R),autoDestroy:Y(T),destroyed:Y(x),closed:Y(B),closeEmitted:Y(k),multiAwaitDrain:Y(V),readingMore:Y(J),dataEmitted:Y(z)});function re(oe,C,ee){typeof ee!="boolean"&&(ee=C instanceof va()),this.state=R|T|Ee|De,oe&&oe.objectMode&&(this.state|=he),ee&&oe&&oe.readableObjectMode&&(this.state|=he),this.highWaterMark=oe?A(this,oe,"readableHighWaterMark",ee):D(!1),this.buffer=new w,this.length=0,this.pipes=[],this.flowing=null,this[$]=null,oe&&oe.emitClose===!1&&(this.state&=~R),oe&&oe.autoDestroy===!1&&(this.state&=~T),this.errored=null,this.defaultEncoding=oe&&oe.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.decoder=null,this.encoding=null,oe&&oe.encoding&&(this.decoder=new Z(oe.encoding),this.encoding=oe.encoding)}function ce(oe){if(!(this instanceof ce))return new ce(oe);const C=this instanceof va();this._readableState=new re(oe,this,C),oe&&(typeof oe.read=="function"&&(this._read=oe.read),typeof oe.destroy=="function"&&(this._destroy=oe.destroy),typeof oe.construct=="function"&&(this._construct=oe.construct),oe.signal&&!C&&m(oe.signal,this)),y.call(this,oe),S.construct(this,()=>{this._readableState.needReadable&&me(this,this._readableState)})}ce.prototype.destroy=S.destroy,ce.prototype._undestroy=S.undestroy,ce.prototype._destroy=function(oe,C){C(oe)},ce.prototype[p.captureRejectionSymbol]=function(oe){this.destroy(oe)},ce.prototype[d]=function(){let oe;return this.destroyed||(oe=this.readableEnded?null:new j,this.destroy(oe)),new l((C,ee)=>v(this,ye=>ye&&ye!==oe?ee(ye):C(null)))},ce.prototype.push=function(oe,C){return Te(this,oe,C,!1)},ce.prototype.unshift=function(oe,C){return Te(this,oe,C,!0)};function Te(oe,C,ee,ye){_("readableAddChunk",C);const Pe=oe._readableState;let Ue;if(Pe.state&he||(typeof C=="string"?(ee=ee||Pe.defaultEncoding,Pe.encoding!==ee&&(ye&&Pe.encoding?C=g.from(C,ee).toString(Pe.encoding):(C=g.from(C,ee),ee=""))):C instanceof g?ee="":y._isUint8Array(C)?(C=y._uint8ArrayToBuffer(C),ee=""):C!=null&&(Ue=new O("chunk",["string","Buffer","Uint8Array"],C))),Ue)K(oe,Ue);else if(C===null)Pe.state&=~ae,F(oe,Pe);else if(Pe.state&he||C&&C.length>0)if(ye)if(Pe.state&ie)K(oe,new U);else{if(Pe.destroyed||Pe.errored)return!1;xe(oe,Pe,C,!0)}else if(Pe.ended)K(oe,new M);else{if(Pe.destroyed||Pe.errored)return!1;Pe.state&=~ae,Pe.decoder&&!ee?(C=Pe.decoder.write(C),Pe.objectMode||C.length!==0?xe(oe,Pe,C,!1):me(oe,Pe)):xe(oe,Pe,C,!1)}else ye||(Pe.state&=~ae,me(oe,Pe));return!Pe.ended&&(Pe.length0?(C.state&V?C.awaitDrainWriters.clear():C.awaitDrainWriters=null,C.dataEmitted=!0,oe.emit("data",ee)):(C.length+=C.objectMode?1:ee.length,ye?C.buffer.unshift(ee):C.buffer.push(ee),C.state&ge&&Q(oe)),me(oe,C)}ce.prototype.isPaused=function(){const oe=this._readableState;return oe[$]===!0||oe.flowing===!1},ce.prototype.setEncoding=function(oe){const C=new Z(oe);this._readableState.decoder=C,this._readableState.encoding=this._readableState.decoder.encoding;const ee=this._readableState.buffer;let ye="";for(const Pe of ee)ye+=C.write(Pe);return ee.clear(),ye!==""&&ee.push(ye),this._readableState.length=ye.length,this};const Le=1073741824;function qe(oe){if(oe>Le)throw new P("size","<= 1GiB",oe);return oe--,oe|=oe>>>1,oe|=oe>>>2,oe|=oe>>>4,oe|=oe>>>8,oe|=oe>>>16,oe++,oe}function G(oe,C){return oe<=0||C.length===0&&C.ended?0:C.state&he?1:s(oe)?C.flowing&&C.length?C.buffer.first().length:C.length:oe<=C.length?oe:C.ended?C.length:0}ce.prototype.read=function(oe){_("read",oe),oe===void 0?oe=NaN:u(oe)||(oe=n(oe,10));const C=this._readableState,ee=oe;if(oe>C.highWaterMark&&(C.highWaterMark=qe(oe)),oe!==0&&(C.state&=~de),oe===0&&C.needReadable&&((C.highWaterMark!==0?C.length>=C.highWaterMark:C.length>0)||C.ended))return _("read: emitReadable",C.length,C.ended),C.length===0&&C.ended?He(this):Q(this),null;if(oe=G(oe,C),oe===0&&C.ended)return C.length===0&&He(this),null;let ye=(C.state&ge)!==0;if(_("need readable",ye),(C.length===0||C.length-oe0?Pe=je(oe,C):Pe=null,Pe===null?(C.needReadable=C.length<=C.highWaterMark,oe=0):(C.length-=oe,C.multiAwaitDrain?C.awaitDrainWriters.clear():C.awaitDrainWriters=null),C.length===0&&(C.ended||(C.needReadable=!0),ee!==oe&&C.ended&&He(this)),Pe!==null&&!C.errorEmitted&&!C.closeEmitted&&(C.dataEmitted=!0,this.emit("data",Pe)),Pe};function F(oe,C){if(_("onEofChunk"),!C.ended){if(C.decoder){const ee=C.decoder.end();ee&&ee.length&&(C.buffer.push(ee),C.length+=C.objectMode?1:ee.length)}C.ended=!0,C.sync?Q(oe):(C.needReadable=!1,C.emittedReadable=!0,te(oe))}}function Q(oe){const C=oe._readableState;_("emitReadable",C.needReadable,C.emittedReadable),C.needReadable=!1,C.emittedReadable||(_("emitReadable",C.flowing),C.emittedReadable=!0,t.nextTick(te,oe))}function te(oe){const C=oe._readableState;_("emitReadable_",C.destroyed,C.length,C.ended),!C.destroyed&&!C.errored&&(C.length||C.ended)&&(oe.emit("readable"),C.emittedReadable=!1),C.needReadable=!C.flowing&&!C.ended&&C.length<=C.highWaterMark,W(oe)}function me(oe,C){!C.readingMore&&C.constructed&&(C.readingMore=!0,t.nextTick(Oe,oe,C))}function Oe(oe,C){for(;!C.reading&&!C.ended&&(C.length1&&ye.pipes.includes(oe)&&(_("false write response, pause",ye.awaitDrainWriters.size),ye.awaitDrainWriters.add(oe)),ee.pause()),$e||($e=Ne(ee,oe),oe.on("drain",$e))}ee.on("data",ft);function ft(Ie){_("ondata");const Me=oe.write(Ie);_("dest.write",Me),Me===!1&&yt()}function et(Ie){if(_("onerror",Ie),be(),oe.removeListener("error",et),oe.listenerCount("error")===0){const Me=oe._writableState||oe._readableState;Me&&!Me.errorEmitted?K(oe,Ie):oe.emit("error",Ie)}}b(oe,"error",et);function Ir(){oe.removeListener("finish",Ke),be()}oe.once("close",Ir);function Ke(){_("onfinish"),oe.removeListener("close",Ir),be()}oe.once("finish",Ke);function be(){_("unpipe"),ee.unpipe(oe)}return oe.emit("pipe",ee),oe.writableNeedDrain===!0?yt():ye.flowing||(_("pipe resume"),ee.resume()),oe};function Ne(oe,C){return function(){const ye=oe._readableState;ye.awaitDrainWriters===C?(_("pipeOnDrain",1),ye.awaitDrainWriters=null):ye.multiAwaitDrain&&(_("pipeOnDrain",ye.awaitDrainWriters.size),ye.awaitDrainWriters.delete(C)),(!ye.awaitDrainWriters||ye.awaitDrainWriters.size===0)&&oe.listenerCount("data")&&oe.resume()}}ce.prototype.unpipe=function(oe){const C=this._readableState,ee={hasUnpiped:!1};if(C.pipes.length===0)return this;if(!oe){const Pe=C.pipes;C.pipes=[],this.pause();for(let Ue=0;Ue0,ye.flowing!==!1&&this.resume()):oe==="readable"&&!ye.endEmitted&&!ye.readableListening&&(ye.readableListening=ye.needReadable=!0,ye.flowing=!1,ye.emittedReadable=!1,_("on readable",ye.length,ye.reading),ye.length?Q(this):ye.reading||t.nextTick(Ve,this)),ee},ce.prototype.addListener=ce.prototype.on,ce.prototype.removeListener=function(oe,C){const ee=y.prototype.removeListener.call(this,oe,C);return oe==="readable"&&t.nextTick(We,this),ee},ce.prototype.off=ce.prototype.removeListener,ce.prototype.removeAllListeners=function(oe){const C=y.prototype.removeAllListeners.apply(this,arguments);return(oe==="readable"||oe===void 0)&&t.nextTick(We,this),C};function We(oe){const C=oe._readableState;C.readableListening=oe.listenerCount("readable")>0,C.resumeScheduled&&C[$]===!1?C.flowing=!0:oe.listenerCount("data")>0?oe.resume():C.readableListening||(C.flowing=null)}function Ve(oe){_("readable nexttick read 0"),oe.read(0)}ce.prototype.resume=function(){const oe=this._readableState;return oe.flowing||(_("resume"),oe.flowing=!oe.readableListening,pe(this,oe)),oe[$]=!1,this};function pe(oe,C){C.resumeScheduled||(C.resumeScheduled=!0,t.nextTick(we,oe,C))}function we(oe,C){_("resume",C.reading),C.reading||oe.read(0),C.resumeScheduled=!1,oe.emit("resume"),W(oe),C.flowing&&!C.reading&&oe.read(0)}ce.prototype.pause=function(){return _("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(_("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState[$]=!0,this};function W(oe){const C=oe._readableState;for(_("flow",C.flowing);C.flowing&&oe.read()!==null;);}ce.prototype.wrap=function(oe){let C=!1;oe.on("data",ye=>{!this.push(ye)&&oe.pause&&(C=!0,oe.pause())}),oe.on("end",()=>{this.push(null)}),oe.on("error",ye=>{K(this,ye)}),oe.on("close",()=>{this.destroy()}),oe.on("destroy",()=>{this.destroy()}),this._read=()=>{C&&oe.resume&&(C=!1,oe.resume())};const ee=a(oe);for(let ye=1;ye{Pe=Fe?L(Pe,Fe):null,ee(),ee=le});try{for(;;){const Fe=oe.destroyed?null:oe.read();if(Fe!==null)yield Fe;else{if(Pe)throw Pe;if(Pe===null)return;await new l(ye)}}}catch(Fe){throw Pe=L(Pe,Fe),Pe}finally{(Pe||(C==null?void 0:C.destroyOnReturn)!==!1)&&(Pe===void 0||oe._readableState.autoDestroy)?S.destroyer(oe,null):(oe.off("readable",ye),Ue())}}r(ce.prototype,{readable:{__proto__:null,get(){const oe=this._readableState;return!!oe&&oe.readable!==!1&&!oe.destroyed&&!oe.errorEmitted&&!oe.endEmitted},set(oe){this._readableState&&(this._readableState.readable=!!oe)}},readableDidRead:{__proto__:null,enumerable:!1,get:function(){return this._readableState.dataEmitted}},readableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._readableState.readable!==!1&&(this._readableState.destroyed||this._readableState.errored)&&!this._readableState.endEmitted)}},readableHighWaterMark:{__proto__:null,enumerable:!1,get:function(){return this._readableState.highWaterMark}},readableBuffer:{__proto__:null,enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}},readableFlowing:{__proto__:null,enumerable:!1,get:function(){return this._readableState.flowing},set:function(oe){this._readableState&&(this._readableState.flowing=oe)}},readableLength:{__proto__:null,enumerable:!1,get(){return this._readableState.length}},readableObjectMode:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.objectMode:!1}},readableEncoding:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.encoding:null}},errored:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.errored:null}},closed:{__proto__:null,get(){return this._readableState?this._readableState.closed:!1}},destroyed:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.destroyed:!1},set(oe){this._readableState&&(this._readableState.destroyed=oe)}},readableEnded:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.endEmitted:!1}}}),r(re.prototype,{pipesCount:{__proto__:null,get(){return this.pipes.length}},paused:{__proto__:null,get(){return this[$]!==!1},set(oe){this[$]=!!oe}}}),ce._fromList=je;function je(oe,C){if(C.length===0)return null;let ee;return C.objectMode?ee=C.buffer.shift():!oe||oe>=C.length?(C.decoder?ee=C.buffer.join(""):C.buffer.length===1?ee=C.buffer.first():ee=C.buffer.concat(C.length),C.buffer.clear()):ee=C.buffer.consume(oe,C.decoder),ee}function He(oe){const C=oe._readableState;_("endReadable",C.endEmitted),C.endEmitted||(C.ended=!0,t.nextTick(Ge,C,oe))}function Ge(oe,C){if(_("endReadableNT",oe.endEmitted,oe.length),!oe.errored&&!oe.closeEmitted&&!oe.endEmitted&&oe.length===0){if(oe.endEmitted=!0,C.emit("end"),C.writable&&C.allowHalfOpen===!1)t.nextTick(tt,C);else if(oe.autoDestroy){const ee=C._writableState;(!ee||ee.autoDestroy&&(ee.finished||ee.writable===!1))&&C.destroy()}}}function tt(oe){oe.writable&&!oe.writableEnded&&!oe.destroyed&&oe.end()}ce.from=function(oe,C){return X(ce,oe,C)};let lt;function ut(){return lt===void 0&&(lt={}),lt}return ce.fromWeb=function(oe,C){return ut().newStreamReadableFromReadableStream(oe,C)},ce.toWeb=function(oe,C){return ut().newReadableStreamFromStreamReadable(oe,C)},ce.wrap=function(oe,C){var ee,ye;return new ce({objectMode:(ee=(ye=oe.readableObjectMode)!==null&&ye!==void 0?ye:oe.objectMode)!==null&&ee!==void 0?ee:!0,...C,destroy(Pe,Ue){S.destroyer(oe,Pe),Ue(Pe)}}).wrap(oe)},D_}var N_,OI;function KT(){if(OI)return N_;OI=1;const t=Ta(),{ArrayPrototypeSlice:e,Error:u,FunctionPrototypeSymbolHasInstance:s,ObjectDefineProperty:n,ObjectDefineProperties:r,ObjectSetPrototypeOf:a,StringPrototypeToLowerCase:o,Symbol:l,SymbolHasInstance:c}=Rr();N_=q,q.WritableState=U;const{EventEmitter:d}=Ry(),h=XT().Stream,{Buffer:f}=Wi(),p=au(),{addAbortSignal:y}=Jb(),{getHighWaterMark:b,getDefaultHighWaterMark:g}=Xb(),{ERR_INVALID_ARG_TYPE:m,ERR_METHOD_NOT_IMPLEMENTED:v,ERR_MULTIPLE_CALLBACK:_,ERR_STREAM_CANNOT_PIPE:w,ERR_STREAM_DESTROYED:S,ERR_STREAM_ALREADY_FINISHED:A,ERR_STREAM_NULL_VALUES:D,ERR_STREAM_WRITE_AFTER_END:L,ERR_UNKNOWN_ENCODING:O}=Un().codes,{errorOrDestroy:E}=p;a(q.prototype,h.prototype),a(q,h);function P(){}const M=l("kOnFinished");function U(T,x,B){typeof B!="boolean"&&(B=x instanceof va()),this.objectMode=!!(T&&T.objectMode),B&&(this.objectMode=this.objectMode||!!(T&&T.writableObjectMode)),this.highWaterMark=T?b(this,T,"writableHighWaterMark",B):g(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;const k=!!(T&&T.decodeStrings===!1);this.decodeStrings=!k,this.defaultEncoding=T&&T.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=K.bind(void 0,x),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,j(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!T||T.emitClose!==!1,this.autoDestroy=!T||T.autoDestroy!==!1,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[M]=[]}function j(T){T.buffered=[],T.bufferedIndex=0,T.allBuffers=!0,T.allNoop=!0}U.prototype.getBuffer=function(){return e(this.buffered,this.bufferedIndex)},n(U.prototype,"bufferedRequestCount",{__proto__:null,get(){return this.buffered.length-this.bufferedIndex}});function q(T){const x=this instanceof va();if(!x&&!s(q,this))return new q(T);this._writableState=new U(T,this,x),T&&(typeof T.write=="function"&&(this._write=T.write),typeof T.writev=="function"&&(this._writev=T.writev),typeof T.destroy=="function"&&(this._destroy=T.destroy),typeof T.final=="function"&&(this._final=T.final),typeof T.construct=="function"&&(this._construct=T.construct),T.signal&&y(T.signal,this)),h.call(this,T),p.construct(this,()=>{const B=this._writableState;B.writing||ae(this,B),de(this,B)})}n(q,c,{__proto__:null,value:function(T){return s(this,T)?!0:this!==q?!1:T&&T._writableState instanceof U}}),q.prototype.pipe=function(){E(this,new w)};function $(T,x,B,k){const V=T._writableState;if(typeof B=="function")k=B,B=V.defaultEncoding;else{if(!B)B=V.defaultEncoding;else if(B!=="buffer"&&!f.isEncoding(B))throw new O(B);typeof k!="function"&&(k=P)}if(x===null)throw new D;if(!V.objectMode)if(typeof x=="string")V.decodeStrings!==!1&&(x=f.from(x,B),B="buffer");else if(x instanceof f)B="buffer";else if(h._isUint8Array(x))x=h._uint8ArrayToBuffer(x),B="buffer";else throw new m("chunk",["string","Buffer","Uint8Array"],x);let J;return V.ending?J=new L:V.destroyed&&(J=new S("write")),J?(t.nextTick(k,J),E(T,J,!0),J):(V.pendingcb++,Z(T,V,x,B,k))}q.prototype.write=function(T,x,B){return $(this,T,x,B)===!0},q.prototype.cork=function(){this._writableState.corked++},q.prototype.uncork=function(){const T=this._writableState;T.corked&&(T.corked--,T.writing||ae(this,T))},q.prototype.setDefaultEncoding=function(x){if(typeof x=="string"&&(x=o(x)),!f.isEncoding(x))throw new O(x);return this._writableState.defaultEncoding=x,this};function Z(T,x,B,k,V){const J=x.objectMode?1:B.length;x.length+=J;const z=x.lengthB.bufferedIndex&&ae(T,B),k?B.afterWriteTickInfo!==null&&B.afterWriteTickInfo.cb===V?B.afterWriteTickInfo.count++:(B.afterWriteTickInfo={count:1,cb:V,stream:T,state:B},t.nextTick(he,B.afterWriteTickInfo)):Re(T,B,1,V))}function he({stream:T,state:x,count:B,cb:k}){return x.afterWriteTickInfo=null,Re(T,x,B,k)}function Re(T,x,B,k){for(!x.ending&&!T.destroyed&&x.length===0&&x.needDrain&&(x.needDrain=!1,T.emit("drain"));B-- >0;)x.pendingcb--,k();x.destroyed&&ie(x),de(T,x)}function ie(T){if(T.writing)return;for(let V=T.bufferedIndex;V1&&T._writev){x.pendingcb-=J-1;const Y=x.allNoop?P:ce=>{for(let Te=z;Te256?(B.splice(0,z),x.bufferedIndex=0):x.bufferedIndex=z}x.bufferProcessing=!1}q.prototype._write=function(T,x,B){if(this._writev)this._writev([{chunk:T,encoding:x}],B);else throw new v("_write()")},q.prototype._writev=null,q.prototype.end=function(T,x,B){const k=this._writableState;typeof T=="function"?(B=T,T=null,x=null):typeof x=="function"&&(B=x,x=null);let V;if(T!=null){const J=$(this,T,x);J instanceof u&&(V=J)}return k.corked&&(k.corked=1,this.uncork()),V||(!k.errored&&!k.ending?(k.ending=!0,de(this,k,!0),k.ended=!0):k.finished?V=new A("end"):k.destroyed&&(V=new S("end"))),typeof B=="function"&&(V||k.finished?t.nextTick(B,V):k[M].push(B)),this};function Ee(T){return T.ending&&!T.destroyed&&T.constructed&&T.length===0&&!T.errored&&T.buffered.length===0&&!T.finished&&!T.writing&&!T.errorEmitted&&!T.closeEmitted}function De(T,x){let B=!1;function k(V){if(B){E(T,V??_());return}if(B=!0,x.pendingcb--,V){const J=x[M].splice(0);for(let z=0;z{Ee(V)?fe(k,V):V.pendingcb--},T,x)):Ee(x)&&(x.pendingcb++,fe(T,x))))}function fe(T,x){x.pendingcb--,x.finished=!0;const B=x[M].splice(0);for(let k=0;k{if(ie!=null)throw new y("nully","body",ie)},ie=>{b(he,ie)});return he=new O({objectMode:!0,readable:!1,write:Z,final(ie){X(async()=>{try{await Re,t.nextTick(ie,null)}catch(ae){t.nextTick(ie,ae)}})},destroy:le})}throw new y("Iterable, AsyncIterable or AsyncFunction",j,$)}if(A(U))return M(U.arrayBuffer());if(n(U))return w(O,U,{objectMode:!0,writable:!1});if(c(U==null?void 0:U.readable)&&d(U==null?void 0:U.writable))return O.fromWeb(U);if(typeof(U==null?void 0:U.writable)=="object"||typeof(U==null?void 0:U.readable)=="object"){const $=U!=null&&U.readable?a(U==null?void 0:U.readable)?U==null?void 0:U.readable:M(U.readable):void 0,Z=U!=null&&U.writable?o(U==null?void 0:U.writable)?U==null?void 0:U.writable:M(U.writable):void 0;return P({readable:$,writable:Z})}const q=U==null?void 0:U.then;if(typeof q=="function"){let $;return L(q,U,Z=>{Z!=null&&$.push(Z),$.push(null)},Z=>{b($,Z)}),$=new O({objectMode:!0,writable:!1,read(){}})}throw new p(j,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],U)};function E(M){let{promise:U,resolve:j}=_();const q=new D,$=q.signal;return{value:M(async function*(){for(;;){const X=U;U=null;const{chunk:le,done:K,cb:he}=await X;if(t.nextTick(he),K)return;if($.aborted)throw new f(void 0,{cause:$.reason});({promise:U,resolve:j}=_()),yield le}}(),{signal:$}),write(X,le,K){const he=j;j=null,he({chunk:X,done:!1,cb:K})},final(X){const le=j;j=null,le({done:!0,cb:X})},destroy(X,le){q.abort(),le(X)}}}function P(M){const U=M.readable&&typeof M.readable.read!="function"?m.wrap(M.readable):M.readable,j=M.writable;let q=!!u(U),$=!!s(j),Z,X,le,K,he;function Re(ie){const ae=K;K=null,ae?ae(ie):ie&&he.destroy(ie)}return he=new O({readableObjectMode:!!(U!=null&&U.readableObjectMode),writableObjectMode:!!(j!=null&&j.writableObjectMode),readable:q,writable:$}),$&&(h(j,ie=>{$=!1,ie&&b(U,ie),Re(ie)}),he._write=function(ie,ae,Ee){j.write(ie,ae)?Ee():Z=Ee},he._final=function(ie){j.end(),X=ie},j.on("drain",function(){if(Z){const ie=Z;Z=null,ie()}}),j.on("finish",function(){if(X){const ie=X;X=null,ie()}})),q&&(h(U,ie=>{q=!1,ie&&b(U,ie),Re(ie)}),U.on("readable",function(){if(le){const ie=le;le=null,ie()}}),U.on("end",function(){he.push(null)}),he._read=function(){for(;;){const ie=U.read();if(ie===null){le=he._read;return}if(!he.push(ie))return}}),he._destroy=function(ie,ae){!ie&&K!==null&&(ie=new f),le=null,Z=null,X=null,K===null?ae(ie):(K=ae,b(j,ie),b(U,ie))},he}return C_}var j_,xI;function va(){if(xI)return j_;xI=1;const{ObjectDefineProperties:t,ObjectGetOwnPropertyDescriptor:e,ObjectKeys:u,ObjectSetPrototypeOf:s}=Rr();j_=a;const n=Kb(),r=KT();s(a.prototype,n.prototype),s(a,n);{const d=u(r.prototype);for(let h=0;h{if(d){c?c(d):this.destroy(d);return}h!=null&&this.push(h),this.push(null),c&&c()}):(this.push(null),c&&c())}function l(){this._final!==o&&o.call(this)}return a.prototype._final=o,a.prototype._transform=function(c,d,h){throw new u("_transform()")},a.prototype._write=function(c,d,h){const f=this._readableState,p=this._writableState,y=f.length;this._transform(c,d,(b,g)=>{if(b){h(b);return}g!=null&&this.push(g),p.ended||y===f.length||f.length{De=!0});const ge=r(ie,{readable:ae,writable:Ee},de=>{De=!de});return{destroy:de=>{De||(De=!0,o.destroyer(ie,de||new p("pipe")))},cleanup:ge}}function q(ie){return g(ie[ie.length-1],"streams[stream.length - 1]"),ie.pop()}function $(ie){if(v(ie))return ie;if(w(ie))return Z(ie);throw new d("val",["Readable","Iterable","AsyncIterable"],ie)}async function*Z(ie){M||(M=Kb()),yield*M.prototype[s].call(ie)}async function X(ie,ae,Ee,{end:De}){let ge,de=null;const fe=R=>{if(R&&(ge=R),de){const T=de;de=null,T()}},H=()=>new u((R,T)=>{ge?T(ge):de=()=>{ge?T(ge):R()}});ae.on("drain",fe);const N=r(ae,{readable:!1},fe);try{ae.writableNeedDrain&&await H();for await(const R of ie)ae.write(R)||await H();De&&(ae.end(),await H()),Ee()}catch(R){Ee(ge!==R?c(ge,R):R)}finally{N(),ae.off("drain",fe)}}async function le(ie,ae,Ee,{end:De}){A(ae)&&(ae=ae.writable);const ge=ae.getWriter();try{for await(const de of ie)await ge.ready,ge.write(de).catch(()=>{});await ge.ready,De&&await ge.close(),Ee()}catch(de){try{await ge.abort(de),Ee(de)}catch(fe){Ee(fe)}}}function K(...ie){return he(ie,a(q(ie)))}function he(ie,ae,Ee){if(ie.length===1&&e(ie[0])&&(ie=ie[0]),ie.length<2)throw new f("streams");const De=new E,ge=De.signal,de=Ee==null?void 0:Ee.signal,fe=[];m(de,"options.signal");function H(){V(new b)}U=U||In().addAbortListener;let N;de&&(N=U(de,H));let R,T;const x=[];let B=0;function k(re){V(re,--B===0)}function V(re,ce){var Te;if(re&&(!R||R.code==="ERR_STREAM_PREMATURE_CLOSE")&&(R=re),!(!R&&!ce)){for(;x.length;)x.shift()(R);(Te=N)===null||Te===void 0||Te[n](),De.abort(),ce&&(R||fe.forEach(xe=>xe()),t.nextTick(ae,R,T))}}let J;for(let re=0;re0,Le=Te||(Ee==null?void 0:Ee.end)!==!1,qe=re===ie.length-1;if(S(ce)){let G=function(F){F&&F.name!=="AbortError"&&F.code!=="ERR_STREAM_PREMATURE_CLOSE"&&k(F)};if(Le){const{destroy:F,cleanup:Q}=j(ce,Te,xe);x.push(F),_(ce)&&qe&&fe.push(Q)}ce.on("error",G),_(ce)&&qe&&fe.push(()=>{ce.removeListener("error",G)})}if(re===0)if(typeof ce=="function"){if(J=ce({signal:ge}),!v(J))throw new h("Iterable, AsyncIterable or Stream","source",J)}else v(ce)||w(ce)||A(ce)?J=ce:J=l.from(ce);else if(typeof ce=="function"){if(A(J)){var z;J=$((z=J)===null||z===void 0?void 0:z.readable)}else J=$(J);if(J=ce(J,{signal:ge}),Te){if(!v(J,!0))throw new h("AsyncIterable",`transform[${re-1}]`,J)}else{var Y;P||(P=Bq());const G=new P({objectMode:!0}),F=(Y=J)===null||Y===void 0?void 0:Y.then;if(typeof F=="function")B++,F.call(J,me=>{T=me,me!=null&&G.write(me),Le&&G.end(),t.nextTick(k)},me=>{G.destroy(me),t.nextTick(k,me)});else if(v(J,!0))B++,X(J,G,k,{end:Le});else if(L(J)||A(J)){const me=J.readable||J;B++,X(me,G,k,{end:Le})}else throw new h("AsyncIterable or Promise","destination",J);J=G;const{destroy:Q,cleanup:te}=j(J,!1,!0);x.push(Q),qe&&fe.push(te)}}else if(S(ce)){if(w(J)){B+=2;const G=Re(J,ce,k,{end:Le});_(ce)&&qe&&fe.push(G)}else if(A(J)||L(J)){const G=J.readable||J;B++,X(G,ce,k,{end:Le})}else if(v(J))B++,X(J,ce,k,{end:Le});else throw new d("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],J);J=ce}else if(D(ce)){if(w(J))B++,le($(J),ce,k,{end:Le});else if(L(J)||v(J))B++,le(J,ce,k,{end:Le});else if(A(J))B++,le(J.readable,ce,k,{end:Le});else throw new d("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],J);J=ce}else J=l.from(ce)}return(ge!=null&&ge.aborted||de!=null&&de.aborted)&&t.nextTick(H),J}function Re(ie,ae,Ee,{end:De}){let ge=!1;if(ae.on("close",()=>{ge||Ee(new y)}),ie.pipe(ae,{end:!1}),De){let de=function(){ge=!0,ae.end()};O(ie)?t.nextTick(de):ie.once("end",de)}else Ee();return r(ie,{readable:!0,writable:!1},de=>{const fe=ie._readableState;de&&de.code==="ERR_STREAM_PREMATURE_CLOSE"&&fe&&fe.ended&&!fe.errored&&!fe.errorEmitted?ie.once("end",Ee).once("error",Ee):Ee(de)}),r(ae,{readable:!1,writable:!0},Ee)}return F_={pipelineImpl:he,pipeline:K},F_}var q_,NI;function Uq(){if(NI)return q_;NI=1;const{pipeline:t}=YT(),e=va(),{destroyer:u}=au(),{isNodeStream:s,isReadable:n,isWritable:r,isWebStream:a,isTransformStream:o,isWritableStream:l,isReadableStream:c}=Aa(),{AbortError:d,codes:{ERR_INVALID_ARG_VALUE:h,ERR_MISSING_ARGS:f}}=Un(),p=rs();return q_=function(...b){if(b.length===0)throw new f("streams");if(b.length===1)return e.from(b[0]);const g=[...b];if(typeof b[0]=="function"&&(b[0]=e.from(b[0])),typeof b[b.length-1]=="function"){const P=b.length-1;b[P]=e.from(b[P])}for(let P=0;P0&&!(r(b[P])||l(b[P])||o(b[P])))throw new h(`streams[${P}]`,g[P],"must be writable")}let m,v,_,w,S;function A(P){const M=w;w=null,M?M(P):P?S.destroy(P):!E&&!O&&S.destroy()}const D=b[0],L=t(b,A),O=!!(r(D)||l(D)||o(D)),E=!!(n(L)||c(L)||o(L));if(S=new e({writableObjectMode:!!(D!=null&&D.writableObjectMode),readableObjectMode:!!(L!=null&&L.readableObjectMode),writable:O,readable:E}),O){if(s(D))S._write=function(M,U,j){D.write(M,U)?j():m=j},S._final=function(M){D.end(),v=M},D.on("drain",function(){if(m){const M=m;m=null,M()}});else if(a(D)){const U=(o(D)?D.writable:D).getWriter();S._write=async function(j,q,$){try{await U.ready,U.write(j).catch(()=>{}),$()}catch(Z){$(Z)}},S._final=async function(j){try{await U.ready,U.close().catch(()=>{}),v=j}catch(q){j(q)}}}const P=o(L)?L.readable:L;p(P,()=>{if(v){const M=v;v=null,M()}})}if(E){if(s(L))L.on("readable",function(){if(_){const P=_;_=null,P()}}),L.on("end",function(){S.push(null)}),S._read=function(){for(;;){const P=L.read();if(P===null){_=S._read;return}if(!S.push(P))return}};else if(a(L)){const M=(o(L)?L.readable:L).getReader();S._read=async function(){for(;;)try{const{value:U,done:j}=await M.read();if(!S.push(U))return;if(j){S.push(null);return}}catch{return}}}}return S._destroy=function(P,M){!P&&w!==null&&(P=new d),_=null,m=null,v=null,w===null?M(P):(w=M,s(L)&&u(L,P))},S},q_}var CI;function MG(){if(CI)return h1;CI=1;const t=globalThis.AbortController||Qo().AbortController,{codes:{ERR_INVALID_ARG_VALUE:e,ERR_INVALID_ARG_TYPE:u,ERR_MISSING_ARGS:s,ERR_OUT_OF_RANGE:n},AbortError:r}=Un(),{validateAbortSignal:a,validateInteger:o,validateObject:l}=Dy(),c=Rr().Symbol("kWeak"),d=Rr().Symbol("kResistStopPropagation"),{finished:h}=rs(),f=Uq(),{addAbortSignalNoValidate:p}=Jb(),{isWritable:y,isNodeStream:b}=Aa(),{deprecate:g}=In(),{ArrayPrototypePush:m,Boolean:v,MathFloor:_,Number:w,NumberIsNaN:S,Promise:A,PromiseReject:D,PromiseResolve:L,PromisePrototypeThen:O,Symbol:E}=Rr(),P=E("kEmpty"),M=E("kEof");function U(de,fe){if(fe!=null&&l(fe,"options"),(fe==null?void 0:fe.signal)!=null&&a(fe.signal,"options.signal"),b(de)&&!y(de))throw new e("stream",de,"must be writable");const H=f(this,de);return fe!=null&&fe.signal&&p(fe.signal,H),H}function j(de,fe){if(typeof de!="function")throw new u("fn",["Function","AsyncFunction"],de);fe!=null&&l(fe,"options"),(fe==null?void 0:fe.signal)!=null&&a(fe.signal,"options.signal");let H=1;(fe==null?void 0:fe.concurrency)!=null&&(H=_(fe.concurrency));let N=H-1;return(fe==null?void 0:fe.highWaterMark)!=null&&(N=_(fe.highWaterMark)),o(H,"options.concurrency",1),o(N,"options.highWaterMark",0),N+=H,(async function*(){const T=In().AbortSignalAny([fe==null?void 0:fe.signal].filter(v)),x=this,B=[],k={signal:T};let V,J,z=!1,Y=0;function re(){z=!0,ce()}function ce(){Y-=1,Te()}function Te(){J&&!z&&Y=N||Y>=H)&&await new A(qe=>{J=qe})}B.push(M)}catch(Le){const qe=D(Le);O(qe,ce,re),B.push(qe)}finally{z=!0,V&&(V(),V=null)}}xe();try{for(;;){for(;B.length>0;){const Le=await B[0];if(Le===M)return;if(T.aborted)throw new r;Le!==P&&(yield Le),B.shift(),Te()}await new A(Le=>{V=Le})}}finally{z=!0,J&&(J(),J=null)}}).call(this)}function q(de=void 0){return de!=null&&l(de,"options"),(de==null?void 0:de.signal)!=null&&a(de.signal,"options.signal"),(async function*(){let H=0;for await(const R of this){var N;if(de!=null&&(N=de.signal)!==null&&N!==void 0&&N.aborted)throw new r({cause:de.signal.reason});yield[H++,R]}}).call(this)}async function $(de,fe=void 0){for await(const H of K.call(this,de,fe))return!0;return!1}async function Z(de,fe=void 0){if(typeof de!="function")throw new u("fn",["Function","AsyncFunction"],de);return!await $.call(this,async(...H)=>!await de(...H),fe)}async function X(de,fe){for await(const H of K.call(this,de,fe))return H}async function le(de,fe){if(typeof de!="function")throw new u("fn",["Function","AsyncFunction"],de);async function H(N,R){return await de(N,R),P}for await(const N of j.call(this,H,fe));}function K(de,fe){if(typeof de!="function")throw new u("fn",["Function","AsyncFunction"],de);async function H(N,R){return await de(N,R)?N:P}return j.call(this,H,fe)}class he extends s{constructor(){super("reduce"),this.message="Reduce of an empty stream requires an initial value"}}async function Re(de,fe,H){var N;if(typeof de!="function")throw new u("reducer",["Function","AsyncFunction"],de);H!=null&&l(H,"options"),(H==null?void 0:H.signal)!=null&&a(H.signal,"options.signal");let R=arguments.length>1;if(H!=null&&(N=H.signal)!==null&&N!==void 0&&N.aborted){const V=new r(void 0,{cause:H.signal.reason});throw this.once("error",()=>{}),await h(this.destroy(V)),V}const T=new t,x=T.signal;if(H!=null&&H.signal){const V={once:!0,[c]:this,[d]:!0};H.signal.addEventListener("abort",()=>T.abort(),V)}let B=!1;try{for await(const V of this){var k;if(B=!0,H!=null&&(k=H.signal)!==null&&k!==void 0&&k.aborted)throw new r;R?fe=await de(fe,V,{signal:x}):(fe=V,R=!0)}if(!B&&!R)throw new he}finally{T.abort()}return fe}async function ie(de){de!=null&&l(de,"options"),(de==null?void 0:de.signal)!=null&&a(de.signal,"options.signal");const fe=[];for await(const N of this){var H;if(de!=null&&(H=de.signal)!==null&&H!==void 0&&H.aborted)throw new r(void 0,{cause:de.signal.reason});m(fe,N)}return fe}function ae(de,fe){const H=j.call(this,de,fe);return(async function*(){for await(const R of H)yield*R}).call(this)}function Ee(de){if(de=w(de),S(de))return 0;if(de<0)throw new n("number",">= 0",de);return de}function De(de,fe=void 0){return fe!=null&&l(fe,"options"),(fe==null?void 0:fe.signal)!=null&&a(fe.signal,"options.signal"),de=Ee(de),(async function*(){var N;if(fe!=null&&(N=fe.signal)!==null&&N!==void 0&&N.aborted)throw new r;for await(const T of this){var R;if(fe!=null&&(R=fe.signal)!==null&&R!==void 0&&R.aborted)throw new r;de--<=0&&(yield T)}}).call(this)}function ge(de,fe=void 0){return fe!=null&&l(fe,"options"),(fe==null?void 0:fe.signal)!=null&&a(fe.signal,"options.signal"),de=Ee(de),(async function*(){var N;if(fe!=null&&(N=fe.signal)!==null&&N!==void 0&&N.aborted)throw new r;for await(const T of this){var R;if(fe!=null&&(R=fe.signal)!==null&&R!==void 0&&R.aborted)throw new r;if(de-- >0&&(yield T),de<=0)return}}).call(this)}return h1.streamReturningOperators={asIndexedPairs:g(q,"readable.asIndexedPairs will be removed in a future version."),drop:De,filter:K,flatMap:ae,map:j,take:ge,compose:U},h1.promiseReturningOperators={every:Z,forEach:le,reduce:Re,toArray:ie,some:$,find:X},h1}var B_,jI;function Qq(){if(jI)return B_;jI=1;const{ArrayPrototypePop:t,Promise:e}=Rr(),{isIterable:u,isNodeStream:s,isWebStream:n}=Aa(),{pipelineImpl:r}=YT(),{finished:a}=rs();Hq();function o(...l){return new e((c,d)=>{let h,f;const p=l[l.length-1];if(p&&typeof p=="object"&&!s(p)&&!u(p)&&!n(p)){const y=t(l);h=y.signal,f=y.end}r(l,(y,b)=>{y?d(y):c(b)},{signal:h,end:f})})}return B_={finished:a,pipeline:o},B_}var LI;function Hq(){if(LI)return m_.exports;LI=1;const{Buffer:t}=Wi(),{ObjectDefineProperty:e,ObjectKeys:u,ReflectApply:s}=Rr(),{promisify:{custom:n}}=In(),{streamReturningOperators:r,promiseReturningOperators:a}=MG(),{codes:{ERR_ILLEGAL_CONSTRUCTOR:o}}=Un(),l=Uq(),{setDefaultHighWaterMark:c,getDefaultHighWaterMark:d}=Xb(),{pipeline:h}=YT(),{destroyer:f}=au(),p=rs(),y=Qq(),b=Aa(),g=m_.exports=XT().Stream;g.isDestroyed=b.isDestroyed,g.isDisturbed=b.isDisturbed,g.isErrored=b.isErrored,g.isReadable=b.isReadable,g.isWritable=b.isWritable,g.Readable=Kb();for(const v of u(r)){let w=function(...S){if(new.target)throw o();return g.Readable.from(s(_,this,S))};const _=r[v];e(w,"name",{__proto__:null,value:_.name}),e(w,"length",{__proto__:null,value:_.length}),e(g.Readable.prototype,v,{__proto__:null,value:w,enumerable:!1,configurable:!0,writable:!0})}for(const v of u(a)){let w=function(...S){if(new.target)throw o();return s(_,this,S)};const _=a[v];e(w,"name",{__proto__:null,value:_.name}),e(w,"length",{__proto__:null,value:_.length}),e(g.Readable.prototype,v,{__proto__:null,value:w,enumerable:!1,configurable:!0,writable:!0})}g.Writable=KT(),g.Duplex=va(),g.Transform=qq(),g.PassThrough=Bq(),g.pipeline=h;const{addAbortSignal:m}=Jb();return g.addAbortSignal=m,g.finished=p,g.destroy=f,g.compose=l,g.setDefaultHighWaterMark=c,g.getDefaultHighWaterMark=d,e(g,"promises",{__proto__:null,configurable:!0,enumerable:!0,get(){return y}}),e(h,n,{__proto__:null,enumerable:!0,get(){return y.pipeline}}),e(p,n,{__proto__:null,enumerable:!0,get(){return y.finished}}),g.Stream=g,g._isUint8Array=function(_){return _ instanceof Uint8Array},g._uint8ArrayToBuffer=function(_){return t.from(_.buffer,_.byteOffset,_.byteLength)},m_.exports}var MI;function Wt(){return MI||(MI=1,function(t){const e=Hq(),u=Qq(),s=e.Readable.destroy;t.exports=e.Readable,t.exports._uint8ArrayToBuffer=e._uint8ArrayToBuffer,t.exports._isUint8Array=e._isUint8Array,t.exports.isDisturbed=e.isDisturbed,t.exports.isErrored=e.isErrored,t.exports.isReadable=e.isReadable,t.exports.Readable=e.Readable,t.exports.Writable=e.Writable,t.exports.Duplex=e.Duplex,t.exports.Transform=e.Transform,t.exports.PassThrough=e.PassThrough,t.exports.addAbortSignal=e.addAbortSignal,t.exports.finished=e.finished,t.exports.destroy=e.destroy,t.exports.destroy=s,t.exports.pipeline=e.pipeline,t.exports.compose=e.compose,Object.defineProperty(e,"promises",{configurable:!0,enumerable:!0,get(){return u}}),t.exports.Stream=e.Stream,t.exports.default=t.exports}(b_)),b_.exports}var FI;function FG(){if(FI)return jc;FI=1,Object.defineProperty(jc,"__esModule",{value:!0}),jc.ActorQueryResultSerializeJson=void 0;const t=Gi(),e=Dt(),u=Xt(),s=Wt();let n=class extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(a){super(a)}async testHandleChecked(a,o){if(!["bindings","quads","boolean"].includes(a.type))throw new Error("This actor can only handle bindings or quad streams.");return!0}async runHandle(a,o,l){const c=new s.Readable;if(c._read=()=>{},a.type==="bindings"||a.type==="quads"){let d=a.type==="bindings"?(0,e.wrap)(a.bindingsStream).map(f=>JSON.stringify(Object.fromEntries([...f].map(([p,y])=>[p.value,u.termToString(y)])))):(0,e.wrap)(a.quadStream).map(f=>JSON.stringify(u.quadToStringQuad(f))),h=!0;d=d.map(f=>{const p=`${h?"":","} +${f}`;return h=!1,p}).prepend(["["]).append([` +] +`]),c.wrap(d)}else try{c.push(`${JSON.stringify(await a.execute())} +`),c.push(null)}catch(d){setTimeout(()=>c.emit("error",d))}return{data:c}}};return jc.ActorQueryResultSerializeJson=n,jc}var qI;function qG(){return qI||(qI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(FG(),t)}(h_)),h_}var U_={},Qc={},BI;function BG(){if(BI)return Qc;BI=1,Object.defineProperty(Qc,"__esModule",{value:!0}),Qc.ActorQueryResultSerializeSimple=void 0;const t=Gi(),e=Dt(),u=Xt(),s=Wt();let n=class wo extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(a){super(a)}async testHandleChecked(a,o){if(!["bindings","quads","boolean","void"].includes(a.type))throw new Error("This actor can only handle bindings streams, quad streams, booleans, or updates.");return!0}static termToString(a){return a.termType==="Quad"?(0,u.termToString)(a):a.value}async runHandle(a,o,l){const c=new s.Readable;return a.type==="bindings"?c.wrap(a.bindingsStream.map(d=>`${[...d].map(([h,f])=>`?${h.value}: ${wo.termToString(f)}`).join(` +`)} + +`)):a.type==="quads"?c.wrap(a.quadStream.map(d=>`subject: ${wo.termToString(d.subject)} +predicate: ${wo.termToString(d.predicate)} +object: ${wo.termToString(d.object)} +graph: ${wo.termToString(d.graph)} + +`)):c.wrap((0,e.wrap)(a.type==="boolean"?a.execute().then(d=>[`${d} +`]):a.execute().then(()=>[`ok +`]))),{data:c}}};return Qc.ActorQueryResultSerializeSimple=n,Qc}var UI;function UG(){return UI||(UI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(BG(),t)}(U_)),U_}var Q_={},Hc={},QI;function QG(){if(QI)return Hc;QI=1,Object.defineProperty(Hc,"__esModule",{value:!0}),Hc.ActorQueryResultSerializeSparqlCsv=void 0;const t=Gi(),e=Wt();let u=class x0 extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(n){super(n)}static bindingToCsvBindings(n){if(!n)return"";let r=n.value;if(n.termType==="Literal")r=`${r}`;else if(n.termType==="BlankNode")r=`_:${r}`;else if(n.termType==="Quad"){let a=x0.bindingToCsvBindings(n.object);n.object.termType==="Literal"&&(a=`"${a.replaceAll('"','""')}"`),r=`<< ${x0.bindingToCsvBindings(n.subject)} ${x0.bindingToCsvBindings(n.predicate)} ${a} >>`}else r=`<${r}>`;return/[",\n\r]/u.test(r)&&(r=`"${r.replaceAll('"','""')}"`),r}async testHandleChecked(n,r){if(n.type!=="bindings")throw new Error("This actor can only handle bindings streams.");return!0}async runHandle(n,r,a){const o=n,l=new e.Readable,c=await o.metadata();return l.push(`${c.variables.map(d=>d.value).join(",")}\r +`),l.wrap(o.bindingsStream.map(d=>`${c.variables.map(h=>x0.bindingToCsvBindings(d.get(h))).join(",")}\r +`)),{data:l}}};return Hc.ActorQueryResultSerializeSparqlCsv=u,Hc}var HI;function HG(){return HI||(HI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(QG(),t)}(Q_)),Q_}var H_={},$c={},$_={},tn={},$I;function $G(){if($I)return tn;$I=1,Object.defineProperty(tn,"__esModule",{value:!0}),tn.stringQuadToQuad=tn.quadToStringQuad=tn.stringToTerm=tn.getLiteralLanguage=tn.getLiteralType=tn.getLiteralValue=tn.termToString=void 0;const t=Et(),e=new t.DataFactory;function u(y){if(y)switch(y.termType){case"NamedNode":return`<${c(y.value)}>`;case"BlankNode":return`_:${y.value}`;case"Literal":{const b=y;return`"${d(b.value)}"${b.datatype&&b.datatype.value!=="http://www.w3.org/2001/XMLSchema#string"&&b.datatype.value!=="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString"?`^^<${b.datatype.value}>`:""}${b.language?`@${b.language}`:""}`}case"Quad":return`<<${u(y.subject)} ${u(y.predicate)} ${u(y.object)}${y.graph.termType==="DefaultGraph"?"":` ${u(y.graph)}`}>>`;case"Variable":return`?${y.value}`;case"DefaultGraph":return y.value}}tn.termToString=u;function s(y){const b=/^"([^]*)"((\^\^.*)|(@.*))?$/u.exec(y);if(!b)throw new Error(`${y} is not a literal`);return b[1].replace(/\\"/ug,'"')}tn.getLiteralValue=s;function n(y){const b=/^"[^]*"(?:\^\^<([^"]+)>|(@)[^@"]+)?$/u.exec(y);if(!b)throw new Error(`${y} is not a literal`);return b[1]||(b[2]?"http://www.w3.org/1999/02/22-rdf-syntax-ns#langString":"http://www.w3.org/2001/XMLSchema#string")}tn.getLiteralType=n;function r(y){const b=/^"[^]*"(?:@([^@"]+)|\^\^[^"]+)?$/u.exec(y);if(!b)throw new Error(`${y} is not a literal`);return b[1]?b[1].toLowerCase():""}tn.getLiteralLanguage=r;function a(y,b){if(b=b||e,!y||y.length===0)return b.defaultGraph();switch(y[0]){case"_":return b.blankNode(y.slice(2));case"?":if(!b.variable)throw new Error("Missing 'variable()' method on the given DataFactory");return b.variable(y.slice(1));case'"':{const g=r(y),m=b.namedNode(n(y));return b.literal(s(y),g||m)}case"<":default:if(y.startsWith("<<")&&y.endsWith(">>")){const g=y.slice(2,-2),m=[];let v=0,_=0;for(let w=0;w"){if(v===0)throw new Error(`Found closing tag without opening tag in ${y}`);v--}S===" "&&v===0&&(m.push(g.slice(_,w)),_=w+1)}if(v!==0)throw new Error(`Found opening tag without closing tag in ${y}`);if(m.push(g.slice(_,g.length)),m.length!==3&&m.length!==4)throw new Error(`Nested quad syntax error ${y}`);return b.quad(a(m[0]),a(m[1]),a(m[2]),m[3]?a(m[3]):void 0)}if(!y.startsWith("<")||!y.endsWith(">"))throw new Error(`Detected invalid iri for named node (must be wrapped in <>): ${y}`);return b.namedNode(y.slice(1,-1))}}tn.stringToTerm=a;function o(y){return{subject:u(y.subject),predicate:u(y.predicate),object:u(y.object),graph:u(y.graph)}}tn.quadToStringQuad=o;function l(y,b){return b=b||e,b.quad(a(y.subject,b),a(y.predicate,b),a(y.object,b),a(y.graph,b))}tn.stringQuadToQuad=l;function c(y){return y.replace(h,p)}function d(y){return h.test(y)&&(y=y.replace(h,p)),y}const h=/["\\\t\n\r\b\f\u0000-\u0019]|[\uD800-\uDBFF][\uDC00-\uDFFF]/g,f=new Map([["\\","\\\\"],['"','\\"'],[" ","\\t"],[` +`,"\\n"],["\r","\\r"],["\b","\\b"],["\f","\\f"]]);function p(y){const b=f.get(y);if(!b){if(y.length===1){const m=y.charCodeAt(0).toString(16);return`${"\\u0000".slice(0,-m.length)}${m}`}const g=((y.charCodeAt(0)-55296)*1024+y.charCodeAt(1)+9216).toString(16);return`${"\\U00000000".slice(0,-g.length)}${g}`}return b}return tn}var VI;function Ny(){return VI||(VI=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.termToString=t.stringToTerm=t.stringQuadToQuad=t.quadToStringQuad=t.getLiteralValue=t.getLiteralType=t.getLiteralLanguage=void 0;const e=$G();Object.defineProperty(t,"getLiteralLanguage",{enumerable:!0,get:function(){return e.getLiteralLanguage}}),Object.defineProperty(t,"getLiteralType",{enumerable:!0,get:function(){return e.getLiteralType}}),Object.defineProperty(t,"getLiteralValue",{enumerable:!0,get:function(){return e.getLiteralValue}}),Object.defineProperty(t,"quadToStringQuad",{enumerable:!0,get:function(){return e.quadToStringQuad}}),Object.defineProperty(t,"stringQuadToQuad",{enumerable:!0,get:function(){return e.stringQuadToQuad}}),Object.defineProperty(t,"stringToTerm",{enumerable:!0,get:function(){return e.stringToTerm}}),Object.defineProperty(t,"termToString",{enumerable:!0,get:function(){return e.termToString}})}($_)),$_}var kI;function VG(){if(kI)return $c;kI=1,Object.defineProperty($c,"__esModule",{value:!0}),$c.ActorQueryResultSerializeSparqlTsv=void 0;const t=Gi(),e=Ny(),u=Wt();let s=class $q extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(r){super(r)}static bindingToTsvBindings(r){return r?(0,e.termToString)(r).replaceAll(" ","\\t").replaceAll(` +`,"\\n").replaceAll("\r","\\r"):""}async testHandleChecked(r,a){if(r.type!=="bindings")throw new Error("This actor can only handle bindings streams.");return!0}async runHandle(r,a,o){const l=r,c=new u.Readable,d=await l.metadata();return c.push(`${d.variables.map(h=>h.value).join(" ")} +`),c.wrap(l.bindingsStream.map(h=>`${d.variables.map(f=>$q.bindingToTsvBindings(h.get(f))).join(" ")} +`)),{data:c}}};return $c.ActorQueryResultSerializeSparqlTsv=s,$c}var zI;function kG(){return zI||(zI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(VG(),t)}(H_)),H_}var V_={},Vc={},kc={},GI;function zG(){if(GI)return kc;GI=1,Object.defineProperty(kc,"__esModule",{value:!0}),kc.XmlSerializer=void 0;let t=class{constructor(){this.stack=[]}open(u,s){const n=`${this.identation()+this.formatTag(u,s,"open")} +`;return this.stack.push(u),n}close(){const u=this.stack.pop();if(u===void 0)throw new Error("There is no tag left to close");return`${this.identation()+this.formatTag(u,{},"close")} +`}serializeNode(u){if(u.children===void 0)return`${this.identation()+this.formatTag(u.name,u.attributes,"self-closing")} +`;if(typeof u.children=="string")return`${this.identation()+this.formatTag(u.name,u.attributes,"open")+this.escape(u.children)+this.formatTag(u.name,{},"close")} +`;const s=[];s.push(`${this.identation()+this.formatTag(u.name,u.attributes,"open")} +`),this.stack.push(u.name);for(const n of u.children)s.push(this.serializeNode(n));return this.stack.pop(),s.push(`${this.identation()+this.formatTag(u.name,{},"close")} +`),s.join("")}identation(){return this.stack.map(u=>" ").join("")}formatTag(u,s,n){return`<${n==="close"?"/":""}${u}${Object.entries(s??{}).map(r=>` ${r[0]}="${this.escape(r[1])}"`)}${n==="self-closing"?"/":""}>`}escape(u){return u.replaceAll(/["&'<>]/gu,s=>{switch(s){case"<":return"<";case">":return">";case"&":return"&";case"'":return"'";case'"':return"""}})}};return kc.XmlSerializer=t,t.header=` +`,kc}var WI;function GG(){if(WI)return Vc;WI=1,Object.defineProperty(Vc,"__esModule",{value:!0}),Vc.ActorQueryResultSerializeSparqlXml=void 0;const t=Gi(),e=Dt(),u=Wt(),s=zG();let n=class Vq extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(a){super(a)}static bindingToXmlBindings(a,o){return{name:"binding",attributes:{name:o.value},children:[this.valueToXmlValue(a)]}}static valueToXmlValue(a){let o;switch(a.termType){case"Literal":return a.language?o={"xml:lang":a.language}:a.datatype&&a.datatype.value!=="http://www.w3.org/2001/XMLSchema#string"?o={datatype:a.datatype.value}:o={},{name:"literal",attributes:o,children:a.value};case"BlankNode":return{name:"bnode",children:a.value};case"Quad":return{name:"triple",children:[{name:"subject",children:[this.valueToXmlValue(a.subject)]},{name:"predicate",children:[this.valueToXmlValue(a.predicate)]},{name:"object",children:[this.valueToXmlValue(a.object)]}]};default:return{name:"uri",children:a.value}}}async testHandleChecked(a,o){if(!["bindings","boolean"].includes(a.type))throw new Error("This actor can only handle bindings streams or booleans.");return!0}async runHandle(a,o,l){const c=new u.Readable;c._read=()=>{};const d=new s.XmlSerializer,h=await a.metadata();if(c.push(s.XmlSerializer.header),c.push(d.open("sparql",{xmlns:"http://www.w3.org/2005/sparql-results#"})),c.push(d.serializeNode({name:"head",children:h.variables.map(f=>({name:"variable",attributes:{name:f.value}}))})),a.type==="bindings"){function*f(){yield d.close(),yield d.close()}c.push(d.open("results"));const p=(0,e.wrap)(a.bindingsStream).map(y=>d.serializeNode({name:"result",children:[...y].map(([b,g])=>Vq.bindingToXmlBindings(g,b))})).append((0,e.wrap)(f()));c.wrap(p)}else try{const f=await a.execute();c.push(d.serializeNode({name:"boolean",children:f.toString()})),c.push(d.close()),setTimeout(()=>c.push(null))}catch(f){setTimeout(()=>c.emit("error",f))}return{data:c}}};return Vc.ActorQueryResultSerializeSparqlXml=n,Vc}var JI;function WG(){return JI||(JI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(GG(),t)}(V_)),V_}var k_={},zc={},XI;function JG(){if(XI)return zc;XI=1,Object.defineProperty(zc,"__esModule",{value:!0}),zc.ActorQueryResultSerializeTable=void 0;const t=Gi(),e=Et(),u=Xt(),s=un(),n=Wt(),r=new e.DataFactory,a=s.QUAD_TERM_NAMES.map(l=>r.variable(l));let o=class m3 extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(c){super(c),this.padding=m3.repeat(" ",this.columnWidth)}static repeat(c,d){return c.repeat(d)}async testHandleChecked(c,d){if(!["bindings","quads"].includes(c.type))throw new Error("This actor can only handle bindings or quad streams.");return!0}termToString(c){return c.termType==="Quad"?(0,u.termToString)(c):c.value}pad(c){return c.length<=this.columnWidth?c+this.padding.slice(c.length):`${c.slice(0,this.columnWidth-1)}…`}pushHeader(c,d){const h=d.map(f=>this.pad(f.value)).join(" ");c.push(`${h} +${m3.repeat("-",h.length)} +`)}createRow(c,d){return`${c.map(h=>d.has(h)?this.termToString(d.get(h)):"").map(h=>this.pad(h)).join(" ")} +`}async runHandle(c,d,h){const f=new n.Readable;let p;if(c.type==="bindings"){p=c.bindingsStream.map(b=>this.createRow(y,b));const y=(await c.metadata()).variables;this.pushHeader(f,y)}else p=c.quadStream.map(y=>`${(0,s.getTerms)(y).map(b=>this.pad(this.termToString(b))).join(" ")} +`),this.pushHeader(f,a);return f.wrap(p),{data:f}}};return zc.ActorQueryResultSerializeTable=o,zc}var KI;function XG(){return KI||(KI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(JG(),t)}(k_)),k_}var z_={},Gc={},G_={},Wc={},W_={},J_={},Jc={},Xc={},YI;function Ho(){if(YI)return Xc;YI=1,Object.defineProperty(Xc,"__esModule",{value:!0}),Xc.Translator=void 0;let t=class{constructor(){this.supportedRdfDatatypes=[],this.fromRdfHandlers={},this.toRdfHandlers={}}static incorrectRdfDataType(u){throw new Error(`Invalid RDF ${u.datatype.value} value: '${u.value}'`)}registerHandler(u,s,n){for(const r of s)this.supportedRdfDatatypes.push(r),this.fromRdfHandlers[r.value]=u;for(const r of n){let a=this.toRdfHandlers[r];a||(this.toRdfHandlers[r]=a=[]),a.push(u)}}fromRdf(u,s){const n=this.fromRdfHandlers[u.datatype.value];return n?n.fromRdf(u,s):u.value}toRdf(u,s){const n=this.toRdfHandlers[typeof u];if(n)for(const r of n){const a=r.toRdf(u,s);if(a)return a}throw new Error(`Invalid JavaScript value: '${u}'`)}getSupportedRdfDatatypes(){return this.supportedRdfDatatypes}getSupportedJavaScriptPrimitives(){return Object.keys(this.toRdfHandlers)}};return Xc.Translator=t,Xc}var ZI;function KG(){if(ZI)return Jc;ZI=1,Object.defineProperty(Jc,"__esModule",{value:!0}),Jc.TypeHandlerBoolean=void 0;const t=Ho();let e=class kq{fromRdf(s,n){switch(s.value){case"true":return!0;case"false":return!1;case"1":return!0;case"0":return!1}return n&&t.Translator.incorrectRdfDataType(s),!1}toRdf(s,{datatype:n,dataFactory:r}){return r.literal(s?"true":"false",n||r.namedNode(kq.TYPE))}};return e.TYPE="http://www.w3.org/2001/XMLSchema#boolean",Jc.TypeHandlerBoolean=e,Jc}var Kc={},eP;function YG(){if(eP)return Kc;eP=1,Object.defineProperty(Kc,"__esModule",{value:!0}),Kc.TypeHandlerDate=void 0;const t=Ho();let e=class g3{fromRdf(s,n){switch(n&&!s.value.match(g3.VALIDATORS[s.datatype.value.substr(33,s.datatype.value.length)])&&t.Translator.incorrectRdfDataType(s),s.datatype.value){case"http://www.w3.org/2001/XMLSchema#gDay":return new Date(0,0,parseInt(s.value,10));case"http://www.w3.org/2001/XMLSchema#gMonthDay":const r=s.value.split("-");return new Date(0,parseInt(r[0],10)-1,parseInt(r[1],10));case"http://www.w3.org/2001/XMLSchema#gYear":return new Date(s.value+"-01-01");case"http://www.w3.org/2001/XMLSchema#gYearMonth":return new Date(s.value+"-01");default:return new Date(s.value)}}toRdf(s,{datatype:n,dataFactory:r}){if(n=n||r.namedNode(g3.TYPES[0]),!(s instanceof Date))return null;const a=s;let o;switch(n.value){case"http://www.w3.org/2001/XMLSchema#gDay":o=String(a.getUTCDate());break;case"http://www.w3.org/2001/XMLSchema#gMonthDay":o=a.getUTCMonth()+1+"-"+a.getUTCDate();break;case"http://www.w3.org/2001/XMLSchema#gYear":o=String(a.getUTCFullYear());break;case"http://www.w3.org/2001/XMLSchema#gYearMonth":o=a.getUTCFullYear()+"-"+(a.getUTCMonth()+1);break;case"http://www.w3.org/2001/XMLSchema#date":o=a.toISOString().replace(/T.*$/,"");break;default:o=a.toISOString()}return r.literal(o,n)}};return e.TYPES=["http://www.w3.org/2001/XMLSchema#dateTime","http://www.w3.org/2001/XMLSchema#date","http://www.w3.org/2001/XMLSchema#gDay","http://www.w3.org/2001/XMLSchema#gMonthDay","http://www.w3.org/2001/XMLSchema#gYear","http://www.w3.org/2001/XMLSchema#gYearMonth"],e.VALIDATORS={date:/^[0-9]+-[0-9][0-9]-[0-9][0-9]Z?$/,dateTime:/^[0-9]+-[0-9][0-9]-[0-9][0-9]T[0-9][0-9]:[0-9][0-9]:[0-9][0-9](\.[0-9][0-9][0-9])?((Z?)|([\+-][0-9][0-9]:[0-9][0-9]))$/,gDay:/^[0-9]+$/,gMonthDay:/^[0-9]+-[0-9][0-9]$/,gYear:/^[0-9]+$/,gYearMonth:/^[0-9]+-[0-9][0-9]$/},Kc.TypeHandlerDate=e,Kc}var Yc={},tP;function ZG(){if(tP)return Yc;tP=1,Object.defineProperty(Yc,"__esModule",{value:!0}),Yc.TypeHandlerNumberDouble=void 0;const t=Ho();let e=class zq{fromRdf(s,n){const r=parseFloat(s.value);return n&&isNaN(r)&&t.Translator.incorrectRdfDataType(s),r}toRdf(s,{datatype:n,dataFactory:r}){return n=n||r.namedNode(zq.TYPES[0]),isNaN(s)?r.literal("NaN",n):isFinite(s)?s%1===0?null:r.literal(s.toExponential(15).replace(/(\d)0*e\+?/,"$1E"),n):r.literal(s>0?"INF":"-INF",n)}};return e.TYPES=["http://www.w3.org/2001/XMLSchema#double","http://www.w3.org/2001/XMLSchema#decimal","http://www.w3.org/2001/XMLSchema#float"],Yc.TypeHandlerNumberDouble=e,Yc}var Zc={},rP;function eW(){if(rP)return Zc;rP=1,Object.defineProperty(Zc,"__esModule",{value:!0}),Zc.TypeHandlerNumberInteger=void 0;const t=Ho();let e=class I0{fromRdf(s,n){const r=parseInt(s.value,10);return n&&(isNaN(r)||s.value.indexOf(".")>=0)&&t.Translator.incorrectRdfDataType(s),r}toRdf(s,{datatype:n,dataFactory:r}){return r.literal(String(s),n||(s<=I0.MAX_INT&&s>=I0.MIN_INT?r.namedNode(I0.TYPES[0]):r.namedNode(I0.TYPES[1])))}};return e.TYPES=["http://www.w3.org/2001/XMLSchema#integer","http://www.w3.org/2001/XMLSchema#long","http://www.w3.org/2001/XMLSchema#int","http://www.w3.org/2001/XMLSchema#byte","http://www.w3.org/2001/XMLSchema#short","http://www.w3.org/2001/XMLSchema#negativeInteger","http://www.w3.org/2001/XMLSchema#nonNegativeInteger","http://www.w3.org/2001/XMLSchema#nonPositiveInteger","http://www.w3.org/2001/XMLSchema#positiveInteger","http://www.w3.org/2001/XMLSchema#unsignedByte","http://www.w3.org/2001/XMLSchema#unsignedInt","http://www.w3.org/2001/XMLSchema#unsignedLong","http://www.w3.org/2001/XMLSchema#unsignedShort"],e.MAX_INT=2147483647,e.MIN_INT=-2147483648,Zc.TypeHandlerNumberInteger=e,Zc}var el={},nP;function tW(){if(nP)return el;nP=1,Object.defineProperty(el,"__esModule",{value:!0}),el.TypeHandlerString=void 0;let t=class{fromRdf(u){return u.value}toRdf(u,{datatype:s,dataFactory:n}){return n.literal(u,s)}};return t.TYPES=["http://www.w3.org/2001/XMLSchema#string","http://www.w3.org/2001/XMLSchema#normalizedString","http://www.w3.org/2001/XMLSchema#anyURI","http://www.w3.org/2001/XMLSchema#base64Binary","http://www.w3.org/2001/XMLSchema#language","http://www.w3.org/2001/XMLSchema#Name","http://www.w3.org/2001/XMLSchema#NCName","http://www.w3.org/2001/XMLSchema#NMTOKEN","http://www.w3.org/2001/XMLSchema#token","http://www.w3.org/2001/XMLSchema#hexBinary","http://www.w3.org/1999/02/22-rdf-syntax-ns#langString","http://www.w3.org/2001/XMLSchema#time","http://www.w3.org/2001/XMLSchema#duration"],el.TypeHandlerString=t,el}var iP;function aP(){return iP||(iP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(KG(),t),u(YG(),t),u(ZG(),t),u(eW(),t),u(tW(),t)}(J_)),J_}var X_={},sP;function rW(){return sP||(sP=1,Object.defineProperty(X_,"__esModule",{value:!0})),X_}var oP;function nW(){return oP||(oP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(p,y,b,g){g===void 0&&(g=b);var m=Object.getOwnPropertyDescriptor(y,b);(!m||("get"in m?!y.__esModule:m.writable||m.configurable))&&(m={enumerable:!0,get:function(){return y[b]}}),Object.defineProperty(p,g,m)}:function(p,y,b,g){g===void 0&&(g=b),p[g]=y[b]}),u=I&&I.__exportStar||function(p,y){for(var b in p)b!=="default"&&!Object.prototype.hasOwnProperty.call(y,b)&&e(y,p,b)};Object.defineProperty(t,"__esModule",{value:!0}),t.getSupportedJavaScriptPrimitives=t.getSupportedRdfDatatypes=t.getTermRaw=t.toRdf=t.fromRdf=void 0;const s=Et(),n=aP(),r=Ho();u(aP(),t),u(rW(),t),u(Ho(),t);const a=new s.DataFactory,o=new r.Translator;o.registerHandler(new n.TypeHandlerString,n.TypeHandlerString.TYPES.map(p=>a.namedNode(p)),["string"]),o.registerHandler(new n.TypeHandlerBoolean,[n.TypeHandlerBoolean.TYPE].map(p=>a.namedNode(p)),["boolean"]),o.registerHandler(new n.TypeHandlerNumberDouble,n.TypeHandlerNumberDouble.TYPES.map(p=>a.namedNode(p)),["number"]),o.registerHandler(new n.TypeHandlerNumberInteger,n.TypeHandlerNumberInteger.TYPES.map(p=>a.namedNode(p)),["number"]),o.registerHandler(new n.TypeHandlerDate,n.TypeHandlerDate.TYPES.map(p=>a.namedNode(p)),["object"]);function l(p,y){return o.fromRdf(p,y)}t.fromRdf=l;function c(p,y){return y&&"namedNode"in y&&(y={dataFactory:y}),y=y||{},y&&!y.dataFactory&&(y.dataFactory=a),o.toRdf(p,y)}t.toRdf=c;function d(p,y){return p.termType==="Literal"?l(p,y):p.value}t.getTermRaw=d;function h(){return o.getSupportedRdfDatatypes()}t.getSupportedRdfDatatypes=h;function f(){return o.getSupportedJavaScriptPrimitives()}t.getSupportedJavaScriptPrimitives=f}(W_)),W_}var K_={},tl={},Y_,uP;function Gq(){if(uP)return Y_;uP=1;var{Buffer:t}=Wi(),e={},u=e.LEFT_BRACE=1,s=e.RIGHT_BRACE=2,n=e.LEFT_BRACKET=3,r=e.RIGHT_BRACKET=4,a=e.COLON=5,o=e.COMMA=6,l=e.TRUE=7,c=e.FALSE=8,d=e.NULL=9,h=e.STRING=10,f=e.NUMBER=11,p=e.START=17,y=e.STOP=18,b=e.TRUE1=33,g=e.TRUE2=34,m=e.TRUE3=35,v=e.FALSE1=49,_=e.FALSE2=50,w=e.FALSE3=51,S=e.FALSE4=52,A=e.NULL1=65,D=e.NULL2=66,L=e.NULL3=67,O=e.NUMBER1=81,E=e.NUMBER3=83,P=e.STRING1=97,M=e.STRING2=98,U=e.STRING3=99,j=e.STRING4=100,q=e.STRING5=101,$=e.STRING6=102,Z=e.VALUE=113,X=e.KEY=114,le=e.OBJECT=129,K=e.ARRAY=130,he="\\".charCodeAt(0),Re="/".charCodeAt(0),ie="\b".charCodeAt(0),ae="\f".charCodeAt(0),Ee=` +`.charCodeAt(0),De="\r".charCodeAt(0),ge=" ".charCodeAt(0),de=64*1024;function fe(R){return t.alloc?t.alloc(R):new t(R)}function H(){this.tState=p,this.value=void 0,this.string=void 0,this.stringBuffer=fe(de),this.stringBufferOffset=0,this.unicode=void 0,this.highSurrogate=void 0,this.key=void 0,this.mode=void 0,this.stack=[],this.state=Z,this.bytes_remaining=0,this.bytes_in_sequence=0,this.temp_buffs={2:fe(2),3:fe(3),4:fe(4)},this.offset=-1}H.toknam=function(R){for(var T=Object.keys(e),x=0,B=T.length;x=de&&(this.string+=this.stringBuffer.toString("utf8"),this.stringBufferOffset=0),this.stringBuffer[this.stringBufferOffset++]=R},N.appendStringBuf=function(R,T,x){var B=R.length;typeof T=="number"&&(typeof x=="number"?x<0?B=R.length-T+x:B=x-T:B=R.length-T),B<0&&(B=0),this.stringBufferOffset+B>de&&(this.string+=this.stringBuffer.toString("utf8",0,this.stringBufferOffset),this.stringBufferOffset=0),R.copy(this.stringBuffer,this.stringBufferOffset,T,x),this.stringBufferOffset+=B},N.write=function(R){typeof R=="string"&&(R=new t(R));for(var T,x=0,B=R.length;x=48&&T<64)this.string=String.fromCharCode(T),this.tState=E;else if(!(T===32||T===9||T===10||T===13))return this.charError(R,x)}else if(this.tState===P)if(T=R[x],this.bytes_remaining>0){for(var k=0;k=128){if(T<=193||T>244)return this.onError(new Error("Invalid UTF-8 character at position "+x+" in state "+H.toknam(this.tState)));if(T>=194&&T<=223&&(this.bytes_in_sequence=2),T>=224&&T<=239&&(this.bytes_in_sequence=3),T>=240&&T<=244&&(this.bytes_in_sequence=4),this.bytes_in_sequence+x>R.length){for(var V=0;V<=R.length-1-x;V++)this.temp_buffs[this.bytes_in_sequence][V]=R[x+V];this.bytes_remaining=x+this.bytes_in_sequence-R.length,x=R.length-1}else this.appendStringBuf(R,x,x+this.bytes_in_sequence),x=x+this.bytes_in_sequence-1}else if(T===34)this.tState=p,this.string+=this.stringBuffer.toString("utf8",0,this.stringBufferOffset),this.stringBufferOffset=0,this.onToken(h,this.string),this.offset+=t.byteLength(this.string,"utf8")+1,this.string=void 0;else if(T===92)this.tState=M;else if(T>=32)this.appendStringChar(T);else return this.charError(R,x);else if(this.tState===M)if(T=R[x],T===34)this.appendStringChar(T),this.tState=P;else if(T===92)this.appendStringChar(he),this.tState=P;else if(T===47)this.appendStringChar(Re),this.tState=P;else if(T===98)this.appendStringChar(ie),this.tState=P;else if(T===102)this.appendStringChar(ae),this.tState=P;else if(T===110)this.appendStringChar(Ee),this.tState=P;else if(T===114)this.appendStringChar(De),this.tState=P;else if(T===116)this.appendStringChar(ge),this.tState=P;else if(T===117)this.unicode="",this.tState=U;else return this.charError(R,x);else if(this.tState===U||this.tState===j||this.tState===q||this.tState===$)if(T=R[x],T>=48&&T<64||T>64&&T<=70||T>96&&T<=102){if(this.unicode+=String.fromCharCode(T),this.tState++===$){var J=parseInt(this.unicode,16);this.unicode=void 0,this.highSurrogate!==void 0&&J>=56320&&J<57343+1?(this.appendStringBuf(new t(String.fromCharCode(this.highSurrogate,J))),this.highSurrogate=void 0):this.highSurrogate===void 0&&J>=55296&&J<56319+1?this.highSurrogate=J:(this.highSurrogate!==void 0&&(this.appendStringBuf(new t(String.fromCharCode(this.highSurrogate))),this.highSurrogate=void 0),this.appendStringBuf(new t(String.fromCharCode(J)))),this.tState=P}}else return this.charError(R,x);else if(this.tState===O||this.tState===E)switch(T=R[x],T){case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:case 46:case 101:case 69:case 43:case 45:this.string+=String.fromCharCode(T),this.tState=E;break;default:this.tState=p;var z=this.numberReviver(this.string);if(z)return z;this.offset+=this.string.length-1,this.string=void 0,x--;break}else if(this.tState===b)if(R[x]===114)this.tState=g;else return this.charError(R,x);else if(this.tState===g)if(R[x]===117)this.tState=m;else return this.charError(R,x);else if(this.tState===m)if(R[x]===101)this.tState=p,this.onToken(l,!0),this.offset+=3;else return this.charError(R,x);else if(this.tState===v)if(R[x]===97)this.tState=_;else return this.charError(R,x);else if(this.tState===_)if(R[x]===108)this.tState=w;else return this.charError(R,x);else if(this.tState===w)if(R[x]===115)this.tState=S;else return this.charError(R,x);else if(this.tState===S)if(R[x]===101)this.tState=p,this.onToken(c,!1),this.offset+=4;else return this.charError(R,x);else if(this.tState===A)if(R[x]===117)this.tState=D;else return this.charError(R,x);else if(this.tState===D)if(R[x]===108)this.tState=L;else return this.charError(R,x);else if(this.tState===L)if(R[x]===108)this.tState=p,this.onToken(d,null),this.offset+=3;else return this.charError(R,x)},N.onToken=function(R,T){},N.parseError=function(R,T){this.tState=y,this.onError(new Error("Unexpected "+H.toknam(R)+(T?"("+JSON.stringify(T)+")":"")+" in state "+H.toknam(this.state)))},N.push=function(){this.stack.push({value:this.value,key:this.key,mode:this.mode})},N.pop=function(){var R=this.value,T=this.stack.pop();this.value=T.value,this.key=T.key,this.mode=T.mode,this.emit(R),this.mode||(this.state=Z)},N.emit=function(R){this.mode&&(this.state=o),this.onValue(R)},N.onValue=function(R){},N.onToken=function(R,T){if(this.state===Z)if(R===h||R===f||R===l||R===c||R===d)this.value&&(this.value[this.key]=T),this.emit(T);else if(R===u)this.push(),this.value?this.value=this.value[this.key]={}:this.value={},this.key=void 0,this.state=X,this.mode=le;else if(R===n)this.push(),this.value?this.value=this.value[this.key]=[]:this.value=[],this.key=0,this.mode=K,this.state=Z;else if(R===s)if(this.mode===le)this.pop();else return this.parseError(R,T);else if(R===r)if(this.mode===K)this.pop();else return this.parseError(R,T);else return this.parseError(R,T);else if(this.state===X)if(R===h)this.key=T,this.state=a;else if(R===s)this.pop();else return this.parseError(R,T);else if(this.state===a)if(R===a)this.state=Z;else return this.parseError(R,T);else if(this.state===o)if(R===o)this.mode===K?(this.key++,this.state=Z):this.mode===le&&(this.state=X);else if(R===r&&this.mode===K||R===s&&this.mode===le)this.pop();else return this.parseError(R,T);else return this.parseError(R,T)},N.numberReviver=function(R){var T=Number(R);if(isNaN(T))return this.charError(buffer,i);R.match(/[0-9]+/)==R&&T.toString()!=R?this.onToken(h,R):this.onToken(f,T)},H.C=e,Y_=H,Y_}var cP;function iW(){if(cP)return tl;cP=1,Object.defineProperty(tl,"__esModule",{value:!0}),tl.SparqlJsonParser=void 0;const t=Et(),e=Wt(),u=Gq();let s=class{constructor(r){var a;r=r||{},this.dataFactory=r.dataFactory||new t.DataFactory,this.prefixVariableQuestionMark=!!r.prefixVariableQuestionMark,this.suppressMissingStreamResultsError=(a=r.suppressMissingStreamResultsError)!==null&&a!==void 0?a:!0}parseJsonResults(r){return r.results.bindings.map(a=>this.parseJsonBindings(a))}parseJsonResultsStream(r){const a=h=>d.emit("error",h);r.on("error",a);const o=new u;o.onError=a;let l=!1,c=!1;o.onValue=h=>{if(o.key==="vars"&&o.stack.length===2&&o.stack[1].key==="head")d.emit("variables",h.map(f=>this.dataFactory.variable(f))),l=!0;else if(o.key==="results"&&o.stack.length===1)c=!0;else if(typeof o.key=="number"&&o.stack.length===3&&o.stack[1].key==="results"&&o.stack[2].key==="bindings")try{d.push(this.parseJsonBindings(h))}catch(f){d.emit("error",f)}else o.key==="metadata"&&o.stack.length===1&&d.emit("metadata",h)};const d=r.on("end",h=>{!c&&!this.suppressMissingStreamResultsError?d.emit("error",new Error("No valid SPARQL query results were found.")):l||d.emit("variables",[])}).pipe(new e.Transform({objectMode:!0,transform(h,f,p){o.write(h),p()}}));return d}parseJsonBindings(r){const a={};for(const o in r){const l=r[o];a[this.prefixVariableQuestionMark?"?"+o:o]=this.parseJsonValue(l)}return a}parseJsonValue(r){let a;switch(r.type){case"bnode":a=this.dataFactory.blankNode(r.value);break;case"literal":r["xml:lang"]?a=this.dataFactory.literal(r.value,r["xml:lang"]):r.datatype?a=this.dataFactory.literal(r.value,this.dataFactory.namedNode(r.datatype)):a=this.dataFactory.literal(r.value);break;case"typed-literal":a=this.dataFactory.literal(r.value,this.dataFactory.namedNode(r.datatype));break;case"triple":const o=r.value;if(!o||!o.subject||!o.predicate||!o.object)throw new Error("Invalid quoted triple: "+JSON.stringify(r));a=this.dataFactory.quad(this.parseJsonValue(o.subject),this.parseJsonValue(o.predicate),this.parseJsonValue(o.object));break;default:a=this.dataFactory.namedNode(r.value);break}return a}parseJsonBoolean(r){if("boolean"in r)return r.boolean;throw new Error("No valid ASK response was found.")}parseJsonBooleanStream(r){return new Promise((a,o)=>{const l=new u;l.onError=o,l.onValue=c=>{l.key==="boolean"&&typeof c=="boolean"&&l.stack.length===1&&a(c)},r.on("error",o).on("data",c=>l.write(c)).on("end",()=>o(new Error("No valid ASK response was found.")))})}};return tl.SparqlJsonParser=s,tl}var lP;function Wq(){return lP||(lP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(iW(),t)}(K_)),K_}var dP;function aW(){if(dP)return Wc;dP=1,Object.defineProperty(Wc,"__esModule",{value:!0}),Wc.Converter=void 0;const t=nW(),e=Wq();let u=class fa{constructor(n){n=n||{delimiter:"_"},n.prefixVariableQuestionMark=!1,this.delimiter=n.delimiter||"_",this.parser=new e.SparqlJsonParser(n),this.materializeRdfJsTerms=n.materializeRdfJsTerms}static addValueToTree(n,r,a,o,l,c){const d=r[0],h=o?o+c+d:d,f=l.singularizeVariables[h];if(r.length===1)f?n[d]||(n[d]=a):(n[d]||(n[d]=[]),n[d].push(a));else{let p;f?(n[d]||(n[d]={}),p=n[d]):(n[d]||(n[d]=[{}]),p=n[d][0]),fa.addValueToTree(p,r.slice(1),a,h,l,c)}}static mergeTrees(n,r){if(typeof n!=typeof r)throw new Error(`Two incompatible tree nodes were found: ${typeof n} and ${typeof r}`);if(Array.isArray(n)!==Array.isArray(r))throw new Error(`Two incompatible tree nodes were found: Array?${Array.isArray(n)} and Array?${Array.isArray(r)}`);if(typeof n=="object"&&typeof r=="object"){if(n.termType&&r.termType)return n.equals(r)?{valid:!0,result:n}:{valid:!1,result:n};if(Array.isArray(n)&&Array.isArray(r)){if(n.length>0){const a=[];let o=!1;for(const l of n){const c=fa.mergeTrees(l,r[0]);c.valid?(o=!0,a.push(c.result)):a.push(l)}if(o)return{valid:!0,result:a}}return{valid:!0,result:n.concat(r)}}else{const a={};for(const o in r)a[o]=r[o];for(const o in n)if(a[o]){const l=fa.mergeTrees(n[o],a[o]);if(l.valid)a[o]=l.result;else return{valid:!1,result:n}}else a[o]=n[o];return{valid:!0,result:a}}}else throw new Error(`Unmergable tree types: ${typeof n} and ${typeof r}`)}static materializeTree(n){if(n.termType)return(0,t.getTermRaw)(n);if(Array.isArray(n))return n.map(fa.materializeTree);{const r={};for(const a in n)r[a]=fa.materializeTree(n[a]);return r}}sparqlJsonResultsToTree(n,r){return this.bindingsToTree(this.parser.parseJsonResults(n),r||{singularizeVariables:{}})}bindingsToTree(n,r){const a=r&&r.singularizeVariables[""];let o=a?{}:[];for(const l of n){const c=a?{}:[{}];for(const d in l){const h=d.split(this.delimiter),f=l[d];fa.addValueToTree(a?c:c[0],h,f,"",r,this.delimiter)}o=fa.mergeTrees(o,c).result}return this.materializeRdfJsTerms&&(o=fa.materializeTree(o)),o}};return Wc.Converter=u,Wc}var fP;function sW(){return fP||(fP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(aW(),t)}(G_)),G_}var hP;function pP(){if(hP)return Gc;hP=1,Object.defineProperty(Gc,"__esModule",{value:!0}),Gc.ActorQueryResultSerializeTree=void 0;const t=Gi(),e=Lt,u=ot,s=Wt(),n=sW();let r=class Jq extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(o){super(o)}static async bindingsStreamToGraphQl(o,l,c){const d=u.ActionContext.ensureActionContext(l),h=new n.Converter(c),f={singularizeVariables:d.get(e.KeysInitQuery.graphqlSingularizeVariables)??{}};return h.bindingsToTree(await o.map(p=>Object.fromEntries([...p].map(([y,b])=>[y.value,b]))).toArray(),f)}async testHandleChecked(o){if(o.type!=="bindings")throw new Error("This actor can only handle bindings streams.");return!0}async runHandle(o,l){const c=new s.Readable;return c._read=()=>{c._read=()=>{},Jq.bindingsStreamToGraphQl(o.bindingsStream,o.context,{materializeRdfJsTerms:!0}).then(d=>{c.push(JSON.stringify(d,null," ")),c.push(null)}).catch(d=>c.emit("error",d))},{data:c}}};return Gc.ActorQueryResultSerializeTree=r,Gc}var yP;function oW(){return yP||(yP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(r,a,o,l){l===void 0&&(l=o);var c=Object.getOwnPropertyDescriptor(a,o);(!c||("get"in c?!a.__esModule:c.writable||c.configurable))&&(c={enumerable:!0,get:function(){return a[o]}}),Object.defineProperty(r,l,c)}:function(r,a,o,l){l===void 0&&(l=o),r[l]=a[o]}),u=I&&I.__exportStar||function(r,a){for(var o in r)o!=="default"&&!Object.prototype.hasOwnProperty.call(a,o)&&e(a,r,o)};Object.defineProperty(t,"__esModule",{value:!0}),t.bindingsStreamToGraphQl=void 0;const s=pP(),{bindingsStreamToGraphQl:n}=s.ActorQueryResultSerializeTree;t.bindingsStreamToGraphQl=n,u(pP(),t)}(z_)),z_}var Z_={},rl={},bP;function uW(){if(bP)return rl;bP=1,Object.defineProperty(rl,"__esModule",{value:!0}),rl.MediatorCombineUnion=void 0;const t=ot;let e=class extends t.Mediator{constructor(s){super(s),this.combiner=this.createCombiner()}async mediate(s){let n;try{n=this.publish(s)}catch{n=[]}if(this.filterErrors){const a=[];for(const o of n)try{await o.reply,a.push(o)}catch{}n=a}await Promise.all(n.map(({reply:a})=>a));const r=await Promise.all(n.map(a=>a.actor.runObservable(s)));return this.combiner(r)}mediateWith(){throw new Error("Method not supported.")}createCombiner(){return s=>{const n={};return n[this.field]={},[{}].concat(s.map(r=>r[this.field])).forEach(r=>{n[this.field]={...r,...n[this.field]}}),n}}};return rl.MediatorCombineUnion=e,rl}var mP;function xa(){return mP||(mP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(uW(),t)}(Z_)),Z_}var ev={},nl={},gP;function cW(){if(gP)return nl;gP=1,Object.defineProperty(nl,"__esModule",{value:!0}),nl.MediatorNumber=void 0;const t=ot;let e=class extends t.Mediator{constructor(s){super(s),this.indexPicker=this.createIndexPicker()}createIndexPicker(){switch(this.type){case"min":return s=>s.reduce((n,r,a)=>{const o=this.getOrDefault(r[this.field],Number.POSITIVE_INFINITY);return o!==null&&(Number.isNaN(n[0])||n[0]>o)?[o,a]:n},[Number.NaN,-1])[1];case"max":return s=>s.reduce((n,r,a)=>{const o=this.getOrDefault(r[this.field],Number.NEGATIVE_INFINITY);return o!==null&&(Number.isNaN(n[0])||n[0]c);const a=[];if(this.ignoreErrors){const c={};c[this.field]=null,r=r.map(d=>d.catch(h=>(a.push(h),c)))}const o=await Promise.all(r),l=this.indexPicker(o);if(l<0)throw new Error(`All actors rejected their test in ${this.name} +${a.map(c=>c.message).join(` +`)}`);return n[l].actor}};return nl.MediatorNumber=e,nl}var _P;function il(){return _P||(_P=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(cW(),t)}(ev)),ev}var tv={},al={},rv={},sl={},oa={},vP;function ZT(){if(vP)return oa;vP=1,Object.defineProperty(oa,"__esModule",{value:!0}),oa.ActorDereferenceBase=oa.isHardError=oa.emptyReadable=void 0;const t=Lt,e=ot,u=Wt();function s(){const a=new u.Readable;return a.push(null),a}oa.emptyReadable=s;function n(a){return!a.get(t.KeysInitQuery.lenient)}oa.isHardError=n;let r=class extends e.Actor{constructor(o){super(o)}async dereferenceErrorHandler(o,l,c){if(n(o.context))throw l;return this.logWarn(o.context,l.message),{...c,data:s()}}};return oa.ActorDereferenceBase=r,oa}var wP;function lW(){if(wP)return sl;wP=1,Object.defineProperty(sl,"__esModule",{value:!0}),sl.ActorDereference=void 0;const t=ZT();let e=class extends t.ActorDereferenceBase{constructor(s){super(s)}async handleDereferenceErrors(s,n,r,a=0){return this.dereferenceErrorHandler(s,n,{url:s.url,exists:!1,headers:r,requestTime:a})}};return sl.ActorDereference=e,sl}var ws={},SP;function dW(){if(SP)return ws;SP=1,Object.defineProperty(ws,"__esModule",{value:!0}),ws.ActorDereferenceParse=ws.getMediaTypeFromExtension=void 0;const t=Wt(),e=ZT();function u(n,r){const a=n.lastIndexOf(".");return a>=0&&(r==null?void 0:r[n.slice(a+1)])||""}ws.getMediaTypeFromExtension=u;let s=class extends e.ActorDereferenceBase{constructor(r){super(r)}async test(r){return!0}handleDereferenceStreamErrors(r,a){return(0,e.isHardError)(r.context)||(a.on("error",o=>{this.logWarn(r.context,o.message,()=>({url:r.url})),a.push(null)}),a=a.pipe(new t.PassThrough({objectMode:!0}))),a}async run(r){var c,d;const{context:a}=r,o=await this.mediatorDereference.mediate({...r,mediaTypes:async()=>{var h,f;return(f=await((h=this.mediatorParseMediatypes)==null?void 0:h.mediate({context:a,mediaTypes:!0})))==null?void 0:f.mediaTypes}});let l;try{l=(await this.mediatorParse.mediate({context:a,handle:{context:a,...o,metadata:await this.getMetadata(o)},handleMediaType:o.mediaType||u(o.url,this.mediaMappings)||r.mediaType})).handle,l.data=this.handleDereferenceStreamErrors(r,l.data)}catch(h){await((d=(c=o.data).close)==null?void 0:d.call(c)),l=await this.dereferenceErrorHandler(r,h,{})}return{...o,...l}}};return ws.ActorDereferenceParse=s,ws}var TP;function eA(){return TP||(TP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(lW(),t),u(dW(),t),u(ZT(),t)}(rv)),rv}var AP;function fW(){if(AP)return al;AP=1,Object.defineProperty(al,"__esModule",{value:!0}),al.ActorDereferenceFallback=void 0;const t=eA();let e=class extends t.ActorDereference{constructor(s){super(s)}async test(s){return!0}async run(s){return this.handleDereferenceErrors(s,new Error(`Could not dereference '${s.url}'`))}};return al.ActorDereferenceFallback=e,al}var EP;function hW(){return EP||(EP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(fW(),t)}(tv)),tv}var nv={},ol={},iv={},ul={},OP;function pW(){if(OP)return ul;OP=1,Object.defineProperty(ul,"__esModule",{value:!0}),ul.ActorRdfJoinEntriesSort=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return ul.ActorRdfJoinEntriesSort=e,ul}var RP;function yW(){return RP||(RP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(pW(),t)}(iv)),iv}var xP;function bW(){if(xP)return ol;xP=1,Object.defineProperty(ol,"__esModule",{value:!0}),ol.ActorRdfJoinEntriesSortCardinality=void 0;const t=yW();let e=class extends t.ActorRdfJoinEntriesSort{constructor(s){super(s)}async test(s){return!0}async run(s){return{entries:[...s.entries].sort((r,a)=>r.metadata.cardinality.value-a.metadata.cardinality.value)}}};return ol.ActorRdfJoinEntriesSortCardinality=e,ol}var IP;function mW(){return IP||(IP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(bW(),t)}(nv)),nv}var av={},Ss={},sv={},cl={},PP;function gW(){if(PP)return cl;PP=1,Object.defineProperty(cl,"__esModule",{value:!0}),cl.ActorRdfJoinSelectivity=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return cl.ActorRdfJoinSelectivity=e,cl}var DP;function _W(){return DP||(DP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(gW(),t)}(sv)),sv}var NP;function vW(){if(NP)return Ss;NP=1,Object.defineProperty(Ss,"__esModule",{value:!0}),Ss.JoinTypes=Ss.ActorRdfJoinSelectivityVariableCounting=void 0;const t=_W(),e=Ot();let u=class Ls extends t.ActorRdfJoinSelectivity{constructor(r){super(r)}async test(r){return{accuracy:.5}}static getPatternCost(r){let a=1;return r.subject.termType==="Variable"&&(a+=4),(r.predicate.termType==="Variable"||r.type===e.Algebra.types.PATH)&&(a+=1),r.object.termType==="Variable"&&(a+=2),r.graph.termType==="Variable"&&(a+=1),a/9}static getJoinTypes(r,a){const o=[];return r.subject.termType==="Variable"?(r.subject.equals(a.subject)&&o.push(s.unboundSS),a.type==="pattern"&&r.subject.equals(a.predicate)&&o.push(s.unboundSP),r.subject.equals(a.object)&&o.push(s.unboundSO),r.subject.equals(a.graph)&&o.push(s.unboundSG)):(r.subject.equals(a.subject)&&o.push(s.boundSS),a.type==="pattern"&&r.subject.equals(a.predicate)&&o.push(s.boundSP),r.subject.equals(a.object)&&o.push(s.boundSO),r.subject.equals(a.graph)&&o.push(s.boundSG)),r.type==="pattern"&&(r.predicate.termType==="Variable"?(r.predicate.equals(a.subject)&&o.push(s.unboundPS),a.type==="pattern"&&r.predicate.equals(a.predicate)&&o.push(s.unboundPP),r.predicate.equals(a.object)&&o.push(s.unboundPO),r.predicate.equals(a.graph)&&o.push(s.unboundPG)):(r.predicate.equals(a.subject)&&o.push(s.boundPS),a.type==="pattern"&&r.predicate.equals(a.predicate)&&o.push(s.boundPP),r.predicate.equals(a.object)&&o.push(s.boundPO),r.predicate.equals(a.graph)&&o.push(s.boundPG))),r.object.termType==="Variable"?(r.object.equals(a.subject)&&o.push(s.unboundOS),a.type==="pattern"&&r.object.equals(a.predicate)&&o.push(s.unboundOP),r.object.equals(a.object)&&o.push(s.unboundOO),r.object.equals(a.graph)&&o.push(s.unboundOG)):(r.object.equals(a.subject)&&o.push(s.boundOS),a.type==="pattern"&&r.object.equals(a.predicate)&&o.push(s.boundOP),r.object.equals(a.object)&&o.push(s.boundOO),r.object.equals(a.graph)&&o.push(s.boundOG)),r.graph.termType==="Variable"?(r.graph.equals(a.subject)&&o.push(s.unboundGS),a.type==="pattern"&&r.graph.equals(a.predicate)&&o.push(s.unboundGP),r.graph.equals(a.object)&&o.push(s.unboundGO),r.graph.equals(a.graph)&&o.push(s.unboundGG)):(r.graph.equals(a.subject)&&o.push(s.boundGS),a.type==="pattern"&&r.graph.equals(a.predicate)&&o.push(s.boundGP),r.graph.equals(a.object)&&o.push(s.boundGO),r.graph.equals(a.graph)&&o.push(s.boundGG)),o}static getOperationsPairwiseJoinCost(r,a){let o=Ls.MAX_PAIRWISE_COST;for(const l of Ls.getJoinTypes(r,a))switch(l){case s.boundSS:o-=2*2;break;case s.boundSP:o-=3*2;break;case s.boundSO:o-=1*2;break;case s.boundSG:o-=3*2;break;case s.boundPS:o-=3*2;break;case s.boundPP:return 1;case s.boundPO:o-=3*2;break;case s.boundPG:o-=3*2;break;case s.boundOS:o-=1*2;break;case s.boundOP:o-=3*2;break;case s.boundOO:o-=1*2;break;case s.boundOG:o-=3*2;break;case s.boundGS:o-=3*2;break;case s.boundGP:o-=3*2;break;case s.boundGO:o-=3*2;break;case s.boundGG:o-=3*2;break;case s.unboundSS:o-=2;break;case s.unboundSP:o-=3;break;case s.unboundSO:o-=1;break;case s.unboundSG:o-=3;break;case s.unboundPS:o-=3;break;case s.unboundPP:o-=3;break;case s.unboundPO:o-=3;break;case s.unboundPG:o-=3;break;case s.unboundOS:o-=1;break;case s.unboundOP:o-=3;break;case s.unboundOO:o-=1;break;case s.unboundOG:o-=3;break;case s.unboundGS:o-=3;break;case s.unboundGP:o-=3;break;case s.unboundGO:o-=3;break;case s.unboundGG:o-=3;break}return o/Ls.MAX_PAIRWISE_COST}static getOperationsJoinCost(r){const a=[];for(const c of r)e.Util.recurseOperation(c,{[e.Algebra.types.PATTERN](d){return a.push(d),!1},[e.Algebra.types.PATH](d){return a.push(d),!1}});let o=0,l=0;for(const c of a)for(const d of a)c!==d&&(o+=Ls.getOperationsPairwiseJoinCost(c,d),l++);return l===0?1:o/l*a.reduce((c,d)=>c*Ls.getPatternCost(d),1)}async run(r){return r.entries.length<=1?{selectivity:1}:{selectivity:Ls.getOperationsJoinCost(r.entries.map(a=>a.operation))}}};Ss.ActorRdfJoinSelectivityVariableCounting=u,u.MAX_PAIRWISE_COST=41*2;var s;return function(n){n[n.boundSS=0]="boundSS",n[n.boundSP=1]="boundSP",n[n.boundSO=2]="boundSO",n[n.boundSG=3]="boundSG",n[n.boundPS=4]="boundPS",n[n.boundPP=5]="boundPP",n[n.boundPO=6]="boundPO",n[n.boundPG=7]="boundPG",n[n.boundOS=8]="boundOS",n[n.boundOP=9]="boundOP",n[n.boundOO=10]="boundOO",n[n.boundOG=11]="boundOG",n[n.boundGS=12]="boundGS",n[n.boundGP=13]="boundGP",n[n.boundGO=14]="boundGO",n[n.boundGG=15]="boundGG",n[n.unboundSS=16]="unboundSS",n[n.unboundSP=17]="unboundSP",n[n.unboundSO=18]="unboundSO",n[n.unboundSG=19]="unboundSG",n[n.unboundPS=20]="unboundPS",n[n.unboundPP=21]="unboundPP",n[n.unboundPO=22]="unboundPO",n[n.unboundPG=23]="unboundPG",n[n.unboundOS=24]="unboundOS",n[n.unboundOP=25]="unboundOP",n[n.unboundOO=26]="unboundOO",n[n.unboundOG=27]="unboundOG",n[n.unboundGS=28]="unboundGS",n[n.unboundGP=29]="unboundGP",n[n.unboundGO=30]="unboundGO",n[n.unboundGG=31]="unboundGG"}(s||(Ss.JoinTypes=s={})),Ss}var CP;function wW(){return CP||(CP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(vW(),t)}(av)),av}var ov={},ll={},uv={},dl={},jP;function SW(){if(jP)return dl;jP=1,Object.defineProperty(dl,"__esModule",{value:!0}),dl.ActorRdfMetadata=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return dl.ActorRdfMetadata=e,dl}var LP;function Xq(){return LP||(LP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(SW(),t)}(uv)),uv}var MP;function TW(){if(MP)return ll;MP=1,Object.defineProperty(ll,"__esModule",{value:!0}),ll.ActorRdfMetadataPrimaryTopic=void 0;const t=Xq(),e=Wt();let u=class extends t.ActorRdfMetadata{constructor(n){super(n)}async test(n){if(n.triples)throw new Error("This actor only supports non-triple quad streams.");return!0}async run(n){const r=new e.Readable({objectMode:!0}),a=new e.Readable({objectMode:!0}),o=()=>{r._read=a._read=()=>{},n.quads.on("error",h=>{r.emit("error",h),a.emit("error",h)});const l={};let c;const d={};n.quads.on("data",h=>{h.predicate.value==="http://rdfs.org/ns/void#subset"&&h.object.value===n.url?c=h.subject.value:h.predicate.value==="http://xmlns.com/foaf/0.1/primaryTopic"&&(d[h.object.value]=h.subject.value);let f=l[h.graph.value];f||(f=l[h.graph.value]=[]),f.push(h)}),n.quads.on("end",()=>{const h=c?d[c]:void 0;for(const f in l)if(f===h){for(const p of l[f])a.push(p);if(this.metadataToData)for(const p of l[f])r.push(p)}else{for(const p of l[f])r.push(p);if(!h&&this.dataToMetadataOnInvalidMetadataGraph)for(const p of l[f])a.push(p)}r.push(null),a.push(null)})};return r._read=a._read=()=>{o()},{data:r,metadata:a}}};return ll.ActorRdfMetadataPrimaryTopic=u,ll}var FP;function AW(){return FP||(FP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(TW(),t)}(ov)),ov}var cv={},fl={},qP;function EW(){if(qP)return fl;qP=1,Object.defineProperty(fl,"__esModule",{value:!0}),fl.ActorRdfMetadataAll=void 0;const t=Xq(),e=Wt();let u=class extends t.ActorRdfMetadata{constructor(n){super(n)}async test(n){return!0}async run(n){const r=new e.Readable({objectMode:!0}),a=new e.Readable({objectMode:!0});n.quads.on("error",l=>{r.emit("error",l),a.emit("error",l)}),n.quads.on("end",()=>{r.push(null),a.push(null)});const o=r._read=a._read=l=>{for(;l>0;){const c=n.quads.read();if(c===null)return n.quads.once("readable",()=>o(l));l--,r.push(c),a.push(c)}};return{data:r,metadata:a}}};return fl.ActorRdfMetadataAll=u,fl}var BP;function OW(){return BP||(BP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(EW(),t)}(cv)),cv}var lv={},hl={},dv={},pl={},UP;function RW(){if(UP)return pl;UP=1,Object.defineProperty(pl,"__esModule",{value:!0}),pl.ActorRdfMetadataAccumulate=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return pl.ActorRdfMetadataAccumulate=e,pl}var QP;function Yb(){return QP||(QP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(RW(),t)}(dv)),dv}var HP;function xW(){if(HP)return hl;HP=1,Object.defineProperty(hl,"__esModule",{value:!0}),hl.ActorRdfMetadataAccumulateCanContainUndefs=void 0;const t=Yb();let e=class extends t.ActorRdfMetadataAccumulate{constructor(s){super(s)}async test(s){return!0}async run(s){if(s.mode==="initialize")return{metadata:{canContainUndefs:!1}};let n=s.accumulatedMetadata.canContainUndefs;return s.appendingMetadata.canContainUndefs&&(n=!0),{metadata:{canContainUndefs:n}}}};return hl.ActorRdfMetadataAccumulateCanContainUndefs=e,hl}var $P;function IW(){return $P||($P=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(xW(),t)}(lv)),lv}var fv={},yl={},VP;function PW(){if(VP)return yl;VP=1,Object.defineProperty(yl,"__esModule",{value:!0}),yl.ActorRdfMetadataAccumulateCardinality=void 0;const t=Yb();let e=class extends t.ActorRdfMetadataAccumulate{constructor(s){super(s)}async test(s){return!0}async run(s){if(s.mode==="initialize")return{metadata:{cardinality:{type:"exact",value:0}}};const n={...s.accumulatedMetadata.cardinality};if(n.dataset)if(s.appendingMetadata.cardinality.dataset){if(n.dataset!==s.appendingMetadata.cardinality.dataset&&s.appendingMetadata.subsetOf===n.dataset)return{metadata:{cardinality:s.appendingMetadata.cardinality}};if(n.dataset===s.appendingMetadata.cardinality.dataset)return{metadata:{cardinality:n}};delete n.dataset}else return{metadata:{cardinality:n}};return!s.appendingMetadata.cardinality||!Number.isFinite(s.appendingMetadata.cardinality.value)?(n.type="estimate",n.value=Number.POSITIVE_INFINITY):(s.appendingMetadata.cardinality.type==="estimate"&&(n.type="estimate"),n.value+=s.appendingMetadata.cardinality.value),{metadata:{cardinality:n}}}};return yl.ActorRdfMetadataAccumulateCardinality=e,yl}var kP;function DW(){return kP||(kP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(PW(),t)}(fv)),fv}var hv={},bl={},zP;function NW(){if(zP)return bl;zP=1,Object.defineProperty(bl,"__esModule",{value:!0}),bl.ActorRdfMetadataAccumulatePageSize=void 0;const t=Yb();let e=class extends t.ActorRdfMetadataAccumulate{constructor(s){super(s)}async test(s){return!0}async run(s){return s.mode==="initialize"?{metadata:{}}:{metadata:{..."pageSize"in s.accumulatedMetadata||"pageSize"in s.appendingMetadata?{pageSize:(s.accumulatedMetadata.pageSize??0)+(s.appendingMetadata.pageSize??0)}:{}}}}};return bl.ActorRdfMetadataAccumulatePageSize=e,bl}var GP;function CW(){return GP||(GP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(NW(),t)}(hv)),hv}var pv={},ml={},WP;function jW(){if(WP)return ml;WP=1,Object.defineProperty(ml,"__esModule",{value:!0}),ml.ActorRdfMetadataAccumulateRequestTime=void 0;const t=Yb();let e=class extends t.ActorRdfMetadataAccumulate{constructor(s){super(s)}async test(s){return!0}async run(s){return s.mode==="initialize"?{metadata:{}}:{metadata:{..."requestTime"in s.accumulatedMetadata||"requestTime"in s.appendingMetadata?{requestTime:(s.accumulatedMetadata.requestTime??0)+(s.appendingMetadata.requestTime??0)}:{}}}}};return ml.ActorRdfMetadataAccumulateRequestTime=e,ml}var JP;function LW(){return JP||(JP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(jW(),t)}(pv)),pv}var yv={},gl={},bv={},_l={},XP;function MW(){if(XP)return _l;XP=1,Object.defineProperty(_l,"__esModule",{value:!0}),_l.ActorRdfMetadataExtract=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return _l.ActorRdfMetadataExtract=e,_l}var KP;function ns(){return KP||(KP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(MW(),t)}(bv)),bv}var mv={exports:{}},YP;function FW(){return YP||(YP=1,function(t){(function(e){var u=function(){function y(b){this.options=b}return y.prototype.toString=function(){return JSON&&JSON.stringify?JSON.stringify(this.options):this.options},y}(),s=function(){function y(D){return Object.prototype.toString.apply(D)==="[object Array]"}function b(D){return Object.prototype.toString.apply(D)==="[object String]"}function g(D){return Object.prototype.toString.apply(D)==="[object Number]"}function m(D){return Object.prototype.toString.apply(D)==="[object Boolean]"}function v(D,L){var O="",E=!0,P;for(P=0;P="a"&&m<="z"||m>="A"&&m<="Z"}function b(m){return m>="0"&&m<="9"}function g(m){return b(m)||m>="a"&&m<="f"||m>="A"&&m<="F"}return{isAlpha:y,isDigit:b,isHexDigit:g}}(),r=function(){var y={encode:function(w){return unescape(encodeURIComponent(w))},numBytes:function(w){return w<=127?1:194<=w&&w<=223?2:224<=w&&w<=239?3:240<=w&&w<=244?4:0},isValidFollowingCharCode:function(w){return 128<=w&&w<=191}};function b(w){var S="",A=y.encode(w),D,L;for(L=0;L1||a.isReserved(w)||a.isUnreserved(w)?w:r.encodeCharacter(w)}function m(v){var _="",w,S="";for(w=0;w1?_+=S:_+=a.isReserved(S)||a.isUnreserved(S)?S:r.encodeCharacter(S);return _}return{encode:y,encodePassReserved:b,encodeLiteral:m,encodeLiteralCharacter:g}}(),l=function(){var y={};function b(g){y[g]={symbol:g,separator:g==="?"?"&":g===""||g==="+"||g==="#"?",":g,named:g===";"||g==="&"||g==="?",ifEmpty:g==="&"||g==="?"?"=":"",first:g==="+"?"":g,encode:g==="+"||g==="#"?o.encodePassReserved:o.encode,toString:function(){return this.symbol}}}return b(""),b("+"),b("#"),b("."),b("/"),b(";"),b("?"),b("&"),{valueOf:function(g){return y[g]?y[g]:"=,!@|".indexOf(g)>=0?null:y[""]}}}();function c(y){var b;if(y==null)return!1;if(s.isArray(y))return y.length>0;if(typeof y=="string"||typeof y=="number"||typeof y=="boolean")return!0;for(b in y)if(y.hasOwnProperty(b)&&c(y[b]))return!0;return!1}var d=function(){function y(b){this.literal=o.encodeLiteral(b)}return y.prototype.expand=function(){return this.literal},y.prototype.toString=y.prototype.expand,y}(),h=function(){function y(g){var m,v=[],_=null,w=null,S=null,A,D="";function L(){var E=g.substring(w,A);if(E.length===0)throw new u({expressionText:g,message:"a varname must be specified",position:A});_={varname:E,exploded:!1,maxLength:null},w=null}function O(){if(S===A)throw new u({expressionText:g,message:"after a ':' you have to specify the length",position:A});_.maxLength=parseInt(g.substring(S,A),10),S=null}for(m=function(E){var P=l.valueOf(E);if(P===null)throw new u({expressionText:g,message:"illegal use of reserved operator",position:A,operator:E});return P}(g.charAt(0)),A=m.symbol.length,w=A;A=4)throw new u({expressionText:g,message:"A :prefix must have max 4 digits",position:A});continue}O()}if(D===":"){if(_.maxLength!==null)throw new u({expressionText:g,message:"only one :maxLength is allowed per varspec",position:A});if(_.exploded)throw new u({expressionText:g,message:"an exploeded varspec MUST NOT be varspeced",position:A});S=A+1;continue}if(D==="*"){if(_===null)throw new u({expressionText:g,message:"exploded without varspec",position:A});if(_.exploded)throw new u({expressionText:g,message:"exploded twice",position:A});if(_.maxLength)throw new u({expressionText:g,message:"an explode (*) MUST NOT follow to a prefix",position:A});_.exploded=!0;continue}if(D===","){v.push(_),_=null,w=A+1;continue}throw new u({expressionText:g,message:"illegal character",character:D,position:A})}return w!==null&&L(),S!==null&&O(),v.push(_),new f(g,m,v)}function b(g){var m,v,_=[],w=null,S=0;for(m=0;m{const o=r[a]||r[`${a}Page`],l=o&&o[n];return[a,l&&l.length>0?[l[0]]:[]]}))}parseUriTemplateCached(n){const r=this.parsedUriTemplateCache[n];return r||(this.parsedUriTemplateCache[n]=(0,e.parse)(n))}getSearchForms(n){const r=n.search,a=[];if(r)for(const o in r)for(const l of r[o]){const c=(n.template||{})[l]||[];if(c.length!==1)throw new Error(`Expected 1 hydra:template for ${l}`);const d=c[0],h=this.parseUriTemplateCached(d),f=Object.fromEntries(((n.mapping||{})[l]||[]).map(y=>{const b=((n.variable||{})[y]||[])[0],g=((n.property||{})[y]||[])[0];if(!b)throw new Error(`Expected a hydra:variable for ${y}`);if(!g)throw new Error(`Expected a hydra:property for ${y}`);return[g,b]})),p=y=>h.expand(Object.fromEntries(Object.keys(y).map(b=>[f[b],y[b]])));a.push({dataset:o,template:d,mappings:f,getUri:p})}return{values:a}}getHydraProperties(n){return new Promise((r,a)=>{n.on("error",a);const o={};n.on("data",l=>{if(l.predicate.value.startsWith(z1.HYDRA)){const c=l.predicate.value.slice(z1.HYDRA.length),d=o[c]||(o[c]={});(d[l.subject.value]||(d[l.subject.value]=[])).push(l.object.value)}}),n.on("end",()=>r(o))})}async run(n){const r={},a=await this.getHydraProperties(n.metadata);return Object.assign(r,this.getLinks(n.url,a)),r.searchForms=this.getSearchForms(a),{metadata:r}}};return gl.ActorRdfMetadataExtractHydraControls=u,u.HYDRA="http://www.w3.org/ns/hydra/core#",u.LINK_TYPES=["first","next","previous","last"],gl}var eD;function BW(){return eD||(eD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(qW(),t)}(yv)),yv}var gv={},vl={},tD;function UW(){if(tD)return vl;tD=1,Object.defineProperty(vl,"__esModule",{value:!0}),vl.ActorRdfMetadataExtractHydraCount=void 0;const t=ns();let e=class extends t.ActorRdfMetadataExtract{constructor(s){super(s)}async test(s){return!0}run(s){return new Promise((n,r)=>{s.metadata.on("error",r),s.metadata.on("data",a=>{this.predicates.includes(a.predicate.value)&&n({metadata:{cardinality:{type:"estimate",value:Number.parseInt(a.object.value,10),dataset:a.subject.value}}})}),s.metadata.on("end",()=>{n({metadata:{cardinality:{type:"estimate",value:0}}})})})}};return vl.ActorRdfMetadataExtractHydraCount=e,vl}var rD;function QW(){return rD||(rD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(UW(),t)}(gv)),gv}var _v={},wl={},nD;function HW(){if(nD)return wl;nD=1,Object.defineProperty(wl,"__esModule",{value:!0}),wl.ActorRdfMetadataExtractHydraPagesize=void 0;const t=ns();let e=class extends t.ActorRdfMetadataExtract{constructor(s){super(s)}async test(s){return!0}async run(s){return new Promise((n,r)=>{s.metadata.on("error",r),s.metadata.on("data",a=>{this.predicates.includes(a.predicate.value)&&n({metadata:{pageSize:Number.parseInt(a.object.value,10)}})}),s.metadata.on("end",()=>{n({metadata:{}})})})}};return wl.ActorRdfMetadataExtractHydraPagesize=e,wl}var iD;function $W(){return iD||(iD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(HW(),t)}(_v)),_v}var vv={},Sl={},aD;function VW(){if(aD)return Sl;aD=1,Object.defineProperty(Sl,"__esModule",{value:!0}),Sl.ActorRdfMetadataExtractRequestTime=void 0;const t=ns();let e=class extends t.ActorRdfMetadataExtract{constructor(s){super(s)}async test(s){return!0}async run(s){return{metadata:{requestTime:s.requestTime}}}};return Sl.ActorRdfMetadataExtractRequestTime=e,Sl}var sD;function kW(){return sD||(sD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(VW(),t)}(vv)),vv}var wv={},Tl={},oD;function zW(){if(oD)return Tl;oD=1,Object.defineProperty(Tl,"__esModule",{value:!0}),Tl.ActorRdfMetadataExtractAllowHttpMethods=void 0;const t=ns();let e=class extends t.ActorRdfMetadataExtract{constructor(s){super(s)}async test(s){return!0}async run(s){var r,a;const n={};return(r=s.headers)!=null&&r.get("allow")&&(n.allowHttpMethods=(a=s.headers.get("allow"))==null?void 0:a.split(/, */u)),{metadata:n}}};return Tl.ActorRdfMetadataExtractAllowHttpMethods=e,Tl}var uD;function GW(){return uD||(uD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(zW(),t)}(wv)),wv}var Sv={},Al={},cD;function WW(){if(cD)return Al;cD=1,Object.defineProperty(Al,"__esModule",{value:!0}),Al.ActorRdfMetadataExtractPutAccepted=void 0;const t=ns();let e=class extends t.ActorRdfMetadataExtract{constructor(s){super(s)}async test(s){return!0}async run(s){var r,a;const n={};return(r=s.headers)!=null&&r.get("accept-put")&&(n.putAccepted=(a=s.headers.get("accept-put"))==null?void 0:a.split(/, */u)),{metadata:n}}};return Al.ActorRdfMetadataExtractPutAccepted=e,Al}var lD;function JW(){return lD||(lD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(WW(),t)}(Sv)),Sv}var Tv={},El={},dD;function XW(){if(dD)return El;dD=1,Object.defineProperty(El,"__esModule",{value:!0}),El.ActorRdfMetadataExtractPatchSparqlUpdate=void 0;const t=ns();let e=class extends t.ActorRdfMetadataExtract{constructor(s){super(s)}async test(s){return!0}async run(s){var r,a,o,l;const n={};return(((a=(r=s.headers)==null?void 0:r.get("accept-patch"))==null?void 0:a.includes("application/sparql-update"))??((l=(o=s.headers)==null?void 0:o.get("ms-author-via"))==null?void 0:l.includes("SPARQL")))&&(n.patchSparqlUpdate=!0),{metadata:n}}};return El.ActorRdfMetadataExtractPatchSparqlUpdate=e,El}var fD;function KW(){return fD||(fD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(XW(),t)}(Tv)),Tv}var Av={},Ol={},hD;function YW(){if(hD)return Ol;hD=1,Object.defineProperty(Ol,"__esModule",{value:!0}),Ol.ActorRdfMetadataExtractSparqlService=void 0;const t=ns(),e=Pi();let u=class extends t.ActorRdfMetadataExtract{constructor(n){super(n)}async test(n){return!0}async run(n){return new Promise((r,a)=>{n.metadata.on("error",a);const o={};n.metadata.on("data",l=>{l.predicate.value==="http://www.w3.org/ns/sparql-service-description#endpoint"&&(l.subject.termType==="BlankNode"||l.subject.value===n.url)?(o.sparqlService=l.object.termType==="Literal"?(0,e.resolve)(l.object.value,n.url):l.object.value,this.inferHttpsEndpoint&&n.url.startsWith("https")&&!o.sparqlService.startsWith("https")&&(o.sparqlService=o.sparqlService.replace("http:","https:"))):l.predicate.value==="http://www.w3.org/ns/sparql-service-description#defaultGraph"&&(o.defaultGraph=l.object.value)}),n.metadata.on("end",()=>{r({metadata:o})})})}};return Ol.ActorRdfMetadataExtractSparqlService=u,Ol}var pD;function ZW(){return pD||(pD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(YW(),t)}(Av)),Av}var Ev={},Rl={},Ov={},xl={},yD;function eJ(){if(yD)return xl;yD=1,Object.defineProperty(xl,"__esModule",{value:!0}),xl.ActorRdfParse=void 0;const t=iu();let e=class extends t.ActorAbstractMediaTyped{constructor(s){super(s)}};return xl.ActorRdfParse=e,xl}var Il={},bD;function tJ(){if(bD)return Il;bD=1,Object.defineProperty(Il,"__esModule",{value:!0}),Il.ActorRdfParseFixedMediaTypes=void 0;const t=iu();let e=class extends t.ActorAbstractMediaTypedFixed{constructor(s){super(s)}async testHandleChecked(s){return!0}};return Il.ActorRdfParseFixedMediaTypes=e,Il}var mD;function su(){return mD||(mD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(eJ(),t),u(tJ(),t)}(Ov)),Ov}var rJ=Wi();/*! queue-microtask. MIT License. Feross Aboukhadijeh */let gD;var nJ=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:I):t=>(gD||(gD=Promise.resolve())).then(t).catch(e=>setTimeout(()=>{throw e},0));const iJ=R$(nJ),Pl="http://www.w3.org/1999/02/22-rdf-syntax-ns#",Dl="http://www.w3.org/2001/XMLSchema#",Rv="http://www.w3.org/2000/10/swap/",ln={xsd:{decimal:`${Dl}decimal`,boolean:`${Dl}boolean`,double:`${Dl}double`,integer:`${Dl}integer`,string:`${Dl}string`},rdf:{type:`${Pl}type`,nil:`${Pl}nil`,first:`${Pl}first`,rest:`${Pl}rest`,langString:`${Pl}langString`},owl:{sameAs:"http://www.w3.org/2002/07/owl#sameAs"},r:{forSome:`${Rv}reify#forSome`,forAll:`${Rv}reify#forAll`},log:{implies:`${Rv}log#implies`}},{xsd:b1}=ln,aJ=/\\u([a-fA-F0-9]{4})|\\U([a-fA-F0-9]{8})|\\([^])/g,_D={"\\":"\\","'":"'",'"':'"',n:` +`,r:"\r",t:" ",f:"\f",b:"\b",_:"_","~":"~",".":".","-":"-","!":"!",$:"$","&":"&","(":"(",")":")","*":"*","+":"+",",":",",";":";","=":"=","/":"/","?":"?","#":"#","@":"@","%":"%"},sJ=/[\x00-\x20<>\\"\{\}\|\^\`]/,oJ={_iri:!0,_unescapedIri:!0,_simpleQuotedString:!0,_langcode:!0,_blank:!0,_newline:!0,_comment:!0,_whitespace:!0,_endOfFile:!0},uJ=/$0^/;class tA{constructor(e){if(this._iri=/^<((?:[^ <>{}\\]|\\[uU])+)>[ \t]*/,this._unescapedIri=/^<([^\x00-\x20<>\\"\{\}\|\^\`]*)>[ \t]*/,this._simpleQuotedString=/^"([^"\\\r\n]*)"(?=[^"])/,this._simpleApostropheString=/^'([^'\\\r\n]*)'(?=[^'])/,this._langcode=/^@([a-z]+(?:-[a-z0-9]+)*)(?=[^a-z0-9\-])/i,this._prefix=/^((?:[A-Za-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)?:(?=[#\s<])/,this._prefixed=/^((?:[A-Za-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)?:((?:(?:[0-:A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~])(?:(?:[\.\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~])*(?:[\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~]))?)?)(?:[ \t]+|(?=\.?[,;!\^\s#()\[\]\{\}"'<>]))/,this._variable=/^\?(?:(?:[A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:[\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)(?=[.,;!\^\s#()\[\]\{\}"'<>])/,this._blank=/^_:((?:[0-9A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)(?:[ \t]+|(?=\.?[,;:\s#()\[\]\{\}"'<>]))/,this._number=/^[\-+]?(?:(\d+\.\d*|\.?\d+)[eE][\-+]?|\d*(\.)?)\d+(?=\.?[,;:\s#()\[\]\{\}"'<>])/,this._boolean=/^(?:true|false)(?=[.,;\s#()\[\]\{\}"'<>])/,this._keyword=/^@[a-z]+(?=[\s#<:])/i,this._sparqlKeyword=/^(?:PREFIX|BASE|GRAPH)(?=[\s#<])/i,this._shortPredicates=/^a(?=[\s#()\[\]\{\}"'<>])/,this._newline=/^[ \t]*(?:#[^\n\r]*)?(?:\r\n|\n|\r)[ \t]*/,this._comment=/#([^\n\r]*)/,this._whitespace=/^[ \t]+/,this._endOfFile=/^(?:#[^\n\r]*)?$/,e=e||{},this._lineMode=!!e.lineMode){this._n3Mode=!1;for(const u in this)!(u in oJ)&&this[u]instanceof RegExp&&(this[u]=uJ)}else this._n3Mode=e.n3!==!1;this.comments=!!e.comments,this._literalClosingPos=0}_tokenizeToEnd(e,u){let s=this._input,n=s.length;for(;;){let o,l;for(;o=this._newline.exec(s);)this.comments&&(l=this._comment.exec(o[0]))&&r("comment",l[1],"",this._line,o[0].length),s=s.substr(o[0].length,s.length),n=s.length,this._line++;if(!o&&(o=this._whitespace.exec(s))&&(s=s.substr(o[0].length,s.length)),this._endOfFile.test(s))return u&&(this.comments&&(l=this._comment.exec(s))&&r("comment",l[1],"",this._line,s.length),s=null,r("eof","","",this._line,0)),this._input=s;const c=this._line,d=s[0];let h="",f="",p="",y=null,b=0,g=!1;switch(d){case"^":if(s.length<3)break;if(s[1]==="^"){if(this._previousMarker="^^",s=s.substr(2),s[0]!=="<"){g=!0;break}}else{this._n3Mode&&(b=1,h="^");break}case"<":if(y=this._unescapedIri.exec(s))h="IRI",f=y[1];else if(y=this._iri.exec(s)){if(f=this._unescape(y[1]),f===null||sJ.test(f))return a(this);h="IRI"}else s.length>1&&s[1]==="<"?(h="<<",b=2):this._n3Mode&&s.length>1&&s[1]==="="&&(h="inverse",b=2,f=">");break;case">":s.length>1&&s[1]===">"&&(h=">>",b=2);break;case"_":((y=this._blank.exec(s))||u&&(y=this._blank.exec(`${s} `)))&&(h="blank",p="_",f=y[1]);break;case'"':if(y=this._simpleQuotedString.exec(s))f=y[1];else if({value:f,matchLength:b}=this._parseLiteral(s),f===null)return a(this);(y!==null||b!==0)&&(h="literal",this._literalClosingPos=0);break;case"'":if(!this._lineMode){if(y=this._simpleApostropheString.exec(s))f=y[1];else if({value:f,matchLength:b}=this._parseLiteral(s),f===null)return a(this);(y!==null||b!==0)&&(h="literal",this._literalClosingPos=0)}break;case"?":this._n3Mode&&(y=this._variable.exec(s))&&(h="var",f=y[0]);break;case"@":this._previousMarker==="literal"&&(y=this._langcode.exec(s))?(h="langcode",f=y[1]):(y=this._keyword.exec(s))&&(h=y[0]);break;case".":if(s.length===1?u:s[1]<"0"||s[1]>"9"){h=".",b=1;break}case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":case"+":case"-":(y=this._number.exec(s)||u&&(y=this._number.exec(`${s} `)))&&(h="literal",f=y[0],p=typeof y[1]=="string"?b1.double:typeof y[2]=="string"?b1.decimal:b1.integer);break;case"B":case"b":case"p":case"P":case"G":case"g":(y=this._sparqlKeyword.exec(s))?h=y[0].toUpperCase():g=!0;break;case"f":case"t":(y=this._boolean.exec(s))?(h="literal",f=y[0],p=b1.boolean):g=!0;break;case"a":(y=this._shortPredicates.exec(s))?(h="abbreviation",f="a"):g=!0;break;case"=":this._n3Mode&&s.length>1&&(h="abbreviation",s[1]!==">"?(b=1,f="="):(b=2,f=">"));break;case"!":if(!this._n3Mode)break;case",":case";":case"[":case"]":case"(":case")":case"}":this._lineMode||(b=1,h=d);break;case"{":!this._lineMode&&s.length>=2&&(s[1]==="|"?(h="{|",b=2):(h=d,b=1));break;case"|":s.length>=2&&s[1]==="}"&&(h="|}",b=2);break;default:g=!0}if(g&&((this._previousMarker==="@prefix"||this._previousMarker==="PREFIX")&&(y=this._prefix.exec(s))?(h="prefix",f=y[1]||""):((y=this._prefixed.exec(s))||u&&(y=this._prefixed.exec(`${s} `)))&&(h="prefixed",p=y[1]||"",f=this._unescape(y[2]))),this._previousMarker==="^^")switch(h){case"prefixed":h="type";break;case"IRI":h="typeIRI";break;default:h=""}if(!h)return u||!/^'''|^"""/.test(s)&&/\n|\r/.test(s)?a(this):this._input=s;const m=b||y[0].length,v=r(h,f,p,c,m);this.previousToken=v,this._previousMarker=h,s=s.substr(m,s.length)}function r(o,l,c,d,h){const f=s?n-s.length:n,p=f+h,y={type:o,value:l,prefix:c,line:d,start:f,end:p};return e(null,y),y}function a(o){e(o._syntaxError(/^\S*/.exec(s)[0]))}}_unescape(e){let u=!1;const s=e.replace(aJ,(n,r,a,o)=>{if(typeof r=="string")return String.fromCharCode(Number.parseInt(r,16));if(typeof a=="string"){let l=Number.parseInt(a,16);return l<=65535?String.fromCharCode(Number.parseInt(a,16)):String.fromCharCode(55296+((l-=65536)>>10),56320+(l&1023))}return o in _D?_D[o]:(u=!0,"")});return u?null:s}_parseLiteral(e){if(e.length>=3){const u=e.match(/^(?:"""|"|'''|'|)/)[0],s=u.length;let n=Math.max(this._literalClosingPos,s);for(;(n=e.indexOf(u,n))>0;){let r=0;for(;e[n-r-1]==="\\";)r++;if(r%2===0){const a=e.substring(s,n),o=a.split(/\r\n|\r|\n/).length-1,l=n+s;if(s===1&&o!==0||s===3&&this._lineMode)break;return this._line+=o,{value:this._unescape(a),matchLength:l}}n++}this._literalClosingPos=e.length-s+1}return{value:"",matchLength:0}}_syntaxError(e){this._input=null;const u=new Error(`Unexpected "${e}" on line ${this._line}.`);return u.context={token:void 0,line:this._line,previousToken:this.previousToken},u}_readStartingBom(e){return e.startsWith("\uFEFF")?e.substr(1):e}tokenize(e,u){if(this._line=1,typeof e=="string")if(this._input=this._readStartingBom(e),typeof u=="function")iJ(()=>this._tokenizeToEnd(u,!0));else{const s=[];let n;if(this._tokenizeToEnd((r,a)=>r?n=r:s.push(a),!0),n)throw n;return s}else this._pendingBuffer=null,typeof e.setEncoding=="function"&&e.setEncoding("utf8"),e.on("data",s=>{this._input!==null&&s.length!==0&&(this._pendingBuffer&&(s=rJ.Buffer.concat([this._pendingBuffer,s]),this._pendingBuffer=null),s[s.length-1]&128?this._pendingBuffer=s:(typeof this._input>"u"?this._input=this._readStartingBom(typeof s=="string"?s:s.toString()):this._input+=s,this._tokenizeToEnd(u,!1)))}),e.on("end",()=>{typeof this._input=="string"&&this._tokenizeToEnd(u,!0)}),e.on("error",u)}}const{rdf:cJ,xsd:Hs}=ln;let Cy,lJ=0;const _3={namedNode:dJ,blankNode:fJ,variable:pJ,literal:hJ,defaultGraph:yJ,quad:vD,triple:vD},wa=_3;let Ji=class Kq{constructor(e){this.id=e}get value(){return this.id}equals(e){return e instanceof Kq?this.id===e.id:!!e&&this.termType===e.termType&&this.value===e.value}hashCode(){return 0}toJSON(){return{termType:this.termType,value:this.value}}};class Zb extends Ji{get termType(){return"NamedNode"}}class ka extends Ji{get termType(){return"Literal"}get value(){return this.id.substring(1,this.id.lastIndexOf('"'))}get language(){const e=this.id;let u=e.lastIndexOf('"')+1;return u0?"INF":"-INF")))),u===""||u===Hs.string?new ka(`"${t}"`):new ka(`"${t}"^^${u}`)}function pJ(t){return new nA(t)}function yJ(){return Cy}function vD(t,e,u,s){return new ny(t,e,u,s)}let wD=0;class em{constructor(e){this._contextStack=[],this._graph=null,e=e||{},this._setBase(e.baseIRI),e.factory&&Yq(this,e.factory);const u=typeof e.format=="string"?e.format.match(/\w*$/)[0].toLowerCase():"",s=/turtle/.test(u),n=/trig/.test(u),r=/triple/.test(u),a=/quad/.test(u),o=this._n3Mode=/n3/.test(u),l=r||a;(this._supportsNamedGraphs=!(s||o))||(this._readPredicateOrNamedGraph=this._readPredicate),this._supportsQuads=!(s||n||r||o),this._supportsRDFStar=u===""||/star|\*$/.test(u),l&&(this._resolveRelativeIRI=c=>null),this._blankNodePrefix=typeof e.blankNodePrefix!="string"?"":e.blankNodePrefix.replace(/^(?!_:)/,"_:"),this._lexer=e.lexer||new tA({lineMode:l,n3:o}),this._explicitQuantifiers=!!e.explicitQuantifiers}static _resetBlankNodePrefix(){wD=0}_setBase(e){if(!e)this._base="",this._basePath="";else{const u=e.indexOf("#");u>=0&&(e=e.substr(0,u)),this._base=e,this._basePath=e.indexOf("/")<0?e:e.replace(/[^\/?]*(?:\?.*)?$/,""),e=e.match(/^(?:([a-z][a-z0-9+.-]*:))?(?:\/\/[^\/]*)?/i),this._baseRoot=e[0],this._baseScheme=e[1]}}_saveContext(e,u,s,n,r){const a=this._n3Mode;this._contextStack.push({type:e,subject:s,predicate:n,object:r,graph:u,inverse:a?this._inversePredicate:!1,blankPrefix:a?this._prefixes._:"",quantified:a?this._quantified:null}),a&&(this._inversePredicate=!1,this._prefixes._=this._graph?`${this._graph.value}.`:".",this._quantified=Object.create(this._quantified))}_restoreContext(e,u){const s=this._contextStack.pop();if(!s||s.type!==e)return this._error(`Unexpected ${u.type}`,u);this._subject=s.subject,this._predicate=s.predicate,this._object=s.object,this._graph=s.graph,this._n3Mode&&(this._inversePredicate=s.inverse,this._prefixes._=s.blankPrefix,this._quantified=s.quantified)}_readInTopContext(e){switch(e.type){case"eof":return this._graph!==null?this._error("Unclosed graph",e):(delete this._prefixes._,this._callback(null,null,this._prefixes));case"PREFIX":this._sparqlStyle=!0;case"@prefix":return this._readPrefix;case"BASE":this._sparqlStyle=!0;case"@base":return this._readBaseIRI;case"{":if(this._supportsNamedGraphs)return this._graph="",this._subject=null,this._readSubject;case"GRAPH":if(this._supportsNamedGraphs)return this._readNamedGraphLabel;default:return this._readSubject(e)}}_readEntity(e,u){let s;switch(e.type){case"IRI":case"typeIRI":const n=this._resolveIRI(e.value);if(n===null)return this._error("Invalid IRI",e);s=this._namedNode(n);break;case"type":case"prefixed":const r=this._prefixes[e.prefix];if(r===void 0)return this._error(`Undefined prefix "${e.prefix}:"`,e);s=this._namedNode(r+e.value);break;case"blank":s=this._blankNode(this._prefixes[e.prefix]+e.value);break;case"var":s=this._variable(e.value.substr(1));break;default:return this._error(`Expected entity but got ${e.type}`,e)}return!u&&this._n3Mode&&s.id in this._quantified&&(s=this._quantified[s.id]),s}_readSubject(e){switch(this._predicate=null,e.type){case"[":return this._saveContext("blank",this._graph,this._subject=this._blankNode(),null,null),this._readBlankNodeHead;case"(":return this._saveContext("list",this._graph,this.RDF_NIL,null,null),this._subject=null,this._readListItem;case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._graph=this._blankNode(),null,null),this._readSubject):this._error("Unexpected graph",e);case"}":return this._readPunctuation(e);case"@forSome":return this._n3Mode?(this._subject=null,this._predicate=this.N3_FORSOME,this._quantifier=this._blankNode,this._readQuantifierList):this._error('Unexpected "@forSome"',e);case"@forAll":return this._n3Mode?(this._subject=null,this._predicate=this.N3_FORALL,this._quantifier=this._variable,this._readQuantifierList):this._error('Unexpected "@forAll"',e);case"literal":if(!this._n3Mode)return this._error("Unexpected literal",e);if(e.prefix.length===0)return this._literalValue=e.value,this._completeSubjectLiteral;this._subject=this._literal(e.value,this._namedNode(e.prefix));break;case"<<":return this._supportsRDFStar?(this._saveContext("<<",this._graph,null,null,null),this._graph=null,this._readSubject):this._error("Unexpected RDF-star syntax",e);default:if((this._subject=this._readEntity(e))===void 0)return;if(this._n3Mode)return this._getPathReader(this._readPredicateOrNamedGraph)}return this._readPredicateOrNamedGraph}_readPredicate(e){const u=e.type;switch(u){case"inverse":this._inversePredicate=!0;case"abbreviation":this._predicate=this.ABBREVIATIONS[e.value];break;case".":case"]":case"}":return this._predicate===null?this._error(`Unexpected ${u}`,e):(this._subject=null,u==="]"?this._readBlankNodeTail(e):this._readPunctuation(e));case";":return this._predicate!==null?this._readPredicate:this._error("Expected predicate but got ;",e);case"[":if(this._n3Mode)return this._saveContext("blank",this._graph,this._subject,this._subject=this._blankNode(),null),this._readBlankNodeHead;case"blank":if(!this._n3Mode)return this._error("Disallowed blank node as predicate",e);default:if((this._predicate=this._readEntity(e))===void 0)return}return this._readObject}_readObject(e){switch(e.type){case"literal":if(e.prefix.length===0)return this._literalValue=e.value,this._readDataTypeOrLang;this._object=this._literal(e.value,this._namedNode(e.prefix));break;case"[":return this._saveContext("blank",this._graph,this._subject,this._predicate,this._subject=this._blankNode()),this._readBlankNodeHead;case"(":return this._saveContext("list",this._graph,this._subject,this._predicate,this.RDF_NIL),this._subject=null,this._readListItem;case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._subject,this._predicate,this._graph=this._blankNode()),this._readSubject):this._error("Unexpected graph",e);case"<<":return this._supportsRDFStar?(this._saveContext("<<",this._graph,this._subject,this._predicate,null),this._graph=null,this._readSubject):this._error("Unexpected RDF-star syntax",e);default:if((this._object=this._readEntity(e))===void 0)return;if(this._n3Mode)return this._getPathReader(this._getContextEndReader())}return this._getContextEndReader()}_readPredicateOrNamedGraph(e){return e.type==="{"?this._readGraph(e):this._readPredicate(e)}_readGraph(e){return e.type!=="{"?this._error(`Expected graph but got ${e.type}`,e):(this._graph=this._subject,this._subject=null,this._readSubject)}_readBlankNodeHead(e){return e.type==="]"?(this._subject=null,this._readBlankNodeTail(e)):(this._predicate=null,this._readPredicate(e))}_readBlankNodeTail(e){if(e.type!=="]")return this._readBlankNodePunctuation(e);this._subject!==null&&this._emit(this._subject,this._predicate,this._object,this._graph);const u=this._predicate===null;return this._restoreContext("blank",e),this._object!==null?this._getContextEndReader():this._predicate!==null?this._readObject:u?this._readPredicateOrNamedGraph:this._readPredicateAfterBlank}_readPredicateAfterBlank(e){switch(e.type){case".":case"}":return this._subject=null,this._readPunctuation(e);default:return this._readPredicate(e)}}_readListItem(e){let u=null,s=null,n=this._readListItem;const r=this._subject,a=this._contextStack,o=a[a.length-1];switch(e.type){case"[":this._saveContext("blank",this._graph,s=this._blankNode(),this.RDF_FIRST,this._subject=u=this._blankNode()),n=this._readBlankNodeHead;break;case"(":this._saveContext("list",this._graph,s=this._blankNode(),this.RDF_FIRST,this.RDF_NIL),this._subject=null;break;case")":if(this._restoreContext("list",e),a.length!==0&&a[a.length-1].type==="list"&&this._emit(this._subject,this._predicate,this._object,this._graph),this._predicate===null){if(n=this._readPredicate,this._subject===this.RDF_NIL)return n}else if(n=this._getContextEndReader(),this._object===this.RDF_NIL)return n;s=this.RDF_NIL;break;case"literal":e.prefix.length===0?(this._literalValue=e.value,n=this._readListItemDataTypeOrLang):(u=this._literal(e.value,this._namedNode(e.prefix)),n=this._getContextEndReader());break;case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._subject,this._predicate,this._graph=this._blankNode()),this._readSubject):this._error("Unexpected graph",e);default:if((u=this._readEntity(e))===void 0)return}if(s===null&&(this._subject=s=this._blankNode()),r===null?o.predicate===null?o.subject=s:o.object=s:this._emit(r,this.RDF_REST,s,this._graph),u!==null){if(this._n3Mode&&(e.type==="IRI"||e.type==="prefixed"))return this._saveContext("item",this._graph,s,this.RDF_FIRST,u),this._subject=u,this._predicate=null,this._getPathReader(this._readListItem);this._emit(s,this.RDF_FIRST,u,this._graph)}return n}_readDataTypeOrLang(e){return this._completeObjectLiteral(e,!1)}_readListItemDataTypeOrLang(e){return this._completeObjectLiteral(e,!0)}_completeLiteral(e){let u=this._literal(this._literalValue);switch(e.type){case"type":case"typeIRI":const s=this._readEntity(e);if(s===void 0)return;u=this._literal(this._literalValue,s),e=null;break;case"langcode":u=this._literal(this._literalValue,e.value),e=null;break}return{token:e,literal:u}}_completeSubjectLiteral(e){return this._subject=this._completeLiteral(e).literal,this._readPredicateOrNamedGraph}_completeObjectLiteral(e,u){const s=this._completeLiteral(e);if(s)return this._object=s.literal,u&&this._emit(this._subject,this.RDF_FIRST,this._object,this._graph),s.token===null?this._getContextEndReader():(this._readCallback=this._getContextEndReader(),this._readCallback(s.token))}_readFormulaTail(e){return e.type!=="}"?this._readPunctuation(e):(this._subject!==null&&this._emit(this._subject,this._predicate,this._object,this._graph),this._restoreContext("formula",e),this._object===null?this._readPredicate:this._getContextEndReader())}_readPunctuation(e){let u,s=this._graph;const n=this._subject,r=this._inversePredicate;switch(e.type){case"}":if(this._graph===null)return this._error("Unexpected graph closing",e);if(this._n3Mode)return this._readFormulaTail(e);this._graph=null;case".":this._subject=null,u=this._contextStack.length?this._readSubject:this._readInTopContext,r&&(this._inversePredicate=!1);break;case";":u=this._readPredicate;break;case",":u=this._readObject;break;case"{|":if(!this._supportsRDFStar)return this._error("Unexpected RDF-star syntax",e);const a=this._predicate,o=this._object;this._subject=this._quad(n,a,o,this.DEFAULTGRAPH),u=this._readPredicate;break;case"|}":if(this._subject.termType!=="Quad")return this._error("Unexpected asserted triple closing",e);this._subject=null,u=this._readPunctuation;break;default:if(this._supportsQuads&&this._graph===null&&(s=this._readEntity(e))!==void 0){u=this._readQuadPunctuation;break}return this._error(`Expected punctuation to follow "${this._object.id}"`,e)}if(n!==null){const a=this._predicate,o=this._object;r?this._emit(o,a,n,s):this._emit(n,a,o,s)}return u}_readBlankNodePunctuation(e){let u;switch(e.type){case";":u=this._readPredicate;break;case",":u=this._readObject;break;default:return this._error(`Expected punctuation to follow "${this._object.id}"`,e)}return this._emit(this._subject,this._predicate,this._object,this._graph),u}_readQuadPunctuation(e){return e.type!=="."?this._error("Expected dot to follow quad",e):this._readInTopContext}_readPrefix(e){return e.type!=="prefix"?this._error("Expected prefix to follow @prefix",e):(this._prefix=e.value,this._readPrefixIRI)}_readPrefixIRI(e){if(e.type!=="IRI")return this._error(`Expected IRI to follow prefix "${this._prefix}:"`,e);const u=this._readEntity(e);return this._prefixes[this._prefix]=u.value,this._prefixCallback(this._prefix,u),this._readDeclarationPunctuation}_readBaseIRI(e){const u=e.type==="IRI"&&this._resolveIRI(e.value);return u?(this._setBase(u),this._readDeclarationPunctuation):this._error("Expected valid IRI to follow base declaration",e)}_readNamedGraphLabel(e){switch(e.type){case"IRI":case"blank":case"prefixed":return this._readSubject(e),this._readGraph;case"[":return this._readNamedGraphBlankLabel;default:return this._error("Invalid graph label",e)}}_readNamedGraphBlankLabel(e){return e.type!=="]"?this._error("Invalid graph label",e):(this._subject=this._blankNode(),this._readGraph)}_readDeclarationPunctuation(e){return this._sparqlStyle?(this._sparqlStyle=!1,this._readInTopContext(e)):e.type!=="."?this._error("Expected declaration to end with a dot",e):this._readInTopContext}_readQuantifierList(e){let u;switch(e.type){case"IRI":case"prefixed":if((u=this._readEntity(e,!0))!==void 0)break;default:return this._error(`Unexpected ${e.type}`,e)}return this._explicitQuantifiers?(this._subject===null?this._emit(this._graph||this.DEFAULTGRAPH,this._predicate,this._subject=this._blankNode(),this.QUANTIFIERS_GRAPH):this._emit(this._subject,this.RDF_REST,this._subject=this._blankNode(),this.QUANTIFIERS_GRAPH),this._emit(this._subject,this.RDF_FIRST,u,this.QUANTIFIERS_GRAPH)):this._quantified[u.id]=this._quantifier(this._blankNode().value),this._readQuantifierPunctuation}_readQuantifierPunctuation(e){return e.type===","?this._readQuantifierList:(this._explicitQuantifiers&&(this._emit(this._subject,this.RDF_REST,this.RDF_NIL,this.QUANTIFIERS_GRAPH),this._subject=null),this._readCallback=this._getContextEndReader(),this._readCallback(e))}_getPathReader(e){return this._afterPath=e,this._readPath}_readPath(e){switch(e.type){case"!":return this._readForwardPath;case"^":return this._readBackwardPath;default:const u=this._contextStack,s=u.length&&u[u.length-1];if(s&&s.type==="item"){const n=this._subject;this._restoreContext("item",e),this._emit(this._subject,this.RDF_FIRST,n,this._graph)}return this._afterPath(e)}}_readForwardPath(e){let u,s;const n=this._blankNode();if((s=this._readEntity(e))!==void 0)return this._predicate===null?(u=this._subject,this._subject=n):(u=this._object,this._object=n),this._emit(u,s,n,this._graph),this._readPath}_readBackwardPath(e){const u=this._blankNode();let s,n;if((s=this._readEntity(e))!==void 0)return this._predicate===null?(n=this._subject,this._subject=u):(n=this._object,this._object=u),this._emit(u,s,n,this._graph),this._readPath}_readRDFStarTailOrGraph(e){return e.type!==">>"?this._supportsQuads&&this._graph===null&&(this._graph=this._readEntity(e))!==void 0?this._readRDFStarTail:this._error(`Expected >> to follow "${this._object.id}"`,e):this._readRDFStarTail(e)}_readRDFStarTail(e){if(e.type!==">>")return this._error(`Expected >> but got ${e.type}`,e);const u=this._quad(this._subject,this._predicate,this._object,this._graph||this.DEFAULTGRAPH);return this._restoreContext("<<",e),this._subject===null?(this._subject=u,this._readPredicate):(this._object=u,this._getContextEndReader())}_getContextEndReader(){const e=this._contextStack;if(!e.length)return this._readPunctuation;switch(e[e.length-1].type){case"blank":return this._readBlankNodeTail;case"list":return this._readListItem;case"formula":return this._readFormulaTail;case"<<":return this._readRDFStarTailOrGraph}}_emit(e,u,s,n){this._callback(null,this._quad(e,u,s,n||this.DEFAULTGRAPH))}_error(e,u){const s=new Error(`${e} on line ${u.line}.`);s.context={token:u,line:u.line,previousToken:this._lexer.previousToken},this._callback(s),this._callback=m1}_resolveIRI(e){return/^[a-z][a-z0-9+.-]*:/i.test(e)?e:this._resolveRelativeIRI(e)}_resolveRelativeIRI(e){if(!e.length)return this._base;switch(e[0]){case"#":return this._base+e;case"?":return this._base.replace(/(?:\?.*)?$/,e);case"/":return(e[1]==="/"?this._baseScheme:this._baseRoot)+this._removeDotSegments(e);default:return/^[^/:]*:/.test(e)?null:this._removeDotSegments(this._basePath+e)}}_removeDotSegments(e){if(!/(^|\/)\.\.?($|[/#?])/.test(e))return e;const u=e.length;let s="",n=-1,r=-1,a=0,o="/";for(;n=r&&(s=s.substr(0,a)),o!=="/")return`${s}/${e.substr(n+1)}`;a=n+1}}}o=e[++n]}return s+e.substring(a)}parse(e,u,s){let n,r,a;if(u&&(u.onQuad||u.onPrefix||u.onComment)?(n=u.onQuad,r=u.onPrefix,a=u.onComment):(n=u,r=s),this._readCallback=this._readInTopContext,this._sparqlStyle=!1,this._prefixes=Object.create(null),this._prefixes._=this._blankNodePrefix?this._blankNodePrefix.substr(2):`b${wD++}_`,this._prefixCallback=r||m1,this._inversePredicate=!1,this._quantified=Object.create(null),!n){const l=[];let c;if(this._callback=(d,h)=>{d?c=d:h&&l.push(h)},this._lexer.tokenize(e).every(d=>this._readCallback=this._readCallback(d)),c)throw c;return l}let o=(l,c)=>{l!==null?(this._callback(l),this._callback=m1):this._readCallback&&(this._readCallback=this._readCallback(c))};a&&(this._lexer.comments=!0,o=(l,c)=>{l!==null?(this._callback(l),this._callback=m1):this._readCallback&&(c.type==="comment"?a(c.value):this._readCallback=this._readCallback(c))}),this._callback=n,this._lexer.tokenize(e,o)}}function m1(){}function Yq(t,e){const u=e.namedNode;t._namedNode=u,t._blankNode=e.blankNode,t._literal=e.literal,t._variable=e.variable,t._quad=e.quad,t.DEFAULTGRAPH=e.defaultGraph(),t.RDF_FIRST=u(ln.rdf.first),t.RDF_REST=u(ln.rdf.rest),t.RDF_NIL=u(ln.rdf.nil),t.N3_FORALL=u(ln.r.forAll),t.N3_FORSOME=u(ln.r.forSome),t.ABBREVIATIONS={a:u(ln.rdf.type),"=":u(ln.owl.sameAs),">":u(ln.log.implies)},t.QUANTIFIERS_GRAPH=u("urn:n3:quantifiers")}Yq(em.prototype,wa);function bJ(t){return!!t&&t.termType==="NamedNode"}function mJ(t){return!!t&&t.termType==="BlankNode"}function gJ(t){return!!t&&t.termType==="Literal"}function _J(t){return!!t&&t.termType==="Variable"}function iy(t){return!!t&&t.termType==="DefaultGraph"}function vJ(t){return iy(t.graph)}function wJ(t,e){return Zq({"":t.value||t},e)("")}function Zq(t,e){const u=Object.create(null);for(const n in t)s(n,t[n]);e=e||wa;function s(n,r){if(typeof r=="string"){const a=Object.create(null);u[n]=o=>a[o]||(a[o]=e.namedNode(r+o))}else if(!(n in u))throw new Error(`Unknown prefix: ${n}`);return u[n]}return s}const e7=Object.freeze(Object.defineProperty({__proto__:null,inDefaultGraph:vJ,isBlankNode:mJ,isDefaultGraph:iy,isLiteral:gJ,isNamedNode:bJ,isVariable:_J,prefix:wJ,prefixes:Zq},Symbol.toStringTag,{value:"Module"})),Nl=wa.defaultGraph(),{rdf:SJ,xsd:mo}=ln,SD=/["\\\t\n\r\b\f\u0000-\u0019\ud800-\udbff]/,TD=/["\\\t\n\r\b\f\u0000-\u0019]|[\ud800-\udbff][\udc00-\udfff]/g,TJ={"\\":"\\\\",'"':'\\"'," ":"\\t","\n":"\\n","\r":"\\r","\b":"\\b","\f":"\\f"};class Cl extends Ji{equals(e){return e===this}}class jy{constructor(e,u){if(this._prefixRegex=/$0^/,e&&typeof e.write!="function"&&(u=e,e=null),u=u||{},this._lists=u.lists,e)this._outputStream=e,this._endStream=u.end===void 0?!0:!!u.end;else{let s="";this._outputStream={write(n,r,a){s+=n,a&&a()},end:n=>{n&&n(null,s)}},this._endStream=!0}this._subject=null,/triple|quad/i.test(u.format)?(this._lineMode=!0,this._writeQuad=this._writeQuadLine):(this._lineMode=!1,this._graph=Nl,this._prefixIRIs=Object.create(null),u.prefixes&&this.addPrefixes(u.prefixes),u.baseIRI&&(this._baseMatcher=new RegExp(`^${ED(u.baseIRI)}${u.baseIRI.endsWith("/")?"":"[#?]"}`),this._baseLength=u.baseIRI.length))}get _inDefaultGraph(){return Nl.equals(this._graph)}_write(e,u){this._outputStream.write(e,"utf8",u)}_writeQuad(e,u,s,n,r){try{n.equals(this._graph)||(this._write((this._subject===null?"":this._inDefaultGraph?`. +`:` +} +`)+(Nl.equals(n)?"":`${this._encodeIriOrBlank(n)} { +`)),this._graph=n,this._subject=null),e.equals(this._subject)?u.equals(this._predicate)?this._write(`, ${this._encodeObject(s)}`,r):this._write(`; + ${this._encodePredicate(this._predicate=u)} ${this._encodeObject(s)}`,r):this._write(`${(this._subject===null?"":`. +`)+this._encodeSubject(this._subject=e)} ${this._encodePredicate(this._predicate=u)} ${this._encodeObject(s)}`,r)}catch(a){r&&r(a)}}_writeQuadLine(e,u,s,n,r){delete this._prefixMatch,this._write(this.quadToString(e,u,s,n),r)}quadToString(e,u,s,n){return`${this._encodeSubject(e)} ${this._encodeIriOrBlank(u)} ${this._encodeObject(s)}${n&&n.value?` ${this._encodeIriOrBlank(n)} . +`:` . +`}`}quadsToString(e){let u="";for(const s of e)u+=this.quadToString(s.subject,s.predicate,s.object,s.graph);return u}_encodeSubject(e){return e.termType==="Quad"?this._encodeQuad(e):this._encodeIriOrBlank(e)}_encodeIriOrBlank(e){if(e.termType!=="NamedNode")return this._lists&&e.value in this._lists&&(e=this.list(this._lists[e.value])),"id"in e?e.id:`_:${e.value}`;let u=e.value;this._baseMatcher&&this._baseMatcher.test(u)&&(u=u.substr(this._baseLength)),SD.test(u)&&(u=u.replace(TD,AD));const s=this._prefixRegex.exec(u);return s?s[1]?this._prefixIRIs[s[1]]+s[2]:u:`<${u}>`}_encodeLiteral(e){let u=e.value;if(SD.test(u)&&(u=u.replace(TD,AD)),e.language)return`"${u}"@${e.language}`;if(this._lineMode){if(e.datatype.value===mo.string)return`"${u}"`}else switch(e.datatype.value){case mo.string:return`"${u}"`;case mo.boolean:if(u==="true"||u==="false")return u;break;case mo.integer:if(/^[+-]?\d+$/.test(u))return u;break;case mo.decimal:if(/^[+-]?\d*\.\d+$/.test(u))return u;break;case mo.double:if(/^[+-]?(?:\d+\.\d*|\.?\d+)[eE][+-]?\d+$/.test(u))return u;break}return`"${u}"^^${this._encodeIriOrBlank(e.datatype)}`}_encodePredicate(e){return e.value===SJ.type?"a":this._encodeIriOrBlank(e)}_encodeObject(e){switch(e.termType){case"Quad":return this._encodeQuad(e);case"Literal":return this._encodeLiteral(e);default:return this._encodeIriOrBlank(e)}}_encodeQuad({subject:e,predicate:u,object:s,graph:n}){return`<<${this._encodeSubject(e)} ${this._encodePredicate(u)} ${this._encodeObject(s)}${iy(n)?"":` ${this._encodeIriOrBlank(n)}`}>>`}_blockedWrite(){throw new Error("Cannot write because the writer has been closed.")}addQuad(e,u,s,n,r){s===void 0?this._writeQuad(e.subject,e.predicate,e.object,e.graph,u):typeof n=="function"?this._writeQuad(e,u,s,Nl,n):this._writeQuad(e,u,s,n||Nl,r)}addQuads(e){for(let u=0;u. +`)}if(s){let n="",r="";for(const a in this._prefixIRIs)n+=n?`|${a}`:a,r+=(r?"|":"")+this._prefixIRIs[a];n=ED(n),this._prefixRegex=new RegExp(`^(?:${r})[^/]*$|^(${n})([_a-zA-Z][\\-_a-zA-Z0-9]*)$`)}this._write(s?` +`:"",u)}blank(e,u){let s=e,n,r;switch(e===void 0?s=[]:e.termType?s=[{predicate:e,object:u}]:"length"in e||(s=[e]),r=s.length){case 0:return new Cl("[]");case 1:if(n=s[0],!(n.object instanceof Cl))return new Cl(`[ ${this._encodePredicate(n.predicate)} ${this._encodeObject(n.object)} ]`);default:let a="[";for(let o=0;o{u=null,e(s,n)});if(this._endStream)try{return this._outputStream.end(u)}catch{}u&&u()}}function AD(t){let e=TJ[t];return e===void 0&&(t.length===1?(e=t.charCodeAt(0).toString(16),e="\\u0000".substr(0,6-e.length)+e):(e=((t.charCodeAt(0)-55296)*1024+t.charCodeAt(1)+9216).toString(16),e="\\U00000000".substr(0,10-e.length)+e)),e}function ED(t){return t.replace(/[\]\/\(\)\*\+\?\.\\\$]/g,"\\$&")}var tm=Wt();const xv=Symbol("iter");function G1(t,e,u=4){if(u===0)return Object.assign(t,e);for(const s in e)t[s]=G1(t[s]||Object.create(null),e[s],u-1);return t}function t7(t,e,u=4){let s=!1;for(const n in t)if(n in e){const r=u===0?null:t7(t[n],e[n],u-1);if(r!==!1)s=s||Object.create(null),s[n]=r;else if(u===3)return!1}return s}class aA{constructor(e={}){this._id=1,this._ids=Object.create(null),this._ids[""]=1,this._entities=Object.create(null),this._entities[1]="",this._blankNodeIndex=0,this._factory=e.factory||wa}_termFromId(e){if(e[0]==="."){const u=this._entities,s=e.split(".");return this._factory.quad(this._termFromId(u[s[1]]),this._termFromId(u[s[2]]),this._termFromId(u[s[3]]),s[4]&&this._termFromId(u[s[4]]))}return Vs(e,this._factory)}_termToNumericId(e){if(e.termType==="Quad"){const u=this._termToNumericId(e.subject),s=this._termToNumericId(e.predicate),n=this._termToNumericId(e.object);let r;return u&&s&&n&&(iy(e.graph)||(r=this._termToNumericId(e.graph)))&&this._ids[r?`.${u}.${s}.${n}.${r}`:`.${u}.${s}.${n}`]}return this._ids[Qa(e)]}_termToNewNumericId(e){const u=e&&e.termType==="Quad"?`.${this._termToNewNumericId(e.subject)}.${this._termToNewNumericId(e.predicate)}.${this._termToNewNumericId(e.object)}${iy(e.graph)?"":`.${this._termToNewNumericId(e.graph)}`}`:Qa(e);return this._ids[u]||(this._ids[this._entities[++this._id]=u]=this._id)}createBlankNode(e){let u,s;if(e)for(u=e=`_:${e}`,s=1;this._ids[u];)u=e+s++;else do u=`_:b${this._blankNodeIndex++}`;while(this._ids[u]);return this._ids[u]=++this._id,this._entities[this._id]=u,this._factory.blankNode(u.substr(2))}}class qn{constructor(e,u){this._size=0,this._graphs=Object.create(null),!u&&e&&!e[0]&&(u=e,e=null),u=u||{},this._factory=u.factory||wa,this._entityIndex=u.entityIndex||new aA({factory:this._factory}),this._entities=this._entityIndex._entities,this._termFromId=this._entityIndex._termFromId.bind(this._entityIndex),this._termToNumericId=this._entityIndex._termToNumericId.bind(this._entityIndex),this._termToNewNumericId=this._entityIndex._termToNewNumericId.bind(this._entityIndex),e&&this.addQuads(e)}get size(){let e=this._size;if(e!==null)return e;e=0;const u=this._graphs;let s,n;for(const r in u)for(const a in s=u[r].subjects)for(const o in n=s[a])e+=Object.keys(n[o]).length;return this._size=e}_addToIndex(e,u,s,n){const r=e[u]||(e[u]={}),a=r[s]||(r[s]={}),o=n in a;return o||(a[n]=null),!o}_removeFromIndex(e,u,s,n){const r=e[u],a=r[s];delete a[n];for(const o in a)return;delete r[s];for(const o in r)return;delete e[u]}*_findInIndex(e,u,s,n,r,a,o,l){let c,d,h;const f=this._entities,p=this._termFromId(f[l]),y={subject:null,predicate:null,object:null};u&&((c=e,e={})[u]=c[u]);for(const b in e)if(d=e[b]){y[r]=this._termFromId(f[b]),s&&((c=d,d={})[s]=c[s]);for(const g in d)if(h=d[g]){y[a]=this._termFromId(f[g]);const m=n?n in h?[n]:[]:Object.keys(h);for(let v=0;v{s in u||(u[s]=!0,e(this._termFromId(this._entities[s],this._factory)))}}add(e){return this.addQuad(e),this}addQuad(e,u,s,n){u||(n=e.graph,s=e.object,u=e.predicate,e=e.subject),n=n?this._termToNewNumericId(n):1;let r=this._graphs[n];return r||(r=this._graphs[n]={subjects:{},predicates:{},objects:{}},Object.freeze(r)),e=this._termToNewNumericId(e),u=this._termToNewNumericId(u),s=this._termToNewNumericId(s),this._addToIndex(r.subjects,e,u,s)?(this._addToIndex(r.predicates,u,s,e),this._addToIndex(r.objects,s,e,u),this._size=null,!0):!1}addQuads(e){for(let u=0;u{this.addQuad(u)}),e}removeQuad(e,u,s,n){u||({subject:e,predicate:u,object:s,graph:n}=e),n=n?this._termToNumericId(n):1;const r=this._graphs;let a,o,l;if(!(e=e&&this._termToNumericId(e))||!(u=u&&this._termToNumericId(u))||!(s=s&&this._termToNumericId(s))||!(a=r[n])||!(o=a.subjects[e])||!(l=o[u])||!(s in l))return!1;this._removeFromIndex(a.subjects,e,u,s),this._removeFromIndex(a.predicates,u,s,e),this._removeFromIndex(a.objects,s,e,u),this._size!==null&&this._size--;for(e in a.subjects)return!0;return delete r[n],!0}removeQuads(e){for(let u=0;u{this.removeQuad(u)}),e}removeMatches(e,u,s,n){const r=new tm.Readable({objectMode:!0}),a=this.readQuads(e,u,s,n);return r._read=o=>{for(;o-- >0;){const{done:l,value:c}=a.next();if(l){r.push(null);return}r.push(c)}},this.remove(r)}deleteGraph(e){return this.removeMatches(null,null,null,e)}getQuads(e,u,s,n){return[...this.readQuads(e,u,s,n)]}*readQuads(e,u,s,n){const r=this._getGraphs(n);let a,o,l,c;if(!(e&&!(o=this._termToNumericId(e))||u&&!(l=this._termToNumericId(u))||s&&!(c=this._termToNumericId(s))))for(const d in r)(a=r[d])&&(o?c?yield*this._findInIndex(a.objects,c,o,l,"object","subject","predicate",d):yield*this._findInIndex(a.subjects,o,l,null,"subject","predicate","object",d):l?yield*this._findInIndex(a.predicates,l,c,null,"predicate","object","subject",d):c?yield*this._findInIndex(a.objects,c,null,null,"object","subject","predicate",d):yield*this._findInIndex(a.subjects,null,null,null,"subject","predicate","object",d))}match(e,u,s,n){return new sA(this,e,u,s,n,{entityIndex:this._entityIndex})}countQuads(e,u,s,n){const r=this._getGraphs(n);let a=0,o,l,c,d;if(e&&!(l=this._termToNumericId(e))||u&&!(c=this._termToNumericId(u))||s&&!(d=this._termToNumericId(s)))return 0;for(const h in r)(o=r[h])&&(e?s?a+=this._countInIndex(o.objects,d,l,c):a+=this._countInIndex(o.subjects,l,c,d):u?a+=this._countInIndex(o.predicates,c,d,l):a+=this._countInIndex(o.objects,d,l,c));return a}forEach(e,u,s,n,r){this.some(a=>(e(a,this),!1),u,s,n,r)}every(e,u,s,n,r){return!this.some(a=>!e(a,this),u,s,n,r)}some(e,u,s,n,r){for(const a of this.readQuads(u,s,n,r))if(e(a))return!0;return!1}getSubjects(e,u,s){const n=[];return this.forSubjects(r=>{n.push(r)},e,u,s),n}forSubjects(e,u,s,n){const r=this._getGraphs(n);let a,o,l;if(e=this._uniqueEntities(e),!(u&&!(o=this._termToNumericId(u))||s&&!(l=this._termToNumericId(s))))for(n in r)(a=r[n])&&(o?l?this._loopBy2Keys(a.predicates,o,l,e):this._loopByKey1(a.subjects,o,e):l?this._loopByKey0(a.objects,l,e):this._loop(a.subjects,e))}getPredicates(e,u,s){const n=[];return this.forPredicates(r=>{n.push(r)},e,u,s),n}forPredicates(e,u,s,n){const r=this._getGraphs(n);let a,o,l;if(e=this._uniqueEntities(e),!(u&&!(o=this._termToNumericId(u))||s&&!(l=this._termToNumericId(s))))for(n in r)(a=r[n])&&(o?l?this._loopBy2Keys(a.objects,l,o,e):this._loopByKey0(a.subjects,o,e):l?this._loopByKey1(a.predicates,l,e):this._loop(a.predicates,e))}getObjects(e,u,s){const n=[];return this.forObjects(r=>{n.push(r)},e,u,s),n}forObjects(e,u,s,n){const r=this._getGraphs(n);let a,o,l;if(e=this._uniqueEntities(e),!(u&&!(o=this._termToNumericId(u))||s&&!(l=this._termToNumericId(s))))for(n in r)(a=r[n])&&(o?l?this._loopBy2Keys(a.subjects,o,l,e):this._loopByKey1(a.objects,o,e):l?this._loopByKey0(a.predicates,l,e):this._loop(a.objects,e))}getGraphs(e,u,s){const n=[];return this.forGraphs(r=>{n.push(r)},e,u,s),n}forGraphs(e,u,s,n){for(const r in this._graphs)this.some(a=>(e(a.graph),!0),u,s,n,this._termFromId(this._entities[r]))}createBlankNode(e){return this._entityIndex.createBlankNode(e)}extractLists({remove:e=!1,ignoreErrors:u=!1}={}){const s={},n=u?()=>!0:(o,l)=>{throw new Error(`${o.value} ${l}`)},r=this.getQuads(null,ln.rdf.rest,ln.rdf.nil,null),a=e?[...r]:[];return r.forEach(o=>{const l=[];let c=!1,d,h;const f=o.graph;let p=o.subject;for(;p&&!c;){const y=this.getQuads(null,null,p,null),b=this.getQuads(p,null,null,null);let g,m=null,v=null,_=null;for(let w=0;wthis.has(c));const u=this._graphs,s=e._graphs;let n,r,a,o,l;for(const c in s){if(!(n=u[c]))return!1;n=n.subjects;for(const d in r=s[c].subjects){if(!(a=n[d]))return!1;for(const h in o=r[d]){if(!(l=a[h]))return!1;for(const f in o[h])if(!(f in l))return!1}}}return!0}deleteMatches(e,u,s,n){for(const r of this.match(e,u,s,n))this.removeQuad(r);return this}difference(e){return e===this?new qn({entityIndex:this._entityIndex}):this.filter(u=>!e.has(u))}equals(e){return e===this||this.size===e.size&&this.contains(e)}filter(e){const u=new qn({entityIndex:this._entityIndex});for(const s of this)e(s,this)&&u.add(s);return u}intersection(e){if(e===this){const u=new qn({entityIndex:this._entityIndex});return u._graphs=G1(Object.create(null),this._graphs),u._size=this._size,u}else if(e instanceof qn&&this._entityIndex===e._entityIndex){const u=new qn({entityIndex:this._entityIndex}),s=t7(e._graphs,this._graphs);return s&&(u._graphs=s,u._size=null),u}return this.filter(u=>e.has(u))}map(e){const u=new qn({entityIndex:this._entityIndex});for(const s of this)u.add(e(s,this));return u}reduce(e,u){const s=this.readQuads();let n=u===void 0?s.next().value:u;for(const r of s)n=e(n,r,this);return n}toArray(){return this.getQuads()}toCanonical(){throw new Error("not implemented")}toStream(){return this.match()}toString(){return new jy().quadsToString(this)}union(e){const u=new qn({entityIndex:this._entityIndex});return u._graphs=G1(Object.create(null),this._graphs),u._size=this._size,u.addAll(e),u}*[Symbol.iterator](){yield*this.readQuads()}}class sA extends tm.Readable{constructor(e,u,s,n,r,a){super({objectMode:!0}),Object.assign(this,{n3Store:e,subject:u,predicate:s,object:n,graph:r,options:a})}get filtered(){if(!this._filtered){const{n3Store:e,graph:u,object:s,predicate:n,subject:r}=this,a=this._filtered=new qn({factory:e._factory,entityIndex:this.options.entityIndex});for(const o of e.readQuads(r,n,s,u))a.addQuad(o)}return this._filtered}get size(){return this.filtered.size}_read(e){e>0&&!this[xv]&&(this[xv]=this[Symbol.iterator]());const u=this[xv];for(;e-- >0;){const{done:s,value:n}=u.next();if(s){this.push(null);return}this.push(n)}}addAll(e){return this.filtered.addAll(e)}contains(e){return this.filtered.contains(e)}deleteMatches(e,u,s,n){return this.filtered.deleteMatches(e,u,s,n)}difference(e){return this.filtered.difference(e)}equals(e){return this.filtered.equals(e)}every(e,u,s,n,r){return this.filtered.every(e,u,s,n,r)}filter(e){return this.filtered.filter(e)}forEach(e,u,s,n,r){return this.filtered.forEach(e,u,s,n,r)}import(e){return this.filtered.import(e)}intersection(e){return this.filtered.intersection(e)}map(e){return this.filtered.map(e)}some(e,u,s,n,r){return this.filtered.some(e,u,s,n,r)}toCanonical(){return this.filtered.toCanonical()}toStream(){return this._filtered?this._filtered.toStream():this.n3Store.match(this.subject,this.predicate,this.object,this.graph)}union(e){return this._filtered?this._filtered.union(e):this.n3Store.match(this.subject,this.predicate,this.object,this.graph).addAll(e)}toArray(){return this._filtered?this._filtered.toArray():this.n3Store.getQuads(this.subject,this.predicate,this.object,this.graph)}reduce(e,u){return this.filtered.reduce(e,u)}toString(){return new jy().quadsToString(this)}add(e){return this.filtered.add(e)}delete(e){return this.filtered.delete(e)}has(e){return this.filtered.has(e)}match(e,u,s,n){return new sA(this.filtered,e,u,s,n,this.options)}*[Symbol.iterator](){yield*this._filtered||this.n3Store.readQuads(this.subject,this.predicate,this.object,this.graph)}}class r7{dataset(e){return new qn(e)}}function n7(t){const e=[];for(const{subject:u,object:s}of t.match(null,wa.namedNode("http://www.w3.org/2000/10/swap/log#implies"),null,wa.defaultGraph())){const n=[...t.match(null,null,null,u)],r=[...t.match(null,null,null,s)];e.push({premise:n,conclusion:r})}return e}class i7{constructor(e){this._store=e}_add(e,u,s,n,r){this._store._addToIndex(n.subjects,e,u,s)&&(this._store._addToIndex(n.predicates,u,s,e),this._store._addToIndex(n.objects,s,e,u),r())}_evaluatePremise(e,u,s,n=0){let r,a,o,l,c;const[d,h,f]=e.premise[n].value,p=u[e.premise[n].content],y=!(o=d.value);for(o in y?p:{[o]:p[o]})if(l=p[o]){y&&(d.value=Number(o)),r=!(o=h.value);for(o in r?l:{[o]:l[o]})if(c=l[o]){r&&(h.value=Number(o)),a=!(o=f.value);for(o in a?c:{[o]:c[o]})a&&(f.value=Number(o)),n===e.premise.length-1?e.conclusion.forEach(b=>{this._add(b.subject.value,b.predicate.value,b.object.value,u,()=>{s(b)})}):this._evaluatePremise(e,u,s,n+1);a&&(f.value=null)}r&&(h.value=null)}y&&(d.value=null)}_evaluateRules(e,u,s){for(let n=0;n{s.push([o.subject.value,o.predicate.value,o.object.value,l])})}const r=o=>{o.forEach(l=>{this._add(l.subject.value,l.predicate.value,l.object.value,u,()=>{n(l)})})};this._evaluateRules(e,u,n);let a;for(;(a=s.pop())!==void 0;){const[o,l,c,d]=a,h=d.basePremise.subject.value;h||(d.basePremise.subject.value=o);const f=d.basePremise.predicate.value;f||(d.basePremise.predicate.value=l);const p=d.basePremise.object.value;p||(d.basePremise.object.value=c),d.premise.length===0?r(d.conclusion):this._evaluatePremise(d,u,n),h||(d.basePremise.subject.value=null),f||(d.basePremise.predicate.value=null),p||(d.basePremise.object.value=null)}}_createRule({premise:e,conclusion:u}){const s={},n=a=>a.termType==="Variable"?s[a.value]=s[a.value]||{}:{value:this._store._termToNewNumericId(a)},r=a=>({subject:n(a.subject),predicate:n(a.predicate),object:n(a.object)});return{premise:e.map(a=>r(a)),conclusion:u.map(a=>r(a)),variables:Object.values(s)}}reason(e){Array.isArray(e)||(e=n7(e)),e=e.map(s=>this._createRule(s));for(const s of e)for(const n of e)for(let r=0;r{l.value=null})}}for(const s of e){const n=new Set;s.premise=s.premise.map(r=>OD(r,n))}const u=this._store._getGraphs();for(const s in u)this._reasonGraphNaive(e,u[s]);this._store._size=null}}function OD({subject:t,predicate:e,object:u},s){const n=t.value||s.has(t)||(s.add(t),!1),r=e.value||s.has(e)||(s.add(e),!1),a=u.value||s.has(u)||(s.add(u),!1);return!n&&r?{content:"predicates",value:[e,u,t]}:a?{content:"objects",value:[u,t,e]}:{content:"subjects",value:[t,e,u]}}function Iv(t,e){return t.value===null&&(t.value=e.value),t.value===e.value}class a7 extends tm.Transform{constructor(e){super({decodeStrings:!0}),this._readableState.objectMode=!0;const u=new em(e);let s,n;const r={onQuad:(a,o)=>{a&&this.emit("error",a)||o&&this.push(o)},onPrefix:(a,o)=>{this.emit("prefix",a,o)}};e&&e.comments&&(r.onComment=a=>{this.emit("comment",a)}),u.parse({on:(a,o)=>{switch(a){case"data":s=o;break;case"end":n=o;break}}},r),this._transform=(a,o,l)=>{s(a),l()},this._flush=a=>{n(),a()}}import(e){return e.on("data",u=>{this.write(u)}),e.on("end",()=>{this.end()}),e.on("error",u=>{this.emit("error",u)}),this}}class s7 extends tm.Transform{constructor(e){super({encoding:"utf8",writableObjectMode:!0});const u=this._writer=new jy({write:(s,n,r)=>{this.push(s),r&&r()},end:s=>{this.push(null),s&&s()}},e);this._transform=(s,n,r)=>{u.addQuad(s,r)},this._flush=s=>{u.end(s)}}import(e){return e.on("data",u=>{this.write(u)}),e.on("end",()=>{this.end()}),e.on("error",u=>{this.emit("error",u)}),e.on("prefix",(u,s)=>{this._writer.addPrefix(u,s)}),this}}const AJ={Lexer:tA,Parser:em,Writer:jy,Store:qn,StoreFactory:r7,EntityIndex:aA,StreamParser:a7,StreamWriter:s7,Util:e7,Reasoner:i7,DataFactory:wa,Term:Ji,NamedNode:Zb,Literal:ka,BlankNode:rA,Variable:nA,DefaultGraph:iA,Quad:ny,Triple:ny,termFromId:Vs,termToId:Qa},EJ=Object.freeze(Object.defineProperty({__proto__:null,BlankNode:rA,DataFactory:wa,DefaultGraph:iA,EntityIndex:aA,Lexer:tA,Literal:ka,NamedNode:Zb,Parser:em,Quad:ny,Reasoner:i7,Store:qn,StoreFactory:r7,StreamParser:a7,StreamWriter:s7,Term:Ji,Triple:ny,Util:e7,Variable:nA,Writer:jy,default:AJ,getRulesFromDataset:n7,termFromId:Vs,termToId:Qa},Symbol.toStringTag,{value:"Module"})),is=iT(EJ);var RD;function OJ(){if(RD)return Rl;RD=1,Object.defineProperty(Rl,"__esModule",{value:!0}),Rl.ActorRdfParseN3=void 0;const t=su(),e=is;let u=class extends t.ActorRdfParseFixedMediaTypes{constructor(n){super(n)}async runHandle(n,r,a){var l;n.data.on("error",c=>o.emit("error",c));const o=n.data.pipe(new e.StreamParser({baseIRI:(l=n.metadata)==null?void 0:l.baseIRI,format:r.endsWith("n3")?r:`${r}*`}));return{data:o,metadata:{triples:r==="text/turtle"||r==="application/n-triples"||r==="text/n3"}}}};return Rl.ActorRdfParseN3=u,Rl}var xD;function RJ(){return xD||(xD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(OJ(),t)}(Ev)),Ev}var Pv={},jl={},Dv={},Ts={},As={},Nv={},ID;function xJ(){return ID||(ID=1,function(t){/** + * Character classes and associated utilities for the 5th edition of XML 1.0. + * + * @author Louis-Dominique Dubeau + * @license MIT + * @copyright Louis-Dominique Dubeau + */Object.defineProperty(t,"__esModule",{value:!0}),t.CHAR=` +\r -퟿-�𐀀-􏿿`,t.S=` \r +`,t.NAME_START_CHAR=":A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�𐀀-󯿿",t.NAME_CHAR="-"+t.NAME_START_CHAR+".0-9·̀-ͯ‿-⁀",t.CHAR_RE=new RegExp("^["+t.CHAR+"]$","u"),t.S_RE=new RegExp("^["+t.S+"]+$","u"),t.NAME_START_CHAR_RE=new RegExp("^["+t.NAME_START_CHAR+"]$","u"),t.NAME_CHAR_RE=new RegExp("^["+t.NAME_CHAR+"]$","u"),t.NAME_RE=new RegExp("^["+t.NAME_START_CHAR+"]["+t.NAME_CHAR+"]*$","u"),t.NMTOKEN_RE=new RegExp("^["+t.NAME_CHAR+"]+$","u");var e=9,u=10,s=13,n=32;t.S_LIST=[n,u,s,e];function r(c){return c>=n&&c<=55295||c===u||c===s||c===e||c>=57344&&c<=65533||c>=65536&&c<=1114111}t.isChar=r;function a(c){return c===n||c===u||c===s||c===e}t.isS=a;function o(c){return c>=65&&c<=90||c>=97&&c<=122||c===58||c===95||c===8204||c===8205||c>=192&&c<=214||c>=216&&c<=246||c>=248&&c<=767||c>=880&&c<=893||c>=895&&c<=8191||c>=8304&&c<=8591||c>=11264&&c<=12271||c>=12289&&c<=55295||c>=63744&&c<=64975||c>=65008&&c<=65533||c>=65536&&c<=983039}t.isNameStartChar=o;function l(c){return o(c)||c>=48&&c<=57||c===45||c===46||c===183||c>=768&&c<=879||c>=8255&&c<=8256}t.isNameChar=l}(Nv)),Nv}var Cv={},PD;function IJ(){return PD||(PD=1,function(t){/** + * Character classes and associated utilities for the 2nd edition of XML 1.1. + * + * @author Louis-Dominique Dubeau + * @license MIT + * @copyright Louis-Dominique Dubeau + */Object.defineProperty(t,"__esModule",{value:!0}),t.CHAR="-퟿-�𐀀-􏿿",t.RESTRICTED_CHAR="-\b\v\f--„†-Ÿ",t.S=` \r +`,t.NAME_START_CHAR=":A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�𐀀-󯿿",t.NAME_CHAR="-"+t.NAME_START_CHAR+".0-9·̀-ͯ‿-⁀",t.CHAR_RE=new RegExp("^["+t.CHAR+"]$","u"),t.RESTRICTED_CHAR_RE=new RegExp("^["+t.RESTRICTED_CHAR+"]$","u"),t.S_RE=new RegExp("^["+t.S+"]+$","u"),t.NAME_START_CHAR_RE=new RegExp("^["+t.NAME_START_CHAR+"]$","u"),t.NAME_CHAR_RE=new RegExp("^["+t.NAME_CHAR+"]$","u"),t.NAME_RE=new RegExp("^["+t.NAME_START_CHAR+"]["+t.NAME_CHAR+"]*$","u"),t.NMTOKEN_RE=new RegExp("^["+t.NAME_CHAR+"]+$","u");var e=9,u=10,s=13,n=32;t.S_LIST=[n,u,s,e];function r(h){return h>=1&&h<=55295||h>=57344&&h<=65533||h>=65536&&h<=1114111}t.isChar=r;function a(h){return h>=1&&h<=8||h===11||h===12||h>=14&&h<=31||h>=127&&h<=132||h>=134&&h<=159}t.isRestrictedChar=a;function o(h){return h===9||h===10||h===13||h>31&&h<127||h===133||h>159&&h<=55295||h>=57344&&h<=65533||h>=65536&&h<=1114111}t.isCharAndNotRestricted=o;function l(h){return h===n||h===u||h===s||h===e}t.isS=l;function c(h){return h>=65&&h<=90||h>=97&&h<=122||h===58||h===95||h===8204||h===8205||h>=192&&h<=214||h>=216&&h<=246||h>=248&&h<=767||h>=880&&h<=893||h>=895&&h<=8191||h>=8304&&h<=8591||h>=11264&&h<=12271||h>=12289&&h<=55295||h>=63744&&h<=64975||h>=65008&&h<=65533||h>=65536&&h<=983039}t.isNameStartChar=c;function d(h){return c(h)||h>=48&&h<=57||h===45||h===46||h===183||h>=768&&h<=879||h>=8255&&h<=8256}t.isNameChar=d}(Cv)),Cv}var jv={},DD;function PJ(){return DD||(DD=1,function(t){/** + * Character class utilities for XML NS 1.0 edition 3. + * + * @author Louis-Dominique Dubeau + * @license MIT + * @copyright Louis-Dominique Dubeau + */Object.defineProperty(t,"__esModule",{value:!0}),t.NC_NAME_START_CHAR="A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�𐀀-󯿿",t.NC_NAME_CHAR="-"+t.NC_NAME_START_CHAR+".0-9·̀-ͯ‿-⁀",t.NC_NAME_START_CHAR_RE=new RegExp("^["+t.NC_NAME_START_CHAR+"]$","u"),t.NC_NAME_CHAR_RE=new RegExp("^["+t.NC_NAME_CHAR+"]$","u"),t.NC_NAME_RE=new RegExp("^["+t.NC_NAME_START_CHAR+"]["+t.NC_NAME_CHAR+"]*$","u");function e(s){return s>=65&&s<=90||s===95||s>=97&&s<=122||s>=192&&s<=214||s>=216&&s<=246||s>=248&&s<=767||s>=880&&s<=893||s>=895&&s<=8191||s>=8204&&s<=8205||s>=8304&&s<=8591||s>=11264&&s<=12271||s>=12289&&s<=55295||s>=63744&&s<=64975||s>=65008&&s<=65533||s>=65536&&s<=983039}t.isNCNameStartChar=e;function u(s){return e(s)||s===45||s===46||s>=48&&s<=57||s===183||s>=768&&s<=879||s>=8255&&s<=8256}t.isNCNameChar=u}(jv)),jv}var ND;function o7(){if(ND)return As;ND=1,Object.defineProperty(As,"__esModule",{value:!0}),As.SaxesParser=As.EVENTS=void 0;const t=xJ(),e=IJ(),u=PJ();var s=t.isS,n=t.isChar,r=t.isNameStartChar,a=t.isNameChar,o=t.S_LIST,l=t.NAME_RE,c=e.isChar,d=u.isNCNameStartChar,h=u.isNCNameChar,f=u.NC_NAME_RE;const p="http://www.w3.org/XML/1998/namespace",y="http://www.w3.org/2000/xmlns/",b={__proto__:null,xml:p,xmlns:y},g={__proto__:null,amp:"&",gt:">",lt:"<",quot:'"',apos:"'"},m=-1,v=-2,_=0,w=1,S=2,A=3,D=4,L=5,O=6,E=7,P=8,M=9,U=10,j=11,q=12,$=13,Z=14,X=15,le=16,K=17,he=18,Re=19,ie=20,ae=21,Ee=22,De=23,ge=24,de=25,fe=26,H=27,N=28,R=29,T=30,x=31,B=32,k=33,V=34,J=35,z=36,Y=37,re=38,ce=39,Te=40,xe=41,Le=42,qe=43,G=44,F=9,Q=10,te=13,me=32,Oe=33,Ne=34,We=38,Ve=39,pe=45,we=47,W=59,Se=60,Ae=61,je=62,He=63,Ge=91,tt=93,lt=133,ut=8232,oe=Ke=>Ke===Ne||Ke===Ve,C=[Ne,Ve],ee=[...C,Ge,je],ye=[...C,Se,tt],Pe=[Ae,He,...o],Ue=[...o,je,We,Se];function Fe(Ke,be,Ie){switch(be){case"xml":Ie!==p&&Ke.fail(`xml prefix must be bound to ${p}.`);break;case"xmlns":Ie!==y&&Ke.fail(`xmlns prefix must be bound to ${y}.`);break}switch(Ie){case y:Ke.fail(be===""?`the default namespace may not be set to ${Ie}.`:`may not assign a prefix (even "xmlns") to the URI ${y}.`);break;case p:switch(be){case"xml":break;case"":Ke.fail(`the default namespace may not be set to ${Ie}.`);break;default:Ke.fail("may not assign the xml namespace to another prefix.")}break}}function Ye(Ke,be){for(const Ie of Object.keys(be))Fe(Ke,Ie,be[Ie])}const $e=Ke=>f.test(Ke),Je=Ke=>l.test(Ke),nt=0,yt=1,ft=2;As.EVENTS=["xmldecl","text","processinginstruction","doctype","comment","opentagstart","attribute","opentag","closetag","cdata","error","end","ready"];const et={xmldecl:"xmldeclHandler",text:"textHandler",processinginstruction:"piHandler",doctype:"doctypeHandler",comment:"commentHandler",opentagstart:"openTagStartHandler",attribute:"attributeHandler",opentag:"openTagHandler",closetag:"closeTagHandler",cdata:"cdataHandler",error:"errorHandler",end:"endHandler",ready:"readyHandler"};class Ir{get closed(){return this._closed}constructor(be){this.opt=be??{},this.fragmentOpt=!!this.opt.fragment;const Ie=this.xmlnsOpt=!!this.opt.xmlns;if(this.trackPosition=this.opt.position!==!1,this.fileName=this.opt.fileName,Ie){this.nameStartCheck=d,this.nameCheck=h,this.isName=$e,this.processAttribs=this.processAttribsNS,this.pushAttrib=this.pushAttribNS,this.ns=Object.assign({__proto__:null},b);const Me=this.opt.additionalNamespaces;Me!=null&&(Ye(this,Me),Object.assign(this.ns,Me))}else this.nameStartCheck=r,this.nameCheck=a,this.isName=Je,this.processAttribs=this.processAttribsPlain,this.pushAttrib=this.pushAttribPlain;this.stateTable=[this.sBegin,this.sBeginWhitespace,this.sDoctype,this.sDoctypeQuote,this.sDTD,this.sDTDQuoted,this.sDTDOpenWaka,this.sDTDOpenWakaBang,this.sDTDComment,this.sDTDCommentEnding,this.sDTDCommentEnded,this.sDTDPI,this.sDTDPIEnding,this.sText,this.sEntity,this.sOpenWaka,this.sOpenWakaBang,this.sComment,this.sCommentEnding,this.sCommentEnded,this.sCData,this.sCDataEnding,this.sCDataEnding2,this.sPIFirstChar,this.sPIRest,this.sPIBody,this.sPIEnding,this.sXMLDeclNameStart,this.sXMLDeclName,this.sXMLDeclEq,this.sXMLDeclValueStart,this.sXMLDeclValue,this.sXMLDeclSeparator,this.sXMLDeclEnding,this.sOpenTag,this.sOpenTagSlash,this.sAttrib,this.sAttribName,this.sAttribNameSawWhite,this.sAttribValue,this.sAttribValueQuoted,this.sAttribValueClosed,this.sAttribValueUnquoted,this.sCloseTag,this.sCloseTagSawWhite],this._init()}_init(){var be;this.openWakaBang="",this.text="",this.name="",this.piTarget="",this.entity="",this.q=null,this.tags=[],this.tag=null,this.topNS=null,this.chunk="",this.chunkPosition=0,this.i=0,this.prevI=0,this.carriedFromPrevious=void 0,this.forbiddenState=nt,this.attribList=[];const{fragmentOpt:Ie}=this;this.state=Ie?$:_,this.reportedTextBeforeRoot=this.reportedTextAfterRoot=this.closedRoot=this.sawRoot=Ie,this.xmlDeclPossible=!Ie,this.xmlDeclExpects=["version"],this.entityReturnState=void 0;let{defaultXMLVersion:Me}=this.opt;if(Me===void 0){if(this.opt.forceXMLVersion===!0)throw new Error("forceXMLVersion set but defaultXMLVersion is not set");Me="1.0"}this.setXMLVersion(Me),this.positionAtNewLine=0,this.doctype=!1,this._closed=!1,this.xmlDecl={version:void 0,encoding:void 0,standalone:void 0},this.line=1,this.column=0,this.ENTITIES=Object.create(g),(be=this.readyHandler)===null||be===void 0||be.call(this)}get position(){return this.chunkPosition+this.i}get columnIndex(){return this.position-this.positionAtNewLine}on(be,Ie){this[et[be]]=Ie}off(be){this[et[be]]=void 0}makeError(be){var Ie;let Me=(Ie=this.fileName)!==null&&Ie!==void 0?Ie:"";return this.trackPosition&&(Me.length>0&&(Me+=":"),Me+=`${this.line}:${this.column}`),Me.length>0&&(Me+=": "),new Error(Me+be)}fail(be){const Ie=this.makeError(be),Me=this.errorHandler;if(Me===void 0)throw Ie;return Me(Ie),this}write(be){if(this.closed)return this.fail("cannot write after close; assign an onready handler.");let Ie=!1;be===null?(Ie=!0,be=""):typeof be=="object"&&(be=be.toString()),this.carriedFromPrevious!==void 0&&(be=`${this.carriedFromPrevious}${be}`,this.carriedFromPrevious=void 0);let Me=be.length;const it=be.charCodeAt(Me-1);!Ie&&(it===te||it>=55296&&it<=56319)&&(this.carriedFromPrevious=be[Me-1],Me--,be=be.slice(0,Me));const{stateTable:at}=this;for(this.chunk=be,this.i=0;this.i=be.length)return m;const Me=be.charCodeAt(Ie);if(this.column++,Me<55296){if(Me>=me||Me===F)return Me;switch(Me){case Q:return this.line++,this.column=0,this.positionAtNewLine=this.position,Q;case te:return be.charCodeAt(Ie+1)===Q&&(this.i=Ie+2),this.line++,this.column=0,this.positionAtNewLine=this.position,v;default:return this.fail("disallowed character."),Me}}if(Me>56319)return Me>=57344&&Me<=65533||this.fail("disallowed character."),Me;const it=65536+(Me-55296)*1024+(be.charCodeAt(Ie+1)-56320);return this.i=Ie+2,it>1114111&&this.fail("disallowed character."),it}getCode11(){const{chunk:be,i:Ie}=this;if(this.prevI=Ie,this.i=Ie+1,Ie>=be.length)return m;const Me=be.charCodeAt(Ie);if(this.column++,Me<55296){if(Me>31&&Me<127||Me>159&&Me!==ut||Me===F)return Me;switch(Me){case Q:return this.line++,this.column=0,this.positionAtNewLine=this.position,Q;case te:{const at=be.charCodeAt(Ie+1);(at===Q||at===lt)&&(this.i=Ie+2)}case lt:case ut:return this.line++,this.column=0,this.positionAtNewLine=this.position,v;default:return this.fail("disallowed character."),Me}}if(Me>56319)return Me>=57344&&Me<=65533||this.fail("disallowed character."),Me;const it=65536+(Me-55296)*1024+(be.charCodeAt(Ie+1)-56320);return this.i=Ie+2,it>1114111&&this.fail("disallowed character."),it}getCodeNorm(){const be=this.getCode();return be===v?Q:be}unget(){this.i=this.prevI,this.column--}captureTo(be){let{i:Ie}=this;const{chunk:Me}=this;for(;;){const it=this.getCode(),at=it===v,Tt=at?Q:it;if(Tt===m||be.includes(Tt))return this.text+=Me.slice(Ie,this.prevI),Tt;at&&(this.text+=`${Me.slice(Ie,this.prevI)} +`,Ie=this.i)}}captureToChar(be){let{i:Ie}=this;const{chunk:Me}=this;for(;;){let it=this.getCode();switch(it){case v:this.text+=`${Me.slice(Ie,this.prevI)} +`,Ie=this.i,it=Q;break;case m:return this.text+=Me.slice(Ie),!1}if(it===be)return this.text+=Me.slice(Ie,this.prevI),!0}}captureNameChars(){const{chunk:be,i:Ie}=this;for(;;){const Me=this.getCode();if(Me===m)return this.name+=be.slice(Ie),m;if(!a(Me))return this.name+=be.slice(Ie,this.prevI),Me===v?Q:Me}}skipSpaces(){for(;;){const be=this.getCodeNorm();if(be===m||!s(be))return be}}setXMLVersion(be){this.currentXMLVersion=be,be==="1.0"?(this.isChar=n,this.getCode=this.getCode10):(this.isChar=c,this.getCode=this.getCode11)}sBegin(){this.chunk.charCodeAt(0)===65279&&(this.i++,this.column++),this.state=w}sBeginWhitespace(){const be=this.i,Ie=this.skipSpaces();switch(this.prevI!==be&&(this.xmlDeclPossible=!1),Ie){case Se:if(this.state=X,this.text.length!==0)throw new Error("no-empty text at start");break;case m:break;default:this.unget(),this.state=$,this.xmlDeclPossible=!1}}sDoctype(){var be;const Ie=this.captureTo(ee);switch(Ie){case je:{(be=this.doctypeHandler)===null||be===void 0||be.call(this,this.text),this.text="",this.state=$,this.doctype=!0;break}case m:break;default:this.text+=String.fromCodePoint(Ie),Ie===Ge?this.state=D:oe(Ie)&&(this.state=A,this.q=Ie)}}sDoctypeQuote(){const be=this.q;this.captureToChar(be)&&(this.text+=String.fromCodePoint(be),this.q=null,this.state=S)}sDTD(){const be=this.captureTo(ye);be!==m&&(this.text+=String.fromCodePoint(be),be===tt?this.state=S:be===Se?this.state=O:oe(be)&&(this.state=L,this.q=be))}sDTDQuoted(){const be=this.q;this.captureToChar(be)&&(this.text+=String.fromCodePoint(be),this.state=D,this.q=null)}sDTDOpenWaka(){const be=this.getCodeNorm();switch(this.text+=String.fromCodePoint(be),be){case Oe:this.state=E,this.openWakaBang="";break;case He:this.state=j;break;default:this.state=D}}sDTDOpenWakaBang(){const be=String.fromCodePoint(this.getCodeNorm()),Ie=this.openWakaBang+=be;this.text+=be,Ie!=="-"&&(this.state=Ie==="--"?P:D,this.openWakaBang="")}sDTDComment(){this.captureToChar(pe)&&(this.text+="-",this.state=M)}sDTDCommentEnding(){const be=this.getCodeNorm();this.text+=String.fromCodePoint(be),this.state=be===pe?U:P}sDTDCommentEnded(){const be=this.getCodeNorm();this.text+=String.fromCodePoint(be),be===je?this.state=D:(this.fail("malformed comment."),this.state=P)}sDTDPI(){this.captureToChar(He)&&(this.text+="?",this.state=q)}sDTDPIEnding(){const be=this.getCodeNorm();this.text+=String.fromCodePoint(be),be===je&&(this.state=D)}sText(){this.tags.length!==0?this.handleTextInRoot():this.handleTextOutsideRoot()}sEntity(){let{i:be}=this;const{chunk:Ie}=this;e:for(;;)switch(this.getCode()){case v:this.entity+=`${Ie.slice(be,this.prevI)} +`,be=this.i;break;case W:{const{entityReturnState:Me}=this,it=this.entity+Ie.slice(be,this.prevI);this.state=Me;let at;it===""?(this.fail("empty entity name."),at="&;"):(at=this.parseEntity(it),this.entity=""),(Me!==$||this.textHandler!==void 0)&&(this.text+=at);break e}case m:this.entity+=Ie.slice(be);break e}}sOpenWaka(){const be=this.getCode();if(r(be))this.state=V,this.unget(),this.xmlDeclPossible=!1;else switch(be){case we:this.state=qe,this.xmlDeclPossible=!1;break;case Oe:this.state=le,this.openWakaBang="",this.xmlDeclPossible=!1;break;case He:this.state=De;break;default:this.fail("disallowed character in tag name"),this.state=$,this.xmlDeclPossible=!1}}sOpenWakaBang(){switch(this.openWakaBang+=String.fromCodePoint(this.getCodeNorm()),this.openWakaBang){case"[CDATA[":!this.sawRoot&&!this.reportedTextBeforeRoot&&(this.fail("text data outside of root node."),this.reportedTextBeforeRoot=!0),this.closedRoot&&!this.reportedTextAfterRoot&&(this.fail("text data outside of root node."),this.reportedTextAfterRoot=!0),this.state=ie,this.openWakaBang="";break;case"--":this.state=K,this.openWakaBang="";break;case"DOCTYPE":this.state=S,(this.doctype||this.sawRoot)&&this.fail("inappropriately located doctype declaration."),this.openWakaBang="";break;default:this.openWakaBang.length>=7&&this.fail("incorrect syntax.")}}sComment(){this.captureToChar(pe)&&(this.state=he)}sCommentEnding(){var be;const Ie=this.getCodeNorm();Ie===pe?(this.state=Re,(be=this.commentHandler)===null||be===void 0||be.call(this,this.text),this.text=""):(this.text+=`-${String.fromCodePoint(Ie)}`,this.state=K)}sCommentEnded(){const be=this.getCodeNorm();be!==je?(this.fail("malformed comment."),this.text+=`--${String.fromCodePoint(be)}`,this.state=K):this.state=$}sCData(){this.captureToChar(tt)&&(this.state=ae)}sCDataEnding(){const be=this.getCodeNorm();be===tt?this.state=Ee:(this.text+=`]${String.fromCodePoint(be)}`,this.state=ie)}sCDataEnding2(){var be;const Ie=this.getCodeNorm();switch(Ie){case je:{(be=this.cdataHandler)===null||be===void 0||be.call(this,this.text),this.text="",this.state=$;break}case tt:this.text+="]";break;default:this.text+=`]]${String.fromCodePoint(Ie)}`,this.state=ie}}sPIFirstChar(){const be=this.getCodeNorm();this.nameStartCheck(be)?(this.piTarget+=String.fromCodePoint(be),this.state=ge):be===He||s(be)?(this.fail("processing instruction without a target."),this.state=be===He?fe:de):(this.fail("disallowed character in processing instruction name."),this.piTarget+=String.fromCodePoint(be),this.state=ge)}sPIRest(){const{chunk:be,i:Ie}=this;for(;;){const Me=this.getCodeNorm();if(Me===m){this.piTarget+=be.slice(Ie);return}if(!this.nameCheck(Me)){this.piTarget+=be.slice(Ie,this.prevI);const it=Me===He;it||s(Me)?this.piTarget==="xml"?(this.xmlDeclPossible||this.fail("an XML declaration must be at the start of the document."),this.state=it?k:H):this.state=it?fe:de:(this.fail("disallowed character in processing instruction name."),this.piTarget+=String.fromCodePoint(Me));break}}}sPIBody(){if(this.text.length===0){const be=this.getCodeNorm();be===He?this.state=fe:s(be)||(this.text=String.fromCodePoint(be))}else this.captureToChar(He)&&(this.state=fe)}sPIEnding(){var be;const Ie=this.getCodeNorm();if(Ie===je){const{piTarget:Me}=this;Me.toLowerCase()==="xml"&&this.fail("the XML declaration must appear at the start of the document."),(be=this.piHandler)===null||be===void 0||be.call(this,{target:Me,body:this.text}),this.piTarget=this.text="",this.state=$}else Ie===He?this.text+="?":(this.text+=`?${String.fromCodePoint(Ie)}`,this.state=de);this.xmlDeclPossible=!1}sXMLDeclNameStart(){const be=this.skipSpaces();if(be===He){this.state=k;return}be!==m&&(this.state=N,this.name=String.fromCodePoint(be))}sXMLDeclName(){const be=this.captureTo(Pe);if(be===He){this.state=k,this.name+=this.text,this.text="",this.fail("XML declaration is incomplete.");return}if(s(be)||be===Ae){if(this.name+=this.text,this.text="",!this.xmlDeclExpects.includes(this.name))switch(this.name.length){case 0:this.fail("did not expect any more name/value pairs.");break;case 1:this.fail(`expected the name ${this.xmlDeclExpects[0]}.`);break;default:this.fail(`expected one of ${this.xmlDeclExpects.join(", ")}`)}this.state=be===Ae?T:R}}sXMLDeclEq(){const be=this.getCodeNorm();if(be===He){this.state=k,this.fail("XML declaration is incomplete.");return}s(be)||(be!==Ae&&this.fail("value required."),this.state=T)}sXMLDeclValueStart(){const be=this.getCodeNorm();if(be===He){this.state=k,this.fail("XML declaration is incomplete.");return}s(be)||(oe(be)?this.q=be:(this.fail("value must be quoted."),this.q=me),this.state=x)}sXMLDeclValue(){const be=this.captureTo([this.q,He]);if(be===He){this.state=k,this.text="",this.fail("XML declaration is incomplete.");return}if(be===m)return;const Ie=this.text;switch(this.text="",this.name){case"version":{this.xmlDeclExpects=["encoding","standalone"];const Me=Ie;this.xmlDecl.version=Me,/^1\.[0-9]+$/.test(Me)?this.opt.forceXMLVersion||this.setXMLVersion(Me):this.fail("version number must match /^1\\.[0-9]+$/.");break}case"encoding":/^[A-Za-z][A-Za-z0-9._-]*$/.test(Ie)||this.fail("encoding value must match /^[A-Za-z0-9][A-Za-z0-9._-]*$/."),this.xmlDeclExpects=["standalone"],this.xmlDecl.encoding=Ie;break;case"standalone":Ie!=="yes"&&Ie!=="no"&&this.fail('standalone value must match "yes" or "no".'),this.xmlDeclExpects=[],this.xmlDecl.standalone=Ie;break}this.name="",this.state=B}sXMLDeclSeparator(){const be=this.getCodeNorm();if(be===He){this.state=k;return}s(be)||(this.fail("whitespace required."),this.unget()),this.state=H}sXMLDeclEnding(){var be;this.getCodeNorm()===je?(this.piTarget!=="xml"?this.fail("processing instructions are not allowed before root."):this.name!=="version"&&this.xmlDeclExpects.includes("version")&&this.fail("XML declaration must contain a version."),(be=this.xmldeclHandler)===null||be===void 0||be.call(this,this.xmlDecl),this.name="",this.piTarget=this.text="",this.state=$):this.fail("The character ? is disallowed anywhere in XML declarations."),this.xmlDeclPossible=!1}sOpenTag(){var be;const Ie=this.captureNameChars();if(Ie===m)return;const Me=this.tag={name:this.name,attributes:Object.create(null)};switch(this.name="",this.xmlnsOpt&&(this.topNS=Me.ns=Object.create(null)),(be=this.openTagStartHandler)===null||be===void 0||be.call(this,Me),this.sawRoot=!0,!this.fragmentOpt&&this.closedRoot&&this.fail("documents may contain only one root."),Ie){case je:this.openTag();break;case we:this.state=J;break;default:s(Ie)||this.fail("disallowed character in tag name."),this.state=z}}sOpenTagSlash(){this.getCode()===je?this.openSelfClosingTag():(this.fail("forward-slash in opening tag not followed by >."),this.state=z)}sAttrib(){const be=this.skipSpaces();be!==m&&(r(be)?(this.unget(),this.state=Y):be===je?this.openTag():be===we?this.state=J:this.fail("disallowed character in attribute name."))}sAttribName(){const be=this.captureNameChars();be===Ae?this.state=ce:s(be)?this.state=re:be===je?(this.fail("attribute without value."),this.pushAttrib(this.name,this.name),this.name=this.text="",this.openTag()):be!==m&&this.fail("disallowed character in attribute name.")}sAttribNameSawWhite(){const be=this.skipSpaces();switch(be){case m:return;case Ae:this.state=ce;break;default:this.fail("attribute without value."),this.text="",this.name="",be===je?this.openTag():r(be)?(this.unget(),this.state=Y):(this.fail("disallowed character in attribute name."),this.state=z)}}sAttribValue(){const be=this.getCodeNorm();oe(be)?(this.q=be,this.state=Te):s(be)||(this.fail("unquoted attribute value."),this.state=Le,this.unget())}sAttribValueQuoted(){const{q:be,chunk:Ie}=this;let{i:Me}=this;for(;;)switch(this.getCode()){case be:this.pushAttrib(this.name,this.text+Ie.slice(Me,this.prevI)),this.name=this.text="",this.q=null,this.state=xe;return;case We:this.text+=Ie.slice(Me,this.prevI),this.state=Z,this.entityReturnState=Te;return;case Q:case v:case F:this.text+=`${Ie.slice(Me,this.prevI)} `,Me=this.i;break;case Se:this.text+=Ie.slice(Me,this.prevI),this.fail("disallowed character.");return;case m:this.text+=Ie.slice(Me);return}}sAttribValueClosed(){const be=this.getCodeNorm();s(be)?this.state=z:be===je?this.openTag():be===we?this.state=J:r(be)?(this.fail("no whitespace between attributes."),this.unget(),this.state=Y):this.fail("disallowed character in attribute name.")}sAttribValueUnquoted(){const be=this.captureTo(Ue);switch(be){case We:this.state=Z,this.entityReturnState=Le;break;case Se:this.fail("disallowed character.");break;case m:break;default:this.text.includes("]]>")&&this.fail('the string "]]>" is disallowed in char data.'),this.pushAttrib(this.name,this.text),this.name=this.text="",be===je?this.openTag():this.state=z}}sCloseTag(){const be=this.captureNameChars();be===je?this.closeTag():s(be)?this.state=G:be!==m&&this.fail("disallowed character in closing tag.")}sCloseTagSawWhite(){switch(this.skipSpaces()){case je:this.closeTag();break;case m:break;default:this.fail("disallowed character in closing tag.")}}handleTextInRoot(){let{i:be,forbiddenState:Ie}=this;const{chunk:Me,textHandler:it}=this;e:for(;;)switch(this.getCode()){case Se:{if(this.state=X,it!==void 0){const{text:at}=this,Tt=Me.slice(be,this.prevI);at.length!==0?(it(at+Tt),this.text=""):Tt.length!==0&&it(Tt)}Ie=nt;break e}case We:this.state=Z,this.entityReturnState=$,it!==void 0&&(this.text+=Me.slice(be,this.prevI)),Ie=nt;break e;case tt:switch(Ie){case nt:Ie=yt;break;case yt:Ie=ft;break;case ft:break;default:throw new Error("impossible state")}break;case je:Ie===ft&&this.fail('the string "]]>" is disallowed in char data.'),Ie=nt;break;case v:it!==void 0&&(this.text+=`${Me.slice(be,this.prevI)} +`),be=this.i,Ie=nt;break;case m:it!==void 0&&(this.text+=Me.slice(be));break e;default:Ie=nt}this.forbiddenState=Ie}handleTextOutsideRoot(){let{i:be}=this;const{chunk:Ie,textHandler:Me}=this;let it=!1;e:for(;;){const at=this.getCode();switch(at){case Se:{if(this.state=X,Me!==void 0){const{text:Tt}=this,Vt=Ie.slice(be,this.prevI);Tt.length!==0?(Me(Tt+Vt),this.text=""):Vt.length!==0&&Me(Vt)}break e}case We:this.state=Z,this.entityReturnState=$,Me!==void 0&&(this.text+=Ie.slice(be,this.prevI)),it=!0;break e;case v:Me!==void 0&&(this.text+=`${Ie.slice(be,this.prevI)} +`),be=this.i;break;case m:Me!==void 0&&(this.text+=Ie.slice(be));break e;default:s(at)||(it=!0)}}it&&(!this.sawRoot&&!this.reportedTextBeforeRoot&&(this.fail("text data outside of root node."),this.reportedTextBeforeRoot=!0),this.closedRoot&&!this.reportedTextAfterRoot&&(this.fail("text data outside of root node."),this.reportedTextAfterRoot=!0))}pushAttribNS(be,Ie){var Me;const{prefix:it,local:at}=this.qname(be),Tt={name:be,prefix:it,local:at,value:Ie};if(this.attribList.push(Tt),(Me=this.attributeHandler)===null||Me===void 0||Me.call(this,Tt),it==="xmlns"){const Vt=Ie.trim();this.currentXMLVersion==="1.0"&&Vt===""&&this.fail("invalid attempt to undefine prefix in XML 1.0"),this.topNS[at]=Vt,Fe(this,at,Vt)}else if(be==="xmlns"){const Vt=Ie.trim();this.topNS[""]=Vt,Fe(this,"",Vt)}}pushAttribPlain(be,Ie){var Me;const it={name:be,value:Ie};this.attribList.push(it),(Me=this.attributeHandler)===null||Me===void 0||Me.call(this,it)}end(){var be,Ie;this.sawRoot||this.fail("document must contain a root element.");const{tags:Me}=this;for(;Me.length>0;){const at=Me.pop();this.fail(`unclosed tag: ${at.name}`)}this.state!==_&&this.state!==$&&this.fail("unexpected end.");const{text:it}=this;return it.length!==0&&((be=this.textHandler)===null||be===void 0||be.call(this,it),this.text=""),this._closed=!0,(Ie=this.endHandler)===null||Ie===void 0||Ie.call(this),this._init(),this}resolve(be){var Ie,Me;let it=this.topNS[be];if(it!==void 0)return it;const{tags:at}=this;for(let Tt=at.length-1;Tt>=0;Tt--)if(it=at[Tt].ns[be],it!==void 0)return it;return it=this.ns[be],it!==void 0?it:(Me=(Ie=this.opt).resolvePrefix)===null||Me===void 0?void 0:Me.call(Ie,be)}qname(be){const Ie=be.indexOf(":");if(Ie===-1)return{prefix:"",local:be};const Me=be.slice(Ie+1),it=be.slice(0,Ie);return(it===""||Me===""||Me.includes(":"))&&this.fail(`malformed name: ${be}.`),{prefix:it,local:Me}}processAttribsNS(){var be;const{attribList:Ie}=this,Me=this.tag;{const{prefix:Tt,local:Vt}=this.qname(Me.name);Me.prefix=Tt,Me.local=Vt;const rr=Me.uri=(be=this.resolve(Tt))!==null&&be!==void 0?be:"";Tt!==""&&(Tt==="xmlns"&&this.fail('tags may not have "xmlns" as prefix.'),rr===""&&(this.fail(`unbound namespace prefix: ${JSON.stringify(Tt)}.`),Me.uri=Tt))}if(Ie.length===0)return;const{attributes:it}=Me,at=new Set;for(const Tt of Ie){const{name:Vt,prefix:rr,local:fi}=Tt;let bn,or;rr===""?(bn=Vt==="xmlns"?y:"",or=Vt):(bn=this.resolve(rr),bn===void 0&&(this.fail(`unbound namespace prefix: ${JSON.stringify(rr)}.`),bn=rr),or=`{${bn}}${fi}`),at.has(or)&&this.fail(`duplicate attribute: ${or}.`),at.add(or),Tt.uri=bn,it[Vt]=Tt}this.attribList=[]}processAttribsPlain(){const{attribList:be}=this,Ie=this.tag.attributes;for(const{name:Me,value:it}of be)Ie[Me]!==void 0&&this.fail(`duplicate attribute: ${Me}.`),Ie[Me]=it;this.attribList=[]}openTag(){var be;this.processAttribs();const{tags:Ie}=this,Me=this.tag;Me.isSelfClosing=!1,(be=this.openTagHandler)===null||be===void 0||be.call(this,Me),Ie.push(Me),this.state=$,this.name=""}openSelfClosingTag(){var be,Ie,Me;this.processAttribs();const{tags:it}=this,at=this.tag;at.isSelfClosing=!0,(be=this.openTagHandler)===null||be===void 0||be.call(this,at),(Ie=this.closeTagHandler)===null||Ie===void 0||Ie.call(this,at),(this.tag=(Me=it[it.length-1])!==null&&Me!==void 0?Me:null)===null&&(this.closedRoot=!0),this.state=$,this.name=""}closeTag(){const{tags:be,name:Ie}=this;if(this.state=$,this.name="",Ie===""){this.fail("weird empty close tag."),this.text+="";return}const Me=this.closeTagHandler;let it=be.length;for(;it-- >0;){const at=this.tag=be.pop();if(this.topNS=at.ns,Me==null||Me(at),at.name===Ie)break;this.fail("unexpected close tag.")}it===0?this.closedRoot=!0:it<0&&(this.fail(`unmatched closing tag: ${Ie}.`),this.text+=``)}parseEntity(be){if(be[0]!=="#"){const Me=this.ENTITIES[be];return Me!==void 0?Me:(this.fail(this.isName(be)?"undefined entity.":"disallowed character in entity name."),`&${be};`)}let Ie=NaN;return be[1]==="x"&&/^#x[0-9a-f]+$/i.test(be)?Ie=parseInt(be.slice(2),16):/^#[0-9]+$/.test(be)&&(Ie=parseInt(be.slice(1),10)),this.isChar(Ie)?String.fromCodePoint(Ie):(this.fail("malformed character entity."),`&${be};`)}}return As.SaxesParser=Ir,As}var Ll={},CD;function DJ(){if(CD)return Ll;CD=1,Object.defineProperty(Ll,"__esModule",{value:!0}),Ll.ParseError=void 0;let t=class extends Error{constructor(u,s){const n=u.saxParser;super(u.trackPosition?`Line ${n.line} column ${n.column+1}: ${s}`:s)}};return Ll.ParseError=t,Ll}var Lv={},Mv={},jD;function NJ(){return jD||(jD=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.validateIri=t.IriValidationStrategy=void 0;function e(){const o="[!$&'()*+,;=]",l="%[a-fA-F0-9]{2}",c="([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])",d=`${c}\\.${c}\\.${c}\\.${c}`,h="[a-fA-F0-9]{1,4}",f=`(${h}:${h}|${d})`,p=`((${h}:){6}${f}|::(${h}:){5}${f}|(${h})?::(${h}:){4}${f}|((${h}:){0,1}${h})?::(${h}:){3}${f}|((${h}:){0,2}${h})?::(${h}:){2}${f}|((${h}:){0,3}${h})?::${h}:${f}|((${h}:){0,4}${h})?::${f}|((${h}:){0,5}${h})?::${h}|((${h}:){0,6}${h})?::)`,y=`v[a-fA-F0-9]+\\.(${o}|${o}|":)+`,b=`\\[(${p}|${y})\\]`,g="[0-9]*",m="[a-zA-Z][a-zA-Z0-9+\\-.]*",_="[-󰀀-󿿽􀀀-􏿽]",A="[a-zA-Z0-9\\-._~ -퟿豈-﷏ﷰ-￯𐀀-🿽𠀀-𯿽𰀀-𿿽񀀀-񏿽񐀀-񟿽񠀀-񯿽񰀀-񿿽򀀀-򏿽򐀀-򟿽򠀀-򯿽򰀀-򿿽󀀀-󏿽󐀀-󟿽󡀀-󯿽]",D=`(${A}|${l}|${o}|[:@])*`,L=`(${D}|[\\/?])*`,O=`(${D}|${_}|[\\/?])*`,E=`(${D})+`,P=`(${D})*`,M="",U=`${E}(\\/${P})*`,j=`\\/(${E}(\\/${P})*)?`,q=`(\\/${P})*`,$=`(${A}|${l}|${o})*`,Z=`(${b}|${d}|${$})`,K=`(\\/\\/${`(${`(${A}|${l}|${o}|:)*`}@)?${Z}(:${g})?`}${q}|${j}|${U}|${M})`,he=`^${m}:${K}(\\?${O})?(#${L})?$`;return new RegExp(he,"u")}const u=e(),s=/^[A-Za-z][\d+-.A-Za-z]*:[^\u0000-\u0020"<>\\^`{|}]*$/u;var n;(function(a){a.Strict="strict",a.Pragmatic="pragmatic",a.None="none"})(n=t.IriValidationStrategy||(t.IriValidationStrategy={}));function r(a,o=n.Strict){switch(o){case n.Strict:return u.test(a)?void 0:new Error(`Invalid IRI according to RFC 3987: '${a}'`);case n.Pragmatic:return s.test(a)?void 0:new Error(`Invalid IRI according to RDF Turtle: '${a}'`);case n.None:return;default:return new Error(`Not supported validation strategy "${o}"`)}}t.validateIri=r}(Mv)),Mv}var LD;function CJ(){return LD||(LD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(NJ(),t)}(Lv)),Lv}var MD;function jJ(){if(MD)return Ts;MD=1,Object.defineProperty(Ts,"__esModule",{value:!0}),Ts.ParseType=Ts.RdfXmlParser=void 0;const t=Pi(),e=o7(),u=Wt(),s=DJ(),n=Et(),r=CJ();let a=class Tr extends u.Transform{constructor(c){super({readableObjectMode:!0}),this.activeTagStack=[],this.nodeIds={},c&&(Object.assign(this,c),this.options=c),this.dataFactory||(this.dataFactory=new n.DataFactory),this.baseIRI||(this.baseIRI=""),this.defaultGraph||(this.defaultGraph=this.dataFactory.defaultGraph()),this.validateUri!==!1&&(this.validateUri=!0),this.iriValidationStrategy||(this.iriValidationStrategy=this.validateUri?r.IriValidationStrategy.Pragmatic:r.IriValidationStrategy.None),this.saxParser=new e.SaxesParser({xmlns:!0,position:this.trackPosition}),this.attachSaxListeners()}import(c){const d=new u.PassThrough({readableObjectMode:!0});c.on("error",f=>h.emit("error",f)),c.on("data",f=>d.push(f)),c.on("end",()=>d.push(null));const h=d.pipe(new Tr(this.options));return h}_transform(c,d,h){try{this.saxParser.write(c)}catch(f){return h(f)}h()}newParseError(c){return new s.ParseError(this,c)}valueToUri(c,d){return this.uriToNamedNode((0,t.resolve)(c,d.baseIRI))}uriToNamedNode(c){const d=(0,r.validateIri)(c,this.iriValidationStrategy);if(d instanceof Error)throw this.newParseError(d.message);return this.dataFactory.namedNode(c)}validateNcname(c){if(!Tr.NCNAME_MATCHER.test(c))throw this.newParseError(`Not a valid NCName: ${c}`)}attachSaxListeners(){this.saxParser.on("error",c=>this.emit("error",c)),this.saxParser.on("opentag",this.onTag.bind(this)),this.saxParser.on("text",this.onText.bind(this)),this.saxParser.on("cdata",this.onText.bind(this)),this.saxParser.on("closetag",this.onCloseTag.bind(this)),this.saxParser.on("doctype",this.onDoctype.bind(this))}onTag(c){const d=this.activeTagStack.length?this.activeTagStack[this.activeTagStack.length-1]:null;let h=o.RESOURCE;if(d&&(d.hadChildren=!0,h=d.childrenParseType),d&&d.childrenStringTags){const p=c.name;let y="";for(const v in c.attributes)y+=` ${v}="${c.attributes[v].value}"`;const g=`<${`${p}${y}`}>`;d.childrenStringTags.push(g);const m={childrenStringTags:d.childrenStringTags};m.childrenStringEmitClosingTag=``,this.activeTagStack.push(m);return}const f={};d?(f.language=d.language,f.baseIRI=d.baseIRI):f.baseIRI=this.baseIRI,this.activeTagStack.push(f),h===o.RESOURCE?this.onTagResource(c,f,d,!d):this.onTagProperty(c,f,d)}onTagResource(c,d,h,f){d.childrenParseType=o.PROPERTY;let p=!0;if(c.uri===Tr.RDF){if(!f&&Tr.FORBIDDEN_NODE_ELEMENTS.indexOf(c.local)>=0)throw this.newParseError(`Illegal node element name: ${c.local}`);switch(c.local){case"RDF":d.childrenParseType=o.RESOURCE;case"Description":p=!1}}const y=[],b=[];let g=null,m=!1,v=!1,_=null;for(const w in c.attributes){const S=c.attributes[w];if(h&&S.uri===Tr.RDF)switch(S.local){case"about":if(g)throw this.newParseError(`Only one of rdf:about, rdf:nodeID and rdf:ID can be present, while ${S.value} and ${g} where found.`);g=S.value;continue;case"ID":if(g)throw this.newParseError(`Only one of rdf:about, rdf:nodeID and rdf:ID can be present, while ${S.value} and ${g} where found.`);this.validateNcname(S.value),g="#"+S.value,m=!0;continue;case"nodeID":if(g)throw this.newParseError(`Only one of rdf:about, rdf:nodeID and rdf:ID can be present, while ${S.value} and ${g} where found.`);this.validateNcname(S.value),g=S.value,v=!0;continue;case"bagID":throw this.newParseError("rdf:bagID is not supported.");case"type":_=S.value;continue;case"aboutEach":throw this.newParseError("rdf:aboutEach is not supported.");case"aboutEachPrefix":throw this.newParseError("rdf:aboutEachPrefix is not supported.");case"li":throw this.newParseError("rdf:li on node elements are not supported.")}else if(S.uri===Tr.XML){if(S.local==="lang"){d.language=S.value===""?null:S.value.toLowerCase();continue}else if(S.local==="base"){d.baseIRI=(0,t.resolve)(S.value,d.baseIRI);continue}}S.prefix!=="xml"&&S.prefix!=="xmlns"&&(S.prefix!==""||S.local!=="xmlns")&&S.uri&&(y.push(this.uriToNamedNode(S.uri+S.local)),b.push(S.value))}if(g!==null&&(d.subject=v?this.dataFactory.blankNode(g):this.valueToUri(g,d),m&&this.claimNodeId(d.subject)),d.subject||(d.subject=this.dataFactory.blankNode()),p){const w=this.uriToNamedNode(c.uri+c.local);this.emitTriple(d.subject,this.dataFactory.namedNode(Tr.RDF+"type"),w,h?h.reifiedStatementId:null)}if(h){if(h.predicate)if(h.childrenCollectionSubject){const w=this.dataFactory.blankNode();this.emitTriple(h.childrenCollectionSubject,h.childrenCollectionPredicate,w,h.reifiedStatementId),this.emitTriple(w,this.dataFactory.namedNode(Tr.RDF+"first"),d.subject,d.reifiedStatementId),h.childrenCollectionSubject=w,h.childrenCollectionPredicate=this.dataFactory.namedNode(Tr.RDF+"rest")}else{this.emitTriple(h.subject,h.predicate,d.subject,h.reifiedStatementId);for(let w=0;w=0)throw this.newParseError(`Illegal property element name: ${c.local}`);d.predicateSubPredicates=[],d.predicateSubObjects=[];let f=!1,p=!1,y=null,b=!0;const g=[],m=[];for(const v in c.attributes){const _=c.attributes[v];if(_.uri===Tr.RDF)switch(_.local){case"resource":if(y)throw this.newParseError(`Found both rdf:resource (${_.value}) and rdf:nodeID (${y}).`);if(f)throw this.newParseError(`rdf:parseType is not allowed on property elements with rdf:resource (${_.value})`);d.hadChildren=!0,y=_.value,b=!1;continue;case"datatype":if(p)throw this.newParseError(`Found both non-rdf:* property attributes and rdf:datatype (${_.value}).`);if(f)throw this.newParseError(`rdf:parseType is not allowed on property elements with rdf:datatype (${_.value})`);d.datatype=this.valueToUri(_.value,d);continue;case"nodeID":if(p)throw this.newParseError(`Found both non-rdf:* property attributes and rdf:nodeID (${_.value}).`);if(d.hadChildren)throw this.newParseError(`Found both rdf:resource and rdf:nodeID (${_.value}).`);if(f)throw this.newParseError(`rdf:parseType is not allowed on property elements with rdf:nodeID (${_.value})`);this.validateNcname(_.value),d.hadChildren=!0,y=_.value,b=!0;continue;case"bagID":throw this.newParseError("rdf:bagID is not supported.");case"parseType":if(p)throw this.newParseError("rdf:parseType is not allowed when non-rdf:* property attributes are present");if(d.datatype)throw this.newParseError(`rdf:parseType is not allowed on property elements with rdf:datatype (${d.datatype.value})`);if(y)throw this.newParseError(`rdf:parseType is not allowed on property elements with rdf:nodeID or rdf:resource (${y})`);if(_.value==="Resource"){f=!0,d.childrenParseType=o.PROPERTY;const w=this.dataFactory.blankNode();this.emitTriple(d.subject,d.predicate,w,d.reifiedStatementId),d.subject=w,d.predicate=null}else _.value==="Collection"?(f=!0,d.hadChildren=!0,d.childrenCollectionSubject=d.subject,d.childrenCollectionPredicate=d.predicate,b=!1):_.value==="Literal"&&(f=!0,d.childrenTagsToString=!0,d.childrenStringTags=[]);continue;case"ID":this.validateNcname(_.value),d.reifiedStatementId=this.valueToUri("#"+_.value,d),this.claimNodeId(d.reifiedStatementId);continue}else if(_.uri===Tr.XML&&_.local==="lang"){d.language=_.value===""?null:_.value.toLowerCase();continue}if(_.prefix!=="xml"&&_.prefix!=="xmlns"&&(_.prefix!==""||_.local!=="xmlns")&&_.uri){if(f||d.datatype)throw this.newParseError(`Found illegal rdf:* properties on property element with attribute: ${_.value}`);d.hadChildren=!0,p=!0,g.push(this.uriToNamedNode(_.uri+_.local)),m.push(this.dataFactory.literal(_.value,d.datatype||d.language))}}if(y!==null){const v=d.subject;d.subject=b?this.dataFactory.blankNode(y):this.valueToUri(y,d),this.emitTriple(v,d.predicate,d.subject,d.reifiedStatementId);for(let _=0;_/g,(d,h,f)=>(this.saxParser.ENTITIES[h]=f,""))}};Ts.RdfXmlParser=a,a.MIME_TYPE="application/rdf+xml",a.RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#",a.XML="http://www.w3.org/XML/1998/namespace",a.FORBIDDEN_NODE_ELEMENTS=["RDF","ID","about","bagID","parseType","resource","nodeID","li","aboutEach","aboutEachPrefix"],a.FORBIDDEN_PROPERTY_ELEMENTS=["Description","RDF","ID","about","bagID","parseType","resource","nodeID","aboutEach","aboutEachPrefix"],a.NCNAME_MATCHER=/^([A-Za-z\xC0-\xD6\xD8-\xF6\u{F8}-\u{2FF}\u{370}-\u{37D}\u{37F}-\u{1FFF}\u{200C}-\u{200D}\u{2070}-\u{218F}\u{2C00}-\u{2FEF}\u{3001}-\u{D7FF}\u{F900}-\u{FDCF}\u{FDF0}-\u{FFFD}\u{10000}-\u{EFFFF}_])([A-Za-z\xC0-\xD6\xD8-\xF6\u{F8}-\u{2FF}\u{370}-\u{37D}\u{37F}-\u{1FFF}\u{200C}-\u{200D}\u{2070}-\u{218F}\u{2C00}-\u{2FEF}\u{3001}-\u{D7FF}\u{F900}-\u{FDCF}\u{FDF0}-\u{FFFD}\u{10000}-\u{EFFFF}_\-.0-9#xB7\u{0300}-\u{036F}\u{203F}-\u{2040}])*$/u;var o;return function(l){l[l.RESOURCE=0]="RESOURCE",l[l.PROPERTY=1]="PROPERTY"}(o||(Ts.ParseType=o={})),Ts}var FD;function LJ(){return FD||(FD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(jJ(),t)}(Dv)),Dv}var qD;function MJ(){if(qD)return jl;qD=1,Object.defineProperty(jl,"__esModule",{value:!0}),jl.ActorRdfParseRdfXml=void 0;const t=su(),e=LJ();let u=class extends t.ActorRdfParseFixedMediaTypes{constructor(n){super(n)}async runHandle(n){var a;n.data.on("error",o=>r.emit("error",o));const r=n.data.pipe(new e.RdfXmlParser({baseIRI:(a=n.metadata)==null?void 0:a.baseIRI}));return{data:r,metadata:{triples:!0}}}};return jl.ActorRdfParseRdfXml=u,jl}var BD;function FJ(){return BD||(BD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(MJ(),t)}(Pv)),Pv}var Fv={},Ml={},qv={},Bv={},UD;function qJ(){return UD||(UD=1,Object.defineProperty(Bv,"__esModule",{value:!0})),Bv}var Uv={},QD;function BJ(){return QD||(QD=1,Object.defineProperty(Uv,"__esModule",{value:!0})),Uv}var Qv={},HD;function UJ(){return HD||(HD=1,Object.defineProperty(Qv,"__esModule",{value:!0})),Qv}var Fl={},Hv={},ql={},$v={},Vv={},g1={},$D;function QJ(){return $D||($D=1,Object.defineProperty(g1,"__esModule",{value:!0}),g1.default=new Uint16Array('ᵁ<Õıʊҝջאٵ۞ޢߖࠏ੊ઑඡ๭༉༦჊ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ὾⁠↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms„‹•˜¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲ΂ϏϢϸontourIntegraìȹoɴ͹\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՗՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲ׌y;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱cò׋؀JTabcdfgorstר׬ׯ׺؀ؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d׷׸䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇܎ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ޷޼߂ߐĀiyޱ޵rc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄΀HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶߻dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣ঳সে্਷ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗ࡜ࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४Ānrࢃ࢏gleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpw৔ਖਛgȀLRlr৞৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼੝੠੷੼અઋ઎p;椅y;䐜Ādl੥੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑ඗ඞcy;䐊cute;䅃ƀaey઴હાron;䅇dil;䅅;䐝ƀgswે૰଎ativeƀMTV૓૟૨ediumSpace;怋hiĀcn૦૘ë૙eryThiî૙tedĀGL૸ଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷ଺reak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪୼஡௫ఄ౞಄ದ೘ൡඅ櫬Āou୛୤ngruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊ஛ement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater΀;EFGLSTஶஷ஽௉௓௘௥扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲௽ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ೒拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨೹setĀ;E೰ೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂ෉෕ෛ෠෧෼ขภยา฿ไlig;䅒cute耻Ó䃓Āiy෎ීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲ෶cr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬื฼de耻Õ䃕es;樷ml耻Ö䃖erĀBP๋๠Āar๐๓r;怾acĀek๚๜;揞et;掴arenthesis;揜Ҁacfhilors๿ງຊຏຒດຝະ໼rtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ໠໤檻cedesȀ;EST່້໏໚扺qual;檯lantEqual;扼ilde;找me;怳Ādp໩໮uct;戏ortionĀ;aȥ໹l;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬؀BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁࿫࿳ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL࿜࿝࿡憒ar;懥eftArrow;懄eiling;按oǵ࿹\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»࿝pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄ቉ቕ቞ቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHc቎ቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗Āeiቻ኉Dzኀ\0ኇefore;戴a;䎘Ācn኎ኘkSpace;쀀  Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0᏿ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0጖y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻፿on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtè૙a;䎖r;愨pf;愤cr;쀀𝒵௡ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚΀;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒΀;Eaeiop዁ᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;e዁ᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;e዁ᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰ᜼ᝃᝈ᝸᝽០៦ᠹᡐᜍ᤽᥈ᥰot;櫭Ācrᛶ᜞kȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e᜚᜛戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;t፜᜷brk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓ᝛ᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯ᝱ᝳ;䎲;愶een;扬r;쀀𝔟g΀costuvwឍឝឳេ៕៛៞ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀako៭ᠦᠵĀcn៲ᠣkƀlst៺֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘᠝斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈؀DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬ᣿ᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教΀;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ᣷᣹᣻᣽;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ᤟;敛;敘;攘;攔΀;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģ᥂bar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;e᜚᜜lƀ;bhᥨᥩᥫ䁜;槅sub;柈Ŭᥴ᥾lĀ;e᥹᥺怢t»᥺pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭍᭒\0᯽\0ᰌƀcpr᦭ᦲ᧝ute;䄇̀;abcdsᦿᧀᧄ᧊᧕᧙戩nd;橄rcup;橉Āau᧏᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r΀;Ecefms᩟᩠ᩢᩫ᪤᪪᪮旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖᪚᪟»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇᫔᫺\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ᫙\0\0᫢aĀ;t᫞᫟䀬;䁀ƀ;fl᫨᫩᫫戁îᅠeĀmx᫱᫶ent»᫩eóɍǧ᫾\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯΀delprvw᭠᭬᭷ᮂᮬᯔ᯹arrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;p᭿ᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰸᰻᰿ᱝᱩᱵᲊᲞᲬᲷ᳻᳿ᴍᵻᶑᶫᶻ᷆᷍rò΁ar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂͸᳖᳜᳠mƀ;oș᳊᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄ὎὚ĀDoḆᴴoôᲉĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»Ṻƀaeiἒ἖Ἒls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙ῜ῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao‌⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧‪‬\0‮耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₟₥₰₴⃰⃵⃺⃿℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕ₝ute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽⃉ƀ;qsؾٌ⃄lanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqr׮ⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0↎proø₞r;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢␧␭␱␵␻ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀஀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼rò৆òΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonó྘quigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d྘➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ᠛旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐௏쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop඄⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roø඄urĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓΀;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨í஘istĀ;s஠டr;쀀𝔫ȀEest௅⩦⩹⩼ƀ;qs஼⩭௡ƀ;qs஼௅⩴lanô௢ií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚΀AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs఻⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs఻⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast୻⭕⭚⭟lleì୻l;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖ΀chimpqu⮽⯍⯙⬄୸⯤⯯Ȁ;cerല⯆ഷ⯉uå൅;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭å೸åഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñ೗Ā;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰⳴ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥ⵲ⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;c᪞ⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācr⵩⵭ir;榿;쀀𝔬ͯ⵹\0\0⵼\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕ⶘ⶥⶨrò᪀Āir⶝ⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔ⷗ǒr;榷rp;榹΀;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ⹞\0⹽\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ⹧⹲຅脀¶;l⹭⹮䂶leìЃɩ⹸\0\0⹻m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳⻴ᤈ⻹⻽⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp໬⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t໻⾴ï໻rel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⿚⋢⿟⿥⿫⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei⿾々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔઀ABHabcdefhilmnoprstux぀けさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤΀cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstw࿜ガクシスゼゾダッデナp;極Ā;f࿠ゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes㄂㄄;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ì࿲âヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘㇤㇮rrowĀ;t࿜ㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowó࿪arpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓rò࿪aòՑ;怏oustĀ;a㈞㈟掱che»㈟mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦΀Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼਴t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì⹯耻­䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;q኱ኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫ਩war;椪lig耻ß䃟௡㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rë๟ƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproø዁im»ኬsðኞĀas㚺㚮ð዁rn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈ΀adempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xô᝷headĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜΀eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roð໻tré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚΀cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜ៟tré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map(function(t){return t.charCodeAt(0)}))),g1}var _1={},VD;function HJ(){return VD||(VD=1,Object.defineProperty(_1,"__esModule",{value:!0}),_1.default=new Uint16Array("Ȁaglq \x1Bɭ\0\0p;䀦os;䀧t;䀾t;䀼uot;䀢".split("").map(function(t){return t.charCodeAt(0)}))),_1}var kv={},kD;function zD(){return kD||(kD=1,function(t){var e;Object.defineProperty(t,"__esModule",{value:!0}),t.replaceCodePoint=t.fromCodePoint=void 0;var u=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]);t.fromCodePoint=(e=String.fromCodePoint)!==null&&e!==void 0?e:function(r){var a="";return r>65535&&(r-=65536,a+=String.fromCharCode(r>>>10&1023|55296),r=56320|r&1023),a+=String.fromCharCode(r),a};function s(r){var a;return r>=55296&&r<=57343||r>1114111?65533:(a=u.get(r))!==null&&a!==void 0?a:r}t.replaceCodePoint=s;function n(r){return(0,t.fromCodePoint)(s(r))}t.default=n}(kv)),kv}var GD;function Xa(){return GD||(GD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(P,M,U,j){j===void 0&&(j=U);var q=Object.getOwnPropertyDescriptor(M,U);(!q||("get"in q?!M.__esModule:q.writable||q.configurable))&&(q={enumerable:!0,get:function(){return M[U]}}),Object.defineProperty(P,j,q)}:function(P,M,U,j){j===void 0&&(j=U),P[j]=M[U]}),u=I&&I.__setModuleDefault||(Object.create?function(P,M){Object.defineProperty(P,"default",{enumerable:!0,value:M})}:function(P,M){P.default=M}),s=I&&I.__importStar||function(P){if(P&&P.__esModule)return P;var M={};if(P!=null)for(var U in P)U!=="default"&&Object.prototype.hasOwnProperty.call(P,U)&&e(M,P,U);return u(M,P),M},n=I&&I.__importDefault||function(P){return P&&P.__esModule?P:{default:P}};Object.defineProperty(t,"__esModule",{value:!0}),t.decodeXML=t.decodeHTMLStrict=t.decodeHTMLAttribute=t.decodeHTML=t.determineBranch=t.EntityDecoder=t.DecodingMode=t.BinTrieFlags=t.fromCodePoint=t.replaceCodePoint=t.decodeCodePoint=t.xmlDecodeTree=t.htmlDecodeTree=void 0;var r=n(QJ());t.htmlDecodeTree=r.default;var a=n(HJ());t.xmlDecodeTree=a.default;var o=s(zD());t.decodeCodePoint=o.default;var l=zD();Object.defineProperty(t,"replaceCodePoint",{enumerable:!0,get:function(){return l.replaceCodePoint}}),Object.defineProperty(t,"fromCodePoint",{enumerable:!0,get:function(){return l.fromCodePoint}});var c;(function(P){P[P.NUM=35]="NUM",P[P.SEMI=59]="SEMI",P[P.EQUALS=61]="EQUALS",P[P.ZERO=48]="ZERO",P[P.NINE=57]="NINE",P[P.LOWER_A=97]="LOWER_A",P[P.LOWER_F=102]="LOWER_F",P[P.LOWER_X=120]="LOWER_X",P[P.LOWER_Z=122]="LOWER_Z",P[P.UPPER_A=65]="UPPER_A",P[P.UPPER_F=70]="UPPER_F",P[P.UPPER_Z=90]="UPPER_Z"})(c||(c={}));var d=32,h;(function(P){P[P.VALUE_LENGTH=49152]="VALUE_LENGTH",P[P.BRANCH_LENGTH=16256]="BRANCH_LENGTH",P[P.JUMP_TABLE=127]="JUMP_TABLE"})(h=t.BinTrieFlags||(t.BinTrieFlags={}));function f(P){return P>=c.ZERO&&P<=c.NINE}function p(P){return P>=c.UPPER_A&&P<=c.UPPER_F||P>=c.LOWER_A&&P<=c.LOWER_F}function y(P){return P>=c.UPPER_A&&P<=c.UPPER_Z||P>=c.LOWER_A&&P<=c.LOWER_Z||f(P)}function b(P){return P===c.EQUALS||y(P)}var g;(function(P){P[P.EntityStart=0]="EntityStart",P[P.NumericStart=1]="NumericStart",P[P.NumericDecimal=2]="NumericDecimal",P[P.NumericHex=3]="NumericHex",P[P.NamedEntity=4]="NamedEntity"})(g||(g={}));var m;(function(P){P[P.Legacy=0]="Legacy",P[P.Strict=1]="Strict",P[P.Attribute=2]="Attribute"})(m=t.DecodingMode||(t.DecodingMode={}));var v=function(){function P(M,U,j){this.decodeTree=M,this.emitCodePoint=U,this.errors=j,this.state=g.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=m.Strict}return P.prototype.startEntity=function(M){this.decodeMode=M,this.state=g.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1},P.prototype.write=function(M,U){switch(this.state){case g.EntityStart:return M.charCodeAt(U)===c.NUM?(this.state=g.NumericStart,this.consumed+=1,this.stateNumericStart(M,U+1)):(this.state=g.NamedEntity,this.stateNamedEntity(M,U));case g.NumericStart:return this.stateNumericStart(M,U);case g.NumericDecimal:return this.stateNumericDecimal(M,U);case g.NumericHex:return this.stateNumericHex(M,U);case g.NamedEntity:return this.stateNamedEntity(M,U)}},P.prototype.stateNumericStart=function(M,U){return U>=M.length?-1:(M.charCodeAt(U)|d)===c.LOWER_X?(this.state=g.NumericHex,this.consumed+=1,this.stateNumericHex(M,U+1)):(this.state=g.NumericDecimal,this.stateNumericDecimal(M,U))},P.prototype.addToNumericResult=function(M,U,j,q){if(U!==j){var $=j-U;this.result=this.result*Math.pow(q,$)+parseInt(M.substr(U,$),q),this.consumed+=$}},P.prototype.stateNumericHex=function(M,U){for(var j=U;U>14;U>14,$!==0){if(Z===c.SEMI)return this.emitNamedEntityData(this.treeIndex,$,this.consumed+this.excess);this.decodeMode!==m.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1},P.prototype.emitNotTerminatedNamedEntity=function(){var M,U=this,j=U.result,q=U.decodeTree,$=(q[j]&h.VALUE_LENGTH)>>14;return this.emitNamedEntityData(j,$,this.consumed),(M=this.errors)===null||M===void 0||M.missingSemicolonAfterCharacterReference(),this.consumed},P.prototype.emitNamedEntityData=function(M,U,j){var q=this.decodeTree;return this.emitCodePoint(U===1?q[M]&~h.VALUE_LENGTH:q[M+1],j),U===3&&this.emitCodePoint(q[M+2],j),j},P.prototype.end=function(){var M;switch(this.state){case g.NamedEntity:return this.result!==0&&(this.decodeMode!==m.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case g.NumericDecimal:return this.emitNumericEntity(0,2);case g.NumericHex:return this.emitNumericEntity(0,3);case g.NumericStart:return(M=this.errors)===null||M===void 0||M.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case g.EntityStart:return 0}},P}();t.EntityDecoder=v;function _(P){var M="",U=new v(P,function(j){return M+=(0,o.fromCodePoint)(j)});return function(q,$){for(var Z=0,X=0;(X=q.indexOf("&",X))>=0;){M+=q.slice(Z,X),U.startEntity($);var le=U.write(q,X+1);if(le<0){Z=X+U.end();break}Z=X+le,X=le===0?Z+1:Z}var K=M+q.slice(Z);return M="",K}}function w(P,M,U,j){var q=(M&h.BRANCH_LENGTH)>>7,$=M&h.JUMP_TABLE;if(q===0)return $!==0&&j===$?U:-1;if($){var Z=j-$;return Z<0||Z>=q?-1:P[U+Z]-1}for(var X=U,le=X+q-1;X<=le;){var K=X+le>>>1,he=P[K];if(hej)le=K-1;else return P[K+q]}return-1}t.determineBranch=w;var S=_(r.default),A=_(a.default);function D(P,M){return M===void 0&&(M=m.Legacy),S(P,M)}t.decodeHTML=D;function L(P){return S(P,m.Attribute)}t.decodeHTMLAttribute=L;function O(P){return S(P,m.Strict)}t.decodeHTMLStrict=O;function E(P){return A(P,m.Strict)}t.decodeXML=E}(Vv)),Vv}var WD;function u7(){return WD||(WD=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.QuoteType=void 0;var e=Xa(),u;(function(f){f[f.Tab=9]="Tab",f[f.NewLine=10]="NewLine",f[f.FormFeed=12]="FormFeed",f[f.CarriageReturn=13]="CarriageReturn",f[f.Space=32]="Space",f[f.ExclamationMark=33]="ExclamationMark",f[f.Number=35]="Number",f[f.Amp=38]="Amp",f[f.SingleQuote=39]="SingleQuote",f[f.DoubleQuote=34]="DoubleQuote",f[f.Dash=45]="Dash",f[f.Slash=47]="Slash",f[f.Zero=48]="Zero",f[f.Nine=57]="Nine",f[f.Semi=59]="Semi",f[f.Lt=60]="Lt",f[f.Eq=61]="Eq",f[f.Gt=62]="Gt",f[f.Questionmark=63]="Questionmark",f[f.UpperA=65]="UpperA",f[f.LowerA=97]="LowerA",f[f.UpperF=70]="UpperF",f[f.LowerF=102]="LowerF",f[f.UpperZ=90]="UpperZ",f[f.LowerZ=122]="LowerZ",f[f.LowerX=120]="LowerX",f[f.OpeningSquareBracket=91]="OpeningSquareBracket"})(u||(u={}));var s;(function(f){f[f.Text=1]="Text",f[f.BeforeTagName=2]="BeforeTagName",f[f.InTagName=3]="InTagName",f[f.InSelfClosingTag=4]="InSelfClosingTag",f[f.BeforeClosingTagName=5]="BeforeClosingTagName",f[f.InClosingTagName=6]="InClosingTagName",f[f.AfterClosingTagName=7]="AfterClosingTagName",f[f.BeforeAttributeName=8]="BeforeAttributeName",f[f.InAttributeName=9]="InAttributeName",f[f.AfterAttributeName=10]="AfterAttributeName",f[f.BeforeAttributeValue=11]="BeforeAttributeValue",f[f.InAttributeValueDq=12]="InAttributeValueDq",f[f.InAttributeValueSq=13]="InAttributeValueSq",f[f.InAttributeValueNq=14]="InAttributeValueNq",f[f.BeforeDeclaration=15]="BeforeDeclaration",f[f.InDeclaration=16]="InDeclaration",f[f.InProcessingInstruction=17]="InProcessingInstruction",f[f.BeforeComment=18]="BeforeComment",f[f.CDATASequence=19]="CDATASequence",f[f.InSpecialComment=20]="InSpecialComment",f[f.InCommentLike=21]="InCommentLike",f[f.BeforeSpecialS=22]="BeforeSpecialS",f[f.SpecialStartSequence=23]="SpecialStartSequence",f[f.InSpecialTag=24]="InSpecialTag",f[f.BeforeEntity=25]="BeforeEntity",f[f.BeforeNumericEntity=26]="BeforeNumericEntity",f[f.InNamedEntity=27]="InNamedEntity",f[f.InNumericEntity=28]="InNumericEntity",f[f.InHexEntity=29]="InHexEntity"})(s||(s={}));function n(f){return f===u.Space||f===u.NewLine||f===u.Tab||f===u.FormFeed||f===u.CarriageReturn}function r(f){return f===u.Slash||f===u.Gt||n(f)}function a(f){return f>=u.Zero&&f<=u.Nine}function o(f){return f>=u.LowerA&&f<=u.LowerZ||f>=u.UpperA&&f<=u.UpperZ}function l(f){return f>=u.UpperA&&f<=u.UpperF||f>=u.LowerA&&f<=u.LowerF}var c;(function(f){f[f.NoValue=0]="NoValue",f[f.Unquoted=1]="Unquoted",f[f.Single=2]="Single",f[f.Double=3]="Double"})(c=t.QuoteType||(t.QuoteType={}));var d={Cdata:new Uint8Array([67,68,65,84,65,91]),CdataEnd:new Uint8Array([93,93,62]),CommentEnd:new Uint8Array([45,45,62]),ScriptEnd:new Uint8Array([60,47,115,99,114,105,112,116]),StyleEnd:new Uint8Array([60,47,115,116,121,108,101]),TitleEnd:new Uint8Array([60,47,116,105,116,108,101])},h=function(){function f(p,y){var b=p.xmlMode,g=b===void 0?!1:b,m=p.decodeEntities,v=m===void 0?!0:m;this.cbs=y,this.state=s.Text,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=s.Text,this.isSpecial=!1,this.running=!0,this.offset=0,this.currentSequence=void 0,this.sequenceIndex=0,this.trieIndex=0,this.trieCurrent=0,this.entityResult=0,this.entityExcess=0,this.xmlMode=g,this.decodeEntities=v,this.entityTrie=g?e.xmlDecodeTree:e.htmlDecodeTree}return f.prototype.reset=function(){this.state=s.Text,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=s.Text,this.currentSequence=void 0,this.running=!0,this.offset=0},f.prototype.write=function(p){this.offset+=this.buffer.length,this.buffer=p,this.parse()},f.prototype.end=function(){this.running&&this.finish()},f.prototype.pause=function(){this.running=!1},f.prototype.resume=function(){this.running=!0,this.indexthis.sectionStart&&this.cbs.ontext(this.sectionStart,this.index),this.state=s.BeforeTagName,this.sectionStart=this.index):this.decodeEntities&&p===u.Amp&&(this.state=s.BeforeEntity)},f.prototype.stateSpecialStartSequence=function(p){var y=this.sequenceIndex===this.currentSequence.length,b=y?r(p):(p|32)===this.currentSequence[this.sequenceIndex];if(!b)this.isSpecial=!1;else if(!y){this.sequenceIndex++;return}this.sequenceIndex=0,this.state=s.InTagName,this.stateInTagName(p)},f.prototype.stateInSpecialTag=function(p){if(this.sequenceIndex===this.currentSequence.length){if(p===u.Gt||n(p)){var y=this.index-this.currentSequence.length;if(this.sectionStart>14)-1;if(!this.allowLegacyEntity()&&p!==u.Semi)this.trieIndex+=b;else{var g=this.index-this.entityExcess+1;g>this.sectionStart&&this.emitPartial(this.sectionStart,g),this.entityResult=this.trieIndex,this.trieIndex+=b,this.entityExcess=0,this.sectionStart=this.index+1,b===0&&this.emitNamedEntity()}}},f.prototype.emitNamedEntity=function(){if(this.state=this.baseState,this.entityResult!==0){var p=(this.entityTrie[this.entityResult]&e.BinTrieFlags.VALUE_LENGTH)>>14;switch(p){case 1:{this.emitCodePoint(this.entityTrie[this.entityResult]&~e.BinTrieFlags.VALUE_LENGTH);break}case 2:{this.emitCodePoint(this.entityTrie[this.entityResult+1]);break}case 3:this.emitCodePoint(this.entityTrie[this.entityResult+1]),this.emitCodePoint(this.entityTrie[this.entityResult+2])}}},f.prototype.stateBeforeNumericEntity=function(p){(p|32)===u.LowerX?(this.entityExcess++,this.state=s.InHexEntity):(this.state=s.InNumericEntity,this.stateInNumericEntity(p))},f.prototype.emitNumericEntity=function(p){var y=this.index-this.entityExcess-1,b=y+2+ +(this.state===s.InHexEntity);b!==this.index&&(y>this.sectionStart&&this.emitPartial(this.sectionStart,y),this.sectionStart=this.index+Number(p),this.emitCodePoint((0,e.replaceCodePoint)(this.entityResult))),this.state=this.baseState},f.prototype.stateInNumericEntity=function(p){p===u.Semi?this.emitNumericEntity(!0):a(p)?(this.entityResult=this.entityResult*10+(p-u.Zero),this.entityExcess++):(this.allowLegacyEntity()?this.emitNumericEntity(!1):this.state=this.baseState,this.index--)},f.prototype.stateInHexEntity=function(p){p===u.Semi?this.emitNumericEntity(!0):a(p)?(this.entityResult=this.entityResult*16+(p-u.Zero),this.entityExcess++):l(p)?(this.entityResult=this.entityResult*16+((p|32)-u.LowerA+10),this.entityExcess++):(this.allowLegacyEntity()?this.emitNumericEntity(!1):this.state=this.baseState,this.index--)},f.prototype.allowLegacyEntity=function(){return!this.xmlMode&&(this.baseState===s.Text||this.baseState===s.InSpecialTag)},f.prototype.cleanup=function(){this.running&&this.sectionStart!==this.index&&(this.state===s.Text||this.state===s.InSpecialTag&&this.sequenceIndex===0?(this.cbs.ontext(this.sectionStart,this.index),this.sectionStart=this.index):(this.state===s.InAttributeValueDq||this.state===s.InAttributeValueSq||this.state===s.InAttributeValueNq)&&(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=this.index))},f.prototype.shouldContinue=function(){return this.index0&&A.has(this.stack[this.stack.length-1]);){var D=this.stack.pop();(_=(v=this.cbs).onclosetag)===null||_===void 0||_.call(v,D,!0)}this.isVoidElement(m)||(this.stack.push(m),f.has(m)?this.foreignContext.push(!0):p.has(m)&&this.foreignContext.push(!1)),(S=(w=this.cbs).onopentagname)===null||S===void 0||S.call(w,m),this.cbs.onopentag&&(this.attribs={})},g.prototype.endOpenTag=function(m){var v,_;this.startIndex=this.openTagStart,this.attribs&&((_=(v=this.cbs).onopentag)===null||_===void 0||_.call(v,this.tagname,this.attribs,m),this.attribs=null),this.cbs.onclosetag&&this.isVoidElement(this.tagname)&&this.cbs.onclosetag(this.tagname,!0),this.tagname=""},g.prototype.onopentagend=function(m){this.endIndex=m,this.endOpenTag(!1),this.startIndex=m+1},g.prototype.onclosetag=function(m,v){var _,w,S,A,D,L;this.endIndex=v;var O=this.getSlice(m,v);if(this.lowerCaseTagNames&&(O=O.toLowerCase()),(f.has(O)||p.has(O))&&this.foreignContext.pop(),this.isVoidElement(O))!this.options.xmlMode&&O==="br"&&((w=(_=this.cbs).onopentagname)===null||w===void 0||w.call(_,"br"),(A=(S=this.cbs).onopentag)===null||A===void 0||A.call(S,"br",{},!0),(L=(D=this.cbs).onclosetag)===null||L===void 0||L.call(D,"br",!1));else{var E=this.stack.lastIndexOf(O);if(E!==-1)if(this.cbs.onclosetag)for(var P=this.stack.length-E;P--;)this.cbs.onclosetag(this.stack.pop(),P!==0);else this.stack.length=E;else!this.options.xmlMode&&O==="p"&&(this.emitOpenTag("p"),this.closeCurrentTag(!0))}this.startIndex=v+1},g.prototype.onselfclosingtag=function(m){this.endIndex=m,this.options.xmlMode||this.options.recognizeSelfClosing||this.foreignContext[this.foreignContext.length-1]?(this.closeCurrentTag(!1),this.startIndex=m+1):this.onopentagend(m)},g.prototype.closeCurrentTag=function(m){var v,_,w=this.tagname;this.endOpenTag(m),this.stack[this.stack.length-1]===w&&((_=(v=this.cbs).onclosetag)===null||_===void 0||_.call(v,w,!m),this.stack.pop())},g.prototype.onattribname=function(m,v){this.startIndex=m;var _=this.getSlice(m,v);this.attribname=this.lowerCaseAttributeNames?_.toLowerCase():_},g.prototype.onattribdata=function(m,v){this.attribvalue+=this.getSlice(m,v)},g.prototype.onattribentity=function(m){this.attribvalue+=(0,n.fromCodePoint)(m)},g.prototype.onattribend=function(m,v){var _,w;this.endIndex=v,(w=(_=this.cbs).onattribute)===null||w===void 0||w.call(_,this.attribname,this.attribvalue,m===s.QuoteType.Double?'"':m===s.QuoteType.Single?"'":m===s.QuoteType.NoValue?void 0:null),this.attribs&&!Object.prototype.hasOwnProperty.call(this.attribs,this.attribname)&&(this.attribs[this.attribname]=this.attribvalue),this.attribvalue=""},g.prototype.getInstructionName=function(m){var v=m.search(y),_=v<0?m:m.substr(0,v);return this.lowerCaseTagNames&&(_=_.toLowerCase()),_},g.prototype.ondeclaration=function(m,v){this.endIndex=v;var _=this.getSlice(m,v);if(this.cbs.onprocessinginstruction){var w=this.getInstructionName(_);this.cbs.onprocessinginstruction("!".concat(w),"!".concat(_))}this.startIndex=v+1},g.prototype.onprocessinginstruction=function(m,v){this.endIndex=v;var _=this.getSlice(m,v);if(this.cbs.onprocessinginstruction){var w=this.getInstructionName(_);this.cbs.onprocessinginstruction("?".concat(w),"?".concat(_))}this.startIndex=v+1},g.prototype.oncomment=function(m,v,_){var w,S,A,D;this.endIndex=v,(S=(w=this.cbs).oncomment)===null||S===void 0||S.call(w,this.getSlice(m,v-_)),(D=(A=this.cbs).oncommentend)===null||D===void 0||D.call(A),this.startIndex=v+1},g.prototype.oncdata=function(m,v,_){var w,S,A,D,L,O,E,P,M,U;this.endIndex=v;var j=this.getSlice(m,v-_);this.options.xmlMode||this.options.recognizeCDATA?((S=(w=this.cbs).oncdatastart)===null||S===void 0||S.call(w),(D=(A=this.cbs).ontext)===null||D===void 0||D.call(A,j),(O=(L=this.cbs).oncdataend)===null||O===void 0||O.call(L)):((P=(E=this.cbs).oncomment)===null||P===void 0||P.call(E,"[CDATA[".concat(j,"]]")),(U=(M=this.cbs).oncommentend)===null||U===void 0||U.call(M)),this.startIndex=v+1},g.prototype.onend=function(){var m,v;if(this.cbs.onclosetag){this.endIndex=this.startIndex;for(var _=this.stack.length;_>0;this.cbs.onclosetag(this.stack[--_],!0));}(v=(m=this.cbs).onend)===null||v===void 0||v.call(m)},g.prototype.reset=function(){var m,v,_,w;(v=(m=this.cbs).onreset)===null||v===void 0||v.call(m),this.tokenizer.reset(),this.tagname="",this.attribname="",this.attribs=null,this.stack.length=0,this.startIndex=0,this.endIndex=0,(w=(_=this.cbs).onparserinit)===null||w===void 0||w.call(_,this),this.buffers.length=0,this.bufferOffset=0,this.writeIndex=0,this.ended=!1},g.prototype.parseComplete=function(m){this.reset(),this.end(m)},g.prototype.getSlice=function(m,v){for(;m-this.bufferOffset>=this.buffers[0].length;)this.shiftBuffer();for(var _=this.buffers[0].slice(m-this.bufferOffset,v-this.bufferOffset);v-this.bufferOffset>this.buffers[0].length;)this.shiftBuffer(),_+=this.buffers[0].slice(0,v-this.bufferOffset);return _},g.prototype.shiftBuffer=function(){this.bufferOffset+=this.buffers[0].length,this.writeIndex--,this.buffers.shift()},g.prototype.write=function(m){var v,_;if(this.ended){(_=(v=this.cbs).onerror)===null||_===void 0||_.call(v,new Error(".write() after done!"));return}this.buffers.push(m),this.tokenizer.running&&(this.tokenizer.write(m),this.writeIndex++)},g.prototype.end=function(m){var v,_;if(this.ended){(_=(v=this.cbs).onerror)===null||_===void 0||_.call(v,new Error(".end() after done!"));return}m&&this.write(m),this.ended=!0,this.tokenizer.end()},g.prototype.pause=function(){this.tokenizer.pause()},g.prototype.resume=function(){for(this.tokenizer.resume();this.tokenizer.running&&this.writeIndex0?this.children[this.children.length-1]:null},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"childNodes",{get:function(){return this.children},set:function(D){this.children=D},enumerable:!1,configurable:!0}),A}(s);Ft.NodeWithChildren=l;var c=function(S){t(A,S);function A(){var D=S!==null&&S.apply(this,arguments)||this;return D.type=u.ElementType.CDATA,D}return Object.defineProperty(A.prototype,"nodeType",{get:function(){return 4},enumerable:!1,configurable:!0}),A}(l);Ft.CDATA=c;var d=function(S){t(A,S);function A(){var D=S!==null&&S.apply(this,arguments)||this;return D.type=u.ElementType.Root,D}return Object.defineProperty(A.prototype,"nodeType",{get:function(){return 9},enumerable:!1,configurable:!0}),A}(l);Ft.Document=d;var h=function(S){t(A,S);function A(D,L,O,E){O===void 0&&(O=[]),E===void 0&&(E=D==="script"?u.ElementType.Script:D==="style"?u.ElementType.Style:u.ElementType.Tag);var P=S.call(this,O)||this;return P.name=D,P.attribs=L,P.type=E,P}return Object.defineProperty(A.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"tagName",{get:function(){return this.name},set:function(D){this.name=D},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"attributes",{get:function(){var D=this;return Object.keys(this.attribs).map(function(L){var O,E;return{name:L,value:D.attribs[L],namespace:(O=D["x-attribsNamespace"])===null||O===void 0?void 0:O[L],prefix:(E=D["x-attribsPrefix"])===null||E===void 0?void 0:E[L]}})},enumerable:!1,configurable:!0}),A}(l);Ft.Element=h;function f(S){return(0,u.isTag)(S)}Ft.isTag=f;function p(S){return S.type===u.ElementType.CDATA}Ft.isCDATA=p;function y(S){return S.type===u.ElementType.Text}Ft.isText=y;function b(S){return S.type===u.ElementType.Comment}Ft.isComment=b;function g(S){return S.type===u.ElementType.Directive}Ft.isDirective=g;function m(S){return S.type===u.ElementType.Root}Ft.isDocument=m;function v(S){return Object.prototype.hasOwnProperty.call(S,"children")}Ft.hasChildren=v;function _(S,A){A===void 0&&(A=!1);var D;if(y(S))D=new r(S.data);else if(b(S))D=new a(S.data);else if(f(S)){var L=A?w(S.children):[],O=new h(S.name,e({},S.attribs),L);L.forEach(function(U){return U.parent=O}),S.namespace!=null&&(O.namespace=S.namespace),S["x-attribsNamespace"]&&(O["x-attribsNamespace"]=e({},S["x-attribsNamespace"])),S["x-attribsPrefix"]&&(O["x-attribsPrefix"]=e({},S["x-attribsPrefix"])),D=O}else if(p(S)){var L=A?w(S.children):[],E=new c(L);L.forEach(function(j){return j.parent=E}),D=E}else if(m(S)){var L=A?w(S.children):[],P=new d(L);L.forEach(function(j){return j.parent=P}),S["x-mode"]&&(P["x-mode"]=S["x-mode"]),D=P}else if(g(S)){var M=new o(S.name,S.data);S["x-name"]!=null&&(M["x-name"]=S["x-name"],M["x-publicId"]=S["x-publicId"],M["x-systemId"]=S["x-systemId"]),D=M}else throw new Error("Not implemented yet: ".concat(S.type));return D.startIndex=S.startIndex,D.endIndex=S.endIndex,S.sourceCodeLocation!=null&&(D.sourceCodeLocation=S.sourceCodeLocation),D}Ft.cloneNode=_;function w(S){for(var A=S.map(function(L){return _(L,!0)}),D=1;D$\x80-\uFFFF]/g;var e=new Map([[34,"""],[38,"&"],[39,"'"],[60,"<"],[62,">"]]);t.getCodePoint=String.prototype.codePointAt!=null?function(n,r){return n.codePointAt(r)}:function(n,r){return(n.charCodeAt(r)&64512)===55296?(n.charCodeAt(r)-55296)*1024+n.charCodeAt(r+1)-56320+65536:n.charCodeAt(r)};function u(n){for(var r="",a=0,o;(o=t.xmlReplacer.exec(n))!==null;){var l=o.index,c=n.charCodeAt(l),d=e.get(c);d!==void 0?(r+=n.substring(a,l)+d,a=l+1):(r+="".concat(n.substring(a,l),"&#x").concat((0,t.getCodePoint)(n,l).toString(16),";"),a=t.xmlReplacer.lastIndex+=+((c&64512)===55296))}return r+n.substr(a)}t.encodeXML=u,t.escape=u;function s(n,r){return function(o){for(var l,c=0,d="";l=n.exec(o);)c!==l.index&&(d+=o.substring(c,l.index)),d+=r.get(l[0].charCodeAt(0)),c=l.index+1;return d+o.substring(c)}}t.escapeUTF8=s(/[&<>'"]/g,e),t.escapeAttribute=s(/["&\u00A0]/g,new Map([[34,"""],[38,"&"],[160," "]])),t.escapeText=s(/[&<>\u00A0]/g,new Map([[38,"&"],[60,"<"],[62,">"],[160," "]]))}(Xv)),Xv}var nN;function iN(){if(nN)return Es;nN=1;var t=I&&I.__importDefault||function(o){return o&&o.__esModule?o:{default:o}};Object.defineProperty(Es,"__esModule",{value:!0}),Es.encodeNonAsciiHTML=Es.encodeHTML=void 0;var e=t($J()),u=v3(),s=/[\t\n!-,./:-@[-`\f{-}$\x80-\uFFFF]/g;function n(o){return a(s,o)}Es.encodeHTML=n;function r(o){return a(u.xmlReplacer,o)}Es.encodeNonAsciiHTML=r;function a(o,l){for(var c="",d=0,h;(h=o.exec(l))!==null;){var f=h.index;c+=l.substring(d,f);var p=l.charCodeAt(f),y=e.default.get(p);if(typeof y=="object"){if(f+10&&(D+=h(w.children,S)),(S.xmlMode||!d.has(w.name))&&(D+=""))),D}function g(w){return"<".concat(w.data,">")}function m(w,S){var A,D=w.data||"";return((A=S.encodeEntities)!==null&&A!==void 0?A:S.decodeEntities)!==!1&&!(!S.xmlMode&&w.parent&&o.has(w.parent.name))&&(D=S.xmlMode||S.encodeEntities!=="utf8"?(0,r.encodeXML)(D):(0,r.escapeText)(D)),D}function v(w){return"")}function _(w){return"")}return go}var uN;function c7(){if(uN)return zn;uN=1;var t=I&&I.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(zn,"__esModule",{value:!0}),zn.innerText=zn.textContent=zn.getText=zn.getInnerHTML=zn.getOuterHTML=void 0;var e=ui(),u=t(zJ()),s=to();function n(c,d){return(0,u.default)(c,d)}zn.getOuterHTML=n;function r(c,d){return(0,e.hasChildren)(c)?c.children.map(function(h){return n(h,d)}).join(""):""}zn.getInnerHTML=r;function a(c){return Array.isArray(c)?c.map(a).join(""):(0,e.isTag)(c)?c.name==="br"?` +`:a(c.children):(0,e.isCDATA)(c)?a(c.children):(0,e.isText)(c)?c.data:""}zn.getText=a;function o(c){return Array.isArray(c)?c.map(o).join(""):(0,e.hasChildren)(c)&&!(0,e.isComment)(c)?o(c.children):(0,e.isText)(c)?c.data:""}zn.textContent=o;function l(c){return Array.isArray(c)?c.map(l).join(""):(0,e.hasChildren)(c)&&(c.type===s.ElementType.Tag||(0,e.isCDATA)(c))?l(c.children):(0,e.isText)(c)?c.data:""}return zn.innerText=l,zn}var Hr={},cN;function GJ(){if(cN)return Hr;cN=1,Object.defineProperty(Hr,"__esModule",{value:!0}),Hr.prevElementSibling=Hr.nextElementSibling=Hr.getName=Hr.hasAttrib=Hr.getAttributeValue=Hr.getSiblings=Hr.getParent=Hr.getChildren=void 0;var t=ui();function e(c){return(0,t.hasChildren)(c)?c.children:[]}Hr.getChildren=e;function u(c){return c.parent||null}Hr.getParent=u;function s(c){var d,h,f=u(c);if(f!=null)return e(f);for(var p=[c],y=c.prev,b=c.next;y!=null;)p.unshift(y),d=y,y=d.prev;for(;b!=null;)p.push(b),h=b,b=h.next;return p}Hr.getSiblings=s;function n(c,d){var h;return(h=c.attribs)===null||h===void 0?void 0:h[d]}Hr.getAttributeValue=n;function r(c,d){return c.attribs!=null&&Object.prototype.hasOwnProperty.call(c.attribs,d)&&c.attribs[d]!=null}Hr.hasAttrib=r;function a(c){return c.name}Hr.getName=a;function o(c){for(var d,h=c.next;h!==null&&!(0,t.isTag)(h);)d=h,h=d.next;return h}Hr.nextElementSibling=o;function l(c){for(var d,h=c.prev;h!==null&&!(0,t.isTag)(h);)d=h,h=d.prev;return h}return Hr.prevElementSibling=l,Hr}var vn={},lN;function WJ(){if(lN)return vn;lN=1,Object.defineProperty(vn,"__esModule",{value:!0}),vn.prepend=vn.prependChild=vn.append=vn.appendChild=vn.replaceElement=vn.removeElement=void 0;function t(a){if(a.prev&&(a.prev.next=a.next),a.next&&(a.next.prev=a.prev),a.parent){var o=a.parent.children,l=o.lastIndexOf(a);l>=0&&o.splice(l,1)}a.next=null,a.prev=null,a.parent=null}vn.removeElement=t;function e(a,o){var l=o.prev=a.prev;l&&(l.next=o);var c=o.next=a.next;c&&(c.prev=o);var d=o.parent=a.parent;if(d){var h=d.children;h[h.lastIndexOf(a)]=o,a.parent=null}}vn.replaceElement=e;function u(a,o){if(t(o),o.next=null,o.parent=a,a.children.push(o)>1){var l=a.children[a.children.length-2];l.next=o,o.prev=l}else o.prev=null}vn.appendChild=u;function s(a,o){t(o);var l=a.parent,c=a.next;if(o.next=c,o.prev=a,a.next=o,o.parent=l,c){if(c.prev=o,l){var d=l.children;d.splice(d.lastIndexOf(c),0,o)}}else l&&l.children.push(o)}vn.append=s;function n(a,o){if(t(o),o.parent=a,o.prev=null,a.children.unshift(o)!==1){var l=a.children[1];l.prev=o,o.next=l}else o.next=null}vn.prependChild=n;function r(a,o){t(o);var l=a.parent;if(l){var c=l.children;c.splice(c.indexOf(a),0,o)}a.prev&&(a.prev.next=o),o.parent=l,o.prev=a.prev,o.next=a,a.prev=o}return vn.prepend=r,vn}var wn={},dN;function l7(){if(dN)return wn;dN=1,Object.defineProperty(wn,"__esModule",{value:!0}),wn.findAll=wn.existsOne=wn.findOne=wn.findOneChild=wn.find=wn.filter=void 0;var t=ui();function e(o,l,c,d){return c===void 0&&(c=!0),d===void 0&&(d=1/0),u(o,Array.isArray(l)?l:[l],c,d)}wn.filter=e;function u(o,l,c,d){for(var h=[],f=[l],p=[0];;){if(p[0]>=f[0].length){if(p.length===1)return h;f.shift(),p.shift();continue}var y=f[0][p[0]++];if(o(y)&&(h.push(y),--d<=0))return h;c&&(0,t.hasChildren)(y)&&y.children.length>0&&(p.unshift(0),f.unshift(y.children))}}wn.find=u;function s(o,l){return l.find(o)}wn.findOneChild=s;function n(o,l,c){c===void 0&&(c=!0);for(var d=null,h=0;h0&&(d=n(o,f.children,!0));else continue}return d}wn.findOne=n;function r(o,l){return l.some(function(c){return(0,t.isTag)(c)&&(o(c)||r(o,c.children))})}wn.existsOne=r;function a(o,l){for(var c=[],d=[l],h=[0];;){if(h[0]>=d[0].length){if(d.length===1)return c;d.shift(),h.shift();continue}var f=d[0][h[0]++];(0,t.isTag)(f)&&(o(f)&&c.push(f),f.children.length>0&&(h.unshift(0),d.unshift(f.children)))}}return wn.findAll=a,wn}var Gn={},fN;function d7(){if(fN)return Gn;fN=1,Object.defineProperty(Gn,"__esModule",{value:!0}),Gn.getElementsByTagType=Gn.getElementsByTagName=Gn.getElementById=Gn.getElements=Gn.testElement=void 0;var t=ui(),e=l7(),u={tag_name:function(h){return typeof h=="function"?function(f){return(0,t.isTag)(f)&&h(f.name)}:h==="*"?t.isTag:function(f){return(0,t.isTag)(f)&&f.name===h}},tag_type:function(h){return typeof h=="function"?function(f){return h(f.type)}:function(f){return f.type===h}},tag_contains:function(h){return typeof h=="function"?function(f){return(0,t.isText)(f)&&h(f.data)}:function(f){return(0,t.isText)(f)&&f.data===h}}};function s(h,f){return typeof f=="function"?function(p){return(0,t.isTag)(p)&&f(p.attribs[h])}:function(p){return(0,t.isTag)(p)&&p.attribs[h]===f}}function n(h,f){return function(p){return h(p)||f(p)}}function r(h){var f=Object.keys(h).map(function(p){var y=h[p];return Object.prototype.hasOwnProperty.call(u,p)?u[p](y):s(p,y)});return f.length===0?null:f.reduce(n)}function a(h,f){var p=r(h);return p?p(f):!0}Gn.testElement=a;function o(h,f,p,y){y===void 0&&(y=1/0);var b=r(h);return b?(0,e.filter)(b,f,p,y):[]}Gn.getElements=o;function l(h,f,p){return p===void 0&&(p=!0),Array.isArray(f)||(f=[f]),(0,e.findOne)(s("id",h),f,p)}Gn.getElementById=l;function c(h,f,p,y){return p===void 0&&(p=!0),y===void 0&&(y=1/0),(0,e.filter)(u.tag_name(h),f,p,y)}Gn.getElementsByTagName=c;function d(h,f,p,y){return p===void 0&&(p=!0),y===void 0&&(y=1/0),(0,e.filter)(u.tag_type(h),f,p,y)}return Gn.getElementsByTagType=d,Gn}var Kv={},hN;function JJ(){return hN||(hN=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.uniqueSort=t.compareDocumentPosition=t.DocumentPosition=t.removeSubsets=void 0;var e=ui();function u(a){for(var o=a.length;--o>=0;){var l=a[o];if(o>0&&a.lastIndexOf(l,o-1)>=0){a.splice(o,1);continue}for(var c=l.parent;c;c=c.parent)if(a.includes(c)){a.splice(o,1);break}}return a}t.removeSubsets=u;var s;(function(a){a[a.DISCONNECTED=1]="DISCONNECTED",a[a.PRECEDING=2]="PRECEDING",a[a.FOLLOWING=4]="FOLLOWING",a[a.CONTAINS=8]="CONTAINS",a[a.CONTAINED_BY=16]="CONTAINED_BY"})(s=t.DocumentPosition||(t.DocumentPosition={}));function n(a,o){var l=[],c=[];if(a===o)return 0;for(var d=(0,e.hasChildren)(a)?a:a.parent;d;)l.unshift(d),d=d.parent;for(d=(0,e.hasChildren)(o)?o:o.parent;d;)c.unshift(d),d=d.parent;for(var h=Math.min(l.length,c.length),f=0;fy.indexOf(g)?p===o?s.FOLLOWING|s.CONTAINED_BY:s.FOLLOWING:p===a?s.PRECEDING|s.CONTAINS:s.PRECEDING}t.compareDocumentPosition=n;function r(a){return a=a.filter(function(o,l,c){return!c.includes(o,l+1)}),a.sort(function(o,l){var c=n(o,l);return c&s.PRECEDING?-1:c&s.FOLLOWING?1:0}),a}t.uniqueSort=r}(Kv)),Kv}var Bl={},pN;function XJ(){if(pN)return Bl;pN=1,Object.defineProperty(Bl,"__esModule",{value:!0}),Bl.getFeed=void 0;var t=c7(),e=d7();function u(f){var p=l(h,f);return p?p.name==="feed"?s(p):n(p):null}Bl.getFeed=u;function s(f){var p,y=f.children,b={type:"atom",items:(0,e.getElementsByTagName)("entry",y).map(function(v){var _,w=v.children,S={media:o(w)};d(S,"id","id",w),d(S,"title","title",w);var A=(_=l("link",w))===null||_===void 0?void 0:_.attribs.href;A&&(S.link=A);var D=c("summary",w)||c("content",w);D&&(S.description=D);var L=c("updated",w);return L&&(S.pubDate=new Date(L)),S})};d(b,"id","id",y),d(b,"title","title",y);var g=(p=l("link",y))===null||p===void 0?void 0:p.attribs.href;g&&(b.link=g),d(b,"description","subtitle",y);var m=c("updated",y);return m&&(b.updated=new Date(m)),d(b,"author","email",y,!0),b}function n(f){var p,y,b=(y=(p=l("channel",f.children))===null||p===void 0?void 0:p.children)!==null&&y!==void 0?y:[],g={type:f.name.substr(0,3),id:"",items:(0,e.getElementsByTagName)("item",f.children).map(function(v){var _=v.children,w={media:o(_)};d(w,"id","guid",_),d(w,"title","title",_),d(w,"link","link",_),d(w,"description","description",_);var S=c("pubDate",_)||c("dc:date",_);return S&&(w.pubDate=new Date(S)),w})};d(g,"title","title",b),d(g,"link","link",b),d(g,"description","description",b);var m=c("lastBuildDate",b);return m&&(g.updated=new Date(m)),d(g,"author","managingEditor",b,!0),g}var r=["url","type","lang"],a=["fileSize","bitrate","framerate","samplingrate","channels","duration","height","width"];function o(f){return(0,e.getElementsByTagName)("media:content",f).map(function(p){for(var y=p.attribs,b={medium:y.medium,isDefault:!!y.isDefault},g=0,m=r;g0){const c=Object.assign(Object.assign({},a),l);if(r.prefix){let d;for(;d=s.PREFIX_REGEX.exec(r.prefix);)c[d[1]]=d[2]}return c}else return a}static expandPrefixedTerm(r,a){const o=r.indexOf(":");let l,c;if(o>=0&&(l=r.substr(0,o),c=r.substr(o+1)),l==="")return"http://www.w3.org/1999/xhtml/vocab#"+c;if(l){const d=a.prefixesAll[l];if(d)return d+c}if(r){const d=a.prefixesAll[r.toLocaleLowerCase()];if(d)return d}return r}static isValidIri(r){return s.IRI_REGEX.test(r)}static contentTypeToProfile(r){return e.RDFA_CONTENTTYPES[r]||""}getBaseIRI(r){let a=r;const o=a.indexOf("#");return o>=0&&(a=a.substr(0,o)),this.dataFactory.namedNode((0,t.resolve)(a,this.baseIRI.value))}getResourceOrBaseIri(r,a){return r===!0?this.getBaseIriTerm(a):r}getBaseIriTerm(r){return r.localBaseIRI||this.baseIRI}createVocabIris(r,a,o,l){return r.split(/\s+/).filter(c=>c&&(o||c.indexOf(":")>=0)).map(c=>this.createIri(c,a,!0,!0,l)).filter(c=>c!=null)}createLiteral(r,a){if(a.interpretObjectAsTime&&!a.datatype){for(const o of s.TIME_REGEXES)if(r.match(o.regex)){a.datatype=this.dataFactory.namedNode(s.XSD+o.type);break}}return this.dataFactory.literal(r,a.datatype||a.language)}createBlankNode(){return this.blankNodeFactory?this.blankNodeFactory():this.dataFactory.blankNode()}createIri(r,a,o,l,c){if(r=r||"",!l)return o||(r=(0,t.resolve)(r,this.getBaseIriTerm(a).value)),s.isValidIri(r)?this.dataFactory.namedNode(r):null;if(r.length>0&&r[0]==="["&&r[r.length-1]==="]"&&(r=r.substr(1,r.length-2),r.indexOf(":")<0))return null;if(r.startsWith("_:"))return c?this.dataFactory.blankNode(r.substr(2)||"b_identity"):null;if(o&&a.vocab&&r.indexOf(":")<0)return this.dataFactory.namedNode(a.vocab+r);let d=s.expandPrefixedTerm(r,a);return o?r!==d&&(d=(0,t.resolve)(d,this.baseIRIDocument.value)):d=(0,t.resolve)(d,this.getBaseIriTerm(a).value),s.isValidIri(d)?this.dataFactory.namedNode(d):null}}return Ul.Util=s,s.RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#",s.XSD="http://www.w3.org/2001/XMLSchema#",s.RDFA="http://www.w3.org/ns/rdfa#",s.PREFIX_REGEX=/\s*([^:\s]*)*:\s*([^\s]*)*\s*/g,s.TIME_REGEXES=[{regex:/^-?P([0-9]+Y)?([0-9]+M)?([0-9]+D)?(T([0-9]+H)?([0-9]+M)?([0-9]+(\.[0-9])?S)?)?$/,type:"duration"},{regex:/^[0-9]+-[0-9][0-9]-[0-9][0-9]T[0-9][0-9]:[0-9][0-9]:[0-9][0-9]((Z?)|([\+-][0-9][0-9]:[0-9][0-9]))$/,type:"dateTime"},{regex:/^[0-9]+-[0-9][0-9]-[0-9][0-9]Z?$/,type:"date"},{regex:/^[0-9][0-9]:[0-9][0-9]:[0-9][0-9]((Z?)|([\+-][0-9][0-9]:[0-9][0-9]))$/,type:"time"},{regex:/^[0-9]+-[0-9][0-9]$/,type:"gYearMonth"},{regex:/^[0-9]+$/,type:"gYear"}],s.IRI_REGEX=/^([A-Za-z][A-Za-z0-9+-.]*|_):[^ "<>{}|\\\[\]`]*$/,Ul}var _N;function eX(){if(_N)return Fl;_N=1,Object.defineProperty(Fl,"__esModule",{value:!0}),Fl.RdfaParser=void 0;const t=KJ(),e=Wt(),u=YJ,s=ZJ,n=oA(),r=f7();let a=class h7 extends e.Transform{constructor(l){super({readableObjectMode:!0}),this.activeTagStack=[],l=l||{},this.options=l,this.util=new r.Util(l.dataFactory,l.baseIRI),this.defaultGraph=l.defaultGraph||this.util.dataFactory.defaultGraph();const c=l.contentType?r.Util.contentTypeToProfile(l.contentType):l.profile||"";this.features=l.features||n.RDFA_FEATURES[c],this.htmlParseListener=l.htmlParseListener,this.rdfaPatterns=this.features.copyRdfaPatterns?{}:null,this.pendingRdfaPatternCopies=this.features.copyRdfaPatterns?{}:null,this.parser=this.initializeParser(c==="xml"),this.activeTagStack.push({incompleteTriples:[],inlist:!1,language:l.language,listMapping:{},listMappingLocal:{},name:"",prefixesAll:Object.assign(Object.assign({},s["@context"]),this.features.xhtmlInitialContext?u["@context"]:{}),prefixesCustom:{},skipElement:!1,vocab:l.vocab})}import(l){const c=new e.PassThrough({readableObjectMode:!0});l.on("error",h=>d.emit("error",h)),l.on("data",h=>c.push(h)),l.on("end",()=>c.push(null));const d=c.pipe(new h7(this.options));return d}_transform(l,c,d){this.parser.write(l.toString()),d()}_flush(l){this.parser.end(),l()}onTagOpen(l,c){let d=this.activeTagStack.length-1;for(;d>0&&this.activeTagStack[d].skipElement;)d--;let h=this.activeTagStack[d];d!==this.activeTagStack.length-1&&(h=Object.assign(Object.assign({},h),{language:this.activeTagStack[this.activeTagStack.length-1].language,prefixesAll:this.activeTagStack[this.activeTagStack.length-1].prefixesAll,prefixesCustom:this.activeTagStack[this.activeTagStack.length-1].prefixesCustom,vocab:this.activeTagStack[this.activeTagStack.length-1].vocab}));const f={collectChildTags:h.collectChildTags,incompleteTriples:[],inlist:"inlist"in c,listMapping:[],listMappingLocal:h.listMapping,localBaseIRI:h.localBaseIRI,name:l,prefixesAll:null,prefixesCustom:null,skipElement:!1};if(this.activeTagStack.push(f),f.collectChildTags){for(const S of Object.keys(h.prefixesCustom).sort()){const A=h.prefixesCustom[S],D=S===""?"xmlns":"xmlns:"+S;D in c||(c[D]=A)}const w=Object.keys(c).map(S=>`${S}="${c[S]}"`).join(" ");if(f.text=[`<${l}${w?" "+w:""}>`],this.features.skipHandlingXmlLiteralChildren)return}let p=!0,y=!0;if(this.features.onlyAllowUriRelRevIfProperty&&("property"in c&&"rel"in c&&(p=!1,c.rel.indexOf(":")<0&&delete c.rel),"property"in c&&"rev"in c&&(y=!1,c.rev.indexOf(":")<0&&delete c.rev)),this.features.copyRdfaPatterns){if(h.collectedPatternTag){const w={attributes:c,children:[],name:l,referenced:!1,rootPattern:!1,text:[]};h.collectedPatternTag.children.push(w),f.collectedPatternTag=w;return}if(c.typeof==="rdfa:Pattern"){f.collectedPatternTag={attributes:c,children:[],name:l,parentTag:h,referenced:!1,rootPattern:!0,text:[]};return}if(c.property==="rdfa:copy"){const w=c.resource||c.href||c.src;this.rdfaPatterns[w]?this.emitPatternCopy(h,this.rdfaPatterns[w],w):(this.pendingRdfaPatternCopies[w]||(this.pendingRdfaPatternCopies[w]=[]),this.pendingRdfaPatternCopies[w].push(h));return}}this.features.baseTag&&l==="base"&&c.href&&(this.util.baseIRI=this.util.getBaseIRI(c.href)),this.features.xmlBase&&c["xml:base"]&&(f.localBaseIRI=this.util.getBaseIRI(c["xml:base"])),this.features.timeTag&&l==="time"&&!c.datatype&&(f.interpretObjectAsTime=!0);let b,g,m;if("vocab"in c?c.vocab?(f.vocab=c.vocab,this.emitTriple(this.util.getBaseIriTerm(f),this.util.dataFactory.namedNode(r.Util.RDFA+"usesVocabulary"),this.util.dataFactory.namedNode(f.vocab))):f.vocab=this.activeTagStack[0].vocab:f.vocab=h.vocab,f.prefixesCustom=r.Util.parsePrefixes(c,h.prefixesCustom,this.features.xmlnsPrefixMappings),f.prefixesAll=Object.keys(f.prefixesCustom).length>0?Object.assign(Object.assign({},h.prefixesAll),f.prefixesCustom):h.prefixesAll,this.features.roleAttribute&&c.role){const w=c.id?this.util.createIri("#"+c.id,f,!1,!1,!1):this.util.createBlankNode(),S=f.vocab;f.vocab="http://www.w3.org/1999/xhtml/vocab#";for(const A of this.util.createVocabIris(c.role,f,!0,!1))this.emitTriple(w,this.util.dataFactory.namedNode("http://www.w3.org/1999/xhtml/vocab#role"),A);f.vocab=S}"xml:lang"in c||this.features.langAttribute&&"lang"in c?f.language=c["xml:lang"]||c.lang:f.language=h.language;const v=this.activeTagStack.length===2;if(!("rel"in c)&&!("rev"in c)?"property"in c&&!("content"in c)&&!("datatype"in c)?("about"in c?(b=this.util.createIri(c.about,f,!1,!0,!0),f.explicitNewSubject=!!b):v?b=!0:h.object&&(b=h.object),"typeof"in c&&("about"in c&&(m=this.util.createIri(c.about,f,!1,!0,!0)),!m&&v&&(m=!0),!m&&"resource"in c&&(m=this.util.createIri(c.resource,f,!1,!0,!0)),!m&&("href"in c||"src"in c)&&(m=this.util.createIri(c.href||c.src,f,!1,!1,!0)),!m&&this.isInheritSubjectInHeadBody(l)&&(m=b),m||(m=this.util.createBlankNode()),g=m)):(("about"in c||"resource"in c)&&(b=this.util.createIri(c.about||c.resource,f,!1,!0,!0),f.explicitNewSubject=!!b),!b&&("href"in c||"src"in c)&&(b=this.util.createIri(c.href||c.src,f,!1,!1,!0),f.explicitNewSubject=!!b),b||(v?b=!0:this.isInheritSubjectInHeadBody(l)?b=h.object:"typeof"in c?(b=this.util.createBlankNode(),f.explicitNewSubject=!0):h.object&&(b=h.object,"property"in c||(f.skipElement=!0))),"typeof"in c&&(m=b)):("about"in c?(b=this.util.createIri(c.about,f,!1,!0,!0),f.explicitNewSubject=!!b,"typeof"in c&&(m=b)):v?b=!0:h.object&&(b=h.object),"resource"in c&&(g=this.util.createIri(c.resource,f,!1,!0,!0)),g||("href"in c||"src"in c?g=this.util.createIri(c.href||c.src,f,!1,!1,!0):"typeof"in c&&!("about"in c)&&!this.isInheritSubjectInHeadBody(l)&&(g=this.util.createBlankNode())),"typeof"in c&&!("about"in c)&&(this.isInheritSubjectInHeadBody(l)?m=b:m=g)),m)for(const w of this.util.createVocabIris(c.typeof,f,!0,!0))this.emitTriple(this.util.getResourceOrBaseIri(m,f),this.util.dataFactory.namedNode(r.Util.RDF+"type"),w);if(b&&(f.listMapping={}),g){if("rel"in c&&"inlist"in c)for(const w of this.util.createVocabIris(c.rel,f,p,!1))this.addListMapping(f,b,w,g);if(!("rel"in c&&"inlist"in c)){if("rel"in c)for(const w of this.util.createVocabIris(c.rel,f,p,!1))this.emitTriple(this.util.getResourceOrBaseIri(b,f),w,this.util.getResourceOrBaseIri(g,f));if("rev"in c)for(const w of this.util.createVocabIris(c.rev,f,y,!1))this.emitTriple(this.util.getResourceOrBaseIri(g,f),w,this.util.getResourceOrBaseIri(b,f))}}if(!g){if("rel"in c)if("inlist"in c)for(const w of this.util.createVocabIris(c.rel,f,p,!1))this.addListMapping(f,b,w,null),f.incompleteTriples.push({predicate:w,reverse:!1,list:!0});else for(const w of this.util.createVocabIris(c.rel,f,p,!1))f.incompleteTriples.push({predicate:w,reverse:!1});if("rev"in c)for(const w of this.util.createVocabIris(c.rev,f,y,!1))f.incompleteTriples.push({predicate:w,reverse:!0});f.incompleteTriples.length>0&&(g=this.util.createBlankNode())}if("property"in c){f.predicates=this.util.createVocabIris(c.property,f,!0,!1);let w;if("datatype"in c?(f.datatype=this.util.createIri(c.datatype,f,!0,!0,!1),f.datatype&&(f.datatype.value===r.Util.RDF+"XMLLiteral"||this.features.htmlDatatype&&f.datatype.value===r.Util.RDF+"HTML")&&(f.collectChildTags=!0)):(!("rev"in c)&&!("rel"in c)&&!("content"in c)&&("resource"in c&&(w=this.util.createIri(c.resource,f,!1,!0,!0)),!w&&"href"in c&&(w=this.util.createIri(c.href,f,!1,!1,!0)),!w&&"src"in c&&(w=this.util.createIri(c.src,f,!1,!1,!0))),"typeof"in c&&!("about"in c)&&(w=m)),"content"in c){const S=this.util.createLiteral(c.content,f);if("inlist"in c)for(const A of f.predicates)this.addListMapping(f,b,A,S);else{const A=this.util.getResourceOrBaseIri(b,f);for(const D of f.predicates)this.emitTriple(A,D,S)}f.predicates=null}else if(this.features.datetimeAttribute&&"datetime"in c){f.interpretObjectAsTime=!0;const S=this.util.createLiteral(c.datetime,f);if("inlist"in c)for(const A of f.predicates)this.addListMapping(f,b,A,S);else{const A=this.util.getResourceOrBaseIri(b,f);for(const D of f.predicates)this.emitTriple(A,D,S)}f.predicates=null}else if(w){const S=this.util.getResourceOrBaseIri(w,f);if("inlist"in c)for(const A of f.predicates)this.addListMapping(f,b,A,S);else{const A=this.util.getResourceOrBaseIri(b,f);for(const D of f.predicates)this.emitTriple(A,D,S)}f.predicates=null}}let _=!1;if(!f.skipElement&&b&&h.incompleteTriples.length>0){_=!0;const w=this.util.getResourceOrBaseIri(h.subject,f),S=this.util.getResourceOrBaseIri(b,f);for(const A of h.incompleteTriples)if(A.reverse)this.emitTriple(S,A.predicate,w);else if(A.list){let D=null;for(let L=this.activeTagStack.length-1;L>=0;L--)if(this.activeTagStack[L].inlist){D=this.activeTagStack[L];break}this.addListMapping(D,b,A.predicate,S)}else this.emitTriple(w,A.predicate,S)}!_&&h.incompleteTriples.length>0&&(f.incompleteTriples=f.incompleteTriples.concat(h.incompleteTriples)),f.subject=b||h.subject,f.object=g||b}onText(l){const c=this.activeTagStack[this.activeTagStack.length-1];if(this.features.copyRdfaPatterns&&c.collectedPatternTag){c.collectedPatternTag.text.push(l);return}c.text||(c.text=[]),c.text.push(l)}onTagClose(){const l=this.activeTagStack[this.activeTagStack.length-1],c=this.activeTagStack[this.activeTagStack.length-2];if(!(l.collectChildTags&&c.collectChildTags&&this.features.skipHandlingXmlLiteralChildren)){if(this.features.copyRdfaPatterns&&l.collectedPatternTag&&l.collectedPatternTag.rootPattern){const d=l.collectedPatternTag.attributes.resource;if(delete l.collectedPatternTag.attributes.resource,delete l.collectedPatternTag.attributes.typeof,this.rdfaPatterns[d]=l.collectedPatternTag,this.pendingRdfaPatternCopies[d]){for(const h of this.pendingRdfaPatternCopies[d])this.emitPatternCopy(h,l.collectedPatternTag,d);delete this.pendingRdfaPatternCopies[d]}this.activeTagStack.pop();return}if(l.predicates){const d=this.util.getResourceOrBaseIri(l.subject,l);let h=l.text||[];l.collectChildTags&&c.collectChildTags&&(h=h.slice(1));const f=this.util.createLiteral(h.join(""),l);if(l.inlist)for(const p of l.predicates)this.addListMapping(l,d,p,f);else for(const p of l.predicates)this.emitTriple(d,p,f);c.predicates||(l.text=null)}if(l.object&&Object.keys(l.listMapping).length>0){const d=this.util.getResourceOrBaseIri(l.object,l);for(const h in l.listMapping){const f=this.util.dataFactory.namedNode(h),p=l.listMapping[h];if(p.length>0){const y=p.map(()=>this.util.createBlankNode());for(let b=0;b`),l.text&&c&&(c.text?c.text=c.text.concat(l.text):c.text=l.text)}onEnd(){if(this.features.copyRdfaPatterns){this.features.copyRdfaPatterns=!1;for(const l in this.rdfaPatterns){const c=this.rdfaPatterns[l];c.referenced||(c.attributes.typeof="rdfa:Pattern",c.attributes.resource=l,this.emitPatternCopy(c.parentTag,c,l),c.referenced=!1,delete c.attributes.typeof,delete c.attributes.resource)}for(const l in this.pendingRdfaPatternCopies)for(const c of this.pendingRdfaPatternCopies[l])this.activeTagStack.push(c),this.onTagOpen("link",{property:"rdfa:copy",href:l}),this.onTagClose(),this.activeTagStack.pop();this.features.copyRdfaPatterns=!0}}isInheritSubjectInHeadBody(l){return this.features.inheritSubjectInHeadBody&&(l==="head"||l==="body")}addListMapping(l,c,d,h){if(l.explicitNewSubject){const f=this.util.createBlankNode();this.emitTriple(this.util.getResourceOrBaseIri(c,l),d,f),this.emitTriple(f,this.util.dataFactory.namedNode(r.Util.RDF+"first"),this.util.getResourceOrBaseIri(h,l)),this.emitTriple(f,this.util.dataFactory.namedNode(r.Util.RDF+"rest"),this.util.dataFactory.namedNode(r.Util.RDF+"nil"))}else{let f=l.listMappingLocal[d.value];f||(l.listMappingLocal[d.value]=f=[]),h&&f.push(h)}}emitTriple(l,c,d){l.termType==="NamedNode"&&l.value.indexOf(":")<0||c.termType==="NamedNode"&&c.value.indexOf(":")<0||d.termType==="NamedNode"&&d.value.indexOf(":")<0||this.push(this.util.dataFactory.quad(l,c,d,this.defaultGraph))}emitPatternCopy(l,c,d){if(this.activeTagStack.push(l),c.referenced=!0,!c.constructedBlankNodes)c.constructedBlankNodes=[],this.util.blankNodeFactory=()=>{const h=this.util.dataFactory.blankNode();return c.constructedBlankNodes.push(h),h};else{let h=0;this.util.blankNodeFactory=()=>c.constructedBlankNodes[h++]}this.emitPatternCopyAbsolute(c,!0,d),this.util.blankNodeFactory=null,this.activeTagStack.pop()}emitPatternCopyAbsolute(l,c,d){if(!(!c&&l.attributes.property==="rdfa:copy"&&l.attributes.href===d)){this.onTagOpen(l.name,l.attributes);for(const h of l.text)this.onText(h);for(const h of l.children)this.emitPatternCopyAbsolute(h,!1,d);this.onTagClose()}}initializeParser(l){return new t.Parser({onclosetag:()=>{try{this.onTagClose(),this.htmlParseListener&&this.htmlParseListener.onTagClose()}catch(c){this.emit("error",c)}},onend:()=>{try{this.onEnd(),this.htmlParseListener&&this.htmlParseListener.onEnd()}catch(c){this.emit("error",c)}},onopentag:(c,d)=>{try{this.onTagOpen(c,d),this.htmlParseListener&&this.htmlParseListener.onTagOpen(c,d)}catch(h){this.emit("error",h)}},ontext:c=>{try{this.onText(c),this.htmlParseListener&&this.htmlParseListener.onText(c)}catch(d){this.emit("error",d)}}},{decodeEntities:!0,recognizeSelfClosing:!0,xmlMode:l})}};return Fl.RdfaParser=a,Fl}var vN;function p7(){return vN||(vN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(qJ(),t),u(BJ(),t),u(UJ(),t),u(eX(),t),u(oA(),t),u(f7(),t)}(qv)),qv}var wN;function tX(){if(wN)return Ml;wN=1,Object.defineProperty(Ml,"__esModule",{value:!0}),Ml.ActorRdfParseXmlRdfa=void 0;const t=su(),e=p7();let u=class extends t.ActorRdfParseFixedMediaTypes{constructor(n){super(n)}async runHandle(n,r,a){var c;const o=(n.headers&&n.headers.get("content-language"))??void 0;n.data.on("error",d=>l.emit("error",d));const l=n.data.pipe(new e.RdfaParser({baseIRI:(c=n.metadata)==null?void 0:c.baseIRI,profile:"xml",language:o}));return{data:l,metadata:{triples:!0}}}};return Ml.ActorRdfParseXmlRdfa=u,Ml}var SN;function rX(){return SN||(SN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(tX(),t)}(Fv)),Fv}var Yv={},Ql={},w1={},Hl={},TN;function y7(){if(TN)return Hl;TN=1,Object.defineProperty(Hl,"__esModule",{value:!0}),Hl.promisifyEventEmitter=void 0;function t(e,u){return new Promise((s,n)=>{e.on("end",()=>s(u)),e.on("error",n)})}return Hl.promisifyEventEmitter=t,Hl}var AN;function ou(){if(AN)return w1;AN=1;var t=I&&I.__awaiter||function(s,n,r,a){function o(l){return l instanceof r?l:new r(function(c){c(l)})}return new(r||(r=Promise))(function(l,c){function d(p){try{f(a.next(p))}catch(y){c(y)}}function h(p){try{f(a.throw(p))}catch(y){c(y)}}function f(p){p.done?l(p.value):o(p.value).then(d,h)}f((a=a.apply(s,n||[])).next())})};Object.defineProperty(w1,"__esModule",{value:!0}),w1.stringify=u;const e=y7();function u(s){return t(this,void 0,void 0,function*(){let n="";return s.on("data",r=>{n+=r}),yield(0,e.promisifyEventEmitter)(s),n})}return w1}var S1={},Zv,EN;function nX(){if(EN)return Zv;EN=1;var t=function(){var e=function(Ye,$e,Je,nt){for(Je=Je||{},nt=Ye.length;nt--;Je[Ye[nt]]=$e);return Je},u=[7,12,13,14,15,16,20,25,115,130],s=[7,13,16,20,25,115,130],n=[7,13,16,115,130],r=[1,25],a=[1,29],o=[1,27],l=[1,28],c=[13,16,115,130],d=[13,16,28,38,40,42,44,46,48,53,56,61,67,85,87,92,93,95,96,102,110,111,115,119,120,126,128,129,130,131,132,133,134,135,136],h=[28,56],f=[1,42],p=[46,48,53,56],y=[1,54],b=[1,60],g=[1,56],m=[1,57],v=[1,58],_=[1,63],w=[1,64],S=[1,65],A=[1,66],D=[1,67],L=[1,68],O=[1,75],E=[28,46,48,53,56],P=[28,42,46,48,53,56],M=[13,16,28,38,40,42,44,46,48,53,56,92,115,119,120,130,131,132,133,134,135,136],U=[13,16,28,38,40,42,44,46,48,53,56,67,85,87,92,95,96,115,119,120,126,128,129,130,131,132,133,134,135,136],j=[13,16,38,40,44,92,115,119,120,130,131,132,133,134,135,136],q=[13,16,28,38,40,42,44,46,48,53,56,67,85,87,92,95,96,115,117,118,119,120,126,128,129,130,131,132,133,134,135,136],$=[13,16,28,56,115,130],Z=[13,16,38,58,87,96,109,115,126,130],X=[1,116],le=[1,112],K=[1,108],he=[1,114],Re=[1,111],ie=[7,13,16,20,25,44,48,53,56,67,85,87,95,96,115,128,129,130],ae=[48,53],Ee=[48,53,87,96,126],De=[13,16,44,48,53,56,85,87,95,96,115,128,129,130],ge=[1,126],de=[13,16,40,44,48,53,56,85,87,95,96,115,128,129,130],fe=[1,129],H=[48,53,67,87,96,126],N=[13,16,40,44,48,53,56,67,85,87,95,96,115,128,129,130],R=[1,133],T=[13,16,40,44,48,53,56,67,85,87,95,96,102,115,128,129,130],x=[13,16,40,44,48,53,56,67,85,87,93,95,96,102,110,111,115,128,129,130],B=[1,151],k=[1,153],V=[1,156],J=[1,157],z=[1,158],Y=[1,167],re=[1,175],ce=[13,16,44,48,53,56,67,85,87,95,96,115,128,129,130],Te=[13,16,44,48,53,56,67,85,87,95,96,115,126,128,129,130],xe=[13,16,46,92,115,119,120,130,131,132,133,134,135,136],Le={trace:function(){},yy:{},symbols_:{error:2,shaclDoc:3,shaclDoc_repetition0:4,shaclDoc_repetition1:5,ttlSection:6,EOF:7,directive:8,baseDecl:9,importsDecl:10,prefixDecl:11,KW_BASE:12,IRIREF:13,KW_IMPORTS:14,KW_PREFIX:15,PNAME_NS:16,nodeShapeIri:17,iri:18,nodeShape:19,KW_SHAPE:20,nodeShape_option0:21,nodeShape_option1:22,nodeShapeBody:23,shapeClass:24,KW_SHAPE_CLASS:25,shapeClass_option0:26,turtleAnnotation:27,";":28,turtleAnnotation2:29,predicate:30,turtleAnnotation2_option0:31,objectList:32,object:33,objectList_repetition0:34,iriOrLiteral:35,blankNodeSection:36,list:37,"(":38,list_repetition0:39,")":40,objectTail:41,",":42,LB:43,"[":44,RB:45,"]":46,LP:47,"%":48,RP:49,pcSection:50,iriHead:51,ttlStatement:52,".":53,ttlSection_repetition0:54,startNodeShape:55,"{":56,endNodeShape:57,"}":58,nodeShapeBody_repetition0:59,targetClass:60,"->":61,targetClass_repetition_plus0:62,constraint:63,constraint_group0:64,constraint_option0:65,orNotComponent:66,"|":67,nodeNot:68,nodeOrEmit:69,nodeOr:70,nodeOr_repetition_plus0:71,nodeValue:72,negation:73,nodeValue_group0:74,"=":75,iriOrLiteralOrArray:76,propertyShape:77,path:78,propertyShape_repetition0:79,propertyOrComponent:80,propertyNot:81,propertyOr:82,propertyOr_repetition_plus0:83,propertyAtom:84,NODEKIND:85,shapeRef:86,PARAM:87,propertyCount:88,propertyMinCount:89,"..":90,propertyMaxCount:91,INTEGER:92,"*":93,shapeRef_group0:94,"@":95,"!":96,pathAlternative:97,additionalAlternative:98,pathSequence:99,pathAlternative_repetition_plus0:100,additionalSequence:101,"/":102,pathEltOrInverse:103,pathSequence_repetition_plus0:104,pathElt:105,pathPrimary:106,pathMod:107,pathInverse:108,"^":109,"?":110,"+":111,iriOrLiteralOrArray_repetition0:112,literal:113,iri_group0:114,a:115,string:116,LANGTAG:117,"^^":118,DECIMAL:119,DOUBLE:120,literal_group0:121,string_group0:122,string_group1:123,shaclDoc_repetition1_group0:124,constraint_group0_repetition_plus0:125,TARGET:126,propertyShape_repetition0_group0:127,ATPNAME_LN:128,ATPNAME_NS:129,PNAME_LN:130,KW_TRUE:131,KW_FALSE:132,STRING_LITERAL1:133,STRING_LITERAL2:134,STRING_LITERAL_LONG1:135,STRING_LITERAL_LONG2:136,$accept:0,$end:1},terminals_:{2:"error",7:"EOF",12:"KW_BASE",13:"IRIREF",14:"KW_IMPORTS",15:"KW_PREFIX",16:"PNAME_NS",20:"KW_SHAPE",25:"KW_SHAPE_CLASS",28:";",38:"(",40:")",42:",",44:"[",46:"]",48:"%",53:".",56:"{",58:"}",61:"->",67:"|",75:"=",85:"NODEKIND",87:"PARAM",90:"..",92:"INTEGER",93:"*",95:"@",96:"!",102:"/",109:"^",110:"?",111:"+",115:"a",117:"LANGTAG",118:"^^",119:"DECIMAL",120:"DOUBLE",126:"TARGET",128:"ATPNAME_LN",129:"ATPNAME_NS",130:"PNAME_LN",131:"KW_TRUE",132:"KW_FALSE",133:"STRING_LITERAL1",134:"STRING_LITERAL2",135:"STRING_LITERAL_LONG1",136:"STRING_LITERAL_LONG2"},productions_:[0,[3,4],[8,1],[8,1],[8,1],[9,2],[10,2],[11,3],[17,1],[19,5],[24,4],[27,2],[29,2],[30,2],[32,2],[33,1],[33,1],[33,1],[37,3],[41,2],[43,1],[45,1],[36,3],[47,1],[49,1],[50,3],[51,1],[52,3],[6,1],[55,1],[57,1],[23,3],[60,2],[63,3],[66,2],[69,1],[70,1],[70,2],[68,1],[68,2],[72,3],[77,2],[80,2],[82,1],[82,2],[81,1],[81,2],[84,1],[84,1],[84,1],[84,3],[84,1],[88,5],[89,1],[91,1],[91,1],[86,1],[86,2],[73,1],[78,1],[98,2],[97,1],[97,2],[101,2],[99,1],[99,2],[105,1],[105,2],[103,1],[103,2],[108,1],[107,1],[107,1],[107,1],[106,1],[106,3],[76,1],[76,3],[35,1],[35,1],[18,1],[18,1],[18,1],[113,1],[113,2],[113,3],[113,1],[113,1],[113,1],[113,1],[116,1],[116,1],[4,0],[4,2],[124,1],[124,1],[5,0],[5,2],[21,0],[21,1],[22,0],[22,1],[26,0],[26,1],[31,0],[31,1],[34,0],[34,2],[39,0],[39,2],[54,0],[54,2],[59,0],[59,2],[62,1],[62,2],[125,1],[125,2],[64,1],[64,1],[65,0],[65,1],[71,1],[71,2],[74,1],[74,1],[127,1],[127,1],[79,0],[79,2],[83,1],[83,2],[94,1],[94,1],[100,1],[100,2],[104,1],[104,2],[112,0],[112,2],[114,1],[114,1],[121,1],[121,1],[122,1],[122,1],[123,1],[123,1]],performAction:function($e,Je,nt,yt,ft,et,Ir){var Ke=et.length-1;switch(ft){case 1:this.$=C(Fe.factory.namedNode(je("")),Fe.factory.namedNode(G),Fe.factory.namedNode(we+"Ontology"));break;case 5:Fe.base=Fe.factory.namedNode(et[Ke].slice(1,-1)),Fe.n3Parser._setBase(Fe.base.value);break;case 6:this.$=C(Fe.base,Fe.factory.namedNode(we+"imports"),Fe.factory.namedNode(et[Ke].slice(1,-1)));break;case 7:this.$=Fe.prefixes[et[Ke-1].substr(0,et[Ke-1].length-1)]=je(et[Ke]);break;case 8:Fe.nodeShapeStack=!1,C(Fe.currentNodeShape=et[Ke],Fe.factory.namedNode(G),Fe.factory.namedNode(pe+"NodeShape"));break;case 10:this.$=C(Fe.currentNodeShape,Fe.factory.namedNode(G),Fe.factory.namedNode(W+"Class"));break;case 11:this.$=Pe();break;case 13:this.$=et[Ke].forEach(Me=>C(Fe.currentNodeShape,et[Ke-1],Me));break;case 14:this.$=[et[Ke-1],...et[Ke]];break;case 18:this.$=Ae(et[Ke-1],!0);break;case 19:case 34:case 42:case 60:case 63:this.$=et[Ke];break;case 20:Fe.tempCurrentNodeShape=Fe.currentNodeShape,this.$=Fe.currentNodeShape=lt();break;case 21:Fe.currentNodeShape=Fe.tempCurrentNodeShape;break;case 22:case 31:this.$=et[Ke-2];break;case 23:Fe.tempCurrentNodeShape=Fe.currentNodeShape,Fe.currentNodeShape=Fe.currentPropertyNode;break;case 24:Fe.currentNodeShape=Fe.tempCurrentNodeShape;break;case 26:Fe.currentNodeShape=et[Ke];break;case 29:Fe.nodeShapeStack?(Fe.nodeShapeStack.push(Fe.currentNodeShape),C(Fe.currentPropertyNode,Fe.factory.namedNode(pe+"node"),Fe.currentNodeShape=lt())):Fe.nodeShapeStack=[],this.$=Fe.currentNodeShape;break;case 30:Fe.nodeShapeStack.length>0&&(Fe.currentNodeShape=Fe.nodeShapeStack.pop());break;case 32:this.$=et[Ke].forEach(Me=>{C(Fe.currentNodeShape,Fe.factory.namedNode(pe+"targetClass"),Me)});break;case 35:this.$=C(Fe.currentNodeShape,Fe.factory.namedNode(pe+et[Ke][0]),et[Ke][1]);break;case 36:break;case 37:const be=Ae([et[Ke-1],...et[Ke]].map(Me=>{const it=lt();return C(it,Fe.factory.namedNode(pe+Me[0]),Me[1]),it}));this.$=["or",be];break;case 39:case 46:this.$=ye("not",...et[Ke]);break;case 40:case 50:this.$=[et[Ke-2],et[Ke]];break;case 43:this.$=et[Ke]&&ee(...et[Ke]);break;case 44:this.$=ee("or",Ae([et[Ke-1],...et[Ke]].map(Me=>{const it=lt();return C(it,Fe.factory.namedNode(pe+Me[0]),Me[1]),it})));break;case 47:this.$=[Se[et[Ke].value]?"datatype":"class",et[Ke]];break;case 48:this.$=["nodeKind",Fe.factory.namedNode(pe+et[Ke])];break;case 49:this.$=["node",Fe.factory.namedNode(et[Ke])];break;case 51:this.$=void 0;break;case 53:this.$=et[Ke]>0&&ee("minCount",Ge(et[Ke],Oe));break;case 54:this.$=ee("maxCount",Ge(et[Ke],Oe));break;case 56:this.$=He(et[Ke].slice(1));break;case 57:this.$=je(et[Ke]);break;case 59:C(Fe.currentNodeShape,Fe.factory.namedNode(pe+"property"),Fe.currentPropertyNode=lt()),ee("path",et[Ke]);break;case 62:const Ie=lt();C(Ie,Fe.factory.namedNode(pe+"alternativePath"),Ae([et[Ke-1],...et[Ke]])),this.$=Ie;break;case 65:this.$=Ae([et[Ke-1],...et[Ke]]);break;case 67:C(this.$=lt(),Fe.factory.namedNode(pe+et[Ke]),et[Ke-1]);break;case 69:C(this.$=lt(),Fe.factory.namedNode(pe+"inversePath"),et[Ke]);break;case 71:this.$="zeroOrOnePath";break;case 72:this.$="zeroOrMorePath";break;case 73:this.$="oneOrMorePath";break;case 75:this.$=et[Ke-1];break;case 77:this.$=Ae(et[Ke-1]);break;case 80:this.$=Fe.factory.namedNode(je(et[Ke]));break;case 81:this.$=Fe.factory.namedNode(He(et[Ke]));break;case 82:this.$=Pe(Fe.factory.namedNode(G));break;case 83:this.$=Ge(et[Ke]);break;case 84:this.$=tt(et[Ke-1],lowercase(et[Ke].substr(1)));break;case 85:this.$=Ge(et[Ke-2],et[Ke]);break;case 86:this.$=Ge(et[Ke],Oe);break;case 87:this.$=Ge(et[Ke],Ne);break;case 88:this.$=Ge(et[Ke].toLowerCase(),We);break;case 89:this.$=Ge(et[Ke].toLowerCase(),Ve);break;case 90:this.$=oe(et[Ke],1);break;case 91:this.$=oe(et[Ke],3);break;case 92:case 96:case 106:case 108:case 110:case 112:case 128:case 138:this.$=[];break;case 93:case 97:case 107:case 109:case 111:case 113:case 115:case 117:case 123:case 129:case 131:case 135:case 137:case 139:et[Ke-1].push(et[Ke]);break;case 114:case 116:case 122:case 130:case 134:case 136:this.$=[et[Ke]];break}},table:[e(u,[2,92],{3:1,4:2}),{1:[3]},e(s,[2,96],{5:3,8:4,9:5,10:6,11:7,12:[1,8],14:[1,9],15:[1,10]}),e(n,[2,110],{6:11,124:12,54:13,19:14,24:15,20:[1,16],25:[1,17]}),e(u,[2,93]),e(u,[2,2]),e(u,[2,3]),e(u,[2,4]),{13:[1,18]},{13:[1,19]},{16:[1,20]},{7:[1,21]},e(s,[2,97]),{7:[2,28],13:r,16:a,18:24,51:23,52:22,114:26,115:o,130:l},e(s,[2,94]),e(s,[2,95]),{13:r,16:a,17:30,18:31,114:26,115:o,130:l},{13:r,16:a,17:32,18:31,114:26,115:o,130:l},e(u,[2,5]),e(u,[2,6]),{13:[1,33]},{1:[2,1]},e(n,[2,111]),{13:r,16:a,18:36,29:34,30:35,114:26,115:o,130:l},e(c,[2,26]),e(d,[2,80]),e(d,[2,81]),e(d,[2,82]),e(d,[2,140]),e(d,[2,141]),e(h,[2,98],{21:37,60:38,61:[1,39]}),e([28,56,61],[2,8]),{26:40,27:41,28:f,56:[2,102]},e(u,[2,7]),{53:[1,43]},e(p,[2,104],{31:44,27:45,28:f}),{13:r,16:a,18:51,32:46,33:47,35:48,36:49,37:50,38:y,43:53,44:b,92:g,113:52,114:26,115:o,116:55,119:m,120:v,121:59,122:61,123:62,130:l,131:_,132:w,133:S,134:A,135:D,136:L},{22:69,27:70,28:f,56:[2,100]},e(h,[2,99]),{13:r,16:a,18:72,62:71,114:26,115:o,130:l},{23:73,55:74,56:O},{56:[2,103]},{13:r,16:a,18:36,29:76,30:35,114:26,115:o,130:l},e(n,[2,27]),e(p,[2,12]),e(p,[2,105]),e(E,[2,13]),e(P,[2,106],{34:77}),e(M,[2,15]),e(M,[2,16]),e(M,[2,17]),e(U,[2,78]),e(U,[2,79]),{13:r,16:a,18:36,29:78,30:35,114:26,115:o,130:l},e(j,[2,108],{39:79}),e(U,[2,83],{117:[1,80],118:[1,81]}),e(U,[2,86]),e(U,[2,87]),e(U,[2,88]),e(U,[2,89]),e(c,[2,20]),e(q,[2,90]),e(q,[2,91]),e(U,[2,142]),e(U,[2,143]),e(q,[2,144]),e(q,[2,145]),e(q,[2,146]),e(q,[2,147]),{23:82,55:74,56:O},{56:[2,101]},e(h,[2,32],{114:26,18:83,13:r,16:a,115:o,130:l}),e($,[2,114]),e(s,[2,10]),e(Z,[2,112],{59:84}),e(Z,[2,29]),e(p,[2,11]),e(E,[2,14],{41:85,42:[1,86]}),{45:87,46:[1,88]},{13:r,16:a,18:51,33:90,35:48,36:49,37:50,38:y,40:[1,89],43:53,44:b,92:g,113:52,114:26,115:o,116:55,119:m,120:v,121:59,122:61,123:62,130:l,131:_,132:w,133:S,134:A,135:D,136:L},e(U,[2,84]),{13:r,16:a,18:91,114:26,115:o,130:l},e(s,[2,9]),e($,[2,115]),{13:r,16:a,18:115,38:X,57:92,58:[1,94],63:93,64:95,68:102,69:98,70:100,72:104,73:105,74:107,77:97,78:99,87:le,96:K,97:101,99:103,103:106,105:109,106:113,108:110,109:he,114:26,115:o,125:96,126:Re,130:l},e(P,[2,107]),{13:r,16:a,18:51,33:117,35:48,36:49,37:50,38:y,43:53,44:b,92:g,113:52,114:26,115:o,116:55,119:m,120:v,121:59,122:61,123:62,130:l,131:_,132:w,133:S,134:A,135:D,136:L},e(M,[2,22]),e(M,[2,21]),e(M,[2,18]),e(j,[2,109]),e(U,[2,85]),e(ie,[2,31]),e(Z,[2,113]),e(ie,[2,30]),{47:120,48:[1,121],50:119,53:[2,120],65:118},e(ae,[2,118],{70:100,68:102,72:104,73:105,74:107,69:122,87:le,96:K,126:Re}),e(ae,[2,119]),e(Ee,[2,116]),e(De,[2,128],{79:123}),e(Ee,[2,35]),e(De,[2,59]),e(Ee,[2,36],{71:124,66:125,67:ge}),e(de,[2,61],{100:127,98:128,67:fe}),e(H,[2,38]),{72:130,74:107,87:le,126:Re},e(N,[2,64],{104:131,101:132,102:R}),{75:[1,134]},e([13,16,56,85,87,95,115,126,128,129,130],[2,58]),e(T,[2,68]),{13:r,16:a,18:115,38:X,105:135,106:113,114:26,115:o,130:l},{75:[2,124]},{75:[2,125]},e(T,[2,66],{107:136,93:[1,138],110:[1,137],111:[1,139]}),e([13,16,38,115,130],[2,70]),e(x,[2,74]),{13:r,16:a,18:115,38:X,97:140,99:103,103:106,105:109,106:113,108:110,109:he,114:26,115:o,130:l},e(P,[2,19]),{53:[1,141]},{53:[2,121]},{13:r,16:a,18:36,29:142,30:35,114:26,115:o,130:l},e(c,[2,23]),e(Ee,[2,117]),e(ae,[2,41],{114:26,55:74,127:143,88:144,82:145,81:147,84:148,73:149,18:150,86:152,23:154,94:155,13:r,16:a,44:[1,146],56:O,85:B,87:k,95:V,96:K,115:o,128:J,129:z,130:l}),e(Ee,[2,37],{66:159,67:ge}),e(H,[2,122]),{68:160,72:104,73:105,74:107,87:le,96:K,126:Re},e(de,[2,62],{98:161,67:fe}),e(N,[2,134]),{13:r,16:a,18:115,38:X,99:162,103:106,105:109,106:113,108:110,109:he,114:26,115:o,130:l},e(H,[2,39]),e(N,[2,65],{101:163,102:R}),e(T,[2,136]),{13:r,16:a,18:115,38:X,103:164,105:109,106:113,108:110,109:he,114:26,115:o,130:l},{13:r,16:a,18:51,35:166,44:Y,76:165,92:g,113:52,114:26,115:o,116:55,119:m,120:v,121:59,122:61,123:62,130:l,131:_,132:w,133:S,134:A,135:D,136:L},e(T,[2,69]),e(T,[2,67]),e(T,[2,71]),e(T,[2,72]),e(T,[2,73]),{40:[1,168]},e(Z,[2,33]),{48:[1,170],49:169},e(De,[2,129]),e(De,[2,126]),e(De,[2,127]),{89:171,92:[1,172]},e(De,[2,43],{83:173,80:174,67:re}),e(ce,[2,45]),{13:r,16:a,18:150,23:154,55:74,56:O,84:176,85:B,86:152,87:k,94:155,95:V,114:26,115:o,128:J,129:z,130:l},e(ce,[2,47]),e(ce,[2,48]),e(ce,[2,49]),{75:[1,177]},e(ce,[2,51]),e(ce,[2,56]),{13:[1,178]},e(ce,[2,132]),e(ce,[2,133]),e(H,[2,123]),e(H,[2,34]),e(N,[2,135]),e(N,[2,60]),e(T,[2,137]),e(T,[2,63]),e(H,[2,40]),e(Te,[2,76]),e(xe,[2,138],{112:179}),e(x,[2,75]),{53:[2,25]},{53:[2,24]},{90:[1,180]},{90:[2,53]},e(De,[2,44],{80:181,67:re}),e(ce,[2,130]),{13:r,16:a,18:150,23:154,55:74,56:O,73:149,81:182,84:148,85:B,86:152,87:k,94:155,95:V,96:K,114:26,115:o,128:J,129:z,130:l},e(ce,[2,46]),{13:r,16:a,18:51,35:166,44:Y,76:183,92:g,113:52,114:26,115:o,116:55,119:m,120:v,121:59,122:61,123:62,130:l,131:_,132:w,133:S,134:A,135:D,136:L},e(ce,[2,57]),{13:r,16:a,18:51,35:185,46:[1,184],92:g,113:52,114:26,115:o,116:55,119:m,120:v,121:59,122:61,123:62,130:l,131:_,132:w,133:S,134:A,135:D,136:L},{91:186,92:[1,187],93:[1,188]},e(ce,[2,131]),e(ce,[2,42]),e(ce,[2,50]),e(Te,[2,77]),e(xe,[2,139]),{46:[1,189]},{46:[2,54]},{46:[2,55]},e(De,[2,52])],defaultActions:{21:[2,1],41:[2,103],70:[2,101],111:[2,124],112:[2,125],119:[2,121],169:[2,25],170:[2,24],172:[2,53],187:[2,54],188:[2,55]},parseError:function($e,Je){if(Je.recoverable)this.trace($e);else{var nt=new Error($e);throw nt.hash=Je,nt}},parse:function($e){var Je=this,nt=[0],yt=[null],ft=[],et=this.table,Ir="",Ke=0,be=0,Ie=2,Me=1,it=ft.slice.call(arguments,1),at=Object.create(this.lexer),Tt={yy:{}};for(var Vt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,Vt)&&(Tt.yy[Vt]=this.yy[Vt]);at.setInput($e,Tt.yy),Tt.yy.lexer=at,Tt.yy.parser=this,typeof at.yylloc>"u"&&(at.yylloc={});var rr=at.yylloc;ft.push(rr);var fi=at.options&&at.options.ranges;typeof Tt.yy.parseError=="function"?this.parseError=Tt.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var bn=function(){var Xr;return Xr=at.lex()||Me,typeof Xr!="number"&&(Xr=Je.symbols_[Xr]||Xr),Xr},or,Ln,Qr,Qn,Pr={},hi,Mr,Ni,Zi;;){if(Ln=nt[nt.length-1],this.defaultActions[Ln]?Qr=this.defaultActions[Ln]:((or===null||typeof or>"u")&&(or=bn()),Qr=et[Ln]&&et[Ln][or]),typeof Qr>"u"||!Qr.length||!Qr[0]){var mn="";Zi=[];for(hi in et[Ln])this.terminals_[hi]&&hi>Ie&&Zi.push("'"+this.terminals_[hi]+"'");at.showPosition?mn="Parse error on line "+(Ke+1)+`: +`+at.showPosition()+` +Expecting `+Zi.join(", ")+", got '"+(this.terminals_[or]||or)+"'":mn="Parse error on line "+(Ke+1)+": Unexpected "+(or==Me?"end of input":"'"+(this.terminals_[or]||or)+"'"),this.parseError(mn,{text:at.match,token:this.terminals_[or]||or,line:at.yylineno,loc:rr,expected:Zi})}if(Qr[0]instanceof Array&&Qr.length>1)throw new Error("Parse Error: multiple actions possible at state: "+Ln+", token: "+or);switch(Qr[0]){case 1:nt.push(or),yt.push(at.yytext),ft.push(at.yylloc),nt.push(Qr[1]),or=null,be=at.yyleng,Ir=at.yytext,Ke=at.yylineno,rr=at.yylloc;break;case 2:if(Mr=this.productions_[Qr[1]][1],Pr.$=yt[yt.length-Mr],Pr._$={first_line:ft[ft.length-(Mr||1)].first_line,last_line:ft[ft.length-1].last_line,first_column:ft[ft.length-(Mr||1)].first_column,last_column:ft[ft.length-1].last_column},fi&&(Pr._$.range=[ft[ft.length-(Mr||1)].range[0],ft[ft.length-1].range[1]]),Qn=this.performAction.apply(Pr,[Ir,be,Ke,Tt.yy,Qr[1],yt,ft].concat(it)),typeof Qn<"u")return Qn;Mr&&(nt=nt.slice(0,-1*Mr*2),yt=yt.slice(0,-1*Mr),ft=ft.slice(0,-1*Mr)),nt.push(this.productions_[Qr[1]][0]),yt.push(Pr.$),ft.push(Pr._$),Ni=et[nt[nt.length-2]][nt[nt.length-1]],nt.push(Ni);break;case 3:return!0}}return!0}};const qe="http://www.w3.org/1999/02/22-rdf-syntax-ns#",G=qe+"type",F=qe+"first",Q=qe+"rest",te=qe+"nil",me="http://www.w3.org/2001/XMLSchema#",Oe=me+"integer",Ne=me+"decimal",We=me+"double",Ve=me+"boolean",pe="http://www.w3.org/ns/shacl#",we="http://www.w3.org/2002/07/owl#",W="http://www.w3.org/2000/01/rdf-schema#",Se={[Oe]:!0,[Ne]:!0,[me+"float"]:!0,[We]:!0,[me+"string"]:!0,[Ve]:!0,[me+"dateTime"]:!0,[me+"nonPositiveInteger"]:!0,[me+"negativeInteger"]:!0,[me+"long"]:!0,[me+"int"]:!0,[me+"short"]:!0,[me+"byte"]:!0,[me+"nonNegativeInteger"]:!0,[me+"unsignedLong"]:!0,[me+"unsignedShort"]:!0,[me+"unsignedByte"]:!0,[me+"positiveInteger"]:!0,[qe+"langString"]:!0};function Ae(Ye,$e=!1){let Je=0,nt=Ye.length;if($e&&nt===0)return Fe.factory.namedNode(te);const yt=head=lt();return nt===0&&C(head,Fe.factory.namedNode(Q),Fe.factory.namedNode(te)),Ye.forEach(ft=>{if(ft===void 0)throw new Error("b");C(head,Fe.factory.namedNode(F),ft),C(head,Fe.factory.namedNode(Q),head=++Je20?"...":"")+$e.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var $e=this.match;return $e.length<20&&($e+=this._input.substr(0,20-$e.length)),($e.substr(0,20)+($e.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var $e=this.pastInput(),Je=new Array($e.length+1).join("-");return $e+this.upcomingInput()+` +`+Je+"^"},test_match:function($e,Je){var nt,yt,ft;if(this.options.backtrack_lexer&&(ft={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(ft.yylloc.range=this.yylloc.range.slice(0))),yt=$e[0].match(/(?:\r\n?|\n).*/g),yt&&(this.yylineno+=yt.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:yt?yt[yt.length-1].length-yt[yt.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+$e[0].length},this.yytext+=$e[0],this.match+=$e[0],this.matches=$e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice($e[0].length),this.matched+=$e[0],nt=this.performAction.call(this,this.yy,this,Je,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),nt)return nt;if(this._backtrack){for(var et in ft)this[et]=ft[et];return!1}return!1},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var $e,Je,nt,yt;this._more||(this.yytext="",this.match="");for(var ft=this._currentRules(),et=0;etJe[0].length)){if(Je=nt,yt=et,this.options.backtrack_lexer){if($e=this.test_match(nt,ft[et]),$e!==!1)return $e;if(this._backtrack){Je=!1;continue}else return!1}else if(!this.options.flex)break}return Je?($e=this.test_match(Je,ft[yt]),$e!==!1?$e:!1):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var Je=this.next();return Je||this.lex()},begin:function(Je){this.conditionStack.push(Je)},popState:function(){var Je=this.conditionStack.length-1;return Je>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(Je){return Je=this.conditionStack.length-1-Math.abs(Je||0),Je>=0?this.conditionStack[Je]:"INITIAL"},pushState:function(Je){this.begin(Je)},stateStackSize:function(){return this.conditionStack.length},options:{flex:!0,"case-insensitive":!0},performAction:function(Je,nt,yt,ft){switch(yt){case 0:break;case 1:return 12;case 2:return 14;case 3:return 15;case 4:return 25;case 5:return 20;case 6:return 131;case 7:return 132;case 8:return 85;case 9:return 126;case 10:return 87;case 11:return"PASS";case 12:return"COMMENT";case 13:return 13;case 14:return 16;case 15:return 130;case 16:return 129;case 17:return 128;case 18:return 117;case 19:return 92;case 20:return 119;case 21:return 120;case 22:return"EXPONENT";case 23:return 133;case 24:return 134;case 25:return 135;case 26:return 136;case 27:return 61;case 28:return 90;case 29:return 58;case 30:return 56;case 31:return 38;case 32:return 40;case 33:return 44;case 34:return 46;case 35:return 110;case 36:return 93;case 37:return 111;case 38:return 67;case 39:return 118;case 40:return 53;case 41:return 96;case 42:return 102;case 43:return 75;case 44:return 95;case 45:return 109;case 46:return 28;case 47:return 42;case 48:return 48;case 49:return 115;case 50:return 7;case 51:console.log(nt.yytext);break}},rules:[/^(?:\s+|#[^\n\r]*)/i,/^(?:BASE)/i,/^(?:IMPORTS)/i,/^(?:PREFIX)/i,/^(?:shapeClass)/i,/^(?:shape)/i,/^(?:true)/i,/^(?:false)/i,/^(?:(BlankNode|IRI|Literal|BlankNodeOrIRI|BlankNodeOrLiteral|IRIOrLiteral\b))/i,/^(?:(targetNode|targetObjectsOf|targetSubjectsOf\b))/i,/^(?:(deactivated|severity|message|class|datatype|nodeKind|minExclusive|minInclusive|maxExclusive|maxInclusive|minLength|maxLength|pattern|flags|languageIn|uniqueLang|equals|disjoint|lessThan|lessThanOrEquals|qualifiedValueShape|qualifiedMinCount|qualifiedMaxCount|qualifiedValueShapesDisjoint|closed|ignoredProperties|hasValue|in))/i,/^(?:([ \t\r\n]+))/i,/^(?:(#[\r\n]*))/i,/^(?:(<([^=<>\"\{\}\|\^`\\\u0000-\u0020]|(\\u([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])|\\U([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])))*>))/i,/^(?:((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])((((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|\.)*((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040]))?)?:))/i,/^(?:(((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])((((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|\.)*((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040]))?)?:)(((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|:|[0-9]|((%([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%))))((((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|\.|:|((%([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%))))*(((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|:|((%([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%)))))?)))/i,/^(?:(@(([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])((((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|\.)*((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040]))?)?:))/i,/^(?:(@((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])((((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|\.)*((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040]))?)?:)(((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|:|[0-9]|((%([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%))))((((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|\.|:|((%([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%))))*(((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|:|((%([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%)))))?)))/i,/^(?:(@[a-zA-Z]+(-[a-zA-Z0-9]+)*))/i,/^(?:([+-]?[0-9]+))/i,/^(?:([+-]?[0-9]*\.[0-9]+))/i,/^(?:([+-]?([0-9]+\.[0-9]*([eE][+-]?[0-9]+)|\.?[0-9]+([eE][+-]?[0-9]+))))/i,/^(?:([eE][+-]?[0-9]+))/i,/^(?:('(?:(?:[^\u0027\u005C\u000A\u000D])|(\\[tbnrf\\\"\']))*'))/i,/^(?:("(?:(?:[^\u0022\u005C\u000A\u000D])|(\\[tbnrf\\\"\']))*"))/i,/^(?:('''(?:(?:'|'')?(?:[^'\\]|(\\[tbnrf\\\"\'])))*'''))/i,/^(?:("""(?:(?:"|"")?(?:[^\"\\]|(\\[tbnrf\\\"\'])))*"""))/i,/^(?:->)/i,/^(?:\.\.)/i,/^(?:\})/i,/^(?:\{)/i,/^(?:\()/i,/^(?:\))/i,/^(?:\[)/i,/^(?:\])/i,/^(?:\?)/i,/^(?:\*)/i,/^(?:\+)/i,/^(?:\|)/i,/^(?:\^\^)/i,/^(?:\.)/i,/^(?:!)/i,/^(?:\/)/i,/^(?:=)/i,/^(?:@)/i,/^(?:\^)/i,/^(?:;)/i,/^(?:,)/i,/^(?:%)/i,/^(?:a)/i,/^(?:$)/i,/^(?:.)/i],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51],inclusive:!0}}};return Ye}();Le.lexer=Ue;function Fe(){this.yy={}}return Fe.prototype=Le,Le.Parser=Fe,new Fe}();return Zv=t,Zv}var ON;function iX(){if(ON)return S1;ON=1;const t=nX().Parser,e=is;class u{constructor(){}parse(n,{extendedSyntax:r,baseIRI:a}={}){this._parser=new t,this._parser.Parser.factory=e.DataFactory,this._parser.Parser.base=e.DataFactory.namedNode(a||"urn:x-base:default"),this._parser.Parser.extended=r===!0,this._parser.Parser.prefixes={rdf:"http://www.w3.org/1999/02/22-rdf-syntax-ns#",rdfs:"http://www.w3.org/2000/01/rdf-schema#",sh:"http://www.w3.org/ns/shacl#",xsd:"http://www.w3.org/2001/XMLSchema#"},this._parser.Parser.currentNodeShape=void 0,this._parser.Parser.currentPropertyNode=void 0,this._parser.Parser.nodeShapeStack=[],this._parser.Parser.tempCurrentNodeShape=void 0,this._parser.Parser.n3Parser=new e.Parser({baseIRI:a||"urn:x-base:default"});const o=[];return this._parser.Parser.onQuad=l=>{o.push(l)},this._parser.parse(n),o.prefixes=this._parser.Parser.prefixes,o}}return S1.Parser=u,S1.parse=function(n,r){return new u().parse(n,r)},S1}var $l={},RN;function aX(){if(RN)return $l;RN=1,Object.defineProperty($l,"__esModule",{value:!0}),$l.PrefixWrappingIterator=void 0;const t=Dt();let e=class extends t.WrappingIterator{constructor(s){super(s==null?void 0:s.then(n=>(this.prefixes=n.prefixes,n)))}read(){if(this.prefixes){for(const s of Object.entries(this.prefixes))this.emit("prefix",...s);delete this.prefixes}return super.read()}};return $l.PrefixWrappingIterator=e,$l}var xN;function sX(){if(xN)return Ql;xN=1,Object.defineProperty(Ql,"__esModule",{value:!0}),Ql.ActorRdfParseShaclc=void 0;const t=su(),e=ou(),u=Wt(),s=iX(),n=aX();let r=class extends t.ActorRdfParseFixedMediaTypes{constructor(o){super(o)}async runHandle(o,l,c){const d=new n.PrefixWrappingIterator((0,e.stringify)(o.data).then(f=>{var p;return(0,s.parse)(f,{extendedSyntax:l==="text/shaclc-ext",baseIRI:(p=o.metadata)==null?void 0:p.baseIRI})})),h=new u.Readable({objectMode:!0});return d.on("prefix",(...f)=>h.emit("prefix",...f)),{data:h.wrap(d),metadata:{triples:!0}}}};return Ql.ActorRdfParseShaclc=r,Ql}var IN;function oX(){return IN||(IN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(sX(),t)}(Yv)),Yv}var ew={},Vl={},tw={},kl={},_o={},PN;function b7(){if(PN)return _o;PN=1,Object.defineProperty(_o,"__esModule",{value:!0}),_o.QuoteType=void 0;var t=Xa(),e;(function(c){c[c.Tab=9]="Tab",c[c.NewLine=10]="NewLine",c[c.FormFeed=12]="FormFeed",c[c.CarriageReturn=13]="CarriageReturn",c[c.Space=32]="Space",c[c.ExclamationMark=33]="ExclamationMark",c[c.Number=35]="Number",c[c.Amp=38]="Amp",c[c.SingleQuote=39]="SingleQuote",c[c.DoubleQuote=34]="DoubleQuote",c[c.Dash=45]="Dash",c[c.Slash=47]="Slash",c[c.Zero=48]="Zero",c[c.Nine=57]="Nine",c[c.Semi=59]="Semi",c[c.Lt=60]="Lt",c[c.Eq=61]="Eq",c[c.Gt=62]="Gt",c[c.Questionmark=63]="Questionmark",c[c.UpperA=65]="UpperA",c[c.LowerA=97]="LowerA",c[c.UpperF=70]="UpperF",c[c.LowerF=102]="LowerF",c[c.UpperZ=90]="UpperZ",c[c.LowerZ=122]="LowerZ",c[c.LowerX=120]="LowerX",c[c.OpeningSquareBracket=91]="OpeningSquareBracket"})(e||(e={}));var u;(function(c){c[c.Text=1]="Text",c[c.BeforeTagName=2]="BeforeTagName",c[c.InTagName=3]="InTagName",c[c.InSelfClosingTag=4]="InSelfClosingTag",c[c.BeforeClosingTagName=5]="BeforeClosingTagName",c[c.InClosingTagName=6]="InClosingTagName",c[c.AfterClosingTagName=7]="AfterClosingTagName",c[c.BeforeAttributeName=8]="BeforeAttributeName",c[c.InAttributeName=9]="InAttributeName",c[c.AfterAttributeName=10]="AfterAttributeName",c[c.BeforeAttributeValue=11]="BeforeAttributeValue",c[c.InAttributeValueDq=12]="InAttributeValueDq",c[c.InAttributeValueSq=13]="InAttributeValueSq",c[c.InAttributeValueNq=14]="InAttributeValueNq",c[c.BeforeDeclaration=15]="BeforeDeclaration",c[c.InDeclaration=16]="InDeclaration",c[c.InProcessingInstruction=17]="InProcessingInstruction",c[c.BeforeComment=18]="BeforeComment",c[c.CDATASequence=19]="CDATASequence",c[c.InSpecialComment=20]="InSpecialComment",c[c.InCommentLike=21]="InCommentLike",c[c.BeforeSpecialS=22]="BeforeSpecialS",c[c.BeforeSpecialT=23]="BeforeSpecialT",c[c.SpecialStartSequence=24]="SpecialStartSequence",c[c.InSpecialTag=25]="InSpecialTag",c[c.InEntity=26]="InEntity"})(u||(u={}));function s(c){return c===e.Space||c===e.NewLine||c===e.Tab||c===e.FormFeed||c===e.CarriageReturn}function n(c){return c===e.Slash||c===e.Gt||s(c)}function r(c){return c>=e.LowerA&&c<=e.LowerZ||c>=e.UpperA&&c<=e.UpperZ}var a;(function(c){c[c.NoValue=0]="NoValue",c[c.Unquoted=1]="Unquoted",c[c.Single=2]="Single",c[c.Double=3]="Double"})(a||(_o.QuoteType=a={}));var o={Cdata:new Uint8Array([67,68,65,84,65,91]),CdataEnd:new Uint8Array([93,93,62]),CommentEnd:new Uint8Array([45,45,62]),ScriptEnd:new Uint8Array([60,47,115,99,114,105,112,116]),StyleEnd:new Uint8Array([60,47,115,116,121,108,101]),TitleEnd:new Uint8Array([60,47,116,105,116,108,101]),TextareaEnd:new Uint8Array([60,47,116,101,120,116,97,114,101,97])},l=function(){function c(d,h){var f=d.xmlMode,p=f===void 0?!1:f,y=d.decodeEntities,b=y===void 0?!0:y,g=this;this.cbs=h,this.state=u.Text,this.buffer="",this.sectionStart=0,this.index=0,this.entityStart=0,this.baseState=u.Text,this.isSpecial=!1,this.running=!0,this.offset=0,this.currentSequence=void 0,this.sequenceIndex=0,this.xmlMode=p,this.decodeEntities=b,this.entityDecoder=new t.EntityDecoder(p?t.xmlDecodeTree:t.htmlDecodeTree,function(m,v){return g.emitCodePoint(m,v)})}return c.prototype.reset=function(){this.state=u.Text,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=u.Text,this.currentSequence=void 0,this.running=!0,this.offset=0},c.prototype.write=function(d){this.offset+=this.buffer.length,this.buffer=d,this.parse()},c.prototype.end=function(){this.running&&this.finish()},c.prototype.pause=function(){this.running=!1},c.prototype.resume=function(){this.running=!0,this.indexthis.sectionStart&&this.cbs.ontext(this.sectionStart,this.index),this.state=u.BeforeTagName,this.sectionStart=this.index):this.decodeEntities&&d===e.Amp&&this.startEntity()},c.prototype.stateSpecialStartSequence=function(d){var h=this.sequenceIndex===this.currentSequence.length,f=h?n(d):(d|32)===this.currentSequence[this.sequenceIndex];if(!f)this.isSpecial=!1;else if(!h){this.sequenceIndex++;return}this.sequenceIndex=0,this.state=u.InTagName,this.stateInTagName(d)},c.prototype.stateInSpecialTag=function(d){if(this.sequenceIndex===this.currentSequence.length){if(d===e.Gt||s(d)){var h=this.index-this.currentSequence.length;if(this.sectionStart=0?(this.state=this.baseState,d===0&&(this.index=this.entityStart)):this.index=this.offset+this.buffer.length-1},c.prototype.cleanup=function(){this.running&&this.sectionStart!==this.index&&(this.state===u.Text||this.state===u.InSpecialTag&&this.sequenceIndex===0?(this.cbs.ontext(this.sectionStart,this.index),this.sectionStart=this.index):(this.state===u.InAttributeValueDq||this.state===u.InAttributeValueSq||this.state===u.InAttributeValueNq)&&(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=this.index))},c.prototype.shouldContinue=function(){return this.index=d||(this.state===u.InCommentLike?this.currentSequence===o.CdataEnd?this.cbs.oncdata(this.sectionStart,d,0):this.cbs.oncomment(this.sectionStart,d,0):this.state===u.InTagName||this.state===u.BeforeAttributeName||this.state===u.BeforeAttributeValue||this.state===u.AfterAttributeName||this.state===u.InAttributeName||this.state===u.InAttributeValueSq||this.state===u.InAttributeValueDq||this.state===u.InAttributeValueNq||this.state===u.InClosingTagName||this.cbs.ontext(this.sectionStart,d))},c.prototype.emitCodePoint=function(d,h){this.baseState!==u.Text&&this.baseState!==u.InSpecialTag?(this.sectionStart0&&A.has(this.stack[0]);){var D=this.stack.shift();(_=(v=this.cbs).onclosetag)===null||_===void 0||_.call(v,D,!0)}this.isVoidElement(m)||(this.stack.unshift(m),this.htmlMode&&(f.has(m)?this.foreignContext.unshift(!0):p.has(m)&&this.foreignContext.unshift(!1))),(S=(w=this.cbs).onopentagname)===null||S===void 0||S.call(w,m),this.cbs.onopentag&&(this.attribs={})},g.prototype.endOpenTag=function(m){var v,_;this.startIndex=this.openTagStart,this.attribs&&((_=(v=this.cbs).onopentag)===null||_===void 0||_.call(v,this.tagname,this.attribs,m),this.attribs=null),this.cbs.onclosetag&&this.isVoidElement(this.tagname)&&this.cbs.onclosetag(this.tagname,!0),this.tagname=""},g.prototype.onopentagend=function(m){this.endIndex=m,this.endOpenTag(!1),this.startIndex=m+1},g.prototype.onclosetag=function(m,v){var _,w,S,A,D,L,O,E;this.endIndex=v;var P=this.getSlice(m,v);if(this.lowerCaseTagNames&&(P=P.toLowerCase()),this.htmlMode&&(f.has(P)||p.has(P))&&this.foreignContext.shift(),this.isVoidElement(P))this.htmlMode&&P==="br"&&((A=(S=this.cbs).onopentagname)===null||A===void 0||A.call(S,"br"),(L=(D=this.cbs).onopentag)===null||L===void 0||L.call(D,"br",{},!0),(E=(O=this.cbs).onclosetag)===null||E===void 0||E.call(O,"br",!1));else{var M=this.stack.indexOf(P);if(M!==-1)for(var U=0;U<=M;U++){var j=this.stack.shift();(w=(_=this.cbs).onclosetag)===null||w===void 0||w.call(_,j,U!==M)}else this.htmlMode&&P==="p"&&(this.emitOpenTag("p"),this.closeCurrentTag(!0))}this.startIndex=v+1},g.prototype.onselfclosingtag=function(m){this.endIndex=m,this.recognizeSelfClosing||this.foreignContext[0]?(this.closeCurrentTag(!1),this.startIndex=m+1):this.onopentagend(m)},g.prototype.closeCurrentTag=function(m){var v,_,w=this.tagname;this.endOpenTag(m),this.stack[0]===w&&((_=(v=this.cbs).onclosetag)===null||_===void 0||_.call(v,w,!m),this.stack.shift())},g.prototype.onattribname=function(m,v){this.startIndex=m;var _=this.getSlice(m,v);this.attribname=this.lowerCaseAttributeNames?_.toLowerCase():_},g.prototype.onattribdata=function(m,v){this.attribvalue+=this.getSlice(m,v)},g.prototype.onattribentity=function(m){this.attribvalue+=(0,n.fromCodePoint)(m)},g.prototype.onattribend=function(m,v){var _,w;this.endIndex=v,(w=(_=this.cbs).onattribute)===null||w===void 0||w.call(_,this.attribname,this.attribvalue,m===s.QuoteType.Double?'"':m===s.QuoteType.Single?"'":m===s.QuoteType.NoValue?void 0:null),this.attribs&&!Object.prototype.hasOwnProperty.call(this.attribs,this.attribname)&&(this.attribs[this.attribname]=this.attribvalue),this.attribvalue=""},g.prototype.getInstructionName=function(m){var v=m.search(y),_=v<0?m:m.substr(0,v);return this.lowerCaseTagNames&&(_=_.toLowerCase()),_},g.prototype.ondeclaration=function(m,v){this.endIndex=v;var _=this.getSlice(m,v);if(this.cbs.onprocessinginstruction){var w=this.getInstructionName(_);this.cbs.onprocessinginstruction("!".concat(w),"!".concat(_))}this.startIndex=v+1},g.prototype.onprocessinginstruction=function(m,v){this.endIndex=v;var _=this.getSlice(m,v);if(this.cbs.onprocessinginstruction){var w=this.getInstructionName(_);this.cbs.onprocessinginstruction("?".concat(w),"?".concat(_))}this.startIndex=v+1},g.prototype.oncomment=function(m,v,_){var w,S,A,D;this.endIndex=v,(S=(w=this.cbs).oncomment)===null||S===void 0||S.call(w,this.getSlice(m,v-_)),(D=(A=this.cbs).oncommentend)===null||D===void 0||D.call(A),this.startIndex=v+1},g.prototype.oncdata=function(m,v,_){var w,S,A,D,L,O,E,P,M,U;this.endIndex=v;var j=this.getSlice(m,v-_);!this.htmlMode||this.options.recognizeCDATA?((S=(w=this.cbs).oncdatastart)===null||S===void 0||S.call(w),(D=(A=this.cbs).ontext)===null||D===void 0||D.call(A,j),(O=(L=this.cbs).oncdataend)===null||O===void 0||O.call(L)):((P=(E=this.cbs).oncomment)===null||P===void 0||P.call(E,"[CDATA[".concat(j,"]]")),(U=(M=this.cbs).oncommentend)===null||U===void 0||U.call(M)),this.startIndex=v+1},g.prototype.onend=function(){var m,v;if(this.cbs.onclosetag){this.endIndex=this.startIndex;for(var _=0;_=this.buffers[0].length;)this.shiftBuffer();for(var _=this.buffers[0].slice(m-this.bufferOffset,v-this.bufferOffset);v-this.bufferOffset>this.buffers[0].length;)this.shiftBuffer(),_+=this.buffers[0].slice(0,v-this.bufferOffset);return _},g.prototype.shiftBuffer=function(){this.bufferOffset+=this.buffers[0].length,this.writeIndex--,this.buffers.shift()},g.prototype.write=function(m){var v,_;if(this.ended){(_=(v=this.cbs).onerror)===null||_===void 0||_.call(v,new Error(".write() after done!"));return}this.buffers.push(m),this.tokenizer.running&&(this.tokenizer.write(m),this.writeIndex++)},g.prototype.end=function(m){var v,_;if(this.ended){(_=(v=this.cbs).onerror)===null||_===void 0||_.call(v,new Error(".end() after done!"));return}m&&this.write(m),this.ended=!0,this.tokenizer.end()},g.prototype.pause=function(){this.tokenizer.pause()},g.prototype.resume=function(){for(this.tokenizer.resume();this.tokenizer.running&&this.writeIndex{};let c=0,d=1;function h(b){l.emit("error",b)}function f(){--d===0&&l.push(null)}const p={baseIRI:((y=r.metadata)==null?void 0:y.baseIRI)??"",context:o,emit:b=>{c--,l.push(b)},end:f,error:h,headers:r.headers};try{const b=await Promise.all(this.busRdfParseHtml.publish(p));d+=b.length;const g=[];for(const _ of b){const{htmlParseListener:w}=await _.actor.run(p);g.push(w)}const m=new e.Parser({onclosetag(){try{for(const _ of g)_.onTagClose()}catch(_){h(_)}},onend(){try{for(const _ of g)_.onEnd()}catch(_){h(_)}f()},onopentag(_,w){try{for(const S of g)S.onTagOpen(_,w)}catch(S){h(S)}},ontext(_){try{for(const w of g)w.onText(_)}catch(w){h(w)}}},{decodeEntities:!0,recognizeSelfClosing:!0,xmlMode:!1}),v=l._read=_=>{for(c=Math.max(_,c);c>0;){const w=r.data.read();if(w===null){r.data.once("readable",()=>v(0));return}m.write(w.toString())}};r.data.on("error",h).on("end",()=>m.end())}catch(b){setTimeout(()=>{l.emit("error",b)})}return{data:l}}}return Vl.ActorRdfParseHtml=s,Vl}var LN;function lX(){return LN||(LN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(cX(),t)}(ew)),ew}var rw={},zl={},nw={},Gl={},MN;function dX(){if(MN)return Gl;MN=1,Object.defineProperty(Gl,"__esModule",{value:!0}),Gl.ActorRdfParseHtml=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return Gl.ActorRdfParseHtml=e,Gl}var FN;function uA(){return FN||(FN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(dX(),t)}(nw)),nw}var iw={},aw={},qN;function fX(){return qN||(qN=1,Object.defineProperty(aw,"__esModule",{value:!0})),aw}var Wl={},BN;function m7(){if(BN)return Wl;BN=1,Object.defineProperty(Wl,"__esModule",{value:!0}),Wl.ItemPropertyHandlerContent=void 0;let t=class{canHandle(u,s){return"content"in s}getObject(u,s,n){return s.createLiteral(u.content,n)}};return Wl.ItemPropertyHandlerContent=t,Wl}var Jl={},Xl={},UN;function rm(){if(UN)return Xl;UN=1,Object.defineProperty(Xl,"__esModule",{value:!0}),Xl.Util=void 0;const t=Et(),e=Pi();class u{constructor(n,r){this.dataFactory=n||new t.DataFactory,this.baseIRI=r||""}static isValidIri(n){return u.IRI_REGEX.test(n)}createVocabIris(n,r,a){return n.split(/\s+/u).filter(o=>!!o).map(o=>{if(!u.isValidIri(o)){if(!a)return;o=`${r.vocab||`${this.baseIRI}#`}${o}`}return this.dataFactory.namedNode(o)}).filter(o=>!!o)}getVocabularyExpansionType(n,r,a){const o=n.split(/\s+/u);if(o.includes("subPropertyOf")||o.includes("equivalentProperty"))return[this.dataFactory.namedNode(`${u.RDF}type`)];if(r.vocab&&r.vocab in a&&a[r.vocab].properties){let l=[];for(const[c,d]of Object.entries(a[r.vocab].properties))o.includes(c)&&(l=[...Object.values(d).map(h=>this.dataFactory.namedNode(h))]);return l}return[]}createSubject(n){if(!u.isValidIri(n))try{n=(0,e.resolve)(n,this.baseIRI)}catch{return}return this.dataFactory.namedNode(n)}createLiteral(n,r){return this.dataFactory.literal(n,r.language)}deriveVocab(n,r){let a;for(const o in r)if(n.startsWith(o)){a=o,a.endsWith("/")||(a+="#");break}if(!a){const o=n.indexOf("#");o>0?a=n.slice(0,o+1):a=(0,e.resolve)(".",n)}return a}}return Xl.Util=u,u.RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#",u.XSD="http://www.w3.org/2001/XMLSchema#",u.RDFA="http://www.w3.org/ns/rdfa#",u.IRI_REGEX=/^([A-Za-z][\d+-.A-Za-z]*|_):[^ "<>[\\\]`{|}]*$/u,Xl}var QN;function g7(){if(QN)return Jl;QN=1,Object.defineProperty(Jl,"__esModule",{value:!0}),Jl.ItemPropertyHandlerNumber=void 0;const t=rm();let e=class{constructor(s,n){this.tagName=s,this.attributeName=n}canHandle(s,n){return this.tagName===s&&this.attributeName in n}getObject(s,n,r){const a=s[this.attributeName];let o;return!Number.isNaN(Number.parseInt(a,10))&&!a.includes(".")?o=`${t.Util.XSD}integer`:Number.isNaN(Number.parseFloat(a))||(o=`${t.Util.XSD}double`),n.dataFactory.literal(a,o&&n.dataFactory.namedNode(o))}};return Jl.ItemPropertyHandlerNumber=e,Jl}var Kl={},HN;function v7(){if(HN)return Kl;HN=1,Object.defineProperty(Kl,"__esModule",{value:!0}),Kl.ItemPropertyHandlerTime=void 0;const t=rm();let e=class _7{canHandle(s,n){return s==="time"&&"datetime"in n}getObject(s,n,r){const a=s.datetime;let o;for(const l of _7.TIME_REGEXES)if(l.regex.test(a)){o=n.dataFactory.namedNode(t.Util.XSD+l.type);break}return n.dataFactory.literal(a,o)}};return Kl.ItemPropertyHandlerTime=e,e.TIME_REGEXES=[{regex:/^-?P(\d+Y)?(\d+M)?(\d+D)?(T(\d+H)?(\d+M)?(\d+(\.\d)?S)?)?$/u,type:"duration"},{regex:/^\d+-\d\d-\d\dT\d\d:\d\d:\d\d((Z?)|([+-]\d\d:\d\d))$/u,type:"dateTime"},{regex:/^\d+-\d\d-\d\dZ?$/u,type:"date"},{regex:/^\d\d:\d\d:\d\d((Z?)|([+-]\d\d:\d\d))$/u,type:"time"},{regex:/^\d+-\d\d$/u,type:"gYearMonth"},{regex:/^\d+$/u,type:"gYear"}],Kl}var Yl={},$N;function w7(){if($N)return Yl;$N=1,Object.defineProperty(Yl,"__esModule",{value:!0}),Yl.ItemPropertyHandlerUrl=void 0;const t=Pi();let e=class{constructor(s,n){this.tagName=s,this.attributeName=n}canHandle(s,n){return this.tagName===s&&this.attributeName in n}getObject(s,n,r){return n.dataFactory.namedNode((0,t.resolve)(s[this.attributeName],n.baseIRI))}};return Yl.ItemPropertyHandlerUrl=e,Yl}var sw={},VN;function hX(){return VN||(VN=1,Object.defineProperty(sw,"__esModule",{value:!0})),sw}var ow={},kN;function pX(){return kN||(kN=1,Object.defineProperty(ow,"__esModule",{value:!0})),ow}var uw={},zN;function yX(){return zN||(zN=1,Object.defineProperty(uw,"__esModule",{value:!0})),uw}var Zl={},cw={},ed={},lw={},GN;function S7(){return GN||(GN=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.QuoteType=void 0;var e=Xa(),u;(function(f){f[f.Tab=9]="Tab",f[f.NewLine=10]="NewLine",f[f.FormFeed=12]="FormFeed",f[f.CarriageReturn=13]="CarriageReturn",f[f.Space=32]="Space",f[f.ExclamationMark=33]="ExclamationMark",f[f.Number=35]="Number",f[f.Amp=38]="Amp",f[f.SingleQuote=39]="SingleQuote",f[f.DoubleQuote=34]="DoubleQuote",f[f.Dash=45]="Dash",f[f.Slash=47]="Slash",f[f.Zero=48]="Zero",f[f.Nine=57]="Nine",f[f.Semi=59]="Semi",f[f.Lt=60]="Lt",f[f.Eq=61]="Eq",f[f.Gt=62]="Gt",f[f.Questionmark=63]="Questionmark",f[f.UpperA=65]="UpperA",f[f.LowerA=97]="LowerA",f[f.UpperF=70]="UpperF",f[f.LowerF=102]="LowerF",f[f.UpperZ=90]="UpperZ",f[f.LowerZ=122]="LowerZ",f[f.LowerX=120]="LowerX",f[f.OpeningSquareBracket=91]="OpeningSquareBracket"})(u||(u={}));var s;(function(f){f[f.Text=1]="Text",f[f.BeforeTagName=2]="BeforeTagName",f[f.InTagName=3]="InTagName",f[f.InSelfClosingTag=4]="InSelfClosingTag",f[f.BeforeClosingTagName=5]="BeforeClosingTagName",f[f.InClosingTagName=6]="InClosingTagName",f[f.AfterClosingTagName=7]="AfterClosingTagName",f[f.BeforeAttributeName=8]="BeforeAttributeName",f[f.InAttributeName=9]="InAttributeName",f[f.AfterAttributeName=10]="AfterAttributeName",f[f.BeforeAttributeValue=11]="BeforeAttributeValue",f[f.InAttributeValueDq=12]="InAttributeValueDq",f[f.InAttributeValueSq=13]="InAttributeValueSq",f[f.InAttributeValueNq=14]="InAttributeValueNq",f[f.BeforeDeclaration=15]="BeforeDeclaration",f[f.InDeclaration=16]="InDeclaration",f[f.InProcessingInstruction=17]="InProcessingInstruction",f[f.BeforeComment=18]="BeforeComment",f[f.CDATASequence=19]="CDATASequence",f[f.InSpecialComment=20]="InSpecialComment",f[f.InCommentLike=21]="InCommentLike",f[f.BeforeSpecialS=22]="BeforeSpecialS",f[f.SpecialStartSequence=23]="SpecialStartSequence",f[f.InSpecialTag=24]="InSpecialTag",f[f.BeforeEntity=25]="BeforeEntity",f[f.BeforeNumericEntity=26]="BeforeNumericEntity",f[f.InNamedEntity=27]="InNamedEntity",f[f.InNumericEntity=28]="InNumericEntity",f[f.InHexEntity=29]="InHexEntity"})(s||(s={}));function n(f){return f===u.Space||f===u.NewLine||f===u.Tab||f===u.FormFeed||f===u.CarriageReturn}function r(f){return f===u.Slash||f===u.Gt||n(f)}function a(f){return f>=u.Zero&&f<=u.Nine}function o(f){return f>=u.LowerA&&f<=u.LowerZ||f>=u.UpperA&&f<=u.UpperZ}function l(f){return f>=u.UpperA&&f<=u.UpperF||f>=u.LowerA&&f<=u.LowerF}var c;(function(f){f[f.NoValue=0]="NoValue",f[f.Unquoted=1]="Unquoted",f[f.Single=2]="Single",f[f.Double=3]="Double"})(c=t.QuoteType||(t.QuoteType={}));var d={Cdata:new Uint8Array([67,68,65,84,65,91]),CdataEnd:new Uint8Array([93,93,62]),CommentEnd:new Uint8Array([45,45,62]),ScriptEnd:new Uint8Array([60,47,115,99,114,105,112,116]),StyleEnd:new Uint8Array([60,47,115,116,121,108,101]),TitleEnd:new Uint8Array([60,47,116,105,116,108,101])},h=function(){function f(p,y){var b=p.xmlMode,g=b===void 0?!1:b,m=p.decodeEntities,v=m===void 0?!0:m;this.cbs=y,this.state=s.Text,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=s.Text,this.isSpecial=!1,this.running=!0,this.offset=0,this.currentSequence=void 0,this.sequenceIndex=0,this.trieIndex=0,this.trieCurrent=0,this.entityResult=0,this.entityExcess=0,this.xmlMode=g,this.decodeEntities=v,this.entityTrie=g?e.xmlDecodeTree:e.htmlDecodeTree}return f.prototype.reset=function(){this.state=s.Text,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=s.Text,this.currentSequence=void 0,this.running=!0,this.offset=0},f.prototype.write=function(p){this.offset+=this.buffer.length,this.buffer=p,this.parse()},f.prototype.end=function(){this.running&&this.finish()},f.prototype.pause=function(){this.running=!1},f.prototype.resume=function(){this.running=!0,this.indexthis.sectionStart&&this.cbs.ontext(this.sectionStart,this.index),this.state=s.BeforeTagName,this.sectionStart=this.index):this.decodeEntities&&p===u.Amp&&(this.state=s.BeforeEntity)},f.prototype.stateSpecialStartSequence=function(p){var y=this.sequenceIndex===this.currentSequence.length,b=y?r(p):(p|32)===this.currentSequence[this.sequenceIndex];if(!b)this.isSpecial=!1;else if(!y){this.sequenceIndex++;return}this.sequenceIndex=0,this.state=s.InTagName,this.stateInTagName(p)},f.prototype.stateInSpecialTag=function(p){if(this.sequenceIndex===this.currentSequence.length){if(p===u.Gt||n(p)){var y=this.index-this.currentSequence.length;if(this.sectionStart>14)-1;if(!this.allowLegacyEntity()&&p!==u.Semi)this.trieIndex+=b;else{var g=this.index-this.entityExcess+1;g>this.sectionStart&&this.emitPartial(this.sectionStart,g),this.entityResult=this.trieIndex,this.trieIndex+=b,this.entityExcess=0,this.sectionStart=this.index+1,b===0&&this.emitNamedEntity()}}},f.prototype.emitNamedEntity=function(){if(this.state=this.baseState,this.entityResult!==0){var p=(this.entityTrie[this.entityResult]&e.BinTrieFlags.VALUE_LENGTH)>>14;switch(p){case 1:{this.emitCodePoint(this.entityTrie[this.entityResult]&~e.BinTrieFlags.VALUE_LENGTH);break}case 2:{this.emitCodePoint(this.entityTrie[this.entityResult+1]);break}case 3:this.emitCodePoint(this.entityTrie[this.entityResult+1]),this.emitCodePoint(this.entityTrie[this.entityResult+2])}}},f.prototype.stateBeforeNumericEntity=function(p){(p|32)===u.LowerX?(this.entityExcess++,this.state=s.InHexEntity):(this.state=s.InNumericEntity,this.stateInNumericEntity(p))},f.prototype.emitNumericEntity=function(p){var y=this.index-this.entityExcess-1,b=y+2+ +(this.state===s.InHexEntity);b!==this.index&&(y>this.sectionStart&&this.emitPartial(this.sectionStart,y),this.sectionStart=this.index+Number(p),this.emitCodePoint((0,e.replaceCodePoint)(this.entityResult))),this.state=this.baseState},f.prototype.stateInNumericEntity=function(p){p===u.Semi?this.emitNumericEntity(!0):a(p)?(this.entityResult=this.entityResult*10+(p-u.Zero),this.entityExcess++):(this.allowLegacyEntity()?this.emitNumericEntity(!1):this.state=this.baseState,this.index--)},f.prototype.stateInHexEntity=function(p){p===u.Semi?this.emitNumericEntity(!0):a(p)?(this.entityResult=this.entityResult*16+(p-u.Zero),this.entityExcess++):l(p)?(this.entityResult=this.entityResult*16+((p|32)-u.LowerA+10),this.entityExcess++):(this.allowLegacyEntity()?this.emitNumericEntity(!1):this.state=this.baseState,this.index--)},f.prototype.allowLegacyEntity=function(){return!this.xmlMode&&(this.baseState===s.Text||this.baseState===s.InSpecialTag)},f.prototype.cleanup=function(){this.running&&this.sectionStart!==this.index&&(this.state===s.Text||this.state===s.InSpecialTag&&this.sequenceIndex===0?(this.cbs.ontext(this.sectionStart,this.index),this.sectionStart=this.index):(this.state===s.InAttributeValueDq||this.state===s.InAttributeValueSq||this.state===s.InAttributeValueNq)&&(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=this.index))},f.prototype.shouldContinue=function(){return this.index0&&A.has(this.stack[this.stack.length-1]);){var D=this.stack.pop();(_=(v=this.cbs).onclosetag)===null||_===void 0||_.call(v,D,!0)}this.isVoidElement(m)||(this.stack.push(m),f.has(m)?this.foreignContext.push(!0):p.has(m)&&this.foreignContext.push(!1)),(S=(w=this.cbs).onopentagname)===null||S===void 0||S.call(w,m),this.cbs.onopentag&&(this.attribs={})},g.prototype.endOpenTag=function(m){var v,_;this.startIndex=this.openTagStart,this.attribs&&((_=(v=this.cbs).onopentag)===null||_===void 0||_.call(v,this.tagname,this.attribs,m),this.attribs=null),this.cbs.onclosetag&&this.isVoidElement(this.tagname)&&this.cbs.onclosetag(this.tagname,!0),this.tagname=""},g.prototype.onopentagend=function(m){this.endIndex=m,this.endOpenTag(!1),this.startIndex=m+1},g.prototype.onclosetag=function(m,v){var _,w,S,A,D,L;this.endIndex=v;var O=this.getSlice(m,v);if(this.lowerCaseTagNames&&(O=O.toLowerCase()),(f.has(O)||p.has(O))&&this.foreignContext.pop(),this.isVoidElement(O))!this.options.xmlMode&&O==="br"&&((w=(_=this.cbs).onopentagname)===null||w===void 0||w.call(_,"br"),(A=(S=this.cbs).onopentag)===null||A===void 0||A.call(S,"br",{},!0),(L=(D=this.cbs).onclosetag)===null||L===void 0||L.call(D,"br",!1));else{var E=this.stack.lastIndexOf(O);if(E!==-1)if(this.cbs.onclosetag)for(var P=this.stack.length-E;P--;)this.cbs.onclosetag(this.stack.pop(),P!==0);else this.stack.length=E;else!this.options.xmlMode&&O==="p"&&(this.emitOpenTag("p"),this.closeCurrentTag(!0))}this.startIndex=v+1},g.prototype.onselfclosingtag=function(m){this.endIndex=m,this.options.xmlMode||this.options.recognizeSelfClosing||this.foreignContext[this.foreignContext.length-1]?(this.closeCurrentTag(!1),this.startIndex=m+1):this.onopentagend(m)},g.prototype.closeCurrentTag=function(m){var v,_,w=this.tagname;this.endOpenTag(m),this.stack[this.stack.length-1]===w&&((_=(v=this.cbs).onclosetag)===null||_===void 0||_.call(v,w,!m),this.stack.pop())},g.prototype.onattribname=function(m,v){this.startIndex=m;var _=this.getSlice(m,v);this.attribname=this.lowerCaseAttributeNames?_.toLowerCase():_},g.prototype.onattribdata=function(m,v){this.attribvalue+=this.getSlice(m,v)},g.prototype.onattribentity=function(m){this.attribvalue+=(0,n.fromCodePoint)(m)},g.prototype.onattribend=function(m,v){var _,w;this.endIndex=v,(w=(_=this.cbs).onattribute)===null||w===void 0||w.call(_,this.attribname,this.attribvalue,m===s.QuoteType.Double?'"':m===s.QuoteType.Single?"'":m===s.QuoteType.NoValue?void 0:null),this.attribs&&!Object.prototype.hasOwnProperty.call(this.attribs,this.attribname)&&(this.attribs[this.attribname]=this.attribvalue),this.attribvalue=""},g.prototype.getInstructionName=function(m){var v=m.search(y),_=v<0?m:m.substr(0,v);return this.lowerCaseTagNames&&(_=_.toLowerCase()),_},g.prototype.ondeclaration=function(m,v){this.endIndex=v;var _=this.getSlice(m,v);if(this.cbs.onprocessinginstruction){var w=this.getInstructionName(_);this.cbs.onprocessinginstruction("!".concat(w),"!".concat(_))}this.startIndex=v+1},g.prototype.onprocessinginstruction=function(m,v){this.endIndex=v;var _=this.getSlice(m,v);if(this.cbs.onprocessinginstruction){var w=this.getInstructionName(_);this.cbs.onprocessinginstruction("?".concat(w),"?".concat(_))}this.startIndex=v+1},g.prototype.oncomment=function(m,v,_){var w,S,A,D;this.endIndex=v,(S=(w=this.cbs).oncomment)===null||S===void 0||S.call(w,this.getSlice(m,v-_)),(D=(A=this.cbs).oncommentend)===null||D===void 0||D.call(A),this.startIndex=v+1},g.prototype.oncdata=function(m,v,_){var w,S,A,D,L,O,E,P,M,U;this.endIndex=v;var j=this.getSlice(m,v-_);this.options.xmlMode||this.options.recognizeCDATA?((S=(w=this.cbs).oncdatastart)===null||S===void 0||S.call(w),(D=(A=this.cbs).ontext)===null||D===void 0||D.call(A,j),(O=(L=this.cbs).oncdataend)===null||O===void 0||O.call(L)):((P=(E=this.cbs).oncomment)===null||P===void 0||P.call(E,"[CDATA[".concat(j,"]]")),(U=(M=this.cbs).oncommentend)===null||U===void 0||U.call(M)),this.startIndex=v+1},g.prototype.onend=function(){var m,v;if(this.cbs.onclosetag){this.endIndex=this.startIndex;for(var _=this.stack.length;_>0;this.cbs.onclosetag(this.stack[--_],!0));}(v=(m=this.cbs).onend)===null||v===void 0||v.call(m)},g.prototype.reset=function(){var m,v,_,w;(v=(m=this.cbs).onreset)===null||v===void 0||v.call(m),this.tokenizer.reset(),this.tagname="",this.attribname="",this.attribs=null,this.stack.length=0,this.startIndex=0,this.endIndex=0,(w=(_=this.cbs).onparserinit)===null||w===void 0||w.call(_,this),this.buffers.length=0,this.bufferOffset=0,this.writeIndex=0,this.ended=!1},g.prototype.parseComplete=function(m){this.reset(),this.end(m)},g.prototype.getSlice=function(m,v){for(;m-this.bufferOffset>=this.buffers[0].length;)this.shiftBuffer();for(var _=this.buffers[0].slice(m-this.bufferOffset,v-this.bufferOffset);v-this.bufferOffset>this.buffers[0].length;)this.shiftBuffer(),_+=this.buffers[0].slice(0,v-this.bufferOffset);return _},g.prototype.shiftBuffer=function(){this.bufferOffset+=this.buffers[0].length,this.writeIndex--,this.buffers.shift()},g.prototype.write=function(m){var v,_;if(this.ended){(_=(v=this.cbs).onerror)===null||_===void 0||_.call(v,new Error(".write() after done!"));return}this.buffers.push(m),this.tokenizer.running&&(this.tokenizer.write(m),this.writeIndex++)},g.prototype.end=function(m){var v,_;if(this.ended){(_=(v=this.cbs).onerror)===null||_===void 0||_.call(v,new Error(".end() after done!"));return}m&&this.write(m),this.ended=!0,this.tokenizer.end()},g.prototype.pause=function(){this.tokenizer.pause()},g.prototype.resume=function(){for(this.tokenizer.resume();this.tokenizer.running&&this.writeIndexf.emit("error",p)),d.on("data",p=>h.push(p)),d.on("end",()=>h.push(null));const f=h.pipe(new w3(this.options));return f}_transform(d,h,f){this.parser.write(d.toString()),f()}_flush(d){this.parser.end(),d()}getItemScope(d){let h=this.itemScopeStack.length-(d?2:1);for(;h>0&&!this.itemScopeStack[h];)h--;return this.itemScopeStack[h]}getDepth(){return this.itemScopeStack.length}onTagOpen(d,h){if(!this.isEmittingReferences){if("id"in h){const p=h.id;this.pendingItemRefsRangeCollecting[p]={events:[],counter:0,ids:[]}}for(const p of Object.values(this.pendingItemRefsRangeCollecting))p.counter++,p.events.push({type:"open",name:d,attributes:h})}this.textBufferStack.push(void 0);let f;if("itemscope"in h){let p;if(this.emittingReferencesItemScopeIdGenerator)p=this.emittingReferencesItemScopeIdGenerator();else{p="itemid"in h&&this.util.createSubject(h.itemid)||this.util.dataFactory.blankNode();for(const b of Object.values(this.pendingItemRefsRangeCollecting))b.ids.push(p)}f={subject:p},this.isEmittingReferences&&(f.blockEmission=!0);const y=this.getItemScope();y&&y.vocab&&(f.vocab=y.vocab),this.itemScopeStack.push(f)}else f=this.getItemScope(),this.itemScopeStack.push(void 0);if(f){if("itemtype"in h)for(const p of this.util.createVocabIris(h.itemtype,f,!1))f.vocab||(f.vocab=this.util.deriveVocab(p.value,this.vocabRegistry)),f.blockEmission||this.emitTriple(f.subject,this.util.dataFactory.namedNode(`${a.Util.RDF}type`),p);if("lang"in h&&(f.language=h.lang),"xml:lang"in h&&(f.language=h["xml:lang"]),"itemscope"in h&&!this.isEmittingReferences&&"itemref"in h)for(const p of h.itemref.split(/\s+/u))p in this.pendingItemRefsDomain||(this.pendingItemRefsDomain[p]=[]),this.pendingItemRefsDomain[p].push(f),this.tryToEmitReferences(p,f)}"itemprop"in h&&this.handleItemProperties(h.itemprop,!1,f,d,h),"itemprop-reverse"in h&&this.handleItemProperties(h["itemprop-reverse"],!0,f,d,h)}onText(d){if(!this.isEmittingReferences)for(const h of Object.values(this.pendingItemRefsRangeCollecting))h.events.push({type:"text",data:d});for(const h of this.textBufferStack)h&&h.push(d)}onTagClose(){if(!this.isEmittingReferences)for(const[h,f]of Object.entries(this.pendingItemRefsRangeCollecting))f.counter--,f.events.push({type:"close"}),f.counter===0&&(this.pendingItemRefsRangeFinalized[h]=f,delete this.pendingItemRefsRangeCollecting[h],this.tryToEmitReferences(h));const d=this.getItemScope(!0);if(d){const h=this.getDepth();if(d.predicates&&h in d.predicates)for(const[f,p]of Object.entries(d.predicates[h])){const y=this.util.createLiteral(this.textBufferStack[h].join(""),d);this.emitPredicateTriples(d,p,y,f==="reverse"),delete d.predicates[h][f]}}this.itemScopeStack.pop(),this.textBufferStack.pop()}onEnd(){}initializeParser(d){return new t.Parser({onclosetag:()=>{try{this.onTagClose(),this.htmlParseListener&&this.htmlParseListener.onTagClose()}catch(h){this.emit("error",h)}},onend:()=>{try{this.onEnd(),this.htmlParseListener&&this.htmlParseListener.onEnd()}catch(h){this.emit("error",h)}},onopentag:(h,f)=>{try{this.onTagOpen(h,f),this.htmlParseListener&&this.htmlParseListener.onTagOpen(h,f)}catch(p){this.emit("error",p)}},ontext:h=>{try{this.onText(h),this.htmlParseListener&&this.htmlParseListener.onText(h)}catch(f){this.emit("error",f)}}},{decodeEntities:!0,recognizeSelfClosing:!0,xmlMode:d})}handleItemProperties(d,h,f,p,y){const b=this.getItemScope(!0);if(b){const g=this.getDepth(),m=this.util.createVocabIris(d,b,!0);b.predicates||(b.predicates={}),b.predicates[g]||(b.predicates[g]={});const v=h?"reverse":"forward";b.predicates[g][v]=m;for(const _ of this.util.getVocabularyExpansionType(d,b,this.vocabRegistry))m.push(_);if(f&&"itemscope"in y)this.emitPredicateTriples(b,m,f.subject,h),delete b.predicates[g][v];else for(const _ of w3.ITEM_PROPERTY_HANDLERS)if(_.canHandle(p,y)){const w=_.getObject(y,this.util,b);this.emitPredicateTriples(b,m,w,h),delete b.predicates[g][v]}b.predicates[g][v]&&(this.textBufferStack[g]=[])}}emitPredicateTriples(d,h,f,p){if(!d.blockEmission)for(const y of h)p?f.termType!=="Literal"&&this.emitTriple(f,y,d.subject):this.emitTriple(d.subject,y,f)}emitTriple(d,h,f){this.push(this.util.dataFactory.quad(d,h,f,this.defaultGraph))}tryToEmitReferences(d,h){const f=this.pendingItemRefsRangeFinalized[d];if(f){let p;if(h){p=[h];const y=this.pendingItemRefsDomain[d].indexOf(h);this.pendingItemRefsDomain[d].splice(y,1)}else p=this.pendingItemRefsDomain[d],delete this.pendingItemRefsDomain[d];if(p){const y=this.itemScopeStack,b=this.textBufferStack;this.isEmittingReferences=!0;for(const g of p){this.itemScopeStack=[g],this.textBufferStack=[void 0];const m=[...f.ids];this.emittingReferencesItemScopeIdGenerator=()=>m.shift();for(const v of f.events)switch(v.type){case"open":this.onTagOpen(v.name,v.attributes);break;case"text":this.onText(v.data);break;case"close":this.onTagClose();break}}this.emittingReferencesItemScopeIdGenerator=void 0,this.itemScopeStack=y,this.textBufferStack=b,this.isEmittingReferences=!1}}}};return Zl.MicrodataRdfParser=l,l.ITEM_PROPERTY_HANDLERS=[new u.ItemPropertyHandlerContent,new r.ItemPropertyHandlerUrl("a","href"),new r.ItemPropertyHandlerUrl("area","href"),new r.ItemPropertyHandlerUrl("audio","src"),new r.ItemPropertyHandlerUrl("embed","src"),new r.ItemPropertyHandlerUrl("iframe","src"),new r.ItemPropertyHandlerUrl("img","src"),new r.ItemPropertyHandlerUrl("link","href"),new r.ItemPropertyHandlerUrl("object","data"),new r.ItemPropertyHandlerUrl("source","src"),new r.ItemPropertyHandlerUrl("track","src"),new r.ItemPropertyHandlerUrl("video","src"),new s.ItemPropertyHandlerNumber("data","value"),new s.ItemPropertyHandlerNumber("meter","value"),new n.ItemPropertyHandlerTime],Zl}var YN;function _X(){return YN||(YN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(fX(),t),u(m7(),t),u(g7(),t),u(v7(),t),u(w7(),t),u(hX(),t),u(pX(),t),u(yX(),t),u(gX(),t),u(rm(),t)}(iw)),iw}var ZN;function vX(){if(ZN)return zl;ZN=1,Object.defineProperty(zl,"__esModule",{value:!0}),zl.ActorRdfParseHtmlMicrodata=void 0;const t=uA(),e=_X();let u=class extends t.ActorRdfParseHtml{constructor(n){super(n)}async test(n){return!0}async run(n){const r=n.headers?n.headers.get("content-type"):null,a=r==null?void 0:r.includes("xml"),o=new e.MicrodataRdfParser({baseIRI:n.baseIRI,xmlMode:a});o.on("error",n.error),o.on("data",n.emit);const l=o.onEnd;return o.onEnd=()=>{l.call(o),n.end()},{htmlParseListener:o}}};return zl.ActorRdfParseHtmlMicrodata=u,zl}var e4;function wX(){return e4||(e4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(vX(),t)}(rw)),rw}var dw={},td={},t4;function SX(){if(t4)return td;t4=1,Object.defineProperty(td,"__esModule",{value:!0}),td.ActorRdfParseHtmlRdfa=void 0;const t=uA(),e=p7();let u=class extends t.ActorRdfParseHtml{constructor(n){super(n)}async test(n){return!0}async run(n){const r=n.headers?n.headers.get("content-type"):null,a=(n.headers&&n.headers.get("content-language"))??void 0,o=r&&r.includes("xml")?"xhtml":"html",l=new e.RdfaParser({baseIRI:n.baseIRI,profile:o,language:a});l.on("error",n.error),l.on("data",n.emit);const c=l.onEnd;return l.onEnd=()=>{c.call(l),n.end()},{htmlParseListener:l}}};return td.ActorRdfParseHtmlRdfa=u,td}var r4;function TX(){return r4||(r4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(SX(),t)}(dw)),dw}var fw={},rd={},hw={},nd={},n4;function AX(){if(n4)return nd;n4=1,Object.defineProperty(nd,"__esModule",{value:!0}),nd.ActorRdfResolveHypermediaLinks=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return nd.ActorRdfResolveHypermediaLinks=e,nd}var i4;function EX(){return i4||(i4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(AX(),t)}(hw)),hw}var a4;function OX(){if(a4)return rd;a4=1,Object.defineProperty(rd,"__esModule",{value:!0}),rd.ActorRdfResolveHypermediaLinksNext=void 0;const t=EX();let e=class extends t.ActorRdfResolveHypermediaLinks{constructor(s){super(s)}async test(s){if(!s.metadata.next||s.metadata.next.length===0)throw new Error(`Actor ${this.name} requires a 'next' metadata entry.`);return!0}async run(s){return{links:s.metadata.next.map(n=>({url:n}))}}};return rd.ActorRdfResolveHypermediaLinksNext=e,rd}var s4;function RX(){return s4||(s4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(OX(),t)}(fw)),fw}var pw={},id={},yw={},ad={},o4;function xX(){if(o4)return ad;o4=1,Object.defineProperty(ad,"__esModule",{value:!0}),ad.ActorRdfSerialize=void 0;const t=iu();let e=class extends t.ActorAbstractMediaTyped{constructor(s){super(s)}};return ad.ActorRdfSerialize=e,ad}var sd={},u4;function IX(){if(u4)return sd;u4=1,Object.defineProperty(sd,"__esModule",{value:!0}),sd.ActorRdfSerializeFixedMediaTypes=void 0;const t=iu();let e=class extends t.ActorAbstractMediaTypedFixed{constructor(s){super(s)}async testHandleChecked(){return!0}};return sd.ActorRdfSerializeFixedMediaTypes=e,sd}var c4;function cA(){return c4||(c4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(xX(),t),u(IX(),t)}(yw)),yw}var l4;function PX(){if(l4)return id;l4=1,Object.defineProperty(id,"__esModule",{value:!0}),id.ActorRdfSerializeN3=void 0;const t=cA(),e=is;let u=class extends t.ActorRdfSerializeFixedMediaTypes{constructor(n){super(n)}async runHandle(n,r){const a=new e.StreamWriter({format:r});let o;return"pipe"in n.quadStream?(n.quadStream.on("error",l=>a.emit("error",l)),o=n.quadStream.pipe(a)):o=a.import(n.quadStream),{data:o,triples:r==="text/turtle"||r==="application/n-triples"||r==="text/n3"}}};return id.ActorRdfSerializeN3=u,id}var d4;function DX(){return d4||(d4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(PX(),t)}(pw)),pw}var bw={},od={},mw={},ud={},cd={},f4;function NX(){if(f4)return cd;f4=1,Object.defineProperty(cd,"__esModule",{value:!0}),cd.SeparatorType=void 0;let t=class{constructor(u){this.label=u}};return cd.SeparatorType=t,t.COMMA=new t(","),t.OBJECT_START=new t("{"),t.OBJECT_END=new t("}"),t.OBJECT_END_COMMA=new t("},"),t.ARRAY_START=new t("["),t.ARRAY_END=new t("]"),t.ARRAY_END_COMMA=new t("],"),t.GRAPH_FIELD_NONCOMPACT=new t('"@graph": ['),t.GRAPH_FIELD_COMPACT=new t('"@graph":['),t.CONTEXT_FIELD=new t('"@context":'),cd}var ld={},h4;function T7(){if(h4)return ld;h4=1,Object.defineProperty(ld,"__esModule",{value:!0}),ld.Util=void 0;const t=Jr();class e{static termToValue(s,n,r={compactIds:!1,useNativeTypes:!1}){switch(s.termType){case"NamedNode":const a=n.compactIri(s.value,r.vocab);return r.compactIds?a:{"@id":a};case"DefaultGraph":return r.compactIds?s.value:{"@id":s.value};case"BlankNode":const o=`_:${s.value}`;return r.compactIds?o:{"@id":o};case"Literal":if(s.datatype.value===e.RDF_JSON){let d;try{d=JSON.parse(s.value)}catch(h){throw new t.ErrorCoded("Invalid JSON literal: "+h.message,t.ERROR_CODES.INVALID_JSON_LITERAL)}return{"@value":d,"@type":"@json"}}if(r.rdfDirection==="i18n-datatype"&&s.datatype.value.startsWith(e.I18N)){const[d,h]=s.datatype.value.substr(e.I18N.length,s.datatype.value.length).split("_");return Object.assign(Object.assign({"@value":s.value},d?{"@language":d}:{}),h?{"@direction":h}:{})}const l=s.datatype.value===e.XSD_STRING,c={"@value":!l&&r.useNativeTypes?e.stringToNativeType(s.value,s.datatype.value):s.value};return s.language?Object.assign(Object.assign({},c),{"@language":s.language}):!l&&typeof c["@value"]=="string"?Object.assign(Object.assign({},c),{"@type":s.datatype.value}):c}}static stringToNativeType(s,n){if(n.startsWith(e.XSD))switch(n.substr(e.XSD.length)){case"boolean":if(s==="true")return!0;if(s==="false")return!1;throw new Error(`Invalid xsd:boolean value '${s}'`);case"integer":case"number":case"int":case"byte":case"long":const a=parseInt(s,10);if(isNaN(a))throw new Error(`Invalid xsd:integer value '${s}'`);return a;case"float":case"double":const o=parseFloat(s);if(isNaN(o))throw new Error(`Invalid xsd:float value '${s}'`);return o}return s}}return ld.Util=e,e.XSD="http://www.w3.org/2001/XMLSchema#",e.XSD_STRING=e.XSD+"string",e.RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#",e.RDF_TYPE=e.RDF+"type",e.RDF_JSON=e.RDF+"JSON",e.I18N="https://www.w3.org/ns/i18n#",ld}var p4;function CX(){if(p4)return ud;p4=1,Object.defineProperty(ud,"__esModule",{value:!0}),ud.JsonLdSerializer=void 0;const t=Jr(),e=NX(),u=T7(),s=Wt();let n=class A7 extends s.Transform{constructor(a={}){super({objectMode:!0}),this.indentation=0,this.options=a,this.options.baseIRI&&!this.options.context&&(this.options.context={"@base":this.options.baseIRI}),this.options.context?(this.originalContext=this.options.context,this.context=new t.ContextParser().parse(this.options.context,{baseIRI:this.options.baseIRI})):this.context=Promise.resolve(new t.JsonLdContextNormalized({}))}import(a){const o=new s.PassThrough({objectMode:!0});a.on("error",c=>l.emit("error",c)),a.on("data",c=>o.push(c)),a.on("end",()=>o.push(null));const l=o.pipe(new A7(this.options));return l}_transform(a,o,l){this.context.then(c=>{this.transformQuad(a,c),l()}).catch(l)}async list(a){const o=await this.context;return{"@list":a.map(l=>u.Util.termToValue(l,o,this.options))}}_flush(a){return this.opened||this.pushDocumentStart(),this.lastPredicate&&this.endPredicate(),this.lastSubject&&this.endSubject(),this.lastGraph&&this.lastGraph.termType!=="DefaultGraph"&&this.endGraph(),this.endDocument(),a(null,null)}transformQuad(a,o){this.opened||this.pushDocumentStart();const l=this.lastGraph&&this.lastGraph.termType!=="DefaultGraph"&&this.lastGraph.equals(a.subject);if(!l&&(!this.lastGraph||!a.graph.equals(this.lastGraph))){let c=a.graph.termType!=="DefaultGraph"&&this.lastSubject&&this.lastSubject.equals(a.graph);this.lastGraph&&(this.lastGraph.termType!=="DefaultGraph"?(this.endPredicate(),this.endSubject(),this.endGraph(!0),c=!1):c?(this.endPredicate(!0),this.lastSubject=null):(this.endPredicate(),this.endSubject(!0))),a.graph.termType!=="DefaultGraph"&&(c||this.pushId(a.graph,!0,o),this.pushSeparator(this.options.space?e.SeparatorType.GRAPH_FIELD_NONCOMPACT:e.SeparatorType.GRAPH_FIELD_COMPACT),this.indentation++),this.lastGraph=a.graph}(!this.lastSubject||!a.subject.equals(this.lastSubject))&&(l?(this.endPredicate(),this.endSubject(),this.indentation--,this.pushSeparator(e.SeparatorType.ARRAY_END_COMMA),this.lastGraph=a.graph):(this.lastSubject&&(this.endPredicate(),this.endSubject(!0)),this.pushId(a.subject,!0,o)),this.lastSubject=a.subject),(!this.lastPredicate||!a.predicate.equals(this.lastPredicate))&&(this.lastPredicate&&this.endPredicate(!0),this.pushPredicate(a.predicate,o)),this.pushObject(a.object,o)}pushDocumentStart(){this.opened=!0,this.originalContext&&!this.options.excludeContext?(this.pushSeparator(e.SeparatorType.OBJECT_START),this.indentation++,this.pushSeparator(e.SeparatorType.CONTEXT_FIELD),this.pushIndented(JSON.stringify(this.originalContext,null,this.options.space)+","),this.pushSeparator(this.options.space?e.SeparatorType.GRAPH_FIELD_NONCOMPACT:e.SeparatorType.GRAPH_FIELD_COMPACT),this.indentation++):(this.pushSeparator(e.SeparatorType.ARRAY_START),this.indentation++)}pushId(a,o,l){if(a.termType==="Quad")this.pushNestedQuad(a,!0,l);else{const c=a.termType==="BlankNode"?"_:"+a.value:l.compactIri(a.value,!1);o?this.pushSeparator(e.SeparatorType.OBJECT_START):(this.push(e.SeparatorType.OBJECT_START.label),this.options.space&&this.push(` +`)),this.indentation++,this.pushIndented(this.options.space?`"@id": "${c}",`:`"@id":"${c}",`)}}pushPredicate(a,o){let l=a.value;!this.options.useRdfType&&l===u.Util.RDF_TYPE&&(l="@type",this.objectOptions=Object.assign(Object.assign({},this.options),{compactIds:!0,vocab:!0}));const c=o.compactIri(l,!0);this.pushIndented(this.options.space?`"${c}": [`:`"${c}":[`),this.indentation++,this.lastPredicate=a}pushObject(a,o){if(this.hadObjectForPredicate?this.pushSeparator(e.SeparatorType.COMMA):this.hadObjectForPredicate=!0,a.termType==="Quad"){const c=this.lastSubject,d=this.lastPredicate;this.hadObjectForPredicate=!1,this.pushNestedQuad(a,!1,o),this.endSubject(!1),this.hadObjectForPredicate=!0,this.lastPredicate=d,this.lastSubject=c;return}let l;try{a["@list"]?l=a:l=u.Util.termToValue(a,o,this.objectOptions||this.options)}catch(c){return this.emit("error",c)}this.pushIndented(JSON.stringify(l,null,this.options.space))}pushNestedQuad(a,o,l){this.pushSeparator(e.SeparatorType.OBJECT_START),this.indentation++,this.pushIndented(this.options.space?'"@id": ':'"@id":',!1),a.graph.termType!=="DefaultGraph"&&this.emit("error",new Error(`Found a nested quad with the non-default graph: ${a.graph.value}`)),this.pushId(a.subject,!1,l),this.pushPredicate(a.predicate,l),this.pushObject(a.object,l),this.endPredicate(!1),this.endSubject(o)}endDocument(){this.opened=!1,this.originalContext&&!this.options.excludeContext?(this.indentation--,this.pushSeparator(e.SeparatorType.ARRAY_END),this.indentation--,this.pushSeparator(e.SeparatorType.OBJECT_END)):(this.indentation--,this.pushSeparator(e.SeparatorType.ARRAY_END))}endPredicate(a){this.indentation--,this.pushSeparator(a?e.SeparatorType.ARRAY_END_COMMA:e.SeparatorType.ARRAY_END),this.hadObjectForPredicate=!1,this.objectOptions=null,this.lastPredicate=null}endSubject(a){this.indentation--,this.pushSeparator(a?e.SeparatorType.OBJECT_END_COMMA:e.SeparatorType.OBJECT_END),this.lastSubject=null}endGraph(a){this.indentation--,this.pushSeparator(e.SeparatorType.ARRAY_END),this.indentation--,this.pushSeparator(a?e.SeparatorType.OBJECT_END_COMMA:e.SeparatorType.OBJECT_END),this.lastGraph=null}pushSeparator(a){this.pushIndented(a.label)}pushIndented(a,o=!0){const l=this.getIndentPrefix(),c=a.split(` +`).map(d=>l+d).join(` +`);this.push(c),this.options.space&&o&&this.push(` +`)}getIndentPrefix(){return this.options.space?this.options.space.repeat(this.indentation):""}};return ud.JsonLdSerializer=n,ud}var y4;function jX(){return y4||(y4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(CX(),t),u(T7(),t)}(mw)),mw}var b4;function LX(){if(b4)return od;b4=1,Object.defineProperty(od,"__esModule",{value:!0}),od.ActorRdfSerializeJsonLd=void 0;const t=cA(),e=jX();let u=class extends t.ActorRdfSerializeFixedMediaTypes{constructor(n){super(n)}async runHandle(n,r,a){const o=new e.JsonLdSerializer({space:" ".repeat(this.jsonStringifyIndentSpaces)});let l;return"pipe"in n.quadStream?(n.quadStream.on("error",c=>o.emit("error",c)),l=n.quadStream.pipe(o)):l=o.import(n.quadStream),{data:l}}};return od.ActorRdfSerializeJsonLd=u,od}var m4;function MX(){return m4||(m4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(LX(),t)}(bw)),bw}var gw={},dd={},T1={},g4;function FX(){if(g4)return T1;g4=1,Object.defineProperty(T1,"__esModule",{value:!0});function t(u,s){return new Promise((n,r)=>{u.on("end",()=>n(s)),u.on("error",r)})}function e(u){const s=[];return t(u.on("data",n=>s.push(n)),s)}return T1.default=e,T1}var fd={},A1={},_w={},hd={},_4;function qX(){if(_4)return hd;_4=1,Object.defineProperty(hd,"__esModule",{value:!0}),hd.fragment=void 0;function t(s){let n=s;(n.endsWith("/")||n.endsWith("#"))&&(n=n.slice(0,n.length-1));const r=[];n.lastIndexOf("/")>0&&r.push(n.lastIndexOf("/")),n.lastIndexOf("#")>0&&r.push(n.lastIndexOf("#"));const a=Math.max(...r);return n.slice(a+1)}function e(s){var n;const r=(n=s.split(/[^a-z0-9]+/ig).filter(a=>a!=="").map(a=>a[0].toUpperCase()+a.slice(1)).join("").match(/[a-z][a-z0-9]+/ig))===null||n===void 0?void 0:n[0];return typeof r>"u"?void 0:r[0].toLowerCase()+r.slice(1)}function u(s){let n=t(s);return n=n?e(n):void 0,n||"v"}return hd.fragment=u,hd}var vw={},pd={},xs={},E1={exports:{}},v4;function BX(){return v4||(v4=1,function(t,e){var u=typeof self<"u"?self:I,s=function(){function r(){this.fetch=!1,this.DOMException=u.DOMException}return r.prototype=u,new r}();(function(r){(function(a){var o={searchParams:"URLSearchParams"in r,iterable:"Symbol"in r&&"iterator"in Symbol,blob:"FileReader"in r&&"Blob"in r&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in r,arrayBuffer:"ArrayBuffer"in r};function l(j){return j&&DataView.prototype.isPrototypeOf(j)}if(o.arrayBuffer)var c=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],d=ArrayBuffer.isView||function(j){return j&&c.indexOf(Object.prototype.toString.call(j))>-1};function h(j){if(typeof j!="string"&&(j=String(j)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(j))throw new TypeError("Invalid character in header field name");return j.toLowerCase()}function f(j){return typeof j!="string"&&(j=String(j)),j}function p(j){var q={next:function(){var $=j.shift();return{done:$===void 0,value:$}}};return o.iterable&&(q[Symbol.iterator]=function(){return q}),q}function y(j){this.map={},j instanceof y?j.forEach(function(q,$){this.append($,q)},this):Array.isArray(j)?j.forEach(function(q){this.append(q[0],q[1])},this):j&&Object.getOwnPropertyNames(j).forEach(function(q){this.append(q,j[q])},this)}y.prototype.append=function(j,q){j=h(j),q=f(q);var $=this.map[j];this.map[j]=$?$+", "+q:q},y.prototype.delete=function(j){delete this.map[h(j)]},y.prototype.get=function(j){return j=h(j),this.has(j)?this.map[j]:null},y.prototype.has=function(j){return this.map.hasOwnProperty(h(j))},y.prototype.set=function(j,q){this.map[h(j)]=f(q)},y.prototype.forEach=function(j,q){for(var $ in this.map)this.map.hasOwnProperty($)&&j.call(q,this.map[$],$,this)},y.prototype.keys=function(){var j=[];return this.forEach(function(q,$){j.push($)}),p(j)},y.prototype.values=function(){var j=[];return this.forEach(function(q){j.push(q)}),p(j)},y.prototype.entries=function(){var j=[];return this.forEach(function(q,$){j.push([$,q])}),p(j)},o.iterable&&(y.prototype[Symbol.iterator]=y.prototype.entries);function b(j){if(j.bodyUsed)return Promise.reject(new TypeError("Already read"));j.bodyUsed=!0}function g(j){return new Promise(function(q,$){j.onload=function(){q(j.result)},j.onerror=function(){$(j.error)}})}function m(j){var q=new FileReader,$=g(q);return q.readAsArrayBuffer(j),$}function v(j){var q=new FileReader,$=g(q);return q.readAsText(j),$}function _(j){for(var q=new Uint8Array(j),$=new Array(q.length),Z=0;Z-1?q:j}function L(j,q){q=q||{};var $=q.body;if(j instanceof L){if(j.bodyUsed)throw new TypeError("Already read");this.url=j.url,this.credentials=j.credentials,q.headers||(this.headers=new y(j.headers)),this.method=j.method,this.mode=j.mode,this.signal=j.signal,!$&&j._bodyInit!=null&&($=j._bodyInit,j.bodyUsed=!0)}else this.url=String(j);if(this.credentials=q.credentials||this.credentials||"same-origin",(q.headers||!this.headers)&&(this.headers=new y(q.headers)),this.method=D(q.method||this.method||"GET"),this.mode=q.mode||this.mode||null,this.signal=q.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&$)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody($)}L.prototype.clone=function(){return new L(this,{body:this._bodyInit})};function O(j){var q=new FormData;return j.trim().split("&").forEach(function($){if($){var Z=$.split("="),X=Z.shift().replace(/\+/g," "),le=Z.join("=").replace(/\+/g," ");q.append(decodeURIComponent(X),decodeURIComponent(le))}}),q}function E(j){var q=new y,$=j.replace(/\r?\n[\t ]+/g," ");return $.split(/\r?\n/).forEach(function(Z){var X=Z.split(":"),le=X.shift().trim();if(le){var K=X.join(":").trim();q.append(le,K)}}),q}S.call(L.prototype);function P(j,q){q||(q={}),this.type="default",this.status=q.status===void 0?200:q.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in q?q.statusText:"OK",this.headers=new y(q.headers),this.url=q.url||"",this._initBody(j)}S.call(P.prototype),P.prototype.clone=function(){return new P(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new y(this.headers),url:this.url})},P.error=function(){var j=new P(null,{status:0,statusText:""});return j.type="error",j};var M=[301,302,303,307,308];P.redirect=function(j,q){if(M.indexOf(q)===-1)throw new RangeError("Invalid status code");return new P(null,{status:q,headers:{location:j}})},a.DOMException=r.DOMException;try{new a.DOMException}catch{a.DOMException=function(q,$){this.message=q,this.name=$;var Z=Error(q);this.stack=Z.stack},a.DOMException.prototype=Object.create(Error.prototype),a.DOMException.prototype.constructor=a.DOMException}function U(j,q){return new Promise(function($,Z){var X=new L(j,q);if(X.signal&&X.signal.aborted)return Z(new a.DOMException("Aborted","AbortError"));var le=new XMLHttpRequest;function K(){le.abort()}le.onload=function(){var he={status:le.status,statusText:le.statusText,headers:E(le.getAllResponseHeaders()||"")};he.url="responseURL"in le?le.responseURL:he.headers.get("X-Request-URL");var Re="response"in le?le.response:le.responseText;$(new P(Re,he))},le.onerror=function(){Z(new TypeError("Network request failed"))},le.ontimeout=function(){Z(new TypeError("Network request failed"))},le.onabort=function(){Z(new a.DOMException("Aborted","AbortError"))},le.open(X.method,X.url,!0),X.credentials==="include"?le.withCredentials=!0:X.credentials==="omit"&&(le.withCredentials=!1),"responseType"in le&&o.blob&&(le.responseType="blob"),X.headers.forEach(function(he,Re){le.setRequestHeader(Re,he)}),X.signal&&(X.signal.addEventListener("abort",K),le.onreadystatechange=function(){le.readyState===4&&X.signal.removeEventListener("abort",K)}),le.send(typeof X._bodyInit>"u"?null:X._bodyInit)})}return U.polyfill=!0,r.fetch||(r.fetch=U,r.Headers=y,r.Request=L,r.Response=P),a.Headers=y,a.Request=L,a.Response=P,a.fetch=U,Object.defineProperty(a,"__esModule",{value:!0}),a})({})})(s),s.fetch.ponyfill=!0,delete s.fetch.polyfill;var n=s;e=n.fetch,e.default=n.fetch,e.fetch=n.fetch,e.Headers=n.Headers,e.Request=n.Request,e.Response=n.Response,t.exports=e}(E1,E1.exports)),E1.exports}var w4;function lA(){if(w4)return xs;w4=1;var t=I&&I.__awaiter||function(n,r,a,o){function l(c){return c instanceof a?c:new a(function(d){d(c)})}return new(a||(a=Promise))(function(c,d){function h(y){try{p(o.next(y))}catch(b){d(b)}}function f(y){try{p(o.throw(y))}catch(b){d(b)}}function p(y){y.done?c(y.value):l(y.value).then(h,f)}p((o=o.apply(n,r||[])).next())})};Object.defineProperty(xs,"__esModule",{value:!0}),xs.fetchContext=xs.fetchJson=void 0;const e=BX();function u(n,r){var a;return t(this,void 0,void 0,function*(){return(yield((a=r==null?void 0:r.fetch)!==null&&a!==void 0?a:e.fetch)(n)).json()})}xs.fetchJson=u;function s(n,r){return t(this,void 0,void 0,function*(){return(yield u(n,r))["@context"]})}return xs.fetchContext=s,xs}var S4;function UX(){if(S4)return pd;S4=1;var t=I&&I.__awaiter||function(s,n,r,a){function o(l){return l instanceof r?l:new r(function(c){c(l)})}return new(r||(r=Promise))(function(l,c){function d(p){try{f(a.next(p))}catch(y){c(y)}}function h(p){try{f(a.throw(p))}catch(y){c(y)}}function f(p){p.done?l(p.value):o(p.value).then(d,h)}f((a=a.apply(s,n||[])).next())})};Object.defineProperty(pd,"__esModule",{value:!0}),pd.lookupUri=void 0;const e=lA();function u(s,n){return t(this,void 0,void 0,function*(){const r=(yield(0,e.fetchContext)(`https://prefix.cc/${s}.file.jsonld`,n))[s];if(typeof r!="string")throw new Error(`Expected uri to be a string, received: ${r} of type ${typeof r}`);return r})}return pd.lookupUri=u,pd}var yd={},T4;function QX(){if(T4)return yd;T4=1;var t=I&&I.__awaiter||function(s,n,r,a){function o(l){return l instanceof r?l:new r(function(c){c(l)})}return new(r||(r=Promise))(function(l,c){function d(p){try{f(a.next(p))}catch(y){c(y)}}function h(p){try{f(a.throw(p))}catch(y){c(y)}}function f(p){p.done?l(p.value):o(p.value).then(d,h)}f((a=a.apply(s,n||[])).next())})};Object.defineProperty(yd,"__esModule",{value:!0}),yd.lookupPrefix=void 0;const e=lA();function u(s,n){return t(this,void 0,void 0,function*(){const r=new URL("https://prefix.cc/reverse");r.searchParams.append("uri",s),r.searchParams.append("format","jsonld");const a=Object.keys(yield(0,e.fetchContext)(r,n));if(a.length===0)throw new Error("No prefixes returned");return a[0]})}return yd.lookupPrefix=u,yd}var bd={},A4;function HX(){if(A4)return bd;A4=1;var t=I&&I.__awaiter||function(s,n,r,a){function o(l){return l instanceof r?l:new r(function(c){c(l)})}return new(r||(r=Promise))(function(l,c){function d(p){try{f(a.next(p))}catch(y){c(y)}}function h(p){try{f(a.throw(p))}catch(y){c(y)}}function f(p){p.done?l(p.value):o(p.value).then(d,h)}f((a=a.apply(s,n||[])).next())})};Object.defineProperty(bd,"__esModule",{value:!0}),bd.lookupAllPrefixes=void 0;const e=lA();function u(s){return t(this,void 0,void 0,function*(){return(0,e.fetchContext)("https://prefix.cc/context",s)})}return bd.lookupAllPrefixes=u,bd}var E4;function O4(){return E4||(E4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(UX(),t),u(QX(),t),u(HX(),t)}(vw)),vw}var R4;function $X(){return R4||(R4=1,function(t){var e=I&&I.__awaiter||function(o,l,c,d){function h(f){return f instanceof c?f:new c(function(p){p(f)})}return new(c||(c=Promise))(function(f,p){function y(m){try{g(d.next(m))}catch(v){p(v)}}function b(m){try{g(d.throw(m))}catch(v){p(v)}}function g(m){m.done?f(m.value):h(m.value).then(y,b)}g((d=d.apply(o,l||[])).next())})};Object.defineProperty(t,"__esModule",{value:!0}),t.lookupAllPrefixes=t.prefixToUri=t.uriToPrefix=void 0;const u=qX(),s=O4();function n(o,l){return e(this,void 0,void 0,function*(){let c;try{c=yield(0,s.lookupPrefix)(o,l)}catch{l!=null&&l.mintOnUnknown&&(c=(0,u.fragment)(o).slice(0,4))}if(typeof c<"u"&&typeof(l==null?void 0:l.existingPrefixes)=="object"&&c in l.existingPrefixes){let d=0;for(;`${c}${d}`in l.existingPrefixes;)d+=1;c=`${c}${d}`}return c})}t.uriToPrefix=n;function r(o,l){return e(this,void 0,void 0,function*(){try{return yield(0,s.lookupUri)(o,l)}catch{return}})}t.prefixToUri=r;var a=O4();Object.defineProperty(t,"lookupAllPrefixes",{enumerable:!0,get:function(){return a.lookupAllPrefixes}})}(_w)),_w}var md={},x4;function VX(){if(x4)return md;x4=1,Object.defineProperty(md,"__esModule",{value:!0}),md.getShaclName=void 0;function t(e){if(e.termType!=="NamedNode"||!e.value.startsWith("http://www.w3.org/ns/shacl#"))throw new Error(`Term ${e.value} is not part of the SHACL namespace`);return e.value.slice(27)}return md.getShaclName=t,md}var O1={},I4;function kX(){return I4||(I4=1,Object.defineProperty(O1,"__esModule",{value:!0}),O1.default={deactivated:!0,severity:!0,message:!0,class:!0,datatype:!0,nodeKind:!0,minExclusive:!0,minInclusive:!0,maxExclusive:!0,maxInclusive:!0,minLength:!0,maxLength:!0,pattern:!0,flags:!0,languageIn:!0,uniqueLang:!0,equals:!0,disjoint:!0,lessThan:!0,lessThanOrEquals:!0,qualifiedValueShape:!0,qualifiedMinCount:!0,qualifiedMaxCount:!0,qualifiedValueShapesDisjoint:!0,closed:!0,ignoredProperties:!0,hasValue:!0,in:!0,node:!0}),O1}var R1={},P4;function zX(){return P4||(P4=1,Object.defineProperty(R1,"__esModule",{value:!0}),R1.default={owl:"http://www.w3.org/2002/07/owl#",rdf:"http://www.w3.org/1999/02/22-rdf-syntax-ns#",rdfs:"http://www.w3.org/2000/01/rdf-schema#",sh:"http://www.w3.org/ns/shacl#",xsd:"http://www.w3.org/2001/XMLSchema#"}),R1}var x1={},D4;function GX(){return D4||(D4=1,Object.defineProperty(x1,"__esModule",{value:!0}),x1.default={targetNode:!0,targetObjectsOf:!0,targetSubjectsOf:!0,deactivated:!0,severity:!0,message:!0,class:!0,datatype:!0,nodeKind:!0,minExclusive:!0,minInclusive:!0,maxExclusive:!0,maxInclusive:!0,minLength:!0,maxLength:!0,pattern:!0,flags:!0,languageIn:!0,equals:!0,disjoint:!0,closed:!0,ignoredProperties:!0,hasValue:!0,in:!0}),x1}var N4;function WX(){if(N4)return A1;N4=1;var t=I&&I.__awaiter||function(p,y,b,g){function m(v){return v instanceof b?v:new b(function(_){_(v)})}return new(b||(b=Promise))(function(v,_){function w(D){try{A(g.next(D))}catch(L){_(L)}}function S(D){try{A(g.throw(D))}catch(L){_(L)}}function A(D){D.done?v(D.value):m(D.value).then(w,S)}A((g=g.apply(p,y||[])).next())})},e=I&&I.__importDefault||function(p){return p&&p.__esModule?p:{default:p}};Object.defineProperty(A1,"__esModule",{value:!0});const u=is,s=$X(),n=Ny(),r=VX(),a=e(kX()),o=e(zX()),l=e(GX());function c(p){var y;return(y=/^[^]*[#/]/.exec(p))===null||y===void 0?void 0:y[0]}const d={"http://www.w3.org/1999/02/22-rdf-syntax-ns#":"rdf","http://www.w3.org/2000/01/rdf-schema#":"rdfs","http://www.w3.org/ns/shacl#":"sh","http://www.w3.org/2001/XMLSchema#":"xsd"},h={rdf:"http://www.w3.org/1999/02/22-rdf-syntax-ns#",rdfs:"http://www.w3.org/2000/01/rdf-schema#",sh:"http://www.w3.org/ns/shacl#",xsd:"http://www.w3.org/2001/XMLSchema#"};class f{constructor(y,b,g={},m=void 0,v=!0,_=!1,w,S=!1){this.store=y,this.base=m,this.errorOnExtraQuads=v,this.mintUnspecifiedPrefixes=_,this.fetch=w,this.extendedSyntax=S,this.prefixes={},this.prefixRev={};for(const A of Object.keys(g)){const D=g[A],L=typeof D=="string"?D:D.value;!(L in d)&&!(A in h)&&(this.prefixRev[L]=A,this.prefixes[A]=L)}this.writer=b}write(){return t(this,void 0,void 0,function*(){const y=this.store.getQuads(null,"http://www.w3.org/1999/02/22-rdf-syntax-ns#type","http://www.w3.org/2002/07/owl#Ontology",null);if(y.length===1&&y[0].subject.termType==="NamedNode"){const g=y[0].subject;this.store.removeQuads(y),g.equals(new u.NamedNode("urn:x-base:default"))||this.writer.add(`BASE ${(0,n.termToString)(g)}`),yield this.writeImports(g)}else throw new Error("Base expected");if(this.mintUnspecifiedPrefixes){const g=new Set;for(const v of[...this.store.getSubjects(null,null,null),...this.store.getPredicates(null,null,null),...this.store.getObjects(null,null,null)])if(v.termType==="NamedNode"){const _=c(v.value);_&&!(_ in this.prefixRev)&&!(_ in d)&&g.add(_)}const m=Object.assign(Object.assign({},this.prefixes),h);yield Promise.all([...g].map(v=>(0,s.uriToPrefix)(v,{fetch:this.fetch,mintOnUnknown:!0,existingPrefixes:m}).then(_=>{this.prefixes[_]=v,m[_]=v,this.prefixRev[v]=_})))}const b=new Set([...this.store.getSubjects(null,null,null),...this.store.getPredicates(null,null,null),...this.store.getObjects(null,null,null)].filter(g=>g.termType==="NamedNode").map(g=>c(g.value)).filter(g=>typeof g=="string"));for(const g in this.prefixRev)b.has(g)||(delete this.prefixes[this.prefixRev[g]],delete this.prefixRev[g]);if(yield this.writePrefixes(),this.prefixes=Object.assign(Object.assign({},this.prefixes),h),this.prefixRev=Object.assign(Object.assign({},this.prefixRev),d),this.writer.newLine(),yield this.writeShapes(),this.extendedSyntax){const g=this.store.getSubjects(null,null,null);g.length>0&&this.writer.newLine(1);for(const m of g)this.writer.add(yield this.termToString(m,!0,!0)),this.writer.add(" "),this.writer.indent(),yield this.writeTurtlePredicates(m),this.writer.deindent();g.length>0&&(this.writer.add(" ."),this.writer.newLine())}if(this.errorOnExtraQuads&&this.store.size>0)throw new Error(`Dataset contains quads that cannot be written in SHACLC [ +${new u.Writer({prefixes:this.prefixes}).quadsToString(this.store.getQuads(null,null,null,null))}]`);this.writer.end()})}writeImports(y){return t(this,void 0,void 0,function*(){const b=this.store.getObjectsOnce(y,new u.NamedNode("http://www.w3.org/2002/07/owl#imports"),null);if(b.length>0)for(const g of b)this.writer.add(`IMPORTS <${g.value}>`,!0)})}writePrefixes(){return t(this,void 0,void 0,function*(){const y=Object.keys(this.prefixes).filter(b=>!(b in o.default)).sort();if(y.length>0)for(const b of y)this.writer.add(`PREFIX ${b}: <${this.prefixes[b]}>`,!0)})}termToString(y,b=!1,g=!1){return t(this,void 0,void 0,function*(){try{if(b)throw new Error("Shacl name disabled");return(0,r.getShaclName)(y)}catch{}if(y.termType==="NamedNode"){const m=c(y.value);return m&&m in this.prefixRev&&m in this.prefixRev?`${this.prefixRev[m]}:${y.value.slice(m.length)}`:(0,n.termToString)(y)}if(y.termType==="Literal")return y.datatypeString==="http://www.w3.org/2001/XMLSchema#integer"||y.datatypeString==="http://www.w3.org/2001/XMLSchema#boolean"?y.value:(0,n.termToString)(y);throw y.termType==="BlankNode"&&g&&(0,n.termToString)(y),new Error(`Invalid term type for extra statement ${y.value} (${y.termType})`)})}writeShapes(){return t(this,void 0,void 0,function*(){for(const y of this.store.getSubjectsOnce(new u.NamedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),new u.NamedNode("http://www.w3.org/ns/shacl#NodeShape"),null)){this.store.getQuadsOnce(y,new u.NamedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),new u.NamedNode("http://www.w3.org/2000/01/rdf-schema#Class"),null).length>0?this.writer.add("shapeClass "):this.writer.add("shape "),this.writer.add(yield this.termToString(y)),this.writer.add(" ");const b=this.store.getObjectsOnce(y,new u.NamedNode("http://www.w3.org/ns/shacl#targetClass"),null);if(b.length>0){this.writer.add("-> ");for(const m of b)m.termType==="NamedNode"?this.writer.add(yield this.termToString(m)):(this.writer.add("!"),this.writer.add(yield this.termToString(this.singleObject(m,new u.NamedNode("http://www.w3.org/ns/shacl#not"),!0)))),this.writer.add(" ")}const g=this.store.getPredicates(y,null,null).filter(m=>[new u.NamedNode("http://www.w3.org/ns/shacl#targetClass"),new u.NamedNode("http://www.w3.org/ns/shacl#property"),new u.NamedNode("http://www.w3.org/ns/shacl#or"),...Object.keys(l.default).map(v=>new u.NamedNode("http://www.w3.org/ns/shacl#"+v))].every(v=>!m.equals(v)));g.length>0&&(this.writer.add(";"),this.writer.indent(),this.writer.newLine(1)),this.extendedSyntax&&(yield this.writeGivenTurtlePredicates(y,g)),g.length>0&&(this.writer.add(" "),this.writer.deindent()),yield this.writeShapeBody(y,!1)}})}getSingleProperty(y,b){let g=[y];try{let m=(0,r.getShaclName)(y.predicate),v="pred";if(m==="not"){const _=this.store.getQuadsOnce(y.object,null,null,null);if(g=g.concat(_),_.length!==1)throw new Error("Can only handle having one predicate of 'not'");[y]=_,m=(0,r.getShaclName)(y.predicate),v="not"}if(!(m in b))throw new Error(`${m} is not allowed`);return{name:m,type:v,object:y.object}}catch{this.store.addQuads(g)}}singleLayerPropertiesList(y,b){const g=[];for(const m of this.store.getQuadsOnce(y,null,null,null)){const v=this.getSingleProperty(m,b);v&&g.push(v)}return g}expectOneProperty(y,b){const g=this.store.getQuadsOnce(y,null,null,null);if(g.length===1){const m=this.getSingleProperty(g[0],b);if(m)return m}this.store.addQuads(g)}orProperties(y,b){const g=[];for(const m of this.store.getQuadsOnce(y,new u.NamedNode("http://www.w3.org/ns/shacl#or"),null,null)){const v=[];for(const _ of this.getList(m.object)){const w=this.expectOneProperty(_,b);if(!w)throw this.store.addQuad(m),new Error("Each entry of the 'or' statement must declare exactly one property");v.push(w)}g.push(v)}return g}getList(y){let b=y;const g=[];for(;!b.equals(new u.NamedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#nil"));)g.push(this.singleObject(b,new u.NamedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#first"),!0)),b=this.singleObject(b,new u.NamedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#rest"),!0);return g}writeIriLiteralOrArray(y){return t(this,void 0,void 0,function*(){if(y.termType==="BlankNode"){this.writer.add("[");let b=!0;for(const g of this.getList(y))b?b=!1:this.writer.add(" "),this.writer.add(yield this.termToString(g));this.writer.add("]")}else this.writer.add(yield this.termToString(y))})}singleObject(y,b,g){var m;return(m=this.singleQuad(y,b,g))===null||m===void 0?void 0:m.object}singleQuad(y,b,g=!1){const m=this.store.getQuadsOnce(y,b,null,null);if(g&&m.length!==1)throw this.store.addQuads(m),new Error(`The subject and predicate ${y==null?void 0:y.value} ${b==null?void 0:b.value} must have exactly one object. Instead has ${m.length}`);if(m.length>1)throw this.store.addQuads(m),new Error(`The subject and predicate ${y==null?void 0:y.value} ${b==null?void 0:b.value} can have at most one object. Instead has ${m.length}`);return m.length===1?m[0]:void 0}writeAssigment({name:y,type:b,object:g}){return t(this,void 0,void 0,function*(){b==="not"&&this.writer.add("!"),this.writer.add(y),this.writer.add("="),yield this.writeIriLiteralOrArray(g)})}writeAtom({name:y,type:b,object:g}){return t(this,void 0,void 0,function*(){switch(b==="not"&&this.writer.add("!"),y){case"node":{if(g.termType==="NamedNode")this.writer.add(`@${yield this.termToString(g)}`);else if(g.termType==="BlankNode")yield this.writeShapeBody(g);else throw new Error("Invalid nested shape, must be blank node or IRI");return}case"nodeKind":{this.writer.add((0,r.getShaclName)(g));return}case"class":{this.writer.add(yield this.termToString(g));return}case"datatype":{this.writer.add(yield this.termToString(g));return}default:this.writer.add(y),this.writer.add("="),yield this.writeIriLiteralOrArray(g)}})}writeAssigments(y,b=" ",g=!0,m){return t(this,void 0,void 0,function*(){for(const v of y)g?g=!1:this.writer.add(b),m?yield this.writeAtom(v):yield this.writeAssigment(v)})}writeParams(y,b=!0,g,m=!1,v=!1){return t(this,void 0,void 0,function*(){const _=this.orProperties(y,g),w=this.singleLayerPropertiesList(y,g);v&&(_.length>0||w.length>0)&&this.writer.newLine(1);for(const S of _)b?b=!1:this.writer.add(" "),yield this.writeAssigments(S,"|",!0,m);yield this.writeAssigments(w," ",b,m),v&&(_.length>0||w.length>0)&&this.writer.add(" .")})}writeShapeBody(y,b=!0){return t(this,void 0,void 0,function*(){this.writer.add("{").indent();const g=this.store.getObjectsOnce(y,new u.NamedNode("http://www.w3.org/ns/shacl#property"),null);yield this.writeParams(y,!0,l.default,!1,!0);for(const m of g)this.writer.newLine(1),yield this.writeProperty(m);this.writer.deindent().newLine(1),b?this.writer.add("} ."):this.writer.add("}").newLine(1)})}writeProperty(y){return t(this,void 0,void 0,function*(){yield this.writePath(this.singleObject(y,new u.NamedNode("http://www.w3.org/ns/shacl#path"),!0));const b=this.singleObject(y,new u.NamedNode("http://www.w3.org/ns/shacl#minCount")),g=this.singleObject(y,new u.NamedNode("http://www.w3.org/ns/shacl#maxCount")),m=this.singleObject(y,new u.NamedNode("http://www.w3.org/ns/shacl#nodeKind")),v=this.singleObject(y,new u.NamedNode("http://www.w3.org/ns/shacl#class")),_=this.singleObject(y,new u.NamedNode("http://www.w3.org/ns/shacl#datatype")),w=this.store.getObjectsOnce(y,new u.NamedNode("http://www.w3.org/ns/shacl#node"),null);if(m&&(this.writer.add(" "),this.writer.add((0,r.getShaclName)(m))),v&&(this.writer.add(" "),this.writer.add(yield this.termToString(v))),_&&(this.writer.add(" "),this.writer.add(yield this.termToString(_))),b!==void 0||g!==void 0){if(this.writer.add(" ["),b){if(b.termType!=="Literal"||b.datatypeString!=="http://www.w3.org/2001/XMLSchema#integer")throw new Error("Invalid min value, must me an integer literal");this.writer.add(b.value)}else this.writer.add("0");if(this.writer.add(".."),g){if(g.termType!=="Literal"||g.datatypeString!=="http://www.w3.org/2001/XMLSchema#integer")throw new Error("Invalid max value, must me an integer literal");this.store.removeMatches(y,new u.NamedNode("http://www.w3.org/ns/shacl#maxCount"),void 0,void 0),this.writer.add(g.value)}else this.writer.add("*");this.writer.add("]")}yield this.writeParams(y,!1,a.default,!0);const S=[];for(const A of w)if(A.termType==="NamedNode")this.writer.add(" "),this.writer.add(`@${yield this.termToString(A)}`);else if(A.termType==="BlankNode")S.push(A);else throw new Error("Invalid nested shape, must be blank node or IRI");for(const A of S)this.writer.add(" "),yield this.writeShapeBody(A);this.extendedSyntax&&this.store.getQuads(y,null,null,null).length>0&&(this.writer.add(" %"),this.writer.indent(),this.writer.newLine(1),yield this.writeTurtlePredicates(y),this.writer.deindent(),this.writer.newLine(1),this.writer.add("%")),S.length===0&&this.writer.add(" .")})}writeTurtlePredicates(y){return t(this,void 0,void 0,function*(){return this.writeGivenTurtlePredicates(y,this.store.getPredicates(y,null,null))})}writeGivenTurtlePredicates(y,b){return t(this,void 0,void 0,function*(){let g=!1;if(b.some(m=>m.equals(u.DataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type")))){const m=this.store.getObjectsOnce(y,u.DataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),null);m.length>0&&(g=!0,this.writer.add("a "),yield this.writeTurtleObjects(m))}for(const m of b)m.equals(u.DataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"))||(g?(this.writer.add(" ;"),this.writer.newLine(1)):g=!0,this.writer.add(yield this.termToString(m,!0)),this.writer.add(" "),yield this.writeTurtleObjects(this.store.getObjectsOnce(y,m,null)))})}writeTurtleObjects(y){return t(this,void 0,void 0,function*(){const b=[],g=[];for(const v of y)v.termType==="BlankNode"&&[...this.store.match(null,null,v),...this.store.match(null,v,null)].length===0?b.push(v):g.push(v);this.writer.add((yield Promise.all(g.map(v=>this.termToString(v,!0,!0)))).join(", "));let m=g.length>0;if(b.length>0)for(const v of b)m?this.writer.add(", "):m=!0,(yield this.writeList(v))||(this.writer.add("["),this.writer.indent(),this.writer.newLine(1),yield this.writeTurtlePredicates(v),this.writer.deindent(),this.writer.newLine(1),this.writer.add("]"))})}writeList(y){return t(this,void 0,void 0,function*(){let b=y;const g=[],m=[];for(;!b.equals(u.DataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#nil"));){const _=this.store.getQuadsOnce(b,u.DataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#first"),null,null),w=this.store.getQuadsOnce(b,u.DataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#rest"),null,null);if(m.push(..._,...w),_.length!==1||w.length!==1||this.store.getQuads(b,null,null,null).length!==0)return this.store.addQuads(m),!1;g.push(_[0].object),b=w[0].object}let v=!1;this.writer.add("(");for(const _ of g)v?this.writer.add(" "):v=!0,yield this.writeTurtleObjects([_]);return this.writer.add(")"),!0})}writePath(y,b=!1){return t(this,void 0,void 0,function*(){if(y.termType==="NamedNode")this.writer.add(yield this.termToString(y));else if(y.termType==="BlankNode"){const g=this.store.getQuadsOnce(y,null,null,null);if(g.length===1){const{predicate:m,object:v}=g[0];switch(m.value){case"http://www.w3.org/ns/shacl#inversePath":this.writer.add("^"),yield this.writePath(v,!0);return;case"http://www.w3.org/ns/shacl#alternativePath":{const _=this.getList(v);if(_.length===0)throw new Error("Invalid Alternative Path - no options");if(_.length===1)yield this.writePath(_[0]);else{b&&this.writer.add("(");let w=!0;for(const S of _)w?w=!1:this.writer.add("|"),yield this.writePath(S,!0);b&&this.writer.add(")")}return}case"http://www.w3.org/ns/shacl#zeroOrMorePath":yield this.writePath(v,!0),this.writer.add("*");return;case"http://www.w3.org/ns/shacl#oneOrMorePath":yield this.writePath(v,!0),this.writer.add("+");return;case"http://www.w3.org/ns/shacl#zeroOrOnePath":yield this.writePath(v,!0),this.writer.add("?");return;default:throw new Error(`Invalid path type ${y.value}`)}}else{this.store.addQuads(g);const m=this.getList(y);if(m.length===0)throw new Error("Invalid Path");{b&&this.writer.add("(");let v=!0;for(const _ of m)v?v=!1:this.writer.add("/"),yield this.writePath(_,!0);b&&this.writer.add(")")}}}else throw new Error("Path should be named node or blank node")})}}return A1.default=f,A1}var I1={},C4;function JX(){if(C4)return I1;C4=1,Object.defineProperty(I1,"__esModule",{value:!0});class t{constructor(u){this.indents=0,this.write=u.write,this.end=u.end}indent(){return this.indents+=1,this}deindent(){if(this.indents<1)throw new Error(`Trying to deindent when indent is only ${this.indents}`);return this.indents-=1,this}add(u,s=!1){return this.write(s?` +${" ".repeat(this.indents)}${u}`:u,"utf-8"),this}newLine(u=2){return this.write(` +`.repeat(u)+" ".repeat(this.indents),"utf-8"),this}}return I1.default=t,I1}var P1={},j4;function XX(){if(j4)return P1;j4=1,Object.defineProperty(P1,"__esModule",{value:!0});const t=is;class e extends t.Store{getQuadsOnce(s,n,r,a){const o=this.getQuads(s,n,r,a);return this.removeQuads(o),o}getSubjectsOnce(s,n,r){return this.getQuadsOnce(null,s,n,r).map(a=>a.subject)}getObjectsOnce(s,n,r){return this.getQuadsOnce(s,n,null,r).map(a=>a.object)}}return P1.default=e,P1}var L4;function KX(){if(L4)return fd;L4=1;var t=I&&I.__awaiter||function(o,l,c,d){function h(f){return f instanceof c?f:new c(function(p){p(f)})}return new(c||(c=Promise))(function(f,p){function y(m){try{g(d.next(m))}catch(v){p(v)}}function b(m){try{g(d.throw(m))}catch(v){p(v)}}function g(m){m.done?f(m.value):h(m.value).then(y,b)}g((d=d.apply(o,l||[])).next())})},e=I&&I.__importDefault||function(o){return o&&o.__esModule?o:{default:o}};Object.defineProperty(fd,"__esModule",{value:!0}),fd.write=void 0;const u=is,s=e(WX()),n=e(JX()),r=e(XX());function a(o,l){return t(this,void 0,void 0,function*(){return new Promise((c,d)=>t(this,void 0,void 0,function*(){try{let h="";const f=new r.default(o),p=f.getGraphs(null,null,null);if(p.length>1)throw new Error("More than one graph found - can serialize in the default graph");if(p.length===1&&!p[0].equals(u.DataFactory.defaultGraph()))throw new Error(`Expected all triples to be in the default graph, instead triples were in ${p[0].value}`);const y=new n.default({write:g=>{h+=g},end:()=>{let g=f.getQuads(null,null,null,null);g.length===0&&(g=void 0),c({text:h,extraQuads:g})}});yield new s.default(f,y,l==null?void 0:l.prefixes,void 0,(l==null?void 0:l.errorOnUnused)!==!1,l==null?void 0:l.mintPrefixes,l==null?void 0:l.fetch,l==null?void 0:l.extendedSyntax).write()}catch(h){d(h)}}))})}return fd.write=a,fd}var M4;function YX(){if(M4)return dd;M4=1,Object.defineProperty(dd,"__esModule",{value:!0}),dd.ActorRdfSerializeShaclc=void 0;const t=cA(),e=FX(),u=Wt(),s=KX();let n=class extends t.ActorRdfSerializeFixedMediaTypes{constructor(a){super(a)}async runHandle(a,o){const l=new u.Readable;l._read=()=>{};try{const c={};a.quadStream.on("prefix",(h,f)=>{c[h]=f});const{text:d}=await(0,s.write)(await(0,e.default)(a.quadStream),{errorOnUnused:!0,extendedSyntax:o==="text/shaclc-ext",prefixes:c});l.push(d),l.push(null)}catch(c){l._read=()=>{l.emit("error",c)}}return{data:l,triples:!0}}};return dd.ActorRdfSerializeShaclc=n,dd}var F4;function ZX(){return F4||(F4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(YX(),t)}(gw)),gw}var ww={},gd={},Sw={},_d={},q4;function eK(){if(q4)return _d;q4=1,Object.defineProperty(_d,"__esModule",{value:!0}),_d.ActorRdfResolveHypermediaLinksQueue=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return _d.ActorRdfResolveHypermediaLinksQueue=e,_d}var Tw={},B4;function tK(){return B4||(B4=1,Object.defineProperty(Tw,"__esModule",{value:!0})),Tw}var vd={},U4;function rK(){if(U4)return vd;U4=1,Object.defineProperty(vd,"__esModule",{value:!0}),vd.LinkQueueWrapper=void 0;let t=class{constructor(u){this.linkQueue=u}push(u,s){return this.linkQueue.push(u,s)}getSize(){return this.linkQueue.getSize()}isEmpty(){return this.linkQueue.isEmpty()}pop(){return this.linkQueue.pop()}peek(){return this.linkQueue.peek()}};return vd.LinkQueueWrapper=t,vd}var Q4;function nK(){return Q4||(Q4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(eK(),t),u(tK(),t),u(rK(),t)}(Sw)),Sw}var wd={},H4;function E7(){if(H4)return wd;H4=1,Object.defineProperty(wd,"__esModule",{value:!0}),wd.LinkQueueFifo=void 0;let t=class{constructor(){this.links=[]}push(u){return this.links.push(u),!0}getSize(){return this.links.length}isEmpty(){return this.links.length===0}pop(){return this.links.shift()}peek(){return this.links[0]}};return wd.LinkQueueFifo=t,wd}var $4;function iK(){if($4)return gd;$4=1,Object.defineProperty(gd,"__esModule",{value:!0}),gd.ActorRdfResolveHypermediaLinksQueueFifo=void 0;const t=nK(),e=E7();let u=class extends t.ActorRdfResolveHypermediaLinksQueue{constructor(n){super(n)}async test(n){return!0}async run(n){return{linkQueue:new e.LinkQueueFifo}}};return gd.ActorRdfResolveHypermediaLinksQueueFifo=u,gd}var V4;function aK(){return V4||(V4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(iK(),t),u(E7(),t)}(ww)),ww}var Aw={},Sd={},Ew={},Td={},k4;function O7(){if(k4)return Td;k4=1,Object.defineProperty(Td,"__esModule",{value:!0}),Td.ActorRdfUpdateQuads=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return Td.ActorRdfUpdateQuads=e,Td}var ua={},z4;function sK(){if(z4)return ua;z4=1,Object.defineProperty(ua,"__esModule",{value:!0}),ua.ActorRdfUpdateQuadsDestination=ua.deskolemize=ua.deskolemizeStream=void 0;const t=dq(),e=Lt,u=O7();function s(a,o){return a==null?void 0:a.map(l=>(0,t.deskolemizeQuad)(l,o))}ua.deskolemizeStream=s;function n(a){var c;const o=a.context.get(e.KeysRdfUpdateQuads.destination),l=(c=a.context.get(e.KeysQuerySourceIdentify.sourceIds))==null?void 0:c.get(o);return l?{...a,quadStreamInsert:s(a.quadStreamInsert,l),quadStreamDelete:s(a.quadStreamDelete,l)}:a}ua.deskolemize=n;let r=class extends u.ActorRdfUpdateQuads{async test(o){return!0}async run(o){const l=await this.getDestination(o.context);return await this.getOutput(l,n(o))}async getOutput(o,l){return{execute:async()=>{await(l.quadStreamDelete?o.delete(l.quadStreamDelete):Promise.resolve()),await(l.deleteGraphs?o.deleteGraphs(l.deleteGraphs.graphs,l.deleteGraphs.requireExistence,l.deleteGraphs.dropGraphs):Promise.resolve()),await(l.createGraphs?o.createGraphs(l.createGraphs.graphs,l.createGraphs.requireNonExistence):Promise.resolve()),await(l.quadStreamInsert?o.insert(l.quadStreamInsert):Promise.resolve())}}}};return ua.ActorRdfUpdateQuadsDestination=r,ua}var Ow={},G4;function oK(){return G4||(G4=1,Object.defineProperty(Ow,"__esModule",{value:!0})),Ow}var Sn={},W4;function uK(){if(W4)return Sn;W4=1,Object.defineProperty(Sn,"__esModule",{value:!0}),Sn.getContextDestinationUrl=Sn.getContextDestination=Sn.getDataDestinationContext=Sn.getDataDestinationValue=Sn.getDataDestinationType=Sn.isDataDestinationRawType=void 0;const t=Lt;function e(o){return typeof o=="string"||"remove"in o}Sn.isDataDestinationRawType=e;function u(o){return typeof o=="string"?"":"remove"in o?"rdfjsStore":o.type}Sn.getDataDestinationType=u;function s(o){return e(o)?o:o.value}Sn.getDataDestinationValue=s;function n(o,l){return typeof o=="string"||"remove"in o||!o.context?l:l.merge(o.context)}Sn.getDataDestinationContext=n;function r(o){return o.get(t.KeysRdfUpdateQuads.destination)}Sn.getContextDestination=r;function a(o){if(o){let l=s(o);if(typeof l=="string"){const c=l.indexOf("#");return c>=0&&(l=l.slice(0,c)),l}}}return Sn.getContextDestinationUrl=a,Sn}var J4;function dA(){return J4||(J4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(O7(),t),u(sK(),t),u(oK(),t),u(uK(),t)}(Ew)),Ew}var Ad={},X4;function cK(){if(X4)return Ad;X4=1,Object.defineProperty(Ad,"__esModule",{value:!0}),Ad.RdfJsQuadDestination=void 0;const t=y7(),e=Et(),u=Xt(),s=new e.DataFactory;let n=class{constructor(a){this.store=a}delete(a){return(0,t.promisifyEventEmitter)(this.store.remove(a))}insert(a){return(0,t.promisifyEventEmitter)(this.store.import(a))}async deleteGraphs(a,o,l){switch(a){case"ALL":await(0,t.promisifyEventEmitter)(this.store.deleteGraph(s.defaultGraph()));case"NAMED":const c=this.store.match(),d={};c.on("data",h=>{h.graph.termType!=="DefaultGraph"&&(d[(0,u.termToString)(h.graph)]=!0)}),await(0,t.promisifyEventEmitter)(c),await Promise.all(Object.keys(d).map(h=>(0,t.promisifyEventEmitter)(this.store.deleteGraph((0,u.stringToTerm)(h)))));break;default:for(const h of Array.isArray(a)?a:[a])await(0,t.promisifyEventEmitter)(this.store.deleteGraph(h))}}async createGraphs(a,o){if(o)for(const l of a){const c=this.store.match(void 0,void 0,void 0,l);await new Promise((d,h)=>{c.once("data",()=>{h(new Error(`Unable to create graph ${l.value} as it already exists`))}),c.on("end",d),c.on("error",h)})}}};return Ad.RdfJsQuadDestination=n,Ad}var K4;function lK(){if(K4)return Sd;K4=1,Object.defineProperty(Sd,"__esModule",{value:!0}),Sd.ActorRdfUpdateQuadsRdfJsStore=void 0;const t=dA(),e=cK();let u=class extends t.ActorRdfUpdateQuadsDestination{constructor(n){super(n)}async test(n){const r=(0,t.getContextDestination)(n.context);if(!r||typeof r=="string"||!("remove"in r)&&"value"in r&&!r.value.remove)throw new Error(`${this.name} received an invalid rdfjsStore.`);return!0}async getDestination(n){const r=(0,t.getContextDestination)(n);return new e.RdfJsQuadDestination("remove"in r?r:r.value)}};return Sd.ActorRdfUpdateQuadsRdfJsStore=u,Sd}var Y4;function dK(){return Y4||(Y4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(lK(),t)}(Aw)),Aw}var Rw={},Ed={},xw={},Od={},Iw={},Is={},Z4;function fK(){if(Z4)return Is;Z4=1,Object.defineProperty(Is,"__esModule",{value:!0}),Is.readableFromWeb=Is.ReadableFromWeb=void 0;const t=Wt();let e=class extends t.Readable{constructor(n,r){super(r),this.reader=n.getReader(),this.readerClosed=!1,this.reader.closed.then(()=>{this.readerClosed=!0}).catch(a=>{this.readerClosed=!0,this.destroy(a)})}_read(){this.reader.read().then(n=>this.push(n.done?null:n.value)).catch(n=>this.destroy(n))}destroy(n){return this.readerClosed||this.reader.cancel(n).then().catch(()=>{}),super.destroy(n)}};Is.ReadableFromWeb=e;function u(s,n){return new e(s,n)}return Is.readableFromWeb=u,Is}var e6;function hK(){return e6||(e6=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.readableFromWeb=void 0;var e=fK();Object.defineProperty(t,"readableFromWeb",{enumerable:!0,get:function(){return e.readableFromWeb}})}(Iw)),Iw}function D1(t){throw new Error('Could not dynamically require "'+t+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var Pw={exports:{}},t6;function pK(){return t6||(t6=1,function(t,e){(function(u){t.exports=u()})(function(){return function u(s,n,r){function a(c,d){if(!n[c]){if(!s[c]){var h=typeof D1=="function"&&D1;if(!d&&h)return h(c,!0);if(o)return o(c,!0);var f=new Error("Cannot find module '"+c+"'");throw f.code="MODULE_NOT_FOUND",f}var p=n[c]={exports:{}};s[c][0].call(p.exports,function(y){var b=s[c][1][y];return a(b||y)},p,p.exports,u,s,n,r)}return n[c].exports}for(var o=typeof D1=="function"&&D1,l=0;l=0;he--)if(Re[he]!==ie[he])return!1;for(he=Re.length-1;he>=0;he--)if(K=Re[he],!g(j[K],q[K],$,Z))return!1;return!0}function _(j,q,$){g(j,q,!0)&&y(j,q,$,"notDeepStrictEqual",_)}function w(j,q){if(!j||!q)return!1;if(Object.prototype.toString.call(q)=="[object RegExp]")return q.test(j);try{if(j instanceof q)return!0}catch{}return!Error.isPrototypeOf(q)&&q.call({},j)===!0}function S(j){var q;try{j()}catch($){q=$}return q}function A(j,q,$,Z){var X;if(typeof q!="function")throw new TypeError('"block" argument must be a function');typeof $=="string"&&(Z=$,$=null),X=S(q),Z=($&&$.name?" ("+$.name+").":".")+(Z?" "+Z:"."),j&&!X&&y(X,$,"Missing expected exception"+Z);var le=typeof Z=="string",K=!j&&D.isError(X),he=!j&&X&&!$;if((K&&le&&w(X,$)||he)&&y(X,$,"Got unwanted exception"+Z),j&&X&&$&&!w(X,$)||!j&&X)throw X}var D=u("util/"),L=Object.prototype.hasOwnProperty,O=Array.prototype.slice,E=(function(){}).name==="foo",P=s.exports=b,M=/\s*function\s+([^\(\s]*)\s*/;P.AssertionError=function(q){this.name="AssertionError",this.actual=q.actual,this.expected=q.expected,this.operator=q.operator,q.message?(this.message=q.message,this.generatedMessage=!1):(this.message=p(this),this.generatedMessage=!0);var $=q.stackStartFunction||y;if(Error.captureStackTrace)Error.captureStackTrace(this,$);else{var Z=new Error;if(Z.stack){var X=Z.stack,le=d($),K=X.indexOf(` +`+le);if(K>=0){var he=X.indexOf(` +`,K+1);X=X.substring(he+1)}this.stack=X}}},D.inherits(P.AssertionError,Error),P.fail=y,P.ok=b,P.equal=function(q,$,Z){q!=$&&y(q,$,Z,"==",P.equal)},P.notEqual=function(q,$,Z){q==$&&y(q,$,Z,"!=",P.notEqual)},P.deepEqual=function(q,$,Z){g(q,$,!1)||y(q,$,Z,"deepEqual",P.deepEqual)},P.deepStrictEqual=function(q,$,Z){g(q,$,!0)||y(q,$,Z,"deepStrictEqual",P.deepStrictEqual)},P.notDeepEqual=function(q,$,Z){g(q,$,!1)&&y(q,$,Z,"notDeepEqual",P.notDeepEqual)},P.notDeepStrictEqual=_,P.strictEqual=function(q,$,Z){q!==$&&y(q,$,Z,"===",P.strictEqual)},P.notStrictEqual=function(q,$,Z){q===$&&y(q,$,Z,"!==",P.notStrictEqual)},P.throws=function(j,q,$){A(!0,j,q,$)},P.doesNotThrow=function(j,q,$){A(!1,j,q,$)},P.ifError=function(j){if(j)throw j};var U=Object.keys||function(j){var q=[];for(var $ in j)L.call(j,$)&&q.push($);return q}}).call(this,typeof I<"u"?I:typeof self<"u"?self:typeof window<"u"?window:{})},{"util/":7}],3:[function(u,s,n){},{}],4:[function(u,s,n){function r(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function o(w){if(p===setTimeout)return setTimeout(w,0);if((p===r||!p)&&setTimeout)return p=setTimeout,setTimeout(w,0);try{return p(w,0)}catch{try{return p.call(null,w,0)}catch{return p.call(this,w,0)}}}function l(w){if(y===clearTimeout)return clearTimeout(w);if((y===a||!y)&&clearTimeout)return y=clearTimeout,clearTimeout(w);try{return y(w)}catch{try{return y.call(null,w)}catch{return y.call(this,w)}}}function c(){v&&g&&(v=!1,g.length?m=g.concat(m):_=-1,m.length&&d())}function d(){if(!v){var w=o(c);v=!0;for(var S=m.length;S;){for(g=m,m=[];++_1)for(var A=1;A=3&&(Ee.depth=arguments[2]),arguments.length>=4&&(Ee.colors=arguments[3]),v(ae)?Ee.showHidden=ae:ae&&n._extend(Ee,ae),L(Ee.showHidden)&&(Ee.showHidden=!1),L(Ee.depth)&&(Ee.depth=2),L(Ee.colors)&&(Ee.colors=!1),L(Ee.customInspect)&&(Ee.customInspect=!0),Ee.colors&&(Ee.stylize=l),h(Ee,ie,Ee.depth)}function l(ie,ae){var Ee=o.styles[ae];return Ee?"\x1B["+o.colors[Ee][0]+"m"+ie+"\x1B["+o.colors[Ee][1]+"m":ie}function c(ie,ae){return ie}function d(ie){var ae={};return ie.forEach(function(Ee,De){ae[Ee]=!0}),ae}function h(ie,ae,Ee){if(ie.customInspect&&ae&&U(ae.inspect)&&ae.inspect!==n.inspect&&(!ae.constructor||ae.constructor.prototype!==ae)){var De=ae.inspect(Ee,ie);return A(De)||(De=h(ie,De,Ee)),De}var ge=f(ie,ae);if(ge)return ge;var de=Object.keys(ae),fe=d(de);if(ie.showHidden&&(de=Object.getOwnPropertyNames(ae)),M(ae)&&(de.indexOf("message")>=0||de.indexOf("description")>=0))return p(ae);if(de.length===0){if(U(ae)){var H=ae.name?": "+ae.name:"";return ie.stylize("[Function"+H+"]","special")}if(O(ae))return ie.stylize(RegExp.prototype.toString.call(ae),"regexp");if(P(ae))return ie.stylize(Date.prototype.toString.call(ae),"date");if(M(ae))return p(ae)}var N="",R=!1,T=["{","}"];if(m(ae)&&(R=!0,T=["[","]"]),U(ae)&&(N=" [Function"+(ae.name?": "+ae.name:"")+"]"),O(ae)&&(N=" "+RegExp.prototype.toString.call(ae)),P(ae)&&(N=" "+Date.prototype.toUTCString.call(ae)),M(ae)&&(N=" "+p(ae)),de.length===0&&(!R||ae.length==0))return T[0]+N+T[1];if(Ee<0)return O(ae)?ie.stylize(RegExp.prototype.toString.call(ae),"regexp"):ie.stylize("[Object]","special");ie.seen.push(ae);var x;return x=R?y(ie,ae,Ee,fe,de):de.map(function(B){return b(ie,ae,Ee,fe,B,R)}),ie.seen.pop(),g(x,N,T)}function f(ie,ae){if(L(ae))return ie.stylize("undefined","undefined");if(A(ae)){var Ee="'"+JSON.stringify(ae).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return ie.stylize(Ee,"string")}return S(ae)?ie.stylize(""+ae,"number"):v(ae)?ie.stylize(""+ae,"boolean"):_(ae)?ie.stylize("null","null"):void 0}function p(ie){return"["+Error.prototype.toString.call(ie)+"]"}function y(ie,ae,Ee,De,ge){for(var de=[],fe=0,H=ae.length;fe-1&&(H=de?H.split(` +`).map(function(R){return" "+R}).join(` +`).substr(2):` +`+H.split(` +`).map(function(R){return" "+R}).join(` +`)):H=ie.stylize("[Circular]","special")),L(fe)){if(de&&ge.match(/^\d+$/))return H;(fe=JSON.stringify(""+ge)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(fe=fe.substr(1,fe.length-2),fe=ie.stylize(fe,"name")):(fe=fe.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),fe=ie.stylize(fe,"string"))}return fe+": "+H}function g(ie,ae,Ee){var De=0;return ie.reduce(function(ge,de){return De++,de.indexOf(` +`)>=0&&De++,ge+de.replace(/\u001b\[\d\d?m/g,"").length+1},0)>60?Ee[0]+(ae===""?"":ae+` + `)+" "+ie.join(`, + `)+" "+Ee[1]:Ee[0]+ae+" "+ie.join(", ")+" "+Ee[1]}function m(ie){return Array.isArray(ie)}function v(ie){return typeof ie=="boolean"}function _(ie){return ie===null}function w(ie){return ie==null}function S(ie){return typeof ie=="number"}function A(ie){return typeof ie=="string"}function D(ie){return typeof ie=="symbol"}function L(ie){return ie===void 0}function O(ie){return E(ie)&&q(ie)==="[object RegExp]"}function E(ie){return typeof ie=="object"&&ie!==null}function P(ie){return E(ie)&&q(ie)==="[object Date]"}function M(ie){return E(ie)&&(q(ie)==="[object Error]"||ie instanceof Error)}function U(ie){return typeof ie=="function"}function j(ie){return ie===null||typeof ie=="boolean"||typeof ie=="number"||typeof ie=="string"||typeof ie=="symbol"||ie===void 0}function q(ie){return Object.prototype.toString.call(ie)}function $(ie){return ie<10?"0"+ie.toString(10):ie.toString(10)}function Z(){var ie=new Date,ae=[$(ie.getHours()),$(ie.getMinutes()),$(ie.getSeconds())].join(":");return[ie.getDate(),Re[ie.getMonth()],ae].join(" ")}function X(ie,ae){return Object.prototype.hasOwnProperty.call(ie,ae)}var le=/%[sdj%]/g;n.format=function(ie){if(!A(ie)){for(var ae=[],Ee=0;Ee=ge)return N;switch(N){case"%s":return String(De[Ee++]);case"%d":return Number(De[Ee++]);case"%j":try{return JSON.stringify(De[Ee++])}catch{return"[Circular]"}default:return N}}),fe=De[Ee];Ee3&&arguments[3]!==void 0?arguments[3]:1,st=arguments.length>4&&arguments[4]!==void 0?arguments[4]:function(){return 1},ht=Object.create(Ni.prototype);return d(ht),ge(ht,Object.create(Xr.prototype),ue,ve,Ce,Xe,st),ht}function c(ue,ve,Ce){var Xe=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,st=arguments.length>4&&arguments[4]!==void 0?arguments[4]:void 0,ht=Object.create(Ni.prototype);return d(ht),Ne(ht,Object.create(Zn.prototype),ue,ve,Ce,Xe,st),ht}function d(ue){ue._state="readable",ue._reader=void 0,ue._storedError=void 0,ue._disturbed=!1}function h(ue){return!!Ke(ue)&&!!Object.prototype.hasOwnProperty.call(ue,"_readableStreamController")}function f(ue){return ue._disturbed}function p(ue){return ue._reader!==void 0}function y(ue,ve){function Ce(){return $(st).then(function(Fr){var gn=Fr.value;if(Fr.done===!0&&ht===!1&&(St===!1&&K(vr._readableStreamController),Qt===!1&&K(zt._readableStreamController),ht=!0),ht!==!0){var Hn=gn,$n=gn;St===!1&&he(vr._readableStreamController,Hn),Qt===!1&&he(zt._readableStreamController,$n)}})}function Xe(){}var st=o(ue),ht=!1,St=!1,Qt=!1,Kt=void 0,lr=void 0,vr=void 0,zt=void 0,Mn=void 0,ei=new Promise(function(Fr){Mn=Fr});return vr=l(Xe,Ce,function(gn){if(St=!0,Kt=gn,Qt===!0){var Hn=Ir([Kt,lr]),$n=m(ue,Hn);Mn($n)}return ei}),zt=l(Xe,Ce,function(gn){if(Qt=!0,lr=gn,St===!0){var Hn=Ir([Kt,lr]),$n=m(ue,Hn);Mn($n)}return ei}),st._closedPromise.catch(function(Fr){ht!==!0&&(ie(vr._readableStreamController,Fr),ie(zt._readableStreamController,Fr),ht=!0)}),[vr,zt]}function b(ue){return new Promise(function(ve,Ce){var Xe={_resolve:ve,_reject:Ce};ue._reader._readIntoRequests.push(Xe)})}function g(ue){return new Promise(function(ve,Ce){var Xe={_resolve:ve,_reject:Ce};ue._reader._readRequests.push(Xe)})}function m(ue,ve){return ue._disturbed=!0,ue._state==="closed"?Promise.resolve(void 0):ue._state==="errored"?Promise.reject(ue._storedError):(v(ue),ue._readableStreamController[hi](ve).then(function(){}))}function v(ue){ue._state="closed";var ve=ue._reader;if(ve!==void 0){if(P(ve)===!0){var Ce=!0,Xe=!1,st=void 0;try{for(var ht,St=ve._readRequests[Symbol.iterator]();!(Ce=(ht=St.next()).done);Ce=!0)(0,ht.value._resolve)(Ye(void 0,!0))}catch(Qt){Xe=!0,st=Qt}finally{try{!Ce&&St.return&&St.return()}finally{if(Xe)throw st}}ve._readRequests=[]}tt(ve)}}function _(ue,ve){ue._state="errored",ue._storedError=ve;var Ce=ue._reader;if(Ce!==void 0){if(P(Ce)===!0){var Xe=!0,st=!1,ht=void 0;try{for(var St,Qt=Ce._readRequests[Symbol.iterator]();!(Xe=(St=Qt.next()).done);Xe=!0)St.value._reject(ve)}catch(ei){st=!0,ht=ei}finally{try{!Xe&&Qt.return&&Qt.return()}finally{if(st)throw ht}}Ce._readRequests=[]}else{var Kt=!0,lr=!1,vr=void 0;try{for(var zt,Mn=Ce._readIntoRequests[Symbol.iterator]();!(Kt=(zt=Mn.next()).done);Kt=!0)zt.value._reject(ve)}catch(ei){lr=!0,vr=ei}finally{try{!Kt&&Mn.return&&Mn.return()}finally{if(lr)throw vr}}Ce._readIntoRequests=[]}He(Ce,ve),Ce._closedPromise.catch(function(){})}}function w(ue,ve,Ce){ue._reader._readIntoRequests.shift()._resolve(Ye(ve,Ce))}function S(ue,ve,Ce){ue._reader._readRequests.shift()._resolve(Ye(ve,Ce))}function A(ue){return ue._reader._readIntoRequests.length}function D(ue){return ue._reader._readRequests.length}function L(ue){var ve=ue._reader;return ve!==void 0&&E(ve)!==!1}function O(ue){var ve=ue._reader;return ve!==void 0&&P(ve)!==!1}function E(ue){return!!Ke(ue)&&!!Object.prototype.hasOwnProperty.call(ue,"_readIntoRequests")}function P(ue){return!!Ke(ue)&&!!Object.prototype.hasOwnProperty.call(ue,"_readRequests")}function M(ue,ve){ue._ownerReadableStream=ve,ve._reader=ue,ve._state==="readable"?Se(ue):ve._state==="closed"?je(ue):(Ae(ue,ve._storedError),ue._closedPromise.catch(function(){}))}function U(ue,ve){return m(ue._ownerReadableStream,ve)}function j(ue){ue._ownerReadableStream._state==="readable"?He(ue,new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")):Ge(ue,new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")),ue._closedPromise.catch(function(){}),ue._ownerReadableStream._reader=void 0,ue._ownerReadableStream=void 0}function q(ue,ve){var Ce=ue._ownerReadableStream;return Ce._disturbed=!0,Ce._state==="errored"?Promise.reject(Ce._storedError):re(Ce._readableStreamController,ve)}function $(ue){var ve=ue._ownerReadableStream;return ve._disturbed=!0,ve._state==="closed"?Promise.resolve(Ye(void 0,!0)):ve._state==="errored"?Promise.reject(ve._storedError):ve._readableStreamController[Mr]()}function Z(ue){return!!Ke(ue)&&!!Object.prototype.hasOwnProperty.call(ue,"_controlledReadableStream")}function X(ue){le(ue)!==!1&&(ue._pulling!==!0?(ue._pulling=!0,ue._pullAlgorithm().then(function(){if(ue._pulling=!1,ue._pullAgain===!0)return ue._pullAgain=!1,X(ue)},function(ve){ie(ue,ve)}).catch(Ie)):ue._pullAgain=!0)}function le(ue){var ve=ue._controlledReadableStream;return De(ue)!==!1&&ue._started!==!1&&(p(ve)===!0&&D(ve)>0||ae(ue)>0)}function K(ue){var ve=ue._controlledReadableStream;ue._closeRequested=!0,ue._queue.length===0&&v(ve)}function he(ue,ve){var Ce=ue._controlledReadableStream;if(p(Ce)===!0&&D(Ce)>0)S(Ce,ve,!1);else{var Xe=void 0;try{Xe=ue._strategySizeAlgorithm(ve)}catch(st){throw ie(ue,st),st}try{at(ue,ve,Xe)}catch(st){throw ie(ue,st),st}}X(ue)}function Re(ue,ve){var Ce=ue._controlledReadableStream;Tt(ue),_(Ce,ve)}function ie(ue,ve){ue._controlledReadableStream._state==="readable"&&Re(ue,ve)}function ae(ue){var ve=ue._controlledReadableStream._state;return ve==="errored"?null:ve==="closed"?0:ue._strategyHWM-ue._queueTotalSize}function Ee(ue){return le(ue)!==!0}function De(ue){var ve=ue._controlledReadableStream._state;return ue._closeRequested===!1&&ve==="readable"}function ge(ue,ve,Ce,Xe,st,ht,St){ve._controlledReadableStream=ue,ve._queue=void 0,ve._queueTotalSize=void 0,Tt(ve),ve._started=!1,ve._closeRequested=!1,ve._pullAgain=!1,ve._pulling=!1,ve._strategySizeAlgorithm=St,ve._strategyHWM=ht,ve._pullAlgorithm=Xe,ve._cancelAlgorithm=st,ue._readableStreamController=ve;var Qt=Ce();Promise.resolve(Qt).then(function(){ve._started=!0,X(ve)},function(Kt){ie(ve,Kt)}).catch(Ie)}function de(ue,ve,Ce,Xe){var st=Object.create(Xr.prototype),ht=Fe(ve,"pull",0,[st]),St=Fe(ve,"cancel",1,[]);ge(ue,st,function(){return Je(ve,"start",[st])},ht,St,Ce,Xe)}function fe(ue){return!!Ke(ue)&&!!Object.prototype.hasOwnProperty.call(ue,"_controlledReadableByteStream")}function H(ue){return!!Ke(ue)&&!!Object.prototype.hasOwnProperty.call(ue,"_associatedReadableByteStreamController")}function N(ue){qe(ue)!==!1&&(ue._pulling!==!0?(ue._pulling=!0,ue._pullAlgorithm().then(function(){ue._pulling=!1,ue._pullAgain===!0&&(ue._pullAgain=!1,N(ue))},function(ve){ue._controlledReadableByteStream._state==="readable"&&Q(ue,ve)}).catch(Ie)):ue._pullAgain=!0)}function R(ue){z(ue),ue._pendingPullIntos=[]}function T(ue,ve){var Ce=!1;ue._state==="closed"&&(Ce=!0);var Xe=x(ve);ve.readerType==="default"?S(ue,Xe,Ce):w(ue,Xe,Ce)}function x(ue){var ve=ue.bytesFilled,Ce=ue.elementSize;return new ue.ctor(ue.buffer,ue.byteOffset,ve/Ce)}function B(ue,ve,Ce,Xe){ue._queue.push({buffer:ve,byteOffset:Ce,byteLength:Xe}),ue._queueTotalSize+=Xe}function k(ue,ve){var Ce=ve.elementSize,Xe=ve.bytesFilled-ve.bytesFilled%Ce,st=Math.min(ue._queueTotalSize,ve.byteLength-ve.bytesFilled),ht=ve.bytesFilled+st,St=ht-ht%Ce,Qt=st,Kt=!1;St>Xe&&(Qt=St-ve.bytesFilled,Kt=!0);for(var lr=ue._queue;Qt>0;){var vr=lr[0],zt=Math.min(Qt,vr.byteLength),Mn=ve.byteOffset+ve.bytesFilled;Ue(ve.buffer,Mn,vr.buffer,vr.byteOffset,zt),vr.byteLength===zt?lr.shift():(vr.byteOffset+=zt,vr.byteLength-=zt),ue._queueTotalSize-=zt,V(ue,zt,ve),Qt-=zt}return Kt}function V(ue,ve,Ce){z(ue),Ce.bytesFilled+=ve}function J(ue){ue._queueTotalSize===0&&ue._closeRequested===!0?v(ue._controlledReadableByteStream):N(ue)}function z(ue){ue._byobRequest!==void 0&&(ue._byobRequest._associatedReadableByteStreamController=void 0,ue._byobRequest._view=void 0,ue._byobRequest=void 0)}function Y(ue){for(;ue._pendingPullIntos.length>0;){if(ue._queueTotalSize===0)return;var ve=ue._pendingPullIntos[0];k(ue,ve)===!0&&(Le(ue),T(ue._controlledReadableByteStream,ve))}}function re(ue,ve){var Ce=ue._controlledReadableByteStream,Xe=1;ve.constructor!==DataView&&(Xe=ve.constructor.BYTES_PER_ELEMENT);var st=ve.constructor,ht={buffer:yt(ve.buffer),byteOffset:ve.byteOffset,byteLength:ve.byteLength,bytesFilled:0,elementSize:Xe,ctor:st,readerType:"byob"};if(ue._pendingPullIntos.length>0)return ue._pendingPullIntos.push(ht),b(Ce);if(Ce._state==="closed"){var St=new ve.constructor(ht.buffer,ht.byteOffset,0);return Promise.resolve(Ye(St,!0))}if(ue._queueTotalSize>0){if(k(ue,ht)===!0){var Qt=x(ht);return J(ue),Promise.resolve(Ye(Qt,!1))}if(ue._closeRequested===!0){var Kt=new TypeError("Insufficient bytes to fill elements in the given buffer");return Q(ue,Kt),Promise.reject(Kt)}}ue._pendingPullIntos.push(ht);var lr=b(Ce);return N(ue),lr}function ce(ue,ve){ve.buffer=yt(ve.buffer);var Ce=ue._controlledReadableByteStream;if(L(Ce)===!0)for(;A(Ce)>0;)T(Ce,Le(ue))}function Te(ue,ve,Ce){if(Ce.bytesFilled+ve>Ce.byteLength)throw new RangeError("bytesWritten out of range");if(V(ue,ve,Ce),!(Ce.bytesFilled0){var st=Ce.byteOffset+Ce.bytesFilled,ht=Ce.buffer.slice(st-Xe,st);B(ue,ht,0,ht.byteLength)}Ce.buffer=yt(Ce.buffer),Ce.bytesFilled-=Xe,T(ue._controlledReadableByteStream,Ce),Y(ue)}}function xe(ue,ve){var Ce=ue._pendingPullIntos[0];if(ue._controlledReadableByteStream._state==="closed"){if(ve!==0)throw new TypeError("bytesWritten must be 0 when calling respond() on a closed stream");ce(ue,Ce)}else Te(ue,ve,Ce)}function Le(ue){var ve=ue._pendingPullIntos.shift();return z(ue),ve}function qe(ue){var ve=ue._controlledReadableByteStream;return ve._state==="readable"&&ue._closeRequested!==!0&&ue._started!==!1&&(O(ve)===!0&&D(ve)>0||L(ve)===!0&&A(ve)>0||te(ue)>0)}function G(ue){var ve=ue._controlledReadableByteStream;if(ue._queueTotalSize>0)ue._closeRequested=!0;else{if(ue._pendingPullIntos.length>0&&ue._pendingPullIntos[0].bytesFilled>0){var Ce=new TypeError("Insufficient bytes to fill elements in the given buffer");throw Q(ue,Ce),Ce}v(ve)}}function F(ue,ve){var Ce=ue._controlledReadableByteStream,Xe=ve.buffer,st=ve.byteOffset,ht=ve.byteLength,St=yt(Xe);O(Ce)===!0?D(Ce)===0?B(ue,St,st,ht):S(Ce,new Uint8Array(St,st,ht),!1):L(Ce)===!0?(B(ue,St,st,ht),Y(ue)):B(ue,St,st,ht)}function Q(ue,ve){var Ce=ue._controlledReadableByteStream;R(ue),Tt(ue),_(Ce,ve)}function te(ue){var ve=ue._controlledReadableByteStream._state;return ve==="errored"?null:ve==="closed"?0:ue._strategyHWM-ue._queueTotalSize}function me(ue,ve){if(ve=Number(ve),$e(ve)===!1)throw new RangeError("bytesWritten must be a finite");xe(ue,ve)}function Oe(ue,ve){var Ce=ue._pendingPullIntos[0];if(Ce.byteOffset+Ce.bytesFilled!==ve.byteOffset)throw new RangeError("The region specified by view does not match byobRequest");if(Ce.byteLength!==ve.byteLength)throw new RangeError("The buffer of view has different capacity than byobRequest");Ce.buffer=ve.buffer,xe(ue,ve.byteLength)}function Ne(ue,ve,Ce,Xe,st,ht,St){ve._controlledReadableByteStream=ue,ve._pullAgain=!1,ve._pulling=!1,R(ve),ve._queue=ve._queueTotalSize=void 0,Tt(ve),ve._closeRequested=!1,ve._started=!1,ve._strategyHWM=ft(ht),ve._pullAlgorithm=Xe,ve._cancelAlgorithm=st,ve._autoAllocateChunkSize=St,ve._pendingPullIntos=[],ue._readableStreamController=ve;var Qt=Ce();Promise.resolve(Qt).then(function(){ve._started=!0,N(ve)},function(Kt){ue._state==="readable"&&Q(ve,Kt)}).catch(Ie)}function We(ue,ve,Ce){var Xe=Object.create(Zn.prototype),st=Fe(ve,"pull",0,[Xe]),ht=Fe(ve,"cancel",1,[]),St=ve.autoAllocateChunkSize;if(St!==void 0&&(Number.isInteger(St)===!1||St<=0))throw new RangeError("autoAllocateChunkSize must be a positive integer");Ne(ue,Xe,function(){return Je(ve,"start",[Xe])},st,ht,Ce,St)}function Ve(ue,ve,Ce){ue._associatedReadableByteStreamController=ve,ue._view=Ce}function pe(ue){return new TypeError("ReadableStream.prototype."+ue+" can only be used on a ReadableStream")}function we(ue){return new TypeError("Cannot "+ue+" a stream using a released reader")}function W(ue){return new TypeError("ReadableStreamDefaultReader.prototype."+ue+" can only be used on a ReadableStreamDefaultReader")}function Se(ue){ue._closedPromise=new Promise(function(ve,Ce){ue._closedPromise_resolve=ve,ue._closedPromise_reject=Ce})}function Ae(ue,ve){ue._closedPromise=Promise.reject(ve),ue._closedPromise_resolve=void 0,ue._closedPromise_reject=void 0}function je(ue){ue._closedPromise=Promise.resolve(void 0),ue._closedPromise_resolve=void 0,ue._closedPromise_reject=void 0}function He(ue,ve){ue._closedPromise_reject(ve),ue._closedPromise_resolve=void 0,ue._closedPromise_reject=void 0}function Ge(ue,ve){ue._closedPromise=Promise.reject(ve)}function tt(ue){ue._closedPromise_resolve(void 0),ue._closedPromise_resolve=void 0,ue._closedPromise_reject=void 0}function lt(ue){return new TypeError("ReadableStreamBYOBReader.prototype."+ue+" can only be used on a ReadableStreamBYOBReader")}function ut(ue){return new TypeError("ReadableStreamDefaultController.prototype."+ue+" can only be used on a ReadableStreamDefaultController")}function oe(ue){return new TypeError("ReadableStreamBYOBRequest.prototype."+ue+" can only be used on a ReadableStreamBYOBRequest")}function C(ue){return new TypeError("ReadableByteStreamController.prototype."+ue+" can only be used on a ReadableByteStreamController")}function ee(ue){try{Promise.prototype.then.call(ue,void 0,function(){})}catch{}}var ye=function(){function ue(ve,Ce){for(var Xe=0;Xe0&&arguments[0]!==void 0?arguments[0]:{},Ce=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Xe=Ce.size,st=Ce.highWaterMark;r(this,ue),d(this);var ht=ve.type;if(String(ht)==="bytes"){if(st===void 0&&(st=0),st=ft(st),Xe!==void 0)throw new RangeError("The strategy for a byte stream cannot have a size function");We(this,ve,st)}else{if(ht!==void 0)throw new RangeError("Invalid type is specified");st===void 0&&(st=1),de(this,ve,st=ft(st),et(Xe))}}return ye(ue,[{key:"cancel",value:function(Ce){return h(this)===!1?Promise.reject(pe("cancel")):p(this)===!0?Promise.reject(new TypeError("Cannot cancel a stream that already has a reader")):m(this,Ce)}},{key:"getReader",value:function(){var Ce=(arguments.length>0&&arguments[0]!==void 0?arguments[0]:{}).mode;if(h(this)===!1)throw pe("getReader");if(Ce===void 0)return o(this);if((Ce=String(Ce))==="byob")return a(this);throw new RangeError("Invalid mode is specified")}},{key:"pipeThrough",value:function(Ce,Xe){var st=Ce.writable,ht=Ce.readable;if(st===void 0||ht===void 0)throw new TypeError("readable and writable arguments must be defined");return ee(this.pipeTo(st,Xe)),ht}},{key:"pipeTo",value:function(Ce){var Xe=this,st=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},ht=st.preventClose,St=st.preventAbort,Qt=st.preventCancel;if(h(this)===!1)return Promise.reject(pe("pipeTo"));if(fi(Ce)===!1)return Promise.reject(new TypeError("ReadableStream.prototype.pipeTo's first argument must be a WritableStream"));if(ht=!!ht,St=!!St,Qt=!!Qt,p(this)===!0)return Promise.reject(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked ReadableStream"));if(bn(Ce)===!0)return Promise.reject(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked WritableStream"));var Kt=o(this),lr=rr(Ce),vr=!1,zt=Promise.resolve();return new Promise(function(Mn,ei){function Fr(){return vr===!0?Promise.resolve():lr._readyPromise.then(function(){return $(Kt).then(function(Yt){var zr=Yt.value;Yt.done!==!0&&(zt=Qn(lr,zr).catch(function(){}))})}).then(Fr)}function gn(){var Yt=zt;return zt.then(function(){return Yt!==zt?gn():void 0})}function Hn(Yt,zr,ri){Yt._state==="errored"?ri(Yt._storedError):zr.catch(ri).catch(Ie)}function $n(Yt,zr,ri){function Ea(){Yt().then(function(){return ea(zr,ri)},function(My){return ea(!0,My)}).catch(Ie)}vr!==!0&&(vr=!0,Ce._state==="writable"&&Pr(Ce)===!1?gn().then(Ea):Ea())}function ti(Yt,zr){vr!==!0&&(vr=!0,Ce._state==="writable"&&Pr(Ce)===!1?gn().then(function(){return ea(Yt,zr)}).catch(Ie):ea(Yt,zr))}function ea(Yt,zr){Qr(lr),j(Kt),Yt?ei(zr):Mn(void 0)}if(Hn(Xe,Kt._closedPromise,function(Yt){St===!1?$n(function(){return or(Ce,Yt)},!0,Yt):ti(!0,Yt)}),Hn(Ce,lr._closedPromise,function(Yt){Qt===!1?$n(function(){return m(Xe,Yt)},!0,Yt):ti(!0,Yt)}),function(zr,ri,Ea){zr._state==="closed"?Ea():ri.then(Ea).catch(Ie)}(Xe,Kt._closedPromise,function(){ht===!1?$n(function(){return Ln(lr)}):ti()}),Pr(Ce)===!0||Ce._state==="closed"){var io=new TypeError("the destination writable stream closed before all data could be piped to it");Qt===!1?$n(function(){return m(Xe,io)},!0,io):ti(!0,io)}Fr().catch(function(Yt){zt=Promise.resolve(),Ie(Yt)})})}},{key:"tee",value:function(){if(h(this)===!1)throw pe("tee");var Ce=y(this);return Ir(Ce)}},{key:"locked",get:function(){if(h(this)===!1)throw pe("locked");return p(this)}}]),ue}();s.exports={CreateReadableByteStream:c,CreateReadableStream:l,ReadableStream:Ni,IsReadableStreamDisturbed:f,ReadableStreamDefaultControllerClose:K,ReadableStreamDefaultControllerEnqueue:he,ReadableStreamDefaultControllerError:Re,ReadableStreamDefaultControllerGetDesiredSize:ae,ReadableStreamDefaultControllerHasBackpressure:Ee,ReadableStreamDefaultControllerCanCloseOrEnqueue:De};var Zi=function(){function ue(ve){if(r(this,ue),h(ve)===!1)throw new TypeError("ReadableStreamDefaultReader can only be constructed with a ReadableStream instance");if(p(ve)===!0)throw new TypeError("This stream has already been locked for exclusive reading by another reader");M(this,ve),this._readRequests=[]}return ye(ue,[{key:"cancel",value:function(Ce){return P(this)===!1?Promise.reject(W("cancel")):this._ownerReadableStream===void 0?Promise.reject(we("cancel")):U(this,Ce)}},{key:"read",value:function(){return P(this)===!1?Promise.reject(W("read")):this._ownerReadableStream===void 0?Promise.reject(we("read from")):$(this)}},{key:"releaseLock",value:function(){if(P(this)===!1)throw W("releaseLock");if(this._ownerReadableStream!==void 0){if(this._readRequests.length>0)throw new TypeError("Tried to release a reader lock when that reader has pending read() calls un-settled");j(this)}}},{key:"closed",get:function(){return P(this)===!1?Promise.reject(W("closed")):this._closedPromise}}]),ue}(),mn=function(){function ue(ve){if(r(this,ue),!h(ve))throw new TypeError("ReadableStreamBYOBReader can only be constructed with a ReadableStream instance given a byte source");if(fe(ve._readableStreamController)===!1)throw new TypeError("Cannot construct a ReadableStreamBYOBReader for a stream not constructed with a byte source");if(p(ve))throw new TypeError("This stream has already been locked for exclusive reading by another reader");M(this,ve),this._readIntoRequests=[]}return ye(ue,[{key:"cancel",value:function(Ce){return E(this)?this._ownerReadableStream===void 0?Promise.reject(we("cancel")):U(this,Ce):Promise.reject(lt("cancel"))}},{key:"read",value:function(Ce){return E(this)?this._ownerReadableStream===void 0?Promise.reject(we("read from")):ArrayBuffer.isView(Ce)?nt(Ce.buffer)===!0?Promise.reject(new TypeError("Cannot read into a view onto a detached ArrayBuffer")):Ce.byteLength===0?Promise.reject(new TypeError("view must have non-zero byteLength")):q(this,Ce):Promise.reject(new TypeError("view must be an array buffer view")):Promise.reject(lt("read"))}},{key:"releaseLock",value:function(){if(!E(this))throw lt("releaseLock");if(this._ownerReadableStream!==void 0){if(this._readIntoRequests.length>0)throw new TypeError("Tried to release a reader lock when that reader has pending read() calls un-settled");j(this)}}},{key:"closed",get:function(){return E(this)?this._closedPromise:Promise.reject(lt("closed"))}}]),ue}(),Xr=function(){function ue(){throw r(this,ue),new TypeError}return ye(ue,[{key:"close",value:function(){if(Z(this)===!1)throw ut("close");if(De(this)===!1)throw new TypeError("The stream is not in a state that permits close");K(this)}},{key:"enqueue",value:function(Ce){if(Z(this)===!1)throw ut("enqueue");if(De(this)===!1)throw new TypeError("The stream is not in a state that permits enqueue");return he(this,Ce)}},{key:"error",value:function(Ce){if(Z(this)===!1)throw ut("error");var Xe=this._controlledReadableStream;if(Xe._state!=="readable")throw new TypeError("The stream is "+Xe._state+" and so cannot be errored");Re(this,Ce)}},{key:hi,value:function(Ce){return Tt(this),this._cancelAlgorithm(Ce)}},{key:Mr,value:function(){var Ce=this._controlledReadableStream;if(this._queue.length>0){var Xe=it(this);return this._closeRequested===!0&&this._queue.length===0?v(Ce):X(this),Promise.resolve(Ye(Xe,!1))}var st=g(Ce);return X(this),st}},{key:"desiredSize",get:function(){if(Z(this)===!1)throw ut("desiredSize");return ae(this)}}]),ue}(),ls=function(){function ue(){throw r(this,ue),new TypeError("ReadableStreamBYOBRequest cannot be used directly")}return ye(ue,[{key:"respond",value:function(Ce){if(H(this)===!1)throw oe("respond");if(this._associatedReadableByteStreamController===void 0)throw new TypeError("This BYOB request has been invalidated");if(nt(this._view.buffer)===!0)throw new TypeError("The BYOB request's buffer has been detached and so cannot be used as a response");me(this._associatedReadableByteStreamController,Ce)}},{key:"respondWithNewView",value:function(Ce){if(H(this)===!1)throw oe("respond");if(this._associatedReadableByteStreamController===void 0)throw new TypeError("This BYOB request has been invalidated");if(!ArrayBuffer.isView(Ce))throw new TypeError("You can only respond with array buffer views");if(nt(Ce.buffer)===!0)throw new TypeError("The supplied view's buffer has been detached and so cannot be used as a response");Oe(this._associatedReadableByteStreamController,Ce)}},{key:"view",get:function(){if(H(this)===!1)throw oe("view");return this._view}}]),ue}(),Zn=function(){function ue(){throw r(this,ue),new TypeError("ReadableByteStreamController constructor cannot be used directly")}return ye(ue,[{key:"close",value:function(){if(fe(this)===!1)throw C("close");if(this._closeRequested===!0)throw new TypeError("The stream has already been closed; do not close it again!");var Ce=this._controlledReadableByteStream._state;if(Ce!=="readable")throw new TypeError("The stream (in "+Ce+" state) is not in the readable state and cannot be closed");G(this)}},{key:"enqueue",value:function(Ce){if(fe(this)===!1)throw C("enqueue");if(this._closeRequested===!0)throw new TypeError("stream is closed or draining");var Xe=this._controlledReadableByteStream._state;if(Xe!=="readable")throw new TypeError("The stream (in "+Xe+" state) is not in the readable state and cannot be enqueued to");if(!ArrayBuffer.isView(Ce))throw new TypeError("You can only enqueue array buffer views when using a ReadableByteStreamController");if(nt(Ce.buffer)===!0)throw new TypeError("Cannot enqueue a view onto a detached ArrayBuffer");F(this,Ce)}},{key:"error",value:function(Ce){if(fe(this)===!1)throw C("error");var Xe=this._controlledReadableByteStream;if(Xe._state!=="readable")throw new TypeError("The stream is "+Xe._state+" and so cannot be errored");Q(this,Ce)}},{key:hi,value:function(Ce){return this._pendingPullIntos.length>0&&(this._pendingPullIntos[0].bytesFilled=0),Tt(this),this._cancelAlgorithm(Ce)}},{key:Mr,value:function(){var Ce=this._controlledReadableByteStream;if(this._queueTotalSize>0){var Xe=this._queue.shift();this._queueTotalSize-=Xe.byteLength,J(this);var st=void 0;try{st=new Uint8Array(Xe.buffer,Xe.byteOffset,Xe.byteLength)}catch(lr){return Promise.reject(lr)}return Promise.resolve(Ye(st,!1))}var ht=this._autoAllocateChunkSize;if(ht!==void 0){var St=void 0;try{St=new ArrayBuffer(ht)}catch(lr){return Promise.reject(lr)}var Qt={buffer:St,byteOffset:0,byteLength:ht,bytesFilled:0,elementSize:1,ctor:Uint8Array,readerType:"default"};this._pendingPullIntos.push(Qt)}var Kt=g(Ce);return N(this),Kt}},{key:"byobRequest",get:function(){if(fe(this)===!1)throw C("byobRequest");if(this._byobRequest===void 0&&this._pendingPullIntos.length>0){var Ce=this._pendingPullIntos[0],Xe=new Uint8Array(Ce.buffer,Ce.byteOffset+Ce.bytesFilled,Ce.byteLength-Ce.bytesFilled),st=Object.create(ls.prototype);Ve(st,this,Xe),this._byobRequest=st}return this._byobRequest}},{key:"desiredSize",get:function(){if(fe(this)===!1)throw C("desiredSize");return te(this)}}]),ue}()},{"./helpers.js":10,"./queue-with-sizes.js":11,"./utils.js":14,"./writable-stream.js":15,"better-assert":16}],13:[function(u,s,n){function r(H,N){if(!(H instanceof N))throw new TypeError("Cannot call a class as a function")}function a(H,N,R){var T=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1,x=arguments.length>4&&arguments[4]!==void 0?arguments[4]:function(){return 1},B=arguments.length>5&&arguments[5]!==void 0?arguments[5]:0,k=arguments.length>6&&arguments[6]!==void 0?arguments[6]:function(){return 1},V=Object.create(de.prototype),J=void 0;o(V,new Promise(function(Y){J=Y}),T,x,B,k),p(V,Object.create(fe.prototype),N,R);var z=H();return J(z),V}function o(H,N,R,T,x,B){function k(){return N}H._writable=De(k,function(J){return v(H,J)},function(){return w(H)},function(){return _(H)},R,T),H._readable=X(k,function(){return S(H)},function(J){return d(H,J),Promise.resolve()},x,B),H._backpressure=void 0,H._backpressureChangePromise=void 0,H._backpressureChangePromise_resolve=void 0,h(H,!0),H._transformStreamController=void 0}function l(H){return!!j(H)&&!!Object.prototype.hasOwnProperty.call(H,"_transformStreamController")}function c(H,N){O("TransformStreamError()"),H._readable._state==="readable"&&he(H._readable._readableStreamController,N),d(H,N)}function d(H,N){ge(H._writable._writableStreamController,N),H._backpressure===!0&&h(H,!1)}function h(H,N){O("TransformStreamSetBackpressure() [backpressure = "+N+"]"),H._backpressureChangePromise!==void 0&&H._backpressureChangePromise_resolve(),H._backpressureChangePromise=new Promise(function(R){H._backpressureChangePromise_resolve=R}),H._backpressure=N}function f(H){return!!j(H)&&!!Object.prototype.hasOwnProperty.call(H,"_controlledTransformStream")}function p(H,N,R,T){N._controlledTransformStream=H,H._transformStreamController=N,N._transformAlgorithm=R,N._flushAlgorithm=T}function y(H,N){var R=Object.create(fe.prototype),T=function(V){try{return b(R,V),Promise.resolve()}catch(J){return Promise.reject(J)}},x=N.transform;if(x!==void 0){if(typeof x!="function")throw new TypeError("transform is not a method");T=function(V){return U(x,N,[V,R]).catch(function(J){throw c(H,J),J})}}var B=M(N,"flush",0,[R]);p(H,R,T,B)}function b(H,N){O("TransformStreamDefaultControllerEnqueue()");var R=H._controlledTransformStream,T=R._readable._readableStreamController;if(ae(T)===!1)throw new TypeError("Readable side is not in a state that permits enqueue");try{K(T,N)}catch(x){throw d(R,x),R._readable._storedError}ie(T)!==R._backpressure&&h(R,!0)}function g(H,N){c(H._controlledTransformStream,N)}function m(H){O("TransformStreamDefaultControllerTerminate()");var N=H._controlledTransformStream,R=N._readable._readableStreamController;ae(R)===!0&&le(R),d(N,new TypeError("TransformStream terminated"))}function v(H,N){O("TransformStreamDefaultSinkWriteAlgorithm()");var R=H._transformStreamController;return H._backpressure===!0?H._backpressureChangePromise.then(function(){var T=H._writable;if(T._state==="erroring")throw T._storedError;return R._transformAlgorithm(N)}):R._transformAlgorithm(N)}function _(H){return c(H,new TypeError("Writable side aborted")),Promise.resolve()}function w(H){O("TransformStreamDefaultSinkCloseAlgorithm()");var N=H._readable;return H._transformStreamController._flushAlgorithm().then(function(){if(N._state==="errored")throw N._storedError;var R=N._readableStreamController;ae(R)===!0&&le(R)}).catch(function(R){throw c(H,R),N._storedError})}function S(H){return O("TransformStreamDefaultSourcePullAlgorithm()"),h(H,!1),H._backpressureChangePromise}function A(H){return new TypeError("TransformStreamDefaultController.prototype."+H+" can only be used on a TransformStreamDefaultController")}function D(H){return new TypeError("TransformStream.prototype."+H+" can only be used on a TransformStream")}var L=function(){function H(N,R){for(var T=0;T0&&arguments[0]!==void 0?arguments[0]:{},R=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},T=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(r(this,H),N.readableType!==void 0)throw new RangeError("Invalid readable type specified");if(N.writableType!==void 0)throw new RangeError("Invalid writable type specified");var x=R.size,B=$(x),k=R.highWaterMark;k===void 0&&(k=1),k=q(k);var V=T.size,J=$(V),z=T.highWaterMark;z===void 0&&(z=0),z=q(z);var Y=void 0;o(this,new Promise(function(ce){Y=ce}),k,B,z,J),y(this,N);var re=P(N,"start",[this._transformStreamController]);Y(re)}return L(H,[{key:"readable",get:function(){if(l(this)===!1)throw D("readable");return this._readable}},{key:"writable",get:function(){if(l(this)===!1)throw D("writable");return this._writable}}]),H}(),fe=function(){function H(){throw r(this,H),new TypeError("TransformStreamDefaultController instances cannot be created directly")}return L(H,[{key:"enqueue",value:function(R){if(f(this)===!1)throw A("enqueue");b(this,R)}},{key:"error",value:function(R){if(f(this)===!1)throw A("error");g(this,R)}},{key:"terminate",value:function(){if(f(this)===!1)throw A("terminate");m(this)}},{key:"desiredSize",get:function(){if(f(this)===!1)throw A("desiredSize");var R=this._controlledTransformStream._readable._readableStreamController;return Re(R)}}]),H}();s.exports={CreateTransformStream:a,TransformStream:de}},{"./helpers.js":10,"./readable-stream.js":12,"./writable-stream.js":15,"better-assert":16,debug:18}],14:[function(u,s,n){var r=u("better-assert");n.rethrowAssertionErrorRejection=function(a){a&&a.constructor===r.AssertionError&&setTimeout(function(){throw a},0)}},{"better-assert":16}],15:[function(u,s,n){function r(C,ee){if(!(C instanceof ee))throw new TypeError("Cannot call a class as a function")}function a(C){return new ut(C)}function o(C,ee,ye,Pe){var Ue=arguments.length>4&&arguments[4]!==void 0?arguments[4]:1,Fe=arguments.length>5&&arguments[5]!==void 0?arguments[5]:function(){return 1},Ye=Object.create(lt.prototype);return l(Ye),K(Ye,Object.create(oe.prototype),C,ee,ye,Pe,Ue,Fe),Ye}function l(C){C._state="writable",C._storedError=void 0,C._writer=void 0,C._writableStreamController=void 0,C._writeRequests=[],C._inFlightWriteRequest=void 0,C._closeRequest=void 0,C._inFlightCloseRequest=void 0,C._pendingAbortRequest=void 0,C._backpressure=!1}function c(C){return!!Ve(C)&&!!Object.prototype.hasOwnProperty.call(C,"_writableStreamController")}function d(C){return C._writer!==void 0}function h(C,ee){var ye=C._state;if(ye==="closed")return Promise.resolve(void 0);if(ye==="errored")return Promise.reject(C._storedError);var Pe=new TypeError("Requested to abort");if(C._pendingAbortRequest!==void 0)return Promise.reject(Pe);var Ue=!1;ye==="erroring"&&(Ue=!0,ee=void 0);var Fe=new Promise(function(Ye,$e){C._pendingAbortRequest={_resolve:Ye,_reject:$e,_reason:ee,_wasAlreadyErroring:Ue}});return Ue===!1&&y(C,Pe),Fe}function f(C){return new Promise(function(ee,ye){var Pe={_resolve:ee,_reject:ye};C._writeRequests.push(Pe)})}function p(C,ee){Q("WritableStreamDealWithRejection(stream, %o)",ee),C._state!=="writable"?b(C):y(C,ee)}function y(C,ee){Q("WritableStreamStartErroring(stream, %o)",ee);var ye=C._writableStreamController;C._state="erroring",C._storedError=ee;var Pe=C._writer;Pe!==void 0&&q(Pe,ee),S(C)===!1&&ye._started===!0&&b(C)}function b(C){Q("WritableStreamFinishErroring()"),C._state="errored",C._writableStreamController[tt]();var ee=C._storedError,ye=!0,Pe=!1,Ue=void 0;try{for(var Fe,Ye=C._writeRequests[Symbol.iterator]();!(ye=(Fe=Ye.next()).done);ye=!0)Fe.value._reject(ee)}catch(Je){Pe=!0,Ue=Je}finally{try{!ye&&Ye.return&&Ye.return()}finally{if(Pe)throw Ue}}if(C._writeRequests=[],C._pendingAbortRequest!==void 0){var $e=C._pendingAbortRequest;if(C._pendingAbortRequest=void 0,$e._wasAlreadyErroring===!0)return $e._reject(ee),void L(C);C._writableStreamController[Ge]($e._reason).then(function(){$e._resolve(),L(C)},function(Je){$e._reject(Je),L(C)})}else L(C)}function g(C){C._inFlightWriteRequest._resolve(void 0),C._inFlightWriteRequest=void 0}function m(C,ee){C._inFlightWriteRequest._reject(ee),C._inFlightWriteRequest=void 0,p(C,ee)}function v(C){C._inFlightCloseRequest._resolve(void 0),C._inFlightCloseRequest=void 0,C._state==="erroring"&&(C._storedError=void 0,C._pendingAbortRequest!==void 0&&(C._pendingAbortRequest._resolve(),C._pendingAbortRequest=void 0)),C._state="closed";var ee=C._writer;ee!==void 0&&Y(ee)}function _(C,ee){C._inFlightCloseRequest._reject(ee),C._inFlightCloseRequest=void 0,C._pendingAbortRequest!==void 0&&(C._pendingAbortRequest._reject(ee),C._pendingAbortRequest=void 0),p(C,ee)}function w(C){return C._closeRequest!==void 0||C._inFlightCloseRequest!==void 0}function S(C){return C._inFlightWriteRequest===void 0&&C._inFlightCloseRequest===void 0?(Q("WritableStreamHasOperationMarkedInFlight() is false"),!1):(Q("WritableStreamHasOperationMarkedInFlight() is true"),!0)}function A(C){C._inFlightCloseRequest=C._closeRequest,C._closeRequest=void 0}function D(C){C._inFlightWriteRequest=C._writeRequests.shift()}function L(C){Q("WritableStreamRejectCloseAndClosedPromiseIfNeeded()"),C._closeRequest!==void 0&&(C._closeRequest._reject(C._storedError),C._closeRequest=void 0);var ee=C._writer;ee!==void 0&&(J(ee,C._storedError),ee._closedPromise.catch(function(){}))}function O(C,ee){var ye=C._writer;ye!==void 0&&ee!==C._backpressure&&(ee===!0?Le(ye):G(ye)),C._backpressure=ee}function E(C){return!!Ve(C)&&!!Object.prototype.hasOwnProperty.call(C,"_ownerWritableStream")}function P(C,ee){return h(C._ownerWritableStream,ee)}function M(C){var ee=C._ownerWritableStream,ye=ee._state;if(ye==="closed"||ye==="errored")return Promise.reject(new TypeError("The stream (in "+ye+" state) is not in the writable state and cannot be closed"));var Pe=new Promise(function(Ue,Fe){var Ye={_resolve:Ue,_reject:Fe};ee._closeRequest=Ye});return ee._backpressure===!0&&ye==="writable"&&G(C),Re(ee._writableStreamController),Pe}function U(C){var ee=C._ownerWritableStream,ye=ee._state;return w(ee)===!0||ye==="closed"?Promise.resolve():ye==="errored"?Promise.reject(ee._storedError):M(C)}function j(C,ee){C._closedPromiseState==="pending"?J(C,ee):z(C,ee),C._closedPromise.catch(function(){})}function q(C,ee){Q("WritableStreamDefaultWriterEnsureReadyPromiseRejected(writer, %o)",ee),C._readyPromiseState==="pending"?xe(C,ee):qe(C,ee),C._readyPromise.catch(function(){})}function $(C){var ee=C._ownerWritableStream,ye=ee._state;return ye==="errored"||ye==="erroring"?null:ye==="closed"?0:ae(ee._writableStreamController)}function Z(C){var ee=C._ownerWritableStream,ye=new TypeError("Writer was released and can no longer be used to monitor the stream's closedness");q(C,ye),j(C,ye),ee._writer=void 0,C._ownerWritableStream=void 0}function X(C,ee){var ye=C._ownerWritableStream,Pe=ye._writableStreamController,Ue=ie(Pe,ee);if(ye!==C._ownerWritableStream)return Promise.reject(x("write to"));var Fe=ye._state;if(Fe==="errored")return Promise.reject(ye._storedError);if(w(ye)===!0||Fe==="closed")return Promise.reject(new TypeError("The stream is closing or closed and cannot be written to"));if(Fe==="erroring")return Promise.reject(ye._storedError);var Ye=f(ye);return Ee(Pe,ee,Ue),Ye}function le(C){return!!Ve(C)&&!!Object.prototype.hasOwnProperty.call(C,"_controlledWritableStream")}function K(C,ee,ye,Pe,Ue,Fe,Ye,$e){ee._controlledWritableStream=C,C._writableStreamController=ee,ee._queue=void 0,ee._queueTotalSize=void 0,He(ee),ee._started=!1,ee._strategySizeAlgorithm=$e,ee._strategyHWM=Ye,ee._writeAlgorithm=Pe,ee._closeAlgorithm=Ue,ee._abortAlgorithm=Fe;var Je=H(ee);O(C,Je);var nt=ye();Promise.resolve(nt).then(function(){ee._started=!0,De(ee)},function(yt){ee._started=!0,p(C,yt)}).catch(we)}function he(C,ee,ye,Pe){var Ue=Object.create(oe.prototype),Fe=me(ee,"write",1,[Ue]),Ye=me(ee,"close",0,[]),$e=me(ee,"abort",1,[]);K(C,Ue,function(){return Oe(ee,"start",[Ue])},Fe,Ye,$e,ye,Pe)}function Re(C){Ae(C,"close",0),De(C)}function ie(C,ee){try{return C._strategySizeAlgorithm(ee)}catch(ye){return ge(C,ye),1}}function ae(C){return C._strategyHWM-C._queueTotalSize}function Ee(C,ee,ye){var Pe={chunk:ee};try{Ae(C,Pe,ye)}catch(Fe){return void ge(C,Fe)}var Ue=C._controlledWritableStream;w(Ue)===!1&&Ue._state==="writable"&&O(Ue,H(C)),De(C)}function De(C){Q("WritableStreamDefaultControllerAdvanceQueueIfNeeded()");var ee=C._controlledWritableStream;if(C._started!==!1&&ee._inFlightWriteRequest===void 0){var ye=ee._state;if(ye!=="closed"&&ye!=="errored")if(ye!=="erroring"){if(C._queue.length!==0){var Pe=je(C);Pe==="close"?de(C):fe(C,Pe.chunk)}}else b(ee)}}function ge(C,ee){C._controlledWritableStream._state==="writable"&&N(C,ee)}function de(C){var ee=C._controlledWritableStream;A(ee),Se(C),C._closeAlgorithm().then(function(){v(ee)},function(ye){_(ee,ye)}).catch(we)}function fe(C,ee){var ye=C._controlledWritableStream;D(ye),C._writeAlgorithm(ee).then(function(){g(ye);var Pe=ye._state;if(Se(C),w(ye)===!1&&Pe==="writable"){var Ue=H(C);O(ye,Ue)}De(C)},function(Pe){m(ye,Pe)}).catch(we)}function H(C){return ae(C)<=0}function N(C,ee){y(C._controlledWritableStream,ee)}function R(C){return new TypeError("WritableStream.prototype."+C+" can only be used on a WritableStream")}function T(C){return new TypeError("WritableStreamDefaultWriter.prototype."+C+" can only be used on a WritableStreamDefaultWriter")}function x(C){return new TypeError("Cannot "+C+" a stream using a released writer")}function B(C){C._closedPromise=new Promise(function(ee,ye){C._closedPromise_resolve=ee,C._closedPromise_reject=ye,C._closedPromiseState="pending"})}function k(C,ee){C._closedPromise=Promise.reject(ee),C._closedPromise_resolve=void 0,C._closedPromise_reject=void 0,C._closedPromiseState="rejected"}function V(C){C._closedPromise=Promise.resolve(void 0),C._closedPromise_resolve=void 0,C._closedPromise_reject=void 0,C._closedPromiseState="resolved"}function J(C,ee){C._closedPromise_reject(ee),C._closedPromise_resolve=void 0,C._closedPromise_reject=void 0,C._closedPromiseState="rejected"}function z(C,ee){C._closedPromise=Promise.reject(ee),C._closedPromiseState="rejected"}function Y(C){C._closedPromise_resolve(void 0),C._closedPromise_resolve=void 0,C._closedPromise_reject=void 0,C._closedPromiseState="resolved"}function re(C){Q("defaultWriterReadyPromiseInitialize()"),C._readyPromise=new Promise(function(ee,ye){C._readyPromise_resolve=ee,C._readyPromise_reject=ye}),C._readyPromiseState="pending"}function ce(C,ee){Q("defaultWriterReadyPromiseInitializeAsRejected(writer, %o)",ee),C._readyPromise=Promise.reject(ee),C._readyPromise_resolve=void 0,C._readyPromise_reject=void 0,C._readyPromiseState="rejected"}function Te(C){Q("defaultWriterReadyPromiseInitializeAsResolved()"),C._readyPromise=Promise.resolve(void 0),C._readyPromise_resolve=void 0,C._readyPromise_reject=void 0,C._readyPromiseState="fulfilled"}function xe(C,ee){Q("defaultWriterReadyPromiseReject(writer, %o)",ee),C._readyPromise_reject(ee),C._readyPromise_resolve=void 0,C._readyPromise_reject=void 0,C._readyPromiseState="rejected"}function Le(C){Q("defaultWriterReadyPromiseReset()"),C._readyPromise=new Promise(function(ee,ye){C._readyPromise_resolve=ee,C._readyPromise_reject=ye}),C._readyPromiseState="pending"}function qe(C,ee){Q("defaultWriterReadyPromiseResetToRejected(writer, %o)",ee),C._readyPromise=Promise.reject(ee),C._readyPromiseState="rejected"}function G(C){Q("defaultWriterReadyPromiseResolve()"),C._readyPromise_resolve(void 0),C._readyPromise_resolve=void 0,C._readyPromise_reject=void 0,C._readyPromiseState="fulfilled"}var F=function(){function C(ee,ye){for(var Pe=0;Pe0&&arguments[0]!==void 0?arguments[0]:{},ye=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Pe=ye.size,Ue=ye.highWaterMark,Fe=Ue===void 0?1:Ue;if(r(this,C),l(this),ee.type!==void 0)throw new RangeError("Invalid type is specified");var Ye=We(Pe);he(this,ee,Fe=Ne(Fe),Ye)}return F(C,[{key:"abort",value:function(ye){return c(this)===!1?Promise.reject(R("abort")):d(this)===!0?Promise.reject(new TypeError("Cannot abort a stream that already has a writer")):h(this,ye)}},{key:"getWriter",value:function(){if(c(this)===!1)throw R("getWriter");return a(this)}},{key:"locked",get:function(){if(c(this)===!1)throw R("locked");return d(this)}}]),C}();s.exports={AcquireWritableStreamDefaultWriter:a,CreateWritableStream:o,IsWritableStream:c,IsWritableStreamLocked:d,WritableStream:lt,WritableStreamAbort:h,WritableStreamDefaultControllerErrorIfNeeded:ge,WritableStreamDefaultWriterCloseWithErrorPropagation:U,WritableStreamDefaultWriterRelease:Z,WritableStreamDefaultWriterWrite:X,WritableStreamCloseQueuedOrInFlight:w};var ut=function(){function C(ee){if(r(this,C),c(ee)===!1)throw new TypeError("WritableStreamDefaultWriter can only be constructed with a WritableStream instance");if(d(ee)===!0)throw new TypeError("This stream has already been locked for exclusive writing by another writer");this._ownerWritableStream=ee,ee._writer=this;var ye=ee._state;if(ye==="writable")w(ee)===!1&&ee._backpressure===!0?re(this):Te(this),B(this);else if(ye==="erroring")ce(this,ee._storedError),this._readyPromise.catch(function(){}),B(this);else if(ye==="closed")Te(this),V(this);else{var Pe=ee._storedError;ce(this,Pe),this._readyPromise.catch(function(){}),k(this,Pe),this._closedPromise.catch(function(){})}}return F(C,[{key:"abort",value:function(ye){return E(this)===!1?Promise.reject(T("abort")):this._ownerWritableStream===void 0?Promise.reject(x("abort")):P(this,ye)}},{key:"close",value:function(){if(E(this)===!1)return Promise.reject(T("close"));var ye=this._ownerWritableStream;return ye===void 0?Promise.reject(x("close")):w(ye)===!0?Promise.reject(new TypeError("cannot close an already-closing stream")):M(this)}},{key:"releaseLock",value:function(){if(E(this)===!1)throw T("releaseLock");this._ownerWritableStream!==void 0&&Z(this)}},{key:"write",value:function(ye){return E(this)===!1?Promise.reject(T("write")):this._ownerWritableStream===void 0?Promise.reject(x("write to")):X(this,ye)}},{key:"closed",get:function(){return E(this)===!1?Promise.reject(T("closed")):this._closedPromise}},{key:"desiredSize",get:function(){if(E(this)===!1)throw T("desiredSize");if(this._ownerWritableStream===void 0)throw x("desiredSize");return $(this)}},{key:"ready",get:function(){return E(this)===!1?Promise.reject(T("ready")):this._readyPromise}}]),C}(),oe=function(){function C(){throw r(this,C),new TypeError("WritableStreamDefaultController cannot be constructed explicitly")}return F(C,[{key:"error",value:function(ye){if(le(this)===!1)throw new TypeError("WritableStreamDefaultController.prototype.error can only be used on a WritableStreamDefaultController");this._controlledWritableStream._state==="writable"&&N(this,ye)}},{key:Ge,value:function(ye){return this._abortAlgorithm(ye)}},{key:tt,value:function(){He(this)}}]),C}()},{"./helpers.js":10,"./queue-with-sizes.js":11,"./utils.js":14,"better-assert":16,debug:18}],16:[function(u,s,n){(function(r){function a(d){if(!d){var h=l(),f=h[1],p=f.getFileName(),y=f.getLineNumber(),b=(b=c.readFileSync(p,"utf8")).split(` +`)[y-1].match(/assert\((.*)\)/)[1];throw new o({message:b,stackStartFunction:h[0].getFunction()})}}var o=u("assert").AssertionError,l=u("callsite"),c=u("fs");s.exports={}.NO_ASSERT?function(){}:a}).call(this,u("_process"))},{_process:4,assert:2,callsite:17,fs:3}],17:[function(u,s,n){s.exports=function(){var r=Error.prepareStackTrace;Error.prepareStackTrace=function(l,c){return c};var a=new Error;Error.captureStackTrace(a,arguments.callee);var o=a.stack;return Error.prepareStackTrace=r,o}},{}],18:[function(u,s,n){(function(r){function a(){return!(typeof window>"u"||!window.process||window.process.type!=="renderer")||(typeof navigator>"u"||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&(typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function o(f){var p=this.useColors;if(f[0]=(p?"%c":"")+this.namespace+(p?" %c":" ")+f[0]+(p?"%c ":" ")+"+"+n.humanize(this.diff),p){var y="color: "+this.color;f.splice(1,0,y,"color: inherit");var b=0,g=0;f[0].replace(/%[a-zA-Z%]/g,function(m){m!=="%%"&&(b++,m==="%c"&&(g=b))}),f.splice(g,0,y)}}function l(){return typeof console=="object"&&console.log&&Function.prototype.apply.call(console.log,console,arguments)}function c(f){try{f==null?n.storage.removeItem("debug"):n.storage.debug=f}catch{}}function d(){var f;try{f=n.storage.debug}catch{}return!f&&typeof r<"u"&&"env"in r&&(f={}.DEBUG),f}function h(){try{return window.localStorage}catch{}}n=s.exports=u("./debug"),n.log=l,n.formatArgs=o,n.save=c,n.load=d,n.useColors=a,n.storage=typeof chrome<"u"&&chrome.storage!==void 0?chrome.storage.local:h(),n.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],n.formatters.j=function(f){try{return JSON.stringify(f)}catch(p){return"[UnexpectedJSONParseError]: "+p.message}},n.enable(d())}).call(this,u("_process"))},{"./debug":19,_process:4}],19:[function(u,s,n){function r(f){var p,y=0;for(p in f)y=(y<<5)-y+f.charCodeAt(p),y|=0;return n.colors[Math.abs(y)%n.colors.length]}function a(f){function p(){if(p.enabled){var b=p,g=+new Date,m=g-(y||g);b.diff=m,b.prev=y,b.curr=g,y=g;for(var v=new Array(arguments.length),_=0;_100)){var b=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(y);if(b){var g=parseFloat(b[1]);switch((b[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return g*p;case"days":case"day":case"d":return g*f;case"hours":case"hour":case"hrs":case"hr":case"h":return g*h;case"minutes":case"minute":case"mins":case"min":case"m":return g*d;case"seconds":case"second":case"secs":case"sec":case"s":return g*c;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return g;default:return}}}}function a(y){return y>=f?Math.round(y/f)+"d":y>=h?Math.round(y/h)+"h":y>=d?Math.round(y/d)+"m":y>=c?Math.round(y/c)+"s":y+"ms"}function o(y){return l(y,f,"day")||l(y,h,"hour")||l(y,d,"minute")||l(y,c,"second")||y+" ms"}function l(y,b,g){if(!(y0)return r(y);if(g==="number"&&isNaN(y)===!1)return b.long?o(y):a(y);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(y))}},{}]},{},[1])(1)})}(Pw)),Pw.exports}var Dw,r6;function R7(){if(r6)return Dw;r6=1;const t=e=>e!==null&&typeof e=="object"&&typeof e.pipe=="function";return t.writable=e=>t(e)&&e.writable!==!1&&typeof e._write=="function"&&typeof e._writableState=="object",t.readable=e=>t(e)&&e.readable!==!1&&typeof e._read=="function"&&typeof e._readableState=="object",t.duplex=e=>t.writable(e)&&t.readable(e),t.transform=e=>t.duplex(e)&&typeof e._transform=="function",Dw=t,Dw}var Nw={exports:{}},n6;function yK(){return n6||(n6=1,function(t){t.exports=e,t.exports.WEBSTREAM_SUPPORT=typeof ReadableStream<"u";function e(u){if(!t.exports.WEBSTREAM_SUPPORT)throw new Error("No web ReadableStream support");var s=!1,n={};function r(l){n.data=d,n.end=d,n.end=h,n.close=h,n.error=h;for(var c in n)u.on(c,n[c]);u.pause();function d(f){s||(l.enqueue(f),u.pause())}function h(f){if(!s){s=!0;for(var p in n)u.removeListener(p,n[p]);f?l.error(f):l.close()}}}function a(){s||u.resume()}function o(){s=!0;for(var l in n)u.removeListener(l,n[l]);u.push(null),u.pause(),u.destroy?u.destroy():u.close&&u.close()}return new ReadableStream({start:r,pull:a,cancel:o})}}(Nw)),Nw.exports}var i6;function x7(){if(i6)return Od;i6=1,Object.defineProperty(Od,"__esModule",{value:!0}),Od.ActorHttp=void 0;const t=ot,e=hK();globalThis.ReadableStream||(globalThis.ReadableStream=pK().ReadableStream);const u=R7(),s=yK();let n=class extends t.Actor{constructor(a){super(a)}static toNodeReadable(a){return u(a)||a===null?a:(0,e.readableFromWeb)(a)}static toWebReadableStream(a){return s(a)}static headersToHash(a){const o={};return a.forEach((l,c)=>{o[c]=l}),o}};return Od.ActorHttp=n,Od}var Rd={},a6;function bK(){if(a6)return Rd;a6=1,Object.defineProperty(Rd,"__esModule",{value:!0}),Rd.validateAndCloseHttpResponse=void 0;const t=ou(),e=x7();async function u(s,n){var r;if(n.status>=400){let a="empty response";if(n.body){const o=e.ActorHttp.toNodeReadable(n.body);a=await(0,t.stringify)(o)}throw new Error(`Could not update ${s} (HTTP status ${n.status}): +${a}`)}await((r=n.body)==null?void 0:r.cancel())}return Rd.validateAndCloseHttpResponse=u,Rd}var s6;function as(){return s6||(s6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(x7(),t),u(bK(),t)}(xw)),xw}var o6={},u6;function I7(){return u6||(u6=1,function(t){(function(e){var u=typeof globalThis<"u"&&globalThis||typeof t<"u"&&t||typeof u<"u"&&u,s={searchParams:"URLSearchParams"in u,iterable:"Symbol"in u&&"iterator"in Symbol,blob:"FileReader"in u&&"Blob"in u&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in u,arrayBuffer:"ArrayBuffer"in u};function n(E){return E&&DataView.prototype.isPrototypeOf(E)}if(s.arrayBuffer)var r=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],a=ArrayBuffer.isView||function(E){return E&&r.indexOf(Object.prototype.toString.call(E))>-1};function o(E){if(typeof E!="string"&&(E=String(E)),/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(E)||E==="")throw new TypeError('Invalid character in header field name: "'+E+'"');return E.toLowerCase()}function l(E){return typeof E!="string"&&(E=String(E)),E}function c(E){var P={next:function(){var M=E.shift();return{done:M===void 0,value:M}}};return s.iterable&&(P[Symbol.iterator]=function(){return P}),P}function d(E){this.map={},E instanceof d?E.forEach(function(P,M){this.append(M,P)},this):Array.isArray(E)?E.forEach(function(P){this.append(P[0],P[1])},this):E&&Object.getOwnPropertyNames(E).forEach(function(P){this.append(P,E[P])},this)}d.prototype.append=function(E,P){E=o(E),P=l(P);var M=this.map[E];this.map[E]=M?M+", "+P:P},d.prototype.delete=function(E){delete this.map[o(E)]},d.prototype.get=function(E){return E=o(E),this.has(E)?this.map[E]:null},d.prototype.has=function(E){return this.map.hasOwnProperty(o(E))},d.prototype.set=function(E,P){this.map[o(E)]=l(P)},d.prototype.forEach=function(E,P){for(var M in this.map)this.map.hasOwnProperty(M)&&E.call(P,this.map[M],M,this)},d.prototype.keys=function(){var E=[];return this.forEach(function(P,M){E.push(M)}),c(E)},d.prototype.values=function(){var E=[];return this.forEach(function(P){E.push(P)}),c(E)},d.prototype.entries=function(){var E=[];return this.forEach(function(P,M){E.push([M,P])}),c(E)},s.iterable&&(d.prototype[Symbol.iterator]=d.prototype.entries);function h(E){if(E.bodyUsed)return Promise.reject(new TypeError("Already read"));E.bodyUsed=!0}function f(E){return new Promise(function(P,M){E.onload=function(){P(E.result)},E.onerror=function(){M(E.error)}})}function p(E){var P=new FileReader,M=f(P);return P.readAsArrayBuffer(E),M}function y(E){var P=new FileReader,M=f(P);return P.readAsText(E),M}function b(E){for(var P=new Uint8Array(E),M=new Array(P.length),U=0;U-1?P:E}function w(E,P){if(!(this instanceof w))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');P=P||{};var M=P.body;if(E instanceof w){if(E.bodyUsed)throw new TypeError("Already read");this.url=E.url,this.credentials=E.credentials,P.headers||(this.headers=new d(E.headers)),this.method=E.method,this.mode=E.mode,this.signal=E.signal,!M&&E._bodyInit!=null&&(M=E._bodyInit,E.bodyUsed=!0)}else this.url=String(E);if(this.credentials=P.credentials||this.credentials||"same-origin",(P.headers||!this.headers)&&(this.headers=new d(P.headers)),this.method=_(P.method||this.method||"GET"),this.mode=P.mode||this.mode||null,this.signal=P.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&M)throw new TypeError("Body not allowed for GET or HEAD requests");if(this._initBody(M),(this.method==="GET"||this.method==="HEAD")&&(P.cache==="no-store"||P.cache==="no-cache")){var U=/([?&])_=[^&]*/;if(U.test(this.url))this.url=this.url.replace(U,"$1_="+new Date().getTime());else{var j=/\?/;this.url+=(j.test(this.url)?"&":"?")+"_="+new Date().getTime()}}}w.prototype.clone=function(){return new w(this,{body:this._bodyInit})};function S(E){var P=new FormData;return E.trim().split("&").forEach(function(M){if(M){var U=M.split("="),j=U.shift().replace(/\+/g," "),q=U.join("=").replace(/\+/g," ");P.append(decodeURIComponent(j),decodeURIComponent(q))}}),P}function A(E){var P=new d,M=E.replace(/\r?\n[\t ]+/g," ");return M.split("\r").map(function(U){return U.indexOf(` +`)===0?U.substr(1,U.length):U}).forEach(function(U){var j=U.split(":"),q=j.shift().trim();if(q){var $=j.join(":").trim();P.append(q,$)}}),P}m.call(w.prototype);function D(E,P){if(!(this instanceof D))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');P||(P={}),this.type="default",this.status=P.status===void 0?200:P.status,this.ok=this.status>=200&&this.status<300,this.statusText=P.statusText===void 0?"":""+P.statusText,this.headers=new d(P.headers),this.url=P.url||"",this._initBody(E)}m.call(D.prototype),D.prototype.clone=function(){return new D(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new d(this.headers),url:this.url})},D.error=function(){var E=new D(null,{status:0,statusText:""});return E.type="error",E};var L=[301,302,303,307,308];D.redirect=function(E,P){if(L.indexOf(P)===-1)throw new RangeError("Invalid status code");return new D(null,{status:P,headers:{location:E}})},e.DOMException=u.DOMException;try{new e.DOMException}catch{e.DOMException=function(P,M){this.message=P,this.name=M;var U=Error(P);this.stack=U.stack},e.DOMException.prototype=Object.create(Error.prototype),e.DOMException.prototype.constructor=e.DOMException}function O(E,P){return new Promise(function(M,U){var j=new w(E,P);if(j.signal&&j.signal.aborted)return U(new e.DOMException("Aborted","AbortError"));var q=new XMLHttpRequest;function $(){q.abort()}q.onload=function(){var X={status:q.status,statusText:q.statusText,headers:A(q.getAllResponseHeaders()||"")};X.url="responseURL"in q?q.responseURL:X.headers.get("X-Request-URL");var le="response"in q?q.response:q.responseText;setTimeout(function(){M(new D(le,X))},0)},q.onerror=function(){setTimeout(function(){U(new TypeError("Network request failed"))},0)},q.ontimeout=function(){setTimeout(function(){U(new TypeError("Network request failed"))},0)},q.onabort=function(){setTimeout(function(){U(new e.DOMException("Aborted","AbortError"))},0)};function Z(X){try{return X===""&&u.location.href?u.location.href:X}catch{return X}}q.open(j.method,Z(j.url),!0),j.credentials==="include"?q.withCredentials=!0:j.credentials==="omit"&&(q.withCredentials=!1),"responseType"in q&&(s.blob?q.responseType="blob":s.arrayBuffer&&j.headers.get("Content-Type")&&j.headers.get("Content-Type").indexOf("application/octet-stream")!==-1&&(q.responseType="arraybuffer")),P&&typeof P.headers=="object"&&!(P.headers instanceof d)?Object.getOwnPropertyNames(P.headers).forEach(function(X){q.setRequestHeader(X,l(P.headers[X]))}):j.headers.forEach(function(X,le){q.setRequestHeader(le,X)}),j.signal&&(j.signal.addEventListener("abort",$),q.onreadystatechange=function(){q.readyState===4&&j.signal.removeEventListener("abort",$)}),q.send(typeof j._bodyInit>"u"?null:j._bodyInit)})}return O.polyfill=!0,u.fetch||(u.fetch=O,u.Headers=d,u.Request=w,u.Response=D),e.Headers=d,e.Request=w,e.Response=D,e.fetch=O,e})({})}(typeof self<"u"?self:I)),o6}var xd={},c6;function mK(){if(c6)return xd;c6=1,Object.defineProperty(xd,"__esModule",{value:!0}),xd.FetchInitPreprocessor=void 0;const t=as();class e{async handle(s){if(s.headers){const n=new Headers(s.headers);n.has("user-agent")&&n.delete("user-agent"),s.headers=n}if(s!=null&&s.headers&&"append"in s.headers&&(s.headers=t.ActorHttp.headersToHash(s.headers)),s.body&&typeof s.body!="string"&&"getReader"in s.body){const n=s.body.getReader(),r=[];for(;;){const{done:a,value:o}=await n.read();if(a)break;r.push(o)}s.body=r.join("")}return{keepalive:!s.body,...s}}async createAbortController(){return new AbortController}}return xd.FetchInitPreprocessor=e,xd}var l6;function gK(){if(l6)return Ed;l6=1,Object.defineProperty(Ed,"__esModule",{value:!0}),Ed.ActorHttpFetch=void 0;const t=as(),e=Lt;I7();const u=mK();let s=class S3 extends t.ActorHttp{constructor(r){super(r),this.userAgent=S3.createUserAgent(),this.fetchInitPreprocessor=new u.FetchInitPreprocessor(r.agentOptions)}static createUserAgent(){return`Comunica/actor-http-fetch (${typeof globalThis.navigator>"u"?`Node.js ${process.version}; ${process.platform}`:`Browser-${globalThis.navigator.userAgent}`})`}async test(r){return{time:Number.POSITIVE_INFINITY}}static async getResponse(r,a,o,l,c,d){var p;let h,f=l+1;for(;f-- >0;)try{const y=await r(a,o);if(d&&y.status>=500&&y.status<600)throw new Error(`Server replied with response code ${y.status}: ${y.statusText}`);return y}catch(y){if(h=y,(p=o.signal)!=null&&p.aborted)throw y;f>0&&await new Promise((b,g)=>{var m;setTimeout(b,c),(m=o.signal)==null||m.addEventListener("abort",()=>{g(new Error("Fetch aborted by timeout."))})})}throw l>0?new Error(`Number of fetch retries (${l}) exceeded. Last error: ${String(h)}`):h}async run(r){var f,p,y,b,g,m,v,_;const a=((f=r.init)==null?void 0:f.headers)??{};r.init=r.init??{},r.init.headers=new Headers(a),r.init.headers.has("user-agent")||r.init.headers.append("user-agent",this.userAgent);const o=r.context.get(e.KeysHttp.auth);o&&r.init.headers.append("Authorization",`Basic ${Buffer.from(o).toString("base64")}`),this.logInfo(r.context,`Requesting ${typeof r.input=="string"?r.input:r.input.url}`,()=>({headers:t.ActorHttp.headersToHash(new Headers(r.init.headers)),method:r.init.method??"GET"})),(p=r.init)!=null&&p.headers&&"append"in r.init.headers&&r.context.has(e.KeysHttp.fetch)&&(r.init.headers=t.ActorHttp.headersToHash(r.init.headers));let l={...r.init};r.context.get(e.KeysHttp.includeCredentials)&&(l.credentials="include");const c=(y=r.context)==null?void 0:y.get(e.KeysHttp.httpTimeout);let d,h;if(c!==void 0){const w=await this.fetchInitPreprocessor.createAbortController();l.signal=w.signal,h=()=>w.abort(),d=setTimeout(()=>h(),c)}try{l=await this.fetchInitPreprocessor.handle(l);const w=((b=r.context)==null?void 0:b.get(e.KeysHttp.httpRetryCount))??0,S=((g=r.context)==null?void 0:g.get(e.KeysHttp.httpRetryDelay))??0,A=((m=r.context)==null?void 0:m.get(e.KeysHttp.httpRetryOnServerError))??!1,D=(v=r.context)==null?void 0:v.get(e.KeysHttp.fetch),L=await S3.getResponse(D??fetch,r.input,l,w,S,A);return d!==void 0&&((((_=r.context)==null?void 0:_.get(e.KeysHttp.httpBodyTimeout))||!1)&&L.body?(h=()=>{var E;return(E=L.body)==null?void 0:E.cancel(new Error(`HTTP timeout when reading the body of ${L.url}. +This error can be disabled by modifying the 'httpBodyTimeout' and/or 'httpTimeout' options.`))},L.body.on("close",()=>{clearTimeout(d)})):clearTimeout(d)),L.body&&!L.body.cancel&&(L.body.cancel=async O=>{L.body.destroy(O),d!==void 0&&clearTimeout(d)}),L}catch(w){throw d!==void 0&&clearTimeout(d),w}}};return Ed.ActorHttpFetch=s,Ed}var d6;function _K(){return d6||(d6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(gK(),t)}(Rw)),Rw}var Cw={},Id={},f6;function vK(){if(f6)return Id;f6=1,Object.defineProperty(Id,"__esModule",{value:!0}),Id.ActorQueryOperationSource=void 0;const t=wt(),e=Lt,u=Cn(),s=Ot();let n=class extends t.ActorQueryOperation{constructor(a){super(a)}async test(a){if(!t.ActorQueryOperation.getOperationSource(a.operation))throw new Error(`Actor ${this.name} requires an operation with source annotation.`);return{httpRequests:1}}async run(a){const o=a.context.get(e.KeysInitQuery.physicalQueryPlanLogger);o&&(o.logOperation(a.operation.type,void 0,a.operation,a.context.get(e.KeysInitQuery.physicalQueryPlanNode),this.name,{}),a.context=a.context.set(e.KeysInitQuery.physicalQueryPlanNode,a.operation));const l=t.ActorQueryOperation.getOperationSource(a.operation),c=l.context?a.context.merge(l.context):a.context;let d=!1;if(s.Util.recurseOperation(a.operation,{construct(){return d=!0,!1}}),d){const p=l.source.queryQuads(a.operation,c),y=(0,u.getMetadataQuads)(p);return{type:"quads",quadStream:p,metadata:y}}switch(a.operation.type){case s.Algebra.types.ASK:return{type:"boolean",execute:()=>l.source.queryBoolean(a.operation,c)};case s.Algebra.types.COMPOSITE_UPDATE:case s.Algebra.types.DELETE_INSERT:case s.Algebra.types.LOAD:case s.Algebra.types.CLEAR:case s.Algebra.types.CREATE:case s.Algebra.types.DROP:case s.Algebra.types.ADD:case s.Algebra.types.MOVE:case s.Algebra.types.COPY:return{type:"void",execute:()=>l.source.queryVoid(a.operation,c)}}const h=l.source.queryBindings(a.operation,c),f=(0,u.getMetadataBindings)(h);return{type:"bindings",bindingsStream:h,metadata:f}}};return Id.ActorQueryOperationSource=n,Id}var h6;function wK(){return h6||(h6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(vK(),t)}(Cw)),Cw}var jw={},Pd={},p6;function SK(){if(p6)return Pd;p6=1,Object.defineProperty(Pd,"__esModule",{value:!0}),Pd.MediatorJoinCoefficientsFixed=void 0;const t=Lt,e=ot;let u=class extends e.Mediator{constructor(n){super(n)}async mediateWith(n,r){var b;const a=[],o=r.map(({reply:g})=>g).map(g=>g.catch(m=>{a.push(m)})),l=await Promise.all(o);let c=l.map(g=>{if(g)return g.iterations*this.cpuWeight+g.persistedItems*this.memoryWeight+g.blockingItems*this.timeWeight+g.requestTime*this.ioWeight});const d=Math.max(...c.filter(g=>g!==void 0)),h=n.context.get(t.KeysQueryOperation.limitIndicator);h&&(c=c.map((g,m)=>g!==void 0&&l[m].blockingItems>0&&l[m].iterations>h?g+d:g));let f=-1,p=Number.POSITIVE_INFINITY;for(const[g,m]of c.entries())m!==void 0&&(f===-1||mg.message).join(` +`)}`);const y=r[f].actor;return y.includeInLogs&&((b=e.Actor.getContextLogger(n.context))==null||b.debug(`Determined physical join operator '${y.logicalType}-${y.physicalName}'`,{entries:n.entries.length,variables:await Promise.all(n.entries.map(async g=>(await g.output.metadata()).variables.map(m=>m.value))),costs:Object.fromEntries(c.map((g,m)=>[`${r[m].actor.logicalType}-${r[m].actor.physicalName}`,g]).filter(g=>g[1]!==void 0)),coefficients:Object.fromEntries(l.map((g,m)=>[`${r[m].actor.logicalType}-${r[m].actor.physicalName}`,g]).filter(g=>g[1]!==void 0))})),y}};return Pd.MediatorJoinCoefficientsFixed=u,Pd}var y6;function TK(){return y6||(y6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(SK(),t)}(jw)),jw}var Lw={},Dd={},b6;function P7(){if(b6)return Dd;b6=1,Object.defineProperty(Dd,"__esModule",{value:!0}),Dd.ActorHttpInvalidate=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return Dd.ActorHttpInvalidate=e,Dd}var Nd={},m6;function AK(){if(m6)return Nd;m6=1,Object.defineProperty(Nd,"__esModule",{value:!0}),Nd.ActorHttpInvalidateListenable=void 0;const t=P7();let e=class extends t.ActorHttpInvalidate{constructor(s){super(s),this.invalidateListeners=[],this.invalidateListeners=[]}addInvalidateListener(s){this.invalidateListeners.push(s)}async test(s){return!0}async run(s){for(const n of this.invalidateListeners)n(s);return{}}};return Nd.ActorHttpInvalidateListenable=e,Nd}var g6;function N1(){return g6||(g6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(P7(),t),u(AK(),t)}(Lw)),Lw}var Mw={},Cd={},_6;function EK(){if(_6)return Cd;_6=1,Object.defineProperty(Cd,"__esModule",{value:!0}),Cd.MediatorAll=void 0;const t=ot;let e=class extends t.Mediator{constructor(s){super(s)}async mediate(s){const n=[];let r;try{r=this.publish(s)}catch{r=[]}for(const o of r)try{await o.reply,n.push(o.actor)}catch{}return(await Promise.all(n.map(o=>o.runObservable(s))))[0]}async mediateWith(){throw new Error("Unsupported operation: MediatorAll#mediateWith")}};return Cd.MediatorAll=e,Cd}var v6;function OK(){return v6||(v6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(EK(),t)}(Mw)),Mw}var Fw={},jd={},qw={},Ld={},Md={},w6;function RK(){if(w6)return Md;w6=1,Object.defineProperty(Md,"__esModule",{value:!0}),Md.instrumentIterator=void 0;function t(u){const s={count:0,timeSelf:0,timeLife:0};return e(u,s,!0),new Promise(n=>{u.on("end",()=>{n(s)})})}Md.instrumentIterator=t;function e(u,s,n){if(!("_profileInstrumented"in u)){if(u._profileInstrumented=!0,"_read"in u){const r=u._read;u._read=(a,o)=>{const l=performance.now();r.call(u,a,()=>{s.timeSelf+=performance.now()-l,o()})}}if("read"in u){const r=u.read;u.read=()=>{const a=performance.now(),o=r.call(u);return n&&o&&s.count++,s.timeSelf+=performance.now()-a,o}}if(n){const r=performance.now();u.on("end",()=>{s.timeLife=performance.now()-r})}"_source"in u&&e(u._source,s,!1)}}return Md}var S6;function xK(){if(S6)return Ld;S6=1,Object.defineProperty(Ld,"__esModule",{value:!0}),Ld.ActorRdfJoin=void 0;const t=Lt,e=ot,u=Cn(),s=Et(),n=Xt(),r=RK(),a=new s.DataFactory;let o=class Da extends e.Actor{constructor(c,d){super(c),this.includeInLogs=!0,this.logicalType=d.logicalType,this.physicalName=d.physicalName,this.limitEntries=d.limitEntries??Number.POSITIVE_INFINITY,this.limitEntriesMin=d.limitEntriesMin??!1,this.canHandleUndefs=d.canHandleUndefs??!1,this.isLeaf=d.isLeaf??!0,this.requiresVariableOverlap=d.requiresVariableOverlap??!1}static hash(c,d){return d.map(h=>{const f=c.get(h);return f?f.value:""}).join("")}static hashNonClashing(c,d){return d.map(h=>{const f=c.get(h);return f?(0,n.termToString)(f):""}).join("")}static overlappingVariables(c){const d=c.map(f=>f.variables);let h=d[0];for(const f of d.slice(1))h=h.filter(p=>f.some(y=>y.value===p.value));return h}static joinVariables(c){return[...new Set(c.flatMap(d=>d.variables.map(h=>h.value)))].map(d=>a.variable(d))}static joinBindings(...c){if(c.length===0)return null;if(c.length===1)return c[0];let d=c[0];for(const h of c.slice(1)){const f=d.merge(h);if(!f)return null;d=f}return d}static getCardinality(c){return c.cardinality}static async getMetadatas(c){return await Promise.all(c.map(d=>d.output.metadata()))}static async getEntriesWithMetadatas(c){const d=await Da.getMetadatas(c);return c.map((h,f)=>({...h,metadata:d[f]}))}static getRequestInitialTimes(c){return c.map(d=>d.pageSize?0:d.requestTime??0)}static getRequestItemTimes(c){return c.map(d=>d.pageSize?(d.requestTime??0)/d.pageSize:0)}constructState(c){const d=new u.MetadataValidationState,h=()=>d.invalidate();for(const f of c)f.state.addInvalidateListener(h);return d}async constructResultMetadata(c,d,h,f={},p=!1){let y;return f.cardinality?y=f.cardinality:(y=d.reduce((b,g)=>{const m=Da.getCardinality(g);return{type:m.type==="estimate"?"estimate":b.type,value:b.value*(p?Math.max(1,m.value):m.value)}},{type:"exact",value:1}),y.value*=(await this.mediatorJoinSelectivity.mediate({entries:c,context:h})).selectivity),{state:this.constructState(d),...f,cardinality:{type:y.type,value:y.value},canContainUndefs:f.canContainUndefs??d.some(b=>b.canContainUndefs),variables:Da.joinVariables(d)}}static async sortJoinEntries(c,d,h){if(d.some(g=>g.metadata.canContainUndefs))return d;const p={};for(const g of d)for(const m of g.metadata.variables){let v=p[m.value];v||(v=0),p[m.value]=++v}const y=[];for(const[g,m]of Object.entries(p))m>=2&&y.push(g);if(y.length===0)throw new Error("Bind join can only join entries with at least one common variable");const b=[];for(const g of d){let m=!1;for(const v of g.metadata.variables)if(y.includes(v.value)){m=!0;break}m||b.push(g)}return(await c.mediate({entries:d,context:h})).entries.sort((g,m)=>{const v=b.includes(g),_=b.includes(m);return v===_?0:v?1:-1})}async test(c){if(c.type!==this.logicalType)throw new Error(`${this.name} can only handle logical joins of type '${this.logicalType}', while '${c.type}' was given.`);if(c.entries.length<=1)throw new Error(`${this.name} requires at least two join entries.`);if(this.limitEntriesMin?c.entries.lengththis.limitEntries)throw new Error(`${this.name} requires ${this.limitEntries} join entries at ${this.limitEntriesMin?"least":"most"}. The input contained ${c.entries.length}.`);for(const h of c.entries)if(h.output.type!=="bindings")throw new Error(`Invalid type of a join entry: Expected 'bindings' but got '${h.output.type}'`);const d=await Da.getMetadatas(c.entries);if(!this.canHandleUndefs){for(const h of d)if(h.canContainUndefs)throw new Error(`Actor ${this.name} can not join streams containing undefs`)}if(this.requiresVariableOverlap&&Da.overlappingVariables(d).length===0)throw new Error(`Actor ${this.name} can only join entries with at least one common variable`);return await this.getJoinCoefficients(c,d)}async run(c){let d;c.context.has(t.KeysInitQuery.physicalQueryPlanLogger)&&(d=c.context.get(t.KeysInitQuery.physicalQueryPlanNode),c.context=c.context.set(t.KeysInitQuery.physicalQueryPlanNode,c));const h=c.context.get(t.KeysInitQuery.physicalQueryPlanLogger);let f;this.includeInLogs&&h&&(f={},h.stashChildren(d,g=>g.logicalOperator.startsWith("join")),h.logOperation(`join-${this.logicalType}`,this.physicalName,c,d,this.name,f));const{result:p,physicalPlanMetadata:y}=await this.getOutput(c),b=await Da.getMetadatas(c.entries);if(f){(0,r.instrumentIterator)(p.bindingsStream).then(m=>{h.appendMetadata(c,{cardinalityReal:m.count,timeSelf:m.timeSelf,timeLife:m.timeLife})}),Object.assign(f,y);const g=b.map(Da.getCardinality);if(f.cardinalities=g,f.joinCoefficients=await this.getJoinCoefficients(c,b),this.isLeaf)for(let m=0;m=this.blockSize&&r(this.consumeChunkAsIterator()),n()}_flush(s){this.chunk.length>0&&this._push(this.consumeChunkAsIterator()),super._flush(s)}};return Fd.ChunkedIterator=e,Fd}var A6;function jn(){return A6||(A6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(xK(),t),u(IK(),t)}(qw)),qw}var E6;function PK(){if(E6)return jd;E6=1,Object.defineProperty(jd,"__esModule",{value:!0}),jd.ActorRdfJoinSingle=void 0;const t=jn();let e=class extends t.ActorRdfJoin{constructor(s){super(s,{logicalType:"inner",physicalName:"single",limitEntries:1}),this.includeInLogs=!1}async test(s){if(s.entries.length!==1)throw new Error(`Actor ${this.name} can only join a single entry`);return await this.getJoinCoefficients()}async getOutput(s){return{result:s.entries[0].output}}async getJoinCoefficients(){return{iterations:0,persistedItems:0,blockingItems:0,requestTime:0}}};return jd.ActorRdfJoinSingle=e,jd}var O6;function DK(){return O6||(O6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(PK(),t)}(Fw)),Fw}var Bw={},qd={},R6;function NK(){if(R6)return qd;R6=1,Object.defineProperty(qd,"__esModule",{value:!0}),qd.ActorRdfJoinMultiEmpty=void 0;const t=jn(),e=Cn(),u=Dt();let s=class extends t.ActorRdfJoin{constructor(r){super(r,{logicalType:"inner",physicalName:"multi-empty",canHandleUndefs:!0})}async test(r){if((await t.ActorRdfJoin.getMetadatas(r.entries)).every(a=>t.ActorRdfJoin.getCardinality(a).value>0))throw new Error(`Actor ${this.name} can only join entries where at least one is empty`);return super.test(r)}async getOutput(r){for(const a of r.entries)a.output.bindingsStream.close();return{result:{bindingsStream:new u.ArrayIterator([],{autoStart:!1}),metadata:async()=>({state:new e.MetadataValidationState,cardinality:{type:"exact",value:0},canContainUndefs:!1,variables:t.ActorRdfJoin.joinVariables(await t.ActorRdfJoin.getMetadatas(r.entries))}),type:"bindings"}}}async getJoinCoefficients(r,a){return{iterations:0,persistedItems:0,blockingItems:0,requestTime:0}}};return qd.ActorRdfJoinMultiEmpty=s,qd}var x6;function CK(){return x6||(x6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(NK(),t)}(Bw)),Bw}var Uw={},Bd={},I6;function jK(){if(I6)return Bd;I6=1,Object.defineProperty(Bd,"__esModule",{value:!0}),Bd.ActorRdfJoinMultiBindSource=void 0;const t=wt(),e=jn(),u=Dt(),s=Ot(),n=new s.Factory;let r=class extends e.ActorRdfJoin{constructor(o){super(o,{logicalType:"inner",physicalName:"bind-source",canHandleUndefs:!0})}async getOutput(o){const l=await e.ActorRdfJoin.getEntriesWithMetadatas(o.entries),c=await this.sortJoinEntries(l,o.context);this.logDebug(o.context,"First entry for Bind Join Source: ",()=>({entry:c[0].operation,metadata:c[0].metadata}));for(const[m,v]of c.entries())m!==0&&v.output.bindingsStream.close();const d=c[0].output,h=c[0].metadata,f=[...c];f.splice(0,1);const p=t.ActorQueryOperation.getOperationSource(f[0].operation),y=this.createOperationFromEntries(f),b=new e.ChunkedIterator(d.bindingsStream,this.blockSize,{autoStart:!1});return{result:{type:"bindings",bindingsStream:new u.UnionIterator(b.map(m=>p.source.queryBindings(y,p.context?o.context.merge(p.context):o.context,{joinBindings:{bindings:m,metadata:h}}))),metadata:()=>this.constructResultMetadata(c,c.map(m=>m.metadata),o.context)},physicalPlanMetadata:{bindIndex:l.indexOf(c[0])}}}async sortJoinEntries(o,l){return o=await e.ActorRdfJoin.sortJoinEntries(this.mediatorJoinEntriesSort,o,l),o=o.sort((c,d)=>c.operationModified&&!d.operationModified?-1:0),o}async getJoinCoefficients(o,l){const c=await this.sortJoinEntries(o.entries.map((_,w)=>({..._,metadata:l[w]})),o.context);l=c.map(_=>_.metadata);const d=e.ActorRdfJoin.getRequestInitialTimes(l),h=e.ActorRdfJoin.getRequestItemTimes(l),f=[...c];[...d],[...h],f.splice(0,1);const p=f.map(_=>t.ActorQueryOperation.getOperationSource(_.operation));if(p.some(_=>!_))throw new Error(`Actor ${this.name} can not bind on remaining operations without source annotation`);if(p.some(_=>_!==p[0]))throw new Error(`Actor ${this.name} can not bind on remaining operations with non-equal source annotation`);const y=p[0],b=this.createOperationFromEntries(f),g=await y.source.getSelectorShape(o.context);if(!t.ActorQueryOperation.doesShapeAcceptOperation(g,b,{joinBindings:!0}))throw new Error(`Actor ${this.name} detected a source that can not handle passing down join bindings`);const m=await Promise.all(f.map(async _=>(await this.mediatorJoinSelectivity.mediate({entries:[c[0],_],context:o.context})).selectivity*this.selectivityModifier)),v=f.map((_,w)=>_.metadata.cardinality.value*m[w]).reduce((_,w)=>_+w,0);return{iterations:1,persistedItems:l[0].cardinality.value,blockingItems:l[0].cardinality.value,requestTime:d[0]+l[0].cardinality.value*h[0]+d[1]+v*h[1]}}createOperationFromEntries(o){return o.length===1?o[0].operation:n.createJoin(o.map(l=>l.operation),!0)}};return Bd.ActorRdfJoinMultiBindSource=r,Bd}var P6;function LK(){return P6||(P6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(jK(),t)}(Uw)),Uw}var Qw={},Ud={},Hw,D6;function MK(){if(D6)return Hw;D6=1;let t=Dt(),e=t.MultiTransformIterator,u=t.SimpleTransformIterator;class s extends e{constructor(r,a,o,l){super(r,l),this.funRight=a,this.funJoin=o}_createTransformer(r){return new u(this.funRight(r),{transform:(a,o,l)=>{let c=this.funJoin(r,a);c!==null&&l(c),o()}})}}return Hw=s,Hw}var $w,N6;function FK(){if(N6)return $w;N6=1;let t=Dt().AsyncIterator;class e extends t{constructor(s,n,r,a){super(),this.addedDataListener=!1,this.left=s,this.right=n,this.funHash=r,this.funJoin=a,this.leftMap=new Map,this.match=null,this.matches=[],this.matchIdx=0,this.left.on("error",l=>this.destroy(l)),this.right.on("error",l=>this.destroy(l)),this.readable=!1,this.left.on("end",o.bind(this));function o(){this.readable=!0,this.right.on("readable",()=>this.readable=!0),this.right.on("end",()=>{this.hasResults()||this._end()})}this.on("newListener",l=>{l==="data"&&this._addDataListenerIfNeeded()}),this.left.readable&&this._addDataListenerIfNeeded(),this.left.on("readable",()=>this._addDataListenerIfNeeded())}hasResults(){return!this.right.ended||this.matchIdxthis.right.close())}_end(){super._end(),u(()=>this.right.destroy())}_createTransformer(r){return new e(this.right.clone(),{transform:(a,o,l)=>{let c=this.funJoin(r,a);c!==null&&l(c),o()}})}}return Vw=s,Vw}var kw,j6;function BK(){if(j6)return kw;j6=1;let t=Dt().AsyncIterator;class e extends t{constructor(s,n,r,a){super(),this.left=s,this.right=n,this.funHash=r,this.funJoin=a,this.usedLeft=!1,this.leftMap=new Map,this.rightMap=new Map,this.on("end",()=>this._cleanup()),this.match=null,this.matches=[],this.matchIdx=0,(this.left.readable||this.right.readable)&&(this.readable=!0),this.left.on("error",o=>this.destroy(o)),this.right.on("error",o=>this.destroy(o)),this.left.on("readable",()=>this.readable=!0),this.right.on("readable",()=>this.readable=!0),this.left.on("end",()=>{this.hasResults()||this._end()}),this.right.on("end",()=>{this.hasResults()||this._end()})}hasResults(){return!this.left.ended||!this.right.ended||!!this.matches&&this.matchIdxthis.emit("readable")),n.on("end",()=>this._removeStream(n));this.streams.length===0&&this.close(),this.idx=this.streams.length-1}_removeStream(s){let n=this.streams.indexOf(s);n<0||(this.streams.splice(n,1),this.idx>=this.streams.length&&--this.idx,this.streams.length===0&&this._end())}close(){super.close();for(let s of this.streams)s.close()}read(){for(let s=0;st.ActorRdfJoin.hash(l,a),t.ActorRdfJoin.joinBindings),metadata:async()=>await this.constructResultMetadata(n.entries,r,n.context)}}}async getJoinCoefficients(n,r){r[1].cardinality.valueD7.hash(l,a),t.ActorRdfJoin.joinBindings),metadata:async()=>await this.constructResultMetadata(n.entries,r,n.context)}}}async getJoinCoefficients(n,r){const a=t.ActorRdfJoin.getRequestInitialTimes(r),o=t.ActorRdfJoin.getRequestItemTimes(r);return{iterations:r[0].cardinality.value+r[1].cardinality.value,persistedItems:r[0].cardinality.value+r[1].cardinality.value,blockingItems:0,requestTime:a[0]+r[0].cardinality.value*o[0]+a[1]+r[1].cardinality.value*o[1]}}};return Qd.ActorRdfJoinSymmetricHash=u,Qd}var U6;function VK(){return U6||(U6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u($K(),t)}(Ww)),Ww}var Jw={},Hd={},Q6;function kK(){if(Q6)return Hd;Q6=1,Object.defineProperty(Hd,"__esModule",{value:!0}),Hd.ActorRdfJoinNestedLoop=void 0;const t=jn(),e=nm();let u=class extends t.ActorRdfJoin{constructor(n){super(n,{logicalType:"inner",physicalName:"nested-loop",limitEntries:2,canHandleUndefs:!0})}async getOutput(n){return{result:{type:"bindings",bindingsStream:new e.NestedLoopJoin(n.entries[0].output.bindingsStream,n.entries[1].output.bindingsStream,t.ActorRdfJoin.joinBindings,{autoStart:!1}),metadata:async()=>await this.constructResultMetadata(n.entries,await t.ActorRdfJoin.getMetadatas(n.entries),n.context)}}}async getJoinCoefficients(n,r){const a=t.ActorRdfJoin.getRequestInitialTimes(r),o=t.ActorRdfJoin.getRequestItemTimes(r);return{iterations:r[0].cardinality.value*r[1].cardinality.value,persistedItems:0,blockingItems:0,requestTime:a[0]+r[0].cardinality.value*o[0]+a[1]+r[1].cardinality.value*o[1]}}};return Hd.ActorRdfJoinNestedLoop=u,Hd}var H6;function zK(){return H6||(H6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(kK(),t)}(Jw)),Jw}var Xw={},$d={},$6;function GK(){if($6)return $d;$6=1,Object.defineProperty($d,"__esModule",{value:!0}),$d.ActorRdfJoinMinusHash=void 0;const t=wt(),e=jn();let u=class extends e.ActorRdfJoin{constructor(n){super(n,{logicalType:"minus",physicalName:"hash",limitEntries:2})}async getOutput(n){const r=n.entries[1].output,a=n.entries[0].output,o=await e.ActorRdfJoin.getMetadatas(n.entries),l=e.ActorRdfJoin.overlappingVariables(o);if(l.length>0){const c={},d=new t.ClosableTransformIterator(async()=>(await new Promise(h=>{r.bindingsStream.on("data",f=>{c[e.ActorRdfJoin.hashNonClashing(f,l)]=!0}),r.bindingsStream.on("end",h),r.bindingsStream.on("error",f=>{d.emit("error",f)})}),a.bindingsStream.filter(h=>!c[e.ActorRdfJoin.hashNonClashing(h,l)])),{autoStart:!1,onClose(){r.bindingsStream.destroy(),a.bindingsStream.destroy()}});return{result:{type:"bindings",bindingsStream:d,metadata:a.metadata}}}return r.bindingsStream.destroy(),{result:a}}async getJoinCoefficients(n,r){const a=e.ActorRdfJoin.getRequestInitialTimes(r),o=e.ActorRdfJoin.getRequestItemTimes(r);return{iterations:r[0].cardinality.value+r[1].cardinality.value,persistedItems:r[0].cardinality.value,blockingItems:r[0].cardinality.value,requestTime:a[0]+r[0].cardinality.value*o[0]+a[1]+r[1].cardinality.value*o[1]}}};return $d.ActorRdfJoinMinusHash=u,$d}var V6;function WK(){return V6||(V6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(GK(),t)}(Xw)),Xw}var Kw={},Vd={},kd={},k6;function JK(){if(k6)return kd;k6=1,Object.defineProperty(kd,"__esModule",{value:!0}),kd.BindingsIndex=void 0;const t=Xt();let e=class T3{constructor(s){this.data={},this.keys=s}static hashTerm(s){return s&&s.termType!=="Variable"?(0,t.termToString)(s):""}add(s){if(this.isBindingsValid(s)){let n=this.data;for(const r of this.keys){const a=T3.hashTerm(s.get(r));let o=n[a];o||(o=n[a]={}),n=o}}}contains(s){return this.isBindingsValid(s)?this.containsRecursive(s,this.keys,[this.data]):!1}isBindingsValid(s){let n=!1;for(const r of this.keys)if(s.get(r)){n=!0;break}return n}containsRecursive(s,n,r){if(n.length===0)return!0;let a;[a,...n]=n;for(const o of r){const l=T3.hashTerm(s.get(a));if(l){const c=[o[l],o[""]].filter(Boolean);if(c.length===0)continue;if(this.containsRecursive(s,n,c))return!0}else{let c=Object.keys(o).map(d=>o[d]);if(c.length===0&&(c=[{}]),this.containsRecursive(s,n,c))return!0}}return!1}};return kd.BindingsIndex=e,kd}var z6;function XK(){if(z6)return Vd;z6=1,Object.defineProperty(Vd,"__esModule",{value:!0}),Vd.ActorRdfJoinMinusHashUndef=void 0;const t=wt(),e=jn(),u=JK();let s=class extends e.ActorRdfJoin{constructor(r){super(r,{logicalType:"minus",physicalName:"hash-undef",limitEntries:2,canHandleUndefs:!0})}async getOutput(r){const a=r.entries[1].output,o=r.entries[0].output,l=await e.ActorRdfJoin.getMetadatas(r.entries),c=e.ActorRdfJoin.overlappingVariables(l);if(c.length>0){const d=new u.BindingsIndex(c),h=new t.ClosableTransformIterator(async()=>(await new Promise(f=>{a.bindingsStream.on("data",p=>d.add(p)),a.bindingsStream.on("end",f),a.bindingsStream.on("error",p=>{h.emit("error",p)})}),o.bindingsStream.filter(f=>!d.contains(f))),{autoStart:!1,onClose(){a.bindingsStream.destroy(),o.bindingsStream.destroy()}});return{result:{type:"bindings",bindingsStream:h,async metadata(){const f=await o.metadata(),p=await o.metadata();return{...p,canContainUndefs:f.canContainUndefs||p.canContainUndefs}}}}}return a.bindingsStream.destroy(),{result:o}}async getJoinCoefficients(r,a){const o=e.ActorRdfJoin.getRequestInitialTimes(a),l=e.ActorRdfJoin.getRequestItemTimes(a);return{iterations:(a[0].cardinality.value+a[1].cardinality.value)*1.01,persistedItems:a[0].cardinality.value,blockingItems:a[0].cardinality.value,requestTime:o[0]+a[0].cardinality.value*l[0]+o[1]+a[1].cardinality.value*l[1]}}};return Vd.ActorRdfJoinMinusHashUndef=s,Vd}var G6;function KK(){return G6||(G6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(XK(),t)}(Kw)),Kw}var Yw={},zd={},Gd={},W6;function YK(){if(W6)return Gd;W6=1,Object.defineProperty(Gd,"__esModule",{value:!0}),Gd.BindingsIndexDef=void 0;let t=class{constructor(u,s){this.keys=u,this.hashFn=s,this.index={}}put(u,s){return this.index[this.hashFn(u,this.keys)]=s}get(u){const s=this.getFirst(u);return s?[s]:[]}getFirst(u){return this.index[this.hashFn(u,this.keys)]}values(){return Object.values(this.index)}};return Gd.BindingsIndexDef=t,Gd}var Wd={},J6;function ZK(){if(J6)return Wd;J6=1,Object.defineProperty(Wd,"__esModule",{value:!0}),Wd.BindingsIndexUndef=void 0;let t=class{constructor(u,s){this.data={},this.keys=u,this.hashFn=s}put(u,s){if(this.isBindingsValid(u)){let n=this.data;for(let r=0;rd&&d.termType!=="Variable"?(0,s.termToString)(d):""):new n.BindingsIndexDef(c,e.ActorRdfJoin.hashNonClashing)}async getOutput(l){const c=l.entries[1].output,d=l.entries[0].output,h=await e.ActorRdfJoin.getMetadatas(l.entries),f=e.ActorRdfJoin.overlappingVariables(h);let p;return this.blocking?p=new t.ClosableTransformIterator(async()=>{const y=A3.constructIndex(this.canHandleUndefs,f);return await new Promise(b=>{c.bindingsStream.on("data",g=>{(y.getFirst(g)??y.put(g,[])).push(g)}),c.bindingsStream.on("end",b),c.bindingsStream.on("error",g=>{p.emit("error",g)})}),new u.MultiTransformIterator(d.bindingsStream,{multiTransform:b=>new u.ArrayIterator(y.get(b).flat().map(g=>e.ActorRdfJoin.joinBindings(b,g)).filter(g=>g!==null),{autoStart:!1}),optional:!0,autoStart:!1})},{autoStart:!1,onClose(){c.bindingsStream.destroy(),d.bindingsStream.destroy()}}):p=new t.ClosableTransformIterator(async()=>{const y=A3.constructIndex(this.canHandleUndefs,f);let b=!0;return c.bindingsStream.on("data",g=>{(y.getFirst(g)??y.put(g,new u.BufferedIterator({autoStart:!1})))._push(g)}),c.bindingsStream.on("end",()=>{for(const g of y.values())g.close();b=!1}),c.bindingsStream.on("error",g=>{p.emit("error",g)}),new u.MultiTransformIterator(d.bindingsStream,{multiTransform:g=>{let m=y.get(g);return m.length===0&&(b?m=[y.put(g,new u.BufferedIterator({autoStart:!1}))]:m=[]),new u.UnionIterator(m.map(_=>_.clone()),{autoStart:!1}).map(_=>e.ActorRdfJoin.joinBindings(g,_))},optional:!0,autoStart:!1})},{autoStart:!1,onClose(){c.bindingsStream.destroy(),d.bindingsStream.destroy()}}),{result:{type:"bindings",bindingsStream:p,metadata:async()=>await this.constructResultMetadata(l.entries,await e.ActorRdfJoin.getMetadatas(l.entries),l.context,{canContainUndefs:!0},!0)}}}async getJoinCoefficients(l,c){const d=e.ActorRdfJoin.getRequestInitialTimes(c),h=e.ActorRdfJoin.getRequestItemTimes(c);let f=c[0].cardinality.value+c[1].cardinality.value;return this.canHandleUndefs||(f*=.8),this.blocking&&(f*=.9),{iterations:f,persistedItems:c[0].cardinality.value,blockingItems:this.blocking?c[0].cardinality.value:0,requestTime:d[0]+c[0].cardinality.value*h[0]+d[1]+c[1].cardinality.value*h[1]}}};return zd.ActorRdfJoinOptionalHash=a,zd}var K6;function C1(){return K6||(K6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(eY(),t)}(Yw)),Yw}var Zw={},Jd={},Y6;function tY(){if(Y6)return Jd;Y6=1,Object.defineProperty(Jd,"__esModule",{value:!0}),Jd.ActorRdfJoinOptionalNestedLoop=void 0;const t=jn(),e=nm();let u=class extends t.ActorRdfJoin{constructor(n){super(n,{logicalType:"optional",physicalName:"nested-loop",limitEntries:2,canHandleUndefs:!0})}async getOutput(n){return{result:{type:"bindings",bindingsStream:new e.NestedLoopJoin(n.entries[0].output.bindingsStream,n.entries[1].output.bindingsStream,t.ActorRdfJoin.joinBindings,{optional:!0,autoStart:!1}),metadata:async()=>await this.constructResultMetadata(n.entries,await t.ActorRdfJoin.getMetadatas(n.entries),n.context,{canContainUndefs:!0},!0)}}}async getJoinCoefficients(n,r){const a=t.ActorRdfJoin.getRequestInitialTimes(r),o=t.ActorRdfJoin.getRequestItemTimes(r);return{iterations:r[0].cardinality.value*r[1].cardinality.value,persistedItems:0,blockingItems:0,requestTime:a[0]+r[0].cardinality.value*o[0]+a[1]+r[1].cardinality.value*o[1]}}};return Jd.ActorRdfJoinOptionalNestedLoop=u,Jd}var Z6;function rY(){return Z6||(Z6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(tY(),t)}(Zw)),Zw}var e2={},Xd={},t2={},Kd={},eC;function nY(){if(eC)return Kd;eC=1,Object.defineProperty(Kd,"__esModule",{value:!0}),Kd.ActorDereferenceRdf=void 0;const t=eA();let e=class extends t.ActorDereferenceParse{constructor(s){super(s)}};return Kd.ActorDereferenceRdf=e,Kd}var tC;function iY(){return tC||(tC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(nY(),t)}(t2)),t2}var rC;function aY(){if(rC)return Xd;rC=1,Object.defineProperty(Xd,"__esModule",{value:!0}),Xd.ActorDereferenceRdfParse=void 0;const t=iY();let e=class extends t.ActorDereferenceRdf{constructor(s){super(s)}async getMetadata(s){return{baseIRI:s.url}}};return Xd.ActorDereferenceRdfParse=e,Xd}var nC;function sY(){return nC||(nC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(aY(),t)}(e2)),e2}var r2={},Yd={},Zd={},iC;function oY(){if(iC)return Zd;iC=1,Object.defineProperty(Zd,"__esModule",{value:!0}),Zd.HtmlScriptListener=void 0;const t=Lt,e=Wt(),u=Pi();let s=class P0{constructor(r,a,o,l,c,d,h,f){this.textChunksJsonLd=[],this.endBarrier=1,this.passedScripts=0,this.isFinalJsonLdProcessing=!1,this.mediatorRdfParseHandle=r,this.cbQuad=a,this.cbError=o,this.cbEnd=l,this.supportedTypes=c,this.context=d.set(t.KeysRdfParseHtmlScript.processingHtmlScript,!0),this.baseIRI=h,this.headers=f,this.onlyFirstScript=d.get(t.KeysRdfParseHtmlScript.extractAllScripts)===!1;const p=this.baseIRI.indexOf("#");this.targetScriptId=p>0?this.baseIRI.slice(p+1,this.baseIRI.length):null}static newErrorCoded(r,a){const o=new Error(r);return o.code=a,o}onEnd(){--this.endBarrier===0&&(this.textChunksJsonLd.length>0?(this.handleMediaType="application/ld+json",this.textChunks=this.textChunksJsonLd,this.textChunks.push("]"),this.textChunksJsonLd=[],this.isFinalJsonLdProcessing=!0,this.endBarrier++,this.onTagClose()):(this.passedScripts===0&&this.targetScriptId&&this.cbError(P0.newErrorCoded(`Failed to find targeted script id "${this.targetScriptId}"`,"loading document failed")),this.cbEnd()),this.isFinalJsonLdProcessing=!1)}onTagClose(){if(this.handleMediaType)if(this.requiresCustomJsonLdHandling(this.handleMediaType)&&!this.isFinalJsonLdProcessing)this.handleMediaType=void 0,this.textChunks=void 0,this.onEnd();else{const r=new e.Readable({objectMode:!0});r._read=()=>{};const a=this.textChunks,o={context:this.context,handle:{metadata:{baseIRI:this.baseIRI},data:r,headers:this.headers,context:this.context},handleMediaType:this.handleMediaType};this.mediatorRdfParseHandle.mediate(o).then(({handle:l})=>{l.data.on("error",c=>this.cbError(P0.newErrorCoded(c.message,"invalid script element"))).on("data",this.cbQuad).on("end",()=>this.onEnd());for(const c of a)r.push(c);r.push(null)}).catch(l=>{this.targetScriptId?this.cbError(P0.newErrorCoded(l.message,"loading document failed")):this.onEnd()}),this.handleMediaType=void 0,this.textChunks=void 0}}onTagOpen(r,a){r==="base"&&a.href&&(this.baseIRI=(0,u.resolve)(a.href,this.baseIRI)),r==="script"&&(!this.targetScriptId||a.id===this.targetScriptId)?this.supportedTypes[a.type]?this.onlyFirstScript&&this.passedScripts>0?this.handleMediaType=void 0:(this.passedScripts++,this.handleMediaType=a.type,this.endBarrier++,this.requiresCustomJsonLdHandling(this.handleMediaType)?(this.textChunks=this.textChunksJsonLd,this.textChunks.push(this.textChunks.length===0?"[":",")):this.textChunks=[]):this.targetScriptId&&this.cbError(P0.newErrorCoded(`Targeted script "${this.targetScriptId}" does not have a supported type`,"loading document failed")):this.handleMediaType=void 0}onText(r){this.handleMediaType&&this.textChunks.push(r)}requiresCustomJsonLdHandling(r){return!this.onlyFirstScript&&!this.targetScriptId&&r==="application/ld+json"}};return Zd.HtmlScriptListener=s,Zd}var aC;function uY(){if(aC)return Yd;aC=1,Object.defineProperty(Yd,"__esModule",{value:!0}),Yd.ActorRdfParseHtmlScript=void 0;const t=uA(),e=oY();let u=class extends t.ActorRdfParseHtml{constructor(n){super(n)}async test(n){return!0}async run(n){const r=(await this.mediatorRdfParseMediatypes.mediate({context:n.context,mediaTypes:!0})).mediaTypes;return{htmlParseListener:new e.HtmlScriptListener(this.mediatorRdfParseHandle,n.emit,n.error,n.end,r,n.context,n.baseIRI,n.headers)}}};return Yd.ActorRdfParseHtmlScript=u,Yd}var sC;function cY(){return sC||(sC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(uY(),t)}(r2)),r2}var n2={},ef={},oC;function lY(){if(oC)return ef;oC=1,Object.defineProperty(ef,"__esModule",{value:!0}),ef.ActorQueryResultSerializeRdf=void 0;const t=Gi();let e=class extends t.ActorQueryResultSerialize{constructor(s){super(s)}async testHandle(s,n,r){if(s.type!=="quads")throw new Error(`Actor ${this.name} can only handle quad streams`);const{mediaTypes:a}=await this.mediatorMediaTypeCombiner.mediate({context:r,mediaTypes:!0});if(!(n in a))throw new Error(`Actor ${this.name} can not handle media type ${n}. All available types: ${Object.keys(a)}`);return!0}async runHandle(s,n,r){return(await this.mediatorRdfSerialize.mediate({context:r,handle:{context:r,quadStream:s.quadStream},handleMediaType:n})).handle}async testMediaType(s){return!0}async getMediaTypes(s){return(await this.mediatorMediaTypeCombiner.mediate({context:s,mediaTypes:!0})).mediaTypes}async testMediaTypeFormats(s){return!0}async getMediaTypeFormats(s){return(await this.mediatorMediaTypeFormatCombiner.mediate({context:s,mediaTypeFormats:!0})).mediaTypeFormats}};return ef.ActorQueryResultSerializeRdf=e,ef}var uC;function dY(){return uC||(uC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(lY(),t)}(n2)),n2}var i2={},tf={},cC;function fY(){if(cC)return tf;cC=1,Object.defineProperty(tf,"__esModule",{value:!0}),tf.ActorHttpWayback=void 0;const t=as(),e=Lt,u=ou();I7();const s="http://wayback.archive-it.org/";function n(o){const l=new Request(o.input,o.init);return{input:new Request(new URL(`/${l.url}`,s),l)}}function r(o){const l=o.get(e.KeysHttpProxy.httpProxyHandler);return l?c=>l.getProxy(n(c)):c=>Promise.resolve(n(c))}let a=class extends t.ActorHttp{constructor(l){super(l)}async test(l){return!0}async run(l){let c=await this.mediatorHttp.mediate(l);if(c.status===404&&l.context.get(e.KeysHttpWayback.recoverBrokenLinks)){let d=await this.mediatorHttp.mediate({...l,context:l.context.set(e.KeysHttpWayback.recoverBrokenLinks,!1).set(e.KeysHttpProxy.httpProxyHandler,{getProxy:r(l.context)})});d.status===200&&([c,d]=[d,c]);const{body:h}=d;h&&("cancel"in h&&typeof h.cancel=="function"?await h.cancel():"destroy"in h&&typeof h.destroy=="function"?h.destroy():await(0,u.stringify)(t.ActorHttp.toNodeReadable(h)))}return c}};return tf.ActorHttpWayback=a,tf}var lC;function hY(){return lC||(lC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(fY(),t)}(i2)),i2}var a2={},rf={},s2={},nf={},af={},sf={},of={},uf={},dC;function pY(){if(dC)return uf;dC=1,Object.defineProperty(uf,"__esModule",{value:!0}),uf.ContainerHandlerIdentifier=void 0;let t=class{canCombineWithGraph(){return!0}async handle(u,s,n,r,a,o){let l;if(s.emittedStack[o+1]&&s.idStack[o+1])l=s.idStack[o+1][0];else{const h=await n.getContainerKey(r[o],r,o)!==null?await n.resourceToTerm(await s.getContext(r),r[o]):n.dataFactory.blankNode();if(!h){s.emittedStack[o]=!1;return}l=h,s.idStack[o+1]=[l]}let c=s.idStack[o];c||(c=s.idStack[o]=[]),c.some(d=>d.equals(l))||c.push(l),await s.handlePendingContainerFlushBuffers()||(s.emittedStack[o]=!1)}};return uf.ContainerHandlerIdentifier=t,uf}var cf={},lf={},fC;function im(){if(fC)return lf;fC=1,Object.defineProperty(lf,"__esModule",{value:!0}),lf.EntryHandlerPredicate=void 0;const t=Jr(),e=ro();let u=class N7{static async handlePredicateObject(n,r,a,o,l,c,d,h,f){const p=await r.getPropertiesDepth(a,o),y=await r.getDepthOffsetGraph(o,a),b=o-y,g=n.idStack[p];if(g&&!f)for(const m of g)if(y>=0){const _=n.idStack[b-1];if(_)for(const w of _)r.emitQuadChecked(o,m,l,c,w,d,h);else d?(r.validateReverseSubject(c),n.getUnidentifiedGraphBufferSafe(b-1).push({subject:c,predicate:l,object:m,isEmbedded:h})):n.getUnidentifiedGraphBufferSafe(b-1).push({subject:m,predicate:l,object:c,isEmbedded:h})}else{const _=await r.getGraphContainerValue(a,p);r.emitQuadChecked(o,m,l,c,_,d,h)}else if(d&&r.validateReverseSubject(c),f){if(n.rdfstar){n.idStack[o]&&n.emitError(new t.ErrorCoded(`Found an illegal @id inside an annotation: ${n.idStack[o][0].value}`,t.ERROR_CODES.INVALID_ANNOTATION));for(let _=0;_=0;_--){const w=m[_];w.depth>p&&(v.nestedAnnotations.push(w),m.splice(_,1))}}}else n.getUnidentifiedValueBufferSafe(p).push({predicate:l,object:c,reverse:d,isEmbedded:h})}isPropertyHandler(){return!0}isStackProcessor(){return!0}async validate(n,r,a,o,l){const c=a[o];if(c){const d=await n.getContext(a);if(!n.jsonLiteralStack[o]&&await r.predicateToTerm(d,a[o]))return e.Util.getContextValueType(d,c)==="@json"&&(n.jsonLiteralStack[o+1]=!0),!0}return!1}async test(n,r,a,o,l){return o[l]}async handle(n,r,a,o,l,c,d){const h=o[c],f=await n.getContext(o),p=await r.predicateToTerm(f,a);if(p){const y=await r.valueToTerm(f,a,l,c,o);if(y.length)for(let b of y){let g=await r.unaliasKeywordParent(o,c);const m=e.Util.isPropertyReverse(f,h,g);let v=0;for(;g==="@reverse"||typeof g=="number";)typeof g=="number"?v++:c--,g=await r.unaliasKeywordParent(o,c-v);const _=e.Util.isPropertyInEmbeddedNode(g);r.validateReverseInEmbeddedNode(a,m,_);const w=e.Util.isPropertyInAnnotationObject(g);if(l){const S="@list"in e.Util.getContextValueContainer(f,a);if(S||l["@list"]){if((S&&!Array.isArray(l)&&!l["@list"]||l["@list"]&&!Array.isArray(l["@list"]))&&b!==r.rdfNil){const A=r.dataFactory.blankNode();n.emitQuad(c,r.dataFactory.quad(A,r.rdfRest,r.rdfNil,r.getDefaultGraph())),n.emitQuad(c,r.dataFactory.quad(A,r.rdfFirst,b,r.getDefaultGraph())),b=A}if(m&&!n.allowSubjectList)throw new t.ErrorCoded(`Found illegal list value in subject position at ${a}`,t.ERROR_CODES.INVALID_REVERSE_PROPERTY_VALUE)}}await N7.handlePredicateObject(n,r,o,c,p,b,m,_,w)}}}};return lf.EntryHandlerPredicate=u,lf}var hC;function yY(){if(hC)return cf;hC=1,Object.defineProperty(cf,"__esModule",{value:!0}),cf.ContainerHandlerIndex=void 0;const t=Jr(),e=im(),u=ro();let s=class{canCombineWithGraph(){return!0}async handle(r,a,o,l,c,d){if(!Array.isArray(c)){const h="@graph"in r,f=await a.getContext(l),p=l[d-1],y=u.Util.getContextValueIndex(f,p);if(y){if(t.Util.isPotentialKeyword(y))throw new t.ErrorCoded(`Keywords can not be used as @index value, got: ${y}`,t.ERROR_CODES.INVALID_TERM_DEFINITION);if(typeof y!="string")throw new t.ErrorCoded(`@index values must be strings, got: ${y}`,t.ERROR_CODES.INVALID_TERM_DEFINITION);if(typeof c!="object"){if(u.Util.getContextValueType(f,p)!=="@id")throw new t.ErrorCoded(`Property-based index containers require nodes as values or strings with @type: @id, but got: ${c}`,t.ERROR_CODES.INVALID_VALUE_OBJECT);const m=o.resourceToTerm(f,c);m&&(a.idStack[d+1]=[m])}const g=o.createVocabOrBaseTerm(f,y);if(g){const m=await o.valueToTerm(f,y,await o.getContainerKey(l[d],l,d),d,l);if(h){const v=await o.getGraphContainerValue(l,d+1);for(const _ of m)a.emitQuad(d,o.dataFactory.quad(v,g,_,o.getDefaultGraph()))}else for(const v of m)await e.EntryHandlerPredicate.handlePredicateObject(a,o,l,d+1,g,v,!1,!1,!1)}}const b=h?2:1;await a.newOnValueJob(l.slice(0,l.length-b),c,d-b,!0),await a.handlePendingContainerFlushBuffers()}a.emittedStack[d]=!1}};return cf.ContainerHandlerIndex=s,cf}var df={},pC;function bY(){if(pC)return df;pC=1,Object.defineProperty(df,"__esModule",{value:!0}),df.ContainerHandlerLanguage=void 0;const t=Jr();let e=class{canCombineWithGraph(){return!1}async handle(s,n,r,a,o,l){const c=await r.getContainerKey(a[l],a,l);if(Array.isArray(o))o=o.map(d=>({"@value":d,"@language":c}));else{if(typeof o!="string")throw new t.ErrorCoded(`Got invalid language map value, got '${JSON.stringify(o)}', but expected string`,t.ERROR_CODES.INVALID_LANGUAGE_MAP_VALUE);o={"@value":o,"@language":c}}await n.newOnValueJob(a.slice(0,a.length-1),o,l-1,!0),n.emittedStack[l]=!1}};return df.ContainerHandlerLanguage=e,df}var ff={},yC;function mY(){if(yC)return ff;yC=1,Object.defineProperty(ff,"__esModule",{value:!0}),ff.ContainerHandlerType=void 0;const t=im(),e=ro();let u=class{canCombineWithGraph(){return!1}async handle(n,r,a,o,l,c){if(!Array.isArray(l)){if(typeof l=="string"){const f=await r.getContext(o),y=e.Util.getContextValueType(f,o[c-1])==="@vocab"?await a.createVocabOrBaseTerm(f,l):await a.resourceToTerm(f,l);if(y){const b={"@id":y.termType==="NamedNode"?y.value:l};await r.newOnValueJob(o.slice(0,o.length-1),b,c-1,!0),r.idStack[c+1]=[y]}}else{const f=!!r.idStack[c+1];f||delete r.idStack[c],await r.newOnValueJob(o.slice(0,o.length-1),l,c-1,!0),f||(r.idStack[c+1]=r.idStack[c])}const d=await a.getContainerKey(o[c],o,c),h=d!==null?a.createVocabOrBaseTerm(await r.getContext(o),d):null;h&&await t.EntryHandlerPredicate.handlePredicateObject(r,a,o,c+1,a.rdfType,h,!1,!1,!1),await r.handlePendingContainerFlushBuffers()}r.emittedStack[c]=!1}};return ff.ContainerHandlerType=u,ff}var bC;function C7(){if(bC)return of;bC=1,Object.defineProperty(of,"__esModule",{value:!0}),of.EntryHandlerContainer=void 0;const t=pY(),e=yY(),u=bY(),s=mY(),n=ro();let r=class Na{static isSimpleGraphContainer(o){return"@graph"in o&&("@set"in o&&Object.keys(o).length===2||Object.keys(o).length===1)}static isComplexGraphContainer(o){return"@graph"in o&&("@set"in o&&Object.keys(o).length>2||!("@set"in o)&&Object.keys(o).length>1)}static getContainerGraphIndex(o,l,c){let d=Na.isSimpleGraphContainer(o),h="";for(let f=l;f=0;p--)if(typeof l[p]!="number"){const y=n.Util.getContextValue(f,"@container",l[p],!1);if(y&&Na.isSimpleGraphContainer(y))return{containers:y,depth:p+1,fallback:!1};const b=n.Util.getContextValue(f,"@container",l[p-1],!1);if(b){const g="@graph"in b;for(const m in Na.CONTAINER_HANDLERS)if(b[m])return g?Na.CONTAINER_HANDLERS[m].canCombineWithGraph()?{containers:b,depth:p,fallback:!1}:d:h?d:{containers:b,depth:p,fallback:!1};return d}else{if(h)return d;h=!0}}return d}static async isBufferableContainerHandler(o,l,c){const d=await Na.getContainerHandler(o,l,c);return!d.fallback&&!("@graph"in d.containers)}isPropertyHandler(){return!1}isStackProcessor(){return!0}async validate(o,l,c,d,h){return!!await this.test(o,l,null,c,d)}async test(o,l,c,d,h){const f=n.Util.getContextValueContainer(await o.getContext(d,2),d[h-1]);for(const p in Na.CONTAINER_HANDLERS)if(f[p])return{containers:f,handler:Na.CONTAINER_HANDLERS[p]};return null}async handle(o,l,c,d,h,f,p){return p.handler.handle(p.containers,o,l,d,h,f)}};return r.CONTAINER_HANDLERS={"@id":new t.ContainerHandlerIdentifier,"@index":new e.ContainerHandlerIndex,"@language":new u.ContainerHandlerLanguage,"@type":new s.ContainerHandlerType},of.EntryHandlerContainer=r,of}var o2,mC;function gY(){return mC||(mC=1,o2=function t(e){return e===null||typeof e!="object"||e.toJSON!=null?JSON.stringify(e):Array.isArray(e)?"["+e.reduce((u,s,n)=>{const r=n===0?"":",",a=s===void 0||typeof s=="symbol"?null:s;return u+r+t(a)},"")+"]":"{"+Object.keys(e).sort().reduce((u,s,n)=>{if(e[s]===void 0||typeof e[s]=="symbol")return u;const r=u.length===0?"":",";return u+r+t(s)+":"+t(e[s])},"")+"}"}),o2}var gC;function ro(){if(gC)return sf;gC=1,Object.defineProperty(sf,"__esModule",{value:!0}),sf.Util=void 0;const t=Jr(),e=Et(),u=C7(),s=gY();let n=class Zt{constructor(a){this.parsingContext=a.parsingContext,this.dataFactory=a.dataFactory||new e.DataFactory,this.rdfFirst=this.dataFactory.namedNode(Zt.RDF+"first"),this.rdfRest=this.dataFactory.namedNode(Zt.RDF+"rest"),this.rdfNil=this.dataFactory.namedNode(Zt.RDF+"nil"),this.rdfType=this.dataFactory.namedNode(Zt.RDF+"type"),this.rdfJson=this.dataFactory.namedNode(Zt.RDF+"JSON")}static getContextValue(a,o,l,c){const d=a.getContextRaw()[l];if(!d)return c;const h=d[o];return h===void 0?c:h}static getContextValueContainer(a,o){return Zt.getContextValue(a,"@container",o,{"@set":!0})}static getContextValueType(a,o){const l=Zt.getContextValue(a,"@type",o,null);return l==="@none"?null:l}static getContextValueLanguage(a,o){return Zt.getContextValue(a,"@language",o,a.getContextRaw()["@language"]||null)}static getContextValueDirection(a,o){return Zt.getContextValue(a,"@direction",o,a.getContextRaw()["@direction"]||null)}static isContextValueReverse(a,o){return!!Zt.getContextValue(a,"@reverse",o,null)}static getContextValueIndex(a,o){return Zt.getContextValue(a,"@index",o,a.getContextRaw()["@index"]||null)}static isPropertyReverse(a,o,l){return l==="@reverse"!==Zt.isContextValueReverse(a,o)}static isPropertyInEmbeddedNode(a){return a==="@id"}static isPropertyInAnnotationObject(a){return a==="@annotation"}static isValidIri(a){return a!==null&&t.Util.isValidIri(a)}static isPrefixArray(a,o){if(a.length>o.length)return!1;for(let l=0;l1)throw new t.ErrorCoded(`Found illegal neighbouring entries next to @set for key: '${o}'`,t.ERROR_CODES.INVALID_SET_OR_LIST_OBJECT);return[]}else if("@list"in l){if(Object.keys(l).length>1)throw new t.ErrorCoded(`Found illegal neighbouring entries next to @list for key: '${o}'`,t.ERROR_CODES.INVALID_SET_OR_LIST_OBJECT);const f=l["@list"];return Array.isArray(f)?f.length===0?[this.rdfNil]:this.parsingContext.idStack[c+1]||[]:await this.valueToTerm(await this.parsingContext.getContext(d),o,f,c-1,d.slice(0,-1))}else{if("@reverse"in l&&typeof l["@reverse"]=="boolean")return[];if("@graph"in Zt.getContextValueContainer(await this.parsingContext.getContext(d),o)){const f=this.parsingContext.graphContainerTermStack[c+1];return f?Object.values(f):[this.dataFactory.blankNode()]}else if("@id"in l){if(Object.keys(l).length>1&&(a=await this.parsingContext.getContext(d,0)),"@context"in l&&(a=await this.parsingContext.parseContext(l["@context"],a.getContextRaw())),l["@type"]==="@vocab")return this.nullableTermToArray(this.createVocabOrBaseTerm(a,l["@id"]));{const f=l["@id"];let p;if(typeof f=="object")if(this.parsingContext.rdfstar)p=this.parsingContext.idStack[c+1][0];else throw new t.ErrorCoded(`Found illegal @id '${l}'`,t.ERROR_CODES.INVALID_ID_VALUE);else p=this.resourceToTerm(a,f);return this.nullableTermToArray(p)}}else return this.parsingContext.emittedStack[c+1]||l&&typeof l=="object"&&Object.keys(l).length===0?this.parsingContext.idStack[c+1]||(this.parsingContext.idStack[c+1]=[this.dataFactory.blankNode()]):[]}case"string":return this.nullableTermToArray(this.stringValueToTerm(c,await this.getContextSelfOrPropertyScoped(a,o),o,l,null));case"boolean":return this.nullableTermToArray(this.stringValueToTerm(c,await this.getContextSelfOrPropertyScoped(a,o),o,(!!l).toString(),this.dataFactory.namedNode(Zt.XSD_BOOLEAN)));case"number":return this.nullableTermToArray(this.stringValueToTerm(c,await this.getContextSelfOrPropertyScoped(a,o),o,l,this.dataFactory.namedNode(l%1===0&&l<1e21?Zt.XSD_INTEGER:Zt.XSD_DOUBLE)));default:return this.parsingContext.emitError(new Error(`Could not determine the RDF type of a ${h}`)),[]}}async getContextSelfOrPropertyScoped(a,o){const l=a.getContextRaw()[o];return l&&typeof l=="object"&&"@context"in l&&(a=await this.parsingContext.parseContext(l,a.getContextRaw(),!0)),a}nullableTermToArray(a){return a?[a]:[]}predicateToTerm(a,o){const l=a.expandTerm(o,!0,this.parsingContext.getExpandOptions());if(!l)return null;if(l[0]==="_"&&l[1]===":")return this.parsingContext.produceGeneralizedRdf?this.dataFactory.blankNode(l.substr(2)):null;if(Zt.isValidIri(l))return this.dataFactory.namedNode(l);if(l&&this.parsingContext.strictValues)this.parsingContext.emitError(new t.ErrorCoded(`Invalid predicate IRI: ${l}`,t.ERROR_CODES.INVALID_IRI_MAPPING));else return null;return null}resourceToTerm(a,o){if(o.startsWith("_:"))return this.dataFactory.blankNode(o.substr(2));const l=a.expandTerm(o,!1,this.parsingContext.getExpandOptions());if(!Zt.isValidIri(l))if(l&&this.parsingContext.strictValues)this.parsingContext.emitError(new Error(`Invalid resource IRI: ${l}`));else return null;return this.dataFactory.namedNode(l)}createVocabOrBaseTerm(a,o){if(o.startsWith("_:"))return this.dataFactory.blankNode(o.substr(2));const l=this.parsingContext.getExpandOptions();let c=a.expandTerm(o,!0,l);if(c===o&&(c=a.expandTerm(o,!1,l)),!Zt.isValidIri(c))if(c&&this.parsingContext.strictValues&&!c.startsWith("@"))this.parsingContext.emitError(new Error(`Invalid term IRI: ${c}`));else return null;return this.dataFactory.namedNode(c)}intToString(a,o){return typeof a=="number"?Number.isFinite(a)?a%1===0&&(!o||o.value!==Zt.XSD_DOUBLE)?Number(a).toString():a.toExponential(15).replace(/(\d)0*e\+?/,"$1E"):a>0?"INF":"-INF":a}stringValueToTerm(a,o,l,c,d){const h=Zt.getContextValueType(o,l);if(h)if(h==="@id"){if(!d)return this.resourceToTerm(o,this.intToString(c,d))}else if(h==="@vocab"){if(!d)return this.createVocabOrBaseTerm(o,this.intToString(c,d))}else d=this.dataFactory.namedNode(h);if(!d){const f=Zt.getContextValueLanguage(o,l),p=Zt.getContextValueDirection(o,l);return p&&this.parsingContext.rdfDirection?this.createLanguageDirectionLiteral(a,this.intToString(c,d),f,p):this.dataFactory.literal(this.intToString(c,d),f)}return this.dataFactory.literal(this.intToString(c,d),d)}createLanguageDirectionLiteral(a,o,l,c){if(this.parsingContext.rdfDirection==="i18n-datatype")return l||(l=""),this.dataFactory.literal(o,this.dataFactory.namedNode(`https://www.w3.org/ns/i18n#${l}_${c}`));{const d=this.dataFactory.blankNode(),h=this.getDefaultGraph();return this.parsingContext.emitQuad(a,this.dataFactory.quad(d,this.dataFactory.namedNode(Zt.RDF+"value"),this.dataFactory.literal(o),h)),l&&this.parsingContext.emitQuad(a,this.dataFactory.quad(d,this.dataFactory.namedNode(Zt.RDF+"language"),this.dataFactory.literal(l),h)),this.parsingContext.emitQuad(a,this.dataFactory.quad(d,this.dataFactory.namedNode(Zt.RDF+"direction"),this.dataFactory.literal(c),h)),d}}valueToJsonString(a){return s(a)}async unaliasKeyword(a,o,l,c,d){if(Number.isInteger(a))return a;if(!c){const h=this.parsingContext.unaliasedKeywordCacheStack[l];if(h)return h}if(!t.Util.isPotentialKeyword(a)){d=d||await this.parsingContext.getContext(o);let h=d.getContextRaw()[a];h&&typeof h=="object"&&(h=h["@id"]),t.Util.isValidKeyword(h)&&(a=h)}return c?a:this.parsingContext.unaliasedKeywordCacheStack[l]=a}async unaliasKeywordParent(a,o){return await this.unaliasKeyword(o>0&&a[o-1],a,o-1)}async unaliasKeywords(a,o,l,c){const d={};for(const h in a)d[await this.unaliasKeyword(h,o,l+1,!0,c)]=a[h];return d}async isLiteral(a,o){for(let l=o;l>=0;l--){if(await this.unaliasKeyword(a[l],a,l)==="@annotation")return!1;if(this.parsingContext.literalStack[l]||this.parsingContext.jsonLiteralStack[l])return!0}return!1}async getDepthOffsetGraph(a,o){for(let l=a-1;l>0;l--)if(await this.unaliasKeyword(o[l],o,l)==="@graph"){const c=(await u.EntryHandlerContainer.getContainerHandler(this.parsingContext,o,l)).containers;return u.EntryHandlerContainer.isComplexGraphContainer(c)?-1:a-l-1}return-1}validateReverseSubject(a){if(a.termType==="Literal")throw new t.ErrorCoded(`Found illegal literal in subject position: ${a.value}`,t.ERROR_CODES.INVALID_REVERSE_PROPERTY_VALUE)}getDefaultGraph(){return this.parsingContext.defaultGraph||this.dataFactory.defaultGraph()}async getGraphContainerValue(a,o){let l=this.getDefaultGraph();const{containers:c,depth:d}=await u.EntryHandlerContainer.getContainerHandler(this.parsingContext,a,o);if("@graph"in c){const h=u.EntryHandlerContainer.getContainerGraphIndex(c,d,a),f=this.parsingContext.graphContainerTermStack[d];if(l=f?f[h]:null,!l){let p=null;if("@id"in c){const y=await this.getContainerKey(a[d],a,d);y!==null&&(p=await this.resourceToTerm(await this.parsingContext.getContext(a),y))}p||(p=this.dataFactory.blankNode()),this.parsingContext.graphContainerTermStack[d]||(this.parsingContext.graphContainerTermStack[d]={}),l=this.parsingContext.graphContainerTermStack[d][h]=p}}return l}async getPropertiesDepth(a,o){let l=o;for(let c=o-1;c>0;c--)if(typeof a[c]!="number"){const d=await this.unaliasKeyword(a[c],a,c);if(d==="@reverse")return c;if(d==="@nest")l=c;else return l}return l}async getContainerKey(a,o,l){const c=await this.unaliasKeyword(a,o,l);return c==="@none"?null:c}validateReverseInEmbeddedNode(a,o,l){if(l&&o&&!this.parsingContext.rdfstarReverseInEmbedded)throw new t.ErrorCoded(`Illegal reverse property in embedded node in ${a}`,t.ERROR_CODES.INVALID_EMBEDDED_NODE)}emitQuadChecked(a,o,l,c,d,h,f){let p;if(h?(this.validateReverseSubject(c),p=this.dataFactory.quad(c,l,o,d)):p=this.dataFactory.quad(o,l,c,d),f){if(p.graph.termType!=="DefaultGraph"&&(p=this.dataFactory.quad(p.subject,p.predicate,p.object)),this.parsingContext.idStack[a-1])throw new t.ErrorCoded("Illegal multiple properties in an embedded node",t.ERROR_CODES.INVALID_EMBEDDED_NODE);this.parsingContext.idStack[a-1]=[p]}else this.parsingContext.emitQuad(a,p);const y=this.parsingContext.annotationsBuffer[a];if(y){for(const b of y)this.emitAnnotation(a,p,b);delete this.parsingContext.annotationsBuffer[a]}}emitAnnotation(a,o,l){let c;l.reverse?(this.validateReverseSubject(l.object),c=this.dataFactory.quad(l.object,l.predicate,o)):c=this.dataFactory.quad(o,l.predicate,l.object),this.parsingContext.emitQuad(a,c);for(const d of l.nestedAnnotations)this.emitAnnotation(a,c,d)}};return n.XSD="http://www.w3.org/2001/XMLSchema#",n.XSD_BOOLEAN=n.XSD+"boolean",n.XSD_INTEGER=n.XSD+"integer",n.XSD_DOUBLE=n.XSD+"double",n.RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#",sf.Util=n,sf}var _C;function _Y(){if(_C)return af;_C=1,Object.defineProperty(af,"__esModule",{value:!0}),af.EntryHandlerArrayValue=void 0;const t=ro(),e=Jr();let u=class{isPropertyHandler(){return!1}isStackProcessor(){return!0}async validate(n,r,a,o,l){return this.test(n,r,null,a,o)}async test(n,r,a,o,l){return typeof o[l]=="number"}async handle(n,r,a,o,l,c){let d=await r.unaliasKeywordParent(o,c);if(d==="@list"){let h=null,f=0;for(let p=c-2;p>0;p--){const y=o[p];if(typeof y=="string"||typeof y=="number"){f=p,h=y;break}}if(h!==null){const p=await r.valueToTerm(await n.getContext(o),h,l,c,o);for(const y of p)await this.handleListElement(n,r,y,l,c,o.slice(0,f),f);p.length===0&&await this.handleListElement(n,r,null,l,c,o.slice(0,f),f)}}else if(d==="@set")await n.newOnValueJob(o.slice(0,-2),l,c-2,!1);else if(d!==void 0&&d!=="@type"){for(let f=c-1;f>0;f--)if(typeof o[f]!="number"){d=await r.unaliasKeyword(o[f],o,f);break}const h=await n.getContext(o.slice(0,-1));if("@list"in t.Util.getContextValueContainer(h,d)){n.emittedStack[c+1]=!0;const f=await r.valueToTerm(await n.getContext(o),d,l,c,o);for(const p of f)await this.handleListElement(n,r,p,l,c,o.slice(0,-1),c-1);f.length===0&&await this.handleListElement(n,r,null,l,c,o.slice(0,-1),c-1)}else n.shiftStack(c,1),await n.newOnValueJob(o.slice(0,-1),l,c-1,!1),n.contextTree.removeContext(o.slice(0,-1))}}async handleListElement(n,r,a,o,l,c,d){let h=n.listPointerStack[l];if(o!==null&&(await r.unaliasKeywords(o,c,l))["@value"]!==null){if(!h||!h.value){const f=r.dataFactory.blankNode();h={value:f,listRootDepth:d,listId:f}}else{const f=r.dataFactory.blankNode();n.emitQuad(l,r.dataFactory.quad(h.value,r.rdfRest,f,r.getDefaultGraph())),h.value=f}a&&n.emitQuad(l,r.dataFactory.quad(h.value,r.rdfFirst,a,r.getDefaultGraph()))}else h||(h={listRootDepth:d,listId:r.rdfNil});n.listPointerStack[l]=h,n.rdfstar&&n.annotationsBuffer[l]&&n.emitError(new e.ErrorCoded("Found an illegal annotation inside a list",e.ERROR_CODES.INVALID_ANNOTATION))}};return af.EntryHandlerArrayValue=u,af}var hf={},vC;function vY(){if(vC)return hf;vC=1,Object.defineProperty(hf,"__esModule",{value:!0}),hf.EntryHandlerInvalidFallback=void 0;let t=class{isPropertyHandler(){return!1}isStackProcessor(){return!0}async validate(u,s,n,r,a){return!1}async test(u,s,n,r,a){return!0}async handle(u,s,n,r,a,o){u.emittedStack[o]=!1}};return hf.EntryHandlerInvalidFallback=t,hf}var pf={},yf={},wC;function ss(){if(wC)return yf;wC=1,Object.defineProperty(yf,"__esModule",{value:!0}),yf.EntryHandlerKeyword=void 0;let t=class{constructor(u){this.keyword=u}isPropertyHandler(){return!1}isStackProcessor(){return!0}async validate(u,s,n,r,a){return!1}async test(u,s,n,r,a){return n===this.keyword}};return yf.EntryHandlerKeyword=t,yf}var SC;function wY(){if(SC)return pf;SC=1,Object.defineProperty(pf,"__esModule",{value:!0}),pf.EntryHandlerKeywordContext=void 0;const t=Jr(),e=ss();let u=class extends e.EntryHandlerKeyword{constructor(){super("@context")}isStackProcessor(){return!1}async handle(n,r,a,o,l,c){n.streamingProfile&&(n.processingStack[c]||n.processingType[c]||n.idStack[c]!==void 0)&&n.emitError(new t.ErrorCoded("Found an out-of-order context, while streaming is enabled.(disable `streamingProfile`)",t.ERROR_CODES.INVALID_STREAMING_KEY_ORDER));const d=n.getContext(o),h=n.parseContext(l,(await d).getContextRaw());n.contextTree.setContext(o.slice(0,-1),h),n.emitContext(l),await n.validateContext(await h)}};return pf.EntryHandlerKeywordContext=u,pf}var bf={},TC;function SY(){if(TC)return bf;TC=1,Object.defineProperty(bf,"__esModule",{value:!0}),bf.EntryHandlerKeywordGraph=void 0;const t=ss();let e=class extends t.EntryHandlerKeyword{constructor(){super("@graph")}async handle(s,n,r,a,o,l){s.graphStack[l+1]=!0}};return bf.EntryHandlerKeywordGraph=e,bf}var mf={},AC;function TY(){if(AC)return mf;AC=1,Object.defineProperty(mf,"__esModule",{value:!0}),mf.EntryHandlerKeywordId=void 0;const t=Jr(),e=ss();let u=class extends e.EntryHandlerKeyword{constructor(){super("@id")}isStackProcessor(){return!1}async handle(n,r,a,o,l,c){if(typeof l!="string"){if(n.rdfstar&&typeof l=="object"){const h=Object.keys(l);h.length===1&&h[0]==="@id"&&n.emitError(new t.ErrorCoded(`Invalid embedded node without property with @id ${l["@id"]}`,t.ERROR_CODES.INVALID_EMBEDDED_NODE))}else n.emitError(new t.ErrorCoded(`Found illegal @id '${l}'`,t.ERROR_CODES.INVALID_ID_VALUE));return}const d=await r.getPropertiesDepth(o,c);if(n.idStack[d]!==void 0&&(n.idStack[d][0].listHead?n.emitError(new t.ErrorCoded(`Found illegal neighbouring entries next to @list for key: '${o[c-1]}'`,t.ERROR_CODES.INVALID_SET_OR_LIST_OBJECT)):n.emitError(new t.ErrorCoded(`Found duplicate @ids '${n.idStack[d][0].value}' and '${l}'`,t.ERROR_CODES.COLLIDING_KEYWORDS))),n.rdfstar&&n.annotationsBuffer[c])for(const h of n.annotationsBuffer[c])h.depth===c&&n.emitError(new t.ErrorCoded(`Found an illegal @id inside an annotation: ${l}`,t.ERROR_CODES.INVALID_ANNOTATION));n.idStack[d]=r.nullableTermToArray(await r.resourceToTerm(await n.getContext(o),l))}};return mf.EntryHandlerKeywordId=u,mf}var gf={},EC;function AY(){if(EC)return gf;EC=1,Object.defineProperty(gf,"__esModule",{value:!0}),gf.EntryHandlerKeywordIncluded=void 0;const t=Jr(),e=ss();let u=class extends e.EntryHandlerKeyword{constructor(){super("@included")}async handle(n,r,a,o,l,c){typeof l!="object"&&n.emitError(new t.ErrorCoded(`Found illegal @included '${l}'`,t.ERROR_CODES.INVALID_INCLUDED_VALUE));const d=await r.unaliasKeywords(l,o,c,await n.getContext(o));"@value"in d&&n.emitError(new t.ErrorCoded(`Found an illegal @included @value node '${JSON.stringify(l)}'`,t.ERROR_CODES.INVALID_INCLUDED_VALUE)),"@list"in d&&n.emitError(new t.ErrorCoded(`Found an illegal @included @list node '${JSON.stringify(l)}'`,t.ERROR_CODES.INVALID_INCLUDED_VALUE)),n.emittedStack[c]=!1}};return gf.EntryHandlerKeywordIncluded=u,gf}var _f={},OC;function EY(){if(OC)return _f;OC=1,Object.defineProperty(_f,"__esModule",{value:!0}),_f.EntryHandlerKeywordNest=void 0;const t=Jr(),e=ss();let u=class extends e.EntryHandlerKeyword{constructor(){super("@nest")}async handle(n,r,a,o,l,c){typeof l!="object"&&n.emitError(new t.ErrorCoded(`Found invalid @nest entry for '${a}': '${l}'`,t.ERROR_CODES.INVALID_NEST_VALUE)),"@value"in await r.unaliasKeywords(l,o,c,await n.getContext(o))&&n.emitError(new t.ErrorCoded(`Found an invalid @value node for '${a}'`,t.ERROR_CODES.INVALID_NEST_VALUE)),n.emittedStack[c]=!1}};return _f.EntryHandlerKeywordNest=u,_f}var vf={},RC;function OY(){if(RC)return vf;RC=1,Object.defineProperty(vf,"__esModule",{value:!0}),vf.EntryHandlerKeywordType=void 0;const t=Jr(),e=ro(),u=im(),s=ss();let n=class extends s.EntryHandlerKeyword{constructor(){super("@type")}isStackProcessor(){return!1}async handle(a,o,l,c,d,h){const f=c[h],p=await a.getContext(c),y=o.rdfType,b=await o.unaliasKeywordParent(c,h),g=e.Util.isPropertyReverse(p,f,b),m=e.Util.isPropertyInEmbeddedNode(b);o.validateReverseInEmbeddedNode(l,g,m);const v=e.Util.isPropertyInAnnotationObject(b),_=Array.isArray(d)?d:[d];for(const A of _){typeof A!="string"&&a.emitError(new t.ErrorCoded(`Found illegal @type '${A}'`,t.ERROR_CODES.INVALID_TYPE_VALUE));const D=o.createVocabOrBaseTerm(p,A);D&&await u.EntryHandlerPredicate.handlePredicateObject(a,o,c,h,y,D,g,m,v)}let w=Promise.resolve(p),S=!1;for(const A of _.sort()){const D=e.Util.getContextValue(p,"@context",A,null);D&&(S=!0,w=w.then(L=>a.parseContext(D,L.getContextRaw())))}a.streamingProfile&&(S||!a.streamingProfileAllowOutOfOrderPlainType)&&(a.processingStack[h]||a.idStack[h])&&a.emitError(new t.ErrorCoded("Found an out-of-order type-scoped context, while streaming is enabled.(disable `streamingProfile`)",t.ERROR_CODES.INVALID_STREAMING_KEY_ORDER)),S&&(w=w.then(A=>A.getContextRaw()["@propagate"]!==!0?new t.JsonLdContextNormalized(Object.assign(Object.assign({},A.getContextRaw()),{"@propagate":!1,"@__propagateFallback":p.getContextRaw()})):A),a.contextTree.setContext(c.slice(0,c.length-1),w)),a.processingType[h]=!0}};return vf.EntryHandlerKeywordType=n,vf}var wf={},xC;function RY(){if(xC)return wf;xC=1,Object.defineProperty(wf,"__esModule",{value:!0}),wf.EntryHandlerKeywordUnknownFallback=void 0;const t=Jr();let e=class j7{isPropertyHandler(){return!1}isStackProcessor(){return!0}async validate(s,n,r,a,o){const l=await n.unaliasKeyword(r[a],r,a);return t.Util.isPotentialKeyword(l)?!(!o&&l==="@list"):!1}async test(s,n,r,a,o){return t.Util.isPotentialKeyword(r)}async handle(s,n,r,a,o,l){const c=j7.VALID_KEYWORDS_TYPES[r];c!==void 0?c&&typeof o!==c.type&&s.emitError(new t.ErrorCoded(`Invalid value type for '${r}' with value '${o}'`,c.errorCode)):s.strictValues&&s.emitError(new Error(`Unknown keyword '${r}' with value '${o}'`)),s.emittedStack[l]=!1}};return e.VALID_KEYWORDS_TYPES={"@index":{type:"string",errorCode:t.ERROR_CODES.INVALID_INDEX_VALUE},"@list":null,"@reverse":{type:"object",errorCode:t.ERROR_CODES.INVALID_REVERSE_VALUE},"@set":null,"@value":null},wf.EntryHandlerKeywordUnknownFallback=e,wf}var Sf={},IC;function xY(){if(IC)return Sf;IC=1,Object.defineProperty(Sf,"__esModule",{value:!0}),Sf.EntryHandlerKeywordValue=void 0;const t=ss();let e=class extends t.EntryHandlerKeyword{constructor(){super("@value")}async validate(s,n,r,a,o){const l=r[a];return l&&!s.literalStack[a]&&await this.test(s,n,l,r,a)&&(s.literalStack[a]=!0),super.validate(s,n,r,a,o)}async test(s,n,r,a,o){return await n.unaliasKeyword(a[o],a.slice(0,a.length-1),o-1,!0)==="@value"}async handle(s,n,r,a,o,l){s.literalStack[l]=!0,delete s.unidentifiedValuesBuffer[l],delete s.unidentifiedGraphsBuffer[l],s.emittedStack[l]=!1}};return Sf.EntryHandlerKeywordValue=e,Sf}var Tf={},Af={},PC;function IY(){if(PC)return Af;PC=1,Object.defineProperty(Af,"__esModule",{value:!0}),Af.ContextTree=void 0;let t=class L7{constructor(){this.subTrees={}}getContext(u){if(u.length>0){const[s,...n]=u,r=this.subTrees[s];if(r){const a=r.getContext(n);if(a)return a.then(({context:o,depth:l})=>({context:o,depth:l+1}))}}return this.context?this.context.then(s=>({context:s,depth:0})):null}setContext(u,s){if(u.length===0)this.context=s;else{const[n,...r]=u;let a=this.subTrees[n];a||(a=this.subTrees[n]=new L7),a.setContext(r,s)}}removeContext(u){this.setContext(u,null)}};return Af.ContextTree=t,Af}var DC;function PY(){if(DC)return Tf;DC=1,Object.defineProperty(Tf,"__esModule",{value:!0}),Tf.ParsingContext=void 0;const t=Jr(),e=Py(),u=IY(),s=F7();let n=class M7{constructor(a){this.contextParser=new t.ContextParser({documentLoader:a.documentLoader,skipValidation:a.skipContextValidation}),this.streamingProfile=!!a.streamingProfile,this.baseIRI=a.baseIRI,this.produceGeneralizedRdf=!!a.produceGeneralizedRdf,this.allowSubjectList=!!a.allowSubjectList,this.processingMode=a.processingMode||s.JsonLdParser.DEFAULT_PROCESSING_MODE,this.strictValues=!!a.strictValues,this.validateValueIndexes=!!a.validateValueIndexes,this.defaultGraph=a.defaultGraph,this.rdfDirection=a.rdfDirection,this.normalizeLanguageTags=a.normalizeLanguageTags,this.streamingProfileAllowOutOfOrderPlainType=a.streamingProfileAllowOutOfOrderPlainType,this.rdfstar=a.rdfstar!==!1,this.rdfstarReverseInEmbedded=a.rdfstarReverseInEmbedded,this.topLevelProperties=!1,this.activeProcessingMode=parseFloat(this.processingMode),this.processingStack=[],this.processingType=[],this.emittedStack=[],this.idStack=[],this.graphStack=[],this.graphContainerTermStack=[],this.listPointerStack=[],this.contextTree=new u.ContextTree,this.literalStack=[],this.validationStack=[],this.unaliasedKeywordCacheStack=[],this.jsonLiteralStack=[],this.unidentifiedValuesBuffer=[],this.unidentifiedGraphsBuffer=[],this.annotationsBuffer=[],this.pendingContainerFlushBuffers=[],this.parser=a.parser,a.context?(this.rootContext=this.parseContext(a.context),this.rootContext.then(o=>this.validateContext(o))):this.rootContext=Promise.resolve(new t.JsonLdContextNormalized(this.baseIRI?{"@base":this.baseIRI,"@__baseDocument":!0}:{}))}async parseContext(a,o,l){return this.contextParser.parse(a,{baseIRI:this.baseIRI,ignoreProtection:l,normalizeLanguageTags:this.normalizeLanguageTags,parentContext:o,processingMode:this.activeProcessingMode})}validateContext(a){const o=a.getContextRaw()["@version"];if(o){if(this.activeProcessingMode&&o>this.activeProcessingMode)throw new e.ErrorCoded(`Unsupported JSON-LD version '${o}' under active processing mode ${this.activeProcessingMode}.`,e.ERROR_CODES.PROCESSING_MODE_CONFLICT);if(this.activeProcessingMode&&o0&&l.context.getContextRaw()["@propagate"]===!1&&l.depth!==o&&!c);return l.depth===0&&l.context.getContextRaw()["@propagate"]===!1&&l.depth!==o&&(l.context=new t.JsonLdContextNormalized({})),l}async newOnValueJob(a,o,l,c){await this.parser.newOnValueJob(a,o,l,c)}async handlePendingContainerFlushBuffers(){if(this.pendingContainerFlushBuffers.length>0){for(const a of this.pendingContainerFlushBuffers)await this.parser.flushBuffer(a.depth,a.keys),this.parser.flushStacks(a.depth);return this.pendingContainerFlushBuffers.splice(0,this.pendingContainerFlushBuffers.length),!0}else return!1}emitQuad(a,o){a===1&&(this.topLevelProperties=!0),this.parser.push(o)}emitError(a){this.parser.emit("error",a)}emitContext(a){this.parser.emit("context",a)}getUnidentifiedValueBufferSafe(a){let o=this.unidentifiedValuesBuffer[a];return o||(o=[],this.unidentifiedValuesBuffer[a]=o),o}getUnidentifiedGraphBufferSafe(a){let o=this.unidentifiedGraphsBuffer[a];return o||(o=[],this.unidentifiedGraphsBuffer[a]=o),o}getAnnotationsBufferSafe(a){let o=this.annotationsBuffer[a];return o||(o=[],this.annotationsBuffer[a]=o),o}getExpandOptions(){return M7.EXPAND_OPTIONS[this.activeProcessingMode]}shiftStack(a,o){const l=this.idStack[a+o];if(l&&(this.idStack[a]=l,this.emittedStack[a]=!0,delete this.idStack[a+o]),this.pendingContainerFlushBuffers.length)for(const c of this.pendingContainerFlushBuffers)c.depth>=a+o&&(c.depth-=o,c.keys.splice(a,o));this.unidentifiedValuesBuffer[a+o]&&(this.unidentifiedValuesBuffer[a]=this.unidentifiedValuesBuffer[a+o],delete this.unidentifiedValuesBuffer[a+o]),this.annotationsBuffer[a+o-1]&&(this.annotationsBuffer[a-1]||(this.annotationsBuffer[a-1]=[]),this.annotationsBuffer[a-1]=[...this.annotationsBuffer[a-1],...this.annotationsBuffer[a+o-1]],delete this.annotationsBuffer[a+o-1])}};return n.EXPAND_OPTIONS={1:{allowPrefixForcing:!1,allowPrefixNonGenDelims:!1,allowVocabRelativeToBase:!1},1.1:{allowPrefixForcing:!0,allowPrefixNonGenDelims:!1,allowVocabRelativeToBase:!0}},Tf.ParsingContext=n,Tf}var Ef={},NC;function DY(){if(NC)return Ef;NC=1,Object.defineProperty(Ef,"__esModule",{value:!0}),Ef.EntryHandlerKeywordAnnotation=void 0;const t=ss(),e=Jr();let u=class extends t.EntryHandlerKeyword{constructor(){super("@annotation")}async handle(n,r,a,o,l,c){(typeof l=="string"||typeof l=="object"&&l["@value"])&&n.emitError(new e.ErrorCoded(`Found illegal annotation value: ${JSON.stringify(l)}`,e.ERROR_CODES.INVALID_ANNOTATION))}};return Ef.EntryHandlerKeywordAnnotation=u,Ef}var CC;function F7(){if(CC)return nf;CC=1,Object.defineProperty(nf,"__esModule",{value:!0}),nf.JsonLdParser=void 0;const t=Gq(),e=Jr(),u=Wt(),s=_Y(),n=C7(),r=vY(),a=im(),o=wY(),l=SY(),c=TY(),d=AY(),h=EY(),f=OY(),p=RY(),y=xY(),b=PY(),g=ro(),m=Nq(),v=DY();let _=class So extends u.Transform{constructor(S){super({readableObjectMode:!0}),S=S||{},this.options=S,this.parsingContext=new b.ParsingContext(Object.assign({parser:this},S)),this.util=new g.Util({dataFactory:S.dataFactory,parsingContext:this.parsingContext}),this.jsonParser=new t,this.contextJobs=[],this.typeJobs=[],this.contextAwaitingJobs=[],this.lastDepth=0,this.lastKeys=[],this.lastOnValueJob=Promise.resolve(),this.attachJsonParserListeners(),this.on("end",()=>{typeof this.jsonParser.mode<"u"&&this.emit("error",new Error("Unclosed document"))})}static fromHttpResponse(S,A,D,L){let O,E=["application/activity+json"];if(L&&L.wellKnownMediaTypes&&(E=L.wellKnownMediaTypes),A!=="application/ld+json"&&!E.includes(A)){if(A!=="application/json"&&!A.endsWith("+json"))throw new e.ErrorCoded(`Unsupported JSON-LD media type ${A}`,e.ERROR_CODES.LOADING_DOCUMENT_FAILED);if(D&&D.has("Link")&&D.forEach((M,U)=>{if(U==="link"){const j=(0,m.parse)(M);for(const q of j.get("rel","http://www.w3.org/ns/json-ld#context")){if(O)throw new e.ErrorCoded("Multiple JSON-LD context link headers were found on "+S,e.ERROR_CODES.MULTIPLE_CONTEXT_LINK_HEADERS);O=q.uri}}}),!O&&!(L!=null&&L.ignoreMissingContextLinkHeader))throw new e.ErrorCoded(`Missing context link header for media type ${A} on ${S}`,e.ERROR_CODES.LOADING_DOCUMENT_FAILED)}let P;if(D&&D.has("Content-Type")){const M=D.get("Content-Type"),U=/; *profile=([^"]*)/.exec(M);U&&U[1]==="http://www.w3.org/ns/json-ld#streaming"&&(P=!0)}return new So(Object.assign({baseIRI:S,context:O,streamingProfile:P},L||{}))}import(S){if("pipe"in S){S.on("error",D=>A.emit("error",D));const A=S.pipe(new So(this.options));return A}else{const A=new u.PassThrough({readableObjectMode:!0});S.on("error",L=>D.emit("error",L)),S.on("data",L=>A.push(L)),S.on("end",()=>A.push(null));const D=A.pipe(new So(this.options));return D}}_transform(S,A,D){this.jsonParser.write(S),this.lastOnValueJob.then(()=>D(),L=>D(L))}async newOnValueJob(S,A,D,L){let O=!0;if(L&&D1&&(U=this.parsingContext.validationStack[this.parsingContext.validationStack.length-1].property);for(let j=Math.max(1,this.parsingContext.validationStack.length-1);j=0?this.parsingContext.idStack[S-U-1]:[await this.util.getGraphContainerValue(A,S)];if(j)for(const q of j){this.parsingContext.emittedStack[S]=!0;for(const $ of O)this.util.emitQuadChecked(S,M,$.predicate,$.object,q,$.reverse,$.isEmbedded)}else{const q=this.parsingContext.getUnidentifiedGraphBufferSafe(S-await this.util.getDepthOffsetGraph(S,A)-1);for(const $ of O)$.reverse?q.push({object:M,predicate:$.predicate,subject:$.object,isEmbedded:$.isEmbedded}):q.push({object:$.object,predicate:$.predicate,subject:M,isEmbedded:$.isEmbedded})}}this.parsingContext.unidentifiedValuesBuffer.splice(S,1),this.parsingContext.literalStack.splice(S,1),this.parsingContext.jsonLiteralStack.splice(S,1)}const E=this.parsingContext.unidentifiedGraphsBuffer[S];if(E){for(const M of D){const U=S===1&&M.termType==="BlankNode"&&!this.parsingContext.topLevelProperties?this.util.getDefaultGraph():M;this.parsingContext.emittedStack[S]=!0;for(const j of E)this.parsingContext.emitQuad(S,this.util.dataFactory.quad(j.subject,j.predicate,j.object,U))}this.parsingContext.unidentifiedGraphsBuffer.splice(S,1)}const P=this.parsingContext.annotationsBuffer[S];if(P){P.length>0&&S===1&&this.parsingContext.emitError(new e.ErrorCoded("Annotations can not be made on top-level nodes",e.ERROR_CODES.INVALID_ANNOTATION));const M=this.parsingContext.getAnnotationsBufferSafe(S-1);for(const U of P)M.push(U);delete this.parsingContext.annotationsBuffer[S]}}async validateKey(S,A,D){for(const L of So.ENTRY_HANDLERS)if(await L.validate(this.parsingContext,this.util,S,A,D))return{valid:!0,property:D||L.isPropertyHandler()};return{valid:!1,property:!1}}attachJsonParserListeners(){this.jsonParser.onValue=S=>{const A=this.jsonParser.stack.length,D=new Array(A+1).fill(0).map((L,O)=>O===A?this.jsonParser.key:this.jsonParser.stack[O].key);if(!this.isParsingContextInner(A)){const L=()=>this.newOnValueJob(D,S,A,!0);if(!this.parsingContext.streamingProfile&&!this.parsingContext.contextTree.getContext(D.slice(0,-1)))if(D[A]==="@context"){let O=this.contextJobs[A];O||(O=this.contextJobs[A]=[]),O.push(L)}else this.contextAwaitingJobs.push({job:L,keys:D,depth:A});else this.lastOnValueJob=this.lastOnValueJob.then(L);!this.parsingContext.streamingProfile&&A===0&&(this.lastOnValueJob=this.lastOnValueJob.then(()=>this.executeBufferedJobs()))}},this.jsonParser.onError=S=>{this.emit("error",S)}}isParsingContextInner(S){for(let A=S;A>0;A--)if(this.jsonParser.stack[A-1].key==="@context")return!0;return!1}async executeBufferedJobs(){for(const A of this.contextJobs)if(A)for(const D of A)await D();this.parsingContext.unaliasedKeywordCacheStack.splice(0);const S=[];for(const A of this.contextAwaitingJobs)await this.util.unaliasKeyword(A.keys[A.depth],A.keys,A.depth,!0)==="@type"||typeof A.keys[A.depth]=="number"&&await this.util.unaliasKeyword(A.keys[A.depth-1],A.keys,A.depth-1,!0)==="@type"?this.typeJobs.push({job:A.job,keys:A.keys.slice(0,A.keys.length-1)}):S.push(A);for(const A of S){if(this.typeJobs.length>0){const D=[],L=[];for(let P=0;PP.keys.length-M.keys.length);for(const P of O)await P.job();const E=L.sort().reverse();for(const P of E)this.typeJobs.splice(P,1)}await A.job()}}};return _.DEFAULT_PROCESSING_MODE="1.1",_.ENTRY_HANDLERS=[new s.EntryHandlerArrayValue,new o.EntryHandlerKeywordContext,new c.EntryHandlerKeywordId,new d.EntryHandlerKeywordIncluded,new l.EntryHandlerKeywordGraph,new h.EntryHandlerKeywordNest,new f.EntryHandlerKeywordType,new y.EntryHandlerKeywordValue,new v.EntryHandlerKeywordAnnotation,new n.EntryHandlerContainer,new p.EntryHandlerKeywordUnknownFallback,new a.EntryHandlerPredicate,new r.EntryHandlerInvalidFallback],nf.JsonLdParser=_,nf}var jC;function NY(){return jC||(jC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(F7(),t)}(s2)),s2}var Of={},LC;function B7(){if(LC)return Of;LC=1,Object.defineProperty(Of,"__esModule",{value:!0}),Of.DocumentLoaderMediated=void 0;const t=as(),e=ou(),u=Jr();let s=class q7 extends u.FetchDocumentLoader{constructor(r,a){super(q7.createFetcher(r,a)),this.mediatorHttp=r,this.context=a}static createFetcher(r,a){return async(o,l)=>{const c=await r.mediate({input:o,init:l,context:a});return c.json=async()=>JSON.parse(await(0,e.stringify)(t.ActorHttp.toNodeReadable(c.body))),c}}};return Of.DocumentLoaderMediated=s,Of}var MC;function CY(){if(MC)return rf;MC=1,Object.defineProperty(rf,"__esModule",{value:!0}),rf.ActorRdfParseJsonLd=void 0;const t=su(),e=Lt,u=NY(),s=B7();let n=class extends t.ActorRdfParseFixedMediaTypes{constructor(a){super(a)}async testHandle(a,o,l){if(l.has(e.KeysRdfParseHtmlScript.processingHtmlScript)&&o!=="application/ld+json")throw new Error("JSON-LD in script tags can only have media type 'application/ld+json'");if(!o||!(o in this.mediaTypePriorities||o.endsWith("+json")))throw new Error(`Unrecognized media type: ${o}`);return await this.testHandleChecked(a)}async runHandle(a,o,l){var h;return{data:u.JsonLdParser.fromHttpResponse(((h=a.metadata)==null?void 0:h.baseIRI)??"",o,a.headers,{documentLoader:l.get(e.KeysRdfParseJsonLd.documentLoader)??new s.DocumentLoaderMediated(this.mediatorHttp,l),strictValues:l.get(e.KeysRdfParseJsonLd.strictValues),...l.get(e.KeysRdfParseJsonLd.parserOptions)}).import(a.data)}}};return rf.ActorRdfParseJsonLd=n,rf}var FC;function jY(){return FC||(FC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(CY(),t),u(B7(),t)}(a2)),a2}var u2={},Rf={},c2={},xf={},qC;function LY(){if(qC)return xf;qC=1,Object.defineProperty(xf,"__esModule",{value:!0}),xf.ActorRdfUpdateHypermedia=void 0;const t=ot;let e=class extends t.Actor{constructor(s,n){super(s),this.destinationType=n}async test(s){if(s.forceDestinationType&&this.destinationType!==s.forceDestinationType)throw new Error(`Actor ${this.name} is not able to handle destination type ${s.forceDestinationType}.`);return this.testMetadata(s)}};return xf.ActorRdfUpdateHypermedia=e,xf}var BC;function fA(){return BC||(BC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(LY(),t)}(c2)),c2}var If={},j1={exports:{}},UC;function hA(){return UC||(UC=1,function(t,e){var u=typeof globalThis<"u"&&globalThis||typeof self<"u"&&self||typeof I<"u"&&I,s=function(){function r(){this.fetch=!1,this.DOMException=u.DOMException}return r.prototype=u,new r}();(function(r){(function(a){var o=typeof r<"u"&&r||typeof self<"u"&&self||typeof o<"u"&&o,l={searchParams:"URLSearchParams"in o,iterable:"Symbol"in o&&"iterator"in Symbol,blob:"FileReader"in o&&"Blob"in o&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in o,arrayBuffer:"ArrayBuffer"in o};function c(q){return q&&DataView.prototype.isPrototypeOf(q)}if(l.arrayBuffer)var d=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],h=ArrayBuffer.isView||function(q){return q&&d.indexOf(Object.prototype.toString.call(q))>-1};function f(q){if(typeof q!="string"&&(q=String(q)),/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(q)||q==="")throw new TypeError('Invalid character in header field name: "'+q+'"');return q.toLowerCase()}function p(q){return typeof q!="string"&&(q=String(q)),q}function y(q){var $={next:function(){var Z=q.shift();return{done:Z===void 0,value:Z}}};return l.iterable&&($[Symbol.iterator]=function(){return $}),$}function b(q){this.map={},q instanceof b?q.forEach(function($,Z){this.append(Z,$)},this):Array.isArray(q)?q.forEach(function($){this.append($[0],$[1])},this):q&&Object.getOwnPropertyNames(q).forEach(function($){this.append($,q[$])},this)}b.prototype.append=function(q,$){q=f(q),$=p($);var Z=this.map[q];this.map[q]=Z?Z+", "+$:$},b.prototype.delete=function(q){delete this.map[f(q)]},b.prototype.get=function(q){return q=f(q),this.has(q)?this.map[q]:null},b.prototype.has=function(q){return this.map.hasOwnProperty(f(q))},b.prototype.set=function(q,$){this.map[f(q)]=p($)},b.prototype.forEach=function(q,$){for(var Z in this.map)this.map.hasOwnProperty(Z)&&q.call($,this.map[Z],Z,this)},b.prototype.keys=function(){var q=[];return this.forEach(function($,Z){q.push(Z)}),y(q)},b.prototype.values=function(){var q=[];return this.forEach(function($){q.push($)}),y(q)},b.prototype.entries=function(){var q=[];return this.forEach(function($,Z){q.push([Z,$])}),y(q)},l.iterable&&(b.prototype[Symbol.iterator]=b.prototype.entries);function g(q){if(q.bodyUsed)return Promise.reject(new TypeError("Already read"));q.bodyUsed=!0}function m(q){return new Promise(function($,Z){q.onload=function(){$(q.result)},q.onerror=function(){Z(q.error)}})}function v(q){var $=new FileReader,Z=m($);return $.readAsArrayBuffer(q),Z}function _(q){var $=new FileReader,Z=m($);return $.readAsText(q),Z}function w(q){for(var $=new Uint8Array(q),Z=new Array($.length),X=0;X<$.length;X++)Z[X]=String.fromCharCode($[X]);return Z.join("")}function S(q){if(q.slice)return q.slice(0);var $=new Uint8Array(q.byteLength);return $.set(new Uint8Array(q)),$.buffer}function A(){return this.bodyUsed=!1,this._initBody=function(q){this.bodyUsed=this.bodyUsed,this._bodyInit=q,q?typeof q=="string"?this._bodyText=q:l.blob&&Blob.prototype.isPrototypeOf(q)?this._bodyBlob=q:l.formData&&FormData.prototype.isPrototypeOf(q)?this._bodyFormData=q:l.searchParams&&URLSearchParams.prototype.isPrototypeOf(q)?this._bodyText=q.toString():l.arrayBuffer&&l.blob&&c(q)?(this._bodyArrayBuffer=S(q.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):l.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(q)||h(q))?this._bodyArrayBuffer=S(q):this._bodyText=q=Object.prototype.toString.call(q):this._bodyText="",this.headers.get("content-type")||(typeof q=="string"?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):l.searchParams&&URLSearchParams.prototype.isPrototypeOf(q)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},l.blob&&(this.blob=function(){var q=g(this);if(q)return q;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){if(this._bodyArrayBuffer){var q=g(this);return q||(ArrayBuffer.isView(this._bodyArrayBuffer)?Promise.resolve(this._bodyArrayBuffer.buffer.slice(this._bodyArrayBuffer.byteOffset,this._bodyArrayBuffer.byteOffset+this._bodyArrayBuffer.byteLength)):Promise.resolve(this._bodyArrayBuffer))}else return this.blob().then(v)}),this.text=function(){var q=g(this);if(q)return q;if(this._bodyBlob)return _(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(w(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},l.formData&&(this.formData=function(){return this.text().then(E)}),this.json=function(){return this.text().then(JSON.parse)},this}var D=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function L(q){var $=q.toUpperCase();return D.indexOf($)>-1?$:q}function O(q,$){if(!(this instanceof O))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');$=$||{};var Z=$.body;if(q instanceof O){if(q.bodyUsed)throw new TypeError("Already read");this.url=q.url,this.credentials=q.credentials,$.headers||(this.headers=new b(q.headers)),this.method=q.method,this.mode=q.mode,this.signal=q.signal,!Z&&q._bodyInit!=null&&(Z=q._bodyInit,q.bodyUsed=!0)}else this.url=String(q);if(this.credentials=$.credentials||this.credentials||"same-origin",($.headers||!this.headers)&&(this.headers=new b($.headers)),this.method=L($.method||this.method||"GET"),this.mode=$.mode||this.mode||null,this.signal=$.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&Z)throw new TypeError("Body not allowed for GET or HEAD requests");if(this._initBody(Z),(this.method==="GET"||this.method==="HEAD")&&($.cache==="no-store"||$.cache==="no-cache")){var X=/([?&])_=[^&]*/;if(X.test(this.url))this.url=this.url.replace(X,"$1_="+new Date().getTime());else{var le=/\?/;this.url+=(le.test(this.url)?"&":"?")+"_="+new Date().getTime()}}}O.prototype.clone=function(){return new O(this,{body:this._bodyInit})};function E(q){var $=new FormData;return q.trim().split("&").forEach(function(Z){if(Z){var X=Z.split("="),le=X.shift().replace(/\+/g," "),K=X.join("=").replace(/\+/g," ");$.append(decodeURIComponent(le),decodeURIComponent(K))}}),$}function P(q){var $=new b,Z=q.replace(/\r?\n[\t ]+/g," ");return Z.split("\r").map(function(X){return X.indexOf(` +`)===0?X.substr(1,X.length):X}).forEach(function(X){var le=X.split(":"),K=le.shift().trim();if(K){var he=le.join(":").trim();$.append(K,he)}}),$}A.call(O.prototype);function M(q,$){if(!(this instanceof M))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');$||($={}),this.type="default",this.status=$.status===void 0?200:$.status,this.ok=this.status>=200&&this.status<300,this.statusText=$.statusText===void 0?"":""+$.statusText,this.headers=new b($.headers),this.url=$.url||"",this._initBody(q)}A.call(M.prototype),M.prototype.clone=function(){return new M(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new b(this.headers),url:this.url})},M.error=function(){var q=new M(null,{status:0,statusText:""});return q.type="error",q};var U=[301,302,303,307,308];M.redirect=function(q,$){if(U.indexOf($)===-1)throw new RangeError("Invalid status code");return new M(null,{status:$,headers:{location:q}})},a.DOMException=o.DOMException;try{new a.DOMException}catch{a.DOMException=function($,Z){this.message=$,this.name=Z;var X=Error($);this.stack=X.stack},a.DOMException.prototype=Object.create(Error.prototype),a.DOMException.prototype.constructor=a.DOMException}function j(q,$){return new Promise(function(Z,X){var le=new O(q,$);if(le.signal&&le.signal.aborted)return X(new a.DOMException("Aborted","AbortError"));var K=new XMLHttpRequest;function he(){K.abort()}K.onload=function(){var ie={status:K.status,statusText:K.statusText,headers:P(K.getAllResponseHeaders()||"")};ie.url="responseURL"in K?K.responseURL:ie.headers.get("X-Request-URL");var ae="response"in K?K.response:K.responseText;setTimeout(function(){Z(new M(ae,ie))},0)},K.onerror=function(){setTimeout(function(){X(new TypeError("Network request failed"))},0)},K.ontimeout=function(){setTimeout(function(){X(new TypeError("Network request failed"))},0)},K.onabort=function(){setTimeout(function(){X(new a.DOMException("Aborted","AbortError"))},0)};function Re(ie){try{return ie===""&&o.location.href?o.location.href:ie}catch{return ie}}K.open(le.method,Re(le.url),!0),le.credentials==="include"?K.withCredentials=!0:le.credentials==="omit"&&(K.withCredentials=!1),"responseType"in K&&(l.blob?K.responseType="blob":l.arrayBuffer&&le.headers.get("Content-Type")&&le.headers.get("Content-Type").indexOf("application/octet-stream")!==-1&&(K.responseType="arraybuffer")),$&&typeof $.headers=="object"&&!($.headers instanceof b)?Object.getOwnPropertyNames($.headers).forEach(function(ie){K.setRequestHeader(ie,p($.headers[ie]))}):le.headers.forEach(function(ie,ae){K.setRequestHeader(ae,ie)}),le.signal&&(le.signal.addEventListener("abort",he),K.onreadystatechange=function(){K.readyState===4&&le.signal.removeEventListener("abort",he)}),K.send(typeof le._bodyInit>"u"?null:le._bodyInit)})}return j.polyfill=!0,o.fetch||(o.fetch=j,o.Headers=b,o.Request=O,o.Response=M),a.Headers=b,a.Request=O,a.Response=M,a.fetch=j,a})({})})(s),s.fetch.ponyfill=!0,delete s.fetch.polyfill;var n=u.fetch?u:s;e=n.fetch,e.default=n.fetch,e.fetch=n.fetch,e.Headers=n.Headers,e.Request=n.Request,e.Response=n.Response,t.exports=e}(j1,j1.exports)),j1.exports}var QC;function U7(){if(QC)return If;QC=1,Object.defineProperty(If,"__esModule",{value:!0}),If.QuadDestinationPatchSparqlUpdate=void 0;const t=as(),e=hA(),u=Ny(),s=Wt();let n=class{constructor(a,o,l){this.url=a,this.context=o,this.mediatorHttp=l}insert(a){return this.wrapSparqlUpdateRequest("INSERT",a)}async delete(a){return this.wrapSparqlUpdateRequest("DELETE",a)}async wrapSparqlUpdateRequest(a,o){const l=o.map(f=>{let p=`${(0,u.termToString)(f.subject)} ${(0,u.termToString)(f.predicate)} ${(0,u.termToString)(f.object)} .`;return f.graph.termType==="DefaultGraph"?p=` ${p} +`:p=` GRAPH ${(0,u.termToString)(f.graph)} { ${p} } +`,p}).prepend([`${a} DATA { +`]).append(["}"]),c=new s.Readable;c.wrap(l);const d=new e.Headers({"content-type":"application/sparql-update"}),h=await this.mediatorHttp.mediate({context:this.context,init:{headers:d,method:"PATCH",body:t.ActorHttp.toWebReadableStream(c)},input:this.url});await(0,t.validateAndCloseHttpResponse)(this.url,h)}async deleteGraphs(a,o,l){throw new Error("Patch-based SPARQL Update destinations don't support named graphs")}async createGraphs(a,o){throw new Error("Patch-based SPARQL Update destinations don't support named graphs")}};return If.QuadDestinationPatchSparqlUpdate=n,If}var HC;function MY(){if(HC)return Rf;HC=1,Object.defineProperty(Rf,"__esModule",{value:!0}),Rf.ActorRdfUpdateHypermediaPatchSparqlUpdate=void 0;const t=fA(),e=U7();let u=class extends t.ActorRdfUpdateHypermedia{constructor(n){super(n,"patchSparqlUpdate")}async testMetadata(n){if(!n.forceDestinationType&&!n.metadata.patchSparqlUpdate)throw new Error(`Actor ${this.name} could not detect a destination with 'application/sparql-update' as 'Accept-Patch' header.`);if(!n.forceDestinationType&&!n.exists)throw new Error(`Actor ${this.name} can only patch a destination that already exists.`);return!0}async run(n){return this.logInfo(n.context,`Identified as patchSparqlUpdate destination: ${n.url}`),{destination:new e.QuadDestinationPatchSparqlUpdate(n.url,n.context,this.mediatorHttp)}}};return Rf.ActorRdfUpdateHypermediaPatchSparqlUpdate=u,Rf}var $C;function FY(){return $C||($C=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(MY(),t),u(U7(),t)}(u2)),u2}var l2={},Pf={},Df={},VC;function Q7(){if(VC)return Df;VC=1,Object.defineProperty(Df,"__esModule",{value:!0}),Df.QuadDestinationPutLdp=void 0;const t=as(),e=hA();let u=class{constructor(n,r,a,o,l,c){this.url=n,this.context=r,this.mediaTypes=a,this.mediatorHttp=o,this.mediatorRdfSerializeMediatypes=l,this.mediatorRdfSerialize=c}insert(n){return this.wrapRdfUpdateRequest("INSERT",n)}async delete(n){throw new Error("Put-based LDP destinations don't support deletions")}async wrapRdfUpdateRequest(n,r){const{mediaTypes:a}=await this.mediatorRdfSerializeMediatypes.mediate({context:this.context,mediaTypes:!0}),o=this.mediaTypes.filter(f=>f in a),l=o.length>0?o[0]:Object.keys(a).sort((f,p)=>a[p]-a[f])[0],{handle:{data:c}}=await this.mediatorRdfSerialize.mediate({context:this.context,handle:{quadStream:r,context:this.context},handleMediaType:l}),d=new e.Headers({"content-type":l}),h=await this.mediatorHttp.mediate({context:this.context,init:{headers:d,method:"PUT",body:t.ActorHttp.toWebReadableStream(c)},input:this.url});await(0,t.validateAndCloseHttpResponse)(this.url,h)}async deleteGraphs(n,r,a){throw new Error("Put-based LDP destinations don't support named graphs")}async createGraphs(n,r){throw new Error("Put-based LDP destinations don't support named graphs")}};return Df.QuadDestinationPutLdp=u,Df}var kC;function qY(){if(kC)return Pf;kC=1,Object.defineProperty(Pf,"__esModule",{value:!0}),Pf.ActorRdfUpdateHypermediaPutLdp=void 0;const t=fA(),e=Q7();let u=class extends t.ActorRdfUpdateHypermedia{constructor(n){super(n,"putLdp")}async testMetadata(n){if(!n.forceDestinationType){if(!n.metadata.allowHttpMethods||!n.metadata.allowHttpMethods.includes("PUT"))throw new Error(`Actor ${this.name} could not detect a destination with 'Allow: PUT' header.`);if(n.exists)throw new Error(`Actor ${this.name} can only put on a destination that does not already exists.`)}return!0}async run(n){return this.logInfo(n.context,`Identified as putLdp destination: ${n.url}`),{destination:new e.QuadDestinationPutLdp(n.url,n.context,n.metadata.putAccepted||[],this.mediatorHttp,this.mediatorRdfSerializeMediatypes,this.mediatorRdfSerialize)}}};return Pf.ActorRdfUpdateHypermediaPutLdp=u,Pf}var zC;function BY(){return zC||(zC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(qY(),t),u(Q7(),t)}(l2)),l2}var d2={},Nf={},Cf={},f2={},jf={},GC={},WC;function UY(){return WC||(WC=1,function(){(function(t){(function(e){var u={searchParams:"URLSearchParams"in t,iterable:"Symbol"in t&&"iterator"in Symbol,blob:"FileReader"in t&&"Blob"in t&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in t,arrayBuffer:"ArrayBuffer"in t};function s(O){return O&&DataView.prototype.isPrototypeOf(O)}if(u.arrayBuffer)var n=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],r=ArrayBuffer.isView||function(O){return O&&n.indexOf(Object.prototype.toString.call(O))>-1};function a(O){if(typeof O!="string"&&(O=String(O)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(O))throw new TypeError("Invalid character in header field name");return O.toLowerCase()}function o(O){return typeof O!="string"&&(O=String(O)),O}function l(O){var E={next:function(){var P=O.shift();return{done:P===void 0,value:P}}};return u.iterable&&(E[Symbol.iterator]=function(){return E}),E}function c(O){this.map={},O instanceof c?O.forEach(function(E,P){this.append(P,E)},this):Array.isArray(O)?O.forEach(function(E){this.append(E[0],E[1])},this):O&&Object.getOwnPropertyNames(O).forEach(function(E){this.append(E,O[E])},this)}c.prototype.append=function(O,E){O=a(O),E=o(E);var P=this.map[O];this.map[O]=P?P+", "+E:E},c.prototype.delete=function(O){delete this.map[a(O)]},c.prototype.get=function(O){return O=a(O),this.has(O)?this.map[O]:null},c.prototype.has=function(O){return this.map.hasOwnProperty(a(O))},c.prototype.set=function(O,E){this.map[a(O)]=o(E)},c.prototype.forEach=function(O,E){for(var P in this.map)this.map.hasOwnProperty(P)&&O.call(E,this.map[P],P,this)},c.prototype.keys=function(){var O=[];return this.forEach(function(E,P){O.push(P)}),l(O)},c.prototype.values=function(){var O=[];return this.forEach(function(E){O.push(E)}),l(O)},c.prototype.entries=function(){var O=[];return this.forEach(function(E,P){O.push([P,E])}),l(O)},u.iterable&&(c.prototype[Symbol.iterator]=c.prototype.entries);function d(O){if(O.bodyUsed)return Promise.reject(new TypeError("Already read"));O.bodyUsed=!0}function h(O){return new Promise(function(E,P){O.onload=function(){E(O.result)},O.onerror=function(){P(O.error)}})}function f(O){var E=new FileReader,P=h(E);return E.readAsArrayBuffer(O),P}function p(O){var E=new FileReader,P=h(E);return E.readAsText(O),P}function y(O){for(var E=new Uint8Array(O),P=new Array(E.length),M=0;M-1?E:O}function _(O,E){E=E||{};var P=E.body;if(O instanceof _){if(O.bodyUsed)throw new TypeError("Already read");this.url=O.url,this.credentials=O.credentials,E.headers||(this.headers=new c(O.headers)),this.method=O.method,this.mode=O.mode,this.signal=O.signal,!P&&O._bodyInit!=null&&(P=O._bodyInit,O.bodyUsed=!0)}else this.url=String(O);if(this.credentials=E.credentials||this.credentials||"same-origin",(E.headers||!this.headers)&&(this.headers=new c(E.headers)),this.method=v(E.method||this.method||"GET"),this.mode=E.mode||this.mode||null,this.signal=E.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&P)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(P)}_.prototype.clone=function(){return new _(this,{body:this._bodyInit})};function w(O){var E=new FormData;return O.trim().split("&").forEach(function(P){if(P){var M=P.split("="),U=M.shift().replace(/\+/g," "),j=M.join("=").replace(/\+/g," ");E.append(decodeURIComponent(U),decodeURIComponent(j))}}),E}function S(O){var E=new c,P=O.replace(/\r?\n[\t ]+/g," ");return P.split(/\r?\n/).forEach(function(M){var U=M.split(":"),j=U.shift().trim();if(j){var q=U.join(":").trim();E.append(j,q)}}),E}g.call(_.prototype);function A(O,E){E||(E={}),this.type="default",this.status=E.status===void 0?200:E.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in E?E.statusText:"OK",this.headers=new c(E.headers),this.url=E.url||"",this._initBody(O)}g.call(A.prototype),A.prototype.clone=function(){return new A(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new c(this.headers),url:this.url})},A.error=function(){var O=new A(null,{status:0,statusText:""});return O.type="error",O};var D=[301,302,303,307,308];A.redirect=function(O,E){if(D.indexOf(E)===-1)throw new RangeError("Invalid status code");return new A(null,{status:E,headers:{location:O}})},e.DOMException=t.DOMException;try{new e.DOMException}catch{e.DOMException=function(E,P){this.message=E,this.name=P;var M=Error(E);this.stack=M.stack},e.DOMException.prototype=Object.create(Error.prototype),e.DOMException.prototype.constructor=e.DOMException}function L(O,E){return new Promise(function(P,M){var U=new _(O,E);if(U.signal&&U.signal.aborted)return M(new e.DOMException("Aborted","AbortError"));var j=new XMLHttpRequest;function q(){j.abort()}j.onload=function(){var $={status:j.status,statusText:j.statusText,headers:S(j.getAllResponseHeaders()||"")};$.url="responseURL"in j?j.responseURL:$.headers.get("X-Request-URL");var Z="response"in j?j.response:j.responseText;P(new A(Z,$))},j.onerror=function(){M(new TypeError("Network request failed"))},j.ontimeout=function(){M(new TypeError("Network request failed"))},j.onabort=function(){M(new e.DOMException("Aborted","AbortError"))},j.open(U.method,U.url,!0),U.credentials==="include"?j.withCredentials=!0:U.credentials==="omit"&&(j.withCredentials=!1),"responseType"in j&&u.blob&&(j.responseType="blob"),U.headers.forEach(function($,Z){j.setRequestHeader(Z,$)}),U.signal&&(U.signal.addEventListener("abort",q),j.onreadystatechange=function(){j.readyState===4&&U.signal.removeEventListener("abort",q)}),j.send(typeof U._bodyInit>"u"?null:U._bodyInit)})}return L.polyfill=!0,t.fetch||(t.fetch=L,t.Headers=c,t.Request=_,t.Response=A),e.Headers=c,e.Request=_,e.Response=A,e.fetch=L,Object.defineProperty(e,"__esModule",{value:!0}),e})({})})(typeof self<"u"?self:I)}()),GC}var h2={},Lf={},JC;function QY(){if(JC)return Lf;JC=1,Object.defineProperty(Lf,"__esModule",{value:!0}),Lf.SparqlXmlParser=void 0;const t=Et(),e=o7(),u=Wt();let s=class{constructor(r){r=r||{},this.dataFactory=r.dataFactory||new t.DataFactory,this.prefixVariableQuestionMark=!!r.prefixVariableQuestionMark}parseXmlResultsStream(r){const a=_=>v.emit("error",_);r.on("error",a);const o=new e.SaxesParser,l=[];let c=!1,d=!1;const h=[];let f={},p="",y="",b,g="",m=[];o.on("error",a),o.on("opentag",_=>{_.name==="variable"&&this.stackEquals(l,["sparql","head"])?h.push(this.dataFactory.variable(_.attributes.name)):_.name==="results"&&this.stackEquals(l,["sparql"])?d=!0:_.name==="result"&&this.stackEquals(l,["sparql","results"])?f={}:_.name==="binding"&&this.stackEquals(l,["sparql","results","result"])?(p=_.attributes.name||"",y="",b="",g="",m=[]):_.name==="triple"&&this.stackBeginsWith(l,["sparql","results","result"])?m.push({components:{}}):l[l.length-1]==="triple"&&this.stackBeginsWith(l,["sparql","results","result","binding"])?(y="",b="",g="",["subject","predicate","object"].includes(_.name)?m[m.length-1].currentComponent=_.name:a(new Error(`Illegal quoted triple component '${_.name}' found on line ${o.line+1}`))):this.stackBeginsWith(l,["sparql","results","result","binding"])&&(y=_.name,"xml:lang"in _.attributes?b=_.attributes["xml:lang"]:"datatype"in _.attributes?b=this.dataFactory.namedNode(_.attributes.datatype):b=void 0),l.push(_.name)}),o.on("closetag",_=>{if(this.stackEquals(l,["sparql","head"])&&(v.emit("variables",h),c=!0),this.stackEquals(l,["sparql","results","result"])&&v.push(f),this.stackBeginsWith(l,["sparql","results","result","binding"])){let w;if(!p&&y)a(new Error(`Terms should have a name on line ${o.line+1}`));else if(y==="uri")w=this.dataFactory.namedNode(g);else if(y==="bnode")w=this.dataFactory.blankNode(g);else if(y==="literal")w=this.dataFactory.literal(g,b);else if(l[l.length-1]==="triple"){const S=m.pop();S&&S.components.subject&&S.components.predicate&&S.components.object?w=this.dataFactory.quad(S.components.subject,S.components.predicate,S.components.object):a(new Error(`Incomplete quoted triple on line ${o.line+1}`))}else y&&a(new Error(`Invalid term type '${y}' on line ${o.line+1}`));if(w)if(m.length>0){const S=m[m.length-1];S.components[S.currentComponent]&&a(new Error(`The ${S.currentComponent} in a quoted triple on line ${o.line+1} was already defined before`)),S.components[S.currentComponent]=w}else{const S=this.prefixVariableQuestionMark?"?"+p:p;f[S]=w}y=void 0}l.pop()}),o.on("text",_=>{this.stackBeginsWith(l,["sparql","results","result","binding"])&&l[l.length-1]===y&&(g=_)});const v=r.on("end",_=>{d?c||v.emit("variables",[]):v.emit("error",new Error("No valid SPARQL query results were found."))}).pipe(new u.Transform({objectMode:!0,transform(_,w,S){o.write(_),S()}}));return v}parseXmlBooleanStream(r){return new Promise((a,o)=>{const l=new e.SaxesParser,c=[];l.on("error",o),l.on("opentag",d=>{c.push(d.name)}),l.on("closetag",d=>{c.pop()}),l.on("text",d=>{this.stackEquals(c,["sparql","boolean"])&&a(d==="true")}),r.on("error",o).on("data",d=>l.write(d)).on("end",()=>o(new Error("No valid ASK response was found.")))})}stackEquals(r,a){return r.length===a.length&&r.every((o,l)=>a[l]===o)}stackBeginsWith(r,a){return r.length>=a.length&&a.every((o,l)=>r[l]===o)}};return Lf.SparqlXmlParser=s,Lf}var XC;function HY(){return XC||(XC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(QY(),t)}(h2)),h2}var p2={exports:{}},KC;function $Y(){return KC||(KC=1,function(t){(function(){var e;typeof window=="object"&&window?e=window:e=I,t.exports?t.exports=e.Promise?e.Promise:r:e.Promise||(e.Promise=r);var u=e.setImmediate||function(f){setTimeout(f,1)};function s(f,p){return function(){f.apply(p,arguments)}}var n=Array.isArray||function(f){return Object.prototype.toString.call(f)==="[object Array]"};function r(f){if(typeof this!="object")throw new TypeError("Promises must be constructed via new");if(typeof f!="function")throw new TypeError("not a function");this._state=null,this._value=null,this._deferreds=[],h(f,s(o,this),s(l,this))}function a(f){var p=this;if(this._state===null){this._deferreds.push(f);return}u(function(){var y=p._state?f.onFulfilled:f.onRejected;if(y===null){(p._state?f.resolve:f.reject)(p._value);return}var b;try{b=y(p._value)}catch(g){f.reject(g);return}f.resolve(b)})}function o(f){try{if(f===this)throw new TypeError("A promise cannot be resolved with itself.");if(f&&(typeof f=="object"||typeof f=="function")){var p=f.then;if(typeof p=="function"){h(s(p,f),s(o,this),s(l,this));return}}this._state=!0,this._value=f,c.call(this)}catch(y){l.call(this,y)}}function l(f){this._state=!1,this._value=f,c.call(this)}function c(){for(var f=0,p=this._deferreds.length;fthis.sparqlJsonParser.parseJsonBooleanStream(d),parseResultsStream:d=>this.sparqlJsonParser.parseJsonResultsStream(d)},[Ms.CONTENTTYPE_SPARQL_XML]:{parseBooleanStream:d=>this.sparqlXmlParser.parseXmlBooleanStream(d),parseResultsStream:d=>this.sparqlXmlParser.parseXmlResultsStream(d)}},this.timeout=c.timeout}getQueryType(c){const d=new t.Parser({sparqlStar:!0}).parse(c);return d.type==="query"?d.queryType==="DESCRIBE"?"CONSTRUCT":d.queryType:"UNKNOWN"}getUpdateTypes(c){const d=new t.Parser({sparqlStar:!0}).parse(c);if(d.type==="update"){const h={};for(const f of d.updates)"type"in f?h[f.type]=!0:h[f.updateType]=!0;return h}else return"UNKNOWN"}async fetchBindings(c,d){const[h,f]=await this.fetchRawStream(c,d,Ms.CONTENTTYPE_SPARQL),p=this.sparqlParsers[h];if(!p)throw new Error("Unknown SPARQL results content type: "+h);return p.parseResultsStream(f)}async fetchAsk(c,d){const[h,f]=await this.fetchRawStream(c,d,Ms.CONTENTTYPE_SPARQL),p=this.sparqlParsers[h];if(!p)throw new Error("Unknown SPARQL results content type: "+h);return p.parseBooleanStream(f)}async fetchTriples(c,d){return(await this.fetchRawStream(c,d,Ms.CONTENTTYPE_TURTLE))[1].pipe(new r.StreamParser({format:Ms.CONTENTTYPE_TURTLE}))}async fetchUpdate(c,d){const h=globalThis.AbortController||await Promise.resolve().then(()=>Qo()),f=new h,p={};this.defaultHeaders.forEach((b,g)=>{p[g]=b});const y={method:"POST",headers:Object.assign(Object.assign({},p),{"content-type":"application/sparql-update"}),body:d,signal:f.signal};await this.handleFetchCall(c,y,{ignoreBody:!0}),f.abort()}async fetchRawStream(c,d,h){let f=this.method==="POST"?c:c+"?query="+encodeURIComponent(d);const p=new Headers(this.defaultHeaders);let y;return p.append("Accept",h),this.method==="POST"?(p.append("Content-Type","application/x-www-form-urlencoded"),y=new URLSearchParams,y.set("query",d),this.additionalUrlParams.forEach((b,g)=>{y.set(g,b)}),p.append("Content-Length",y.toString().length.toString())):this.additionalUrlParams.toString()!==""&&(f+=`&${this.additionalUrlParams.toString()}`),this.handleFetchCall(f,{headers:p,method:this.method,body:y})}async handleFetchCall(c,d,h={}){let f;if(this.timeout){const g=new AbortController;d.signal=g.signal,f=setTimeout(()=>g.abort(),this.timeout)}const p=await(this.fetchCb||fetch)(c,d);clearTimeout(f);let y;h.ignoreBody||(y=a(p.body)?p.body:new n.ReadableWebToNodeStream(p.body));let b=p.headers.get("Content-Type")||"";if(b.indexOf(";")>0&&(b=b.substr(0,b.indexOf(";"))),!p.ok){const g=/^[^?]*/u.exec(c)[0];let m="empty response";throw y&&(m=await s(y)),new Error(`Invalid SPARQL endpoint response from ${g} (HTTP status ${p.status}): +${m}`)}return[b,y]}};return o.CONTENTTYPE_SPARQL_JSON="application/sparql-results+json",o.CONTENTTYPE_SPARQL_XML="application/sparql-results+xml",o.CONTENTTYPE_SPARQL=`${o.CONTENTTYPE_SPARQL_JSON};q=1.0,${o.CONTENTTYPE_SPARQL_XML};q=0.7`,o.CONTENTTYPE_TURTLE="text/turtle",jf.SparqlEndpointFetcher=o,jf}var t8;function H7(){return t8||(t8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(zY(),t)}(f2)),f2}var r8;function $7(){if(r8)return Cf;r8=1,Object.defineProperty(Cf,"__esModule",{value:!0}),Cf.QuadDestinationSparql=void 0;const t=ou(),e=H7(),u=Ny();let s=class{constructor(r,a,o){this.url=r,this.context=a,this.mediatorHttp=o,this.endpointFetcher=new e.SparqlEndpointFetcher({fetch:(l,c)=>this.mediatorHttp.mediate({input:l,init:c,context:this.context}),prefixVariableQuestionMark:!0})}insert(r){return this.wrapSparqlUpdateRequest("INSERT",r)}async delete(r){return this.wrapSparqlUpdateRequest("DELETE",r)}async wrapSparqlUpdateRequest(r,a){const o=a.map(c=>{let d=`${(0,u.termToString)(c.subject)} ${(0,u.termToString)(c.predicate)} ${(0,u.termToString)(c.object)} .`;return c.graph.termType==="DefaultGraph"?d=` ${d} +`:d=` GRAPH ${(0,u.termToString)(c.graph)} { ${d} } +`,d}).prepend([`${r} DATA { +`]).append(["}"]),l=await(0,t.stringify)(o);await this.endpointFetcher.fetchUpdate(this.url,l)}async deleteGraphs(r,a,o){const l=Array.isArray(r)?r:[r],c=[];for(const d of l){let h;typeof d=="string"?h=d:d.termType==="DefaultGraph"?h="DEFAULT":h=`GRAPH <${d.value}>`,c.push(`${o?"DROP":"CLEAR"} ${a?"":"SILENT "}${h}`)}await this.endpointFetcher.fetchUpdate(this.url,c.join("; "))}async createGraphs(r,a){const o=[];for(const l of r)o.push(`CREATE${a?"":" SILENT"} GRAPH <${l.value}>`);await this.endpointFetcher.fetchUpdate(this.url,o.join("; "))}};return Cf.QuadDestinationSparql=s,Cf}var n8;function GY(){if(n8)return Nf;n8=1,Object.defineProperty(Nf,"__esModule",{value:!0}),Nf.ActorRdfUpdateHypermediaSparql=void 0;const t=fA(),e=$7();let u=class extends t.ActorRdfUpdateHypermedia{constructor(n){super(n,"sparql")}async testMetadata(n){if(!n.forceDestinationType&&!n.metadata.sparqlService&&!(this.checkUrlSuffixSparql&&n.url.endsWith("/sparql"))&&!(this.checkUrlSuffixUpdate&&n.url.endsWith("/update")))throw new Error(`Actor ${this.name} could not detect a SPARQL service description or URL ending on /sparql or /update.`);return!0}async run(n){return this.logInfo(n.context,`Identified as sparql destination: ${n.url}`),{destination:new e.QuadDestinationSparql(n.metadata.sparqlService||n.url,n.context,this.mediatorHttp)}}};return Nf.ActorRdfUpdateHypermediaSparql=u,Nf}var i8;function WY(){return i8||(i8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(GY(),t),u($7(),t)}(d2)),d2}var b2={},Ff={},a8;function JY(){if(a8)return Ff;a8=1,Object.defineProperty(Ff,"__esModule",{value:!0}),Ff.ActorQueryOperationBgpJoin=void 0;const t=wt(),e=Ot();let u=class V7 extends t.ActorQueryOperationTypedMediated{constructor(n){super(n,"bgp")}async testOperation(n,r){return!0}async runOperation(n,r){return this.mediatorQueryOperation.mediate({operation:V7.FACTORY.createJoin(n.patterns),context:r})}};return Ff.ActorQueryOperationBgpJoin=u,u.FACTORY=new e.Factory,Ff}var s8;function XY(){return s8||(s8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(JY(),t)}(b2)),b2}var m2={},qf={},o8;function KY(){if(o8)return qf;o8=1,Object.defineProperty(qf,"__esModule",{value:!0}),qf.ActorQueryOperationAsk=void 0;const t=wt();let e=class extends t.ActorQueryOperationTypedMediated{constructor(s){super(s,"ask")}async testOperation(s,n){return!0}async runOperation(s,n){const r=await this.mediatorQueryOperation.mediate({operation:s.input,context:n}),{bindingsStream:a}=t.ActorQueryOperation.getSafeBindings(r);return{type:"boolean",execute:async()=>(await a.take(1).toArray()).length===1}}};return qf.ActorQueryOperationAsk=e,qf}var u8;function YY(){return u8||(u8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(KY(),t)}(m2)),m2}var g2={},Bf={},Uf={},c8;function k7(){if(c8)return Uf;c8=1,Object.defineProperty(Uf,"__esModule",{value:!0}),Uf.BindingsToQuadsIterator=void 0;const t=Dt(),e=Et(),u=un(),s=new e.DataFactory;let n=class D0 extends t.MultiTransformIterator{constructor(a,o){super(o,{autoStart:!1}),this.template=a,this.blankNodeCounter=0}static bindTerm(a,o){return o.termType==="Variable"?a.get(o):o}static bindQuad(a,o){try{return(0,u.mapTermsNested)(o,l=>{const c=D0.bindTerm(a,l);if(!c)throw new Error("Unbound term");return c})}catch{}}static localizeBlankNode(a,o){return o.termType==="BlankNode"?s.blankNode(`${o.value}${a}`):o}static localizeQuad(a,o){return(0,u.mapTermsNested)(o,l=>D0.localizeBlankNode(a,l))}bindTemplate(a,o,l){return o.map(D0.localizeQuad.bind(null,l)).map(d=>D0.bindQuad.bind(null,a)(d)).filter(Boolean)}_createTransformer(a){return new t.ArrayIterator(this.bindTemplate(a,this.template,this.blankNodeCounter++),{autoStart:!1})}};return Uf.BindingsToQuadsIterator=n,Uf}var l8;function ZY(){if(l8)return Bf;l8=1,Object.defineProperty(Bf,"__esModule",{value:!0}),Bf.ActorQueryOperationConstruct=void 0;const t=wt(),e=un(),u=Ot(),s=k7();let n=class z7 extends t.ActorQueryOperationTypedMediated{constructor(a){super(a,"construct")}static getVariables(a){return(0,e.uniqTerms)([].concat.apply([],a.map(o=>(0,e.getVariables)((0,e.getTermsNested)(o)))))}async testOperation(a,o){return!0}async runOperation(a,o){const l=z7.getVariables(a.template),c={type:u.Algebra.types.PROJECT,input:a.input,variables:l},d=t.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:c,context:o})),h=new s.BindingsToQuadsIterator(a.template,d.bindingsStream);return{metadata:()=>d.metadata().then(p=>({...p,order:void 0,cardinality:{type:p.cardinality.type,value:p.cardinality.value*a.template.length},canContainUndefs:!1,availableOrders:void 0})),quadStream:h,type:"quads"}}};return Bf.ActorQueryOperationConstruct=n,Bf}var d8;function G7(){return d8||(d8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(ZY(),t),u(k7(),t)}(g2)),g2}var _2={},Qf={},f8;function eZ(){if(f8)return Qf;f8=1,Object.defineProperty(Qf,"__esModule",{value:!0}),Qf.ActorQueryOperationDistinctHash=void 0;const t=wt();let e=class extends t.ActorQueryOperationTypedMediated{constructor(s){super(s,"distinct")}async testOperation(s,n){return!0}async runOperation(s,n){const r=await this.mediatorQueryOperation.mediate({operation:s.input,context:n});if(r.type==="quads"&&this.mediatorHashQuads!==void 0){const l=t.ActorQueryOperation.getSafeQuads(r);return{type:"quads",quadStream:l.quadStream.filter(await this.newHashFilterQuads(n)),metadata:l.metadata}}const a=t.ActorQueryOperation.getSafeBindings(r);return{type:"bindings",bindingsStream:a.bindingsStream.filter(await this.newHashFilter(n)),metadata:a.metadata}}async newHashFilter(s){const{hashFunction:n}=await this.mediatorHashBindings.mediate({allowHashCollisions:!0,context:s}),r={};return a=>{const o=n(a);return!(o in r)&&(r[o]=!0)}}async newHashFilterQuads(s){if(this.mediatorHashQuads===void 0)return a=>!0;const{hashFunction:n}=await this.mediatorHashQuads.mediate({allowHashCollisions:!0,context:s}),r={};return a=>{const o=n(a);return!(o in r)&&(r[o]=!0)}}};return Qf.ActorQueryOperationDistinctHash=e,Qf}var h8;function tZ(){return h8||(h8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(eZ(),t)}(_2)),_2}var v2={},Hf={},p8;function rZ(){if(p8)return Hf;p8=1,Object.defineProperty(Hf,"__esModule",{value:!0}),Hf.ActorQueryOperationFromQuad=void 0;const t=wt(),e=Ot();let u=class hr extends t.ActorQueryOperationTypedMediated{constructor(n){super(n,"from")}static copyOperation(n,r){const a={};for(const o of Object.keys(n))Array.isArray(n[o])&&o!=="template"?o==="variables"?a[o]=n[o]:a[o]=n[o].map(r):hr.ALGEBRA_TYPES.includes(n[o].type)?a[o]=r(n[o]):a[o]=n[o];return a}static applyOperationDefaultGraph(n,r){if(n.type==="bgp"&&n.patterns.length>0||n.type==="path"||n.type==="pattern"){if(n.type==="bgp")return hr.joinOperations(n.patterns.map(o=>{if(o.graph.termType!=="DefaultGraph")return hr.FACTORY.createBgp([o]);const l=r.map(c=>hr.FACTORY.createBgp([Object.assign(hr.FACTORY.createPattern(o.subject,o.predicate,o.object,c),{metadata:o.metadata})]));return hr.unionOperations(l)}));if(n.graph.termType!=="DefaultGraph")return n;const a=r.map(o=>n.type==="path"?hr.FACTORY.createPath(n.subject,n.predicate,n.object,o):Object.assign(hr.FACTORY.createPattern(n.subject,n.predicate,n.object,o),{metadata:n.metadata}));return hr.unionOperations(a)}return hr.copyOperation(n,a=>this.applyOperationDefaultGraph(a,r))}static applyOperationNamedGraph(n,r,a){if(n.type==="bgp"&&n.patterns.length>0||n.type==="path"||n.type==="pattern"){const o=n.type==="bgp"?n.patterns[0].graph:n.graph;if(o.termType==="DefaultGraph")return{type:e.Algebra.types.BGP,patterns:[]};if(o.termType==="Variable"){if(r.length===1){const c=r[0],d={};d[`?${o.value}`]=c;const h=hr.FACTORY.createValues([o],[d]);let f;return n.type==="bgp"?f=hr.FACTORY.createBgp(n.patterns.map(p=>hr.FACTORY.createPattern(p.subject,p.predicate,p.object,c))):n.type==="path"?f=hr.FACTORY.createPath(n.subject,n.predicate,n.object,c):f=hr.FACTORY.createPattern(n.subject,n.predicate,n.object,c),hr.FACTORY.createJoin([h,f])}return hr.unionOperations(r.map(c=>hr.applyOperationNamedGraph(n,[c],a)))}return[...r,...a].some(c=>c.equals(o))?n:{type:e.Algebra.types.BGP,patterns:[]}}return hr.copyOperation(n,o=>this.applyOperationNamedGraph(o,r,a))}static joinOperations(n){if(n.length===1)return n[0];if(n.length>1)return hr.FACTORY.createJoin(n);throw new Error("A join can only be applied on at least one operation")}static unionOperations(n){if(n.length===1)return n[0];if(n.length>1)return hr.FACTORY.createUnion(n);throw new Error("A union can only be applied on at least one operation")}static createOperation(n){let r=n.input;return n.default.length>0&&(r=hr.applyOperationDefaultGraph(r,n.default)),(n.named.length>0||n.default.length>0)&&(r=hr.applyOperationNamedGraph(r,n.named,n.default)),r}async testOperation(n,r){return!0}async runOperation(n,r){const a=hr.createOperation(n);return this.mediatorQueryOperation.mediate({operation:a,context:r})}};return Hf.ActorQueryOperationFromQuad=u,u.FACTORY=new e.Factory,u.ALGEBRA_TYPES=Object.keys(e.Algebra.types).map(s=>e.Algebra.types[s]),Hf}var y8;function nZ(){return y8||(y8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(rZ(),t)}(v2)),v2}var w2={},$f={},b8;function iZ(){if(b8)return $f;b8=1,Object.defineProperty($f,"__esModule",{value:!0}),$f.ActorQueryOperationProject=void 0;const t=wt(),e=UT(),u=Et(),s=new u.DataFactory;let n=class extends t.ActorQueryOperationTypedMediated{constructor(a){super(a,"project")}async testOperation(a,o){return!0}async runOperation(a,o){const l=t.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:a.input,context:o})),c=await l.metadata(),d=a.variables,h=c.variables.filter(b=>!d.some(g=>b.value===g.value));d.filter(b=>!c.variables.some(g=>b.value===g.value)).length>0&&(c.canContainUndefs=!0);let p=h.length===0?l.bindingsStream:l.bindingsStream.map(b=>{for(const g of h)b=b.delete(g);return b}),y=0;return p=p.map(b=>{y++;const g=new Map;return b.map(m=>{if(m instanceof e.BlankNodeBindingsScoped){let v=g.get(m.value);return v||(v=s.blankNode(`${m.value}${y}`),g.set(m.value,v)),v}return m})}),{type:"bindings",bindingsStream:p,metadata:async()=>({...c,variables:d})}}};return $f.ActorQueryOperationProject=n,$f}var m8;function aZ(){return m8||(m8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(iZ(),t)}(w2)),w2}var S2={},Vf={},kf={},g8;function os(){var f,p,b,g,m,v,_,w,S,A,D,L,O,E,P,M,U,j,q,$,Z,X,le,K,he,Re,E3,ae,Ee,De,ge,de,W7,H,N,R,T,Ca,B,ja,V,O3,z,Y,W1,ce,J1,xe,pr,qe,R3,F,N0,te,La,Oe,x3;if(g8)return kf;g8=1,Object.defineProperty(kf,"__esModule",{value:!0}),kf.LRUCache=void 0;const t=typeof performance=="object"&&performance&&typeof performance.now=="function"?performance:Date,e=new Set,u=typeof process=="object"&&process?process:{},s=(Ve,pe,we,W)=>{typeof u.emitWarning=="function"?u.emitWarning(Ve,pe,we,W):console.error(`[${we}] ${pe}: ${Ve}`)};let n=globalThis.AbortController,r=globalThis.AbortSignal;if(typeof n>"u"){r=class{constructor(){wr(this,"onabort");wr(this,"_onabort",[]);wr(this,"reason");wr(this,"aborted",!1)}addEventListener(W,Se){this._onabort.push(Se)}},n=class{constructor(){wr(this,"signal",new r);pe()}abort(W){var Se,Ae;if(!this.signal.aborted){this.signal.reason=W,this.signal.aborted=!0;for(const je of this.signal._onabort)je(W);(Ae=(Se=this.signal).onabort)==null||Ae.call(Se,W)}}};let Ve=((f=u.env)==null?void 0:f.LRU_CACHE_IGNORE_AC_WARNING)!=="1";const pe=()=>{Ve&&(Ve=!1,s("AbortController is not defined. If using lru-cache in node 14, load an AbortController polyfill from the `node-abort-controller` package. A minimal polyfill is provided for use by LRUCache.fetch(), but it should not be relied upon in other contexts (eg, passing it to other APIs that use AbortController/AbortSignal might have undesirable effects). You may disable this with LRU_CACHE_IGNORE_AC_WARNING=1 in the env.","NO_ABORT_CONTROLLER","ENOTSUP",pe))}}const a=Ve=>!e.has(Ve),o=Ve=>Ve&&Ve===Math.floor(Ve)&&Ve>0&&isFinite(Ve),l=Ve=>o(Ve)?Ve<=Math.pow(2,8)?Uint8Array:Ve<=Math.pow(2,16)?Uint16Array:Ve<=Math.pow(2,32)?Uint32Array:Ve<=Number.MAX_SAFE_INTEGER?c:null:null;class c extends Array{constructor(pe){super(pe),this.fill(0)}}const y=class y{constructor(pe,we){wr(this,"heap");wr(this,"length");if(!_e(y,p))throw new TypeError("instantiate Stack using Stack.create(n)");this.heap=new we(pe),this.length=0}static create(pe){const we=l(pe);if(!we)return[];_t(y,p,!0);const W=new y(pe,we);return _t(y,p,!1),W}push(pe){this.heap[this.length++]=pe}pop(){return this.heap[--this.length]}};p=new WeakMap,xt(y,p,!1);let d=y;const We=class We{constructor(pe){xt(this,Re);xt(this,de);xt(this,T);xt(this,B);xt(this,V);xt(this,Y);xt(this,ce);xt(this,xe);xt(this,qe);xt(this,F);xt(this,te);xt(this,Oe);xt(this,b,void 0);xt(this,g,void 0);xt(this,m,void 0);xt(this,v,void 0);xt(this,_,void 0);xt(this,w,void 0);wr(this,"ttl");wr(this,"ttlResolution");wr(this,"ttlAutopurge");wr(this,"updateAgeOnGet");wr(this,"updateAgeOnHas");wr(this,"allowStale");wr(this,"noDisposeOnSet");wr(this,"noUpdateTTL");wr(this,"maxEntrySize");wr(this,"sizeCalculation");wr(this,"noDeleteOnFetchRejection");wr(this,"noDeleteOnStaleGet");wr(this,"allowStaleOnFetchAbort");wr(this,"allowStaleOnFetchRejection");wr(this,"ignoreFetchAbort");xt(this,S,void 0);xt(this,A,void 0);xt(this,D,void 0);xt(this,L,void 0);xt(this,O,void 0);xt(this,E,void 0);xt(this,P,void 0);xt(this,M,void 0);xt(this,U,void 0);xt(this,j,void 0);xt(this,q,void 0);xt(this,$,void 0);xt(this,Z,void 0);xt(this,X,void 0);xt(this,le,void 0);xt(this,K,void 0);xt(this,he,void 0);xt(this,ae,()=>{});xt(this,Ee,()=>{});xt(this,De,()=>{});xt(this,ge,()=>!1);xt(this,H,pe=>{});xt(this,N,(pe,we,W)=>{});xt(this,R,(pe,we,W,Se)=>{if(W||Se)throw new TypeError("cannot set size without setting maxSize or maxEntrySize on cache");return 0});wr(this,z,"LRUCache");const{max:we=0,ttl:W,ttlResolution:Se=1,ttlAutopurge:Ae,updateAgeOnGet:je,updateAgeOnHas:He,allowStale:Ge,dispose:tt,disposeAfter:lt,noDisposeOnSet:ut,noUpdateTTL:oe,maxSize:C=0,maxEntrySize:ee=0,sizeCalculation:ye,fetchMethod:Pe,memoMethod:Ue,noDeleteOnFetchRejection:Fe,noDeleteOnStaleGet:Ye,allowStaleOnFetchRejection:$e,allowStaleOnFetchAbort:Je,ignoreFetchAbort:nt}=pe;if(we!==0&&!o(we))throw new TypeError("max option must be a nonnegative integer");const yt=we?l(we):Array;if(!yt)throw new Error("invalid max value: "+we);if(_t(this,b,we),_t(this,g,C),this.maxEntrySize=ee||_e(this,g),this.sizeCalculation=ye,this.sizeCalculation){if(!_e(this,g)&&!this.maxEntrySize)throw new TypeError("cannot set sizeCalculation without setting maxSize or maxEntrySize");if(typeof this.sizeCalculation!="function")throw new TypeError("sizeCalculation set to non-function")}if(Ue!==void 0&&typeof Ue!="function")throw new TypeError("memoMethod must be a function if defined");if(_t(this,w,Ue),Pe!==void 0&&typeof Pe!="function")throw new TypeError("fetchMethod must be a function if specified");if(_t(this,_,Pe),_t(this,K,!!Pe),_t(this,D,new Map),_t(this,L,new Array(we).fill(void 0)),_t(this,O,new Array(we).fill(void 0)),_t(this,E,new yt(we)),_t(this,P,new yt(we)),_t(this,M,0),_t(this,U,0),_t(this,j,d.create(we)),_t(this,S,0),_t(this,A,0),typeof tt=="function"&&_t(this,m,tt),typeof lt=="function"?(_t(this,v,lt),_t(this,q,[])):(_t(this,v,void 0),_t(this,q,void 0)),_t(this,le,!!_e(this,m)),_t(this,he,!!_e(this,v)),this.noDisposeOnSet=!!ut,this.noUpdateTTL=!!oe,this.noDeleteOnFetchRejection=!!Fe,this.allowStaleOnFetchRejection=!!$e,this.allowStaleOnFetchAbort=!!Je,this.ignoreFetchAbort=!!nt,this.maxEntrySize!==0){if(_e(this,g)!==0&&!o(_e(this,g)))throw new TypeError("maxSize must be a positive integer if specified");if(!o(this.maxEntrySize))throw new TypeError("maxEntrySize must be a positive integer if specified");ct(this,de,W7).call(this)}if(this.allowStale=!!Ge,this.noDeleteOnStaleGet=!!Ye,this.updateAgeOnGet=!!je,this.updateAgeOnHas=!!He,this.ttlResolution=o(Se)||Se===0?Se:1,this.ttlAutopurge=!!Ae,this.ttl=W||0,this.ttl){if(!o(this.ttl))throw new TypeError("ttl must be a positive integer if specified");ct(this,Re,E3).call(this)}if(_e(this,b)===0&&this.ttl===0&&_e(this,g)===0)throw new TypeError("At least one of max, maxSize, or ttl is required");if(!this.ttlAutopurge&&!_e(this,b)&&!_e(this,g)){const ft="LRU_CACHE_UNBOUNDED";a(ft)&&(e.add(ft),s("TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.","UnboundedCacheWarning",ft,We))}}static unsafeExposeInternals(pe){return{starts:_e(pe,Z),ttls:_e(pe,X),sizes:_e(pe,$),keyMap:_e(pe,D),keyList:_e(pe,L),valList:_e(pe,O),next:_e(pe,E),prev:_e(pe,P),get head(){return _e(pe,M)},get tail(){return _e(pe,U)},free:_e(pe,j),isBackgroundFetch:we=>{var W;return ct(W=pe,xe,pr).call(W,we)},backgroundFetch:(we,W,Se,Ae)=>{var je;return ct(je=pe,ce,J1).call(je,we,W,Se,Ae)},moveToTail:we=>{var W;return ct(W=pe,F,N0).call(W,we)},indexes:we=>{var W;return ct(W=pe,T,Ca).call(W,we)},rindexes:we=>{var W;return ct(W=pe,B,ja).call(W,we)},isStale:we=>{var W;return _e(W=pe,ge).call(W,we)}}}get max(){return _e(this,b)}get maxSize(){return _e(this,g)}get calculatedSize(){return _e(this,A)}get size(){return _e(this,S)}get fetchMethod(){return _e(this,_)}get memoMethod(){return _e(this,w)}get dispose(){return _e(this,m)}get disposeAfter(){return _e(this,v)}getRemainingTTL(pe){return _e(this,D).has(pe)?1/0:0}*entries(){for(const pe of ct(this,T,Ca).call(this))_e(this,O)[pe]!==void 0&&_e(this,L)[pe]!==void 0&&!ct(this,xe,pr).call(this,_e(this,O)[pe])&&(yield[_e(this,L)[pe],_e(this,O)[pe]])}*rentries(){for(const pe of ct(this,B,ja).call(this))_e(this,O)[pe]!==void 0&&_e(this,L)[pe]!==void 0&&!ct(this,xe,pr).call(this,_e(this,O)[pe])&&(yield[_e(this,L)[pe],_e(this,O)[pe]])}*keys(){for(const pe of ct(this,T,Ca).call(this)){const we=_e(this,L)[pe];we!==void 0&&!ct(this,xe,pr).call(this,_e(this,O)[pe])&&(yield we)}}*rkeys(){for(const pe of ct(this,B,ja).call(this)){const we=_e(this,L)[pe];we!==void 0&&!ct(this,xe,pr).call(this,_e(this,O)[pe])&&(yield we)}}*values(){for(const pe of ct(this,T,Ca).call(this))_e(this,O)[pe]!==void 0&&!ct(this,xe,pr).call(this,_e(this,O)[pe])&&(yield _e(this,O)[pe])}*rvalues(){for(const pe of ct(this,B,ja).call(this))_e(this,O)[pe]!==void 0&&!ct(this,xe,pr).call(this,_e(this,O)[pe])&&(yield _e(this,O)[pe])}[Symbol.iterator](){return this.entries()}find(pe,we={}){for(const W of ct(this,T,Ca).call(this)){const Se=_e(this,O)[W],Ae=ct(this,xe,pr).call(this,Se)?Se.__staleWhileFetching:Se;if(Ae!==void 0&&pe(Ae,_e(this,L)[W],this))return this.get(_e(this,L)[W],we)}}forEach(pe,we=this){for(const W of ct(this,T,Ca).call(this)){const Se=_e(this,O)[W],Ae=ct(this,xe,pr).call(this,Se)?Se.__staleWhileFetching:Se;Ae!==void 0&&pe.call(we,Ae,_e(this,L)[W],this)}}rforEach(pe,we=this){for(const W of ct(this,B,ja).call(this)){const Se=_e(this,O)[W],Ae=ct(this,xe,pr).call(this,Se)?Se.__staleWhileFetching:Se;Ae!==void 0&&pe.call(we,Ae,_e(this,L)[W],this)}}purgeStale(){let pe=!1;for(const we of ct(this,B,ja).call(this,{allowStale:!0}))_e(this,ge).call(this,we)&&(ct(this,te,La).call(this,_e(this,L)[we],"expire"),pe=!0);return pe}info(pe){const we=_e(this,D).get(pe);if(we===void 0)return;const W=_e(this,O)[we],Se=ct(this,xe,pr).call(this,W)?W.__staleWhileFetching:W;if(Se===void 0)return;const Ae={value:Se};if(_e(this,X)&&_e(this,Z)){const je=_e(this,X)[we],He=_e(this,Z)[we];if(je&&He){const Ge=je-(t.now()-He);Ae.ttl=Ge,Ae.start=Date.now()}}return _e(this,$)&&(Ae.size=_e(this,$)[we]),Ae}dump(){const pe=[];for(const we of ct(this,T,Ca).call(this,{allowStale:!0})){const W=_e(this,L)[we],Se=_e(this,O)[we],Ae=ct(this,xe,pr).call(this,Se)?Se.__staleWhileFetching:Se;if(Ae===void 0||W===void 0)continue;const je={value:Ae};if(_e(this,X)&&_e(this,Z)){je.ttl=_e(this,X)[we];const He=t.now()-_e(this,Z)[we];je.start=Math.floor(Date.now()-He)}_e(this,$)&&(je.size=_e(this,$)[we]),pe.unshift([W,je])}return pe}load(pe){this.clear();for(const[we,W]of pe){if(W.start){const Se=Date.now()-W.start;W.start=t.now()-Se}this.set(we,W.value,W)}}set(pe,we,W={}){var oe,C,ee,ye,Pe;if(we===void 0)return this.delete(pe),this;const{ttl:Se=this.ttl,start:Ae,noDisposeOnSet:je=this.noDisposeOnSet,sizeCalculation:He=this.sizeCalculation,status:Ge}=W;let{noUpdateTTL:tt=this.noUpdateTTL}=W;const lt=_e(this,R).call(this,pe,we,W.size||0,He);if(this.maxEntrySize&<>this.maxEntrySize)return Ge&&(Ge.set="miss",Ge.maxEntrySizeExceeded=!0),ct(this,te,La).call(this,pe,"set"),this;let ut=_e(this,S)===0?void 0:_e(this,D).get(pe);if(ut===void 0)ut=_e(this,S)===0?_e(this,U):_e(this,j).length!==0?_e(this,j).pop():_e(this,S)===_e(this,b)?ct(this,Y,W1).call(this,!1):_e(this,S),_e(this,L)[ut]=pe,_e(this,O)[ut]=we,_e(this,D).set(pe,ut),_e(this,E)[_e(this,U)]=ut,_e(this,P)[ut]=_e(this,U),_t(this,U,ut),Jy(this,S)._++,_e(this,N).call(this,ut,lt,Ge),Ge&&(Ge.set="add"),tt=!1;else{ct(this,F,N0).call(this,ut);const Ue=_e(this,O)[ut];if(we!==Ue){if(_e(this,K)&&ct(this,xe,pr).call(this,Ue)){Ue.__abortController.abort(new Error("replaced"));const{__staleWhileFetching:Fe}=Ue;Fe!==void 0&&!je&&(_e(this,le)&&((oe=_e(this,m))==null||oe.call(this,Fe,pe,"set")),_e(this,he)&&((C=_e(this,q))==null||C.push([Fe,pe,"set"])))}else je||(_e(this,le)&&((ee=_e(this,m))==null||ee.call(this,Ue,pe,"set")),_e(this,he)&&((ye=_e(this,q))==null||ye.push([Ue,pe,"set"])));if(_e(this,H).call(this,ut),_e(this,N).call(this,ut,lt,Ge),_e(this,O)[ut]=we,Ge){Ge.set="replace";const Fe=Ue&&ct(this,xe,pr).call(this,Ue)?Ue.__staleWhileFetching:Ue;Fe!==void 0&&(Ge.oldValue=Fe)}}else Ge&&(Ge.set="update")}if(Se!==0&&!_e(this,X)&&ct(this,Re,E3).call(this),_e(this,X)&&(tt||_e(this,De).call(this,ut,Se,Ae),Ge&&_e(this,Ee).call(this,Ge,ut)),!je&&_e(this,he)&&_e(this,q)){const Ue=_e(this,q);let Fe;for(;Fe=Ue==null?void 0:Ue.shift();)(Pe=_e(this,v))==null||Pe.call(this,...Fe)}return this}pop(){var pe;try{for(;_e(this,S);){const we=_e(this,O)[_e(this,M)];if(ct(this,Y,W1).call(this,!0),ct(this,xe,pr).call(this,we)){if(we.__staleWhileFetching)return we.__staleWhileFetching}else if(we!==void 0)return we}}finally{if(_e(this,he)&&_e(this,q)){const we=_e(this,q);let W;for(;W=we==null?void 0:we.shift();)(pe=_e(this,v))==null||pe.call(this,...W)}}}has(pe,we={}){const{updateAgeOnHas:W=this.updateAgeOnHas,status:Se}=we,Ae=_e(this,D).get(pe);if(Ae!==void 0){const je=_e(this,O)[Ae];if(ct(this,xe,pr).call(this,je)&&je.__staleWhileFetching===void 0)return!1;if(_e(this,ge).call(this,Ae))Se&&(Se.has="stale",_e(this,Ee).call(this,Se,Ae));else return W&&_e(this,ae).call(this,Ae),Se&&(Se.has="hit",_e(this,Ee).call(this,Se,Ae)),!0}else Se&&(Se.has="miss");return!1}peek(pe,we={}){const{allowStale:W=this.allowStale}=we,Se=_e(this,D).get(pe);if(Se===void 0||!W&&_e(this,ge).call(this,Se))return;const Ae=_e(this,O)[Se];return ct(this,xe,pr).call(this,Ae)?Ae.__staleWhileFetching:Ae}async fetch(pe,we={}){const{allowStale:W=this.allowStale,updateAgeOnGet:Se=this.updateAgeOnGet,noDeleteOnStaleGet:Ae=this.noDeleteOnStaleGet,ttl:je=this.ttl,noDisposeOnSet:He=this.noDisposeOnSet,size:Ge=0,sizeCalculation:tt=this.sizeCalculation,noUpdateTTL:lt=this.noUpdateTTL,noDeleteOnFetchRejection:ut=this.noDeleteOnFetchRejection,allowStaleOnFetchRejection:oe=this.allowStaleOnFetchRejection,ignoreFetchAbort:C=this.ignoreFetchAbort,allowStaleOnFetchAbort:ee=this.allowStaleOnFetchAbort,context:ye,forceRefresh:Pe=!1,status:Ue,signal:Fe}=we;if(!_e(this,K))return Ue&&(Ue.fetch="get"),this.get(pe,{allowStale:W,updateAgeOnGet:Se,noDeleteOnStaleGet:Ae,status:Ue});const Ye={allowStale:W,updateAgeOnGet:Se,noDeleteOnStaleGet:Ae,ttl:je,noDisposeOnSet:He,size:Ge,sizeCalculation:tt,noUpdateTTL:lt,noDeleteOnFetchRejection:ut,allowStaleOnFetchRejection:oe,allowStaleOnFetchAbort:ee,ignoreFetchAbort:C,status:Ue,signal:Fe};let $e=_e(this,D).get(pe);if($e===void 0){Ue&&(Ue.fetch="miss");const Je=ct(this,ce,J1).call(this,pe,$e,Ye,ye);return Je.__returned=Je}else{const Je=_e(this,O)[$e];if(ct(this,xe,pr).call(this,Je)){const Ir=W&&Je.__staleWhileFetching!==void 0;return Ue&&(Ue.fetch="inflight",Ir&&(Ue.returnedStale=!0)),Ir?Je.__staleWhileFetching:Je.__returned=Je}const nt=_e(this,ge).call(this,$e);if(!Pe&&!nt)return Ue&&(Ue.fetch="hit"),ct(this,F,N0).call(this,$e),Se&&_e(this,ae).call(this,$e),Ue&&_e(this,Ee).call(this,Ue,$e),Je;const yt=ct(this,ce,J1).call(this,pe,$e,Ye,ye),et=yt.__staleWhileFetching!==void 0&&W;return Ue&&(Ue.fetch=nt?"stale":"refresh",et&&nt&&(Ue.returnedStale=!0)),et?yt.__staleWhileFetching:yt.__returned=yt}}async forceFetch(pe,we={}){const W=await this.fetch(pe,we);if(W===void 0)throw new Error("fetch() returned undefined");return W}memo(pe,we={}){const W=_e(this,w);if(!W)throw new Error("no memoMethod provided to constructor");const{context:Se,forceRefresh:Ae,...je}=we,He=this.get(pe,je);if(!Ae&&He!==void 0)return He;const Ge=W(pe,He,{options:je,context:Se});return this.set(pe,Ge,je),Ge}get(pe,we={}){const{allowStale:W=this.allowStale,updateAgeOnGet:Se=this.updateAgeOnGet,noDeleteOnStaleGet:Ae=this.noDeleteOnStaleGet,status:je}=we,He=_e(this,D).get(pe);if(He!==void 0){const Ge=_e(this,O)[He],tt=ct(this,xe,pr).call(this,Ge);return je&&_e(this,Ee).call(this,je,He),_e(this,ge).call(this,He)?(je&&(je.get="stale"),tt?(je&&W&&Ge.__staleWhileFetching!==void 0&&(je.returnedStale=!0),W?Ge.__staleWhileFetching:void 0):(Ae||ct(this,te,La).call(this,pe,"expire"),je&&W&&(je.returnedStale=!0),W?Ge:void 0)):(je&&(je.get="hit"),tt?Ge.__staleWhileFetching:(ct(this,F,N0).call(this,He),Se&&_e(this,ae).call(this,He),Ge))}else je&&(je.get="miss")}delete(pe){return ct(this,te,La).call(this,pe,"delete")}clear(){return ct(this,Oe,x3).call(this,"delete")}};z=Symbol.toStringTag,b=new WeakMap,g=new WeakMap,m=new WeakMap,v=new WeakMap,_=new WeakMap,w=new WeakMap,S=new WeakMap,A=new WeakMap,D=new WeakMap,L=new WeakMap,O=new WeakMap,E=new WeakMap,P=new WeakMap,M=new WeakMap,U=new WeakMap,j=new WeakMap,q=new WeakMap,$=new WeakMap,Z=new WeakMap,X=new WeakMap,le=new WeakMap,K=new WeakMap,he=new WeakMap,Re=new WeakSet,E3=function(){const pe=new c(_e(this,b)),we=new c(_e(this,b));_t(this,X,pe),_t(this,Z,we),_t(this,De,(Ae,je,He=t.now())=>{if(we[Ae]=je!==0?He:0,pe[Ae]=je,je!==0&&this.ttlAutopurge){const Ge=setTimeout(()=>{_e(this,ge).call(this,Ae)&&ct(this,te,La).call(this,_e(this,L)[Ae],"expire")},je+1);Ge.unref&&Ge.unref()}}),_t(this,ae,Ae=>{we[Ae]=pe[Ae]!==0?t.now():0}),_t(this,Ee,(Ae,je)=>{if(pe[je]){const He=pe[je],Ge=we[je];if(!He||!Ge)return;Ae.ttl=He,Ae.start=Ge,Ae.now=W||Se();const tt=Ae.now-Ge;Ae.remainingTTL=He-tt}});let W=0;const Se=()=>{const Ae=t.now();if(this.ttlResolution>0){W=Ae;const je=setTimeout(()=>W=0,this.ttlResolution);je.unref&&je.unref()}return Ae};this.getRemainingTTL=Ae=>{const je=_e(this,D).get(Ae);if(je===void 0)return 0;const He=pe[je],Ge=we[je];if(!He||!Ge)return 1/0;const tt=(W||Se())-Ge;return He-tt},_t(this,ge,Ae=>{const je=we[Ae],He=pe[Ae];return!!He&&!!je&&(W||Se())-je>He})},ae=new WeakMap,Ee=new WeakMap,De=new WeakMap,ge=new WeakMap,de=new WeakSet,W7=function(){const pe=new c(_e(this,b));_t(this,A,0),_t(this,$,pe),_t(this,H,we=>{_t(this,A,_e(this,A)-pe[we]),pe[we]=0}),_t(this,R,(we,W,Se,Ae)=>{if(ct(this,xe,pr).call(this,W))return 0;if(!o(Se))if(Ae){if(typeof Ae!="function")throw new TypeError("sizeCalculation must be a function");if(Se=Ae(W,we),!o(Se))throw new TypeError("sizeCalculation return invalid (expect positive integer)")}else throw new TypeError("invalid size value (must be positive integer). When maxSize or maxEntrySize is used, sizeCalculation or size must be set.");return Se}),_t(this,N,(we,W,Se)=>{if(pe[we]=W,_e(this,g)){const Ae=_e(this,g)-pe[we];for(;_e(this,A)>Ae;)ct(this,Y,W1).call(this,!0)}_t(this,A,_e(this,A)+pe[we]),Se&&(Se.entrySize=W,Se.totalCalculatedSize=_e(this,A))})},H=new WeakMap,N=new WeakMap,R=new WeakMap,T=new WeakSet,Ca=function*({allowStale:pe=this.allowStale}={}){if(_e(this,S))for(let we=_e(this,U);!(!ct(this,V,O3).call(this,we)||((pe||!_e(this,ge).call(this,we))&&(yield we),we===_e(this,M)));)we=_e(this,P)[we]},B=new WeakSet,ja=function*({allowStale:pe=this.allowStale}={}){if(_e(this,S))for(let we=_e(this,M);!(!ct(this,V,O3).call(this,we)||((pe||!_e(this,ge).call(this,we))&&(yield we),we===_e(this,U)));)we=_e(this,E)[we]},V=new WeakSet,O3=function(pe){return pe!==void 0&&_e(this,D).get(_e(this,L)[pe])===pe},Y=new WeakSet,W1=function(pe){var Ae,je;const we=_e(this,M),W=_e(this,L)[we],Se=_e(this,O)[we];return _e(this,K)&&ct(this,xe,pr).call(this,Se)?Se.__abortController.abort(new Error("evicted")):(_e(this,le)||_e(this,he))&&(_e(this,le)&&((Ae=_e(this,m))==null||Ae.call(this,Se,W,"evict")),_e(this,he)&&((je=_e(this,q))==null||je.push([Se,W,"evict"]))),_e(this,H).call(this,we),pe&&(_e(this,L)[we]=void 0,_e(this,O)[we]=void 0,_e(this,j).push(we)),_e(this,S)===1?(_t(this,M,_t(this,U,0)),_e(this,j).length=0):_t(this,M,_e(this,E)[we]),_e(this,D).delete(W),Jy(this,S)._--,we},ce=new WeakSet,J1=function(pe,we,W,Se){const Ae=we===void 0?void 0:_e(this,O)[we];if(ct(this,xe,pr).call(this,Ae))return Ae;const je=new n,{signal:He}=W;He==null||He.addEventListener("abort",()=>je.abort(He.reason),{signal:je.signal});const Ge={signal:je.signal,options:W,context:Se},tt=(ye,Pe=!1)=>{const{aborted:Ue}=je.signal,Fe=W.ignoreFetchAbort&&ye!==void 0;if(W.status&&(Ue&&!Pe?(W.status.fetchAborted=!0,W.status.fetchError=je.signal.reason,Fe&&(W.status.fetchAbortIgnored=!0)):W.status.fetchResolved=!0),Ue&&!Fe&&!Pe)return ut(je.signal.reason);const Ye=C;return _e(this,O)[we]===C&&(ye===void 0?Ye.__staleWhileFetching?_e(this,O)[we]=Ye.__staleWhileFetching:ct(this,te,La).call(this,pe,"fetch"):(W.status&&(W.status.fetchUpdated=!0),this.set(pe,ye,Ge.options))),ye},lt=ye=>(W.status&&(W.status.fetchRejected=!0,W.status.fetchError=ye),ut(ye)),ut=ye=>{const{aborted:Pe}=je.signal,Ue=Pe&&W.allowStaleOnFetchAbort,Fe=Ue||W.allowStaleOnFetchRejection,Ye=Fe||W.noDeleteOnFetchRejection,$e=C;if(_e(this,O)[we]===C&&(!Ye||$e.__staleWhileFetching===void 0?ct(this,te,La).call(this,pe,"fetch"):Ue||(_e(this,O)[we]=$e.__staleWhileFetching)),Fe)return W.status&&$e.__staleWhileFetching!==void 0&&(W.status.returnedStale=!0),$e.__staleWhileFetching;if($e.__returned===$e)throw ye},oe=(ye,Pe)=>{var Fe;const Ue=(Fe=_e(this,_))==null?void 0:Fe.call(this,pe,Ae,Ge);Ue&&Ue instanceof Promise&&Ue.then(Ye=>ye(Ye===void 0?void 0:Ye),Pe),je.signal.addEventListener("abort",()=>{(!W.ignoreFetchAbort||W.allowStaleOnFetchAbort)&&(ye(void 0),W.allowStaleOnFetchAbort&&(ye=Ye=>tt(Ye,!0)))})};W.status&&(W.status.fetchDispatched=!0);const C=new Promise(oe).then(tt,lt),ee=Object.assign(C,{__abortController:je,__staleWhileFetching:Ae,__returned:void 0});return we===void 0?(this.set(pe,ee,{...Ge.options,status:void 0}),we=_e(this,D).get(pe)):_e(this,O)[we]=ee,ee},xe=new WeakSet,pr=function(pe){if(!_e(this,K))return!1;const we=pe;return!!we&&we instanceof Promise&&we.hasOwnProperty("__staleWhileFetching")&&we.__abortController instanceof n},qe=new WeakSet,R3=function(pe,we){_e(this,P)[we]=pe,_e(this,E)[pe]=we},F=new WeakSet,N0=function(pe){pe!==_e(this,U)&&(pe===_e(this,M)?_t(this,M,_e(this,E)[pe]):ct(this,qe,R3).call(this,_e(this,P)[pe],_e(this,E)[pe]),ct(this,qe,R3).call(this,_e(this,U),pe),_t(this,U,pe))},te=new WeakSet,La=function(pe,we){var Se,Ae,je,He;let W=!1;if(_e(this,S)!==0){const Ge=_e(this,D).get(pe);if(Ge!==void 0)if(W=!0,_e(this,S)===1)ct(this,Oe,x3).call(this,we);else{_e(this,H).call(this,Ge);const tt=_e(this,O)[Ge];if(ct(this,xe,pr).call(this,tt)?tt.__abortController.abort(new Error("deleted")):(_e(this,le)||_e(this,he))&&(_e(this,le)&&((Se=_e(this,m))==null||Se.call(this,tt,pe,we)),_e(this,he)&&((Ae=_e(this,q))==null||Ae.push([tt,pe,we]))),_e(this,D).delete(pe),_e(this,L)[Ge]=void 0,_e(this,O)[Ge]=void 0,Ge===_e(this,U))_t(this,U,_e(this,P)[Ge]);else if(Ge===_e(this,M))_t(this,M,_e(this,E)[Ge]);else{const lt=_e(this,P)[Ge];_e(this,E)[lt]=_e(this,E)[Ge];const ut=_e(this,E)[Ge];_e(this,P)[ut]=_e(this,P)[Ge]}Jy(this,S)._--,_e(this,j).push(Ge)}}if(_e(this,he)&&((je=_e(this,q))!=null&&je.length)){const Ge=_e(this,q);let tt;for(;tt=Ge==null?void 0:Ge.shift();)(He=_e(this,v))==null||He.call(this,...tt)}return W},Oe=new WeakSet,x3=function(pe){var we,W,Se;for(const Ae of ct(this,B,ja).call(this,{allowStale:!0})){const je=_e(this,O)[Ae];if(ct(this,xe,pr).call(this,je))je.__abortController.abort(new Error("deleted"));else{const He=_e(this,L)[Ae];_e(this,le)&&((we=_e(this,m))==null||we.call(this,je,He,pe)),_e(this,he)&&((W=_e(this,q))==null||W.push([je,He,pe]))}}if(_e(this,D).clear(),_e(this,O).fill(void 0),_e(this,L).fill(void 0),_e(this,X)&&_e(this,Z)&&(_e(this,X).fill(0),_e(this,Z).fill(0)),_e(this,$)&&_e(this,$).fill(0),_t(this,M,0),_t(this,U,0),_e(this,j).length=0,_t(this,A,0),_t(this,S,0),_e(this,he)&&_e(this,q)){const Ae=_e(this,q);let je;for(;je=Ae==null?void 0:Ae.shift();)(Se=_e(this,v))==null||Se.call(this,...je)}};let h=We;return kf.LRUCache=h,kf}var _8;function sZ(){if(_8)return Vf;_8=1,Object.defineProperty(Vf,"__esModule",{value:!0}),Vf.ActorQueryOperationReducedHash=void 0;const t=wt(),e=os();let u=class extends t.ActorQueryOperationTypedMediated{constructor(n){super(n,"reduced")}async testOperation(n,r){return!0}async runOperation(n,r){const a=t.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:n.input,context:r}));return{type:"bindings",bindingsStream:a.bindingsStream.filter(await this.newHashFilter(r)),metadata:a.metadata}}async newHashFilter(n){const{hashFunction:r}=await this.mediatorHashBindings.mediate({allowHashCollisions:!0,context:n}),a=new e.LRUCache({max:this.cacheSize});return o=>{const l=r(o);return a.has(l)?!1:(a.set(l,!0),!0)}}};return Vf.ActorQueryOperationReducedHash=u,Vf}var v8;function oZ(){return v8||(v8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(sZ(),t)}(S2)),S2}var T2={},zf={},w8;function uZ(){if(w8)return zf;w8=1,Object.defineProperty(zf,"__esModule",{value:!0}),zf.ActorQueryOperationSlice=void 0;const t=wt(),e=Lt;let u=class extends t.ActorQueryOperationTypedMediated{constructor(n){super(n,"slice")}async testOperation(n,r){return!0}async runOperation(n,r){n.length&&(r=r.set(e.KeysQueryOperation.limitIndicator,n.length));const a=await this.mediatorQueryOperation.mediate({operation:n.input,context:r});return a.type==="bindings"?{type:"bindings",bindingsStream:this.sliceStream(a.bindingsStream,n),metadata:this.sliceMetadata(a,n)}:a.type==="quads"?{type:"quads",quadStream:this.sliceStream(a.quadStream,n),metadata:this.sliceMetadata(a,n)}:a}sliceStream(n,r){const a=!!r.length||r.length===0,{start:o}=r,l=a?r.start+r.length-1:Number.POSITIVE_INFINITY;return n.transform({offset:o,limit:Math.max(l-o+1,0),autoStart:!1})}sliceMetadata(n,r){const a=!!r.length||r.length===0;return()=>n.metadata().then(o=>{const l={...o.cardinality};return Number.isFinite(l.value)&&(l.value=Math.max(0,l.value-r.start),a&&(l.value=Math.min(l.value,r.length))),{...o,cardinality:l}})}};return zf.ActorQueryOperationSlice=u,zf}var S8;function cZ(){return S8||(S8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(uZ(),t)}(T2)),T2}var A2={},Gf={},T8;function lZ(){if(T8)return Gf;T8=1,Object.defineProperty(Gf,"__esModule",{value:!0}),Gf.ActorQueryOperationUnion=void 0;const t=wt(),e=Cn(),u=Dt(),s=un();let n=class X1 extends t.ActorQueryOperationTypedMediated{constructor(a){super(a,"union")}static unionVariables(a){return(0,s.uniqTerms)(a.flat())}static async unionMetadata(a,o,l,c){let d=(await c.mediate({mode:"initialize",context:l})).metadata;for(const f of a)d={...f,...(await c.mediate({mode:"append",accumulatedMetadata:d,appendingMetadata:f,context:l})).metadata};d.state=new e.MetadataValidationState;const h=()=>d.state.invalidate();for(const f of a)f.state.addInvalidateListener(h);return o&&(d.variables=X1.unionVariables(a.map(f=>f.variables))),d}async testOperation(a,o){return!0}async runOperation(a,o){const l=await Promise.all(a.input.map(d=>this.mediatorQueryOperation.mediate({operation:d,context:o})));let c;for(const d of l)if(c===void 0)c=d.type;else if(c!==d.type)throw new Error(`Unable to union ${c} and ${d.type}`);if(c==="bindings"||a.input.length===0){const d=l.map(t.ActorQueryOperation.getSafeBindings);return{type:"bindings",bindingsStream:new u.UnionIterator(d.map(p=>p.bindingsStream),{autoStart:!1}),metadata:()=>Promise.all(d.map(p=>p.metadata())).then(p=>X1.unionMetadata(p,!0,o,this.mediatorRdfMetadataAccumulate))}}if(c==="quads"){const d=l.map(t.ActorQueryOperation.getSafeQuads);return{type:"quads",quadStream:new u.UnionIterator(d.map(p=>p.quadStream),{autoStart:!1}),metadata:()=>Promise.all(d.map(p=>p.metadata())).then(p=>X1.unionMetadata(p,!1,o,this.mediatorRdfMetadataAccumulate))}}throw new Error(`Unable to union ${c}`)}};return Gf.ActorQueryOperationUnion=n,Gf}var A8;function J7(){return A8||(A8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(lZ(),t)}(A2)),A2}var E2={},Wf={},O2={},Jf={},Xf={},E8;function X7(){if(E8)return Xf;E8=1,Object.defineProperty(Xf,"__esModule",{value:!0}),Xf.PathVariableObjectIterator=void 0;const t=wt(),e=Dt(),u=Et(),s=Xt(),n=Ot(),r=new u.DataFactory,a=new n.Factory;let o=class extends e.BufferedIterator{constructor(c,d,h,f,p,y,b=16){super({autoStart:!0}),this.subject=c,this.predicate=d,this.graph=h,this.context=f,this.mediatorQueryOperation=p,this.maxRunningOperations=b,this.termHashes=new Map,this.runningOperations=[],this.pendingOperations=[],this._push(this.subject,y)}_end(c){for(const d of this.runningOperations)d.destroy();super._end(c)}_push(c,d=!0){let h;if(d&&(h=(0,s.termToString)(c),this.termHashes.has(h)))return;const f=r.variable("b");this.pendingOperations.push({variable:f,operation:a.createPath(c,this.predicate,f,this.graph)}),h&&(this.termHashes.set(h,c),super._push(c))}_read(c,d){const h=this;(async function(){for(;h.runningOperations.lengthh.destroy(m)),g.on("readable",()=>{h.readable=!0,h._fillBufferAsync()}),g.on("end",()=>{h.runningOperations.splice(h.runningOperations.indexOf(g),1),h.readable=!0,h._fillBufferAsync()})),h.setProperty("metadata",b.metadata)}let f=0,p;for(;f!==(f=c);)for(let y=0;y0;y++)(p=h.runningOperations[y].read())!==null&&(c--,h._push(p));h.runningOperations.length===0&&h.pendingOperations.length===0&&h.close()})().then(()=>{d()},f=>this.destroy(f))}};return Xf.PathVariableObjectIterator=o,Xf}var O8;function dZ(){if(O8)return Jf;O8=1,Object.defineProperty(Jf,"__esModule",{value:!0}),Jf.ActorAbstractPath=void 0;const t=wt(),e=Lt,u=Dt(),s=Et(),n=Xt(),r=Ot(),a=X7(),o=new s.DataFactory;let l=class ha extends t.ActorQueryOperationTypedMediated{constructor(d,h){super(d,"path"),this.predicateType=h}async testOperation(d,h){if(d.predicate.type!==this.predicateType)throw new Error(`This Actor only supports ${this.predicateType} Path operations.`);return!0}generateVariable(d,h){return h?d&&(d.subject.value===h||d.object.value===h)?this.generateVariable(d,`${h}b`):o.variable(h):this.generateVariable(d,"b")}async isPathArbitraryLengthDistinct(d,h){return d.get(e.KeysQueryOperation.isPathArbitraryLengthDistinctKey)?(d=d.set(e.KeysQueryOperation.isPathArbitraryLengthDistinctKey,!1),{context:d,operation:void 0}):(d=d.set(e.KeysQueryOperation.isPathArbitraryLengthDistinctKey,!0),{context:d,operation:t.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:ha.FACTORY.createDistinct(h),context:d}))})}async predicateStarGraphVariable(d,h,f,p,y,b){const g=this.getPathSources(f),m=this.generateVariable(ha.FACTORY.createPath(d,f,h,p)),v=ha.FACTORY.createUnion([this.assignPatternSources(ha.FACTORY.createPattern(d,m,h,p),g),this.assignPatternSources(ha.FACTORY.createPattern(h,m,d,p),g)]),_=t.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({context:y,operation:v})),w=new Set;return{bindingsStream:new u.MultiTransformIterator(_.bindingsStream,{multiTransform:A=>{const D=A.get(p);return w.has(D.value)?new u.EmptyIterator:(w.add(D.value),new u.TransformIterator(async()=>{const L=new u.BufferedIterator;return await this.getObjectsPredicateStar(d,f,D,y,{},L,{count:0}),L.transform({transform(O,E,P){P(b.bindings([[h,O],[p,D]])),E()}})},{maxBufferSize:128}))},autoStart:!1}),metadata:_.metadata}}async getObjectsPredicateStarEval(d,h,f,p,y,b,g){if(p.termType==="Variable")return this.predicateStarGraphVariable(d,f,h,p,y,g);const m=new a.PathVariableObjectIterator(d,h,p,y,this.mediatorQueryOperation,b);return{bindingsStream:m.transform({autoStart:!1,transform(_,w,S){S(g.bindings([[f,_]])),w()}}),async metadata(){const _=await new Promise(w=>{m.getProperty("metadata",S=>w(S()))});return _.cardinality.value++,_}}}async getObjectsPredicateStar(d,h,f,p,y,b,g){const m=(0,n.termToString)(d);if(y[m])return;b._push(d),y[m]=d,g.count++;const v=this.generateVariable(),_=ha.FACTORY.createPath(d,h,v,f),w=t.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:_,context:p}));return w.bindingsStream.on("data",async S=>{const A=S.get(v);await this.getObjectsPredicateStar(A,h,f,p,y,b,g)}),w.bindingsStream.on("end",()=>{--g.count===0&&b.close()}),w.metadata}async getSubjectAndObjectBindingsPredicateStar(d,h,f,p,y,b,g,m,v,_,w,S){const A=(0,n.termToString)(p)+(0,n.termToString)(b);if(v[A])return;if(w.count++,v[A]=!0,_._push(S.bindings([[d,f],[h,p]])),A in m){const L=await m[A];for(const O of L)await this.getSubjectAndObjectBindingsPredicateStar(d,h,f,O,y,b,g,m,v,_,w,S);--w.count===0&&_.close();return}const D=new Promise(async(L,O)=>{const E=[],P=this.generateVariable(),M=ha.FACTORY.createPath(p,y,P,b),U=t.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:M,context:g}));U.bindingsStream.on("data",async j=>{const q=j.get(P);E.push(q),await this.getSubjectAndObjectBindingsPredicateStar(d,h,f,q,y,b,g,m,v,_,w,S)}),U.bindingsStream.on("error",O),U.bindingsStream.on("end",()=>{--w.count===0&&_.close(),L(E)})});m[A]=D}getPathSources(d){switch(d.type){case r.Algebra.types.ALT:case r.Algebra.types.SEQ:return d.input.flatMap(h=>this.getPathSources(h));case r.Algebra.types.INV:case r.Algebra.types.ONE_OR_MORE_PATH:case r.Algebra.types.ZERO_OR_MORE_PATH:case r.Algebra.types.ZERO_OR_ONE_PATH:return this.getPathSources(d.path);case r.Algebra.types.LINK:case r.Algebra.types.NPS:{const h=t.ActorQueryOperation.getOperationSource(d);if(!h)throw new Error("Could not find a required source on a link path operation");return[h]}}}assignPatternSources(d,h){if(h.length===0)throw new Error("Attempted to assign zero sources to a pattern during property path handling");return h.length===1?t.ActorQueryOperation.assignOperationSource(d,h[0]):ha.FACTORY.createUnion(h.map(f=>t.ActorQueryOperation.assignOperationSource(d,f)),!0)}};return Jf.ActorAbstractPath=l,l.FACTORY=new r.Factory,Jf}var R8;function us(){return R8||(R8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(dZ(),t),u(X7(),t)}(O2)),O2}var x8;function fZ(){if(x8)return Wf;x8=1,Object.defineProperty(Wf,"__esModule",{value:!0}),Wf.ActorQueryOperationPathAlt=void 0;const t=us(),e=J7(),u=wt(),s=Dt(),n=Ot();let r=class extends t.ActorAbstractPath{constructor(o){super(o,n.Algebra.types.ALT)}async runOperation(o,l){const c=o.predicate,d=(await Promise.all(c.input.map(p=>this.mediatorQueryOperation.mediate({context:l,operation:t.ActorAbstractPath.FACTORY.createPath(o.subject,p,o.object,o.graph)})))).map(u.ActorQueryOperation.getSafeBindings);return{type:"bindings",bindingsStream:new s.UnionIterator(d.map(p=>p.bindingsStream),{autoStart:!1}),metadata:()=>Promise.all(d.map(p=>p.metadata())).then(p=>e.ActorQueryOperationUnion.unionMetadata(p,!0,l,this.mediatorRdfMetadataAccumulate))}}};return Wf.ActorQueryOperationPathAlt=r,Wf}var I8;function hZ(){return I8||(I8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(fZ(),t)}(E2)),E2}var R2={},Kf={},P8;function pZ(){if(P8)return Kf;P8=1,Object.defineProperty(Kf,"__esModule",{value:!0}),Kf.ActorQueryOperationPathInv=void 0;const t=us(),e=Ot();let u=class extends t.ActorAbstractPath{constructor(n){super(n,e.Algebra.types.INV)}async runOperation(n,r){const a=n.predicate,o=t.ActorAbstractPath.FACTORY.createPath(n.object,a.path,n.subject,n.graph);return this.mediatorQueryOperation.mediate({operation:o,context:r})}};return Kf.ActorQueryOperationPathInv=u,Kf}var D8;function yZ(){return D8||(D8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(pZ(),t)}(R2)),R2}var x2={},Yf={},N8;function bZ(){if(N8)return Yf;N8=1,Object.defineProperty(Yf,"__esModule",{value:!0}),Yf.ActorQueryOperationPathNps=void 0;const t=us(),e=wt(),u=Ot();let s=class extends t.ActorAbstractPath{constructor(r){super(r,u.Algebra.types.NPS)}async runOperation(r,a){const o=r.predicate,l=this.generateVariable(r),c=Object.assign(t.ActorAbstractPath.FACTORY.createPattern(r.subject,l,r.object,r.graph),{metadata:o.metadata}),d=e.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:c,context:a}));return{type:"bindings",bindingsStream:d.bindingsStream.map(f=>o.iris.some(p=>p.equals(f.get(l)))?null:f.delete(l)),metadata:d.metadata}}};return Yf.ActorQueryOperationPathNps=s,Yf}var C8;function mZ(){return C8||(C8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(bZ(),t)}(x2)),x2}var I2={},Zf={},j8;function gZ(){if(j8)return Zf;j8=1,Object.defineProperty(Zf,"__esModule",{value:!0}),Zf.ActorQueryOperationPathLink=void 0;const t=us(),e=Ot();let u=class extends t.ActorAbstractPath{constructor(n){super(n,e.Algebra.types.LINK)}async runOperation(n,r){const a=n.predicate,o=Object.assign(t.ActorAbstractPath.FACTORY.createPattern(n.subject,a.iri,n.object,n.graph),{metadata:a.metadata});return this.mediatorQueryOperation.mediate({operation:o,context:r})}};return Zf.ActorQueryOperationPathLink=u,Zf}var L8;function _Z(){return L8||(L8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(gZ(),t)}(I2)),I2}var P2={},eh={},M8;function vZ(){if(M8)return eh;M8=1,Object.defineProperty(eh,"__esModule",{value:!0}),eh.ActorQueryOperationClear=void 0;const t=wt(),e=Et(),u=new e.DataFactory;let s=class extends t.ActorQueryOperationTypedMediated{constructor(r){super(r,"clear")}async testOperation(r,a){return t.ActorQueryOperation.throwOnReadOnly(a),!0}async runOperation(r,a){let o;r.source==="DEFAULT"?o=u.defaultGraph():typeof r.source=="string"?o=r.source:o=[r.source];const{execute:l}=await this.mediatorUpdateQuads.mediate({deleteGraphs:{graphs:o,requireExistence:!r.silent,dropGraphs:!1},context:a});return{type:"void",execute:l}}};return eh.ActorQueryOperationClear=s,eh}var F8;function wZ(){return F8||(F8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(vZ(),t)}(P2)),P2}var D2={},th={},q8;function SZ(){if(q8)return th;q8=1,Object.defineProperty(th,"__esModule",{value:!0}),th.ActorQueryOperationUpdateCompositeUpdate=void 0;const t=wt();let e=class extends t.ActorQueryOperationTypedMediated{constructor(s){super(s,"compositeupdate")}async testOperation(s,n){return t.ActorQueryOperation.throwOnReadOnly(n),!0}async runOperation(s,n){return{type:"void",execute:()=>(async()=>{for(const a of s.updates)await t.ActorQueryOperation.getSafeVoid(await this.mediatorQueryOperation.mediate({operation:a,context:n})).execute()})()}}};return th.ActorQueryOperationUpdateCompositeUpdate=e,th}var B8;function TZ(){return B8||(B8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(SZ(),t)}(D2)),D2}var N2={},rh={},U8;function AZ(){if(U8)return rh;U8=1,Object.defineProperty(rh,"__esModule",{value:!0}),rh.ActorQueryOperationCreate=void 0;const t=wt();let e=class extends t.ActorQueryOperationTypedMediated{constructor(s){super(s,"create")}async testOperation(s,n){return t.ActorQueryOperation.throwOnReadOnly(n),!0}async runOperation(s,n){const{execute:r}=await this.mediatorUpdateQuads.mediate({createGraphs:{graphs:[s.source],requireNonExistence:!s.silent},context:n});return{type:"void",execute:r}}};return rh.ActorQueryOperationCreate=e,rh}var Q8;function EZ(){return Q8||(Q8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(AZ(),t)}(N2)),N2}var C2={},nh={},H8;function OZ(){if(H8)return nh;H8=1,Object.defineProperty(nh,"__esModule",{value:!0}),nh.ActorQueryOperationDrop=void 0;const t=wt(),e=Et(),u=new e.DataFactory;let s=class extends t.ActorQueryOperationTypedMediated{constructor(r){super(r,"drop")}async testOperation(r,a){return t.ActorQueryOperation.throwOnReadOnly(a),!0}async runOperation(r,a){let o;r.source==="DEFAULT"?o=u.defaultGraph():typeof r.source=="string"?o=r.source:o=[r.source];const{execute:l}=await this.mediatorUpdateQuads.mediate({deleteGraphs:{graphs:o,requireExistence:!r.silent,dropGraphs:!0},context:a});return{type:"void",execute:l}}};return nh.ActorQueryOperationDrop=s,nh}var $8;function RZ(){return $8||($8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(OZ(),t)}(C2)),C2}var j2={},ih={},V8;function xZ(){if(V8)return ih;V8=1,Object.defineProperty(ih,"__esModule",{value:!0}),ih.ActorQueryOperationLoad=void 0;const t=wt(),e=Lt,u=Et(),s=Ot(),n=new u.DataFactory;let r=class K7 extends t.ActorQueryOperationTypedMediated{constructor(o){super(o,"load"),this.factory=new s.Factory}async testOperation(o,l){return t.ActorQueryOperation.throwOnReadOnly(l),!0}async runOperation(o,l){let c=l;o.silent&&(c=c.set(e.KeysInitQuery.lenient,!0));const{querySource:d}=await this.mediatorQuerySourceIdentify.mediate({querySourceUnidentified:{value:o.source.value},context:c});let f=K7.getSafeQuads(await this.mediatorQueryOperation.mediate({operation:this.factory.createConstruct(t.ActorQueryOperation.assignOperationSource(this.factory.createPattern(n.variable("s"),n.variable("p"),n.variable("o")),d),[this.factory.createPattern(n.variable("s"),n.variable("p"),n.variable("o"))]),context:c})).quadStream;o.destination&&(f=f.map(y=>n.quad(y.subject,y.predicate,y.object,o.destination)));const{execute:p}=await this.mediatorUpdateQuads.mediate({quadStreamInsert:f,context:l});return{type:"void",execute:p}}};return ih.ActorQueryOperationLoad=r,ih}var k8;function IZ(){return k8||(k8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(xZ(),t)}(j2)),j2}var L2={},ah={},z8;function PZ(){if(z8)return ah;z8=1,Object.defineProperty(ah,"__esModule",{value:!0}),ah.ActorQueryOperationJoin=void 0;const t=wt();let e=class extends t.ActorQueryOperationTypedMediated{constructor(s){super(s,"join")}async testOperation(s,n){return!0}async runOperation(s,n){const r=(await Promise.all(s.input.map(async a=>({output:await this.mediatorQueryOperation.mediate({operation:a,context:n}),operation:a})))).map(({output:a,operation:o})=>({output:t.ActorQueryOperation.getSafeBindings(a),operation:o}));return this.mediatorJoin.mediate({type:"inner",entries:r,context:n})}};return ah.ActorQueryOperationJoin=e,ah}var G8;function DZ(){return G8||(G8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(PZ(),t)}(L2)),L2}var M2={},sh={},W8;function NZ(){if(W8)return sh;W8=1,Object.defineProperty(sh,"__esModule",{value:!0}),sh.ActorQueryOperationMinus=void 0;const t=wt();let e=class extends t.ActorQueryOperationTypedMediated{constructor(s){super(s,"minus")}async testOperation(s,n){return!0}async runOperation(s,n){const r=(await Promise.all(s.input.map(async a=>({output:await this.mediatorQueryOperation.mediate({operation:a,context:n}),operation:a})))).map(({output:a,operation:o})=>({output:t.ActorQueryOperation.getSafeBindings(a),operation:o}));return this.mediatorJoin.mediate({type:"minus",entries:r,context:n})}};return sh.ActorQueryOperationMinus=e,sh}var J8;function CZ(){return J8||(J8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(NZ(),t)}(M2)),M2}var F2={},oh={},X8;function jZ(){if(X8)return oh;X8=1,Object.defineProperty(oh,"__esModule",{value:!0}),oh.ActorQueryOperationPathSeq=void 0;const t=us(),e=wt(),u=Ot();let s=class extends t.ActorAbstractPath{constructor(r){super(r,u.Algebra.types.SEQ)}async runOperation(r,a){const o=r.predicate;let l=r.subject;const c=[],d=await Promise.all(o.input.map((p,y)=>{const b=y===o.input.length-1?r.object:this.generateVariable(r,`b${y}`),g=t.ActorAbstractPath.FACTORY.createPath(l,p,b,r.graph),m=this.mediatorQueryOperation.mediate({context:a,operation:g});return l=b,y({output:e.ActorQueryOperation.getSafeBindings(await p),operation:y}))),h=e.ActorQueryOperation.getSafeBindings(await this.mediatorJoin.mediate({type:"inner",entries:d,context:a}));return{type:"bindings",bindingsStream:h.bindingsStream.transform({transform(p,y,b){for(const g of c)p=p.delete(g);b(p),y()}}),async metadata(){const p=await h.metadata(),y=p.variables.filter(b=>!c.some(g=>g.value===b.value));return{...p,variables:y}}}}};return oh.ActorQueryOperationPathSeq=s,oh}var K8;function LZ(){return K8||(K8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(jZ(),t)}(F2)),F2}var q2={},uh={},Y8;function MZ(){if(Y8)return uh;Y8=1,Object.defineProperty(uh,"__esModule",{value:!0}),uh.ActorRdfJoinMultiSmallest=void 0;const t=wt(),e=jn(),u=Ot();let s=class Y7 extends e.ActorRdfJoin{constructor(r){super(r,{logicalType:"inner",physicalName:"multi-smallest",limitEntries:3,limitEntriesMin:!0,canHandleUndefs:!0,isLeaf:!1})}async sortJoinEntries(r,a){return(await this.mediatorJoinEntriesSort.mediate({entries:r,context:a})).entries}async getOutput(r){const a=await this.sortJoinEntries(await e.ActorRdfJoin.getEntriesWithMetadatas([...r.entries]),r.context),o=a[0],l=a[1];a.splice(0,2);const c={output:t.ActorQueryOperation.getSafeBindings(await this.mediatorJoin.mediate({type:r.type,entries:[o,l],context:r.context})),operation:Y7.FACTORY.createJoin([o.operation,l.operation],!1)};return a.push(c),{result:await this.mediatorJoin.mediate({type:r.type,entries:a,context:r.context})}}async getJoinCoefficients(r,a){a=[...a],a=(await this.sortJoinEntries(r.entries.map((d,h)=>({...d,metadata:a[h]})),r.context)).map(d=>d.metadata);const l=e.ActorRdfJoin.getRequestInitialTimes(a),c=e.ActorRdfJoin.getRequestItemTimes(a);return{iterations:a[0].cardinality.value*a[1].cardinality.value*a.slice(2).reduce((d,h)=>d*h.cardinality.value,1),persistedItems:0,blockingItems:0,requestTime:l[0]+a[0].cardinality.value*c[0]+l[1]+a[1].cardinality.value*c[1]+a.slice(2).reduce((d,h,f)=>d+l.slice(2)[f]+h.cardinality.value*c.slice(2)[f],0)}}};return uh.ActorRdfJoinMultiSmallest=s,s.FACTORY=new u.Factory,uh}var Z8;function FZ(){return Z8||(Z8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(MZ(),t)}(q2)),q2}var B2={},ch={},U2={},lh={},dh={},e5;function Z7(){if(e5)return dh;e5=1,Object.defineProperty(dh,"__esModule",{value:!0}),dh.bindingsToString=void 0;const t=Xt();function e(u){const s={};for(const n of u.keys())s[n.value]=(0,t.termToString)(u.get(n));return JSON.stringify(s,null," ")}return dh.bindingsToString=e,dh}var t5;function eB(){if(t5)return lh;t5=1,Object.defineProperty(lh,"__esModule",{value:!0}),lh.Bindings=void 0;const t=ot,e=BT,u=Z7();let s=class ni{constructor(r,a,o){this.type="bindings",this.dataFactory=r,this.entries=a,this.contextHolder=o}has(r){return this.entries.has(typeof r=="string"?r:r.value)}get(r){return this.entries.get(typeof r=="string"?r:r.value)}set(r,a){return new ni(this.dataFactory,this.entries.set(typeof r=="string"?r:r.value,a),this.contextHolder)}delete(r){return new ni(this.dataFactory,this.entries.delete(typeof r=="string"?r:r.value),this.contextHolder)}keys(){return this.mapIterable(this.iteratorToIterable(this.entries.keys()),r=>this.dataFactory.variable(r))}values(){return this.iteratorToIterable(this.entries.values())}forEach(r){for(const[a,o]of this.entries.entries())r(o,this.dataFactory.variable(a))}get size(){return this.entries.size}[Symbol.iterator](){return this.mapIterable(this.iteratorToIterable(this.entries.entries()),([r,a])=>[this.dataFactory.variable(r),a])[Symbol.iterator]()}equals(r){var a;if(!r)return!1;if(this===r)return!0;if(this.size!==r.size)return!1;for(const o of this.keys())if(!((a=this.get(o))!=null&&a.equals(r.get(o))))return!1;return!0}filter(r){return new ni(this.dataFactory,(0,e.Map)(this.entries.filter((a,o)=>r(a,this.dataFactory.variable(o)))),this.contextHolder)}map(r){return new ni(this.dataFactory,(0,e.Map)(this.entries.map((a,o)=>r(a,this.dataFactory.variable(o)))),this.contextHolder)}merge(r){const a=new Set([...this.iteratorToIterable(this.entries.keys()),...[...r.keys()].map(l=>l.value)]),o=[];for(const l of a){const c=this.entries.get(l),d=r.get(this.dataFactory.variable(l));if(c&&d&&!c.equals(d))return;const h=c||d;o.push([l,h])}return this.createBindingsWithContexts(o,r)}mergeWith(r,a){const o=new Set([...this.iteratorToIterable(this.entries.keys()),...[...a.keys()].map(c=>c.value)]),l=[];for(const c of o){const d=this.dataFactory.variable(c),h=this.entries.get(c),f=a.get(d);let p;h&&f&&!h.equals(f)?p=r(h,f,d):p=h||f,l.push([c,p])}return this.createBindingsWithContexts(l,a)}createBindingsWithContexts(r,a){if(this.contextHolder&&this.contextHolder.context){let o=this.contextHolder.context;return"contextHolder"in a&&a.contextHolder&&a.contextHolder.context&&(o=ni.mergeContext(this.contextHolder.contextMergeHandlers,o,a.contextHolder.context)),new ni(this.dataFactory,(0,e.Map)(r),{contextMergeHandlers:this.contextHolder.contextMergeHandlers,context:o})}return new ni(this.dataFactory,(0,e.Map)(r),a.contextHolder)}static mergeContext(r,a,o){const l=[...a.keys(),...o.keys()],c={},d={},h=new Set(o.keys().map(p=>p.name)),f=a.keys().filter(p=>h.has(p.name));for(const p of l){if(d[p.name]===1)continue;d[p.name]=1;const y=f.some(b=>b.name===p.name);if(r[p.name]&&y){c[p.name]=r[p.name].run(a.get(p),o.get(p));continue}if(!(!r[p.name]&&y)){if(!a.get(p)){c[p.name]=o.get(p);continue}o.get(p)||(c[p.name]=a.get(p))}}return new t.ActionContext(c)}setContextEntry(r,a){return this.setContextEntryRaw(r,a)}setContextEntryRaw(r,a){var o;return this.contextHolder&&this.contextHolder.context?new ni(this.dataFactory,this.entries,{contextMergeHandlers:this.contextHolder.contextMergeHandlers,context:this.contextHolder.context.set(r,a)}):new ni(this.dataFactory,this.entries,{contextMergeHandlers:((o=this.contextHolder)==null?void 0:o.contextMergeHandlers)??{},context:new t.ActionContext().set(r,a)})}deleteContextEntry(r){return this.deleteContextEntryRaw(r)}deleteContextEntryRaw(r){var a;return this.contextHolder?new ni(this.dataFactory,this.entries,{contextMergeHandlers:this.contextHolder.contextMergeHandlers,context:(a=this.contextHolder.context)==null?void 0:a.delete(r)}):new ni(this.dataFactory,this.entries)}getContext(){var r;return(r=this.contextHolder)==null?void 0:r.context}getContextEntry(r){var a;return(a=this.getContext())==null?void 0:a.get(r)}toString(){return(0,u.bindingsToString)(this)}*mapIterable(r,a){for(const o of r)yield a(o)}iteratorToIterable(r){return{[Symbol.iterator]:()=>r}}};return lh.Bindings=s,lh}var fh={},r5;function qZ(){if(r5)return fh;r5=1,Object.defineProperty(fh,"__esModule",{value:!0}),fh.BindingsFactory=void 0;const t=BT,e=Et(),u=eB();let s=class tB{constructor(r=new e.DataFactory,a){this.dataFactory=r,this.contextMergeHandlers=a}static async create(r,a){return new tB(new e.DataFactory,(await r.mediate({context:a})).mergeHandlers)}bindings(r=[]){return new u.Bindings(this.dataFactory,(0,t.Map)(r.map(([a,o])=>[a.value,o])),this.contextMergeHandlers?{contextMergeHandlers:this.contextMergeHandlers}:void 0)}fromBindings(r){return this.bindings([...r])}fromRecord(r){return this.bindings(Object.entries(r).map(([a,o])=>[this.dataFactory.variable(a),o]))}};return fh.BindingsFactory=s,fh}var n5;function xr(){return n5||(n5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(eB(),t),u(qZ(),t),u(Z7(),t)}(U2)),U2}var i5;function BZ(){if(i5)return ch;i5=1,Object.defineProperty(ch,"__esModule",{value:!0}),ch.ActorRdfJoinMultiSmallestFilterBindings=void 0;const t=xr(),e=wt(),u=jn(),s=Lt,n=Dt(),r=Ot();let a=class rB extends u.ActorRdfJoin{constructor(l){super(l,{logicalType:"inner",physicalName:"multi-smallest-filter-bindings",limitEntries:2,limitEntriesMin:!0,isLeaf:!1})}async sortJoinEntries(l,c){let{entries:d}=await this.mediatorJoinEntriesSort.mediate({entries:l,context:c});d=d.sort((g,m)=>g.operationModified&&!m.operationModified?-1:0);const h=d.splice(0,1)[0];let f,p=-1,y=0;for(const[g,m]of d.entries()){const v=h.metadata.variables.filter(_=>m.metadata.variables.some(w=>_.equals(w))).length;(!f||v>y||v===y&&(m.metadata.variables.lengthh.metadata.variables.some(L=>D.equals(L))),b={},g=p.clone().map(D=>D.filter((L,O)=>y.some(E=>E.equals(O)))).filter(D=>{const L=(0,t.bindingsToString)(D);return!(L in b)&&(b[L]=!0)}),m=new u.ChunkedIterator(g,this.blockSize,{autoStart:!1}),v=e.ActorQueryOperation.getOperationSource(h.operation),w={output:{type:"bindings",bindingsStream:new n.UnionIterator(m.map(D=>v.source.queryBindings(h.operation,v.context?l.context.merge(v.context):l.context,{filterBindings:{bindings:D,metadata:d.metadata}}))),metadata:h.output.metadata},operation:h.operation,operationModified:!0};h.output.bindingsStream.destroy();const S={output:e.ActorQueryOperation.getSafeBindings(await this.mediatorJoin.mediate({type:l.type,entries:[d,w],context:l.context.set(s.KeysRdfJoin.lastPhysicalJoin,this.physicalName)})),operation:rB.FACTORY.createJoin([d.operation,w.operation],!1),operationModified:!0},A=f;return A.unshift(S),{result:await this.mediatorJoin.mediate({type:l.type,entries:A,context:l.context}),physicalPlanMetadata:{firstIndex:c.indexOf(d),secondIndex:c.indexOf(h)}}}async getJoinCoefficients(l,c){if(l.context.get(s.KeysRdfJoin.lastPhysicalJoin)===this.physicalName)throw new Error(`Actor ${this.name} can not be called recursively`);c=[...c];const{first:d,second:h,remaining:f}=await this.sortJoinEntries(l.entries.map((w,S)=>({...w,metadata:c[S]})),l.context),p=e.ActorQueryOperation.getOperationSource(h.operation);if(!p)throw new Error(`Actor ${this.name} can only process if entries[1] has a source`);const y=h.operation,b=await p.source.getSelectorShape(l.context);if(!e.ActorQueryOperation.doesShapeAcceptOperation(b,y,{filterBindings:!0}))throw new Error(`Actor ${this.name} can only process if entries[1] accept filterBindings`);c=[d.metadata,h.metadata,...f.map(w=>w.metadata)];const g=u.ActorRdfJoin.getRequestInitialTimes(c),m=u.ActorRdfJoin.getRequestItemTimes(c),{selectivity:v}=await this.mediatorJoinSelectivity.mediate({entries:[d,h],context:l.context}),_=f.reduce((w,S)=>w*S.metadata.cardinality.value*this.selectivityModifier,1);return{iterations:v*this.selectivityModifier*h.metadata.cardinality.value*_,persistedItems:d.metadata.cardinality.value,blockingItems:d.metadata.cardinality.value,requestTime:g[0]+c[0].cardinality.value*m[0]+g[1]+_*m[1]}}};return ch.ActorRdfJoinMultiSmallestFilterBindings=a,a.FACTORY=new r.Factory,ch}var a5;function UZ(){return a5||(a5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(BZ(),t)}(B2)),B2}var Q2={},hh={},s5;function QZ(){if(s5)return hh;s5=1,Object.defineProperty(hh,"__esModule",{value:!0}),hh.ActorOptimizeQueryOperationFilterPushdown=void 0;const t=di(),e=wt(),u=un(),s=Ot();let n=class extends t.ActorOptimizeQueryOperation{constructor(a){super(a)}async test(a){return!0}async run(a){let o=a.operation;const l=this;this.splitConjunctive&&(o=s.Util.mapOperation(o,{filter(p,y){return p.expression.expressionType===s.Algebra.expressionTypes.OPERATOR&&p.expression.operator==="&&"?(l.logDebug(a.context,`Split conjunctive filter into ${p.expression.args.length} nested filters`),{recurse:!0,result:p.expression.args.reduce((b,g)=>y.createFilter(b,g),p.input)}):{recurse:!0,result:p}}}));const c=this.getSources(o),d=new Map(await Promise.all(c.map(async p=>[p,await p.source.getSelectorShape(a.context)])));let h=!0,f=0;for(;h&&f1&&l.logDebug(a.context,`Pushed down filters in ${f} iterations`),this.mergeConjunctive&&(o=s.Util.mapOperation(o,{filter(p,y){if(p.input.type===s.Algebra.types.FILTER){const{nestedExpressions:b,input:g}=l.getNestedFilterExpressions(p);return l.logDebug(a.context,`Merge ${b.length} nested filters into conjunctive filter`),{recurse:!0,result:y.createFilter(g,b.slice(1).reduce((m,v)=>y.createOperatorExpression("&&",[m,v]),b[0]))}}return{recurse:!0,result:p}}})),{operation:o,context:a.context}}shouldAttemptPushDown(a,o,l){if(this.aggressivePushdown)return!0;const c=a.expression;return!!(c.expressionType===s.Algebra.expressionTypes.OPERATOR&&c.operator==="="&&(c.args[0].expressionType==="term"&&c.args[0].term.termType!=="Variable"&&c.args[1].expressionType==="term"&&c.args[1].term.termType==="Variable"||c.args[0].expressionType==="term"&&c.args[0].term.termType==="Variable"&&c.args[1].expressionType==="term"&&c.args[1].term.termType!=="Variable")||o.some(d=>e.ActorQueryOperation.doesShapeAcceptOperation(l.get(d),a)))}getSources(a){const o=new Set,l=c=>{const d=e.ActorQueryOperation.getOperationSource(c);return d&&o.add(d),!1};return s.Util.recurseOperation(a,{[s.Algebra.types.PATTERN]:l,[s.Algebra.types.LINK]:l,[s.Algebra.types.NPS]:l,[s.Algebra.types.SERVICE]:l}),[...o]}getExpressionVariables(a){switch(a.expressionType){case s.Algebra.expressionTypes.AGGREGATE:case s.Algebra.expressionTypes.WILDCARD:throw new Error(`Getting expression variables is not supported for ${a.expressionType}`);case s.Algebra.expressionTypes.EXISTENCE:return s.Util.inScopeVariables(a.input);case s.Algebra.expressionTypes.NAMED:return[];case s.Algebra.expressionTypes.OPERATOR:return(0,u.uniqTerms)(a.args.flatMap(o=>this.getExpressionVariables(o)));case s.Algebra.expressionTypes.TERM:return a.term.termType==="Variable"?[a.term]:[]}}getOverlappingOperations(a,o){const l=[],c=[],d=[];for(const h of a.input){const f=s.Util.inScopeVariables(h);this.variablesSubSetOf(o,f)?l.push(h):this.variablesIntersect(o,f)?c.push(h):d.push(h)}return{fullyOverlapping:l,partiallyOverlapping:c,notOverlapping:d}}filterPushdown(a,o,l,c,d){if(this.isExpressionFalse(a))return[!0,c.createUnion([])];if(a.type===s.Algebra.types.EXPRESSION&&a.expressionType===s.Algebra.expressionTypes.EXISTENCE)return[!1,c.createFilter(l,a)];switch(l.type){case s.Algebra.types.EXTEND:return this.variablesIntersect([l.variable],o)?[!1,c.createFilter(l,a)]:[!0,c.createExtend(this.filterPushdown(a,o,l.input,c,d)[1],l.variable,l.expression)];case s.Algebra.types.FILTER:{const[h,f]=this.filterPushdown(a,o,l.input,c,d);return[h,c.createFilter(f,l.expression)]}case s.Algebra.types.JOIN:{if(l.input.length===0)return[!1,c.createFilter(l,a)];const{fullyOverlapping:h,partiallyOverlapping:f,notOverlapping:p}=this.getOverlappingOperations(l,o),y=[];let b=!1;return h.length>0&&(b=!0,y.push(c.createJoin(h.map(g=>this.filterPushdown(a,o,g,c,d)[1])))),f.length>0&&y.push(c.createFilter(c.createJoin(f,!1),a)),p.length>0&&y.push(...p),y.length>1&&(b=!0),b&&this.logDebug(d,`Push down filter across join entries with ${h.length} fully overlapping, ${f.length} partially overlapping, and ${p.length} not overlapping`),[b,y.length===1?y[0]:c.createJoin(y)]}case s.Algebra.types.NOP:return[!0,l];case s.Algebra.types.PROJECT:return this.variablesIntersect(l.variables,o)?[!0,c.createProject(this.filterPushdown(a,o,l.input,c,d)[1],l.variables)]:[!0,l];case s.Algebra.types.UNION:{const{fullyOverlapping:h,partiallyOverlapping:f,notOverlapping:p}=this.getOverlappingOperations(l,o),y=[];let b=!1;return h.length>0&&(b=!0,y.push(c.createUnion(h.map(g=>this.filterPushdown(a,o,g,c,d)[1])))),f.length>0&&y.push(c.createFilter(c.createUnion(f,!1),a)),p.length>0&&y.push(...p),y.length>1&&(b=!0),b&&this.logDebug(d,`Push down filter across union entries with ${h.length} fully overlapping, ${f.length} partially overlapping, and ${p.length} not overlapping`),[b,y.length===1?y[0]:c.createUnion(y)]}case s.Algebra.types.VALUES:return this.variablesIntersect(l.variables,o)?[!1,c.createFilter(l,a)]:[!0,l];case s.Algebra.types.LEFT_JOIN:{if(this.pushIntoLeftJoins){const h=s.Util.inScopeVariables(l.input[1]);if(!this.variablesIntersect(o,h))return this.logDebug(d,"Push down filter into left join"),[!0,c.createLeftJoin(this.filterPushdown(a,o,l.input[0],c,d)[1],l.input[1],l.expression)]}return[!1,c.createFilter(l,a)]}case s.Algebra.types.PATTERN:{if(this.pushEqualityIntoPatterns){const h=this.getEqualityExpressionPushableIntoPattern(a);if(h){let f=!1;const p=l.metadata;if(l=(0,u.mapTermsNested)(l,y=>y.equals(h.variable)?(f=!0,h.term):y),l.type=s.Algebra.types.PATTERN,l.metadata=p,f)return this.logDebug(d,`Push down filter into pattern for ?${h.variable.value}`),[!0,c.createJoin([l,c.createValues([h.variable],[{[`?${h.variable.value}`]:h.term}])])]}}return[!1,c.createFilter(l,a)]}case s.Algebra.types.PATH:{if(this.pushEqualityIntoPatterns){const h=this.getEqualityExpressionPushableIntoPattern(a);if(h&&(l.subject.equals(h.variable)||l.object.equals(h.variable))){this.logDebug(d,`Push down filter into path for ?${h.variable.value}`);const f=l.metadata;return l=c.createPath(l.subject.equals(h.variable)?h.term:l.subject,l.predicate,l.object.equals(h.variable)?h.term:l.object),l.metadata=f,[!0,c.createJoin([l,c.createValues([h.variable],[{[`?${h.variable.value}`]:h.term}])])]}}return[!1,c.createFilter(l,a)]}case s.Algebra.types.MINUS:case s.Algebra.types.ALT:case s.Algebra.types.ASK:case s.Algebra.types.BGP:case s.Algebra.types.CONSTRUCT:case s.Algebra.types.DESCRIBE:case s.Algebra.types.DISTINCT:case s.Algebra.types.EXPRESSION:case s.Algebra.types.FROM:case s.Algebra.types.GRAPH:case s.Algebra.types.GROUP:case s.Algebra.types.INV:case s.Algebra.types.LINK:case s.Algebra.types.NPS:case s.Algebra.types.ONE_OR_MORE_PATH:case s.Algebra.types.ORDER_BY:case s.Algebra.types.REDUCED:case s.Algebra.types.SEQ:case s.Algebra.types.SERVICE:case s.Algebra.types.SLICE:case s.Algebra.types.ZERO_OR_MORE_PATH:case s.Algebra.types.ZERO_OR_ONE_PATH:case s.Algebra.types.COMPOSITE_UPDATE:case s.Algebra.types.DELETE_INSERT:case s.Algebra.types.LOAD:case s.Algebra.types.CLEAR:case s.Algebra.types.CREATE:case s.Algebra.types.DROP:case s.Algebra.types.ADD:case s.Algebra.types.MOVE:case s.Algebra.types.COPY:return[!1,c.createFilter(l,a)]}}getEqualityExpressionPushableIntoPattern(a){if(a.expressionType===s.Algebra.expressionTypes.OPERATOR&&a.operator==="="){if(a.args[0].expressionType==="term"&&a.args[0].term.termType!=="Variable"&&(a.args[0].term.termType!=="Literal"||this.isLiteralWithCanonicalLexicalForm(a.args[0].term))&&a.args[1].expressionType==="term"&&a.args[1].term.termType==="Variable")return{variable:a.args[1].term,term:a.args[0].term};if(a.args[0].expressionType==="term"&&a.args[0].term.termType==="Variable"&&a.args[1].expressionType==="term"&&a.args[1].term.termType!=="Variable"&&(a.args[1].term.termType!=="Literal"||this.isLiteralWithCanonicalLexicalForm(a.args[1].term)))return{variable:a.args[0].term,term:a.args[1].term}}}isLiteralWithCanonicalLexicalForm(a){if(a.termType==="Literal")switch(a.datatype.value){case"http://www.w3.org/2001/XMLSchema#string":case"http://www.w3.org/1999/02/22-rdf-syntax-ns#langString":case"http://www.w3.org/2001/XMLSchema#normalizedString":case"http://www.w3.org/2001/XMLSchema#anyURI":case"http://www.w3.org/2001/XMLSchema#base64Binary":case"http://www.w3.org/2001/XMLSchema#language":case"http://www.w3.org/2001/XMLSchema#Name":case"http://www.w3.org/2001/XMLSchema#NCName":case"http://www.w3.org/2001/XMLSchema#NMTOKEN":case"http://www.w3.org/2001/XMLSchema#token":case"http://www.w3.org/2001/XMLSchema#hexBinary":return!0}return!1}variablesIntersect(a,o){return a.some(l=>o.some(c=>l.equals(c)))}variablesSubSetOf(a,o){return a.length<=o.length&&a.every(l=>o.some(c=>l.equals(c)))}isExpressionFalse(a){return a.term&&a.term.termType==="Literal"&&a.term.value==="false"}getNestedFilterExpressions(a){if(a.input.type===s.Algebra.types.FILTER){const o=this.getNestedFilterExpressions(a.input);return{nestedExpressions:[a.expression,...o.nestedExpressions],input:o.input}}return{nestedExpressions:[a.expression],input:a.input}}};return hh.ActorOptimizeQueryOperationFilterPushdown=n,hh}var o5;function HZ(){return o5||(o5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(QZ(),t)}(Q2)),Q2}var H2={},ph={},Ps={},u5;function nB(){if(u5)return Ps;u5=1,Object.defineProperty(Ps,"__esModule",{value:!0}),Ps.ActorDereferenceHttpBase=Ps.mediaTypesToAcceptString=void 0;const t=eA(),e=as(),u=ou(),s=hA(),n=Pi(),r=/^[^ ;]*/u;function a(l,c){const d="*/*;q=0.1",h=[],f=Object.entries(l).map(([y,b])=>({mediaType:y,priority:b})).sort((y,b)=>b.priority===y.priority?y.mediaType.localeCompare(b.mediaType):b.priority-y.priority);let p=f.length-1;for(const{mediaType:y,priority:b}of f){const g=y+(b===1?"":`;q=${b.toFixed(3).replace(/0*$/u,"")}`);if(p+g.length>c){for(;p+d.length>c;){const m=h.pop()??"";p-=m.length+1}h.push(d);break}h.push(g),p+=g.length}return h.length===0?"*/*":h.join(",")}Ps.mediaTypesToAcceptString=a;let o=class extends t.ActorDereference{constructor(c){super(c)}async test({url:c}){if(!/^https?:/u.test(c))throw new Error(`Cannot retrieve ${c} because it is not an HTTP(S) URL.`);return!0}async run(c){var m,v;let d=!0;const h=new s.Headers(c.headers);h.append("Accept",a(await((m=c.mediaTypes)==null?void 0:m.call(c))??{},this.getMaxAcceptHeaderLength()));let f;const p=Date.now();try{f=await this.mediatorHttp.mediate({context:c.context,init:{headers:h,method:c.method},input:c.url})}catch(_){return this.handleDereferenceErrors(c,_)}const y=(0,n.resolve)(f.url,c.url),b=Date.now()-p;if(f.status!==200){d=!1;const _=f.body?await(0,u.stringify)(e.ActorHttp.toNodeReadable(f.body)):"empty response";if(!c.acceptErrors){const w=new Error(`Could not retrieve ${c.url} (HTTP status ${f.status}): +${_}`);return this.handleDereferenceErrors(c,w,f.headers,b)}}const g=(v=r.exec(f.headers.get("content-type")??""))==null?void 0:v[0];return{url:y,data:d?e.ActorHttp.toNodeReadable(f.body):(0,t.emptyReadable)(),exists:d,requestTime:b,headers:f.headers,mediaType:g==="text/plain"?void 0:g}}};return Ps.ActorDereferenceHttpBase=o,Ps}var c5;function $Z(){if(c5)return ph;c5=1,Object.defineProperty(ph,"__esModule",{value:!0}),ph.ActorDereferenceHttp=void 0;const t=nB();class e extends t.ActorDereferenceHttpBase{getMaxAcceptHeaderLength(){return this.maxAcceptHeaderLengthBrowser}}return ph.ActorDereferenceHttp=e,ph}var l5;function VZ(){return l5||(l5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u($Z(),t),u(nB(),t)}(H2)),H2}var $2={},yh={},d5;function kZ(){if(d5)return yh;d5=1,Object.defineProperty(yh,"__esModule",{value:!0}),yh.ActorHttpProxy=void 0;const t=as(),e=Lt;let u=class extends t.ActorHttp{constructor(n){super(n)}async test(n){const r=n.context.get(e.KeysHttpProxy.httpProxyHandler);if(!r)throw new Error(`Actor ${this.name} could not find a proxy handler in the context.`);if(!await r.getProxy(n))throw new Error(`Actor ${this.name} could not determine a proxy for the given request.`);return{time:Number.POSITIVE_INFINITY}}async run(n){const r=typeof n.input=="string"?n.input:n.input.url,a=n.context.get(e.KeysHttpProxy.httpProxyHandler),o=await this.mediatorHttp.mediate({...await a.getProxy(n),context:n.context.delete(e.KeysHttpProxy.httpProxyHandler)});return Object.defineProperty(o,"url",{configurable:!0,enumerable:!0,get:()=>o.headers.get("x-final-url")??r}),o}};return yh.ActorHttpProxy=u,yh}var bh={},f5;function zZ(){if(f5)return bh;f5=1,Object.defineProperty(bh,"__esModule",{value:!0}),bh.ProxyHandlerStatic=void 0;let t=class{constructor(u){this.prefixUrl=u}async getProxy(u){return{init:u.init,input:this.modifyInput(u.input)}}modifyInput(u){return typeof u=="string"?this.prefixUrl+u:new Request(this.prefixUrl+u.url,u)}};return bh.ProxyHandlerStatic=t,bh}var h5;function GZ(){return h5||(h5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(kZ(),t),u(zZ(),t)}($2)),$2}var V2={},mh={},p5;function WZ(){if(p5)return mh;p5=1,Object.defineProperty(mh,"__esModule",{value:!0}),mh.ActorContextPreprocessQuerySourceIdentify=void 0;const t=xy(),e=Lt,u=ot,s=os();let n=class extends t.ActorContextPreprocess{constructor(a){super(a),this.cache=this.cacheSize?new s.LRUCache({max:this.cacheSize}):void 0;const o=this.cache;o&&this.httpInvalidator.addInvalidateListener(({url:l})=>l?o.delete(l):o.clear())}async test(a){return!0}async run(a){let o=a.context;if(o.has(e.KeysInitQuery.querySourcesUnidentified)){const l=a.context.get(e.KeysInitQuery.querySourcesUnidentified),c=await Promise.all(l.map(h=>this.expandSource(h))),d=await Promise.all(c.map(async h=>this.identifySource(h,a.context)));o=a.context.delete(e.KeysInitQuery.querySourcesUnidentified).set(e.KeysQueryOperation.querySources,d)}return{context:o}}async expandSource(a){return typeof a=="string"||"match"in a?{value:a}:{...a,context:(await this.mediatorContextPreprocess.mediate({context:u.ActionContext.ensureActionContext(a.context??{})})).context}}identifySource(a,o){let l;return typeof a.value=="string"&&this.cache&&(l=this.cache.get(a.value)),l||(l=this.mediatorQuerySourceIdentify.mediate({querySourceUnidentified:a,context:o}).then(({querySource:c})=>c),typeof a.value=="string"&&this.cache&&this.cache.set(a.value,l)),l}};return mh.ActorContextPreprocessQuerySourceIdentify=n,mh}var y5;function JZ(){return y5||(y5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(WZ(),t)}(V2)),V2}var k2={},gh={},b5;function XZ(){if(b5)return gh;b5=1,Object.defineProperty(gh,"__esModule",{value:!0}),gh.ActorRdfUpdateQuadsHypermedia=void 0;const t=dA(),e=os();let u=class extends t.ActorRdfUpdateQuadsDestination{constructor(n){super(n),this.cache=this.cacheSize?new e.LRUCache({max:this.cacheSize}):void 0;const r=this.cache;r&&this.httpInvalidator.addInvalidateListener(({url:a})=>a?r.delete(a):r.clear())}async test(n){if(!(0,t.getContextDestinationUrl)((0,t.getContextDestination)(n.context)))throw new Error(`Actor ${this.name} can only update quads against a single destination URL.`);return!0}getDestination(n){const r=(0,t.getContextDestination)(n);let a=(0,t.getContextDestinationUrl)(r);if(this.cache&&this.cache.has(a))return this.cache.get(a);const o=(async()=>{var h;let l,c;try{const f=await this.mediatorDereferenceRdf.mediate({context:n,url:a,acceptErrors:!0});c=f.exists,a=f.url;const p=await this.mediatorMetadata.mediate({context:n,url:a,quads:f.data,triples:(h=f.metadata)==null?void 0:h.triples});l=(await this.mediatorMetadataExtract.mediate({context:n,url:a,metadata:p.metadata,headers:f.headers,requestTime:f.requestTime})).metadata}catch{l={},c=!1}const{destination:d}=await this.mediatorRdfUpdateHypermedia.mediate({context:n,url:a,metadata:l,exists:c,forceDestinationType:(0,t.getDataDestinationType)(r)});return d})();return this.cache&&this.cache.set(a,o),o}};return gh.ActorRdfUpdateQuadsHypermedia=u,gh}var m5;function KZ(){return m5||(m5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(XZ(),t)}(k2)),k2}var z2={},_h={},g5;function YZ(){if(g5)return _h;g5=1,Object.defineProperty(_h,"__esModule",{value:!0}),_h.ActionObserverHttp=void 0;const t=ot;class e extends t.ActionObserver{constructor(s){super(s),this.requests=0,this.bus.subscribeObserver(this),this.httpInvalidator.addInvalidateListener(()=>{this.requests=0})}onRun(s,n,r){this.requests++}}return _h.ActionObserverHttp=e,_h}var vh={},_5;function ZZ(){if(_5)return vh;_5=1,Object.defineProperty(vh,"__esModule",{value:!0}),vh.ActorQueryResultSerializeSparqlJson=void 0;const t=Gi(),e=Dt(),u=Wt();let s=class C0 extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(r){super(r)}static bindingToJsonBindings(r){if(r.termType==="Literal"){const a=r,o={value:a.value,type:"literal"},{language:l,datatype:c}=a;return l?o["xml:lang"]=l:c&&c.value!=="http://www.w3.org/2001/XMLSchema#string"&&(o.datatype=c.value),o}return r.termType==="BlankNode"?{value:r.value,type:"bnode"}:r.termType==="Quad"?{value:{subject:C0.bindingToJsonBindings(r.subject),predicate:C0.bindingToJsonBindings(r.predicate),object:C0.bindingToJsonBindings(r.object)},type:"triple"}:{value:r.value,type:"uri"}}async testHandleChecked(r,a){if(!["bindings","boolean"].includes(r.type))throw new Error("This actor can only handle bindings streams or booleans.");return!0}async runHandle(r,a,o){const l=new u.Readable,c={};if(r.type==="bindings"){const d=await r.metadata();d.variables.length>0&&(c.vars=d.variables.map(h=>h.value))}if(l.push(`{"head": ${JSON.stringify(c)}, +`),r.type==="bindings"){const d=r.bindingsStream;l.push(`"results": { "bindings": [ +`);let h=!0;function*f(p){yield p()}l.wrap((0,e.wrap)(d).map(p=>{const y=`${h?"":`, +`}${JSON.stringify(Object.fromEntries([...p].map(([b,g])=>[b.value,C0.bindingToJsonBindings(g)])))}`;return h=!1,y}).append((0,e.wrap)(f(()=>` +]}${this.emitMetadata?`, +"metadata": { "httpRequests": ${this.httpObserver.requests} }`:""}} +`))))}else l.wrap((0,e.wrap)(r.execute().then(d=>[`"boolean":${d} +} +`])));return{data:l}}};return vh.ActorQueryResultSerializeSparqlJson=s,vh}var v5;function w5(){return v5||(v5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(YZ(),t),u(ZZ(),t)}(z2)),z2}var G2={},wh={},S5;function eee(){if(S5)return wh;S5=1,Object.defineProperty(wh,"__esModule",{value:!0}),wh.ActionObserverHttp=void 0;const t=ot;let e=class extends t.ActionObserver{constructor(s){super(s),this.requests=0,this.bus.subscribeObserver(this),this.httpInvalidator.addInvalidateListener(()=>{this.requests=0})}onRun(s,n,r){this.requests++}};return wh.ActionObserverHttp=e,wh}var Sh={},T5;function tee(){if(T5)return Sh;T5=1,Object.defineProperty(Sh,"__esModule",{value:!0}),Sh.ActorQueryResultSerializeStats=void 0;const t=Gi(),e=Dt(),u=Wt(),s=Ta();let n=class extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(a){super(a)}async testHandleChecked(a,o){if(!["bindings","quads"].includes(a.type))throw new Error("This actor can only handle bindings streams or quad streams.");return!0}pushHeader(a){const o=["Result","Delay (ms)","HTTP requests"].join(",");a.push(`${o} +`)}createStat(a,o){return`${[o,this.delay(a),this.httpObserver.requests].join(",")} +`}createFooter(a){return`${["TOTAL",this.delay(a),this.httpObserver.requests].join(",")} +`}async runHandle(a,o,l){const c=new u.Readable,d=a.type==="bindings"?a.bindingsStream:a.quadStream,h=this.now();let f=1;function*p(b){yield b()}const y=(0,e.wrap)(d).map(()=>this.createStat(h,f++)).append((0,e.wrap)(p(()=>this.createFooter(h))));return this.pushHeader(c),c.wrap(y),{data:c}}now(){if(typeof performance>"u"){const a=s.hrtime();return a[0]*1e3+a[1]/1e6}return performance.now()}delay(a){return this.now()-a}};return Sh.ActorQueryResultSerializeStats=n,Sh}var A5;function E5(){return A5||(A5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(eee(),t),u(tee(),t)}(G2)),G2}var W2={},Th={},J2={},Ah={},O5;function ree(){if(O5)return Ah;O5=1,Object.defineProperty(Ah,"__esModule",{value:!0}),Ah.ActorQuerySourceIdentifyHypermedia=void 0;const t=ot;class e extends t.Actor{constructor(s,n){super(s),this.sourceType=n}async test(s){if(s.forceSourceType&&this.sourceType!==s.forceSourceType)throw new Error(`Actor ${this.name} is not able to handle source type ${s.forceSourceType}.`);return this.testMetadata(s)}}return Ah.ActorQuerySourceIdentifyHypermedia=e,Ah}var R5;function pA(){return R5||(R5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(ree(),t)}(J2)),J2}var Eh={},X2={},Oh={},x5;function nee(){if(x5)return Oh;x5=1,Object.defineProperty(Oh,"__esModule",{value:!0}),Oh.ActorQuerySourceIdentify=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return Oh.ActorQuerySourceIdentify=e,Oh}var $r={},I5;function iee(){if(I5)return $r;I5=1,Object.defineProperty($r,"__esModule",{value:!0}),$r.filterMatchingQuotedQuads=$r.quadsOrderToBindingsOrder=$r.quadsMetadataToBindingsMetadata=$r.setMetadata=$r.getDuplicateElementLinks=$r.getVariables=$r.isTermVariable=$r.quadsToBindings=void 0;const t=wt(),e=Cn(),u=Et(),s=Xt(),n=un(),r=tq(),a=new u.DataFactory;function o(b,g,m,v){const _=c(g),w=g.graph.termType==="Variable"&&!v,S=d(g),A=(0,n.reduceTermsNested)(g,(O,E,P)=>(E.termType==="Variable"&&(O[P.join("_")]=E.value),O),{});let D=b;w&&(D=D.filter(O=>O.graph.termType!=="DefaultGraph")),S&&(D=D.filter(O=>{for(const E in S){const P=E.split("_"),M=(0,n.getValueNestedPath)(O,P);for(const U of S[E])if(!M.equals((0,n.getValueNestedPath)(O,U)))return!1}return!0}));const L=new t.ClosableIterator(D.map(O=>m.bindings(Object.keys(A).map(E=>{const P=E.split("_"),M=A[E],U=(0,n.getValueNestedPath)(O,P);return[a.variable(M),U]}))),{onClose:()=>b.destroy()});return h(L,b,A,_,w||!!S),L}$r.quadsToBindings=o;function l(b){return b.termType==="Variable"}$r.isTermVariable=l;function c(b){return(0,n.uniqTerms)((0,n.getTermsNested)(b).filter(l))}$r.getVariables=c;function d(b){const g={};let m=!1;if((0,n.forEachTermsNested)(b,(_,w)=>{if(_.termType==="Variable"){const S=(0,s.termToString)(_),A=(g[S]||(g[S]=[])).push(w);m=m||A>1}}),!m)return;const v={};for(const _ in g){const w=g[_],S=w.slice(1);S.length>0&&(v[w[0].join("_")]=S)}return v}$r.getDuplicateElementLinks=d;function h(b,g,m,v,_){const w=A=>{"canContainUndefs"in A||(A.canContainUndefs=!1),_&&(A.cardinality.type="estimate"),b.setProperty("metadata",f((0,e.validateMetadataQuads)(A),m,v)),A.state&&A.state.addInvalidateListener(()=>{h(b,g,m,v,_)})},S=g.getProperty("metadata");S?w(S):g.getProperty("metadata",w)}$r.setMetadata=h;function f(b,g,m){return{...b,canContainUndefs:!1,order:b.order?p(b.order,g):void 0,availableOrders:b.availableOrders?b.availableOrders.map(v=>({cost:v.cost,terms:p(v.terms,g)})):void 0,variables:m}}$r.quadsMetadataToBindingsMetadata=f;function p(b,g){const m={};return b.map(v=>{const _=g[v.term];if(_&&!m[_])return m[_]=!0,{term:a.variable(_),direction:v.direction}}).filter(Boolean)}$r.quadsOrderToBindingsOrder=p;function y(b,g){return(0,n.someTerms)(b,m=>m.termType==="Quad")&&(g=g.filter(m=>(0,r.matchPatternMappings)(m,b))),g}return $r.filterMatchingQuotedQuads=y,$r}var P5;function Ly(){return P5||(P5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(nee(),t),u(iee(),t)}(X2)),X2}var D5;function iB(){if(D5)return Eh;D5=1,Object.defineProperty(Eh,"__esModule",{value:!0}),Eh.QuerySourceQpf=void 0;const t=Ly(),e=Lt,u=Dt(),s=Et(),n=Xt(),r=Ny(),a=un(),o=Ot(),l=new o.Factory,c=new s.DataFactory;let d=class I3{constructor(p,y,b,g,m,v,_,w,S,A,D,L){this.referenceValue=S,this.mediatorMetadata=p,this.mediatorMetadataExtract=y,this.mediatorDereferenceRdf=b,this.bindingsFactory=g,this.subjectUri=m,this.predicateUri=v,this.objectUri=_,this.graphUri=w,this.url=S,this.bindingsRestricted=D,this.cachedQuads={};const O=this.getSearchForm(A);if(!O)throw new Error("Illegal state: found no TPF/QPF search form anymore in metadata.");if(this.searchForm=O,this.defaultGraph=A.defaultGraph?c.namedNode(A.defaultGraph):void 0,L){let E=(0,u.wrap)(L);this.defaultGraph&&(E=this.reverseMapQuadsToDefaultGraph(E)),E.setProperty("metadata",A),this.cacheQuads(E,c.variable(""),c.variable(""),c.variable(""),c.variable(""))}}async getSelectorShape(){return this.bindingsRestricted?I3.SELECTOR_SHAPE_BR:I3.SELECTOR_SHAPE}queryBindings(p,y,b){if(p.type!=="pattern")throw new Error(`Attempted to pass non-pattern operation '${p.type}' to QuerySourceQpf`);const g=!!y.get(e.KeysQueryOperation.unionDefaultGraph);let m=this.match(p.subject,p.predicate,p.object,p.graph,g,y,b);return m=(0,t.filterMatchingQuotedQuads)(p,m),(0,t.quadsToBindings)(m,p,this.bindingsFactory,g)}getSearchForm(p){if(!p.searchForms||!p.searchForms.values)return;const{searchForms:y}=p;for(const b of y.values)if(this.graphUri&&this.subjectUri in b.mappings&&this.predicateUri in b.mappings&&this.objectUri in b.mappings&&this.graphUri in b.mappings&&Object.keys(b.mappings).length===4||this.subjectUri in b.mappings&&this.predicateUri in b.mappings&&this.objectUri in b.mappings&&Object.keys(b.mappings).length===3)return b}createFragmentUri(p,y,b,g,m){const v={},_=[{uri:this.subjectUri,term:y},{uri:this.predicateUri,term:b},{uri:this.objectUri,term:g},{uri:this.graphUri,term:m}];for(const w of _)w.uri&&(this.bindingsRestricted||w.term.termType!=="Variable"&&(w.term.termType!=="Quad"||(0,a.everyTermsNested)(w.term,S=>S.termType!=="Variable")))&&(v[w.uri]=(0,n.termToString)(w.term));return p.getUri(v)}match(p,y,b,g,m,v,_){let w=!1;if(g.termType==="DefaultGraph")if(this.defaultGraph)w=!0,g=this.defaultGraph;else if(Object.keys(this.searchForm.mappings).length===4&&!this.defaultGraph)if(m)g=c.variable("g");else{const L=new u.ArrayIterator([],{autoStart:!1});return L.setProperty("metadata",{requestTime:0,cardinality:{type:"exact",value:0},first:null,next:null,last:null,canContainUndefs:!1}),L}else Object.keys(this.searchForm.mappings).length===3&&(g=c.variable("g"));if(!(_!=null&&_.filterBindings)){const L=this.getCachedQuads(p,y,b,g);if(L)return L}const S=this;let A;const D=async function(){var M;let L=S.createFragmentUri(S.searchForm,p,y,b,g);_!=null&&_.filterBindings&&(L=await S.getBindingsRestrictedLink(p,y,b,g,L,_.filterBindings));const O=await S.mediatorDereferenceRdf.mediate({context:v,url:L});L=O.url;const E=await S.mediatorMetadata.mediate({context:v,url:L,quads:O.data,triples:(M=O.metadata)==null?void 0:M.triples}),{metadata:P}=await S.mediatorMetadataExtract.mediate({context:v,url:L,metadata:E.metadata,requestTime:O.requestTime});return A.setProperty("metadata",{...P,canContainUndefs:!1,subsetOf:S.url}),E.data}();return A=new u.TransformIterator(async()=>{const L=await D,O=c.defaultGraph();let E=(0,u.wrap)(L).transform({filter(P){return(0,a.matchPattern)(P,p,y,b,g)?!0:w&&(0,a.matchPattern)(P,p,y,b,O)}});return(w||g.termType==="Variable")&&(E=this.reverseMapQuadsToDefaultGraph(E)),E},{autoStart:!1}),_!=null&&_.filterBindings?A:(this.cacheQuads(A,p,y,b,g),this.getCachedQuads(p,y,b,g))}async getBindingsRestrictedLink(p,y,b,g,m,v){const _=[];for(const S of await v.bindings.toArray()){const A=["("];for(const D of v.metadata.variables){const L=S.get(D);A.push(L?(0,r.termToString)(L):"UNDEF"),A.push(" ")}A.push(")"),_.push(A.join(""))}_.length===0&&_.push("()");const w=encodeURIComponent(`(${v.metadata.variables.map(S=>`?${S.value}`).join(" ")}) { ${_.join(" ")} }`);return`${m}&values=${w}`}reverseMapQuadsToDefaultGraph(p){const y=c.defaultGraph();return p.map(b=>(0,a.mapTerms)(b,(g,m)=>m==="graph"&&g.equals(this.defaultGraph)?y:g))}getPatternId(p,y,b,g){return JSON.stringify({s:p.termType==="Variable"?"":h(p),p:y.termType==="Variable"?"":h(y),o:b.termType==="Variable"?"":h(b),g:g.termType==="Variable"?"":h(g)})}cacheQuads(p,y,b,g,m){const v=this.getPatternId(y,b,g,m);this.cachedQuads[v]=p.clone()}getCachedQuads(p,y,b,g){const m=this.getPatternId(p,y,b,g),v=this.cachedQuads[m];if(v)return v.clone()}queryQuads(p,y){throw new Error("queryQuads is not implemented in QuerySourceQpf")}queryBoolean(p,y){throw new Error("queryBoolean is not implemented in QuerySourceQpf")}queryVoid(p,y){throw new Error("queryVoid is not implemented in QuerySourceQpf")}};Eh.QuerySourceQpf=d,d.SELECTOR_SHAPE={type:"operation",operation:{operationType:"pattern",pattern:l.createPattern(c.variable("s"),c.variable("p"),c.variable("o"),c.variable("g"))},variablesOptional:[c.variable("s"),c.variable("p"),c.variable("o"),c.variable("g")]},d.SELECTOR_SHAPE_BR={type:"operation",operation:{operationType:"pattern",pattern:l.createPattern(c.variable("s"),c.variable("p"),c.variable("o"),c.variable("g"))},variablesOptional:[c.variable("s"),c.variable("p"),c.variable("o"),c.variable("g")],filterBindings:!0};function h(f){return f.termType==="DefaultGraph"?"|":(0,n.termToString)(f)}return Eh}var N5;function aee(){if(N5)return Th;N5=1,Object.defineProperty(Th,"__esModule",{value:!0}),Th.ActorQuerySourceIdentifyHypermediaQpf=void 0;const t=xr(),e=pA(),u=iB();let s=class extends e.ActorQuerySourceIdentifyHypermedia{constructor(r){super(r,"qpf")}async test(r){if(r.forceSourceType&&r.forceSourceType!=="qpf"&&r.forceSourceType!=="brtpf")throw new Error(`Actor ${this.name} is not able to handle source type ${r.forceSourceType}.`);return this.testMetadata(r)}async testMetadata(r){const{searchForm:a}=await this.createSource(r.url,r.metadata,r.context,r.forceSourceType==="brtpf");if(r.handledDatasets&&r.handledDatasets[a.dataset])throw new Error(`Actor ${this.name} can only be applied for the first page of a QPF dataset.`);return{filterFactor:1}}async run(r){this.logInfo(r.context,`Identified as qpf source: ${r.url}`);const a=await this.createSource(r.url,r.metadata,r.context,r.forceSourceType==="brtpf",r.quads);return{source:a,dataset:a.searchForm.dataset}}async createSource(r,a,o,l,c){return new u.QuerySourceQpf(this.mediatorMetadata,this.mediatorMetadataExtract,this.mediatorDereferenceRdf,await t.BindingsFactory.create(this.mediatorMergeBindingsContext,o),this.subjectUri,this.predicateUri,this.objectUri,this.graphUri,r,a,l,c)}};return Th.ActorQuerySourceIdentifyHypermediaQpf=s,Th}var C5;function see(){return C5||(C5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(aee(),t),u(iB(),t)}(W2)),W2}var K2={},Rh={},xh={},j5;function aB(){if(j5)return xh;j5=1,Object.defineProperty(xh,"__esModule",{value:!0}),xh.QuerySourceSparql=void 0;const t=Lt,e=ot,u=Dt(),s=H7(),n=os(),r=Et(),a=Ot(),o=new a.Factory,l=new r.DataFactory,c=l.variable("count"),d={type:"estimate",value:Number.POSITIVE_INFINITY};let h=class ii{constructor(p,y,b,g,m,v,_,w){this.referenceValue=p,this.url=p,this.context=y,this.mediatorHttp=b,this.bindMethod=g,this.bindingsFactory=m,this.endpointFetcher=new s.SparqlEndpointFetcher({method:v?"GET":"POST",fetch:(S,A)=>this.mediatorHttp.mediate({input:S,init:A,context:this.lastSourceContext}),prefixVariableQuestionMark:!0}),this.cache=_>0?new n.LRUCache({max:_}):void 0,this.countTimeout=w}async getSelectorShape(){return ii.SELECTOR_SHAPE}queryBindings(p,y,b){let g;b!=null&&b.joinBindings?g=ii.addBindingsToOperation(this.bindMethod,p,b.joinBindings):g=Promise.resolve(p);const m=new u.TransformIterator(async()=>{const v=await g,_=a.Util.inScopeVariables(v),w=y.get(t.KeysInitQuery.queryString),S=!(b!=null&&b.joinBindings)&&w?w:ii.operationToSelectQuery(v,_),A=ii.operationCanContainUndefs(v);return this.queryBindingsRemote(this.url,S,_,y,A)},{autoStart:!1});return this.attachMetadata(m,y,g),m}queryQuads(p,y){this.lastSourceContext=this.context.merge(y);const b=this.endpointFetcher.fetchTriples(this.url,y.get(t.KeysInitQuery.queryString)??ii.operationToQuery(p));this.lastSourceContext=void 0;const g=(0,u.wrap)(b,{autoStart:!1,maxBufferSize:Number.POSITIVE_INFINITY});return this.attachMetadata(g,y,Promise.resolve(p.input)),g}queryBoolean(p,y){this.lastSourceContext=this.context.merge(y);const b=this.endpointFetcher.fetchAsk(this.url,y.get(t.KeysInitQuery.queryString)??ii.operationToQuery(p));return this.lastSourceContext=void 0,b}queryVoid(p,y){this.lastSourceContext=this.context.merge(y);const b=this.endpointFetcher.fetchUpdate(this.url,y.get(t.KeysInitQuery.queryString)??ii.operationToQuery(p));return this.lastSourceContext=void 0,b}attachMetadata(p,y,b){let g=[],m=!1;new Promise(async(v,_)=>{var S;let w;try{const A=await b;g=a.Util.inScopeVariables(A),w=ii.operationToCountQuery(A),m=ii.operationCanContainUndefs(A);const D=(S=this.cache)==null?void 0:S.get(w);if(D!==void 0)return v(D);const L=setTimeout(()=>v(d),this.countTimeout),O=await this.queryBindingsRemote(this.url,w,[c],y,!1);O.on("data",E=>{var U;clearTimeout(L);const P=E.get(c),M={type:"estimate",value:Number.POSITIVE_INFINITY};if(P){const j=Number.parseInt(P.value,10);Number.isNaN(j)||(M.type="exact",M.value=j,(U=this.cache)==null||U.set(w,M))}return v(M)}),O.on("error",()=>{clearTimeout(L),v(d)}),O.on("end",()=>{clearTimeout(L),v(d)})}catch(A){return _(A)}}).then(v=>p.setProperty("metadata",{cardinality:v,canContainUndefs:m,variables:g})).catch(()=>p.setProperty("metadata",{cardinality:d,canContainUndefs:m,variables:g}))}static async addBindingsToOperation(p,y,b){const g=await b.bindings.toArray();switch(p){case"values":return o.createJoin([o.createValues(b.metadata.variables,g.map(m=>Object.fromEntries([...m].map(([v,_])=>[`?${v.value}`,_])))),y],!1);case"union":throw new Error('Not implemented yet: "union" case');case"filter":throw new Error('Not implemented yet: "filter" case')}}static operationToSelectQuery(p,y){return ii.operationToQuery(o.createProject(p,y))}static operationToCountQuery(p){return ii.operationToQuery(o.createProject(o.createExtend(o.createGroup(p,[],[o.createBoundAggregate(l.variable("var0"),"count",o.createWildcardExpression(),!1)]),l.variable("count"),o.createTermExpression(l.variable("var0"))),[l.variable("count")]))}static operationToQuery(p){return(0,a.toSparql)(p,{sparqlStar:!0})}static operationCanContainUndefs(p){let y=!1;return a.Util.recurseOperation(p,{leftjoin(){return y=!0,!1},values(b){return y=b.bindings.some(g=>b.variables.some(m=>!(`?${m.value}`in g))),!1},union(b){const g=b.input.map(a.Util.inScopeVariables).map(m=>m.map(v=>v.value)).map(m=>m.sort((v,_)=>v.localeCompare(_))).map(m=>m.join(","));return g.every(m=>m===g[0])?!0:(y=!0,!1)}}),y}async queryBindingsRemote(p,y,b,g,m){this.lastSourceContext=this.context.merge(g);const v=await this.endpointFetcher.fetchBindings(p,y);return this.lastSourceContext=void 0,(0,u.wrap)(v,{autoStart:!1,maxBufferSize:Number.POSITIVE_INFINITY}).map(w=>this.bindingsFactory.bindings(b.map(S=>{var D;const A=w[`?${S.value}`];return!m&&!A&&((D=e.Actor.getContextLogger(this.context))==null||D.warn(`The endpoint ${p} failed to provide a binding for ${S.value}.`)),[S,A]}).filter(([S,A])=>!!A)))}toString(){return`QuerySourceSparql(${this.url})`}};return xh.QuerySourceSparql=h,h.SELECTOR_SHAPE={type:"disjunction",children:[{type:"operation",operation:{operationType:"type",type:a.Algebra.types.PROJECT},joinBindings:!0},{type:"operation",operation:{operationType:"type",type:a.Algebra.types.CONSTRUCT}},{type:"operation",operation:{operationType:"type",type:a.Algebra.types.DESCRIBE}},{type:"operation",operation:{operationType:"type",type:a.Algebra.types.ASK}},{type:"operation",operation:{operationType:"type",type:a.Algebra.types.COMPOSITE_UPDATE}}]},xh}var L5;function oee(){if(L5)return Rh;L5=1,Object.defineProperty(Rh,"__esModule",{value:!0}),Rh.ActorQuerySourceIdentifyHypermediaSparql=void 0;const t=xr(),e=pA(),u=aB();let s=class extends e.ActorQuerySourceIdentifyHypermedia{constructor(r){super(r,"sparql")}async testMetadata(r){if(!r.forceSourceType&&!r.metadata.sparqlService&&!(this.checkUrlSuffix&&r.url.endsWith("/sparql")))throw new Error(`Actor ${this.name} could not detect a SPARQL service description or URL ending on /sparql.`);return{filterFactor:1}}async run(r){return this.logInfo(r.context,`Identified ${r.url} as sparql source with service URL: ${r.metadata.sparqlService||r.url}`),{source:new u.QuerySourceSparql(r.forceSourceType?r.url:r.metadata.sparqlService||r.url,r.context,this.mediatorHttp,this.bindMethod,await t.BindingsFactory.create(this.mediatorMergeBindingsContext,r.context),this.forceHttpGet,this.cacheSize,this.countTimeout)}}};return Rh.ActorQuerySourceIdentifyHypermediaSparql=s,Rh}var M5;function uee(){return M5||(M5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(oee(),t),u(aB(),t)}(K2)),K2}var Y2={},Ih={},Z2={},Ph={},Dh={},F5;function sB(){if(F5)return Dh;F5=1,Object.defineProperty(Dh,"__esModule",{value:!0}),Dh.QuerySourceRdfJs=void 0;const t=Ly(),e=Lt,u=Cn(),s=Dt(),n=Et(),r=un(),a=Ot(),o=new a.Factory,l=new n.DataFactory;let c=class An{constructor(h,f){this.source=h,this.referenceValue=h,this.bindingsFactory=f}static nullifyVariables(h,f){return!h||h.termType==="Variable"||!f&&h.termType==="Quad"&&(0,r.someTermsNested)(h,p=>p.termType==="Variable")?void 0:h}static hasDuplicateVariables(h){const f=(0,r.filterTermsNested)(h,p=>p.termType==="Variable");return f.length>1&&(0,r.uniqTerms)(f).lengthb.destroy(m)),(0,t.quadsToBindings)(b,h,this.bindingsFactory,!!f.get(e.KeysQueryOperation.unionDefaultGraph))}async setMetadata(h,f){var g;const p=!!((g=this.source.features)!=null&&g.quotedTripleFiltering);let y;if(this.source.countQuads)y=await this.source.countQuads(An.nullifyVariables(f.subject,p),An.nullifyVariables(f.predicate,p),An.nullifyVariables(f.object,p),An.nullifyVariables(f.graph,p));else{let m=0;y=await new Promise((v,_)=>{const w=this.source.match(An.nullifyVariables(f.subject,p),An.nullifyVariables(f.predicate,p),An.nullifyVariables(f.object,p),An.nullifyVariables(f.graph,p));w.on("error",_),w.on("end",()=>v(m)),w.on("data",()=>m++)})}const b=!p&&(0,r.someTerms)(f,m=>m.termType==="Quad")||An.hasDuplicateVariables(f);h.setProperty("metadata",{state:new u.MetadataValidationState,cardinality:{type:b?"estimate":"exact",value:y},canContainUndefs:!1})}queryQuads(h,f){throw new Error("queryQuads is not implemented in QuerySourceQpf")}queryBoolean(h,f){throw new Error("queryBoolean is not implemented in QuerySourceQpf")}queryVoid(h,f){throw new Error("queryVoid is not implemented in QuerySourceQpf")}toString(){return`QuerySourceRdfJs(${this.source.constructor.name})`}};return Dh.QuerySourceRdfJs=c,c.SELECTOR_SHAPE={type:"operation",operation:{operationType:"pattern",pattern:o.createPattern(l.variable("s"),l.variable("p"),l.variable("o"))},variablesOptional:[l.variable("s"),l.variable("p"),l.variable("o")]},Dh}var q5;function cee(){if(q5)return Ph;q5=1,Object.defineProperty(Ph,"__esModule",{value:!0}),Ph.ActorQuerySourceIdentifyRdfJs=void 0;const t=xr(),e=Ly(),u=ot,s=sB();let n=class extends e.ActorQuerySourceIdentify{constructor(a){super(a)}async test(a){const o=a.querySourceUnidentified;if(o.type!==void 0&&o.type!=="rdfjs")throw new Error(`${this.name} requires a single query source with rdfjs type to be present in the context.`);if(typeof o.value=="string"||!("match"in o.value))throw new Error(`${this.name} received an invalid rdfjs query source.`);return!0}async run(a){return{querySource:{source:new s.QuerySourceRdfJs(a.querySourceUnidentified.value,await t.BindingsFactory.create(this.mediatorMergeBindingsContext,a.context)),context:a.querySourceUnidentified.context??new u.ActionContext}}}};return Ph.ActorQuerySourceIdentifyRdfJs=n,Ph}var eS={},B5;function lee(){return B5||(B5=1,Object.defineProperty(eS,"__esModule",{value:!0})),eS}var U5;function yA(){return U5||(U5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(cee(),t),u(lee(),t),u(sB(),t)}(Z2)),Z2}var Nh={},tS={},Ch={},jh={},Lh={},Q5;function oB(){if(Q5)return Lh;Q5=1,Object.defineProperty(Lh,"__esModule",{value:!0}),Lh.TermDictionaryNumberRecordFullTerms=void 0;const t=Et(),e=Xt();let u=class{constructor(n=new t.DataFactory){this.lastId=0,this.dictionary={},this.reverseDictionary={},this.features={quotedTriples:!1},this.dataFactory=n}encode(n){const r=(0,e.termToString)(n);let a=this.dictionary[r];return a===void 0&&(a=this.lastId++,this.dictionary[r]=a,this.reverseDictionary[a]=n),a}encodeOptional(n){const r=(0,e.termToString)(n);return this.dictionary[r]}decode(n){const r=this.reverseDictionary[n];if(r===void 0)throw new Error(`The value ${n} is not present in this dictionary`);return r}*encodings(){for(const n of Object.keys(this.reverseDictionary))yield Number.parseInt(n,10)}findQuotedTriples(n){throw new Error("findQuotedTriples is not supported")}findQuotedTriplesEncoded(n){throw new Error("findQuotedTriplesEncoded is not supported")}};return Lh.TermDictionaryNumberRecordFullTerms=u,Lh}var Mh={},Fh={},rS={},H5;function Xi(){return H5||(H5=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.arePatternsQuoted=t.quadHasVariables=t.quadToPattern=t.encodeOptionalTerms=t.orderQuadComponents=t.getComponentOrderScore=t.getBestIndex=t.QUAD_TERM_NAMES_INVERSE=void 0;const e=un();t.QUAD_TERM_NAMES_INVERSE=Object.fromEntries(e.QUAD_TERM_NAMES.map((c,d)=>[c,d]));function u(c,d){if(c.length===1||d.every(p=>p!==void 0))return 0;const h=[];for(let p=0;p({score:s(p,h),index:y})).sort((p,y)=>y.score-p.score)[0].index}t.getBestIndex=u;function s(c,d){return c.map((h,f)=>d.includes(h)?c.length-f:0).reduce((h,f)=>h+f,0)}t.getComponentOrderScore=s;function n(c,d){return c.map(h=>{const f=t.QUAD_TERM_NAMES_INVERSE[h];return d[f]})}t.orderQuadComponents=n;function r(c,d){const h=c.map(f=>{if(f){if(f.termType==="Quad"&&o(f))return;const p=d.encodeOptional(f);return p===void 0?"none":p}return f});if(!h.includes("none"))return h}t.encodeOptionalTerms=r;function a(c,d,h,f,p){let y=!1;return[[c||void 0,d||void 0,h||void 0,f||void 0].map(g=>{if(g){if(g.termType==="Variable")return;if(g.termType==="Quad"){if(p)return g;y=!0;return}}return g}),y]}t.quadToPattern=a;function o(c){for(const d of e.QUAD_TERM_NAMES){const h=c[d];if(h.termType==="Variable"||h.termType==="Quad"&&o(h))return!0}return!1}t.quadHasVariables=o;function l(c){return c.map(d=>(d==null?void 0:d.termType)==="Quad"&&o(d))}t.arePatternsQuoted=l}(rS)),rS}var $5;function bA(){if($5)return Fh;$5=1,Object.defineProperty(Fh,"__esModule",{value:!0}),Fh.RdfStoreIndexNestedMap=void 0;const t=Xi();let e=class{constructor(s){this.features={quotedTripleFiltering:!1},this.dictionary=s.dictionary,this.nestedMap=new Map}set(s,n){const r=this.nestedMap;let a=r.get(s[0]);a||(a=new Map,r.set(s[0],a));let o=a.get(s[1]);o||(o=new Map,a.set(s[1],o));let l=o.get(s[2]);l||(l=new Map,o.set(s[2],l));const c=l.has(s[3]);return c||l.set(s[3],n),!c}remove(s){const n=this.nestedMap,r=n.get(s[0]);if(!r)return!1;const a=r.get(s[1]);if(!a)return!1;const o=a.get(s[2]);if(!o)return!1;const l=o.delete(s[3]);return l&&o.size===0&&(a.delete(s[2]),a.size===0&&(r.delete(s[1]),r.size===0&&n.delete(s[0]))),l}get(s){const n=(0,t.encodeOptionalTerms)(s,this.dictionary);if(!(!n||n.includes(void 0)))return this.getEncoded(n)}getEncoded(s){const n=this.nestedMap.get(s[0]);if(!n)return;const r=n.get(s[1]);if(!r)return;const a=r.get(s[2]);if(a)return a.get(s[3])}*find(s){const n=(0,t.encodeOptionalTerms)(s,this.dictionary);if(!n)return;const[r,a,o,l]=n,[c,d,h,f]=s;let p,y,b,g,m,v,_;const w=this.nestedMap,S=r!==void 0?w.has(r)?[r]:[]:w.keys();for(const A of S){m=w.get(A),p=c||this.dictionary.decode(A);const D=a!==void 0?m.has(a)?[a]:[]:m.keys();for(const L of D){v=m.get(L),y=d||this.dictionary.decode(L);const O=o!==void 0?v.has(o)?[o]:[]:v.keys();for(const E of O){_=v.get(E),b=h||this.dictionary.decode(E);const P=l!==void 0?_.has(l)?[l]:[]:_.keys();for(const M of P)g=f||this.dictionary.decode(M),yield[p,y,b,g]}}}}*findEncoded(s,n){const[r,a,o,l]=s;let c,d,h;const f=this.nestedMap,p=r!==void 0?f.has(r)?[r]:[]:f.keys();for(const y of p){c=f.get(y);const b=a!==void 0?c.has(a)?[a]:[]:c.keys();for(const g of b){d=c.get(g);const m=o!==void 0?d.has(o)?[o]:[]:d.keys();for(const v of m){h=d.get(v);const _=l!==void 0?h.has(l)?[l]:[]:h.keys();for(const w of _)yield[y,g,v,w]}}}}count(s){let n=0;const r=(0,t.encodeOptionalTerms)(s,this.dictionary);if(!r)return 0;const a=r[0],o=r[1],l=r[2],c=r[3];let d,h,f;const p=this.nestedMap,y=a!==void 0?p.has(a)?[a]:[]:p.keys();for(const b of y){d=p.get(b);const g=o!==void 0?d.has(o)?[o]:[]:d.keys();for(const m of g){h=d.get(m);const v=l!==void 0?h.has(l)?[l]:[]:h.keys();for(const _ of v)f=h.get(_),c!==void 0?f.has(c)&&n++:n+=f.size}}return n}};return Fh.RdfStoreIndexNestedMap=e,Fh}var V5;function uB(){if(V5)return Mh;V5=1,Object.defineProperty(Mh,"__esModule",{value:!0}),Mh.TermDictionaryQuotedIndexed=void 0;const t=Et(),e=bA(),u=Xi();let s=class pa{constructor(r,a=new t.DataFactory){this.quotedTriplesDictionary=[],this.features={quotedTriples:!0},this.plainTermDictionary=r;const o={indexCombinations:[],indexConstructor:void 0,dictionary:this,dataFactory:a};this.quotedTriplesReverseDictionaries=[new e.RdfStoreIndexNestedMap(o),new e.RdfStoreIndexNestedMap(o),new e.RdfStoreIndexNestedMap(o)],this.dataFactory=a}encode(r){return r.termType==="Quad"?this.encodeQuotedTriple(r,!1):this.plainTermDictionary.encode(r)}encodeQuotedTriple(r,a){if(r.graph.termType!=="DefaultGraph")throw new Error("Encoding of quoted quads outside of the default graph is not allowed");const o=(0,u.encodeOptionalTerms)([r.subject,r.predicate,r.object,r.graph],this),l=o&&o.every(f=>f!==void 0)?this.quotedTriplesReverseDictionaries[0].getEncoded(o):void 0;if(l!==void 0||a)return l===void 0?void 0:pa.BITMASK|l;const c=[this.encode(r.subject),this.encode(r.predicate),this.encode(r.object)],d=this.quotedTriplesDictionary.length+1;this.quotedTriplesDictionary.push(c);const h=this.encode(this.dataFactory.defaultGraph());return this.quotedTriplesReverseDictionaries[0].set([c[0],c[1],c[2],h],d),this.quotedTriplesReverseDictionaries[1].set([c[1],c[2],c[0],h],d),this.quotedTriplesReverseDictionaries[2].set([c[2],c[0],c[1],h],d),pa.BITMASK|d}encodeOptional(r){return r.termType==="Quad"?this.encodeQuotedTriple(r,!0):this.plainTermDictionary.encodeOptional(r)}decode(r){if(pa.BITMASK&r){const a=(~pa.BITMASK&r)-1;if(a>=this.quotedTriplesDictionary.length)throw new Error(`The value ${r} is not present in the quoted triples range of the dictionary`);const o=this.quotedTriplesDictionary[a];return this.dataFactory.quad(this.decode(o[0]),this.decode(o[1]),this.decode(o[2]))}return this.plainTermDictionary.decode(r)}*encodings(){for(const r of this.plainTermDictionary.encodings())yield r;for(const r of this.quotedTriplesDictionary.keys())yield pa.BITMASK|1+r}*findQuotedTriples(r){for(const a of this.findQuotedTriplesEncoded(r))yield this.decode(a)}*findQuotedTriplesEncoded(r){const[a,o]=(0,u.quadToPattern)(r.subject,r.predicate,r.object,r.graph,!0);for(const l of this.patternToIterable(a[0]))for(const c of this.patternToIterable(a[1]))for(const d of this.patternToIterable(a[2]))for(const h of this.patternToIterable(a[3]))if(l&&c||!c&&!d){const f=[l,c,d,h];for(const p of this.quotedTriplesReverseDictionaries[0].findEncoded(f,a))yield pa.BITMASK|this.quotedTriplesReverseDictionaries[0].getEncoded(p)}else if(!l&&c){const f=[c,d,l,h];for(const p of this.quotedTriplesReverseDictionaries[1].findEncoded(f,a))yield pa.BITMASK|this.quotedTriplesReverseDictionaries[1].getEncoded(p)}else{const f=[d,l,c,h];for(const p of this.quotedTriplesReverseDictionaries[2].findEncoded(f,a))yield pa.BITMASK|this.quotedTriplesReverseDictionaries[2].getEncoded(p)}}*patternToIterable(r){if((r==null?void 0:r.termType)==="Quad"){yield*this.findQuotedTriplesEncoded(r);return}if(r===void 0){yield void 0;return}const a=this.encodeOptional(r);a!==void 0&&(yield a)}};return s.BITMASK=1<<31,Mh.TermDictionaryQuotedIndexed=s,Mh}var qh={},k5;function cB(){if(k5)return qh;k5=1,Object.defineProperty(qh,"__esModule",{value:!0}),qh.RdfStoreIndexNestedMapQuoted=void 0;const t=Xi(),e=bA();let u=class extends e.RdfStoreIndexNestedMap{constructor(n){super(n),this.features={quotedTripleFiltering:!0}}*getQuotedPatternKeys(n,r){for(const a of this.dictionary.findQuotedTriplesEncoded(r))n.has(a)&&(yield a)}*find(n){const r=(0,t.encodeOptionalTerms)(n,this.dictionary);if(!r)return;const[a,o,l,c]=r,[d,h,f,p]=n,[y,b,g,m]=(0,t.arePatternsQuoted)(n);let v,_,w,S,A,D,L;const O=this.nestedMap,E=d!==void 0?y?this.getQuotedPatternKeys(O,d):O.has(a)?[a]:[]:O.keys();for(const P of E){A=O.get(P),v=!y&&d?d:this.dictionary.decode(P);const M=h!==void 0?b?this.getQuotedPatternKeys(A,h):A.has(o)?[o]:[]:A.keys();for(const U of M){D=A.get(U),_=!b&&h?h:this.dictionary.decode(U);const j=f!==void 0?g?this.getQuotedPatternKeys(D,f):D.has(l)?[l]:[]:D.keys();for(const q of j){L=D.get(q),w=!g&&f?f:this.dictionary.decode(q);const $=p!==void 0?m?this.getQuotedPatternKeys(L,p):L.has(c)?[c]:[]:L.keys();for(const Z of $)S=!m&&p?p:this.dictionary.decode(Z),yield[v,_,w,S]}}}}*findEncoded(n,r){const[a,o,l,c]=n,[d,h,f,p]=r,[y,b,g,m]=(0,t.arePatternsQuoted)(r);let v,_,w;const S=this.nestedMap,A=d!==void 0?y?this.getQuotedPatternKeys(S,d):S.has(a)?[a]:[]:S.keys();for(const D of A){v=S.get(D);const L=h!==void 0?b?this.getQuotedPatternKeys(v,h):v.has(o)?[o]:[]:v.keys();for(const O of L){_=v.get(O);const E=f!==void 0?g?this.getQuotedPatternKeys(_,f):_.has(l)?[l]:[]:_.keys();for(const P of E){w=_.get(P);const M=p!==void 0?m?this.getQuotedPatternKeys(w,p):w.has(c)?[c]:[]:w.keys();for(const U of M)yield[Number.parseInt(D,10),Number.parseInt(O,10),Number.parseInt(P,10),Number.parseInt(U,10)]}}}}count(n){let r=0;const a=(0,t.encodeOptionalTerms)(n,this.dictionary);if(!a)return 0;const[o,l,c,d]=a,[h,f,p,y]=n,[b,g,m,v]=(0,t.arePatternsQuoted)(n);let _,w,S;const A=this.nestedMap,D=h!==void 0?b?this.getQuotedPatternKeys(A,h):A.has(o)?[o]:[]:A.keys();for(const L of D){_=A.get(L);const O=f!==void 0?g?this.getQuotedPatternKeys(_,f):_.has(l)?[l]:[]:_.keys();for(const E of O){w=_.get(E);const P=p!==void 0?m?this.getQuotedPatternKeys(w,p):w.has(c)?[c]:[]:w.keys();for(const M of P)S=w.get(M),y!==void 0?v?r+=[...this.getQuotedPatternKeys(S,y)].length:S.has(d)&&r++:r+=S.size}}return r}};return qh.RdfStoreIndexNestedMapQuoted=u,qh}var z5;function lB(){if(z5)return jh;z5=1,Object.defineProperty(jh,"__esModule",{value:!0}),jh.RdfStore=void 0;const t=Dt(),e=Et(),u=un(),s=fB(),n=oB(),r=uB(),a=cB(),o=Xi();let l=class j0{constructor(d){this.features={quotedTripleFiltering:!0},this._size=0,this.options=d,this.dataFactory=d.dataFactory,this.dictionary=d.dictionary,this.indexesWrapped=j0.constructIndexesWrapped(d),this.indexesWrappedComponentOrders=this.indexesWrapped.map(h=>h.componentOrder)}static createDefault(){return new j0({indexCombinations:j0.DEFAULT_INDEX_COMBINATIONS,indexConstructor:d=>new a.RdfStoreIndexNestedMapQuoted(d),dictionary:new r.TermDictionaryQuotedIndexed(new n.TermDictionaryNumberRecordFullTerms),dataFactory:new e.DataFactory})}static constructIndexesWrapped(d){const h=[];if(d.indexCombinations.length===0)throw new Error("At least one index combination is required");for(const f of d.indexCombinations){if(!j0.isCombinationValid(f))throw new Error(`Invalid index combination: ${f}`);h.push({index:d.indexConstructor(d),componentOrder:f,componentOrderInverse:Object.fromEntries(f.map((p,y)=>[p,y]))})}return h}static isCombinationValid(d){for(const h of u.QUAD_TERM_NAMES)if(!d.includes(h))return!1;return d.length===4}get size(){return this._size}addQuad(d){const h=[this.dictionary.encode(d.subject),this.dictionary.encode(d.predicate),this.dictionary.encode(d.object),this.dictionary.encode(d.graph)];let f=!1;for(const p of this.indexesWrapped)f=p.index.set((0,o.orderQuadComponents)(p.componentOrder,h),!0);return f?(this._size++,!0):!1}removeQuad(d){const h=[this.dictionary.encodeOptional(d.subject),this.dictionary.encodeOptional(d.predicate),this.dictionary.encodeOptional(d.object),this.dictionary.encodeOptional(d.graph)];if(h.includes(void 0))return!1;let f=!1;for(const p of this.indexesWrapped)if(f=p.index.remove((0,o.orderQuadComponents)(p.componentOrder,h)),!f)break;return f?(this._size--,!0):!1}remove(d){return d.on("data",h=>this.removeQuad(h)),d}removeMatches(d,h,f,p){return this.remove(this.match(d,h,f,p))}deleteGraph(d){return typeof d=="string"&&(d=this.dataFactory.namedNode(d)),this.removeMatches(void 0,void 0,void 0,d)}import(d){return d.on("data",h=>this.addQuad(h)),d}*readQuads(d,h,f,p){const y=!!this.dictionary.features.quotedTriples&&Object.values(this.indexesWrapped).every(_=>_.index.features.quotedTripleFiltering),[b,g]=(0,o.quadToPattern)(d,h,f,p,y),m=this.indexesWrapped[(0,o.getBestIndex)(this.indexesWrappedComponentOrders,b)],v=(0,o.orderQuadComponents)(m.componentOrder,b);for(const _ of m.index.find(v)){const w=this.dataFactory.quad(_[m.componentOrderInverse.subject],_[m.componentOrderInverse.predicate],_[m.componentOrderInverse.object],_[m.componentOrderInverse.graph]);g?(0,u.matchPattern)(w,d,h,f,p)&&(yield w):yield w}}getQuads(d,h,f,p){return[...this.readQuads(d,h,f,p)]}match(d,h,f,p){return(0,t.wrap)(this.readQuads(d,h,f,p))}countQuads(d,h,f,p){const y=!!this.dictionary.features.quotedTriples&&Object.values(this.indexesWrapped).every(v=>v.index.features.quotedTripleFiltering),[b]=(0,o.quadToPattern)(d,h,f,p,y);if(b.every(v=>v===void 0))return this.size;const g=this.indexesWrapped[(0,o.getBestIndex)(this.indexesWrappedComponentOrders,b)],m=(0,o.orderQuadComponents)(g.componentOrder,b);return g.index.count(m)}asDataset(){return new s.DatasetCoreWrapper(this)}};return l.DEFAULT_INDEX_COMBINATIONS=[["graph","subject","predicate","object"],["graph","predicate","object","subject"],["graph","object","subject","predicate"]],jh.RdfStore=l,jh}var G5;function fB(){if(G5)return Ch;G5=1,Object.defineProperty(Ch,"__esModule",{value:!0}),Ch.DatasetCoreWrapper=void 0;const t=lB();let e=class dB{constructor(s){this.store=s}get size(){return this.store.size}add(s){return this.store.addQuad(s),this}delete(s){return this.store.removeQuad(s),this}has(s){for(const n of this.store.readQuads(s.subject,s.predicate,s.object,s.graph))return!0;return!1}match(s,n,r,a){const o=new t.RdfStore(this.store.options);for(const l of this.store.readQuads(s,n,r,a))o.addQuad(l);return new dB(o)}[Symbol.iterator](){return this.store.readQuads()}};return Ch.DatasetCoreWrapper=e,Ch}var nS={},W5;function dee(){return W5||(W5=1,Object.defineProperty(nS,"__esModule",{value:!0})),nS}var Bh={},J5;function fee(){if(J5)return Bh;J5=1,Object.defineProperty(Bh,"__esModule",{value:!0}),Bh.TermDictionaryNumberMap=void 0;const t=Et(),e=Xt();let u=class{constructor(n=new t.DataFactory){this.lastId=0,this.dictionary=new Map,this.reverseDictionary=new Map,this.features={quotedTriples:!1},this.dataFactory=n}encode(n){const r=(0,e.termToString)(n);let a=this.dictionary.get(r);return a===void 0&&(a=this.lastId++,this.dictionary.set(r,a),this.reverseDictionary.set(a,r)),a}encodeOptional(n){const r=(0,e.termToString)(n);return this.dictionary.get(r)}decode(n){const r=this.reverseDictionary.get(n);if(r===void 0)throw new Error(`The value ${n} is not present in this dictionary`);return(0,e.stringToTerm)(r,this.dataFactory)}encodings(){return this.reverseDictionary.keys()}findQuotedTriples(n){throw new Error("findQuotedTriples is not supported")}findQuotedTriplesEncoded(n){throw new Error("findQuotedTriplesEncoded is not supported")}};return Bh.TermDictionaryNumberMap=u,Bh}var Uh={},X5;function hee(){if(X5)return Uh;X5=1,Object.defineProperty(Uh,"__esModule",{value:!0}),Uh.TermDictionaryNumberRecord=void 0;const t=Et(),e=Xt();let u=class{constructor(n=new t.DataFactory){this.lastId=0,this.dictionary={},this.reverseDictionary={},this.features={quotedTriples:!1},this.dataFactory=n}encode(n){const r=(0,e.termToString)(n);let a=this.dictionary[r];return a===void 0&&(a=this.lastId++,this.dictionary[r]=a,this.reverseDictionary[a]=r),a}encodeOptional(n){const r=(0,e.termToString)(n);return this.dictionary[r]}decode(n){const r=this.reverseDictionary[n];if(r===void 0)throw new Error(`The value ${n} is not present in this dictionary`);return(0,e.stringToTerm)(r,this.dataFactory)}*encodings(){for(const n of Object.keys(this.reverseDictionary))yield Number.parseInt(n,10)}findQuotedTriples(n){throw new Error("findQuotedTriples is not supported")}findQuotedTriplesEncoded(n){throw new Error("findQuotedTriplesEncoded is not supported")}};return Uh.TermDictionaryNumberRecord=u,Uh}var Qh={},K5;function pee(){if(K5)return Qh;K5=1,Object.defineProperty(Qh,"__esModule",{value:!0}),Qh.TermDictionaryQuoted=void 0;const t=Et(),e=un();let u=class Fs{constructor(n,r,a=new t.DataFactory){this.features={quotedTriples:!0},this.plainTermDictionary=n,this.quotedTriplesDictionary=r,this.dataFactory=a}encode(n){return n.termType==="Quad"?Fs.BITMASK|1+this.quotedTriplesDictionary.encode(n):this.plainTermDictionary.encode(n)}encodeOptional(n){if(n.termType==="Quad"){const r=this.quotedTriplesDictionary.encodeOptional(n);return r===void 0?r:Fs.BITMASK|1+r}return this.plainTermDictionary.encodeOptional(n)}decode(n){if(Fs.BITMASK&n){const r=(~Fs.BITMASK&n)-1;return this.quotedTriplesDictionary.decode(r)}return this.plainTermDictionary.decode(n)}*encodings(){for(const n of this.plainTermDictionary.encodings())yield n;for(const n of this.quotedTriplesDictionary.encodings())yield Fs.BITMASK|1+n}*findQuotedTriples(n){for(const r of this.findQuotedTriplesEncoded(n))yield this.decode(r)}*findQuotedTriplesEncoded(n){for(let r of this.quotedTriplesDictionary.encodings()){r=Fs.BITMASK|1+r;const a=this.decode(r);(0,e.matchPattern)(a,n.subject,n.predicate,n.object,n.graph)&&(yield r)}}};return u.BITMASK=1<<31,Qh.TermDictionaryQuoted=u,Qh}var Hh={},Y5;function yee(){if(Y5)return Hh;Y5=1,Object.defineProperty(Hh,"__esModule",{value:!0}),Hh.TermDictionaryQuotedReferential=void 0;const t=Et(),e=un(),u=Xi();let s=class ya{constructor(r,a=new t.DataFactory){this.quotedTriplesDictionary=[],this.quotedTriplesReverseDictionary={},this.features={quotedTriples:!0},this.plainTermDictionary=r,this.dataFactory=a}encode(r){return r.termType==="Quad"?this.encodeQuotedTriple(r,!1):this.plainTermDictionary.encode(r)}encodeQuotedTriple(r,a){var o;if(r.graph.termType!=="DefaultGraph")throw new Error("Encoding of quoted quads outside of the default graph is not allowed");const l=(o=(0,u.encodeOptionalTerms)([r.subject,r.predicate,r.object,void 0],this))===null||o===void 0?void 0:o.slice(0,3),c=l&&l.every(f=>f!==void 0)?this.quotedTriplesReverseDictionary[l.join(ya.SEPARATOR)]:void 0;if(c!==void 0||a)return c===void 0?void 0:ya.BITMASK|c;const d=[this.encode(r.subject),this.encode(r.predicate),this.encode(r.object)],h=this.quotedTriplesDictionary.length+1;return this.quotedTriplesDictionary.push(d),this.quotedTriplesReverseDictionary[d.join(ya.SEPARATOR)]=h,ya.BITMASK|h}encodeOptional(r){return r.termType==="Quad"?this.encodeQuotedTriple(r,!0):this.plainTermDictionary.encodeOptional(r)}decode(r){if(ya.BITMASK&r){const a=(~ya.BITMASK&r)-1;if(a>=this.quotedTriplesDictionary.length)throw new Error(`The value ${r} is not present in the quoted triples range of the dictionary`);const o=this.quotedTriplesDictionary[a];return this.dataFactory.quad(this.decode(o[0]),this.decode(o[1]),this.decode(o[2]))}return this.plainTermDictionary.decode(r)}*encodings(){for(const r of this.plainTermDictionary.encodings())yield r;for(const r of this.quotedTriplesDictionary.keys())yield ya.BITMASK|1+r}*findQuotedTriples(r){for(const a of this.findQuotedTriplesEncoded(r))yield this.decode(a)}*findQuotedTriplesEncoded(r){for(let a of this.quotedTriplesDictionary.keys()){a=ya.BITMASK|1+a;const o=this.decode(a);(0,e.matchPattern)(o,r.subject,r.predicate,r.object,r.graph)&&(yield a)}}};return s.BITMASK=1<<31,s.SEPARATOR="_",Hh.TermDictionaryQuotedReferential=s,Hh}var $h={},Z5;function bee(){if(Z5)return $h;Z5=1,Object.defineProperty($h,"__esModule",{value:!0}),$h.TermDictionarySymbol=void 0;const t=Et(),e=Xt();let u=class{constructor(n=new t.DataFactory){this.features={quotedTriples:!1},this.dataFactory=n}encode(n){return Symbol.for(`rdf::${(0,e.termToString)(n)}`)}encodeOptional(n){return this.encode(n)}decode(n){const r=Symbol.keyFor(n);if(r===void 0)throw new Error(`The value ${String(n)} is not present in this dictionary`);return(0,e.stringToTerm)(r.slice(5),this.dataFactory)}encodings(){throw new Error("encodings is not supported")}findQuotedTriples(n){throw new Error("findQuotedTriples is not supported")}findQuotedTriplesEncoded(n){throw new Error("findQuotedTriplesEncoded is not supported")}};return $h.TermDictionarySymbol=u,$h}var iS={},ej;function mee(){return ej||(ej=1,Object.defineProperty(iS,"__esModule",{value:!0})),iS}var Vh={},tj;function hB(){if(tj)return Vh;tj=1,Object.defineProperty(Vh,"__esModule",{value:!0}),Vh.RdfStoreIndexNestedMapRecursive=void 0;const t=Xi();let e=class{constructor(s){this.features={quotedTripleFiltering:!1},this.dictionary=s.dictionary,this.nestedMap=new Map}set(s,n){let r=this.nestedMap,a=!1;for(const[o,l]of s.entries()){const c=r;let d=c.get(l);d?o===s.length-1&&(a=!0):(d=o===s.length-1?n:new Map,c.set(l,d)),r=d}return!a}remove(s){const n=this.nestedMap,r=n.get(s[0]);if(!r)return!1;const a=r.get(s[1]);if(!a)return!1;const o=a.get(s[2]);if(!o)return!1;const l=o.delete(s[3]);return l&&o.size===0&&(a.delete(s[2]),a.size===0&&(r.delete(s[1]),r.size===0&&n.delete(s[0]))),l}get(s){const n=(0,t.encodeOptionalTerms)(s,this.dictionary);if(!(!n||n.includes(void 0)))return this.getEncoded(n)}getEncoded(s){const n=this.nestedMap.get(s[0]);if(!n)return;const r=n.get(s[1]);if(!r)return;const a=r.get(s[2]);if(a)return a.get(s[3])}*find(s){const n=(0,t.encodeOptionalTerms)(s,this.dictionary);if(n)for(const r of this.findEncoded(n,s))yield[n[0]!==void 0?s[0]:this.dictionary.decode(r[0]),n[1]!==void 0?s[1]:this.dictionary.decode(r[1]),n[2]!==void 0?s[2]:this.dictionary.decode(r[2]),n[3]!==void 0?s[3]:this.dictionary.decode(r[3])]}*findEncoded(s,n){return yield*this.findEncodedInner(0,s,n,this.nestedMap,[])}*findEncodedInner(s,n,r,a,o){if(s===n.length)yield[...o];else{const l=n[s];if(r[s]){const d=l;if(d!==void 0){const h=a.get(d);h&&(o[s]=l,yield*this.findEncodedInner(s+1,n,r,h,o))}}else for(const[d,h]of a.entries())o[s]=d,yield*this.findEncodedInner(s+1,n,r,h,o)}}count(s){return this.countInner(0,s,this.nestedMap)}countInner(s,n,r){const a=n[s];let o=0;if(a){const l=this.dictionary.encodeOptional(a);if(l!==void 0){if(s===n.length-1)return r.has(l)?1:0;const c=r.get(l);c&&(o+=this.countInner(s+1,n,c))}}else{if(s===n.length-1)return r.size;for(const l of r.values())o+=this.countInner(s+1,n,l)}return o}};return Vh.RdfStoreIndexNestedMapRecursive=e,Vh}var kh={},rj;function gee(){if(rj)return kh;rj=1,Object.defineProperty(kh,"__esModule",{value:!0}),kh.RdfStoreIndexNestedMapRecursiveQuoted=void 0;const t=Xi(),e=hB();let u=class extends e.RdfStoreIndexNestedMapRecursive{constructor(n){super(n),this.features={quotedTripleFiltering:!0}}*findEncoded(n,r){return yield*this.findEncodedInnerQuoted(0,n,r,(0,t.arePatternsQuoted)(r),this.nestedMap,[])}*findEncodedInnerQuoted(n,r,a,o,l,c){if(n===r.length)yield[...c];else{const d=r[n],h=a[n];if(h)if(o[n]){const f=this.dictionary.findQuotedTriplesEncoded(h);for(const p of f){const y=l.get(p);y&&(c[n]=p,yield*this.findEncodedInnerQuoted(n+1,r,a,o,y,c))}}else{const f=d;if(f!==void 0){const p=l.get(f);p&&(c[n]=d,yield*this.findEncodedInnerQuoted(n+1,r,a,o,p,c))}}else for(const[f,p]of l.entries())c[n]=f,yield*this.findEncodedInnerQuoted(n+1,r,a,o,p,c)}}countInner(n,r,a){const o=r[n];let l=0;if(o)if(o.termType==="Quad"&&(0,t.quadHasVariables)(o)){const c=this.dictionary.findQuotedTriplesEncoded(o);for(const d of c)if(n===r.length-1)a.has(d)&&l++;else{const h=a.get(d);h&&(l+=this.countInner(n+1,r,h))}}else{const c=this.dictionary.encodeOptional(o);if(c!==void 0){if(n===r.length-1)return a.has(c)?1:0;const d=a.get(c);d&&(l+=this.countInner(n+1,r,d))}}else{if(n===r.length-1)return a.size;for(const c of a.values())l+=this.countInner(n+1,r,c)}return l}};return kh.RdfStoreIndexNestedMapRecursiveQuoted=u,kh}var zh={},nj;function pB(){if(nj)return zh;nj=1,Object.defineProperty(zh,"__esModule",{value:!0}),zh.RdfStoreIndexNestedRecord=void 0;const t=Xi();let e=class{constructor(s){this.features={quotedTripleFiltering:!1},this.dictionary=s.dictionary,this.nestedRecords={}}set(s,n){const r=this.nestedRecords,a=r[s[0]]||(r[s[0]]={}),o=a[s[1]]||(a[s[1]]={}),l=o[s[2]]||(o[s[2]]={});return l[s[3]]?!1:(l[s[3]]=n,!0)}remove(s){const n=this.nestedRecords,r=n[s[0]];if(!r)return!1;const a=r[s[1]];if(!a)return!1;const o=a[s[2]];return!o||!o[s[3]]?!1:(delete o[s[3]],Object.keys(o).length===0&&(delete a[s[2]],Object.keys(a).length===0&&(delete r[s[1]],Object.keys(r).length===0&&delete n[s[0]])),!0)}get(s){const n=(0,t.encodeOptionalTerms)(s,this.dictionary);if(!(!n||n.includes(void 0)))return this.getEncoded(n)}getEncoded(s){var n,r,a;return(a=(r=(n=this.nestedRecords[s[0]])===null||n===void 0?void 0:n[s[1]])===null||r===void 0?void 0:r[s[2]])===null||a===void 0?void 0:a[s[3]]}*find(s){const n=(0,t.encodeOptionalTerms)(s,this.dictionary);if(!n)return;const[r,a,o,l]=n,[c,d,h,f]=s;let p,y,b,g,m,v,_;const w=this.nestedRecords,S=r!==void 0?r in w?[r]:[]:Object.keys(w);for(const A of S){m=w[A],p=c||this.dictionary.decode(Number.parseInt(A,10));const D=a!==void 0?a in m?[a]:[]:Object.keys(m);for(const L of D){v=m[L],y=d||this.dictionary.decode(Number.parseInt(L,10));const O=o!==void 0?o in v?[o]:[]:Object.keys(v);for(const E of O){_=v[E],b=h||this.dictionary.decode(Number.parseInt(E,10));const P=l!==void 0?l in _?[l]:[]:Object.keys(_);for(const M of P)g=f||this.dictionary.decode(Number.parseInt(M,10)),yield[p,y,b,g]}}}}*findEncoded(s,n){const[r,a,o,l]=s;let c,d,h;const f=this.nestedRecords,p=r!==void 0?r in f?[r]:[]:Object.keys(f);for(const y of p){c=f[y];const b=a!==void 0?a in c?[a]:[]:Object.keys(c);for(const g of b){d=c[g];const m=o!==void 0?o in d?[o]:[]:Object.keys(d);for(const v of m){h=d[v];const _=l!==void 0?l in h?[l]:[]:Object.keys(h);for(const w of _)yield[Number.parseInt(y,10),Number.parseInt(g,10),Number.parseInt(v,10),Number.parseInt(w,10)]}}}}count(s){let n=0;const r=(0,t.encodeOptionalTerms)(s,this.dictionary);if(!r)return 0;const a=r[0],o=r[1],l=r[2],c=r[3];let d,h,f;const p=this.nestedRecords,y=a!==void 0?a in p?[a]:[]:Object.keys(p);for(const b of y){d=p[b];const g=o!==void 0?o in d?[o]:[]:Object.keys(d);for(const m of g){h=d[m];const v=l!==void 0?l in h?[l]:[]:Object.keys(h);for(const _ of v)f=h[_],c!==void 0?c in f&&n++:n+=Object.keys(f).length}}return n}};return zh.RdfStoreIndexNestedRecord=e,zh}var Gh={},ij;function _ee(){if(ij)return Gh;ij=1,Object.defineProperty(Gh,"__esModule",{value:!0}),Gh.RdfStoreIndexNestedRecordQuoted=void 0;const t=Xi(),e=pB();let u=class extends e.RdfStoreIndexNestedRecord{constructor(n){super(n),this.features={quotedTripleFiltering:!0}}*getQuotedPatternKeys(n,r){for(const a of this.dictionary.findQuotedTriplesEncoded(r))a in n&&(yield a)}*find(n){const r=(0,t.encodeOptionalTerms)(n,this.dictionary);if(!r)return;const[a,o,l,c]=r,[d,h,f,p]=n,[y,b,g,m]=(0,t.arePatternsQuoted)(n);let v,_,w,S,A,D,L;const O=this.nestedRecords,E=d!==void 0?y?this.getQuotedPatternKeys(O,d):a in O?[a]:[]:Object.keys(O);for(const P of E){A=O[P],v=!y&&d?d:this.dictionary.decode(Number.parseInt(P,10));const M=h!==void 0?b?this.getQuotedPatternKeys(A,h):o in A?[o]:[]:Object.keys(A);for(const U of M){D=A[U],_=!b&&h?h:this.dictionary.decode(Number.parseInt(U,10));const j=f!==void 0?g?this.getQuotedPatternKeys(D,f):l in D?[l]:[]:Object.keys(D);for(const q of j){L=D[q],w=!g&&f?f:this.dictionary.decode(Number.parseInt(q,10));const $=p!==void 0?m?this.getQuotedPatternKeys(L,p):c in L?[c]:[]:Object.keys(L);for(const Z of $)S=!m&&p?p:this.dictionary.decode(Number.parseInt(Z,10)),yield[v,_,w,S]}}}}*findEncoded(n,r){const[a,o,l,c]=n,[d,h,f,p]=r,[y,b,g,m]=(0,t.arePatternsQuoted)(r);let v,_,w;const S=this.nestedRecords,A=d!==void 0?y?this.getQuotedPatternKeys(S,d):a in S?[a]:[]:Object.keys(S);for(const D of A){v=S[D];const L=h!==void 0?b?this.getQuotedPatternKeys(v,h):o in v?[o]:[]:Object.keys(v);for(const O of L){_=v[O];const E=f!==void 0?g?this.getQuotedPatternKeys(_,f):l in _?[l]:[]:Object.keys(_);for(const P of E){w=_[P];const M=p!==void 0?m?this.getQuotedPatternKeys(w,p):c in w?[c]:[]:Object.keys(w);for(const U of M)yield[Number.parseInt(D,10),Number.parseInt(O,10),Number.parseInt(P,10),Number.parseInt(U,10)]}}}}count(n){let r=0;const a=(0,t.encodeOptionalTerms)(n,this.dictionary);if(!a)return 0;const[o,l,c,d]=a,[h,f,p,y]=n,[b,g,m,v]=(0,t.arePatternsQuoted)(n);let _,w,S;const A=this.nestedRecords,D=h!==void 0?b?this.getQuotedPatternKeys(A,h):o in A?[o]:[]:Object.keys(A);for(const L of D){_=A[L];const O=f!==void 0?g?this.getQuotedPatternKeys(_,f):l in _?[l]:[]:Object.keys(_);for(const E of O){w=_[E];const P=p!==void 0?m?this.getQuotedPatternKeys(w,p):c in w?[c]:[]:Object.keys(w);for(const M of P)S=w[M],y!==void 0?v?r+=[...this.getQuotedPatternKeys(S,y)].length:d in S&&r++:r+=Object.keys(S).length}}return r}};return Gh.RdfStoreIndexNestedRecordQuoted=u,Gh}var aS={},aj;function vee(){return aj||(aj=1,Object.defineProperty(aS,"__esModule",{value:!0})),aS}var sS={},sj;function wee(){return sj||(sj=1,Object.defineProperty(sS,"__esModule",{value:!0})),sS}var oj;function See(){return oj||(oj=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(fB(),t),u(dee(),t),u(fee(),t),u(hee(),t),u(oB(),t),u(pee(),t),u(uB(),t),u(yee(),t),u(bee(),t),u(mee(),t),u(bA(),t),u(cB(),t),u(hB(),t),u(gee(),t),u(pB(),t),u(_ee(),t),u(vee(),t),u(Xi(),t),u(wee(),t),u(lB(),t)}(tS)),tS}var uj;function yB(){if(uj)return Nh;uj=1,Object.defineProperty(Nh,"__esModule",{value:!0}),Nh.storeStream=void 0;const t=See();function e(u){const s=t.RdfStore.createDefault();return new Promise((n,r)=>s.import(u).on("error",r).once("end",()=>n(s)))}return Nh.storeStream=e,Nh}var cj;function Tee(){if(cj)return Ih;cj=1,Object.defineProperty(Ih,"__esModule",{value:!0}),Ih.ActorQuerySourceIdentifyHypermediaNone=void 0;const t=yA(),e=xr(),u=pA(),s=yB();let n=class extends u.ActorQuerySourceIdentifyHypermedia{constructor(a){super(a,"file")}async testMetadata(a){return{filterFactor:0}}async run(a){this.logInfo(a.context,`Identified as file source: ${a.url}`);const o=new t.QuerySourceRdfJs(await(0,s.storeStream)(a.quads),await e.BindingsFactory.create(this.mediatorMergeBindingsContext,a.context));return o.toString=()=>`QuerySourceRdfJs(${a.url})`,o.referenceValue=a.url,{source:o}}};return Ih.ActorQuerySourceIdentifyHypermediaNone=n,Ih}var lj;function Aee(){return lj||(lj=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Tee(),t)}(Y2)),Y2}var oS={},Wh={},uS={},Jh={},Xh={},cS={},Ds={},dj;function Ki(){if(dj)return Ds;dj=1,Object.defineProperty(Ds,"__esModule",{value:!0}),Ds.asTermType=Ds.ExpressionType=void 0;var t;(function(u){u.Aggregate="aggregate",u.Existence="existence",u.Named="named",u.Operator="operator",u.SpecialOperator="specialOperator",u.Term="term",u.Variable="variable",u.AsyncExtension="asyncExtension",u.SyncExtension="syncExtension"})(t||(Ds.ExpressionType=t={}));function e(u){if(u==="namedNode"||u==="literal"||u==="blankNode"||u==="quad")return u}return Ds.asTermType=e,Ds}var Kh={},fj;function Eee(){if(fj)return Kh;fj=1,Object.defineProperty(Kh,"__esModule",{value:!0}),Kh.Variable=void 0;const t=Ki();let e=class{constructor(s){this.expressionType=t.ExpressionType.Variable,this.name=s}};return Kh.Variable=e,Kh}var At={},Yh={},lS={},hj;function Nn(){return hj||(hj=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.NamedOperators=t.SetFunctions=t.SetFunction=t.Operators=t.SpecialOperators=t.RegularOperators=t.SpecialOperator=t.RegularOperator=t.TypeURL=t.TypeAlias=void 0;var e;(function(a){a.SPARQL_NUMERIC="SPARQL_NUMERIC",a.SPARQL_STRINGLY="SPARQL_STRINGLY"})(e||(t.TypeAlias=e={}));var u;(function(a){a.XSD_ANY_URI="http://www.w3.org/2001/XMLSchema#anyURI",a.XSD_STRING="http://www.w3.org/2001/XMLSchema#string",a.RDF_LANG_STRING="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString",a.XSD_BOOLEAN="http://www.w3.org/2001/XMLSchema#boolean",a.XSD_DATE_TIME="http://www.w3.org/2001/XMLSchema#dateTime",a.XSD_DATE_TIME_STAMP="http://www.w3.org/2001/XMLSchema#dateTimeStamp",a.XSD_DATE="http://www.w3.org/2001/XMLSchema#date",a.XSD_G_MONTH="http://www.w3.org/2001/XMLSchema#gMonth",a.XSD_G_MONTHDAY="http://www.w3.org/2001/XMLSchema#gMonthDay",a.XSD_G_YEAR="http://www.w3.org/2001/XMLSchema#gYear",a.XSD_G_YEAR_MONTH="http://www.w3.org/2001/XMLSchema#gYearMonth",a.XSD_TIME="http://www.w3.org/2001/XMLSchema#time",a.XSD_G_DAY="http://www.w3.org/2001/XMLSchema#gDay",a.XSD_DECIMAL="http://www.w3.org/2001/XMLSchema#decimal",a.XSD_FLOAT="http://www.w3.org/2001/XMLSchema#float",a.XSD_DOUBLE="http://www.w3.org/2001/XMLSchema#double",a.XSD_INTEGER="http://www.w3.org/2001/XMLSchema#integer",a.XSD_NON_POSITIVE_INTEGER="http://www.w3.org/2001/XMLSchema#nonPositiveInteger",a.XSD_NEGATIVE_INTEGER="http://www.w3.org/2001/XMLSchema#negativeInteger",a.XSD_LONG="http://www.w3.org/2001/XMLSchema#long",a.XSD_INT="http://www.w3.org/2001/XMLSchema#int",a.XSD_SHORT="http://www.w3.org/2001/XMLSchema#short",a.XSD_BYTE="http://www.w3.org/2001/XMLSchema#byte",a.XSD_NON_NEGATIVE_INTEGER="http://www.w3.org/2001/XMLSchema#nonNegativeInteger",a.XSD_POSITIVE_INTEGER="http://www.w3.org/2001/XMLSchema#positiveInteger",a.XSD_UNSIGNED_LONG="http://www.w3.org/2001/XMLSchema#unsignedLong",a.XSD_UNSIGNED_INT="http://www.w3.org/2001/XMLSchema#unsignedInt",a.XSD_UNSIGNED_SHORT="http://www.w3.org/2001/XMLSchema#unsignedShort",a.XSD_UNSIGNED_BYTE="http://www.w3.org/2001/XMLSchema#unsignedByte",a.XSD_NORMALIZED_STRING="http://www.w3.org/2001/XMLSchema#normalizedString",a.XSD_TOKEN="http://www.w3.org/2001/XMLSchema#token",a.XSD_LANGUAGE="http://www.w3.org/2001/XMLSchema#language",a.XSD_NM_TOKEN="http://www.w3.org/2001/XMLSchema#NMTOKEN",a.XSD_NAME="http://www.w3.org/2001/XMLSchema#name",a.XSD_NC_NAME="http://www.w3.org/2001/XMLSchema#NCName",a.XSD_ENTITY="http://www.w3.org/2001/XMLSchema#ENTITY",a.XSD_ID="http://www.w3.org/2001/XMLSchema#ID",a.XSD_ID_REF="http://www.w3.org/2001/XMLSchema#IDREF",a.XSD_DURATION="http://www.w3.org/2001/XMLSchema#duration",a.XSD_YEAR_MONTH_DURATION="http://www.w3.org/2001/XMLSchema#yearMonthDuration",a.XSD_DAY_TIME_DURATION="http://www.w3.org/2001/XMLSchema#dayTimeDuration"})(u||(t.TypeURL=u={}));var s;(function(a){a.NOT="!",a.UMINUS="uminus",a.UPLUS="uplus",a.EQUAL="=",a.NOT_EQUAL="!=",a.LT="<",a.GT=">",a.LTE="<=",a.GTE=">=",a.MULTIPLICATION="*",a.DIVISION="/",a.ADDITION="+",a.SUBTRACTION="-",a.IS_IRI="isiri",a.IS_URI="isuri",a.IS_BLANK="isblank",a.IS_LITERAL="isliteral",a.IS_NUMERIC="isnumeric",a.STR="str",a.LANG="lang",a.DATATYPE="datatype",a.IRI="iri",a.URI="uri",a.STRDT="strdt",a.STRLANG="strlang",a.UUID="uuid",a.STRUUID="struuid",a.STRLEN="strlen",a.SUBSTR="substr",a.UCASE="ucase",a.LCASE="lcase",a.STRSTARTS="strstarts",a.STRENDS="strends",a.CONTAINS="contains",a.STRBEFORE="strbefore",a.STRAFTER="strafter",a.ENCODE_FOR_URI="encode_for_uri",a.LANG_MATCHES="langmatches",a.REGEX="regex",a.REPLACE="replace",a.ABS="abs",a.ROUND="round",a.CEIL="ceil",a.FLOOR="floor",a.RAND="rand",a.NOW="now",a.YEAR="year",a.MONTH="month",a.DAY="day",a.HOURS="hours",a.MINUTES="minutes",a.SECONDS="seconds",a.TIMEZONE="timezone",a.TZ="tz",a.MD5="md5",a.SHA1="sha1",a.SHA256="sha256",a.SHA384="sha384",a.SHA512="sha512",a.TRIPLE="triple",a.SUBJECT="subject",a.PREDICATE="predicate",a.OBJECT="object",a.IS_TRIPLE="istriple"})(s||(t.RegularOperator=s={}));var n;(function(a){a.BOUND="bound",a.IF="if",a.COALESCE="coalesce",a.LOGICAL_OR="||",a.LOGICAL_AND="&&",a.SAME_TERM="sameterm",a.IN="in",a.NOT_IN="notin",a.CONCAT="concat",a.BNODE="bnode"})(n||(t.SpecialOperator=n={})),t.RegularOperators=new Set(Object.values(s)),t.SpecialOperators=new Set(Object.values(n)),t.Operators=new Set([...t.RegularOperators,...t.SpecialOperators]);var r;(function(a){a.COUNT="count",a.SUM="sum",a.MIN="min",a.MAX="max",a.AVG="avg",a.GROUP_CONCAT="group_concat",a.SAMPLE="sample"})(r||(t.SetFunction=r={})),t.SetFunctions=new Set(Object.values(r)),t.NamedOperators=new Set([u.XSD_STRING,u.XSD_FLOAT,u.XSD_DOUBLE,u.XSD_DECIMAL,u.XSD_INTEGER,u.XSD_DATE_TIME,u.XSD_DATE,u.XSD_BOOLEAN,u.XSD_TIME,u.XSD_DURATION,u.XSD_DAY_TIME_DURATION,u.XSD_YEAR_MONTH_DURATION])}(lS)),lS}var mt={},pj;function on(){if(pj)return mt;pj=1,Object.defineProperty(mt,"__esModule",{value:!0}),mt.NoExistenceHook=mt.NoAggregator=mt.ExtensionFunctionError=mt.UnknownNamedOperator=mt.UnknownOperator=mt.InvalidTermType=mt.InvalidExpressionType=mt.InvalidExpression=mt.InvalidArity=mt.UnexpectedError=mt.ParseError=mt.EmptyAggregateError=mt.IncompatibleLanguageOperation=mt.InvalidTimezoneCall=mt.CastError=mt.InvalidCompareArgumentTypes=mt.InvalidArgumentTypes=mt.InError=mt.CoalesceError=mt.RDFEqualTypeError=mt.EBVCoercionError=mt.UnboundVariableError=mt.InvalidLexicalForm=mt.isExpressionError=mt.ExpressionError=void 0;class t extends Error{}mt.ExpressionError=t;function e(E){return E instanceof t}mt.isExpressionError=e;class u extends t{constructor(P){super(`Invalid lexical form '${O(P)}'`),this.arg=P}}mt.InvalidLexicalForm=u;class s extends t{constructor(P,M){super(`Unbound variable '${O(P)}'`),this.variable=P,this.bindings=M}}mt.UnboundVariableError=s;class n extends t{constructor(P){super(`Cannot coerce term to EBV '${O(P)}'`),this.arg=P}}mt.EBVCoercionError=n;class r extends t{constructor(P){super("Equality test for literals with unsupported datatypes"),this.args=P}}mt.RDFEqualTypeError=r;class a extends t{constructor(P){super("All COALESCE arguments threw errors"),this.errors=P}}mt.CoalesceError=a;class o extends t{constructor(P){super(`Some argument to IN errorred and none where equal. ${P.map(M=>`(${M.toString()}) `).join("and ")}`),this.errors=P}}mt.InError=o;class l extends t{constructor(P,M){super(`Argument types not valid for operator: '${O(M)}' with '${O(P)}`),this.args=P,this.op=M}}mt.InvalidArgumentTypes=l;class c extends t{constructor(P,M){super(`Compared argument types are supported: '${P.termType}' and '${M.termType}'`),this.arg0=P,this.arg1=M}}mt.InvalidCompareArgumentTypes=c;class d extends t{constructor(P,M){super(`Invalid cast: '${O(P)}' to '${O(M)}'`),this.arg=P}}mt.CastError=d;class h extends t{constructor(P){super(`TIMEZONE call on ${P} which has no timezone`),this.dateString=P}}mt.InvalidTimezoneCall=h;class f extends t{constructor(P,M){super(`Operation on incompatible language literals '${O(P)}' and '${O(M)}'`),this.arg1=P,this.arg2=M}}mt.IncompatibleLanguageOperation=f;class p extends t{constructor(){super("Empty aggregate expression")}}mt.EmptyAggregateError=p;class y extends t{constructor(P,M){super(`Failed to parse ${P} as ${M}.`)}}mt.ParseError=y;class b extends Error{constructor(P,M){super(`Programmer Error '${P}'`),this.payload=M}}mt.UnexpectedError=b;class g extends Error{constructor(P,M){super(`The number of args does not match the arity of the operator '${O(M)}'.`),this.args=P,this.op=M}}mt.InvalidArity=g;class m extends Error{constructor(P){super(`Invalid SPARQL Expression '${O(P)}'`)}}mt.InvalidExpression=m;class v extends Error{constructor(P){super(`Invalid expression type for SPARQL Expression '${O(P)}'`),this.expr=P}}mt.InvalidExpressionType=v;class _ extends Error{constructor(P){super(`Invalid term type for term '${O(P)}'`),this.term=P}}mt.InvalidTermType=_;class w extends Error{constructor(P){super(`Unknown operator: '${O(P)}`)}}mt.UnknownOperator=w;class S extends Error{constructor(P){super(`Unknown named operator: '${O(P)}'`)}}mt.UnknownNamedOperator=S;class A extends Error{constructor(P,M){M instanceof Error?super(`Error thrown in ${P}: ${M.message}${M.stack?` +${M.stack}`:""}`):super(`Error thrown in ${P}`)}}mt.ExtensionFunctionError=A;class D extends Error{constructor(P){super(`Aggregate expression ${O(P)} found, but no aggregate hook provided.`)}}mt.NoAggregator=D;class L extends Error{constructor(){super("EXISTS found, but no existence hook provided.")}}mt.NoExistenceHook=L;function O(E){return JSON.stringify(E)}return mt}var jr={},Ht={},yj;function uu(){if(yj)return Ht;yj=1,Object.defineProperty(Ht,"__esModule",{value:!0}),Ht.extractTimeZone=Ht.extractRawTimeZone=Ht.dayTimeDurationsToSeconds=Ht.yearMonthDurationsToMonths=Ht.trimToDayTimeDuration=Ht.trimToYearMonthDuration=Ht.toUTCDate=Ht.toJSDate=Ht.negateDuration=Ht.toDateTimeRepresentation=Ht.defaultedDateTimeRepresentation=Ht.simplifyDurationRepresentation=Ht.defaultedDurationRepresentation=Ht.defaultedYearMonthDurationRepresentation=Ht.defaultedDayTimeDurationRepresentation=void 0;function t(b){return{day:b.day??0,hours:b.hours??0,minutes:b.minutes??0,seconds:b.seconds??0}}Ht.defaultedDayTimeDurationRepresentation=t;function e(b){return{year:b.year??0,month:b.month??0}}Ht.defaultedYearMonthDurationRepresentation=e;function u(b){return{...t(b),...e(b)}}Ht.defaultedDurationRepresentation=u;function s(b){const g=u(b),m={},v=g.year+Math.trunc(g.month/12);v&&(m.year=v,g.month%=12),g.month&&(m.month=g.month);const _=g.day+Math.trunc(g.hours/24)+Math.trunc(g.minutes/(24*60))+Math.trunc(g.seconds/(24*60*60));_&&(m.day=_,g.hours%=24,g.minutes%=24*60,g.seconds%=24*60*60);const w=g.hours+Math.trunc(g.minutes/60)+Math.trunc(g.seconds/(60*60));w&&(m.hours=w,g.minutes%=60,g.seconds%=60*60);const S=g.minutes+Math.trunc(g.seconds/60);return S&&(m.minutes=S,g.seconds%=60),g.seconds&&(m.seconds=g.seconds),m}Ht.simplifyDurationRepresentation=s;function n(b){return{...b,day:b.day??1,hours:b.hours??0,month:b.month??1,year:b.year??0,seconds:b.seconds??0,minutes:b.minutes??0}}Ht.defaultedDateTimeRepresentation=n;function r({date:b,timeZone:g}){return{year:b.getFullYear(),month:b.getMonth()+1,day:b.getDate(),hours:b.getHours(),minutes:b.getMinutes(),seconds:b.getSeconds(),zoneHours:g.zoneHours,zoneMinutes:g.zoneMinutes}}Ht.toDateTimeRepresentation=r;function a(b){return{year:b.year===void 0?void 0:-1*b.year,month:b.month===void 0?void 0:-1*b.month,day:b.day===void 0?void 0:-1*b.day,hours:b.hours===void 0?void 0:-1*b.hours,minutes:b.minutes===void 0?void 0:-1*b.minutes,seconds:b.seconds===void 0?void 0:-1*b.seconds}}Ht.negateDuration=a;function o(b){const g=new Date(b.year,b.month-1,b.day,b.hours,b.minutes,Math.trunc(b.seconds),b.seconds%1*1e3);return b.year>=0&&b.year<100&&g.setFullYear(g.getFullYear()-1900),g}Ht.toJSDate=o;function l(b,g){const m=o(n(b)),v=m.getTimezoneOffset(),_=b.zoneHours??g.zoneHours,w=b.zoneMinutes??g.zoneMinutes;return new Date(m.getTime()-(v+_*60+w)*60*1e3)}Ht.toUTCDate=l;function c(b){return{year:b.year,month:b.month}}Ht.trimToYearMonthDuration=c;function d(b){return{day:b.day,hours:b.hours,minutes:b.minutes,seconds:b.seconds}}Ht.trimToDayTimeDuration=d;function h(b){return b.year*12+b.month}Ht.yearMonthDurationsToMonths=h;function f(b){return((b.day*24+b.hours)*60+b.minutes)*60+b.seconds}Ht.dayTimeDurationsToSeconds=f;function p(b){return/(Z|([+-]\d\d:\d\d))?$/u.exec(b)[0]}Ht.extractRawTimeZone=p;function y(b){return{zoneHours:b.getTimezoneOffset()/60,zoneMinutes:b.getTimezoneOffset()%60}}return Ht.extractTimeZone=y,Ht}var ca={},bj;function bB(){if(bj)return ca;bj=1,Object.defineProperty(ca,"__esModule",{value:!0}),ca.elapsedDuration=ca.addDurationToDateTime=ca.maximumDayInMonthFor=void 0;const t=uu();function e(r,a,o=0){const l=r-o,c=a-o,d=Math.floor(l/c);return{intDiv:d,remainder:r-d*c}}function u(r,a){const{intDiv:o,remainder:l}=e(a,13,1),c=r+o;return[1,3,5,7,8,10,12].includes(l)?31:[4,6,9,11].includes(l)?30:l===2&&(e(c,400).remainder===0||e(c,100).remainder!==0&&e(c,4).remainder===0)?29:28}ca.maximumDayInMonthFor=u;function s(r,a){const o={...r};let l=e(r.month+a.month,13,1);for(o.month=l.remainder,o.year=r.year+a.year+l.intDiv,l=e(r.seconds+a.seconds,60),o.seconds=l.remainder,l=e(r.minutes+a.minutes+l.intDiv,60),o.minutes=l.remainder,l=e(r.hours+a.hours+l.intDiv,24),o.hours=l.remainder,o.day=r.day+a.day+l.intDiv;;){let c;if(o.day<1)o.day+=u(o.year,o.month-1),c=-1;else if(o.day>u(o.year,o.month))o.day-=u(o.year,o.month),c=1;else break;l=e(o.month+c,13,1),o.month=l.remainder,o.year+=l.intDiv}return o}ca.addDurationToDateTime=s;function n(r,a,o){const l=(0,t.toUTCDate)(r,o),c=(0,t.toUTCDate)(a,o),d=l.getTime()-c.getTime();return{day:Math.floor(d/(1e3*60*60*24)),hours:Math.floor(d%(1e3*60*60*24)/(1e3*60*60)),minutes:Math.floor(d%(1e3*60*60)/(1e3*60)),seconds:d%(1e3*60)}}return ca.elapsedDuration=n,ca}var mj;function P3(){if(mj)return jr;mj=1,Object.defineProperty(jr,"__esModule",{value:!0}),jr.parseDayTimeDuration=jr.parseYearMonthDuration=jr.parseDuration=jr.parseTime=jr.parseDate=jr.parseDateTime=jr.parseXSDInteger=jr.parseXSDDecimal=jr.parseXSDFloat=void 0;const t=uu(),e=on(),u=bB();function s(y){const b=Number(y);return Number.isNaN(b)?y==="NaN"?Number.NaN:y==="INF"||y==="+INF"?Number.POSITIVE_INFINITY:y==="-INF"?Number.NEGATIVE_INFINITY:void 0:b}jr.parseXSDFloat=s;function n(y){const b=Number(y);return Number.isNaN(b)?void 0:b}jr.parseXSDDecimal=n;function r(y){const b=Number.parseInt(y,10);return Number.isNaN(b)?void 0:b}jr.parseXSDInteger=r;function a(y){const[b,g]=y.split("T");return{...l(b),...c(g)}}jr.parseDateTime=a;function o(y){if(y==="")return{zoneHours:void 0,zoneMinutes:void 0};if(y==="Z")return{zoneHours:0,zoneMinutes:0};const g=y.replaceAll(/^([+|-])(\d\d):(\d\d)$/gu,"$11!$2!$3").split("!").map(Number);return{zoneHours:g[0]*g[1],zoneMinutes:g[0]*g[2]}}function l(y){const b=y.replaceAll(/^(-)?([123456789]*\d{4})-(\d\d)-(\d\d)(Z|([+-]\d\d:\d\d))?$/gu,"$11!$2!$3!$4!$5");if(b===y)throw new e.ParseError(y,"date");const g=b.split("!"),m=g.slice(0,-1).map(Number),v={year:m[0]*m[1],month:m[2],day:m[3],...o(g[4])};if(!(v.month>=1&&v.month<=12)||!(v.day>=1&&v.day<=(0,u.maximumDayInMonthFor)(v.year,v.month)))throw new e.ParseError(y,"date");return v}jr.parseDate=l;function c(y){const b=y.replaceAll(/^(\d\d):(\d\d):(\d\d(\.\d+)?)(Z|([+-]\d\d:\d\d))?$/gu,"$1!$2!$3!$5");if(b===y)throw new e.ParseError(y,"time");const g=b.split("!"),m=g.slice(0,-1).map(Number),v={hours:m[0],minutes:m[1],seconds:m[2],...o(g[3])};if(v.seconds>=60||v.minutes>=60||v.hours>24||v.hours===24&&(v.minutes!==0||v.seconds!==0))throw new e.ParseError(y,"time");return v}function d(y){const b=c(y);return b.hours%=24,b}jr.parseTime=d;function h(y){const[b,g]=y.split("T"),m=b.replaceAll(/^(-)?P(\d+Y)?(\d+M)?(\d+D)?$/gu,"$11S!$2!$3!$4");if(m===b)throw new e.ParseError(y,"duration");const v=m.split("!");if(g!==void 0){const S=g.replaceAll(/^(\d+H)?(\d+M)?(\d+(\.\d+)?S)?$/gu,"$1!$2!$3");if(g===""||g===S)throw new e.ParseError(y,"duration");v.push(...S.split("!"))}const _=v.map(S=>S.slice(0,-1));if(!_.slice(1).some(Boolean))throw new e.ParseError(y,"duration");const w=Number(_[0]);return(0,t.simplifyDurationRepresentation)({year:_[1]?w*Number(_[1]):void 0,month:_[2]?w*Number(_[2]):void 0,day:_[3]?w*Number(_[3]):void 0,hours:_[4]?w*Number(_[4]):void 0,minutes:_[5]?w*Number(_[5]):void 0,seconds:_[6]?w*Number(_[6]):void 0})}jr.parseDuration=h;function f(y){const b=h(y);if(["hours","minutes","seconds","day"].some(g=>!!b[g]))throw new e.ParseError(y,"yearMonthDuration");return b}jr.parseYearMonthDuration=f;function p(y){const b=h(y);if(["year","month"].some(g=>!!b[g]))throw new e.ParseError(y,"dayTimeDuration");return b}return jr.parseDayTimeDuration=p,jr}var dS={},fr={},Zh={},gj;function mB(){if(gj)return Zh;gj=1,Object.defineProperty(Zh,"__esModule",{value:!0}),Zh.OverloadTree=void 0;const t=Kn(),e=am();let u=class D3{constructor(n,r){this.identifier=n,this.implementation=void 0,this.generalOverloads=Object.create(null),this.literalOverLoads=[],this.depth=r??0,this.promotionCount=void 0}getSubtree(n){const r=(0,e.asGeneralType)(n);if(r)return this.generalOverloads[r];for(const[a,o]of this.literalOverLoads)if(n===a)return o}getImplementationExact(n){let r=this;for(const a of n)if(r=r.getSubtree(a),!r)return;return r.implementation}search(n,r,a){let o=a[this.identifier],l=0;for(;l({node:h,index:d+1})));c.length>0;){const{index:h,node:f}=c.pop();if(h===n.length&&f.implementation)return this.addToCache(a,n,f.implementation),f.implementation;c.push(...f.getSubTreeWithArg(n[h],r).map(p=>({node:p,index:h+1})))}}addToCache(n,r,a){function o(c,d){return d in c||(c[d]={}),c[d]}let l=o(n,this.identifier);for(const c of r){const d=(0,t.isLiteralTermExpression)(c),h=d?d.dataType:c.termType;l.cache=l.cache??{},l=o(l.cache,h)}l.func=a}addOverload(n,r){this._addOverload([...n],r,0)}_addOverload(n,r,a){const[o,...l]=n;if(!o){(this.promotionCount===void 0||a<=this.promotionCount)&&(this.promotionCount=a,this.implementation=r);return}let c=this.getSubtree(o);if(!c){const d=new D3(this.identifier,this.depth+1),h=(0,e.asGeneralType)(o);h&&(this.generalOverloads[h]=d);const f=(0,e.asOverrideType)(o);f&&this.literalOverLoads.push([f,d]),c=d}if(c._addOverload(l,r,a),e.typePromotion[o])for(const d of e.typePromotion[o])this.addPromotedOverload(d.typeToPromote,r,d.conversionFunction,l,a)}addPromotedOverload(n,r,a,o,l){let c=this.getSubtree(n);if(!c){const d=new D3(this.identifier,this.depth+1);this.literalOverLoads.push([n,d]),c=d}c._addOverload(o,d=>h=>r(d)([...h.slice(0,this.depth),a(h[this.depth]),...h.slice(this.depth+1,h.length)]),l+1)}getSubTreeWithArg(n,r){const a=[],o=(0,t.isLiteralTermExpression)(n);if(this.generalOverloads.term&&a.push(this.generalOverloads.term),this.generalOverloads[n.termType]&&a.push(this.generalOverloads[n.termType]),o){const l=(0,e.asKnownLiteralType)(o.dataType);let c;l?c=e.superTypeDictTable[l]:c=(0,e.getSuperTypes)(o.dataType,r);const d=this.literalOverLoads.filter(([h,f])=>h in c).map(([h,f])=>[c[h],f]);d.sort(([h,f],[p,y])=>h-p),a.push(...d.map(([h,f])=>f))}return a}};return Zh.OverloadTree=u,Zh}var _j;function Yi(){if(_j)return fr;_j=1,Object.defineProperty(fr,"__esModule",{value:!0}),fr.expressionToVar=fr.dateTime=fr.langString=fr.string=fr.double=fr.float=fr.decimal=fr.integer=fr.bool=fr.Builder=fr.declare=void 0;const t=Et(),e=Kn(),u=Kn(),s=Nn(),n=Nn(),r=on(),a=mB(),o=new t.DataFactory;function l(_){return new c(_)}fr.declare=l;class c{constructor(w){this.overloadTree=new a.OverloadTree(w),this.collected=!1}collect(){if(this.collected)throw new Error("Builders can only be collected once!");return this.collected=!0,this.overloadTree}static wrapInvalidLexicalProtected(w){return S=>A=>{for(const[D,L]of A.entries())if(L instanceof u.NonLexicalLiteral)throw new r.InvalidLexicalForm(A[D].toRDF());return w(S)(A)}}set(w,S,A=!0){return this.overloadTree.addOverload(w,A?c.wrapInvalidLexicalProtected(S):S),this}copy({from:w,to:S}){const A=this.overloadTree.getImplementationExact(w);if(!A)throw new r.UnexpectedError("Tried to copy implementation, but types not found",{from:w,to:S});return this.set(S,A)}onUnary(w,S,A=!0){return this.set([w],D=>([L])=>S(D)(L),A)}onUnaryTyped(w,S,A=!0){return this.set([w],D=>([L])=>S(D)(L.typedValue),A)}onBinary(w,S,A=!0){return this.set(w,D=>([L,O])=>S(D)(L,O),A)}onBinaryTyped(w,S,A=!0){return this.set(w,D=>([L,O])=>S(D)(L.typedValue,O.typedValue),A)}onTernaryTyped(w,S,A=!0){return this.set(w,D=>([L,O,E])=>S(D)(L.typedValue,O.typedValue,E.typedValue),A)}onTernary(w,S,A=!0){return this.set(w,D=>([L,O,E])=>S(D)(L,O,E),A)}onQuaternaryTyped(w,S,A=!0){return this.set(w,D=>([L,O,E,P])=>S(D)(L.typedValue,O.typedValue,E.typedValue,P.typedValue),A)}onTerm1(w,S=!1){return this.set(["term"],A=>([D])=>w(A)(D),S)}onTerm3(w){return this.set(["term","term","term"],S=>([A,D,L])=>w(S)(A,D,L))}onQuad1(w){return this.set(["quad"],S=>([A])=>w(S)(A))}onLiteral1(w,S=!0){return this.set(["literal"],A=>([D])=>w(A)(D),S)}onBoolean1(w,S=!0){return this.set([s.TypeURL.XSD_BOOLEAN],A=>([D])=>w(A)(D),S)}onBoolean1Typed(w,S=!0){return this.set([s.TypeURL.XSD_BOOLEAN],A=>([D])=>w(A)(D.typedValue),S)}onString1(w,S=!0){return this.set([s.TypeURL.XSD_STRING],A=>([D])=>w(A)(D),S)}onString1Typed(w,S=!0){return this.set([s.TypeURL.XSD_STRING],A=>([D])=>w(A)(D.typedValue),S)}onLangString1(w,S=!0){return this.set([s.TypeURL.RDF_LANG_STRING],A=>([D])=>w(A)(D),S)}onStringly1(w,S=!0){return this.set([s.TypeAlias.SPARQL_STRINGLY],A=>([D])=>w(A)(D),S)}onStringly1Typed(w,S=!0){return this.set([s.TypeAlias.SPARQL_STRINGLY],A=>([D])=>w(A)(D.typedValue),S)}onNumeric1(w,S=!0){return this.set([s.TypeAlias.SPARQL_NUMERIC],A=>([D])=>w(A)(D),S)}onDateTime1(w,S=!0){return this.set([s.TypeURL.XSD_DATE_TIME],A=>([D])=>w(A)(D),S)}numericConverter(w,S=!0){const A=D=>L=>w(D)(L.typedValue);return this.onUnary(n.TypeURL.XSD_INTEGER,D=>L=>h(A(D)(L)),S).onUnary(n.TypeURL.XSD_DECIMAL,D=>L=>f(A(D)(L)),S).onUnary(n.TypeURL.XSD_FLOAT,D=>L=>p(A(D)(L)),S).onUnary(n.TypeURL.XSD_DOUBLE,D=>L=>y(A(D)(L)),S)}arithmetic(w,S=!0){const A=D=>(L,O)=>w(D)(L.typedValue,O.typedValue);return this.onBinary([n.TypeURL.XSD_INTEGER,n.TypeURL.XSD_INTEGER],D=>(L,O)=>h(A(D)(L,O)),S).onBinary([n.TypeURL.XSD_DECIMAL,n.TypeURL.XSD_DECIMAL],D=>(L,O)=>f(A(D)(L,O)),S).onBinary([n.TypeURL.XSD_FLOAT,n.TypeURL.XSD_FLOAT],D=>(L,O)=>p(A(D)(L,O)),S).onBinary([n.TypeURL.XSD_DOUBLE,n.TypeURL.XSD_DOUBLE],D=>(L,O)=>y(A(D)(L,O)),S)}numberTest(w){return this.numeric(S=>([A,D])=>{const L=w(S)(A.typedValue,D.typedValue);return d(L)})}stringTest(w,S=!0){return this.set([s.TypeURL.XSD_STRING,s.TypeURL.XSD_STRING],A=>([D,L])=>{const O=w(A)(D.typedValue,L.typedValue);return d(O)},S)}booleanTest(w,S=!0){return this.set([s.TypeURL.XSD_BOOLEAN,s.TypeURL.XSD_BOOLEAN],A=>([D,L])=>{const O=w(A)(D.typedValue,L.typedValue);return d(O)},S)}dateTimeTest(w,S=!0){return this.set([s.TypeURL.XSD_DATE_TIME,s.TypeURL.XSD_DATE_TIME],A=>([D,L])=>{const O=w(A)(D.typedValue,L.typedValue);return d(O)},S)}numeric(w){return this.set([s.TypeAlias.SPARQL_NUMERIC,s.TypeAlias.SPARQL_NUMERIC],w)}}fr.Builder=c;function d(_){return new e.BooleanLiteral(_)}fr.bool=d;function h(_){return new e.IntegerLiteral(_)}fr.integer=h;function f(_){return new e.DecimalLiteral(_)}fr.decimal=f;function p(_){return new e.FloatLiteral(_)}fr.float=p;function y(_){return new e.DoubleLiteral(_)}fr.double=y;function b(_){return new e.StringLiteral(_)}fr.string=b;function g(_,w){return new e.LangStringLiteral(_,w)}fr.langString=g;function m(_,w){return new e.DateTimeLiteral(_,w)}fr.dateTime=m;function v(_){return o.variable(_.name.slice(1))}return fr.expressionToVar=v,fr}var vj;function am(){return vj||(vj=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.typePromotion=t.isSubTypeOf=t.getSuperTypeDict=t.isInternalSubType=t.asGeneralType=t.asOverrideType=t.asKnownLiteralType=t.asTypeAlias=t.typeAliasCheck=t.extensionTableInit=t.getSuperTypes=t.superTypeDictTable=t.extensionTableInput=void 0;const e=Kn(),u=Yi(),s=Nn();t.extensionTableInput={[s.TypeURL.XSD_DATE_TIME_STAMP]:s.TypeURL.XSD_DATE_TIME,[s.TypeURL.XSD_DAY_TIME_DURATION]:s.TypeURL.XSD_DURATION,[s.TypeURL.XSD_YEAR_MONTH_DURATION]:s.TypeURL.XSD_DURATION,[s.TypeURL.RDF_LANG_STRING]:s.TypeAlias.SPARQL_STRINGLY,[s.TypeURL.XSD_STRING]:s.TypeAlias.SPARQL_STRINGLY,[s.TypeURL.XSD_NORMALIZED_STRING]:s.TypeURL.XSD_STRING,[s.TypeURL.XSD_TOKEN]:s.TypeURL.XSD_NORMALIZED_STRING,[s.TypeURL.XSD_LANGUAGE]:s.TypeURL.XSD_TOKEN,[s.TypeURL.XSD_NM_TOKEN]:s.TypeURL.XSD_TOKEN,[s.TypeURL.XSD_NAME]:s.TypeURL.XSD_TOKEN,[s.TypeURL.XSD_NC_NAME]:s.TypeURL.XSD_NAME,[s.TypeURL.XSD_ENTITY]:s.TypeURL.XSD_NC_NAME,[s.TypeURL.XSD_ID]:s.TypeURL.XSD_NC_NAME,[s.TypeURL.XSD_ID_REF]:s.TypeURL.XSD_NC_NAME,[s.TypeURL.XSD_DOUBLE]:s.TypeAlias.SPARQL_NUMERIC,[s.TypeURL.XSD_FLOAT]:s.TypeAlias.SPARQL_NUMERIC,[s.TypeURL.XSD_DECIMAL]:s.TypeAlias.SPARQL_NUMERIC,[s.TypeURL.XSD_INTEGER]:s.TypeURL.XSD_DECIMAL,[s.TypeURL.XSD_NON_POSITIVE_INTEGER]:s.TypeURL.XSD_INTEGER,[s.TypeURL.XSD_NEGATIVE_INTEGER]:s.TypeURL.XSD_NON_POSITIVE_INTEGER,[s.TypeURL.XSD_LONG]:s.TypeURL.XSD_INTEGER,[s.TypeURL.XSD_INT]:s.TypeURL.XSD_LONG,[s.TypeURL.XSD_SHORT]:s.TypeURL.XSD_INT,[s.TypeURL.XSD_BYTE]:s.TypeURL.XSD_SHORT,[s.TypeURL.XSD_NON_NEGATIVE_INTEGER]:s.TypeURL.XSD_INTEGER,[s.TypeURL.XSD_POSITIVE_INTEGER]:s.TypeURL.XSD_NON_NEGATIVE_INTEGER,[s.TypeURL.XSD_UNSIGNED_LONG]:s.TypeURL.XSD_NON_NEGATIVE_INTEGER,[s.TypeURL.XSD_UNSIGNED_INT]:s.TypeURL.XSD_UNSIGNED_LONG,[s.TypeURL.XSD_UNSIGNED_SHORT]:s.TypeURL.XSD_UNSIGNED_INT,[s.TypeURL.XSD_UNSIGNED_BYTE]:s.TypeURL.XSD_UNSIGNED_SHORT,[s.TypeURL.XSD_DATE_TIME]:"term",[s.TypeURL.XSD_BOOLEAN]:"term",[s.TypeURL.XSD_DATE]:"term",[s.TypeURL.XSD_G_MONTH]:"term",[s.TypeURL.XSD_G_MONTHDAY]:"term",[s.TypeURL.XSD_G_YEAR]:"term",[s.TypeURL.XSD_G_YEAR_MONTH]:"term",[s.TypeURL.XSD_TIME]:"term",[s.TypeURL.XSD_G_DAY]:"term",[s.TypeURL.XSD_DURATION]:"term",[s.TypeAlias.SPARQL_NUMERIC]:"term",[s.TypeAlias.SPARQL_STRINGLY]:"term",[s.TypeURL.XSD_ANY_URI]:"term"},t.superTypeDictTable=Object.create(null);function n(b,g){const m=g.cache.get(b);if(m)return m;const v=g.discoverer(b);if(v==="term"){const S=Object.create(null);return S.__depth=0,S[b]=0,g.cache.set(b,S),S}let _;const w=c(v);return w?_={...t.superTypeDictTable[w]}:_={...n(v,g)},_.__depth++,_[b]=_.__depth,g.cache.set(b,_),_}t.getSuperTypes=n;function r(){for(const[b,g]of Object.entries(t.extensionTableInput)){const m=b;t.superTypeDictTable[m]||a(m,g,t.superTypeDictTable)}}t.extensionTableInit=r,r();function a(b,g,m){if(g==="term"||g===void 0){const v=Object.create(null);v.__depth=0,v[b]=0,m[b]=v;return}m[g]||a(g,t.extensionTableInput[g],m),m[b]={...m[g],[b]:m[g].__depth+1,__depth:m[g].__depth+1}}t.typeAliasCheck=Object.create(null);function o(){for(const b of Object.values(s.TypeAlias))t.typeAliasCheck[b]=!0}o();function l(b){if(b in t.typeAliasCheck)return b}t.asTypeAlias=l;function c(b){if(b in t.superTypeDictTable)return b}t.asKnownLiteralType=c;function d(b){if(c(b)??b==="term")return b}t.asOverrideType=d;function h(b){if(b==="term"||(0,e.asTermType)(b))return b}t.asGeneralType=h;function f(b,g){return b!=="term"&&t.superTypeDictTable[b]&&t.superTypeDictTable[b][g]!==void 0}t.isInternalSubType=f;function p(b,g){const m=c(b);return m?t.superTypeDictTable[m]:n(b,g)}t.getSuperTypeDict=p;function y(b,g,m){return b==="term"?!1:p(b,m)[g]!==void 0}t.isSubTypeOf=y,t.typePromotion={[s.TypeURL.XSD_STRING]:[{typeToPromote:s.TypeURL.XSD_ANY_URI,conversionFunction:b=>(0,u.string)(b.str())}],[s.TypeURL.XSD_DOUBLE]:[{typeToPromote:s.TypeURL.XSD_FLOAT,conversionFunction:b=>(0,u.double)(b.typedValue)},{typeToPromote:s.TypeURL.XSD_DECIMAL,conversionFunction:b=>(0,u.double)(b.typedValue)}],[s.TypeURL.XSD_FLOAT]:[{typeToPromote:s.TypeURL.XSD_DECIMAL,conversionFunction:b=>(0,u.float)(b.typedValue)}]}}(dS)),dS}var wj;function no(){if(wj)return Yh;wj=1,Object.defineProperty(Yh,"__esModule",{value:!0}),Yh.TermTransformer=void 0;const t=Xt(),e=Ot(),u=Kn(),s=Nn(),n=on(),r=on(),a=P3(),o=P3(),l=am();let c=class{constructor(h){this.superTypeProvider=h}transformRDFTermUnsafe(h){return this.transformTerm({term:h,type:e.Algebra.types.EXPRESSION,expressionType:e.Algebra.expressionTypes.TERM})}transformTerm(h){if(!h.term)throw new n.InvalidExpression(h);switch(h.term.termType){case"Variable":return new u.Variable(t.termToString(h.term));case"Literal":return this.transformLiteral(h.term);case"NamedNode":return new u.NamedNode(h.term.value);case"BlankNode":return new u.BlankNode(h.term.value);case"Quad":return new u.Quad(h.term,this.superTypeProvider);default:throw new n.InvalidTermType(h)}}transformLiteral(h){if(!h.datatype||[null,void 0,""].includes(h.datatype.value))return h.language?new u.LangStringLiteral(h.value,h.language):new u.StringLiteral(h.value);const f=h.datatype.value,p=(0,l.getSuperTypeDict)(f,this.superTypeProvider);try{if(s.TypeURL.XSD_STRING in p)return new u.StringLiteral(h.value,f);if(s.TypeURL.RDF_LANG_STRING in p)return new u.LangStringLiteral(h.value,h.language);if(s.TypeURL.XSD_YEAR_MONTH_DURATION in p)return new u.YearMonthDurationLiteral((0,a.parseYearMonthDuration)(h.value),h.value,f);if(s.TypeURL.XSD_DAY_TIME_DURATION in p)return new u.DayTimeDurationLiteral((0,a.parseDayTimeDuration)(h.value),h.value,f);if(s.TypeURL.XSD_DURATION in p)return new u.DurationLiteral((0,a.parseDuration)(h.value),h.value,f);if(s.TypeURL.XSD_DATE_TIME in p){const g=new Date(h.value);return Number.isNaN(g.getTime())?new u.NonLexicalLiteral(void 0,f,this.superTypeProvider,h.value):new u.DateTimeLiteral((0,a.parseDateTime)(h.value),h.value,f)}if(s.TypeURL.XSD_DATE in p)return new u.DateLiteral((0,a.parseDate)(h.value),h.value,f);if(s.TypeURL.XSD_TIME in p)return new u.TimeLiteral((0,a.parseTime)(h.value),h.value,f);if(s.TypeURL.XSD_BOOLEAN in p)return h.value!=="true"&&h.value!=="false"&&h.value!=="1"&&h.value!=="0"?new u.NonLexicalLiteral(void 0,f,this.superTypeProvider,h.value):new u.BooleanLiteral(h.value==="true"||h.value==="1",h.value);if(s.TypeURL.XSD_DECIMAL in p){const g=o.parseXSDDecimal(h.value);return g===void 0?new u.NonLexicalLiteral(void 0,f,this.superTypeProvider,h.value):s.TypeURL.XSD_INTEGER in p?new u.IntegerLiteral(g,f,h.value):new u.DecimalLiteral(g,f,h.value)}const y=s.TypeURL.XSD_FLOAT in p,b=s.TypeURL.XSD_DOUBLE in p;if(y||b){const g=o.parseXSDFloat(h.value);return g===void 0?new u.NonLexicalLiteral(void 0,f,this.superTypeProvider,h.value):y?new u.FloatLiteral(g,f,h.value):new u.DoubleLiteral(g,f,h.value)}return new u.Literal(h.value,f,h.value)}catch(y){if(y instanceof Error&&(0,r.isExpressionError)(y))return new u.NonLexicalLiteral(void 0,f,this.superTypeProvider,h.value);throw y}}};return Yh.TermTransformer=c,Yh}var bi={},Sj;function Oee(){if(Sj)return bi;Sj=1,Object.defineProperty(bi,"__esModule",{value:!0}),bi.serializeDuration=bi.serializeTime=bi.serializeDate=bi.serializeDateTime=void 0;function t(a,o=2){return a.toLocaleString(void 0,{minimumIntegerDigits:o,useGrouping:!1})}function e(a){return`${s({year:a.year,month:a.month,day:a.day})}T${n(a)}`}bi.serializeDateTime=e;function u(a){return a.zoneHours===void 0||a.zoneMinutes===void 0?"":a.zoneHours===0&&a.zoneMinutes===0?"Z":`${a.zoneHours>=0?`+${t(a.zoneHours)}`:t(a.zoneHours)}:${t(Math.abs(a.zoneMinutes))}`}function s(a){return`${t(a.year,4)}-${t(a.month)}-${t(a.day)}${u(a)}`}bi.serializeDate=s;function n(a){return`${t(a.hours)}:${t(a.minutes)}:${t(a.seconds)}${u(a)}`}bi.serializeTime=n;function r(a,o="PT0S"){if(!Object.values(a).some(g=>(g||0)!==0))return o;const l=Object.values(a).some(g=>(g||0)<0)?"-":"",c=a.year?`${Math.abs(a.year)}Y`:"",d=a.month?`${Math.abs(a.month)}M`:"",h=a.day?`${Math.abs(a.day)}D`:"",f=`${l}P${c}${d}${h}`;if(!(a.hours||a.minutes||a.seconds))return f;const p=a.hours?`${Math.abs(a.hours)}H`:"",y=a.minutes?`${Math.abs(a.minutes)}M`:"",b=a.seconds?`${Math.abs(a.seconds)}S`:"";return`${f}T${p}${y}${b}`}return bi.serializeDuration=r,bi}var Tj;function Ree(){if(Tj)return At;Tj=1,Object.defineProperty(At,"__esModule",{value:!0}),At.isNonLexicalLiteral=At.NonLexicalLiteral=At.YearMonthDurationLiteral=At.DayTimeDurationLiteral=At.DurationLiteral=At.DateLiteral=At.TimeLiteral=At.DateTimeLiteral=At.StringLiteral=At.LangStringLiteral=At.BooleanLiteral=At.DoubleLiteral=At.FloatLiteral=At.DecimalLiteral=At.IntegerLiteral=At.NumericLiteral=At.Literal=At.isLiteralTermExpression=At.Quad=At.BlankNode=At.NamedNode=At.Term=void 0;const t=Et(),e=no(),u=Nn(),s=Nn(),n=on(),r=Oee(),a=am(),o=Ki(),l=new t.DataFactory;let c=class{constructor(){this.expressionType=o.ExpressionType.Term}str(){throw new n.InvalidArgumentTypes([this],u.RegularOperator.STR)}coerceEBV(){throw new n.EBVCoercionError(this)}};At.Term=c;class d extends c{constructor($){super(),this.value=$,this.termType="namedNode"}toRDF(){return l.namedNode(this.value)}str(){return this.value}}At.NamedNode=d;class h extends c{constructor($){super(),this.termType="blankNode",this.value=typeof $=="string"?l.blankNode($):$}toRDF(){return this.value}}At.BlankNode=h;class f extends c{constructor($,Z){super(),this.termType="quad",this.transformer=new e.TermTransformer(Z),this.valueTerm=$}toRDF(){return this.valueTerm}get subject(){return this.transformer.transformRDFTermUnsafe(this.RDFsubject)}get predicate(){return this.transformer.transformRDFTermUnsafe(this.RDFpredicate)}get object(){return this.transformer.transformRDFTermUnsafe(this.RDFobject)}get RDFsubject(){return this.toRDF().subject}get RDFpredicate(){return this.toRDF().predicate}get RDFobject(){return this.toRDF().object}}At.Quad=f;function p(q){if(q.termType==="literal")return q}At.isLiteralTermExpression=p;class y extends c{constructor($,Z,X,le){super(),this.typedValue=$,this.dataType=Z,this.strValue=X,this.language=le,this.termType="literal"}toRDF(){return l.literal(this.strValue??this.str(),this.language??l.namedNode(this.dataType))}str(){return this.strValue??this.typedValue.toString()}}At.Literal=y;class b extends y{constructor($,Z,X,le){super($,Z,X,le),this.typedValue=$,this.strValue=X,this.language=le}coerceEBV(){return!!this.typedValue}toRDF(){const $=super.toRDF();return Number.isFinite(this.typedValue)||($.value=$.value.replace("Infinity","INF")),$}str(){return this.strValue??this.specificFormatter(this.typedValue)}}At.NumericLiteral=b;class g extends b{constructor($,Z,X,le){super($,Z??s.TypeURL.XSD_INTEGER,X,le),this.typedValue=$,this.strValue=X,this.language=le}specificFormatter($){return $.toFixed(0)}}At.IntegerLiteral=g;class m extends b{constructor($,Z,X,le){super($,Z??s.TypeURL.XSD_DECIMAL,X,le),this.typedValue=$,this.strValue=X,this.language=le}specificFormatter($){return $.toString()}}At.DecimalLiteral=m;class v extends b{constructor($,Z,X,le){super($,Z??s.TypeURL.XSD_FLOAT,X,le),this.typedValue=$,this.strValue=X,this.language=le}specificFormatter($){return $.toString()}}At.FloatLiteral=v;class _ extends b{constructor($,Z,X,le){super($,Z??s.TypeURL.XSD_DOUBLE,X,le),this.typedValue=$,this.strValue=X,this.language=le}specificFormatter($){if(!Number.isFinite($))return $>0?"INF":$<0?"-INF":"NaN";const Z=$.toExponential(),[X,le]=Z.split("e"),K=le.replace(/\+/u,"");return`${X.includes(".")?X:`${X}.0`}E${K}`}}At.DoubleLiteral=_;class w extends y{constructor($,Z,X){super($,X??s.TypeURL.XSD_BOOLEAN,Z),this.typedValue=$,this.strValue=Z}coerceEBV(){return this.typedValue}}At.BooleanLiteral=w;class S extends y{constructor($,Z,X){super($,X??s.TypeURL.RDF_LANG_STRING,$,Z),this.typedValue=$,this.language=Z}coerceEBV(){return this.str().length>0}}At.LangStringLiteral=S;class A extends y{constructor($,Z){super($,Z??s.TypeURL.XSD_STRING,$),this.typedValue=$}coerceEBV(){return this.str().length>0}}At.StringLiteral=A;class D extends y{constructor($,Z,X){super($,X??s.TypeURL.XSD_DATE_TIME,Z),this.typedValue=$,this.strValue=Z}str(){return(0,r.serializeDateTime)(this.typedValue)}}At.DateTimeLiteral=D;class L extends y{constructor($,Z,X){super($,X??s.TypeURL.XSD_TIME,Z),this.typedValue=$,this.strValue=Z}str(){return(0,r.serializeTime)(this.typedValue)}}At.TimeLiteral=L;class O extends y{constructor($,Z,X){super($,X??s.TypeURL.XSD_DATE,Z),this.typedValue=$,this.strValue=Z}str(){return(0,r.serializeDate)(this.typedValue)}}At.DateLiteral=O;class E extends y{constructor($,Z,X){super($,X??s.TypeURL.XSD_DURATION,Z),this.typedValue=$,this.strValue=Z}str(){return(0,r.serializeDuration)(this.typedValue)}}At.DurationLiteral=E;class P extends E{constructor($,Z,X){super($,Z,X??s.TypeURL.XSD_DAY_TIME_DURATION),this.typedValue=$,this.strValue=Z}}At.DayTimeDurationLiteral=P;class M extends y{constructor($,Z,X){super($,X??s.TypeURL.XSD_YEAR_MONTH_DURATION,Z),this.typedValue=$,this.strValue=Z}str(){return(0,r.serializeDuration)(this.typedValue,"P0M")}}At.YearMonthDurationLiteral=M;class U extends y{constructor($,Z,X,le,K){super({toString:()=>"undefined"},Z,le,K),this.openWorldType=X}coerceEBV(){if((0,a.isSubTypeOf)(this.dataType,s.TypeURL.XSD_BOOLEAN,this.openWorldType)||(0,a.isSubTypeOf)(this.dataType,s.TypeAlias.SPARQL_NUMERIC,this.openWorldType))return!1;throw new n.EBVCoercionError(this)}toRDF(){return l.literal(this.str(),this.language??l.namedNode(this.dataType))}str(){return this.strValue??""}}At.NonLexicalLiteral=U;function j(q){if(q instanceof U)return q}return At.isNonLexicalLiteral=j,At}var ep={},Aj;function xee(){if(Aj)return ep;Aj=1,Object.defineProperty(ep,"__esModule",{value:!0}),ep.Operator=void 0;const t=Ki();let e=class{constructor(s,n){this.args=s,this.apply=n,this.expressionType=t.ExpressionType.Operator}};return ep.Operator=e,ep}var tp={},Ej;function Iee(){if(Ej)return tp;Ej=1,Object.defineProperty(tp,"__esModule",{value:!0}),tp.SpecialOperator=void 0;const t=Ki();let e=class{constructor(s,n,r){this.args=s,this.applyAsync=n,this.applySynchronously=r,this.expressionType=t.ExpressionType.SpecialOperator}};return tp.SpecialOperator=e,tp}var rp={},Oj;function Pee(){if(Oj)return rp;Oj=1,Object.defineProperty(rp,"__esModule",{value:!0}),rp.Named=void 0;const t=Ki();let e=class{constructor(s,n,r){this.name=s,this.args=n,this.apply=r,this.expressionType=t.ExpressionType.Named}};return rp.Named=e,rp}var np={},Rj;function Dee(){if(Rj)return np;Rj=1,Object.defineProperty(np,"__esModule",{value:!0}),np.Aggregate=void 0;const t=Ki();let e=class{constructor(s,n){this.name=s,this.expression=n,this.expressionType=t.ExpressionType.Aggregate}};return np.Aggregate=e,np}var ip={},xj;function Nee(){if(xj)return ip;xj=1,Object.defineProperty(ip,"__esModule",{value:!0}),ip.Existence=void 0;const t=Ki();let e=class{constructor(s){this.expression=s,this.expressionType=t.ExpressionType.Existence}};return ip.Existence=e,ip}var ap={},Ij;function Cee(){if(Ij)return ap;Ij=1,Object.defineProperty(ap,"__esModule",{value:!0}),ap.AsyncExtension=void 0;const t=Ki();let e=class{constructor(s,n,r){this.name=s,this.args=n,this.apply=r,this.expressionType=t.ExpressionType.AsyncExtension}};return ap.AsyncExtension=e,ap}var sp={},Pj;function jee(){if(Pj)return sp;Pj=1,Object.defineProperty(sp,"__esModule",{value:!0}),sp.SyncExtension=void 0;const t=Ki();let e=class{constructor(s,n,r){this.name=s,this.args=n,this.apply=r,this.expressionType=t.ExpressionType.SyncExtension}};return sp.SyncExtension=e,sp}var Dj;function Kn(){return Dj||(Dj=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Ki(),t),u(Eee(),t),u(Ree(),t),u(xee(),t),u(Iee(),t),u(Pee(),t),u(Dee(),t),u(Nee(),t),u(Cee(),t),u(jee(),t)}(cS)),cS}var fS={},mi={},Nj;function N3(){if(Nj)return mi;Nj=1,Object.defineProperty(mi,"__esModule",{value:!0}),mi.SpecialFunction=mi.NamedFunction=mi.RegularFunction=mi.BaseFunction=void 0;const t=on();class e{constructor(o,l){this.operator=o,this.apply=(c,d)=>(this.monomorph(c,d.superTypeProvider,d.functionArgumentsCache)??this.handleInvalidTypes(c))(d)(c),this.arity=l.arity,this.overloads=l.overloads}monomorph(o,l,c){return this.overloads.search(o,l,c)}}mi.BaseFunction=e;class u extends e{constructor(o,l){super(o,l),this.functionClass="regular"}handleInvalidTypes(o){throw new t.InvalidArgumentTypes(o,this.operator)}}mi.RegularFunction=u;class s extends e{constructor(o,l){super(o,l),this.functionClass="named"}handleInvalidTypes(o){throw new t.InvalidArgumentTypes(o,this.operator)}}mi.NamedFunction=s;class n{constructor(o,l){this.operator=o,this.functionClass="special",this.arity=l.arity,this.applySynchronously=l.applySynchronously,this.applyAsync=l.applyAsync,this.checkArity=l.checkArity??r(this.arity)}}mi.SpecialFunction=n;function r(a){return o=>a===Number.POSITIVE_INFINITY?!0:o.length===a}return mi}var op={},Cj;function Lee(){if(Cj)return op;Cj=1,Object.defineProperty(op,"__esModule",{value:!0}),op.namedDefinitions=void 0;const t=Kn(),e=Kn(),u=Nn(),s=uu(),n=on(),r=P3(),a=Yi(),o={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_STRING).onNumeric1(()=>_=>(0,a.string)((0,a.float)(_.typedValue).str())).onBoolean1Typed(()=>_=>(0,a.string)((0,a.bool)(_).str())).onTerm1(()=>_=>(0,a.string)(_.str())).collect()},l={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_FLOAT).onNumeric1(()=>_=>(0,a.float)(_.typedValue)).onBoolean1Typed(()=>_=>(0,a.float)(_?1:0)).onUnary(u.TypeURL.XSD_STRING,()=>_=>{const w=(0,r.parseXSDFloat)(_.str());if(w===void 0)throw new n.CastError(_,u.TypeURL.XSD_FLOAT);return(0,a.float)(w)},!1).collect()},c={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_DOUBLE).onNumeric1(()=>_=>(0,a.double)(_.typedValue)).onBoolean1Typed(()=>_=>(0,a.double)(_?1:0)).onUnary(u.TypeURL.XSD_STRING,()=>_=>{const w=(0,r.parseXSDFloat)(_.str());if(w===void 0)throw new n.CastError(_,u.TypeURL.XSD_DOUBLE);return(0,a.double)(w)},!1).collect()},d={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_DECIMAL).onNumeric1(()=>_=>{const w=(0,r.parseXSDDecimal)(_.str());if(w===void 0)throw new n.CastError(_,u.TypeURL.XSD_DECIMAL);return(0,a.decimal)(w)}).onString1(()=>_=>{const w=_.str(),S=/^([+-])?(\d+(\.\d+)?)$/u.test(w)?(0,r.parseXSDDecimal)(w):void 0;if(S===void 0)throw new n.CastError(_,u.TypeURL.XSD_DECIMAL);return(0,a.decimal)(S)},!1).onBoolean1Typed(()=>_=>(0,a.decimal)(_?1:0)).collect()},h={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_INTEGER).onBoolean1Typed(()=>_=>(0,a.integer)(_?1:0)).onNumeric1(()=>_=>{const w=(0,r.parseXSDInteger)(_.str());if(w===void 0)throw new n.CastError(_,u.TypeURL.XSD_INTEGER);return(0,a.integer)(w)},!1).onString1(()=>_=>{const w=_.str(),S=/^\d+$/u.test(w)?(0,r.parseXSDInteger)(w):void 0;if(S===void 0)throw new n.CastError(_,u.TypeURL.XSD_INTEGER);return(0,a.integer)(S)}).collect()},f={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_DATE_TIME).onUnary(u.TypeURL.XSD_DATE_TIME,()=>_=>_).onUnary(u.TypeURL.XSD_STRING,()=>_=>(0,a.dateTime)((0,r.parseDateTime)(_.str()),_.str()),!1).onUnary(u.TypeURL.XSD_DATE,()=>_=>new t.DateTimeLiteral({..._.typedValue,hours:0,minutes:0,seconds:0})).collect()},p={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_BOOLEAN).onNumeric1(()=>_=>(0,a.bool)(_.coerceEBV()),!0).onUnary(u.TypeURL.XSD_BOOLEAN,()=>_=>(0,a.bool)(_.coerceEBV()),!0).onUnary(u.TypeURL.XSD_STRING,()=>_=>{switch(_.str()){case"true":return(0,a.bool)(!0);case"false":return(0,a.bool)(!1);case"1":return(0,a.bool)(!0);case"0":return(0,a.bool)(!1);default:throw new n.CastError(_,u.TypeURL.XSD_BOOLEAN)}},!1).collect()},y={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_TIME).onUnary(u.TypeURL.XSD_TIME,()=>_=>new t.TimeLiteral(_.typedValue,_.strValue)).onUnary(u.TypeURL.XSD_DATE_TIME,()=>_=>new t.TimeLiteral(_.typedValue)).onStringly1(()=>_=>new t.TimeLiteral((0,r.parseTime)(_.str()))).collect()},b={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_DATE).onUnary(u.TypeURL.XSD_DATE,()=>_=>new t.DateLiteral(_.typedValue,_.strValue)).onUnary(u.TypeURL.XSD_DATE_TIME,()=>_=>new t.DateLiteral(_.typedValue)).onStringly1(()=>_=>new t.DateLiteral((0,r.parseDate)(_.str()))).collect()},g={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_DURATION).onUnary(u.TypeURL.XSD_DURATION,()=>_=>new t.DurationLiteral(_.typedValue,_.strValue)).onStringly1(()=>_=>new e.DurationLiteral((0,r.parseDuration)(_.str()))).collect()},m={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_DAY_TIME_DURATION).onUnary(u.TypeURL.XSD_DURATION,()=>_=>new t.DayTimeDurationLiteral((0,s.trimToDayTimeDuration)(_.typedValue))).onStringly1(()=>_=>new t.DayTimeDurationLiteral((0,r.parseDayTimeDuration)(_.str()))).collect()},v={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_YEAR_MONTH_DURATION).onUnary(u.TypeURL.XSD_DURATION,()=>_=>new t.YearMonthDurationLiteral((0,s.trimToYearMonthDuration)(_.typedValue))).onStringly1(()=>_=>new t.YearMonthDurationLiteral((0,r.parseYearMonthDuration)(_.str()))).collect()};return op.namedDefinitions={[u.TypeURL.XSD_STRING]:o,[u.TypeURL.XSD_FLOAT]:l,[u.TypeURL.XSD_DOUBLE]:c,[u.TypeURL.XSD_DECIMAL]:d,[u.TypeURL.XSD_INTEGER]:h,[u.TypeURL.XSD_DATE_TIME]:f,[u.TypeURL.XSD_DATE]:b,[u.TypeURL.XSD_BOOLEAN]:p,[u.TypeURL.XSD_TIME]:y,[u.TypeURL.XSD_DURATION]:g,[u.TypeURL.XSD_DAY_TIME_DURATION]:m,[u.TypeURL.XSD_YEAR_MONTH_DURATION]:v},op}var up={},hS={exports:{}},jj;function Mee(){return jj||(jj=1,function(t){(function(e){var u,s=/^-?(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?$/i,n=Math.ceil,r=Math.floor,a="[BigNumber Error] ",o=a+"Number primitive has more than 15 significant digits: ",l=1e14,c=14,d=9007199254740991,h=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],f=1e7,p=1e9;function y(A){var D,L,O,E=ae.prototype={constructor:ae,toString:null,valueOf:null},P=new ae(1),M=20,U=4,j=-7,q=21,$=-1e7,Z=1e7,X=!1,le=1,K=0,he={prefix:"",groupSize:3,secondaryGroupSize:0,groupSeparator:",",decimalSeparator:".",fractionGroupSize:0,fractionGroupSeparator:" ",suffix:""},Re="0123456789abcdefghijklmnopqrstuvwxyz",ie=!0;function ae(H,N){var R,T,x,B,k,V,J,z,Y=this;if(!(Y instanceof ae))return new ae(H,N);if(N==null){if(H&&H._isBigNumber===!0){Y.s=H.s,!H.c||H.e>Z?Y.c=Y.e=null:H.e<$?Y.c=[Y.e=0]:(Y.e=H.e,Y.c=H.c.slice());return}if((V=typeof H=="number")&&H*0==0){if(Y.s=1/H<0?(H=-H,-1):1,H===~~H){for(B=0,k=H;k>=10;k/=10,B++);B>Z?Y.c=Y.e=null:(Y.e=B,Y.c=[H]);return}z=String(H)}else{if(!s.test(z=String(H)))return O(Y,z,V);Y.s=z.charCodeAt(0)==45?(z=z.slice(1),-1):1}(B=z.indexOf("."))>-1&&(z=z.replace(".","")),(k=z.search(/e/i))>0?(B<0&&(B=k),B+=+z.slice(k+1),z=z.substring(0,k)):B<0&&(B=z.length)}else{if(v(N,2,Re.length,"Base"),N==10&&ie)return Y=new ae(H),de(Y,M+Y.e+1,U);if(z=String(H),V=typeof H=="number"){if(H*0!=0)return O(Y,z,V,N);if(Y.s=1/H<0?(z=z.slice(1),-1):1,ae.DEBUG&&z.replace(/^0\.0*|\./,"").length>15)throw Error(o+H)}else Y.s=z.charCodeAt(0)===45?(z=z.slice(1),-1):1;for(R=Re.slice(0,N),B=k=0,J=z.length;kB){B=J;continue}}else if(!x&&(z==z.toUpperCase()&&(z=z.toLowerCase())||z==z.toLowerCase()&&(z=z.toUpperCase()))){x=!0,k=-1,B=0;continue}return O(Y,String(H),V,N)}V=!1,z=L(z,N,10,Y.s),(B=z.indexOf("."))>-1?z=z.replace(".",""):B=z.length}for(k=0;z.charCodeAt(k)===48;k++);for(J=z.length;z.charCodeAt(--J)===48;);if(z=z.slice(k,++J)){if(J-=k,V&&ae.DEBUG&&J>15&&(H>d||H!==r(H)))throw Error(o+Y.s*H);if((B=B-k-1)>Z)Y.c=Y.e=null;else if(B<$)Y.c=[Y.e=0];else{if(Y.e=B,Y.c=[],k=(B+1)%c,B<0&&(k+=c),k=-p&&x<=p&&x===r(x)){if(T[0]===0){if(x===0&&T.length===1)return!0;break e}if(N=(x+1)%c,N<1&&(N+=c),String(T[0]).length==N){for(N=0;N=l||R!==r(R))break e;if(R!==0)return!0}}}else if(T===null&&x===null&&(B===null||B===1||B===-1))return!0;throw Error(a+"Invalid BigNumber: "+H)},ae.maximum=ae.max=function(){return De(arguments,-1)},ae.minimum=ae.min=function(){return De(arguments,1)},ae.random=function(){var H=9007199254740992,N=Math.random()*H&2097151?function(){return r(Math.random()*H)}:function(){return(Math.random()*1073741824|0)*8388608+(Math.random()*8388608|0)};return function(R){var T,x,B,k,V,J=0,z=[],Y=new ae(P);if(R==null?R=M:v(R,0,p),k=n(R/c),X)if(crypto.getRandomValues){for(T=crypto.getRandomValues(new Uint32Array(k*=2));J>>11),V>=9e15?(x=crypto.getRandomValues(new Uint32Array(2)),T[J]=x[0],T[J+1]=x[1]):(z.push(V%1e14),J+=2);J=k/2}else if(crypto.randomBytes){for(T=crypto.randomBytes(k*=7);J=9e15?crypto.randomBytes(7).copy(T,J):(z.push(V%1e14),J+=7);J=k/7}else throw X=!1,Error(a+"crypto unavailable");if(!X)for(;J=10;V/=10,J++);Jx-1&&(V[k+1]==null&&(V[k+1]=0),V[k+1]+=V[k]/x|0,V[k]%=x)}return V.reverse()}return function(R,T,x,B,k){var V,J,z,Y,re,ce,Te,xe,Le=R.indexOf("."),qe=M,G=U;for(Le>=0&&(Y=K,K=0,R=R.replace(".",""),xe=new ae(T),ce=xe.pow(R.length-Le),K=Y,xe.c=N(S(g(ce.c),ce.e,"0"),10,x,H),xe.e=xe.c.length),Te=N(R,T,x,k?(V=Re,H):(V=H,Re)),z=Y=Te.length;Te[--Y]==0;Te.pop());if(!Te[0])return V.charAt(0);if(Le<0?--z:(ce.c=Te,ce.e=z,ce.s=B,ce=D(ce,xe,qe,G,x),Te=ce.c,re=ce.r,z=ce.e),J=z+qe+1,Le=Te[J],Y=x/2,re=re||J<0||Te[J+1]!=null,re=G<4?(Le!=null||re)&&(G==0||G==(ce.s<0?3:2)):Le>Y||Le==Y&&(G==4||re||G==6&&Te[J-1]&1||G==(ce.s<0?8:7)),J<1||!Te[0])R=re?S(V.charAt(1),-qe,V.charAt(0)):V.charAt(0);else{if(Te.length=J,re)for(--x;++Te[--J]>x;)Te[J]=0,J||(++z,Te=[1].concat(Te));for(Y=Te.length;!Te[--Y];);for(Le=0,R="";Le<=Y;R+=V.charAt(Te[Le++]));R=S(R,z,V.charAt(0))}return R}}(),D=function(){function H(T,x,B){var k,V,J,z,Y=0,re=T.length,ce=x%f,Te=x/f|0;for(T=T.slice();re--;)J=T[re]%f,z=T[re]/f|0,k=Te*J+z*ce,V=ce*J+k%f*f+Y,Y=(V/B|0)+(k/f|0)+Te*z,T[re]=V%B;return Y&&(T=[Y].concat(T)),T}function N(T,x,B,k){var V,J;if(B!=k)J=B>k?1:-1;else for(V=J=0;Vx[V]?1:-1;break}return J}function R(T,x,B,k){for(var V=0;B--;)T[B]-=V,V=T[B]1;T.splice(0,1));}return function(T,x,B,k,V){var J,z,Y,re,ce,Te,xe,Le,qe,G,F,Q,te,me,Oe,Ne,We,Ve=T.s==x.s?1:-1,pe=T.c,we=x.c;if(!pe||!pe[0]||!we||!we[0])return new ae(!T.s||!x.s||(pe?we&&pe[0]==we[0]:!we)?NaN:pe&&pe[0]==0||!we?Ve*0:Ve/0);for(Le=new ae(Ve),qe=Le.c=[],z=T.e-x.e,Ve=B+z+1,V||(V=l,z=b(T.e/c)-b(x.e/c),Ve=Ve/c|0),Y=0;we[Y]==(pe[Y]||0);Y++);if(we[Y]>(pe[Y]||0)&&z--,Ve<0)qe.push(1),re=!0;else{for(me=pe.length,Ne=we.length,Y=0,Ve+=2,ce=r(V/(we[0]+1)),ce>1&&(we=H(we,ce,V),pe=H(pe,ce,V),Ne=we.length,me=pe.length),te=Ne,G=pe.slice(0,Ne),F=G.length;F=V/2&&Oe++;do{if(ce=0,J=N(we,G,Ne,F),J<0){if(Q=G[0],Ne!=F&&(Q=Q*V+(G[1]||0)),ce=r(Q/Oe),ce>1)for(ce>=V&&(ce=V-1),Te=H(we,ce,V),xe=Te.length,F=G.length;N(Te,G,xe,F)==1;)ce--,R(Te,Ne=10;Ve/=10,Y++);de(Le,B+(Le.e=Y+z*c-1)+1,k,re)}else Le.e=z,Le.r=+re;return Le}}();function Ee(H,N,R,T){var x,B,k,V,J;if(R==null?R=U:v(R,0,8),!H.c)return H.toString();if(x=H.c[0],k=H.e,N==null)J=g(H.c),J=T==1||T==2&&(k<=j||k>=q)?w(J,k):S(J,k,"0");else if(H=de(new ae(H),N,R),B=H.e,J=g(H.c),V=J.length,T==1||T==2&&(N<=B||B<=j)){for(;VV){if(--N>0)for(J+=".";N--;J+="0");}else if(N+=B-V,N>0)for(B+1==V&&(J+=".");N--;J+="0");return H.s<0&&x?"-"+J:J}function De(H,N){for(var R,T,x=1,B=new ae(H[0]);x=10;x/=10,T++);return(R=T+R*c-1)>Z?H.c=H.e=null:R<$?H.c=[H.e=0]:(H.e=R,H.c=N),H}O=function(){var H=/^(-?)0([xbo])(?=\w[\w.]*$)/i,N=/^([^.]+)\.$/,R=/^\.([^.]+)$/,T=/^-?(Infinity|NaN)$/,x=/^\s*\+(?=[\w.])|^\s+|\s+$/g;return function(B,k,V,J){var z,Y=V?k:k.replace(x,"");if(T.test(Y))B.s=isNaN(Y)?null:Y<0?-1:1;else{if(!V&&(Y=Y.replace(H,function(re,ce,Te){return z=(Te=Te.toLowerCase())=="x"?16:Te=="b"?2:8,!J||J==z?ce:re}),J&&(z=J,Y=Y.replace(N,"$1").replace(R,"0.$1")),k!=Y))return new ae(Y,z);if(ae.DEBUG)throw Error(a+"Not a"+(J?" base "+J:"")+" number: "+k);B.s=null}B.c=B.e=null}}();function de(H,N,R,T){var x,B,k,V,J,z,Y,re=H.c,ce=h;if(re){e:{for(x=1,V=re[0];V>=10;V/=10,x++);if(B=N-x,B<0)B+=c,k=N,J=re[z=0],Y=r(J/ce[x-k-1]%10);else if(z=n((B+1)/c),z>=re.length)if(T){for(;re.length<=z;re.push(0));J=Y=0,x=1,B%=c,k=B-c+1}else break e;else{for(J=V=re[z],x=1;V>=10;V/=10,x++);B%=c,k=B-c+x,Y=k<0?0:r(J/ce[x-k-1]%10)}if(T=T||N<0||re[z+1]!=null||(k<0?J:J%ce[x-k-1]),T=R<4?(Y||T)&&(R==0||R==(H.s<0?3:2)):Y>5||Y==5&&(R==4||T||R==6&&(B>0?k>0?J/ce[x-k]:0:re[z-1])%10&1||R==(H.s<0?8:7)),N<1||!re[0])return re.length=0,T?(N-=H.e+1,re[0]=ce[(c-N%c)%c],H.e=-N||0):re[0]=H.e=0,H;if(B==0?(re.length=z,V=1,z--):(re.length=z+1,V=ce[c-B],re[z]=k>0?r(J/ce[x-k]%ce[k])*V:0),T)for(;;)if(z==0){for(B=1,k=re[0];k>=10;k/=10,B++);for(k=re[0]+=V,V=1;k>=10;k/=10,V++);B!=V&&(H.e++,re[0]==l&&(re[0]=1));break}else{if(re[z]+=V,re[z]!=l)break;re[z--]=0,V=1}for(B=re.length;re[--B]===0;re.pop());}H.e>Z?H.c=H.e=null:H.e<$&&(H.c=[H.e=0])}return H}function fe(H){var N,R=H.e;return R===null?H.toString():(N=g(H.c),N=R<=j||R>=q?w(N,R):S(N,R,"0"),H.s<0?"-"+N:N)}return E.absoluteValue=E.abs=function(){var H=new ae(this);return H.s<0&&(H.s=1),H},E.comparedTo=function(H,N){return m(this,new ae(H,N))},E.decimalPlaces=E.dp=function(H,N){var R,T,x,B=this;if(H!=null)return v(H,0,p),N==null?N=U:v(N,0,8),de(new ae(B),H+B.e+1,N);if(!(R=B.c))return null;if(T=((x=R.length-1)-b(this.e/c))*c,x=R[x])for(;x%10==0;x/=10,T--);return T<0&&(T=0),T},E.dividedBy=E.div=function(H,N){return D(this,new ae(H,N),M,U)},E.dividedToIntegerBy=E.idiv=function(H,N){return D(this,new ae(H,N),0,1)},E.exponentiatedBy=E.pow=function(H,N){var R,T,x,B,k,V,J,z,Y,re=this;if(H=new ae(H),H.c&&!H.isInteger())throw Error(a+"Exponent not an integer: "+fe(H));if(N!=null&&(N=new ae(N)),V=H.e>14,!re.c||!re.c[0]||re.c[0]==1&&!re.e&&re.c.length==1||!H.c||!H.c[0])return Y=new ae(Math.pow(+fe(re),V?H.s*(2-_(H)):+fe(H))),N?Y.mod(N):Y;if(J=H.s<0,N){if(N.c?!N.c[0]:!N.s)return new ae(NaN);T=!J&&re.isInteger()&&N.isInteger(),T&&(re=re.mod(N))}else{if(H.e>9&&(re.e>0||re.e<-1||(re.e==0?re.c[0]>1||V&&re.c[1]>=24e7:re.c[0]<8e13||V&&re.c[0]<=9999975e7)))return B=re.s<0&&_(H)?-0:0,re.e>-1&&(B=1/B),new ae(J?1/B:B);K&&(B=n(K/c+2))}for(V?(R=new ae(.5),J&&(H.s=1),z=_(H)):(x=Math.abs(+fe(H)),z=x%2),Y=new ae(P);;){if(z){if(Y=Y.times(re),!Y.c)break;B?Y.c.length>B&&(Y.c.length=B):T&&(Y=Y.mod(N))}if(x){if(x=r(x/2),x===0)break;z=x%2}else if(H=H.times(R),de(H,H.e+1,1),H.e>14)z=_(H);else{if(x=+fe(H),x===0)break;z=x%2}re=re.times(re),B?re.c&&re.c.length>B&&(re.c.length=B):T&&(re=re.mod(N))}return T?Y:(J&&(Y=P.div(Y)),N?Y.mod(N):B?de(Y,K,U,k):Y)},E.integerValue=function(H){var N=new ae(this);return H==null?H=U:v(H,0,8),de(N,N.e+1,H)},E.isEqualTo=E.eq=function(H,N){return m(this,new ae(H,N))===0},E.isFinite=function(){return!!this.c},E.isGreaterThan=E.gt=function(H,N){return m(this,new ae(H,N))>0},E.isGreaterThanOrEqualTo=E.gte=function(H,N){return(N=m(this,new ae(H,N)))===1||N===0},E.isInteger=function(){return!!this.c&&b(this.e/c)>this.c.length-2},E.isLessThan=E.lt=function(H,N){return m(this,new ae(H,N))<0},E.isLessThanOrEqualTo=E.lte=function(H,N){return(N=m(this,new ae(H,N)))===-1||N===0},E.isNaN=function(){return!this.s},E.isNegative=function(){return this.s<0},E.isPositive=function(){return this.s>0},E.isZero=function(){return!!this.c&&this.c[0]==0},E.minus=function(H,N){var R,T,x,B,k=this,V=k.s;if(H=new ae(H,N),N=H.s,!V||!N)return new ae(NaN);if(V!=N)return H.s=-N,k.plus(H);var J=k.e/c,z=H.e/c,Y=k.c,re=H.c;if(!J||!z){if(!Y||!re)return Y?(H.s=-N,H):new ae(re?k:NaN);if(!Y[0]||!re[0])return re[0]?(H.s=-N,H):new ae(Y[0]?k:U==3?-0:0)}if(J=b(J),z=b(z),Y=Y.slice(),V=J-z){for((B=V<0)?(V=-V,x=Y):(z=J,x=re),x.reverse(),N=V;N--;x.push(0));x.reverse()}else for(T=(B=(V=Y.length)<(N=re.length))?V:N,V=N=0;N0)for(;N--;Y[R++]=0);for(N=l-1;T>V;){if(Y[--T]=0;){for(R=0,ce=Q[x]%qe,Te=Q[x]/qe|0,k=J,B=x+k;B>x;)z=F[--k]%qe,Y=F[k]/qe|0,V=Te*z+Y*ce,z=ce*z+V%qe*qe+xe[B]+R,R=(z/Le|0)+(V/qe|0)+Te*Y,xe[B--]=z%Le;xe[B]=R}return R?++T:xe.splice(0,1),ge(H,xe,T)},E.negated=function(){var H=new ae(this);return H.s=-H.s||null,H},E.plus=function(H,N){var R,T=this,x=T.s;if(H=new ae(H,N),N=H.s,!x||!N)return new ae(NaN);if(x!=N)return H.s=-N,T.minus(H);var B=T.e/c,k=H.e/c,V=T.c,J=H.c;if(!B||!k){if(!V||!J)return new ae(x/0);if(!V[0]||!J[0])return J[0]?H:new ae(V[0]?T:x*0)}if(B=b(B),k=b(k),V=V.slice(),x=B-k){for(x>0?(k=B,R=J):(x=-x,R=V),R.reverse();x--;R.push(0));R.reverse()}for(x=V.length,N=J.length,x-N<0&&(R=J,J=V,V=R,N=x),x=0;N;)x=(V[--N]=V[N]+J[N]+x)/l|0,V[N]=l===V[N]?0:V[N]%l;return x&&(V=[x].concat(V),++k),ge(H,V,k)},E.precision=E.sd=function(H,N){var R,T,x,B=this;if(H!=null&&H!==!!H)return v(H,1,p),N==null?N=U:v(N,0,8),de(new ae(B),H,N);if(!(R=B.c))return null;if(x=R.length-1,T=x*c+1,x=R[x]){for(;x%10==0;x/=10,T--);for(x=R[0];x>=10;x/=10,T++);}return H&&B.e+1>T&&(T=B.e+1),T},E.shiftedBy=function(H){return v(H,-d,d),this.times("1e"+H)},E.squareRoot=E.sqrt=function(){var H,N,R,T,x,B=this,k=B.c,V=B.s,J=B.e,z=M+4,Y=new ae("0.5");if(V!==1||!k||!k[0])return new ae(!V||V<0&&(!k||k[0])?NaN:k?B:1/0);if(V=Math.sqrt(+fe(B)),V==0||V==1/0?(N=g(k),(N.length+J)%2==0&&(N+="0"),V=Math.sqrt(+N),J=b((J+1)/2)-(J<0||J%2),V==1/0?N="5e"+J:(N=V.toExponential(),N=N.slice(0,N.indexOf("e")+1)+J),R=new ae(N)):R=new ae(V+""),R.c[0]){for(J=R.e,V=J+z,V<3&&(V=0);;)if(x=R,R=Y.times(x.plus(D(B,x,z,1))),g(x.c).slice(0,V)===(N=g(R.c)).slice(0,V))if(R.e0&&xe>0){for(B=xe%V||V,Y=Te.substr(0,B);B0&&(Y+=z+Te.slice(B)),ce&&(Y="-"+Y)}T=re?Y+(R.decimalSeparator||"")+((J=+R.fractionGroupSize)?re.replace(new RegExp("\\d{"+J+"}\\B","g"),"$&"+(R.fractionGroupSeparator||"")):re):Y}return(R.prefix||"")+T+(R.suffix||"")},E.toFraction=function(H){var N,R,T,x,B,k,V,J,z,Y,re,ce,Te=this,xe=Te.c;if(H!=null&&(V=new ae(H),!V.isInteger()&&(V.c||V.s!==1)||V.lt(P)))throw Error(a+"Argument "+(V.isInteger()?"out of range: ":"not an integer: ")+fe(V));if(!xe)return new ae(Te);for(N=new ae(P),z=R=new ae(P),T=J=new ae(P),ce=g(xe),B=N.e=ce.length-Te.e-1,N.c[0]=h[(k=B%c)<0?c+k:k],H=!H||V.comparedTo(N)>0?B>0?N:z:V,k=Z,Z=1/0,V=new ae(ce),J.c[0]=0;Y=D(V,N,0,1),x=R.plus(Y.times(T)),x.comparedTo(H)!=1;)R=T,T=x,z=J.plus(Y.times(x=z)),J=x,N=V.minus(Y.times(x=N)),V=x;return x=D(H.minus(R),T,0,1),J=J.plus(x.times(z)),R=R.plus(x.times(T)),J.s=z.s=Te.s,B=B*2,re=D(z,T,B,U).minus(Te).abs().comparedTo(D(J,R,B,U).minus(Te).abs())<1?[z,T]:[J,R],Z=k,re},E.toNumber=function(){return+fe(this)},E.toPrecision=function(H,N){return H!=null&&v(H,1,p),Ee(this,H,N,2)},E.toString=function(H){var N,R=this,T=R.s,x=R.e;return x===null?T?(N="Infinity",T<0&&(N="-"+N)):N="NaN":(H==null?N=x<=j||x>=q?w(g(R.c),x):S(g(R.c),x,"0"):H===10&&ie?(R=de(new ae(R),M+x+1,U),N=S(g(R.c),R.e,"0")):(v(H,2,Re.length,"Base"),N=L(S(g(R.c),x,"0"),10,H,T,!0)),T<0&&R.c[0]&&(N="-"+N)),N},E.valueOf=E.toJSON=function(){return fe(this)},E._isBigNumber=!0,A!=null&&ae.set(A),ae}function b(A){var D=A|0;return A>0||A===D?D:D-1}function g(A){for(var D,L,O=1,E=A.length,P=A[0]+"";Oq^L?1:-1;for(U=(j=E.length)<(q=P.length)?j:q,M=0;MP[M]^L?1:-1;return j==q?0:j>q^L?1:-1}function v(A,D,L,O){if(AL||A!==r(A))throw Error(a+(O||"Argument")+(typeof A=="number"?AL?" out of range: ":" not an integer: ":" not a primitive number: ")+String(A))}function _(A){var D=A.c.length-1;return b(A.e/c)==D&&A.c[D]%2!=0}function w(A,D){return(A.length>1?A.charAt(0)+"."+A.slice(1):A)+(D<0?"e":"e+")+D}function S(A,D,L){var O,E;if(D<0){for(E=L+".";++D;E+=L);A=E+A}else if(O=A.length,++D>O){for(E=L,D-=O;--D;E+=L);A+=E}else D>>25)+w|0,A+=(_&w|~_&S)+v[1]-389564586|0,A=(A<<12|A>>>20)+_|0,S+=(A&_|~A&w)+v[2]+606105819|0,S=(S<<17|S>>>15)+A|0,w+=(S&A|~S&_)+v[3]-1044525330|0,w=(w<<22|w>>>10)+S|0,_+=(w&S|~w&A)+v[4]-176418897|0,_=(_<<7|_>>>25)+w|0,A+=(_&w|~_&S)+v[5]+1200080426|0,A=(A<<12|A>>>20)+_|0,S+=(A&_|~A&w)+v[6]-1473231341|0,S=(S<<17|S>>>15)+A|0,w+=(S&A|~S&_)+v[7]-45705983|0,w=(w<<22|w>>>10)+S|0,_+=(w&S|~w&A)+v[8]+1770035416|0,_=(_<<7|_>>>25)+w|0,A+=(_&w|~_&S)+v[9]-1958414417|0,A=(A<<12|A>>>20)+_|0,S+=(A&_|~A&w)+v[10]-42063|0,S=(S<<17|S>>>15)+A|0,w+=(S&A|~S&_)+v[11]-1990404162|0,w=(w<<22|w>>>10)+S|0,_+=(w&S|~w&A)+v[12]+1804603682|0,_=(_<<7|_>>>25)+w|0,A+=(_&w|~_&S)+v[13]-40341101|0,A=(A<<12|A>>>20)+_|0,S+=(A&_|~A&w)+v[14]-1502002290|0,S=(S<<17|S>>>15)+A|0,w+=(S&A|~S&_)+v[15]+1236535329|0,w=(w<<22|w>>>10)+S|0,_+=(w&A|S&~A)+v[1]-165796510|0,_=(_<<5|_>>>27)+w|0,A+=(_&S|w&~S)+v[6]-1069501632|0,A=(A<<9|A>>>23)+_|0,S+=(A&w|_&~w)+v[11]+643717713|0,S=(S<<14|S>>>18)+A|0,w+=(S&_|A&~_)+v[0]-373897302|0,w=(w<<20|w>>>12)+S|0,_+=(w&A|S&~A)+v[5]-701558691|0,_=(_<<5|_>>>27)+w|0,A+=(_&S|w&~S)+v[10]+38016083|0,A=(A<<9|A>>>23)+_|0,S+=(A&w|_&~w)+v[15]-660478335|0,S=(S<<14|S>>>18)+A|0,w+=(S&_|A&~_)+v[4]-405537848|0,w=(w<<20|w>>>12)+S|0,_+=(w&A|S&~A)+v[9]+568446438|0,_=(_<<5|_>>>27)+w|0,A+=(_&S|w&~S)+v[14]-1019803690|0,A=(A<<9|A>>>23)+_|0,S+=(A&w|_&~w)+v[3]-187363961|0,S=(S<<14|S>>>18)+A|0,w+=(S&_|A&~_)+v[8]+1163531501|0,w=(w<<20|w>>>12)+S|0,_+=(w&A|S&~A)+v[13]-1444681467|0,_=(_<<5|_>>>27)+w|0,A+=(_&S|w&~S)+v[2]-51403784|0,A=(A<<9|A>>>23)+_|0,S+=(A&w|_&~w)+v[7]+1735328473|0,S=(S<<14|S>>>18)+A|0,w+=(S&_|A&~_)+v[12]-1926607734|0,w=(w<<20|w>>>12)+S|0,_+=(w^S^A)+v[5]-378558|0,_=(_<<4|_>>>28)+w|0,A+=(_^w^S)+v[8]-2022574463|0,A=(A<<11|A>>>21)+_|0,S+=(A^_^w)+v[11]+1839030562|0,S=(S<<16|S>>>16)+A|0,w+=(S^A^_)+v[14]-35309556|0,w=(w<<23|w>>>9)+S|0,_+=(w^S^A)+v[1]-1530992060|0,_=(_<<4|_>>>28)+w|0,A+=(_^w^S)+v[4]+1272893353|0,A=(A<<11|A>>>21)+_|0,S+=(A^_^w)+v[7]-155497632|0,S=(S<<16|S>>>16)+A|0,w+=(S^A^_)+v[10]-1094730640|0,w=(w<<23|w>>>9)+S|0,_+=(w^S^A)+v[13]+681279174|0,_=(_<<4|_>>>28)+w|0,A+=(_^w^S)+v[0]-358537222|0,A=(A<<11|A>>>21)+_|0,S+=(A^_^w)+v[3]-722521979|0,S=(S<<16|S>>>16)+A|0,w+=(S^A^_)+v[6]+76029189|0,w=(w<<23|w>>>9)+S|0,_+=(w^S^A)+v[9]-640364487|0,_=(_<<4|_>>>28)+w|0,A+=(_^w^S)+v[12]-421815835|0,A=(A<<11|A>>>21)+_|0,S+=(A^_^w)+v[15]+530742520|0,S=(S<<16|S>>>16)+A|0,w+=(S^A^_)+v[2]-995338651|0,w=(w<<23|w>>>9)+S|0,_+=(S^(w|~A))+v[0]-198630844|0,_=(_<<6|_>>>26)+w|0,A+=(w^(_|~S))+v[7]+1126891415|0,A=(A<<10|A>>>22)+_|0,S+=(_^(A|~w))+v[14]-1416354905|0,S=(S<<15|S>>>17)+A|0,w+=(A^(S|~_))+v[5]-57434055|0,w=(w<<21|w>>>11)+S|0,_+=(S^(w|~A))+v[12]+1700485571|0,_=(_<<6|_>>>26)+w|0,A+=(w^(_|~S))+v[3]-1894986606|0,A=(A<<10|A>>>22)+_|0,S+=(_^(A|~w))+v[10]-1051523|0,S=(S<<15|S>>>17)+A|0,w+=(A^(S|~_))+v[1]-2054922799|0,w=(w<<21|w>>>11)+S|0,_+=(S^(w|~A))+v[8]+1873313359|0,_=(_<<6|_>>>26)+w|0,A+=(w^(_|~S))+v[15]-30611744|0,A=(A<<10|A>>>22)+_|0,S+=(_^(A|~w))+v[6]-1560198380|0,S=(S<<15|S>>>17)+A|0,w+=(A^(S|~_))+v[13]+1309151649|0,w=(w<<21|w>>>11)+S|0,_+=(S^(w|~A))+v[4]-145523070|0,_=(_<<6|_>>>26)+w|0,A+=(w^(_|~S))+v[11]-1120210379|0,A=(A<<10|A>>>22)+_|0,S+=(_^(A|~w))+v[2]+718787259|0,S=(S<<15|S>>>17)+A|0,w+=(A^(S|~_))+v[9]-343485551|0,w=(w<<21|w>>>11)+S|0,m[0]=_+m[0]|0,m[1]=w+m[1]|0,m[2]=S+m[2]|0,m[3]=A+m[3]|0}function r(m){var v=[],_;for(_=0;_<64;_+=4)v[_>>2]=m.charCodeAt(_)+(m.charCodeAt(_+1)<<8)+(m.charCodeAt(_+2)<<16)+(m.charCodeAt(_+3)<<24);return v}function a(m){var v=[],_;for(_=0;_<64;_+=4)v[_>>2]=m[_]+(m[_+1]<<8)+(m[_+2]<<16)+(m[_+3]<<24);return v}function o(m){var v=m.length,_=[1732584193,-271733879,-1732584194,271733878],w,S,A,D,L,O;for(w=64;w<=v;w+=64)n(_,r(m.substring(w-64,w)));for(m=m.substring(w-64),S=m.length,A=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],w=0;w>2]|=m.charCodeAt(w)<<(w%4<<3);if(A[w>>2]|=128<<(w%4<<3),w>55)for(n(_,A),w=0;w<16;w+=1)A[w]=0;return D=v*8,D=D.toString(16).match(/(.*?)(.{0,8})$/),L=parseInt(D[2],16),O=parseInt(D[1],16)||0,A[14]=L,A[15]=O,n(_,A),_}function l(m){var v=m.length,_=[1732584193,-271733879,-1732584194,271733878],w,S,A,D,L,O;for(w=64;w<=v;w+=64)n(_,a(m.subarray(w-64,w)));for(m=w-64>2]|=m[w]<<(w%4<<3);if(A[w>>2]|=128<<(w%4<<3),w>55)for(n(_,A),w=0;w<16;w+=1)A[w]=0;return D=v*8,D=D.toString(16).match(/(.*?)(.{0,8})$/),L=parseInt(D[2],16),O=parseInt(D[1],16)||0,A[14]=L,A[15]=O,n(_,A),_}function c(m){var v="",_;for(_=0;_<4;_+=1)v+=s[m>>_*8+4&15]+s[m>>_*8&15];return v}function d(m){var v;for(v=0;vA?new ArrayBuffer(0):(D=A-S,L=new ArrayBuffer(D),O=new Uint8Array(L),E=new Uint8Array(this,S,D),O.set(E),L)}}();function h(m){return/[\u0080-\uFFFF]/.test(m)&&(m=unescape(encodeURIComponent(m))),m}function f(m,v){var _=m.length,w=new ArrayBuffer(_),S=new Uint8Array(w),A;for(A=0;A<_;A+=1)S[A]=m.charCodeAt(A);return v?S:w}function p(m){return String.fromCharCode.apply(null,new Uint8Array(m))}function y(m,v,_){var w=new Uint8Array(m.byteLength+v.byteLength);return w.set(new Uint8Array(m)),w.set(new Uint8Array(v),m.byteLength),_?w:w.buffer}function b(m){var v=[],_=m.length,w;for(w=0;w<_-1;w+=2)v.push(parseInt(m.substr(w,2),16));return String.fromCharCode.apply(String,v)}function g(){this.reset()}return g.prototype.append=function(m){return this.appendBinary(h(m)),this},g.prototype.appendBinary=function(m){this._buff+=m,this._length+=m.length;var v=this._buff.length,_;for(_=64;_<=v;_+=64)n(this._hash,r(this._buff.substring(_-64,_)));return this._buff=this._buff.substring(_-64),this},g.prototype.end=function(m){var v=this._buff,_=v.length,w,S=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],A;for(w=0;w<_;w+=1)S[w>>2]|=v.charCodeAt(w)<<(w%4<<3);return this._finish(S,_),A=d(this._hash),m&&(A=b(A)),this.reset(),A},g.prototype.reset=function(){return this._buff="",this._length=0,this._hash=[1732584193,-271733879,-1732584194,271733878],this},g.prototype.getState=function(){return{buff:this._buff,length:this._length,hash:this._hash.slice()}},g.prototype.setState=function(m){return this._buff=m.buff,this._length=m.length,this._hash=m.hash,this},g.prototype.destroy=function(){delete this._hash,delete this._buff,delete this._length},g.prototype._finish=function(m,v){var _=v,w,S,A;if(m[_>>2]|=128<<(_%4<<3),_>55)for(n(this._hash,m),_=0;_<16;_+=1)m[_]=0;w=this._length*8,w=w.toString(16).match(/(.*?)(.{0,8})$/),S=parseInt(w[2],16),A=parseInt(w[1],16)||0,m[14]=S,m[15]=A,n(this._hash,m)},g.hash=function(m,v){return g.hashBinary(h(m),v)},g.hashBinary=function(m,v){var _=o(m),w=d(_);return v?b(w):w},g.ArrayBuffer=function(){this.reset()},g.ArrayBuffer.prototype.append=function(m){var v=y(this._buff.buffer,m,!0),_=v.length,w;for(this._length+=m.byteLength,w=64;w<=_;w+=64)n(this._hash,a(v.subarray(w-64,w)));return this._buff=w-64<_?new Uint8Array(v.buffer.slice(w-64)):new Uint8Array(0),this},g.ArrayBuffer.prototype.end=function(m){var v=this._buff,_=v.length,w=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],S,A;for(S=0;S<_;S+=1)w[S>>2]|=v[S]<<(S%4<<3);return this._finish(w,_),A=d(this._hash),m&&(A=b(A)),this.reset(),A},g.ArrayBuffer.prototype.reset=function(){return this._buff=new Uint8Array(0),this._length=0,this._hash=[1732584193,-271733879,-1732584194,271733878],this},g.ArrayBuffer.prototype.getState=function(){var m=g.prototype.getState.call(this);return m.buff=p(m.buff),m},g.ArrayBuffer.prototype.setState=function(m){return m.buff=f(m.buff,!0),g.prototype.setState.call(this,m)},g.ArrayBuffer.prototype.destroy=g.prototype.destroy,g.ArrayBuffer.prototype._finish=g.prototype._finish,g.ArrayBuffer.hash=function(m,v){var _=l(new Uint8Array(m)),w=d(_);return v?b(w):w},g})}(pS)),pS.exports}var yS={},cp={},L1={},Mj;function gB(){if(Mj)return L1;Mj=1,Object.defineProperty(L1,"__esModule",{value:!0}),L1.default=u;let t;const e=new Uint8Array(16);function u(){if(!t&&(t=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!t))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return t(e)}return L1}var vo={},lp={},dp={},Fj;function qee(){if(Fj)return dp;Fj=1,Object.defineProperty(dp,"__esModule",{value:!0}),dp.default=void 0;var t=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;return dp.default=t,dp}var qj;function sm(){if(qj)return lp;qj=1,Object.defineProperty(lp,"__esModule",{value:!0}),lp.default=void 0;var t=e(qee());function e(n){return n&&n.__esModule?n:{default:n}}function u(n){return typeof n=="string"&&t.default.test(n)}var s=u;return lp.default=s,lp}var Bj;function om(){if(Bj)return vo;Bj=1,Object.defineProperty(vo,"__esModule",{value:!0}),vo.default=void 0,vo.unsafeStringify=s;var t=e(sm());function e(a){return a&&a.__esModule?a:{default:a}}const u=[];for(let a=0;a<256;++a)u.push((a+256).toString(16).slice(1));function s(a,o=0){return u[a[o+0]]+u[a[o+1]]+u[a[o+2]]+u[a[o+3]]+"-"+u[a[o+4]]+u[a[o+5]]+"-"+u[a[o+6]]+u[a[o+7]]+"-"+u[a[o+8]]+u[a[o+9]]+"-"+u[a[o+10]]+u[a[o+11]]+u[a[o+12]]+u[a[o+13]]+u[a[o+14]]+u[a[o+15]]}function n(a,o=0){const l=s(a,o);if(!(0,t.default)(l))throw TypeError("Stringified UUID is invalid");return l}var r=n;return vo.default=r,vo}var Uj;function Bee(){if(Uj)return cp;Uj=1,Object.defineProperty(cp,"__esModule",{value:!0}),cp.default=void 0;var t=u(gB()),e=om();function u(c){return c&&c.__esModule?c:{default:c}}let s,n,r=0,a=0;function o(c,d,h){let f=d&&h||0;const p=d||new Array(16);c=c||{};let y=c.node||s,b=c.clockseq!==void 0?c.clockseq:n;if(y==null||b==null){const S=c.random||(c.rng||t.default)();y==null&&(y=s=[S[0]|1,S[1],S[2],S[3],S[4],S[5]]),b==null&&(b=n=(S[6]<<8|S[7])&16383)}let g=c.msecs!==void 0?c.msecs:Date.now(),m=c.nsecs!==void 0?c.nsecs:a+1;const v=g-r+(m-a)/1e4;if(v<0&&c.clockseq===void 0&&(b=b+1&16383),(v<0||g>r)&&c.nsecs===void 0&&(m=0),m>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");r=g,a=m,n=b,g+=122192928e5;const _=((g&268435455)*1e4+m)%4294967296;p[f++]=_>>>24&255,p[f++]=_>>>16&255,p[f++]=_>>>8&255,p[f++]=_&255;const w=g/4294967296*1e4&268435455;p[f++]=w>>>8&255,p[f++]=w&255,p[f++]=w>>>24&15|16,p[f++]=w>>>16&255,p[f++]=b>>>8|128,p[f++]=b&255;for(let S=0;S<6;++S)p[f+S]=y[S];return d||(0,e.unsafeStringify)(p)}var l=o;return cp.default=l,cp}var fp={},Ia={},hp={},Qj;function _B(){if(Qj)return hp;Qj=1,Object.defineProperty(hp,"__esModule",{value:!0}),hp.default=void 0;var t=e(sm());function e(n){return n&&n.__esModule?n:{default:n}}function u(n){if(!(0,t.default)(n))throw TypeError("Invalid UUID");let r;const a=new Uint8Array(16);return a[0]=(r=parseInt(n.slice(0,8),16))>>>24,a[1]=r>>>16&255,a[2]=r>>>8&255,a[3]=r&255,a[4]=(r=parseInt(n.slice(9,13),16))>>>8,a[5]=r&255,a[6]=(r=parseInt(n.slice(14,18),16))>>>8,a[7]=r&255,a[8]=(r=parseInt(n.slice(19,23),16))>>>8,a[9]=r&255,a[10]=(r=parseInt(n.slice(24,36),16))/1099511627776&255,a[11]=r/4294967296&255,a[12]=r>>>24&255,a[13]=r>>>16&255,a[14]=r>>>8&255,a[15]=r&255,a}var s=u;return hp.default=s,hp}var Hj;function vB(){if(Hj)return Ia;Hj=1,Object.defineProperty(Ia,"__esModule",{value:!0}),Ia.URL=Ia.DNS=void 0,Ia.default=a;var t=om(),e=u(_B());function u(o){return o&&o.__esModule?o:{default:o}}function s(o){o=unescape(encodeURIComponent(o));const l=[];for(let c=0;c>5]>>>m%32&255,_=parseInt(g.charAt(v>>>4&15)+g.charAt(v&15),16);y.push(_)}return y}function u(p){return(p+64>>>9<<4)+14+1}function s(p,y){p[y>>5]|=128<>5]|=(p[g/8]&255)<>16)+(y>>16)+(b>>16)<<16|b&65535}function a(p,y){return p<>>32-y}function o(p,y,b,g,m,v){return r(a(r(r(y,p),r(g,v)),m),b)}function l(p,y,b,g,m,v,_){return o(y&b|~y&g,p,y,m,v,_)}function c(p,y,b,g,m,v,_){return o(y&g|b&~g,p,y,m,v,_)}function d(p,y,b,g,m,v,_){return o(y^b^g,p,y,m,v,_)}function h(p,y,b,g,m,v,_){return o(b^(y|~g),p,y,m,v,_)}var f=t;return pp.default=f,pp}var Vj;function Qee(){if(Vj)return fp;Vj=1,Object.defineProperty(fp,"__esModule",{value:!0}),fp.default=void 0;var t=u(vB()),e=u(Uee());function u(r){return r&&r.__esModule?r:{default:r}}var n=(0,t.default)("v3",48,e.default);return fp.default=n,fp}var yp={},bp={},kj;function Hee(){if(kj)return bp;kj=1,Object.defineProperty(bp,"__esModule",{value:!0}),bp.default=void 0;var e={randomUUID:typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};return bp.default=e,bp}var zj;function $ee(){if(zj)return yp;zj=1,Object.defineProperty(yp,"__esModule",{value:!0}),yp.default=void 0;var t=s(Hee()),e=s(gB()),u=om();function s(a){return a&&a.__esModule?a:{default:a}}function n(a,o,l){if(t.default.randomUUID&&!o&&!a)return t.default.randomUUID();a=a||{};const c=a.random||(a.rng||e.default)();if(c[6]=c[6]&15|64,c[8]=c[8]&63|128,o){l=l||0;for(let d=0;d<16;++d)o[l+d]=c[d];return o}return(0,u.unsafeStringify)(c)}var r=n;return yp.default=r,yp}var mp={},gp={},Gj;function Vee(){if(Gj)return gp;Gj=1,Object.defineProperty(gp,"__esModule",{value:!0}),gp.default=void 0;function t(n,r,a,o){switch(n){case 0:return r&a^~r&o;case 1:return r^a^o;case 2:return r&a^r&o^a&o;case 3:return r^a^o}}function e(n,r){return n<>>32-r}function u(n){const r=[1518500249,1859775393,2400959708,3395469782],a=[1732584193,4023233417,2562383102,271733878,3285377520];if(typeof n=="string"){const d=unescape(encodeURIComponent(n));n=[];for(let h=0;h>>0;g=b,b=y,y=e(p,30)>>>0,p=f,f=_}a[0]=a[0]+f>>>0,a[1]=a[1]+p>>>0,a[2]=a[2]+y>>>0,a[3]=a[3]+b>>>0,a[4]=a[4]+g>>>0}return[a[0]>>24&255,a[0]>>16&255,a[0]>>8&255,a[0]&255,a[1]>>24&255,a[1]>>16&255,a[1]>>8&255,a[1]&255,a[2]>>24&255,a[2]>>16&255,a[2]>>8&255,a[2]&255,a[3]>>24&255,a[3]>>16&255,a[3]>>8&255,a[3]&255,a[4]>>24&255,a[4]>>16&255,a[4]>>8&255,a[4]&255]}var s=u;return gp.default=s,gp}var Wj;function kee(){if(Wj)return mp;Wj=1,Object.defineProperty(mp,"__esModule",{value:!0}),mp.default=void 0;var t=u(vB()),e=u(Vee());function u(r){return r&&r.__esModule?r:{default:r}}var n=(0,t.default)("v5",80,e.default);return mp.default=n,mp}var _p={},Jj;function zee(){if(Jj)return _p;Jj=1,Object.defineProperty(_p,"__esModule",{value:!0}),_p.default=void 0;var t="00000000-0000-0000-0000-000000000000";return _p.default=t,_p}var vp={},Xj;function Gee(){if(Xj)return vp;Xj=1,Object.defineProperty(vp,"__esModule",{value:!0}),vp.default=void 0;var t=e(sm());function e(n){return n&&n.__esModule?n:{default:n}}function u(n){if(!(0,t.default)(n))throw TypeError("Invalid UUID");return parseInt(n.slice(14,15),16)}var s=u;return vp.default=s,vp}var Kj;function wB(){return Kj||(Kj=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"NIL",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(t,"parse",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"v1",{enumerable:!0,get:function(){return e.default}}),Object.defineProperty(t,"v3",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(t,"v4",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"v5",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(t,"validate",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"version",{enumerable:!0,get:function(){return a.default}});var e=d(Bee()),u=d(Qee()),s=d($ee()),n=d(kee()),r=d(zee()),a=d(Gee()),o=d(sm()),l=d(om()),c=d(_B());function d(h){return h&&h.__esModule?h:{default:h}}}(yS)),yS}var wp={},Yj;function um(){if(Yj)return wp;Yj=1,Object.defineProperty(wp,"__esModule",{value:!0}),wp.orderTypes=void 0;const t=os(),e=cu(),u=no(),s=Nn(),n=on();function r(c,d,h=!1,f,p){if(c===d)return 0;if(c===void 0)return-1;if(d===void 0)return 1;if(c.termType!==d.termType)return l[c.termType]"term"),cache:f??new t.LRUCache({max:1e3})},defaultTimeZone:{zoneHours:0,zoneMinutes:0}},g=new u.TermTransformer(b.superTypeProvider),m=g.transformLiteral(c),v=g.transformLiteral(d);try{return y.apply([m,v],b).typedValue?0:p.apply([m,v],b).typedValue?1:-1}catch{const _=o(m.dataType,v.dataType);return _!==0?_:o(m.str(),v.str())}}function o(c,d){return c===d?0:cC=>(0,b.bool)(!C.coerceEBV())).collect()},w={arity:1,overloads:(0,b.declare)(l.RegularOperator.UPLUS).numericConverter(()=>C=>C).collect()},S={arity:1,overloads:(0,b.declare)(l.RegularOperator.UMINUS).numericConverter(()=>C=>-C).collect()},A={arity:2,overloads:(0,b.declare)(l.RegularOperator.MULTIPLICATION).arithmetic(()=>(C,ee)=>new t.BigNumber(C).times(ee).toNumber()).collect()},D={arity:2,overloads:(0,b.declare)(l.RegularOperator.DIVISION).arithmetic(()=>(C,ee)=>new t.BigNumber(C).div(ee).toNumber()).onBinaryTyped([c.TypeURL.XSD_INTEGER,c.TypeURL.XSD_INTEGER],()=>(C,ee)=>{if(ee===0)throw new h.ExpressionError("Integer division by 0");return(0,b.decimal)(new t.BigNumber(C).div(ee).toNumber())}).collect()},L={arity:2,overloads:(0,b.declare)(l.RegularOperator.ADDITION).arithmetic(()=>(C,ee)=>new t.BigNumber(C).plus(ee).toNumber()).set([c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DAY_TIME_DURATION],()=>([C,ee])=>new a.DateTimeLiteral((0,p.addDurationToDateTime)(C.typedValue,(0,d.defaultedDurationRepresentation)(ee.typedValue)))).copy({from:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DAY_TIME_DURATION],to:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_YEAR_MONTH_DURATION]}).set([c.TypeURL.XSD_DATE,c.TypeURL.XSD_DAY_TIME_DURATION],()=>([C,ee])=>new a.DateLiteral((0,p.addDurationToDateTime)((0,d.defaultedDateTimeRepresentation)(C.typedValue),(0,d.defaultedDurationRepresentation)(ee.typedValue)))).copy({from:[c.TypeURL.XSD_DATE,c.TypeURL.XSD_DAY_TIME_DURATION],to:[c.TypeURL.XSD_DATE,c.TypeURL.XSD_YEAR_MONTH_DURATION]}).set([c.TypeURL.XSD_TIME,c.TypeURL.XSD_DAY_TIME_DURATION],()=>([C,ee])=>new a.TimeLiteral((0,p.addDurationToDateTime)((0,d.defaultedDateTimeRepresentation)(C.typedValue),(0,d.defaultedDurationRepresentation)(ee.typedValue)))).copy({from:[c.TypeURL.XSD_TIME,c.TypeURL.XSD_DAY_TIME_DURATION],to:[c.TypeURL.XSD_TIME,c.TypeURL.XSD_YEAR_MONTH_DURATION]}).collect()},O={arity:2,overloads:(0,b.declare)(l.RegularOperator.SUBTRACTION).arithmetic(()=>(C,ee)=>new t.BigNumber(C).minus(ee).toNumber()).set([c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DATE_TIME],({defaultTimeZone:C})=>([ee,ye])=>new a.DayTimeDurationLiteral((0,p.elapsedDuration)(ee.typedValue,ye.typedValue,C))).copy({from:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_DATE,c.TypeURL.XSD_DATE]}).copy({from:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_TIME,c.TypeURL.XSD_TIME]}).set([c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DAY_TIME_DURATION],()=>([C,ee])=>new a.DateTimeLiteral((0,p.addDurationToDateTime)(C.typedValue,(0,d.defaultedDurationRepresentation)((0,d.negateDuration)(ee.typedValue))))).copy({from:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DAY_TIME_DURATION],to:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_YEAR_MONTH_DURATION]}).set([c.TypeURL.XSD_DATE,c.TypeURL.XSD_DAY_TIME_DURATION],()=>([C,ee])=>new a.DateLiteral((0,p.addDurationToDateTime)((0,d.defaultedDateTimeRepresentation)(C.typedValue),(0,d.defaultedDurationRepresentation)((0,d.negateDuration)(ee.typedValue))))).copy({from:[c.TypeURL.XSD_DATE,c.TypeURL.XSD_DAY_TIME_DURATION],to:[c.TypeURL.XSD_DATE,c.TypeURL.XSD_YEAR_MONTH_DURATION]}).set([c.TypeURL.XSD_TIME,c.TypeURL.XSD_DAY_TIME_DURATION],()=>([C,ee])=>new a.TimeLiteral((0,p.addDurationToDateTime)((0,d.defaultedDateTimeRepresentation)(C.typedValue),(0,d.defaultedDurationRepresentation)((0,d.negateDuration)(ee.typedValue))))).collect()},E={arity:2,overloads:(0,b.declare)(l.RegularOperator.EQUAL).numberTest(()=>(C,ee)=>C===ee).stringTest(()=>(C,ee)=>C.localeCompare(ee)===0).set([c.TypeURL.RDF_LANG_STRING,c.TypeURL.RDF_LANG_STRING],()=>([C,ee])=>(0,b.bool)(C.str()===ee.str()&&C.language===ee.language)).set([c.TypeAlias.SPARQL_STRINGLY,c.TypeAlias.SPARQL_STRINGLY],()=>()=>(0,b.bool)(!1)).booleanTest(()=>(C,ee)=>C===ee).dateTimeTest(({defaultTimeZone:C})=>(ee,ye)=>(0,d.toUTCDate)(ee,C).getTime()===(0,d.toUTCDate)(ye,C).getTime()).copy({from:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_DATE,c.TypeURL.XSD_DATE]}).set(["quad","quad"],C=>([ee,ye])=>{const Pe=new y.RegularFunction(c.RegularOperator.EQUAL,E);return(0,b.bool)(Pe.apply([ee.subject,ye.subject],C).coerceEBV()&&Pe.apply([ee.predicate,ye.predicate],C).coerceEBV()&&Pe.apply([ee.object,ye.object],C).coerceEBV())},!1).set(["term","term"],()=>([C,ee])=>(0,b.bool)(P(C,ee)),!1).set([c.TypeURL.XSD_DURATION,c.TypeURL.XSD_DURATION],()=>([C,ee])=>(0,b.bool)((0,d.yearMonthDurationsToMonths)((0,d.defaultedYearMonthDurationRepresentation)(C.typedValue))===(0,d.yearMonthDurationsToMonths)((0,d.defaultedYearMonthDurationRepresentation)(ee.typedValue))&&(0,d.dayTimeDurationsToSeconds)((0,d.defaultedDayTimeDurationRepresentation)(C.typedValue))===(0,d.dayTimeDurationsToSeconds)((0,d.defaultedDayTimeDurationRepresentation)(ee.typedValue)))).set([c.TypeURL.XSD_TIME,c.TypeURL.XSD_TIME],({defaultTimeZone:C})=>([ee,ye])=>(0,b.bool)((0,d.toUTCDate)((0,d.defaultedDateTimeRepresentation)(ee.typedValue),C).getTime()===(0,d.toUTCDate)((0,d.defaultedDateTimeRepresentation)(ye.typedValue),C).getTime())).collect()};function P(C,ee){const ye=C.toRDF(),Pe=ee.toRDF(),Ue=ye.equals(Pe);if(!Ue&&ye.termType==="Literal"&&Pe.termType==="Literal")throw new h.RDFEqualTypeError([C,ee]);return Ue}const M={arity:2,overloads:(0,b.declare)(l.RegularOperator.NOT_EQUAL).set(["term","term"],C=>([ee,ye])=>(0,b.bool)(!m.regularFunctions[l.RegularOperator.EQUAL].apply([ee,ye],C).typedValue)).collect()},U={arity:2,overloads:(0,b.declare)(l.RegularOperator.LT).numberTest(()=>(C,ee)=>C(C,ee)=>C.localeCompare(ee)===-1).booleanTest(()=>(C,ee)=>C([C,ee])=>(0,b.bool)((0,f.orderTypes)(C.toRDF(),ee.toRDF(),!0)===-1),!1).dateTimeTest(({defaultTimeZone:C})=>(ee,ye)=>(0,d.toUTCDate)(ee,C).getTime()<(0,d.toUTCDate)(ye,C).getTime()).copy({from:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_DATE,c.TypeURL.XSD_DATE]}).set([c.TypeURL.XSD_YEAR_MONTH_DURATION,c.TypeURL.XSD_YEAR_MONTH_DURATION],()=>([C,ee])=>(0,b.bool)((0,d.yearMonthDurationsToMonths)((0,d.defaultedYearMonthDurationRepresentation)(C.typedValue))<(0,d.yearMonthDurationsToMonths)((0,d.defaultedYearMonthDurationRepresentation)(ee.typedValue)))).set([c.TypeURL.XSD_DAY_TIME_DURATION,c.TypeURL.XSD_DAY_TIME_DURATION],()=>([C,ee])=>(0,b.bool)((0,d.dayTimeDurationsToSeconds)((0,d.defaultedDayTimeDurationRepresentation)(C.typedValue))<(0,d.dayTimeDurationsToSeconds)((0,d.defaultedDayTimeDurationRepresentation)(ee.typedValue)))).set([c.TypeURL.XSD_TIME,c.TypeURL.XSD_TIME],({defaultTimeZone:C})=>([ee,ye])=>(0,b.bool)((0,d.toUTCDate)((0,d.defaultedDateTimeRepresentation)(ee.typedValue),C).getTime()<(0,d.toUTCDate)((0,d.defaultedDateTimeRepresentation)(ye.typedValue),C).getTime())).collect()},j={arity:2,overloads:(0,b.declare)(l.RegularOperator.GT).set(["term","term"],C=>([ee,ye])=>m.regularFunctions[l.RegularOperator.LT].apply([ye,ee],C)).collect()},q={arity:2,overloads:(0,b.declare)(l.RegularOperator.LTE).set(["term","term"],C=>([ee,ye])=>(0,b.bool)(m.regularFunctions[l.RegularOperator.LT].apply([ee,ye],C).typedValue||m.regularFunctions[l.RegularOperator.EQUAL].apply([ee,ye],C).typedValue)).collect()},$={arity:2,overloads:(0,b.declare)(l.RegularOperator.GTE).set(["term","term"],C=>([ee,ye])=>m.regularFunctions[l.RegularOperator.LTE].apply([ye,ee],C)).collect()},Z={arity:1,overloads:(0,b.declare)(l.RegularOperator.IS_IRI).onTerm1(()=>C=>(0,b.bool)(C.termType==="namedNode")).collect()},X={arity:1,overloads:(0,b.declare)(l.RegularOperator.IS_BLANK).onTerm1(()=>C=>(0,b.bool)(C.termType==="blankNode")).collect()},le={arity:1,overloads:(0,b.declare)(l.RegularOperator.IS_LITERAL).onTerm1(()=>C=>(0,b.bool)(C.termType==="literal")).collect()},K={arity:1,overloads:(0,b.declare)(l.RegularOperator.IS_NUMERIC).onNumeric1(()=>()=>(0,b.bool)(!0)).onTerm1(()=>()=>(0,b.bool)(!1)).collect()},he={arity:1,overloads:(0,b.declare)(l.RegularOperator.STR).onTerm1(()=>C=>(0,b.string)(C.str())).collect()},Re={arity:1,overloads:(0,b.declare)(l.RegularOperator.LANG).onLiteral1(()=>C=>(0,b.string)(C.language??"")).collect()},ie={arity:1,overloads:(0,b.declare)(l.RegularOperator.DATATYPE).onLiteral1(()=>C=>new a.NamedNode(C.dataType)).collect()},ae={arity:1,overloads:(0,b.declare)(l.RegularOperator.IRI).set(["namedNode"],C=>ee=>{const ye=ee[0],Pe=(0,s.resolve)(ye.str(),C.baseIRI??"");return new a.NamedNode(Pe)}).onString1(C=>ee=>{const ye=(0,s.resolve)(ee.str(),C.baseIRI??"");return new a.NamedNode(ye)}).collect()},Ee={arity:2,overloads:(0,b.declare)(l.RegularOperator.STRDT).set([c.TypeURL.XSD_STRING,"namedNode"],({superTypeProvider:C})=>([ee,ye])=>{const Pe=v.literal(ee.typedValue,v.namedNode(ye.value));return new o.TermTransformer(C).transformLiteral(Pe)}).collect()},De={arity:2,overloads:(0,b.declare)(l.RegularOperator.STRLANG).onBinaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>(C,ee)=>new a.LangStringLiteral(C,ee.toLowerCase())).collect()},ge={arity:0,overloads:(0,b.declare)(l.RegularOperator.UUID).set([],()=>()=>new a.NamedNode(`urn:uuid:${r.v4()}`)).collect()},de={arity:0,overloads:(0,b.declare)(l.RegularOperator.STRUUID).set([],()=>()=>(0,b.string)(r.v4())).collect()},fe={arity:1,overloads:(0,b.declare)(l.RegularOperator.STRLEN).onStringly1(()=>C=>(0,b.integer)([...C.typedValue].length)).collect()},H={arity:[2,3],overloads:(0,b.declare)(l.RegularOperator.SUBSTR).onBinaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_INTEGER],()=>(C,ee)=>(0,b.string)([...C].slice(ee-1).join(""))).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.XSD_INTEGER],()=>(C,ee)=>{const ye=[...C.typedValue].slice(ee.typedValue-1).join("");return(0,b.langString)(ye,C.language)}).onTernaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_INTEGER,c.TypeURL.XSD_INTEGER],()=>(C,ee,ye)=>(0,b.string)([...C].slice(ee-1,ye+ee-1).join(""))).onTernary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.XSD_INTEGER,c.TypeURL.XSD_INTEGER],()=>(C,ee,ye)=>{const Pe=[...C.typedValue].slice(ee.typedValue-1,ye.typedValue+ee.typedValue-1).join("");return(0,b.langString)(Pe,C.language)}).collect()},N={arity:1,overloads:(0,b.declare)(l.RegularOperator.UCASE).onString1Typed(()=>C=>(0,b.string)(C.toUpperCase())).onLangString1(()=>C=>(0,b.langString)(C.typedValue.toUpperCase(),C.language)).collect()},R={arity:1,overloads:(0,b.declare)(l.RegularOperator.LCASE).onString1Typed(()=>C=>(0,b.string)(C.toLowerCase())).onLangString1(()=>C=>(0,b.langString)(C.typedValue.toLowerCase(),C.language)).collect()},T={arity:2,overloads:(0,b.declare)(l.RegularOperator.STRSTARTS).onBinaryTyped([c.TypeAlias.SPARQL_STRINGLY,c.TypeURL.XSD_STRING],()=>(C,ee)=>(0,b.bool)(C.startsWith(ee))).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.RDF_LANG_STRING],()=>(C,ee)=>{if(C.language!==ee.language)throw new h.IncompatibleLanguageOperation(C,ee);return(0,b.bool)(C.typedValue.startsWith(ee.typedValue))}).collect()},x={arity:2,overloads:(0,b.declare)(l.RegularOperator.STRENDS).onBinaryTyped([c.TypeAlias.SPARQL_STRINGLY,c.TypeURL.XSD_STRING],()=>(C,ee)=>(0,b.bool)(C.endsWith(ee))).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.RDF_LANG_STRING],()=>(C,ee)=>{if(C.language!==ee.language)throw new h.IncompatibleLanguageOperation(C,ee);return(0,b.bool)(C.typedValue.endsWith(ee.typedValue))}).collect()},B={arity:2,overloads:(0,b.declare)(l.RegularOperator.CONTAINS).onBinaryTyped([c.TypeAlias.SPARQL_STRINGLY,c.TypeURL.XSD_STRING],()=>(C,ee)=>(0,b.bool)(C.includes(ee))).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.RDF_LANG_STRING],()=>(C,ee)=>{if(C.language!==ee.language)throw new h.IncompatibleLanguageOperation(C,ee);return(0,b.bool)(C.typedValue.includes(ee.typedValue))}).collect()},k={arity:2,overloads:(0,b.declare)(l.RegularOperator.STRBEFORE).onBinaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>(C,ee)=>(0,b.string)(C.slice(0,Math.max(0,C.indexOf(ee))))).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.XSD_STRING],()=>(C,ee)=>{const[ye,Pe]=[C.typedValue,ee.typedValue],Ue=C.typedValue.slice(0,Math.max(0,ye.indexOf(Pe)));return Ue||!Pe?(0,b.langString)(Ue,C.language):(0,b.string)(Ue)}).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.RDF_LANG_STRING],()=>(C,ee)=>{if(C.language!==ee.language)throw new h.IncompatibleLanguageOperation(C,ee);const[ye,Pe]=[C.typedValue,ee.typedValue],Ue=C.typedValue.slice(0,Math.max(0,ye.indexOf(Pe)));return Ue||!Pe?(0,b.langString)(Ue,C.language):(0,b.string)(Ue)}).collect()},V={arity:2,overloads:(0,b.declare)(l.RegularOperator.STRAFTER).onBinaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>(C,ee)=>(0,b.string)(C.slice(C.indexOf(ee)).slice(ee.length))).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.XSD_STRING],()=>(C,ee)=>{const[ye,Pe]=[C.typedValue,ee.typedValue],Ue=ye.slice(ye.indexOf(Pe)).slice(Pe.length);return Ue||!Pe?(0,b.langString)(Ue,C.language):(0,b.string)(Ue)}).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.RDF_LANG_STRING],()=>(C,ee)=>{if(C.language!==ee.language)throw new h.IncompatibleLanguageOperation(C,ee);const[ye,Pe]=[C.typedValue,ee.typedValue],Ue=ye.slice(ye.indexOf(Pe)).slice(Pe.length);return Ue||!Pe?(0,b.langString)(Ue,C.language):(0,b.string)(Ue)}).collect()},J={arity:1,overloads:(0,b.declare)(l.RegularOperator.ENCODE_FOR_URI).onStringly1Typed(()=>C=>(0,b.string)(encodeURI(C))).collect()},z={arity:2,overloads:(0,b.declare)(l.RegularOperator.LANG_MATCHES).onBinaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>(C,ee)=>(0,b.bool)(g.langMatches(C,ee))).collect()};function Y(){return(C,ee)=>(0,b.bool)(g.matches(C,ee))}function re(){return(C,ee,ye)=>(0,b.bool)(g.matches(C,ee,ye))}const ce={arity:[2,3],overloads:(0,b.declare)(l.RegularOperator.REGEX).onBinaryTyped([c.TypeAlias.SPARQL_STRINGLY,c.TypeURL.XSD_STRING],Y).onTernaryTyped([c.TypeAlias.SPARQL_STRINGLY,c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],re).collect()},Te={arity:[3,4],overloads:(0,b.declare)(l.RegularOperator.REPLACE).onTernaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>(C,ee,ye)=>(0,b.string)(g.replace(C,ee,ye))).set([c.TypeURL.RDF_LANG_STRING,c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>([C,ee,ye])=>{const Pe=g.replace(C.typedValue,ee.typedValue,ye.typedValue);return(0,b.langString)(Pe,C.language)}).onQuaternaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>(C,ee,ye,Pe)=>(0,b.string)(g.replace(C,ee,ye,Pe))).set([c.TypeURL.RDF_LANG_STRING,c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>([C,ee,ye,Pe])=>{const Ue=g.replace(C.typedValue,ee.typedValue,ye.typedValue,Pe.typedValue);return(0,b.langString)(Ue,C.language)}).collect()},xe={arity:1,overloads:(0,b.declare)(l.RegularOperator.ABS).numericConverter(()=>C=>Math.abs(C)).collect()},Le={arity:1,overloads:(0,b.declare)(l.RegularOperator.ROUND).numericConverter(()=>C=>Math.round(C)).collect()},qe={arity:1,overloads:(0,b.declare)(l.RegularOperator.CEIL).numericConverter(()=>C=>Math.ceil(C)).collect()},G={arity:1,overloads:(0,b.declare)(l.RegularOperator.FLOOR).numericConverter(()=>C=>Math.floor(C)).collect()},F={arity:0,overloads:(0,b.declare)(l.RegularOperator.RAND).set([],()=>()=>(0,b.double)(Math.random())).collect()},Q={arity:0,overloads:(0,b.declare)(l.RegularOperator.NOW).set([],C=>()=>new a.DateTimeLiteral((0,d.toDateTimeRepresentation)({date:C.now,timeZone:C.defaultTimeZone}))).collect()},te={arity:1,overloads:(0,b.declare)(l.RegularOperator.YEAR).onDateTime1(()=>C=>(0,b.integer)(C.typedValue.year)).set([c.TypeURL.XSD_DATE],()=>([C])=>(0,b.integer)(C.typedValue.year)).collect()},me={arity:1,overloads:(0,b.declare)(l.RegularOperator.MONTH).onDateTime1(()=>C=>(0,b.integer)(C.typedValue.month)).set([c.TypeURL.XSD_DATE],()=>([C])=>(0,b.integer)(C.typedValue.month)).collect()},Oe={arity:1,overloads:(0,b.declare)(l.RegularOperator.DAY).onDateTime1(()=>C=>(0,b.integer)(C.typedValue.day)).set([c.TypeURL.XSD_DATE],()=>([C])=>(0,b.integer)(C.typedValue.day)).collect()},Ne={arity:1,overloads:(0,b.declare)(l.RegularOperator.HOURS).onDateTime1(()=>C=>(0,b.integer)(C.typedValue.hours)).set([c.TypeURL.XSD_TIME],()=>([C])=>(0,b.integer)(C.typedValue.hours)).collect()},We={arity:1,overloads:(0,b.declare)(l.RegularOperator.MINUTES).onDateTime1(()=>C=>(0,b.integer)(C.typedValue.minutes)).set([c.TypeURL.XSD_TIME],()=>([C])=>(0,b.integer)(C.typedValue.minutes)).collect()},Ve={arity:1,overloads:(0,b.declare)(l.RegularOperator.SECONDS).onDateTime1(()=>C=>(0,b.decimal)(C.typedValue.seconds)).set([c.TypeURL.XSD_TIME],()=>([C])=>(0,b.integer)(C.typedValue.seconds)).collect()},pe={arity:1,overloads:(0,b.declare)(l.RegularOperator.TIMEZONE).onDateTime1(()=>C=>{const ee={hours:C.typedValue.zoneHours,minutes:C.typedValue.zoneMinutes};if(ee.hours===void 0&&ee.minutes===void 0)throw new h.InvalidTimezoneCall(C.str());return new a.DayTimeDurationLiteral(ee)}).copy({from:[c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_DATE]}).copy({from:[c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_TIME]}).collect()},we={arity:1,overloads:(0,b.declare)(l.RegularOperator.TZ).onDateTime1(()=>C=>(0,b.string)((0,d.extractRawTimeZone)(C.str()))).copy({from:[c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_DATE]}).copy({from:[c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_TIME]}).collect()},W={arity:1,overloads:(0,b.declare)(l.RegularOperator.MD5).onString1Typed(()=>C=>(0,b.string)((0,n.hash)(C))).collect()},Se={arity:1,overloads:(0,b.declare)(l.RegularOperator.SHA1).onString1Typed(()=>C=>(0,b.string)((0,e.sha1)().update(C).digest("hex"))).collect()},Ae={arity:1,overloads:(0,b.declare)(l.RegularOperator.SHA256).onString1Typed(()=>C=>(0,b.string)((0,e.sha256)().update(C).digest("hex"))).collect()},je={arity:1,overloads:(0,b.declare)(l.RegularOperator.SHA384).onString1Typed(()=>C=>(0,b.string)((0,e.sha384)().update(C).digest("hex"))).collect()},He={arity:1,overloads:(0,b.declare)(l.RegularOperator.SHA512).onString1Typed(()=>C=>(0,b.string)((0,e.sha512)().update(C).digest("hex"))).collect()},Ge={arity:3,overloads:(0,b.declare)(l.RegularOperator.TRIPLE).onTerm3(C=>(...ee)=>new a.Quad(v.quad(ee[0].toRDF(),ee[1].toRDF(),ee[2].toRDF()),C.superTypeProvider)).collect()},tt={arity:1,overloads:(0,b.declare)(l.RegularOperator.SUBJECT).onQuad1(()=>C=>C.subject).collect()},lt={arity:1,overloads:(0,b.declare)(l.RegularOperator.PREDICATE).onQuad1(()=>C=>C.predicate).collect()},ut={arity:1,overloads:(0,b.declare)(l.RegularOperator.OBJECT).onQuad1(()=>C=>C.object).collect()},oe={arity:1,overloads:(0,b.declare)(l.RegularOperator.IS_TRIPLE).onTerm1(()=>C=>(0,b.bool)(C.termType==="quad")).collect()};return up.definitions={"!":_,uplus:w,uminus:S,"*":A,"/":D,"+":L,"-":O,"=":E,"!=":M,"<":U,">":j,"<=":q,">=":$,isiri:Z,isuri:Z,isblank:X,isliteral:le,isnumeric:K,str:he,lang:Re,datatype:ie,iri:ae,uri:ae,strdt:Ee,strlang:De,uuid:ge,struuid:de,strlen:fe,substr:H,ucase:N,lcase:R,strstarts:T,strends:x,contains:B,strbefore:k,strafter:V,encode_for_uri:J,langmatches:z,regex:ce,replace:Te,abs:xe,round:Le,ceil:qe,floor:G,rand:F,now:Q,year:te,month:me,day:Oe,hours:Ne,minutes:We,seconds:Ve,timezone:pe,tz:we,md5:W,sha1:Se,sha256:Ae,sha384:je,sha512:He,triple:Ge,subject:tt,predicate:lt,object:ut,istriple:oe},up}var Sp={},tL;function Xee(){if(tL)return Sp;tL=1,Object.defineProperty(Sp,"__esModule",{value:!0}),Sp.specialDefinitions=void 0;const t=wB(),e=Kn(),u=Nn(),s=on(),n=Yi(),r=cu(),a={arity:1,async applyAsync({args:D,mapping:L}){return o({args:D,mapping:L})},applySynchronously({args:D,mapping:L}){return o({args:D,mapping:L})}};function o({args:D,mapping:L}){const O=D[0];if(O.expressionType!==e.ExpressionType.Variable)throw new s.InvalidArgumentTypes(D,u.SpecialOperator.BOUND);const E=L.has((0,n.expressionToVar)(O));return(0,n.bool)(E)}const l={arity:3,async applyAsync({args:D,mapping:L,evaluate:O}){const P=(await O(D[0],L)).coerceEBV();return O(P?D[1]:D[2],L)},applySynchronously({args:D,mapping:L,evaluate:O}){const P=O(D[0],L).coerceEBV();return O(P?D[1]:D[2],L)}},c={arity:Number.POSITIVE_INFINITY,async applyAsync({args:D,mapping:L,evaluate:O}){const E=[];for(const P of D)try{return await O(P,L)}catch(M){E.push(M)}throw new s.CoalesceError(E)},applySynchronously({args:D,mapping:L,evaluate:O}){const E=[];for(const P of D)try{return O(P,L)}catch(M){E.push(M)}throw new s.CoalesceError(E)}},d={arity:2,async applyAsync({args:D,mapping:L,evaluate:O}){const[E,P]=D;try{if((await O(E,L)).coerceEBV())return(0,n.bool)(!0);const q=(await O(P,L)).coerceEBV();return(0,n.bool)(q)}catch(M){if(!(await O(P,L)).coerceEBV())throw M;return(0,n.bool)(!0)}},applySynchronously({args:D,mapping:L,evaluate:O}){const[E,P]=D;try{if(O(E,L).coerceEBV())return(0,n.bool)(!0);const q=O(P,L).coerceEBV();return(0,n.bool)(q)}catch(M){if(!O(P,L).coerceEBV())throw M;return(0,n.bool)(!0)}}},h={arity:2,async applyAsync({args:D,mapping:L,evaluate:O}){const[E,P]=D;try{if(!(await O(E,L)).coerceEBV())return(0,n.bool)(!1);const q=(await O(P,L)).coerceEBV();return(0,n.bool)(q)}catch(M){if((await O(P,L)).coerceEBV())throw M;return(0,n.bool)(!1)}},applySynchronously({args:D,mapping:L,evaluate:O}){const[E,P]=D;try{if(!O(E,L).coerceEBV())return(0,n.bool)(!1);const q=O(P,L).coerceEBV();return(0,n.bool)(q)}catch(M){if(O(P,L).coerceEBV())throw M;return(0,n.bool)(!1)}}},f={arity:2,async applyAsync({args:D,mapping:L,evaluate:O}){const[E,P]=D.map(j=>O(j,L)),[M,U]=await Promise.all([E,P]);return(0,n.bool)(M.toRDF().equals(U.toRDF()))},applySynchronously({args:D,mapping:L,evaluate:O}){const[E,P]=D.map(M=>O(M,L));return(0,n.bool)(E.toRDF().equals(P.toRDF()))}},p={arity:Number.POSITIVE_INFINITY,checkArity(D){return D.length>0},async applyAsync(D){const{args:L,mapping:O,evaluate:E}=D,[P,...M]=L,U=await E(P,O);return y(U,{...D,args:M},[])},applySynchronously(D){const{args:L,mapping:O,evaluate:E}=D,[P,...M]=L,U=E(P,O);return b(U,{...D,args:M},[])}};async function y(D,L,O){const{args:E,mapping:P,evaluate:M}=L;if(E.length===0)return O.every(j=>!j)?(0,n.bool)(!1):Promise.reject(new s.InError(O));try{const U=E.shift(),j=await M(U,P);return r.regularFunctions[u.RegularOperator.EQUAL].apply([D,j],L).typedValue?(0,n.bool)(!0):y(D,L,[...O,!1])}catch(U){return y(D,L,[...O,U])}}function b(D,L,O){const{args:E,mapping:P,evaluate:M}=L;if(E.length===0){if(O.every(j=>!j))return(0,n.bool)(!1);throw new s.InError(O)}try{const U=E.shift(),j=M(U,P);return r.regularFunctions[u.RegularOperator.EQUAL].apply([D,j],L).typedValue?(0,n.bool)(!0):b(D,L,[...O,!1])}catch(U){return b(D,L,[...O,U])}}const g={arity:Number.POSITIVE_INFINITY,checkArity(D){return D.length>0},async applyAsync(D){const O=await r.specialFunctions[u.SpecialOperator.IN].applyAsync(D);return(0,n.bool)(!O.typedValue)},applySynchronously(D){const O=r.specialFunctions[u.SpecialOperator.IN].applySynchronously(D);return(0,n.bool)(!O.typedValue)}},m=(0,n.declare)(u.SpecialOperator.CONCAT).onStringly1(()=>D=>D).collect(),v={arity:Number.POSITIVE_INFINITY,async applyAsync(D){const{args:L,mapping:O,evaluate:E,functionArgumentsCache:P,superTypeProvider:M}=D,U=L.map(async X=>E(X,O)).map(async X=>{const le=m.search([await X],M,P);if(!le)throw new s.InvalidArgumentTypes(L,u.SpecialOperator.CONCAT);return le(D)([await X])}),j=await Promise.all(U),$=j.map(X=>X.typedValue).join(""),Z=_(j)?j[0].language:void 0;return Z?(0,n.langString)($,Z):(0,n.string)($)},applySynchronously(D){const{args:L,mapping:O,evaluate:E,superTypeProvider:P,functionArgumentsCache:M}=D,U=L.map(Z=>E(Z,O)).map(Z=>{const X=m.search([Z],P,M);if(!X)throw new s.InvalidArgumentTypes(L,u.SpecialOperator.CONCAT);return X(D)([Z])}),q=U.map(Z=>Z.typedValue).join(""),$=_(U)?U[0].language:void 0;return $?(0,n.langString)(q,$):(0,n.string)(q)}};function _(D){return D.length>0&&D.every(L=>L.language===D[0].language)}const w=(0,n.declare)(u.SpecialOperator.BNODE).onString1(()=>D=>D).collect(),S={arity:Number.POSITIVE_INFINITY,checkArity(D){return D.length===0||D.length===1},async applyAsync(D){const{args:L,mapping:O,evaluate:E,superTypeProvider:P,functionArgumentsCache:M}=D,U=L.length===1?await E(L[0],O):void 0;let j;if(U){const q=w.search([U],P,M);if(!q)throw new s.InvalidArgumentTypes(L,u.SpecialOperator.BNODE);j=q(D)([U]).str()}if(D.bnode){const q=await D.bnode(j);return new e.BlankNode(q)}return A(j)},applySynchronously(D){const{args:L,mapping:O,evaluate:E,superTypeProvider:P,functionArgumentsCache:M}=D,U=L.length===1?E(L[0],O):void 0;let j;if(U){const q=w.search([U],P,M);if(!q)throw new s.InvalidArgumentTypes(L,u.SpecialOperator.BNODE);j=q(D)([U]).str()}if(D.bnode){const q=D.bnode(j);return new e.BlankNode(q)}return A(j)}};function A(D){return new e.BlankNode(D??t.v4())}return Sp.specialDefinitions={bound:a,if:l,coalesce:c,"&&":h,"||":d,sameterm:f,in:p,notin:g,concat:v,bnode:S},Sp}var rL;function cu(){return rL||(rL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(l,c,d,h){h===void 0&&(h=d);var f=Object.getOwnPropertyDescriptor(c,d);(!f||("get"in f?!c.__esModule:f.writable||f.configurable))&&(f={enumerable:!0,get:function(){return c[d]}}),Object.defineProperty(l,h,f)}:function(l,c,d,h){h===void 0&&(h=d),l[h]=c[d]}),u=I&&I.__exportStar||function(l,c){for(var d in l)d!=="default"&&!Object.prototype.hasOwnProperty.call(c,d)&&e(c,l,d)};Object.defineProperty(t,"__esModule",{value:!0}),t.OverloadTree=t.namedFunctions=t.specialFunctions=t.regularFunctions=void 0;const s=N3(),n=Lee(),r=Jee(),a=Xee();u(N3(),t),t.regularFunctions=Object.fromEntries(Object.entries(r.definitions).map(([l,c])=>[l,new s.RegularFunction(l,c)])),t.specialFunctions=Object.fromEntries(Object.entries(a.specialDefinitions).map(([l,c])=>[l,new s.SpecialFunction(l,c)])),t.namedFunctions=Object.fromEntries(Object.entries(n.namedDefinitions).map(([l,c])=>[l,new s.NamedFunction(l,c)]));var o=mB();Object.defineProperty(t,"OverloadTree",{enumerable:!0,get:function(){return o.OverloadTree}})}(fS)),fS}var nL;function SB(){if(nL)return Xh;nL=1,Object.defineProperty(Xh,"__esModule",{value:!0}),Xh.AlgebraTransformer=void 0;const t=Ot(),e=Kn(),u=cu(),s=Nn(),n=on(),r=on(),a=no();let o=class L0 extends a.TermTransformer{constructor(c){super(c.superTypeProvider),this.algebraConfig=c,this.creatorConfig={type:c.type,creator:c.creator}}transformAlgebra(c){const d=t.Algebra.expressionTypes;switch(c.expressionType){case d.TERM:return this.transformTerm(c);case d.OPERATOR:return this.transformOperator(c);case d.NAMED:return this.transformNamed(c);case d.EXISTENCE:return L0.transformExistence(c);case d.AGGREGATE:return L0.transformAggregate(c);case d.WILDCARD:return L0.transformWildcard(c)}}static transformWildcard(c){return new e.NamedNode(c.wildcard.value)}transformOperator(c){const d=c.operator.toLowerCase();if(s.SpecialOperators.has(d)){const y=d,b=c.args.map(m=>this.transformAlgebra(m)),g=u.specialFunctions[y];if(!g.checkArity(b))throw new n.InvalidArity(b,y);return new e.SpecialOperator(b,g.applyAsync,g.applySynchronously)}if(!s.Operators.has(d))throw new n.UnknownOperator(c.operator);const h=d,f=c.args.map(y=>this.transformAlgebra(y)),p=u.regularFunctions[h];if(!L0.hasCorrectArity(f,p.arity))throw new n.InvalidArity(f,h);return new e.Operator(f,y=>p.apply(y,this.algebraConfig))}wrapSyncFunction(c,d){return h=>{try{const f=c(h.map(p=>p.toRDF()));return this.transformRDFTermUnsafe(f)}catch(f){throw new r.ExtensionFunctionError(d,f)}}}wrapAsyncFunction(c,d){return async h=>{try{const f=await c(h.map(p=>p.toRDF()));return this.transformRDFTermUnsafe(f)}catch(f){throw new r.ExtensionFunctionError(d,f)}}}transformNamed(c){const d=c.name.value,h=c.args.map(f=>this.transformAlgebra(f));if(s.NamedOperators.has(d)){const f=c.name.value,p=u.namedFunctions[f];return new e.Named(c.name,h,y=>p.apply(y,this.algebraConfig))}if(this.creatorConfig.type==="sync"){const f=this.creatorConfig.creator(c.name);if(f){const p=this.wrapSyncFunction(f,c.name.value);return new e.SyncExtension(c.name,h,p)}}else{const f=this.creatorConfig.creator(c.name);if(f){const p=this.wrapAsyncFunction(f,c.name.value);return new e.AsyncExtension(c.name,h,p)}}throw new n.UnknownNamedOperator(c.name.value)}static hasCorrectArity(c,d){return Array.isArray(d)?d.includes(c.length):c.length===d}static transformAggregate(c){const d=c.aggregator;return new e.Aggregate(d,c)}static transformExistence(c){return new e.Existence(c)}};return Xh.AlgebraTransformer=o,Xh}var Tp={},Ap={},iL;function TB(){if(iL)return Ap;iL=1,Object.defineProperty(Ap,"__esModule",{value:!0}),Ap.BaseExpressionEvaluator=void 0;const t=Yi(),e=on();let u=class{constructor(n){this.termTransformer=n}term(n){return n}variable(n,r){const a=r.get((0,t.expressionToVar)(n));if(!a)throw new e.UnboundVariableError(n.name,r);return this.termTransformer.transformRDFTermUnsafe(a)}};return Ap.BaseExpressionEvaluator=u,Ap}var aL;function Kee(){if(aL)return Tp;aL=1,Object.defineProperty(Tp,"__esModule",{value:!0}),Tp.AsyncRecursiveEvaluator=void 0;const t=Kn(),e=no(),u=on(),s=TB();let n=class extends s.BaseExpressionEvaluator{constructor(a,o){super(o??new e.TermTransformer(a.superTypeProvider)),this.context=a,this.subEvaluators={[t.ExpressionType.Term]:(l,c)=>this.term(l),[t.ExpressionType.Variable]:(l,c)=>this.variable(l,c),[t.ExpressionType.Operator]:(l,c)=>this.evalOperator(l,c),[t.ExpressionType.SpecialOperator]:(l,c)=>this.evalSpecialOperator(l,c),[t.ExpressionType.Named]:(l,c)=>this.evalNamed(l,c),[t.ExpressionType.Existence]:(l,c)=>this.evalExistence(l,c),[t.ExpressionType.Aggregate]:(l,c)=>this.evalAggregate(l),[t.ExpressionType.AsyncExtension]:(l,c)=>this.evalAsyncExtension(l,c)}}async evaluate(a,o){const l=this.subEvaluators[a.expressionType];if(!l)throw new u.InvalidExpressionType(a);return l.bind(this)(a,o)}async evalOperator(a,o){const l=a.args.map(d=>this.evaluate(d,o)),c=await Promise.all(l);return a.apply(c)}async evalSpecialOperator(a,o){const l=this.evaluate.bind(this),c={args:a.args,mapping:o,superTypeProvider:this.context.superTypeProvider,now:this.context.now,baseIRI:this.context.baseIRI,functionArgumentsCache:this.context.functionArgumentsCache,evaluate:l,bnode:this.context.bnode,defaultTimeZone:this.context.defaultTimeZone};return a.applyAsync(c)}async _evalAsyncArgs(a,o){const l=a.map(c=>this.evaluate(c,o));return await Promise.all(l)}async evalNamed(a,o){return a.apply(await this._evalAsyncArgs(a.args,o))}async evalAsyncExtension(a,o){return await a.apply(await this._evalAsyncArgs(a.args,o))}async evalExistence(a,o){if(!this.context.exists)throw new u.NoExistenceHook;return new t.BooleanLiteral(await this.context.exists(a.expression,o))}async evalAggregate(a){if(!this.context.aggregate)throw new u.NoAggregator;return this.termTransformer.transformRDFTermUnsafe(await this.context.aggregate(a.expression))}};return Tp.AsyncRecursiveEvaluator=n,Tp}var sL;function EB(){if(sL)return Jh;sL=1,Object.defineProperty(Jh,"__esModule",{value:!0}),Jh.AsyncEvaluator=void 0;const t=os(),e=SB(),u=uu(),s=Kee();let n=class AB{static completeContext(a){const o=a.now??new Date(Date.now());return{now:o,baseIRI:a.baseIRI??void 0,functionArgumentsCache:a.functionArgumentsCache??{},superTypeProvider:{cache:a.typeCache??new t.LRUCache({max:1e3}),discoverer:a.getSuperType??(()=>"term")},extensionFunctionCreator:a.extensionFunctionCreator,exists:a.exists,aggregate:a.aggregate,bnode:a.bnode,defaultTimeZone:a.defaultTimeZone??(0,u.extractTimeZone)(o)}}constructor(a,o={}){this.algExpr=a;const l=o.extensionFunctionCreator??(()=>{}),c=AB.completeContext(o),d=new e.AlgebraTransformer({type:"async",creator:l,...c});this.expr=d.transformAlgebra(a),this.evaluator=new s.AsyncRecursiveEvaluator(c,d)}async evaluate(a){return(await this.evaluator.evaluate(this.expr,a)).toRDF()}async evaluateAsEBV(a){return(await this.evaluator.evaluate(this.expr,a)).coerceEBV()}async evaluateAsInternal(a){return await this.evaluator.evaluate(this.expr,a)}};return Jh.AsyncEvaluator=n,Jh}var Ep={},Op={},oL;function Yee(){if(oL)return Op;oL=1,Object.defineProperty(Op,"__esModule",{value:!0}),Op.SyncRecursiveEvaluator=void 0;const t=Kn(),e=no(),u=on(),s=TB();let n=class extends s.BaseExpressionEvaluator{constructor(a,o){super(o??new e.TermTransformer(a.superTypeProvider)),this.context=a,this.subEvaluators={[t.ExpressionType.Term]:(l,c)=>this.term(l),[t.ExpressionType.Variable]:(l,c)=>this.variable(l,c),[t.ExpressionType.Operator]:(l,c)=>this.evalOperator(l,c),[t.ExpressionType.SpecialOperator]:(l,c)=>this.evalSpecialOperator(l,c),[t.ExpressionType.Named]:(l,c)=>this.evalNamed(l,c),[t.ExpressionType.Existence]:(l,c)=>this.evalExistence(l,c),[t.ExpressionType.Aggregate]:(l,c)=>this.evalAggregate(l),[t.ExpressionType.SyncExtension]:(l,c)=>this.evalSyncExtension(l,c)}}evaluate(a,o){const l=this.subEvaluators[a.expressionType];if(!l)throw new u.InvalidExpressionType(a);return l.bind(this)(a,o)}evalOperator(a,o){const l=a.args.map(c=>this.evaluate(c,o));return a.apply(l)}evalSpecialOperator(a,o){const l=this.evaluate.bind(this),c={args:a.args,mapping:o,superTypeProvider:this.context.superTypeProvider,now:this.context.now,baseIRI:this.context.baseIRI,functionArgumentsCache:this.context.functionArgumentsCache,evaluate:l,bnode:this.context.bnode,defaultTimeZone:this.context.defaultTimeZone};return a.applySynchronously(c)}evalNamed(a,o){const l=a.args.map(c=>this.evaluate(c,o));return a.apply(l)}evalSyncExtension(a,o){const l=a.args.map(c=>this.evaluate(c,o));return a.apply(l)}evalExistence(a,o){if(!this.context.exists)throw new u.NoExistenceHook;return new t.BooleanLiteral(this.context.exists(a.expression,o))}evalAggregate(a){if(!this.context.aggregate)throw new u.NoAggregator;return this.termTransformer.transformRDFTermUnsafe(this.context.aggregate(a.expression))}};return Op.SyncRecursiveEvaluator=n,Op}var uL;function RB(){if(uL)return Ep;uL=1,Object.defineProperty(Ep,"__esModule",{value:!0}),Ep.SyncEvaluator=void 0;const t=os(),e=SB(),u=uu(),s=Yee();let n=class OB{static completeContext(a){const o=a.now??new Date(Date.now());return{now:o,baseIRI:a.baseIRI??void 0,functionArgumentsCache:a.functionArgumentsCache??{},superTypeProvider:{cache:a.typeCache??new t.LRUCache({max:1e3}),discoverer:a.getSuperType??(()=>"term")},extensionFunctionCreator:a.extensionFunctionCreator,exists:a.exists,aggregate:a.aggregate,bnode:a.bnode,defaultTimeZone:a.defaultTimeZone??(0,u.extractTimeZone)(o)}}constructor(a,o={}){this.algExpr=a,this.context=o;const l=o.extensionFunctionCreator??(()=>{}),c=OB.completeContext(o),d=new e.AlgebraTransformer({type:"sync",creator:l,...c});this.expr=d.transformAlgebra(a),this.evaluator=new s.SyncRecursiveEvaluator(c,d)}evaluate(a){return this.evaluator.evaluate(this.expr,a).toRDF()}evaluateAsEBV(a){return this.evaluator.evaluate(this.expr,a).coerceEBV()}evaluateAsInternal(a){return this.evaluator.evaluate(this.expr,a)}};return Ep.SyncEvaluator=n,Ep}var Rp={},xp={},Ip={},Pp={},Ns={},cL;function cs(){if(cL)return Ns;cL=1,Object.defineProperty(Ns,"__esModule",{value:!0}),Ns.Aggregator=Ns.AggregatorComponent=void 0;const t=Xt(),e=no(),u=Nn(),s=am();class n{static emptyValue(){}constructor(o,l){this.sharedContext=l,this.separator=o.separator||" ",this.termTransformer=new e.TermTransformer(l.superTypeProvider)}termToNumericOrError(o){if(o.termType!=="Literal")throw new Error(`Term with value ${o.value} has type ${o.termType} and is not a numeric literal`);if(!(0,s.isSubTypeOf)(o.datatype.value,u.TypeAlias.SPARQL_NUMERIC,this.sharedContext.superTypeProvider))throw new Error(`Term datatype ${o.datatype.value} with value ${o.value} has type ${o.termType} and is not a numeric literal`);return this.termTransformer.transformLiteral(o)}}Ns.AggregatorComponent=n;let r=class{constructor(o,l){this.aggregatorComponent=l,this.variableValues=new Map,this.distinct=o.distinct}static emptyValue(o){return o.emptyValue()}result(){return this.aggregatorComponent.result()}put(o,l=""){this.canSkip(o,l)||(this.aggregatorComponent.put(o),this.addSeen(o,l))}canSkip(o,l){const c=this.variableValues.get(l);return this.distinct&&c!==void 0&&c.has(t.termToString(o))}addSeen(o,l){this.distinct&&(this.variableValues.has(l)||this.variableValues.set(l,new Set),this.variableValues.get(l).add(t.termToString(o)))}};return Ns.Aggregator=r,Ns}var lL;function Zee(){if(lL)return Pp;lL=1,Object.defineProperty(Pp,"__esModule",{value:!0}),Pp.Average=void 0;const t=Kn(),e=cu(),u=Yi(),s=Nn(),n=cs();let r=class xB extends n.AggregatorComponent{constructor(){super(...arguments),this.summer=e.regularFunctions[s.RegularOperator.ADDITION],this.divider=e.regularFunctions[s.RegularOperator.DIVISION],this.state=void 0}static emptyValue(){return(0,u.integer)(0).toRDF()}put(o){if(this.state===void 0){const l=this.termToNumericOrError(o);this.state={sum:l,count:1}}else{const l=this.termToNumericOrError(o);this.state.sum=this.summer.apply([this.state.sum,l],this.sharedContext),this.state.count++}}result(){if(this.state===void 0)return xB.emptyValue();const o=new t.IntegerLiteral(this.state.count);return this.divider.apply([this.state.sum,o],this.sharedContext).toRDF()}};return Pp.Average=r,Pp}var Dp={},dL;function ete(){if(dL)return Dp;dL=1,Object.defineProperty(Dp,"__esModule",{value:!0}),Dp.Count=void 0;const t=Yi(),e=cs();let u=class IB extends e.AggregatorComponent{constructor(){super(...arguments),this.state=void 0}static emptyValue(){return(0,t.integer)(0).toRDF()}put(){this.state===void 0&&(this.state=0),this.state++}result(){return this.state===void 0?IB.emptyValue():(0,t.integer)(this.state).toRDF()}};return Dp.Count=u,Dp}var Np={},fL;function tte(){if(fL)return Np;fL=1,Object.defineProperty(Np,"__esModule",{value:!0}),Np.GroupConcat=void 0;const t=Yi(),e=cs();let u=class PB extends e.AggregatorComponent{constructor(){super(...arguments),this.state=void 0,this.lastLanguageValid=!0,this.lastLanguage=void 0}static emptyValue(){return(0,t.string)("").toRDF()}put(n){this.state===void 0?(this.state=n.value,n.termType==="Literal"&&(this.lastLanguage=n.language)):(this.state+=this.separator+n.value,this.lastLanguageValid&&n.termType==="Literal"&&this.lastLanguage!==n.language&&(this.lastLanguageValid=!1,this.lastLanguage=void 0))}result(){return this.state===void 0?PB.emptyValue():this.lastLanguageValid&&this.lastLanguage?(0,t.langString)(this.state,this.lastLanguage).toRDF():(0,t.string)(this.state).toRDF()}};return Np.GroupConcat=u,Np}var Cp={},hL;function rte(){if(hL)return Cp;hL=1,Object.defineProperty(Cp,"__esModule",{value:!0}),Cp.Max=void 0;const t=um(),e=cs();let u=class DB extends e.AggregatorComponent{constructor(){super(...arguments),this.state=void 0}put(n){if(n.termType!=="Literal")throw new Error(`Term with value ${n.value} has type ${n.termType} and is not a literal`);this.state===void 0?this.state=n:(0,t.orderTypes)(this.state,n)===-1&&(this.state=n)}result(){return this.state===void 0?DB.emptyValue():this.state}};return Cp.Max=u,Cp}var jp={},pL;function nte(){if(pL)return jp;pL=1,Object.defineProperty(jp,"__esModule",{value:!0}),jp.Min=void 0;const t=um(),e=cs();let u=class NB extends e.AggregatorComponent{constructor(){super(...arguments),this.state=void 0}put(n){if(n.termType!=="Literal")throw new Error(`Term with value ${n.value} has type ${n.termType} and is not a literal`);this.state===void 0?this.state=n:(0,t.orderTypes)(this.state,n)===1&&(this.state=n)}result(){return this.state===void 0?NB.emptyValue():this.state}};return jp.Min=u,jp}var Lp={},yL;function ite(){if(yL)return Lp;yL=1,Object.defineProperty(Lp,"__esModule",{value:!0}),Lp.Sample=void 0;const t=cs();let e=class CB extends t.AggregatorComponent{constructor(){super(...arguments),this.state=void 0}put(s){this.state===void 0&&(this.state=s)}result(){return this.state===void 0?CB.emptyValue():this.state}};return Lp.Sample=e,Lp}var Mp={},bL;function ate(){if(bL)return Mp;bL=1,Object.defineProperty(Mp,"__esModule",{value:!0}),Mp.Sum=void 0;const t=cu(),e=Yi(),u=Nn(),s=cs();let n=class jB extends s.AggregatorComponent{constructor(){super(...arguments),this.state=void 0,this.summer=t.regularFunctions[u.RegularOperator.ADDITION]}static emptyValue(){return(0,e.integer)(0).toRDF()}put(a){if(this.state===void 0)this.state=this.termToNumericOrError(a);else{const o=this.termToNumericOrError(a);this.state=this.summer.apply([this.state,o],this.sharedContext)}}result(){return this.state===void 0?jB.emptyValue():this.state.toRDF()}};return Mp.Sum=n,Mp}var mL;function ste(){if(mL)return Ip;mL=1,Object.defineProperty(Ip,"__esModule",{value:!0}),Ip.aggregators=void 0;const t=Zee(),e=ete(),u=tte(),s=rte(),n=nte(),r=ite(),a=ate();return Ip.aggregators={count:e.Count,sum:a.Sum,min:n.Min,max:s.Max,avg:t.Average,group_concat:u.GroupConcat,sample:r.Sample},Ip}var Fp={},gL;function ote(){if(gL)return Fp;gL=1,Object.defineProperty(Fp,"__esModule",{value:!0}),Fp.WildcardCountAggregator=void 0;const t=Xt(),e=Yi();let u=class{constructor(n){this.bindingValues=new Map,this.counter=0,this.distinct=n.distinct}putBindings(n){this.handleDistinct(n)||(this.counter+=1)}static emptyValue(){return(0,e.integer)(0).toRDF()}result(){return(0,e.integer)(this.counter).toRDF()}handleDistinct(n){if(this.distinct){const r=[...n];r.sort((d,h)=>d[0].value.localeCompare(h[0].value));const a=r.map(([d])=>d.value).join(","),o=r.map(([,d])=>t.termToString(d)).join(","),l=this.bindingValues.get(a),c=l!==void 0&&l.has(o);return l||this.bindingValues.set(a,new Set),this.bindingValues.get(a).add(o),c}return!1}};return Fp.WildcardCountAggregator=u,Fp}var _L;function LB(){if(_L)return xp;_L=1,Object.defineProperty(xp,"__esModule",{value:!0}),xp.BaseAggregateEvaluator=void 0;const t=Ot(),e=ste(),u=cs(),s=ote(),n=on();let r=class{constructor(o,l,c){this.throwError=!1,this.isWildcard=!1,this.errorOccurred=!1,this.expression=o,this.aggregator=new u.Aggregator(o,new e.aggregators[o.aggregator](o,l)),this.throwError=c??!1,this.isWildcard=o.expression.expressionType===t.Algebra.expressionTypes.WILDCARD,this.isWildcard&&(this.wildcardAggregator=new s.WildcardCountAggregator(o))}static emptyValue(o,l=!1){let c;if(o.expression.expressionType===t.Algebra.expressionTypes.WILDCARD?c=s.WildcardCountAggregator.emptyValue():c=u.Aggregator.emptyValue(e.aggregators[o.aggregator]),c===void 0&&l)throw new n.EmptyAggregateError;return c}result(){if(!this.errorOccurred)return this.isWildcard?this.wildcardAggregator.result():this.aggregator.result()}};return xp.BaseAggregateEvaluator=r,xp}var vL;function ute(){if(vL)return Rp;vL=1,Object.defineProperty(Rp,"__esModule",{value:!0}),Rp.AggregateEvaluator=void 0;const t=LB(),e=RB();let u=class extends t.BaseAggregateEvaluator{constructor(n,r,a){super(n,e.SyncEvaluator.completeContext(r??{}),a),this.evaluator=new e.SyncEvaluator(n.expression,r)}put(n){if(!this.errorOccurred)if(this.isWildcard)this.wildcardAggregator.putBindings(n);else try{const r=this.evaluator.evaluate(n);this.aggregator.put(r)}catch(r){this.safeThrow(r)}}safeThrow(n){if(this.throwError)throw n;this.errorOccurred=!0}};return Rp.AggregateEvaluator=u,Rp}var qp={},wL;function cte(){if(wL)return qp;wL=1,Object.defineProperty(qp,"__esModule",{value:!0}),qp.AsyncAggregateEvaluator=void 0;const t=EB(),e=LB();let u=class extends e.BaseAggregateEvaluator{constructor(n,r,a){super(n,t.AsyncEvaluator.completeContext(r??{}),a),this.evaluator=new t.AsyncEvaluator(n.expression,r),this.errorOccurred=!1}async put(n){if(!this.errorOccurred)if(this.isWildcard)this.wildcardAggregator.putBindings(n);else try{const r=await this.evaluator.evaluate(n);if(!r||this.errorOccurred)return;this.aggregator.put(r)}catch(r){this.safeThrow(r)}}safeThrow(n){if(this.throwError)throw n;this.errorOccurred=!0}};return qp.AsyncAggregateEvaluator=u,qp}var SL;function lu(){return SL||(SL=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.AsyncAggregateEvaluator=t.orderTypes=t.isExpressionError=t.ExpressionError=t.AggregateEvaluator=t.SyncEvaluator=t.AsyncEvaluator=void 0;var e=EB();Object.defineProperty(t,"AsyncEvaluator",{enumerable:!0,get:function(){return e.AsyncEvaluator}});var u=RB();Object.defineProperty(t,"SyncEvaluator",{enumerable:!0,get:function(){return u.SyncEvaluator}});var s=ute();Object.defineProperty(t,"AggregateEvaluator",{enumerable:!0,get:function(){return s.AggregateEvaluator}});var n=on();Object.defineProperty(t,"ExpressionError",{enumerable:!0,get:function(){return n.ExpressionError}}),Object.defineProperty(t,"isExpressionError",{enumerable:!0,get:function(){return n.isExpressionError}});var r=um();Object.defineProperty(t,"orderTypes",{enumerable:!0,get:function(){return r.orderTypes}});var a=cte();Object.defineProperty(t,"AsyncAggregateEvaluator",{enumerable:!0,get:function(){return a.AsyncAggregateEvaluator}})}(uS)),uS}var TL;function lte(){if(TL)return Wh;TL=1,Object.defineProperty(Wh,"__esModule",{value:!0}),Wh.ActorQueryOperationExtend=void 0;const t=xr(),e=wt(),u=lu();let s=class extends e.ActorQueryOperationTypedMediated{constructor(r){super(r,"extend")}async testOperation(r,a){const o=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,a);return new u.AsyncEvaluator(r.expression,e.ActorQueryOperation.getAsyncExpressionContext(a,this.mediatorQueryOperation,o)),!0}async runOperation(r,a){const{expression:o,input:l,variable:c}=r,d=e.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:l,context:a}));if((await d.metadata()).variables.some(g=>g.equals(c)))throw new Error(`Illegal binding to variable '${c.value}' that has already been bound`);const h=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,a),f={...e.ActorQueryOperation.getAsyncExpressionContext(a,this.mediatorQueryOperation,h)},p=new u.AsyncEvaluator(o,f),y=async(g,m,v)=>{try{const _=await p.evaluate(g),w=g.set(c,_);v(w)}catch(_){(0,u.isExpressionError)(_)?(v(g),this.logWarn(a,`Expression error for extend operation (${_.message})with bindings '${(0,t.bindingsToString)(g)}'`)):b.emit("error",_)}m()},b=d.bindingsStream.transform({autoStart:!1,transform:y});return{type:"bindings",bindingsStream:b,async metadata(){const g=await d.metadata();return{...g,variables:[...g.variables,c]}}}}};return Wh.ActorQueryOperationExtend=s,Wh}var AL;function dte(){return AL||(AL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(lte(),t)}(oS)),oS}var bS={},Bp={},EL;function fte(){if(EL)return Bp;EL=1,Object.defineProperty(Bp,"__esModule",{value:!0}),Bp.ActorQueryOperationFilter=void 0;const t=xr(),e=wt(),u=lu();let s=class extends e.ActorQueryOperationTypedMediated{constructor(r){super(r,"filter")}async testOperation(r,a){const o=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,a),l={...e.ActorQueryOperation.getAsyncExpressionContext(a,this.mediatorQueryOperation,o)};return new u.AsyncEvaluator(r.expression,l),!0}async runOperation(r,a){const o=await this.mediatorQueryOperation.mediate({operation:r.input,context:a}),l=e.ActorQueryOperation.getSafeBindings(o);e.ActorQueryOperation.validateQueryOutput(l,"bindings");const c=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,a),d={...e.ActorQueryOperation.getAsyncExpressionContext(a,this.mediatorQueryOperation,c)},h=new u.AsyncEvaluator(r.expression,d),f=async(y,b,g)=>{try{await h.evaluateAsEBV(y)&&g(y)}catch(m){(0,u.isExpressionError)(m)?this.logWarn(a,"Error occurred while filtering.",()=>({error:m,bindings:(0,t.bindingsToString)(y)})):p.emit("error",m)}b()},p=l.bindingsStream.transform({transform:f,autoStart:!1});return{type:"bindings",bindingsStream:p,metadata:l.metadata}}};return Bp.ActorQueryOperationFilter=s,Bp}var OL;function hte(){return OL||(OL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(fte(),t)}(bS)),bS}var mS={},Up={},Qp={},RL;function pte(){if(RL)return Qp;RL=1,Object.defineProperty(Qp,"__esModule",{value:!0}),Qp.GroupsState=void 0;const t=lu(),e=Et(),u=new e.DataFactory;let s=class{constructor(r,a,o,l){this.hashFunction=r,this.pattern=a,this.sparqleeConfig=o,this.bindingsFactory=l,this.groups=new Map,this.groupsInitializer=new Map,this.groupVariables=new Set(this.pattern.variables.map(c=>c.value)),this.waitCounter=1,this.resultHasBeenCalled=!1}consumeBindings(r){const a=this.resultCheck();if(a)return a;this.waitCounter++;const o=r.filter((h,f)=>this.groupVariables.has(f.value)),l=this.hashBindings(o);let c=this.groupsInitializer.get(l),d;if(c){const h=c;d=(async()=>{const f=await h;await Promise.all(this.pattern.aggregates.map(async p=>{const y=p.variable.value;await f.aggregators[y].put(r)}))})().then(async()=>{this.subtractWaitCounterAndCollect()})}else c=(async()=>{const h={};await Promise.all(this.pattern.aggregates.map(async p=>{const y=p.variable.value;h[y]=new t.AsyncAggregateEvaluator(p,this.sparqleeConfig),await h[y].put(r)}));const f={aggregators:h,bindings:o};return this.groups.set(l,f),this.subtractWaitCounterAndCollect(),f})(),this.groupsInitializer.set(l,c),d=c;return d}subtractWaitCounterAndCollect(){--this.waitCounter===0&&this.handleResultCollection()}handleResultCollection(){let r=[...this.groups].map(([a,o])=>{const{bindings:l,aggregators:c}=o;let d=l;for(const h in c){const f=c[h].result();f&&(d=d.set(u.variable(h),f))}return d});if(r.length===0&&this.groupVariables.size===0){const a=[];for(const o of this.pattern.aggregates){const l=o.variable,c=t.AsyncAggregateEvaluator.emptyValue(o);c!==void 0&&a.push([l,c])}r=[this.bindingsFactory.bindings(a)]}this.waitResolver(r)}resultCheck(){if(this.resultHasBeenCalled)return Promise.reject(new Error("Calling any function after calling collectResult is invalid."))}collectResults(){const r=this.resultCheck();if(r)return r;this.resultHasBeenCalled=!0;const a=new Promise(o=>{this.waitResolver=o});return this.subtractWaitCounterAndCollect(),a}hashBindings(r){return this.hashFunction(r)}};return Qp.GroupsState=s,Qp}var xL;function yte(){if(xL)return Up;xL=1,Object.defineProperty(Up,"__esModule",{value:!0}),Up.ActorQueryOperationGroup=void 0;const t=xr(),e=wt(),u=lu(),s=Dt(),n=pte();let r=class extends e.ActorQueryOperationTypedMediated{constructor(o){super(o,"group")}async testOperation(o,l){const c=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,l);for(const d of o.aggregates)new u.AsyncEvaluator(d.expression,e.ActorQueryOperation.getAsyncExpressionContext(l,this.mediatorQueryOperation,c));return!0}async runOperation(o,l){const c=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,l),{hashFunction:d}=await this.mediatorHashBindings.mediate({allowHashCollisions:!0,context:l}),{input:h,aggregates:f}=o,p=await this.mediatorQueryOperation.mediate({operation:h,context:l}),y=e.ActorQueryOperation.getSafeBindings(p),b=[...o.variables,...f.map(v=>v.variable)],g=e.ActorQueryOperation.getAsyncExpressionContext(l,this.mediatorQueryOperation,c);return{type:"bindings",bindingsStream:new s.TransformIterator(()=>new Promise((v,_)=>{const w=new n.GroupsState(d,o,g,c);y.bindingsStream.on("end",async()=>{try{const S=new s.ArrayIterator(await w.collectResults(),{autoStart:!1});v(S)}catch(S){_(S)}}),y.bindingsStream.on("error",_),y.bindingsStream.on("data",S=>{w.consumeBindings(S).catch(_)})}),{autoStart:!1}),metadata:async()=>({...await y.metadata(),variables:b})}}};return Up.ActorQueryOperationGroup=r,Up}var IL;function bte(){return IL||(IL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(yte(),t)}(mS)),mS}var gS={},Hp={},PL;function mte(){if(PL)return Hp;PL=1,Object.defineProperty(Hp,"__esModule",{value:!0}),Hp.ActorQueryOperationLeftJoin=void 0;const t=xr(),e=wt(),u=lu();let s=class extends e.ActorQueryOperationTypedMediated{constructor(r){super(r,"leftjoin")}async testOperation(r,a){return!0}async runOperation(r,a){const o=(await Promise.all(r.input.map(async c=>({output:await this.mediatorQueryOperation.mediate({operation:c,context:a}),operation:c})))).map(({output:c,operation:d})=>({output:e.ActorQueryOperation.getSafeBindings(c),operation:d})),l=await this.mediatorJoin.mediate({type:"optional",entries:o,context:a});if(r.expression){const d=(await o[1].output.metadata()).variables,h=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,a),f={...e.ActorQueryOperation.getAsyncExpressionContext(a,this.mediatorQueryOperation,h)},p=new u.AsyncEvaluator(r.expression,f),y=l.bindingsStream.transform({autoStart:!1,transform:async(b,g,m)=>{if(!d.every(v=>b.has(v.value)))return m(b),g();try{await p.evaluateAsEBV(b)&&m(b)}catch(v){(0,u.isExpressionError)(v)?this.logWarn(a,"Error occurred while filtering.",()=>({error:v,bindings:b})):y.emit("error",v)}g()}});l.bindingsStream=y}return l}};return Hp.ActorQueryOperationLeftJoin=s,Hp}var DL;function gte(){return DL||(DL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(mte(),t)}(gS)),gS}var _S={},$p={},NL;function _te(){if(NL)return $p;NL=1,Object.defineProperty($p,"__esModule",{value:!0}),$p.ActorQueryOperationNop=void 0;const t=xr(),e=wt(),u=Cn(),s=Dt();let n=class extends e.ActorQueryOperationTypedMediated{constructor(a){super(a,"nop")}async testOperation(a,o){return!0}async runOperation(a,o){const l=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,o);return{bindingsStream:new s.SingletonIterator(l.bindings()),metadata:()=>Promise.resolve({state:new u.MetadataValidationState,cardinality:{type:"exact",value:1},canContainUndefs:!1,variables:[]}),type:"bindings"}}};return $p.ActorQueryOperationNop=n,$p}var CL;function vte(){return CL||(CL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(_te(),t)}(_S)),_S}var vS={},Vp={},kp={},jL;function wte(){if(jL)return kp;jL=1,Object.defineProperty(kp,"__esModule",{value:!0}),kp.SortIterator=void 0;const t=Dt();let e=class extends t.TransformIterator{constructor(s,n,r){super(s,r);const a=r&&r.window;this.windowLength=Number.isFinite(a)&&a>0?a:Number.POSITIVE_INFINITY,this.sort=n,this.sorted=[]}_read(s,n){let r,{length:a}=this.sorted;for(;a!==this.windowLength&&(r=this.source.read(),r!==null);){let o=0,l=a-1,c,d;for(;o<=l;)c=Math.trunc((o+l)/2),d=this.sort(r,this.sorted[c]),d<0?o=c+1:d>0?l=c-1:(o=c,l=-1);this.sorted.splice(o,0,r),a++}a===this.windowLength&&this._push(this.sorted.pop()),n()}_flush(s){let{length:n}=this.sorted;for(;n--;)this._push(this.sorted.pop());s()}};return kp.SortIterator=e,kp}var LL;function Ste(){if(LL)return Vp;LL=1,Object.defineProperty(Vp,"__esModule",{value:!0}),Vp.ActorQueryOperationOrderBy=void 0;const t=xr(),e=wt(),u=lu(),s=Ot(),n=wte();let r=class extends e.ActorQueryOperationTypedMediated{constructor(o){super(o,"orderby"),this.window=o.window??Number.POSITIVE_INFINITY}async testOperation(o,l){const c=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,l);for(let d of o.expressions)d=this.extractSortExpression(d),new u.AsyncEvaluator(d,e.ActorQueryOperation.getAsyncExpressionContext(l,this.mediatorQueryOperation,c));return!0}async runOperation(o,l){const c=await this.mediatorQueryOperation.mediate({operation:o.input,context:l}),d=e.ActorQueryOperation.getSafeBindings(c),h={window:this.window},f=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,l),p={...e.ActorQueryOperation.getAsyncExpressionContext(l,this.mediatorQueryOperation,f)};let{bindingsStream:y}=d;for(let b=o.expressions.length-1;b>=0;b--){let g=o.expressions[b];const m=this.isAscending(g);g=this.extractSortExpression(g);const v=new u.AsyncEvaluator(g,p),_=async(A,D,L)=>{try{const O=await v.evaluate(A);L({bindings:A,result:O})}catch(O){(0,u.isExpressionError)(O)||y.emit("error",O),L({bindings:A,result:void 0})}D()},w=y.transform({transform:_});y=new n.SortIterator(w,(A,D)=>{let L=(0,u.orderTypes)(A.result,D.result);return m||(L*=-1),L},h).map(({bindings:A})=>A)}return{type:"bindings",bindingsStream:y,metadata:d.metadata}}extractSortExpression(o){const{expressionType:l,operator:c}=o;return l!==s.Algebra.expressionTypes.OPERATOR?o:c==="desc"?o.args[0]:o}isAscending(o){const{expressionType:l,operator:c}=o;return l!==s.Algebra.expressionTypes.OPERATOR?!0:c!=="desc"}};return Vp.ActorQueryOperationOrderBy=r,Vp}var ML;function Tte(){return ML||(ML=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Ste(),t)}(vS)),vS}var wS={},zp={},FL;function Ate(){if(FL)return zp;FL=1,Object.defineProperty(zp,"__esModule",{value:!0}),zp.ActorQueryOperationService=void 0;const t=xr(),e=wt(),u=Cn(),s=Dt();let n=class extends e.ActorQueryOperationTypedMediated{constructor(a){super(a,"service")}async testOperation(a,o){if(a.name.termType!=="NamedNode")throw new Error(`${this.name} can only query services by IRI, while a ${a.name.termType} was given.`);return!0}async runOperation(a,o){const{querySource:l}=await this.mediatorQuerySourceIdentify.mediate({querySourceUnidentified:{value:a.name.value,type:this.forceSparqlEndpoint?"sparql":void 0},context:o});let c;try{c=e.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:e.ActorQueryOperation.assignOperationSource(a.input,l),context:o}))}catch(d){if(a.silent){const h=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,o);c={bindingsStream:new s.SingletonIterator(h.bindings()),type:"bindings",metadata:async()=>({state:new u.MetadataValidationState,cardinality:{type:"exact",value:1},canContainUndefs:!1,variables:[]})},this.logWarn(o,`An error occurred when executing a SERVICE clause: ${d.message}`)}else throw d}return c}};return zp.ActorQueryOperationService=n,zp}var qL;function Ete(){return qL||(qL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Ate(),t)}(wS)),wS}var SS={},Gp={},BL;function Ote(){if(BL)return Gp;BL=1,Object.defineProperty(Gp,"__esModule",{value:!0}),Gp.ActorQueryOperationValues=void 0;const t=xr(),e=wt(),u=Cn(),s=Dt(),n=Et(),r=new n.DataFactory;let a=class extends e.ActorQueryOperationTyped{constructor(l){super(l,"values")}async testOperation(l,c){return!0}async runOperation(l,c){const d=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,c),h=new s.ArrayIterator(l.bindings.map(y=>d.bindings(Object.entries(y).map(([b,g])=>[r.variable(b.slice(1)),g])))),f=l.variables;return{type:"bindings",bindingsStream:h,metadata:()=>Promise.resolve({state:new u.MetadataValidationState,cardinality:{type:"exact",value:l.bindings.length},canContainUndefs:l.bindings.some(y=>f.some(b=>!(`?${b.value}`in y))),variables:f})}}};return Gp.ActorQueryOperationValues=a,Gp}var UL;function Rte(){return UL||(UL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Ote(),t)}(SS)),SS}var TS={},Wp={},QL;function xte(){if(QL)return Wp;QL=1,Object.defineProperty(Wp,"__esModule",{value:!0}),Wp.ActorQueryOperationPathOneOrMore=void 0;const t=us(),e=xr(),u=wt(),s=Dt(),n=Ot();let r=class extends t.ActorAbstractPath{constructor(o){super(o,n.Algebra.types.ONE_OR_MORE_PATH)}async runOperation(o,l){const c=await e.BindingsFactory.create(this.mediatorMergeBindingsContext,l),d=await this.isPathArbitraryLengthDistinct(l,o);if(d.operation)return d.operation;l=d.context;const h=o.predicate;if(o.subject.termType!=="Variable"&&o.object.termType==="Variable"){const b=o.object,g=await this.getObjectsPredicateStarEval(o.subject,h.path,b,o.graph,l,!1,c),m=o.graph.termType==="Variable"?[b,o.graph]:[b];return{type:"bindings",bindingsStream:g.bindingsStream,metadata:async()=>({...await g.metadata(),variables:m})}}if(o.subject.termType==="Variable"&&o.object.termType==="Variable"){const b=t.ActorAbstractPath.FACTORY.createDistinct(t.ActorAbstractPath.FACTORY.createPath(o.subject,o.predicate.path,o.object,o.graph)),g=u.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({context:l,operation:b})),m=o.subject,v=o.object,_={},w=new s.MultiTransformIterator(g.bindingsStream,{multiTransform:A=>{const D=A.get(m),L=A.get(v),O=o.graph.termType==="Variable"?A.get(o.graph):o.graph;return new s.TransformIterator(async()=>{const E=new s.BufferedIterator;return await this.getSubjectAndObjectBindingsPredicateStar(m,v,D,L,h.path,O,l,_,{},E,{count:0},c),E.transform({transform(P,M,U){o.graph.termType==="Variable"&&(P=P.set(o.graph,O)),U(P),M()}})},{maxBufferSize:128})},autoStart:!1}),S=o.graph.termType==="Variable"?[m,v,o.graph]:[m,v];return{type:"bindings",bindingsStream:w,metadata:async()=>({...await g.metadata(),variables:S})}}if(o.subject.termType==="Variable"&&o.object.termType!=="Variable")return this.mediatorQueryOperation.mediate({context:l,operation:t.ActorAbstractPath.FACTORY.createPath(o.object,t.ActorAbstractPath.FACTORY.createOneOrMorePath(t.ActorAbstractPath.FACTORY.createInv(h.path)),o.subject,o.graph)});const f=this.generateVariable(),p=u.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({context:l,operation:t.ActorAbstractPath.FACTORY.createPath(o.subject,h,f,o.graph)}));return{type:"bindings",bindingsStream:p.bindingsStream.transform({filter:b=>o.object.equals(b.get(f)),transform(b,g,m){const v=o.graph.termType==="Variable"?c.bindings([[o.graph,b.get(o.graph)]]):c.bindings();m(v),g()}}),metadata:async()=>({...await p.metadata(),variables:o.graph.termType==="Variable"?[o.graph]:[]})}}};return Wp.ActorQueryOperationPathOneOrMore=r,Wp}var HL;function Ite(){return HL||(HL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(xte(),t)}(TS)),TS}var AS={},Jp={},$L;function Pte(){if($L)return Jp;$L=1,Object.defineProperty(Jp,"__esModule",{value:!0}),Jp.ActorQueryOperationPathZeroOrMore=void 0;const t=us(),e=xr(),u=wt(),s=Dt(),n=Xt(),r=Ot();let a=class extends t.ActorAbstractPath{constructor(l){super(l,r.Algebra.types.ZERO_OR_MORE_PATH)}async runOperation(l,c){const d=await e.BindingsFactory.create(this.mediatorMergeBindingsContext,c),h=await this.isPathArbitraryLengthDistinct(c,l);if(h.operation)return h.operation;c=h.context;const f=l.predicate,p=this.getPathSources(f),y=l.subject.termType==="Variable",b=l.object.termType==="Variable";if(l.subject.termType==="Variable"&&l.object.termType==="Variable"){const S=this.generateVariable(l),A=this.assignPatternSources(t.ActorAbstractPath.FACTORY.createPattern(l.subject,S,l.object,l.graph),p),D=u.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({context:c,operation:A})),L=l.subject,O=l.object,E=new Set,P={},M=new s.MultiTransformIterator(D.bindingsStream,{multiTransform:j=>{const q=j.get(L),$=j.get(O),Z=l.graph.termType==="Variable"?j.get(l.graph):l.graph,X=(0,n.termToString)(q)+(0,n.termToString)(Z),le=(0,n.termToString)($)+(0,n.termToString)(Z);return new s.TransformIterator(async()=>{if(E.has(X)&&E.has(le))return new s.EmptyIterator;const K=new s.BufferedIterator,he={count:0};return E.has(X)||(E.add(X),await this.getSubjectAndObjectBindingsPredicateStar(L,O,q,q,f.path,Z,c,P,{},K,he,d)),E.has(le)||(E.add(le),await this.getSubjectAndObjectBindingsPredicateStar(L,O,$,$,f.path,Z,c,P,{},K,he,d)),K.transform({transform(Re,ie,ae){l.graph.termType==="Variable"&&(Re=Re.set(l.graph,Z)),ae(Re),ie()}})})}}),U=l.graph.termType==="Variable"?[L,l.object,l.graph]:[L,l.object];return{type:"bindings",bindingsStream:M,metadata:async()=>({...await D.metadata(),variables:U})}}if(!y&&!b){const S=this.generateVariable(),A=await this.getObjectsPredicateStarEval(l.subject,f.path,S,l.graph,c,!0,d);return{type:"bindings",bindingsStream:A.bindingsStream.transform({filter:L=>l.object.equals(L.get(S)),transform(L,O,E){const P=l.graph.termType==="Variable"?d.bindings([[l.graph,L.get(l.graph)]]):d.bindings();E(P),O()}}),metadata:async()=>({...await A.metadata(),variables:l.graph.termType==="Variable"?[l.graph]:[]})}}const g=y?l.object:l.subject,m=y?l.subject:l.object,v=y?t.ActorAbstractPath.FACTORY.createInv(f.path):f.path,_=await this.getObjectsPredicateStarEval(g,v,m,l.graph,c,!0,d),w=l.graph.termType==="Variable"?[m,l.graph]:[m];return{type:"bindings",bindingsStream:_.bindingsStream,metadata:async()=>({...await _.metadata(),variables:w})}}};return Jp.ActorQueryOperationPathZeroOrMore=a,Jp}var VL;function Dte(){return VL||(VL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Pte(),t)}(AS)),AS}var ES={},Xp={},kL;function Nte(){if(kL)return Xp;kL=1,Object.defineProperty(Xp,"__esModule",{value:!0}),Xp.ActorQueryOperationPathZeroOrOne=void 0;const t=us(),e=xr(),u=wt(),s=Cn(),n=Dt(),r=Ot();let a=class extends t.ActorAbstractPath{constructor(l){super(l,r.Algebra.types.ZERO_OR_ONE_PATH)}async runOperation(l,c){const d=await e.BindingsFactory.create(this.mediatorMergeBindingsContext,c),h=l.predicate,f=this.getPathSources(h),p=[];if(l.subject.termType!=="Variable"&&l.object.termType!=="Variable"&&l.subject.equals(l.object))return{type:"bindings",bindingsStream:new n.SingletonIterator(d.bindings()),metadata:()=>Promise.resolve({state:new s.MetadataValidationState,cardinality:{type:"exact",value:1},canContainUndefs:!1,variables:[]})};const y=await this.isPathArbitraryLengthDistinct(c,l);if(y.operation)return y.operation;c=y.context;const b=u.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({context:c,operation:t.ActorAbstractPath.FACTORY.createPath(l.subject,h.path,l.object,l.graph)}));let g;if(l.subject.termType==="Variable"&&l.object.termType==="Variable"){const m=this.generateVariable(l),v=u.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({context:c,operation:t.ActorAbstractPath.FACTORY.createFilter(this.assignPatternSources(t.ActorAbstractPath.FACTORY.createPattern(l.subject,m,l.object,l.graph),f),t.ActorAbstractPath.FACTORY.createOperatorExpression("=",[t.ActorAbstractPath.FACTORY.createTermExpression(l.subject),t.ActorAbstractPath.FACTORY.createTermExpression(l.object)]))})).bindingsStream.map(_=>_.delete(m));g=new n.UnionIterator([v,b.bindingsStream],{autoStart:!1})}else l.subject.termType==="Variable"&&p.push(d.bindings([[l.subject,l.object]])),l.object.termType==="Variable"&&p.push(d.bindings([[l.object,l.subject]])),g=b.bindingsStream.prepend(p);return{type:"bindings",bindingsStream:g,metadata:b.metadata}}};return Xp.ActorQueryOperationPathZeroOrOne=a,Xp}var zL;function Cte(){return zL||(zL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Nte(),t)}(ES)),ES}var OS={},Kp={},GL;function jte(){if(GL)return Kp;GL=1,Object.defineProperty(Kp,"__esModule",{value:!0}),Kp.ActorQueryOperationUpdateDeleteInsert=void 0;const t=G7(),e=xr(),u=wt(),s=Dt();let n=class extends u.ActorQueryOperationTypedMediated{constructor(a){super(a,"deleteinsert"),this.blankNodeCounter=0}async testOperation(a,o){return u.ActorQueryOperation.throwOnReadOnly(o),!0}async runOperation(a,o){const l=await e.BindingsFactory.create(this.mediatorMergeBindingsContext,o),c=a.where?u.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:a.where,context:o})).bindingsStream:new s.ArrayIterator([l.bindings()],{autoStart:!1});let d,h;a.insert&&(d=new t.BindingsToQuadsIterator(a.insert.map(t.BindingsToQuadsIterator.localizeQuad.bind(null,this.blankNodeCounter)),c.clone()),this.blankNodeCounter++),a.delete&&(h=new t.BindingsToQuadsIterator(a.delete.map(t.BindingsToQuadsIterator.localizeQuad.bind(null,this.blankNodeCounter)),c.clone()),this.blankNodeCounter++);const{execute:f}=await this.mediatorUpdateQuads.mediate({quadStreamInsert:d,quadStreamDelete:h,context:o});return{type:"void",execute:f}}};return Kp.ActorQueryOperationUpdateDeleteInsert=n,Kp}var WL;function Lte(){return WL||(WL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(jte(),t)}(OS)),OS}var RS={},Yp={},xS={},Zp={},JL;function Mte(){if(JL)return Zp;JL=1,Object.defineProperty(Zp,"__esModule",{value:!0}),Zp.ActorQueryProcess=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return Zp.ActorQueryProcess=e,Zp}var XL;function cm(){return XL||(XL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Mte(),t)}(xS)),xS}var KL;function Fte(){if(KL)return Yp;KL=1,Object.defineProperty(Yp,"__esModule",{value:!0}),Yp.ActorQueryProcessSequential=void 0;const t=xr(),e=wt(),u=cm(),s=Lt,n=ot;let r=class extends u.ActorQueryProcess{constructor(o){super(o)}async test(o){if(o.context.get(s.KeysInitQuery.explain)||o.context.get(new n.ActionContextKey("explain")))throw new Error(`${this.name} is not able to explain queries.`);return!0}async run(o){let{operation:l,context:c}=await this.parse(o.query,o.context);return{operation:l,context:c}=await this.optimize(l,c),{result:await this.evaluate(l,c)}}async parse(o,l){l=(await this.mediatorContextPreprocess.mediate({context:l,initialize:!0})).context;let c;if(typeof o=="string"){l=l.set(s.KeysInitQuery.queryString,o);const d=l.get(s.KeysInitQuery.baseIRI),h=l.get(s.KeysInitQuery.queryFormat),f=await this.mediatorQueryParse.mediate({context:l,query:o,queryFormat:h,baseIRI:d});c=f.operation,f.baseIRI&&(l=l.set(s.KeysInitQuery.baseIRI,f.baseIRI))}else c=o;if(l.has(s.KeysInitQuery.initialBindings)){const d=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,l);c=(0,e.materializeOperation)(c,l.get(s.KeysInitQuery.initialBindings),d),l=l.delete(s.KeysInitQuery.queryString)}return{operation:c,context:l}}async optimize(o,l){return l=l.set(s.KeysInitQuery.query,o),{operation:o,context:l}=await this.mediatorOptimizeQueryOperation.mediate({context:l,operation:o}),l=l.set(s.KeysInitQuery.query,o),{operation:o,context:l}}async evaluate(o,l){const c=await this.mediatorQueryOperation.mediate({context:l,operation:o});return c.context=l,c}};return Yp.ActorQueryProcessSequential=r,Yp}var YL;function qte(){return YL||(YL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Fte(),t)}(RS)),RS}var IS={},e0={},t0={},r0={},n0={},ZL;function Bte(){if(ZL)return n0;ZL=1,Object.defineProperty(n0,"__esModule",{value:!0}),n0.LinkedRdfSourcesAsyncRdfIterator=void 0;const t=Cn(),e=Dt();let u=class extends e.BufferedIterator{constructor(n,r,a,o,l,c,d,h){if(super({autoStart:!1,...h}),this.started=!1,this.currentIterators=[],this.iteratorsPendingCreation=0,this.iteratorsPendingTermination=0,this.accumulatedMetadata=Promise.resolve(void 0),this._reading=!1,this.cacheSize=n,this.operation=r,this.queryBindingsOptions=a,this.context=o,this.firstUrl=l,this.maxIterators=c,this.sourceStateGetter=d,this.maxIterators<=0)throw new Error(`LinkedRdfSourcesAsyncRdfIterator.maxIterators must be larger than zero, but got ${this.maxIterators}`)}kickstart(){this.started||this._fillBufferAsync()}getProperty(n,r){return n==="metadata"&&!this.started&&(this.preflightMetadata||(this.preflightMetadata=new Promise((a,o)=>{this.sourceStateGetter({url:this.firstUrl},{}).then(l=>{const c=l.source.queryBindings(this.operation,this.context);c.getProperty("metadata",d=>{d.state=new t.MetadataValidationState,c.destroy(),this.accumulateMetadata(l.metadata,d).then(h=>{const f={...l.metadata,...d,...h};a(f)}).catch(()=>{a({...l.metadata,state:new t.MetadataValidationState})})})}).catch(o)})),this.preflightMetadata.then(a=>this.setProperty("metadata",a)).catch(()=>{})),super.getProperty(n,r)}_end(n){for(const r of this.currentIterators)r.destroy();super._end(n)}_read(n,r){if(this.started){for(const a of this.currentIterators){for(;n>0;){const o=a.read();if(o===null)break;n--,this._push(o)}if(n<=0)break}n>=0&&this.canStartNewIterator()?this.sourceStateGetter({url:this.firstUrl},{}).then(a=>{this.startIteratorsForNextUrls(a.handledDatasets,!1),r()}):r()}else this.started=!0,this.sourceStateGetter({url:this.firstUrl},{}).then(a=>{this.startIterator(a),r()}).catch(a=>setTimeout(()=>this.destroy(a)))}canStartNewIterator(){return this.currentIterators.length+this.iteratorsPendingCreation+this.iteratorsPendingTermination0}startIterator(n){try{const r=n.source.queryBindings(this.operation,this.context,this.queryBindingsOptions);this.currentIterators.push(r);let a=!1,o=!1;r._destination=this,r.on("error",l=>this.destroy(l)),r.on("readable",()=>this._fillBuffer()),r.on("end",()=>{this.currentIterators.splice(this.currentIterators.indexOf(r),1),a=!0,o||this.iteratorsPendingTermination++,o&&this.startIteratorsForNextUrls(n.handledDatasets,!0)}),r.getProperty("metadata",l=>{this.accumulatedMetadata=this.accumulatedMetadata.then(c=>(async()=>(c||(c=n.metadata),this.accumulateMetadata(c,l)))().then(d=>{const h={...n.metadata,...l,...d};return h.state=new t.MetadataValidationState,this.updateMetadata(h),this.preflightMetadata&&this.preflightMetadata.then(f=>f.state.invalidate()).catch(()=>{}),this.getSourceLinks(h).then(f=>Promise.all(f)).then(async f=>{const p=await this.getLinkQueue();for(const y of f)p.push(y,n.link);o=!0,a&&this.iteratorsPendingTermination--,this.startIteratorsForNextUrls(n.handledDatasets,!0)}).catch(f=>this.destroy(f)),h})).catch(c=>(this.destroy(c),{}))})}catch(r){this.destroy(r)}}updateMetadata(n){const r=this.getProperty("metadata");this.setProperty("metadata",n),r==null||r.state.invalidate()}isRunning(){return!this.done}startIteratorsForNextUrls(n,r){this.getLinkQueue().then(a=>{for(;this.canStartNewIterator()&&this.isRunning();){const o=a.pop();if(o)this.iteratorsPendingCreation++,this.sourceStateGetter(o,n).then(l=>{this.iteratorsPendingCreation--,this.startIterator(l)}).catch(l=>this.emit("error",l));else break}r&&this.isCloseable(a,!0)&&this.close()}).catch(a=>this.destroy(a))}isCloseable(n,r){return n.isEmpty()&&!this.areIteratorsRunning()}};return n0.LinkedRdfSourcesAsyncRdfIterator=u,n0}var eM;function Ute(){if(eM)return r0;eM=1,Object.defineProperty(r0,"__esModule",{value:!0}),r0.MediatedLinkedRdfSourcesAsyncRdfIterator=void 0;const t=Lt,e=Et(),u=Ot(),s=Bte(),n=new e.DataFactory,r=new u.Factory;let a=class extends s.LinkedRdfSourcesAsyncRdfIterator{constructor(l,c,d,h,f,p,y,b,g,m,v,_){super(l,c,d,h,p,y,b,g?{maxBufferSize:Number.POSITIVE_INFINITY}:void 0),this.wasForcefullyClosed=!1,this.forceSourceType=f,this.mediatorMetadataAccumulate=m,this.mediatorRdfResolveHypermediaLinks=v,this.mediatorRdfResolveHypermediaLinksQueue=_,this.handledUrls={[p]:!0},this.aggregatedStore=g}close(){if(!this.aggregatedStore){super.close();return}this.getLinkQueue().then(l=>{this.isCloseable(l,!1)?(this.aggregatedStore&&setTimeout(()=>this.aggregatedStore.end()),super.close()):this.wasForcefullyClosed=!0}).catch(l=>super.destroy(l))}destroy(l){if(!this.aggregatedStore){super.destroy(l);return}this.getLinkQueue().then(c=>{l??this.isCloseable(c,!1)?(this.aggregatedStore&&setTimeout(()=>this.aggregatedStore.end()),super.destroy(l)):this.wasForcefullyClosed=!0}).catch(c=>super.destroy(c))}isCloseable(l,c){return(c?l.isEmpty():this.wasForcefullyClosed||l.isEmpty())&&!this.areIteratorsRunning()}canStartNewIterator(){return!this.wasForcefullyClosed&&this.aggregatedStore&&this.aggregatedStore.hasRunningIterators()||super.canStartNewIterator()}canStartNewIteratorConsiderReadable(){return!this.aggregatedStore}isRunning(){return this.aggregatedStore&&this.aggregatedStore.hasRunningIterators()||!this.done}getLinkQueue(){return this.linkQueue||(this.linkQueue=this.mediatorRdfResolveHypermediaLinksQueue.mediate({firstUrl:this.firstUrl,context:this.context}).then(l=>l.linkQueue)),this.linkQueue}async getSourceLinks(l){try{const{links:c}=await this.mediatorRdfResolveHypermediaLinks.mediate({context:this.context,metadata:l});return c.filter(d=>this.handledUrls[d.url]?!1:(this.handledUrls[d.url]=!0,!0))}catch{return[]}}startIterator(l){var c;if(this.aggregatedStore&&!this.aggregatedStore.containedSources.has(l.link.url)){(c=this.aggregatedStore)==null||c.containedSources.add(l.link.url);const d=l.source.queryBindings(r.createPattern(n.variable("s"),n.variable("p"),n.variable("o"),n.variable("g")),this.context.set(t.KeysQueryOperation.unionDefaultGraph,!0)).map(h=>n.quad(h.get("s"),h.get("p"),h.get("o"),h.get("g")));this.aggregatedStore.import(d).on("end",()=>{super.startIterator(l)})}else super.startIterator(l)}async accumulateMetadata(l,c){return(await this.mediatorMetadataAccumulate.mediate({mode:"append",accumulatedMetadata:l,appendingMetadata:c,context:this.context})).metadata}updateMetadata(l){var c;super.updateMetadata(l),(c=this.aggregatedStore)==null||c.setBaseMetadata(l,!0)}};return r0.MediatedLinkedRdfSourcesAsyncRdfIterator=a,r0}var i0={},PS={},a0={},tM;function MB(){if(tM)return a0;tM=1,Object.defineProperty(a0,"__esModule",{value:!0}),a0.PendingStreamsIndex=void 0;const t=Xt(),e=un();let u=class qs{constructor(){this.indexedStreams=new Map,this.allStreams=[]}termToString(n){return n&&n.termType!=="Variable"?(0,t.termToString)(n):qs.ID_VARIABLE}addPatternListener(n,r,a,o,l){this.allStreams.push(n);const c=`${this.termToString(r)}${qs.ID_SEPARATOR}${this.termToString(a)}${qs.ID_SEPARATOR}${this.termToString(o)}${qs.ID_SEPARATOR}${this.termToString(l)}`;let d=this.indexedStreams.get(c);d||(d=[],this.indexedStreams.set(c,d)),d.push(n)}getPendingStreamsForQuad(n){let r=[(0,e.getTerms)(n).map(o=>(0,t.termToString)(o))];for(let o=0;o1||y(_,w)})})}function y(_,w){try{b(d[_](w))}catch(S){v(f[0][3],S)}}function b(_){_.value instanceof e?Promise.resolve(_.value.v).then(g,m):v(f[0][2],_)}function g(_){y("next",_)}function m(_){y("throw",_)}function v(_,w){_(w),f.shift(),f.length&&y(f[0][0],f[0][1])}};Object.defineProperty(s0,"__esModule",{value:!0}),s0.StreamingStore=void 0;const s=is,n=Wt(),r=MB();let a=class FB{constructor(l=new s.Store){this.pendingStreams=new r.PendingStreamsIndex,this.ended=!1,this.store=l}end(){this.ended=!0;for(const l of this.pendingStreams.allStreams)l.push(null)}importToListeners(l){l.on("data",c=>{if(!this.ended&&!this.store.countQuads(c.subject,c.predicate,c.object,c.graph))for(const d of this.pendingStreams.getPendingStreamsForQuad(c))d.isInitialized&&(d.push(c),d.emit("quad",c))})}static concatStreams(l){return u(this,arguments,function*(){var d,h,f,p;for(const m of l)try{for(var y=!0,b=(h=void 0,t(m)),g;g=yield e(b.next()),d=g.done,!d;){p=g.value,y=!1;try{yield yield e(p)}finally{y=!0}}}catch(v){h={error:v}}finally{try{!y&&!d&&(f=b.return)&&(yield e(f.call(b)))}finally{if(h)throw h.error}}})}import(l){if(this.ended)throw new Error("Attempted to import into an ended StreamingStore");return this.importToListeners(l),this.store.import(l)}match(l,c,d,h){const f=this.store.match(l,c,d,h);let p=f;if(!this.ended){const y=new n.PassThrough({objectMode:!0});this.pendingStreams.addPatternListener(y,l,c,d,h),p=n.Readable.from(FB.concatStreams([f,y])),p._pipeSource=f;const b=f._read;f._read=g=>{y.isInitialized=!0,b.call(f,g)}}return p}getStore(){return this.store}};return s0.StreamingStore=a,s0}var nM;function Hte(){return nM||(nM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(MB(),t),u(Qte(),t)}(PS)),PS}var iM;function $te(){if(iM)return i0;iM=1,Object.defineProperty(i0,"__esModule",{value:!0}),i0.StreamingStoreMetadata=void 0;const t=wt(),e=Cn(),u=Hte();let s=class extends u.StreamingStore{constructor(r,a){super(r),this.started=!1,this.containedSources=new Set,this.runningIterators=new Set,this.iteratorCreatedListeners=new Set,this.baseMetadata={state:new e.MetadataValidationState,cardinality:{type:"exact",value:0},canContainUndefs:!1,variables:[]},this.metadataAccumulator=a}import(r){return this.ended||super.import(r),r}hasRunningIterators(){return this.runningIterators.size>0}match(r,a,o,l){const c=super.match(r,a,o,l),d=new t.ClosableTransformIterator(c,{autoStart:!1,onClose:()=>{this.runningIterators.delete(d)}});let h=this.getStore().countQuads(r,a,o,l);const f={state:new e.MetadataValidationState,cardinality:{type:"estimate",value:h},canContainUndefs:!1};d.setProperty("metadata",f),d.setProperty("lastCount",h),c.on("quad",()=>{d.setProperty("lastCount",++h),this.updateMetadataState(d,h)}),this.runningIterators.add(d);for(const p of this.iteratorCreatedListeners)p();return d}setBaseMetadata(r,a){if(this.baseMetadata={...r},this.baseMetadata.cardinality={type:"exact",value:0},a)for(const o of this.runningIterators){const l=o.getProperty("lastCount");this.updateMetadataState(o,l)}}updateMetadataState(r,a){const o={state:new e.MetadataValidationState,cardinality:{type:"estimate",value:a},canContainUndefs:!1,variables:[]};this.metadataAccumulator(this.baseMetadata,o).then(l=>{l.state=new e.MetadataValidationState;const c=r.getProperty("metadata");r.setProperty("metadata",l),c==null||c.state.invalidate()}).catch(()=>{})}addIteratorCreatedListener(r){this.iteratorCreatedListeners.add(r)}removeIteratorCreatedListener(r){this.iteratorCreatedListeners.delete(r)}};return i0.StreamingStoreMetadata=s,i0}var aM;function qB(){if(aM)return t0;aM=1,Object.defineProperty(t0,"__esModule",{value:!0}),t0.QuerySourceHypermedia=void 0;const t=yA(),e=Lt,u=Dt(),s=os(),n=Wt(),r=Ute(),a=$te();let o=class{constructor(c,d,h,f,p,y,b,g){this.referenceValue=d,this.cacheSize=c,this.firstUrl=d,this.forceSourceType=h,this.maxIterators=f,this.mediators=y,this.aggregateStore=p,this.logWarning=b,this.bindingsFactory=g,this.sourcesState=new s.LRUCache({max:this.cacheSize})}async getSelectorShape(c){return(await this.getSourceCached({url:this.firstUrl},{},c,this.getAggregateStore(c))).source.getSelectorShape(c)}queryBindings(c,d,h){const f=this.getAggregateStore(d);if(f&&c.type==="pattern"&&f.started)return new t.QuerySourceRdfJs(f,this.bindingsFactory).queryBindings(c,d);this.sourcesState.size===0&&this.getSourceCached({url:this.firstUrl},{},d,f).catch(y=>p.destroy(y));const p=new r.MediatedLinkedRdfSourcesAsyncRdfIterator(this.cacheSize,c,h,d,this.forceSourceType,this.firstUrl,this.maxIterators,(y,b)=>this.getSourceCached(y,b,d,f),f,this.mediators.mediatorMetadataAccumulate,this.mediators.mediatorRdfResolveHypermediaLinks,this.mediators.mediatorRdfResolveHypermediaLinksQueue);if(f){f.started=!0;const y=()=>p.kickstart();f.addIteratorCreatedListener(y),p.on("end",()=>f.removeIteratorCreatedListener(y))}return p}queryQuads(c,d){return new u.TransformIterator(async()=>(await this.getSourceCached({url:this.firstUrl},{},d,this.getAggregateStore(d))).source.queryQuads(c,d))}async queryBoolean(c,d){return await(await this.getSourceCached({url:this.firstUrl},{},d,this.getAggregateStore(d))).source.queryBoolean(c,d)}async queryVoid(c,d){return await(await this.getSourceCached({url:this.firstUrl},{},d,this.getAggregateStore(d))).source.queryVoid(c,d)}async getSource(c,d,h,f){var v;c.context&&(h=h.merge(c.context));let p=c.url,y,b;try{const _=await this.mediators.mediatorDereferenceRdf.mediate({context:h,url:p});p=_.url;const w=await this.mediators.mediatorMetadata.mediate({context:h,url:p,quads:_.data,triples:(v=_.metadata)==null?void 0:v.triples});w.data.on("error",()=>{}),b=(await this.mediators.mediatorMetadataExtract.mediate({context:h,url:p,metadata:w.metadata,headers:_.headers,requestTime:_.requestTime})).metadata,y=w.data,c.transform&&(y=await c.transform(y))}catch(_){y=new n.Readable,y.read=()=>(setTimeout(()=>y.emit("error",_)),null),{metadata:b}=await this.mediators.mediatorMetadataAccumulate.mediate({context:h,mode:"initialize"}),this.logWarning(`Metadata extraction for ${p} failed: ${_.message}`)}f==null||f.setBaseMetadata(b,!1),f==null||f.containedSources.add(c.url),f==null||f.import(y);const{source:g,dataset:m}=await this.mediators.mediatorQuerySourceIdentifyHypermedia.mediate({context:h,forceSourceType:c.url===this.firstUrl?this.forceSourceType:void 0,handledDatasets:d,metadata:b,quads:y,url:p});return m&&(d[m]=!0),{link:c,source:g,metadata:b,handledDatasets:d}}getSourceCached(c,d,h,f){let p=this.sourcesState.get(c.url);return p||(p=this.getSource(c,d,h,f),(c.url===this.firstUrl||f===void 0)&&this.sourcesState.set(c.url,p),p)}getAggregateStore(c){let d;if(this.aggregateStore){const h=c.get(e.KeysQuerySourceIdentify.hypermediaSourcesAggregatedStores);if(h)return d=h.get(this.firstUrl),d||(d=new a.StreamingStoreMetadata(void 0,async(f,p)=>(await this.mediators.mediatorMetadataAccumulate.mediate({mode:"append",accumulatedMetadata:f,appendingMetadata:p,context:c})).metadata),h.set(this.firstUrl,d)),d}}toString(){return`QuerySourceHypermedia(${this.firstUrl})`}};return t0.QuerySourceHypermedia=o,t0}var sM;function Vte(){if(sM)return e0;sM=1,Object.defineProperty(e0,"__esModule",{value:!0}),e0.ActorQuerySourceIdentifyHypermedia=void 0;const t=xr(),e=Ly(),u=Lt,s=ot,n=qB();let r=class extends e.ActorQuerySourceIdentify{constructor(o){super(o)}async test(o){if(typeof o.querySourceUnidentified.value!="string")throw new TypeError(`${this.name} requires a single query source with a URL value to be present in the context.`);return!0}async run(o){var l;return{querySource:{source:new n.QuerySourceHypermedia(this.cacheSize,o.querySourceUnidentified.value,o.querySourceUnidentified.type,this.maxIterators,this.aggregateTraversalStore&&!!((l=o.querySourceUnidentified.context)!=null&&l.get(u.KeysQuerySourceIdentify.traverse)),{mediatorMetadata:this.mediatorMetadata,mediatorMetadataExtract:this.mediatorMetadataExtract,mediatorMetadataAccumulate:this.mediatorMetadataAccumulate,mediatorDereferenceRdf:this.mediatorDereferenceRdf,mediatorQuerySourceIdentifyHypermedia:this.mediatorQuerySourceIdentifyHypermedia,mediatorRdfResolveHypermediaLinks:this.mediatorRdfResolveHypermediaLinks,mediatorRdfResolveHypermediaLinksQueue:this.mediatorRdfResolveHypermediaLinksQueue},c=>this.logWarn(o.context,c),await t.BindingsFactory.create(this.mediatorMergeBindingsContext,o.context)),context:o.querySourceUnidentified.context??new s.ActionContext}}}};return e0.ActorQuerySourceIdentifyHypermedia=r,e0}var oM;function kte(){return oM||(oM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Vte(),t),u(qB(),t)}(IS)),IS}var DS={},o0={},uM;function zte(){if(uM)return o0;uM=1,Object.defineProperty(o0,"__esModule",{value:!0}),o0.ActorRdfJoinNone=void 0;const t=xr(),e=jn(),u=Cn(),s=Dt();let n=class extends e.ActorRdfJoin{constructor(a){super(a,{logicalType:"inner",physicalName:"none",limitEntries:0})}async test(a){if(a.entries.length>0)throw new Error(`Actor ${this.name} can only join zero entries`);return await this.getJoinCoefficients()}async getOutput(a){const o=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,a.context);return{result:{bindingsStream:new s.ArrayIterator([o.bindings()],{autoStart:!1}),metadata:()=>Promise.resolve({state:new u.MetadataValidationState,cardinality:{type:"exact",value:1},canContainUndefs:!1,variables:[]}),type:"bindings"}}}async getJoinCoefficients(){return{iterations:0,persistedItems:0,blockingItems:0,requestTime:0}}};return o0.ActorRdfJoinNone=n,o0}var cM;function Gte(){return cM||(cM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(zte(),t)}(DS)),DS}var NS={},u0={},lM;function Wte(){if(lM)return u0;lM=1,Object.defineProperty(u0,"__esModule",{value:!0}),u0.ActorRdfJoinMultiBind=void 0;const t=xr(),e=wt(),u=jn(),s=Lt,n=Dt(),r=Ot();let a=class C3 extends u.ActorRdfJoin{constructor(l){l.minMaxCardinalityRatio===void 0&&(l.minMaxCardinalityRatio=60),super(l,{logicalType:"inner",physicalName:"bind",canHandleUndefs:!0,isLeaf:!1})}static createBindStream(l,c,d,h,f,p){const y=l==="depth-first",b=g=>{const m=d.map(_=>(0,e.materializeOperation)(_,g,p,{bindFilter:!0})),v=_=>_.merge(g);return new n.TransformIterator(async()=>(await h(m,g)).transform({map:v}),{maxBufferSize:128,autoStart:y})};switch(l){case"depth-first":return new n.MultiTransformIterator(c,{autoStart:!1,multiTransform:b,optional:f});case"breadth-first":return new n.UnionIterator(c.transform({map:b,optional:f}),{autoStart:!1});default:throw new Error(`Received request for unknown bind order: ${l}`)}}async getOutput(l){const c=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,l.context),d=await u.ActorRdfJoin.getEntriesWithMetadatas(l.entries),h=await u.ActorRdfJoin.sortJoinEntries(this.mediatorJoinEntriesSort,d,l.context);this.logDebug(l.context,"First entry for Bind Join: ",()=>({entry:h[0].operation,metadata:h[0].metadata}));for(const[g,m]of h.entries())g!==0&&m.output.bindingsStream.close();const f=h[0].output,p=[...h];p.splice(0,1);const y=l.context.set(s.KeysQueryOperation.joinLeftMetadata,h[0].metadata).set(s.KeysQueryOperation.joinRightMetadatas,p.map(g=>g.metadata));return{result:{type:"bindings",bindingsStream:C3.createBindStream(this.bindOrder,f.bindingsStream,p.map(g=>g.operation),async(g,m)=>{const v=g.length===1?g[0]:C3.FACTORY.createJoin(g);return e.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:v,context:y==null?void 0:y.set(s.KeysQueryOperation.joinBindings,m)})).bindingsStream},!1,c),metadata:()=>this.constructResultMetadata(h,h.map(g=>g.metadata),l.context)},physicalPlanMetadata:{bindIndex:d.indexOf(h[0]),bindOperation:h[0].operation,bindOperationCardinality:h[0].metadata.cardinality,bindOrder:this.bindOrder}}}canBindWithOperation(l){let c=!0;return r.Util.recurseOperation(l,{[r.Algebra.types.EXTEND](){return c=!1,!1},[r.Algebra.types.GROUP](){return c=!1,!1}}),c}async getJoinCoefficients(l,c){const d=await u.ActorRdfJoin.sortJoinEntries(this.mediatorJoinEntriesSort,l.entries.map((w,S)=>({...w,metadata:c[S]})),l.context);c=d.map(w=>w.metadata);const h=u.ActorRdfJoin.getRequestInitialTimes(c),f=u.ActorRdfJoin.getRequestItemTimes(c),p=[...d],y=[...h],b=[...f];if(p.splice(0,1),y.splice(0,1),b.splice(0,1),p.some(w=>!this.canBindWithOperation(w.operation)))throw new Error(`Actor ${this.name} can not bind on Extend and Group operations`);if(p.some(w=>w.operationModified))throw new Error(`Actor ${this.name} can not be used over remaining entries with modified operations`);if(c[0].cardinality.value*this.minMaxCardinalityRatio>Math.max(...c.map(w=>w.cardinality.value)))throw new Error(`Actor ${this.name} can only run if the smallest stream is much smaller than largest stream`);const g=await Promise.all(p.map(async w=>(await this.mediatorJoinSelectivity.mediate({entries:[d[0],w],context:l.context})).selectivity*this.selectivityModifier)),m=p.map((w,S)=>w.metadata.cardinality.value*g[S]).reduce((w,S)=>w+S,0),v=y.reduce((w,S)=>w+S,0),_=b.reduce((w,S)=>w+S,0);return{iterations:c[0].cardinality.value*m,persistedItems:0,blockingItems:0,requestTime:h[0]+c[0].cardinality.value*(f[0]+v+m*_)}}};return u0.ActorRdfJoinMultiBind=a,a.FACTORY=new r.Factory,u0}var dM;function BB(){return dM||(dM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Wte(),t)}(NS)),NS}var CS={},c0={},fM;function Jte(){if(fM)return c0;fM=1,Object.defineProperty(c0,"__esModule",{value:!0}),c0.ActorRdfJoinOptionalBind=void 0;const t=BB(),e=xr(),u=wt(),s=jn(),n=Lt,r=Ot();let a=class extends s.ActorRdfJoin{constructor(l){super(l,{logicalType:"optional",physicalName:"bind",limitEntries:2,canHandleUndefs:!0,isLeaf:!1})}async getOutput(l){const c=await e.BindingsFactory.create(this.mediatorMergeBindingsContext,l.context);l.entries[1].output.bindingsStream.close();const d=l.context.set(n.KeysQueryOperation.joinLeftMetadata,await l.entries[0].output.metadata()).set(n.KeysQueryOperation.joinRightMetadatas,[await l.entries[1].output.metadata()]);return{result:{type:"bindings",bindingsStream:t.ActorRdfJoinMultiBind.createBindStream(this.bindOrder,l.entries[0].output.bindingsStream,[l.entries[1].operation],async(f,p)=>{const y=f[0];return u.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:y,context:d==null?void 0:d.set(n.KeysQueryOperation.joinBindings,p)})).bindingsStream},!0,c),metadata:async()=>await this.constructResultMetadata(l.entries,await s.ActorRdfJoin.getMetadatas(l.entries),l.context,{canContainUndefs:!0},!0)}}}async getJoinCoefficients(l,c){if(s.ActorRdfJoin.overlappingVariables(c).length===0)throw new Error(`Actor ${this.name} only join entries with at least one common variable`);const d=s.ActorRdfJoin.getRequestInitialTimes(c),h=s.ActorRdfJoin.getRequestItemTimes(c);if(l.entries[1].operation.type===r.Algebra.types.EXTEND||l.entries[1].operation.type===r.Algebra.types.GROUP)throw new Error(`Actor ${this.name} can not bind on Extend and Group operations`);const f=(await this.mediatorJoinSelectivity.mediate({entries:l.entries,context:l.context})).selectivity*this.selectivityModifier;return{iterations:c[0].cardinality.value*c[1].cardinality.value*f,persistedItems:0,blockingItems:0,requestTime:d[0]+c[0].cardinality.value*(h[0]+d[1]+f*c[1].cardinality.value*h[1])}}};return c0.ActorRdfJoinOptionalBind=a,c0}var hM;function Xte(){return hM||(hM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Jte(),t)}(CS)),CS}var jS={},l0={},pM;function Kte(){if(pM)return l0;pM=1,Object.defineProperty(l0,"__esModule",{value:!0}),l0.ActorQueryProcessExplainParsed=void 0;const t=cm(),e=Lt,u=ot;let s=class extends t.ActorQueryProcess{constructor(r){super(r)}async test(r){if((r.context.get(e.KeysInitQuery.explain)||r.context.get(new u.ActionContextKey("explain")))!=="parsed")throw new Error(`${this.name} can only explain in 'parsed' mode.`);return!0}async run(r){const{operation:a}=await this.queryProcessor.parse(r.query,r.context);return{result:{explain:!0,type:"parsed",data:a}}}};return l0.ActorQueryProcessExplainParsed=s,l0}var yM;function Yte(){return yM||(yM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Kte(),t)}(jS)),jS}var LS={},d0={},bM;function Zte(){if(bM)return d0;bM=1,Object.defineProperty(d0,"__esModule",{value:!0}),d0.ActorQueryProcessExplainLogical=void 0;const t=cm(),e=Lt,u=ot;let s=class extends t.ActorQueryProcess{constructor(r){super(r)}async test(r){if((r.context.get(e.KeysInitQuery.explain)||r.context.get(new u.ActionContextKey("explain")))!=="logical")throw new Error(`${this.name} can only explain in 'logical' mode.`);return!0}async run(r){let{operation:a,context:o}=await this.queryProcessor.parse(r.query,r.context);return{operation:a,context:o}=await this.queryProcessor.optimize(a,o),{result:{explain:!0,type:"logical",data:a}}}};return d0.ActorQueryProcessExplainLogical=s,d0}var mM;function ere(){return mM||(mM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Zte(),t)}(LS)),LS}var MS={},f0={},Cs={},gM;function UB(){if(gM)return Cs;gM=1,Object.defineProperty(Cs,"__esModule",{value:!0}),Cs.numberToString=Cs.MemoryPhysicalQueryPlanLogger=void 0;const t=Xt();let e=class{constructor(){this.planNodes=new Map}logOperation(n,r,a,o,l,c){const d={actor:l,logicalOperator:n,physicalOperator:r,rawNode:a,children:[],metadata:c};if(this.planNodes.set(a,d),this.rootNode){if(!o)throw new Error("Detected more than one parent-less node");const h=this.planNodes.get(o);if(!h)throw new Error("Could not find parent node");h.children.push(d)}else{if(o)throw new Error("No root node has been set yet, while a parent is being referenced");this.rootNode=d}}stashChildren(n,r){const a=this.planNodes.get(n);if(!a)throw new Error("Could not find plan node");a.children=r?a.children.filter(r):[]}unstashChild(n,r){const a=this.planNodes.get(n);if(a){const o=this.planNodes.get(r);if(!o)throw new Error("Could not find plan parent node");o.children.push(a)}}appendMetadata(n,r){const a=this.planNodes.get(n);a&&(a.metadata={...a.metadata,...r})}toJson(){return this.rootNode?this.planNodeToJson(this.rootNode):{}}planNodeToJson(n){var a;const r={logical:n.logicalOperator,physical:n.physicalOperator,...this.getLogicalMetadata(n.rawNode),...this.compactMetadata(n.metadata)};if(n.children.length>0&&(r.children=n.children.map(o=>this.planNodeToJson(o))),r.physical==="bind"&&r.children){const o={};for(const c of r.children){const d=((a=c.children)==null?void 0:a.at(-1))??c,h=this.getPlanHash(d).join(",");o[h]||(o[h]=[]),o[h].push(c)}const l=[];for(const c of Object.values(o))l.push({occurrences:c.length,firstOccurrence:c[0]});r.childrenCompact=l,delete r.children}return r}getPlanHash(n){let r=[`${n.logical}-${n.physical}`];return n.children?r=[...r,...n.children.flatMap(a=>this.getPlanHash(a))]:n.childrenCompact&&(r=[...r,...n.childrenCompact.flatMap(a=>this.getPlanHash(a.firstOccurrence))]),r}compactMetadata(n){return Object.fromEntries(Object.entries(n).map(([r,a])=>[r,this.compactMetadataValue(a)]))}compactMetadataValue(n){return n&&typeof n=="object"&&"termType"in n?this.getLogicalMetadata(n):n}getLogicalMetadata(n){var a;const r={};if("type"in n){const o=n;switch((a=o.metadata)!=null&&a.scopedSource&&(r.source=o.metadata.scopedSource.source.toString()),o.type){case"pattern":r.pattern=this.quadToString(o);break;case"project":r.variables=o.variables.map(l=>l.value);break}}return r}quadToString(n){return`${(0,t.termToString)(n.subject)} ${(0,t.termToString)(n.predicate)} ${(0,t.termToString)(n.object)}${n.graph.termType==="DefaultGraph"?"":` ${(0,t.termToString)(n.graph)}`}`}toCompactString(){const n=this.toJson(),r=[],a=new Map;if("logical"in n?this.nodeToCompactString(r,a,"",n):r.push("Empty"),a.size>0){r.push(""),r.push("sources:");for(const[o,l]of a.entries())r.push(` ${l}: ${o}`)}return r.join(` +`)}nodeToCompactString(n,r,a,o,l){let c;o.source&&(c=r.get(o.source),c===void 0&&(c=r.size,r.set(o.source,c))),n.push(`${a}${o.logical}${o.physical?`(${o.physical})`:""}${o.pattern?` (${o.pattern})`:""}${o.variables?` (${o.variables.join(",")})`:""}${o.bindOperation?` bindOperation:(${o.bindOperation.pattern}) bindCardEst:${o.bindOperationCardinality.type==="estimate"?"~":""}${u(o.bindOperationCardinality.value)}`:""}${o.cardinality?` cardEst:${o.cardinality.type==="estimate"?"~":""}${u(o.cardinality.value)}`:""}${o.source?` src:${c}`:""}${o.cardinalityReal?` cardReal:${o.cardinalityReal}`:""}${o.timeSelf?` timeSelf:${u(o.timeSelf)}ms`:""}${o.timeLife?` timeLife:${u(o.timeLife)}ms`:""}${l?` ${l}`:""}`);for(const d of o.children??[])this.nodeToCompactString(n,r,`${a} `,d);for(const d of o.childrenCompact??[])this.nodeToCompactString(n,r,`${a} `,d.firstOccurrence,`compacted-occurrences:${d.occurrences}`)}};Cs.MemoryPhysicalQueryPlanLogger=e;function u(s){return s.toLocaleString("en-US",{minimumFractionDigits:0,maximumFractionDigits:3})}return Cs.numberToString=u,Cs}var _M;function tre(){if(_M)return f0;_M=1,Object.defineProperty(f0,"__esModule",{value:!0}),f0.ActorQueryProcessExplainPhysical=void 0;const t=cm(),e=Lt,u=ot,s=UB();let n=class extends t.ActorQueryProcess{constructor(a){super(a)}async test(a){const o=a.context.get(e.KeysInitQuery.explain)||a.context.get(new u.ActionContextKey("explain"));if(o!=="physical"&&o!=="physical-json")throw new Error(`${this.name} can only explain in 'physical' or 'physical-json' mode.`);return!0}async run(a){let{operation:o,context:l}=await this.queryProcessor.parse(a.query,a.context);({operation:o,context:l}=await this.queryProcessor.optimize(o,l));const c=new s.MemoryPhysicalQueryPlanLogger;l=l.set(e.KeysInitQuery.physicalQueryPlanLogger,c);const d=await this.queryProcessor.evaluate(o,l);switch(d.type){case"bindings":await d.bindingsStream.toArray();break;case"quads":await d.quadStream.toArray();break;case"boolean":await d.execute();break;case"void":await d.execute();break}const h=a.context.get(e.KeysInitQuery.explain)??a.context.getSafe(new u.ActionContextKey("explain"));return{result:{explain:!0,type:h,data:h==="physical"?c.toCompactString():c.toJson()}}}};return f0.ActorQueryProcessExplainPhysical=n,f0}var vM;function rre(){return vM||(vM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(tre(),t),u(UB(),t)}(MS)),MS}var FS={},h0={},wM;function nre(){if(wM)return h0;wM=1,Object.defineProperty(h0,"__esModule",{value:!0}),h0.ActorOptimizeQueryOperationPruneEmptySourceOperations=void 0;const t=di(),e=wt(),u=Lt,s=Et(),n=Ot(),r=new n.Factory,a=new s.DataFactory;let o=class M0 extends t.ActorOptimizeQueryOperation{constructor(c){super(c)}async test(c){if(e.ActorQueryOperation.getOperationSource(c.operation))throw new Error(`Actor ${this.name} does not work with top-level operation sources.`);return!0}async run(c){let d=c.operation;const h=[],f=this;n.Util.recurseOperation(d,{[n.Algebra.types.UNION](y){return f.collectMultiOperationInputs(y.input,h,n.Algebra.types.PATTERN),!0},[n.Algebra.types.ALT](y){return f.collectMultiOperationInputs(y.input,h,n.Algebra.types.LINK),!1},[n.Algebra.types.SERVICE](){return!1}});const p=new Set;return await Promise.all(h.map(async y=>{const b=y.type==="link"?r.createPattern(a.variable("?s"),y.iri,a.variable("?o")):y;await this.hasSourceResults(e.ActorQueryOperation.getOperationSource(y),b,c.context)||p.add(y)})),p.size>0&&(this.logDebug(c.context,`Pruning ${p.size} source-specific operations`),d=n.Util.mapOperation(d,{[n.Algebra.types.UNION](y,b){return f.mapMultiOperation(y,p,g=>b.createUnion(g))},[n.Algebra.types.ALT](y,b){return f.mapMultiOperation(y,p,g=>b.createAlt(g))}}),d=n.Util.mapOperation(d,{[n.Algebra.types.PROJECT](y,b){return M0.hasEmptyOperation(y)?{recurse:!1,result:b.createUnion([])}:{recurse:!0,result:y}},[n.Algebra.types.LEFT_JOIN](y){return M0.hasEmptyOperation(y.input[1])?{recurse:!0,result:y.input[0]}:{recurse:!0,result:y}}})),{operation:d,context:c.context}}static hasEmptyOperation(c){let d=!1;return n.Util.recurseOperation(c,{[n.Algebra.types.UNION](h){return h.input.every(f=>M0.hasEmptyOperation(f))&&(d=!0),!1},[n.Algebra.types.ALT](h){return h.input.length===0&&(d=!0),!1},[n.Algebra.types.LEFT_JOIN](h){return M0.hasEmptyOperation(h.input[0])&&(d=!0),!1}}),d}collectMultiOperationInputs(c,d,h){for(const f of c)e.ActorQueryOperation.getOperationSource(f)&&f.type===h&&d.push(f)}mapMultiOperation(c,d,h){const f=c.input.filter(p=>!d.has(p));return f.length===c.input.length?{result:c,recurse:!0}:f.length===0?{result:h([]),recurse:!1}:f.length===1?{result:f[0],recurse:!0}:{result:h(f),recurse:!0}}async hasSourceResults(c,d,h){var p;if((p=c.context)!=null&&p.get(u.KeysQuerySourceIdentify.traverse))return!0;if(this.useAskIfSupported){const y=r.createAsk(d);if(e.ActorQueryOperation.doesShapeAcceptOperation(await c.source.getSelectorShape(h),y))return c.source.queryBoolean(y,h)}const f=c.source.queryBindings(d,h);return new Promise((y,b)=>{f.on("error",b),f.getProperty("metadata",g=>{f.destroy(),y(g.cardinality.value>0)})})}};return h0.ActorOptimizeQueryOperationPruneEmptySourceOperations=o,h0}var SM;function ire(){return SM||(SM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(nre(),t)}(FS)),FS}var qS={},p0={},TM;function are(){if(TM)return p0;TM=1,Object.defineProperty(p0,"__esModule",{value:!0}),p0.ActorQuerySourceIdentifySerialized=void 0;const t=Ly(),e=yB(),u=Wt();let s=class extends t.ActorQuerySourceIdentify{constructor(r){super(r)}async test(r){if(!this.isStringSource(r.querySourceUnidentified))throw new Error(`${this.name} requires a single query source with serialized type to be present in the context.`);return!0}async run(r){return await this.mediatorQuerySourceIdentify.mediate({querySourceUnidentified:{type:"rdfjs",value:await this.getRdfSource(r.context,r.querySourceUnidentified),context:r.querySourceUnidentified.context},context:r.context})}async getRdfSource(r,a){const o=new u.Readable({objectMode:!0});o._read=()=>{},o.push(a.value),o.push(null);const l={context:r,handle:{metadata:{baseIRI:a.baseIRI},data:o,context:r},handleMediaType:a.mediaType},c=await this.mediatorRdfParse.mediate(l);return await(0,e.storeStream)(c.handle.data)}isStringSource(r){return"type"in r?r.type==="serialized":typeof r.value!="string"?!1:"mediaType"in r}};return p0.ActorQuerySourceIdentifySerialized=s,p0}var AM;function sre(){return AM||(AM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(are(),t)}(qS)),qS}var BS={},y0={},EM;function ore(){if(EM)return y0;EM=1,Object.defineProperty(y0,"__esModule",{value:!0}),y0.ActorOptimizeQueryOperationJoinConnected=void 0;const t=di(),e=Ot();let u=class K1 extends t.ActorOptimizeQueryOperation{async test(n){return!0}async run(n){return{operation:e.Util.mapOperation(n.operation,{join(a,o){return{recurse:!1,result:K1.cluster(a,o)}}}),context:n.context}}static cluster(n,r){const a=n.input.map(d=>({inScopeVariables:Object.fromEntries(e.Util.inScopeVariables(d).map(h=>[h.value,!0])),entries:[d]}));let o,l=a;do o=l,l=K1.clusterIteration(o);while(o.length!==l.length);const c=l.map(d=>d.entries.length===1?d.entries[0]:r.createJoin(d.entries));return c.length===1?c[0]:r.createJoin(c,!1)}static clusterIteration(n){const r=[];for(const a of n){let o=!1;for(const l of r)if(K1.haveOverlappingVariables(a.inScopeVariables,l.inScopeVariables)){l.entries=[...l.entries,...a.entries],l.inScopeVariables={...l.inScopeVariables,...a.inScopeVariables},o=!0;break}o||r.push({inScopeVariables:a.inScopeVariables,entries:a.entries})}return r}static haveOverlappingVariables(n,r){for(const a of Object.keys(n))if(r[a])return!0;return!1}};return y0.ActorOptimizeQueryOperationJoinConnected=u,y0}var OM;function ure(){return OM||(OM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(ore(),t)}(BS)),BS}var US={},b0={},RM;function cre(){if(RM)return b0;RM=1,Object.defineProperty(b0,"__esModule",{value:!0}),b0.ActorOptimizeQueryOperationBgpToJoin=void 0;const t=di(),e=Ot();let u=class extends t.ActorOptimizeQueryOperation{async test(n){return!0}async run(n){return{operation:e.Util.mapOperation(n.operation,{bgp(a,o){return{recurse:!1,result:o.createJoin(a.patterns)}}}),context:n.context}}};return b0.ActorOptimizeQueryOperationBgpToJoin=u,b0}var xM;function lre(){return xM||(xM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(cre(),t)}(US)),US}var QS={},m0={},IM;function dre(){if(IM)return m0;IM=1,Object.defineProperty(m0,"__esModule",{value:!0}),m0.ActorOptimizeQueryOperationJoinBgp=void 0;const t=di(),e=Ot();let u=class extends t.ActorOptimizeQueryOperation{async test(n){return!0}async run(n){return{operation:e.Util.mapOperation(n.operation,{join(a,o){return a.input.every(l=>l.type==="bgp")?{recurse:!1,result:o.createBgp(a.input.flatMap(l=>l.patterns))}:{recurse:!1,result:a}}}),context:n.context}}};return m0.ActorOptimizeQueryOperationJoinBgp=u,m0}var PM;function fre(){return PM||(PM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(dre(),t)}(QS)),QS}var HS={},g0={},DM;function hre(){if(DM)return g0;DM=1,Object.defineProperty(g0,"__esModule",{value:!0}),g0.ActorOptimizeQueryOperationAssignSourcesExhaustive=void 0;const t=di(),e=wt(),u=dA(),s=Lt,n=Ot();let r=class extends t.ActorOptimizeQueryOperation{constructor(o){super(o)}async test(o){return!0}async run(o){const l=o.context.get(s.KeysQueryOperation.querySources)??[];if(l.length===0)return{operation:o.operation,context:o.context};if(l.length===1){const c=l[0],d=o.context.get(s.KeysRdfUpdateQuads.destination);if(!d||c.source.referenceValue===(0,u.getDataDestinationValue)(d))try{const h=await c.source.getSelectorShape(o.context);if(e.ActorQueryOperation.doesShapeAcceptOperation(h,o.operation))return{operation:e.ActorQueryOperation.assignOperationSource(o.operation,c),context:o.context}}catch{}}return{operation:this.assignExhaustive(o.operation,l),context:o.context.delete(s.KeysInitQuery.queryString)}}assignExhaustive(o,l){const c=this;return n.Util.mapOperation(o,{[n.Algebra.types.PATTERN](d,h){return l.length===1?{result:e.ActorQueryOperation.assignOperationSource(d,l[0]),recurse:!1}:{result:h.createUnion(l.map(f=>e.ActorQueryOperation.assignOperationSource(d,f))),recurse:!1}},[n.Algebra.types.LINK](d,h){return l.length===1?{result:e.ActorQueryOperation.assignOperationSource(d,l[0]),recurse:!1}:{result:h.createAlt(l.map(f=>e.ActorQueryOperation.assignOperationSource(d,f))),recurse:!1}},[n.Algebra.types.NPS](d,h){return l.length===1?{result:e.ActorQueryOperation.assignOperationSource(d,l[0]),recurse:!1}:{result:h.createAlt(l.map(f=>e.ActorQueryOperation.assignOperationSource(d,f))),recurse:!1}},[n.Algebra.types.SERVICE](d){return{result:d,recurse:!1}},[n.Algebra.types.CONSTRUCT](d,h){return{result:h.createConstruct(c.assignExhaustive(d.input,l),d.template),recurse:!1}},[n.Algebra.types.DELETE_INSERT](d,h){return{result:h.createDeleteInsert(d.delete,d.insert,d.where?c.assignExhaustive(d.where,l):void 0),recurse:!1}}})}};return g0.ActorOptimizeQueryOperationAssignSourcesExhaustive=r,g0}var NM;function pre(){return NM||(NM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(hre(),t)}(HS)),HS}var $S={},_0={},CM;function yre(){if(CM)return _0;CM=1,Object.defineProperty(_0,"__esModule",{value:!0}),_0.ActorOptimizeQueryOperationDescribeToConstructsSubject=void 0;const t=di(),e=Et(),u=Ot(),s=new e.DataFactory,n=new u.Factory;let r=class extends t.ActorOptimizeQueryOperation{constructor(o){super(o)}async test(o){if(o.operation.type!==u.Algebra.types.DESCRIBE)throw new Error(`Actor ${this.name} only supports describe operations, but got ${o.operation.type}`);return!0}async run(o){const l=o.operation,c=l.terms.filter(h=>h.termType!=="Variable").map(h=>{const f=[s.quad(h,s.variable("__predicate"),s.variable("__object"))];return f.forEach(y=>y.type="pattern"),{input:{type:u.Algebra.types.BGP,patterns:f},template:f,type:"construct"}});if(c.length!==l.terms.length){let h=[];l.terms.filter(f=>f.termType==="Variable").forEach((f,p)=>{const y=[s.quad(f,s.variable(`__predicate${p}`),s.variable(`__object${p}`))];y.forEach(b=>b.type="pattern"),h=[...h,...y]}),c.push({input:{type:u.Algebra.types.JOIN,input:[l.input,{type:u.Algebra.types.BGP,patterns:h}]},template:h,type:u.Algebra.types.CONSTRUCT})}return{operation:n.createUnion(c,!1),context:o.context}}};return _0.ActorOptimizeQueryOperationDescribeToConstructsSubject=r,_0}var jM;function bre(){return jM||(jM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(yre(),t)}($S)),$S}var mre=function(t){const e=new(WV()).LoggerVoid,u=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-init/^3.0.0/components/ActorInit.jsonld#ActorInit_default_bus"}),s=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-context-preprocess/^3.0.0/components/ActorContextPreprocess.jsonld#ActorContextPreprocess_default_bus"}),n=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-hash-bindings/^3.0.0/components/ActorHashBindings.jsonld#ActorHashBindings_default_bus"}),r=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-hash-quads/^3.0.0/components/ActorHashQuads.jsonld#ActorHashQuads_default_bus"}),a=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-optimize-query-operation/^3.0.0/components/ActorOptimizeQueryOperation.jsonld#ActorOptimizeQueryOperation_default_bus"}),o=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-query-parse/^3.0.0/components/ActorQueryParse.jsonld#ActorQueryParse_default_bus"}),l=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-query-result-serialize/^3.0.0/components/ActorQueryResultSerialize.jsonld#ActorQueryResultSerialize_default_bus"}),c=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-query-source-identify-hypermedia/^3.0.0/components/ActorQuerySourceIdentifyHypermedia.jsonld#ActorQuerySourceIdentifyHypermedia_default_bus"}),d=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-dereference/^3.0.0/components/ActorDereference.jsonld#ActorDereference_default_bus"}),h=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-dereference-rdf/^3.0.0/components/ActorDereferenceRdf.jsonld#ActorDereferenceRdf_default_bus"}),f=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-join-entries-sort/^3.0.0/components/ActorRdfJoinEntriesSort.jsonld#ActorRdfJoinEntriesSort_default_bus"}),p=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-join-selectivity/^3.0.0/components/ActorRdfJoinSelectivity.jsonld#ActorRdfJoinSelectivity_default_bus"}),y=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-metadata/^3.0.0/components/ActorRdfMetadata.jsonld#ActorRdfMetadata_default_bus"}),b=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-metadata-accumulate/^3.0.0/components/ActorRdfMetadataAccumulate.jsonld#ActorRdfMetadataAccumulate_default_bus"}),g=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-metadata-extract/^3.0.0/components/ActorRdfMetadataExtract.jsonld#ActorRdfMetadataExtract_default_bus"}),m=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-parse/^3.0.0/components/ActorRdfParse.jsonld#ActorRdfParse_default_bus"}),v=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-parse-html/^3.0.0/components/ActorRdfParseHtml.jsonld#ActorRdfParseHtml_default_bus"}),_=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-resolve-hypermedia-links/^3.0.0/components/ActorRdfResolveHypermediaLinks.jsonld#ActorRdfResolveHypermediaLinks_default_bus"}),w=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-serialize/^3.0.0/components/ActorRdfSerialize.jsonld#ActorRdfSerialize_default_bus"}),S=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-resolve-hypermedia-links-queue/^3.0.0/components/ActorRdfResolveHypermediaLinksQueue.jsonld#ActorRdfResolveHypermediaLinksQueue_default_bus"}),A=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-update-hypermedia/^3.0.0/components/ActorRdfUpdateHypermedia.jsonld#ActorRdfUpdateHypermedia_default_bus"}),D=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-update-quads/^3.0.0/components/ActorRdfUpdateQuads.jsonld#ActorRdfUpdateQuads_default_bus"}),L=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-http/^3.0.0/components/ActorHttp.jsonld#ActorHttp_default_bus"}),O=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-http/^3.0.0/components/ActorHttp.jsonld#ActorHttp_fallback_bus"}),E=new(wt()).BusQueryOperation({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-query-operation/^3.0.0/components/ActorQueryOperation.jsonld#ActorQueryOperation_default_bus"}),P=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-query-process/^3.0.0/components/ActorQueryProcess.jsonld#ActorQueryProcess_default_bus"}),M=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-query-source-identify/^3.0.0/components/ActorQuerySourceIdentify.jsonld#ActorQuerySourceIdentify_default_bus"}),U=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-join/^3.0.0/components/ActorRdfJoin.jsonld#ActorRdfJoin_default_bus"}),j=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-http-invalidate/^3.0.0/components/ActorHttpInvalidate.jsonld#ActorHttpInvalidate_default_bus"}),q=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-merge-bindings-context/^3.0.0/components/ActorMergeBindingsContext.jsonld#ActorMergeBindingsContext_default_bus"});new(Ak()).ActorContextPreprocessConvertShortcuts({contextKeyShortcuts:{baseIRI:"@comunica/actor-init-query:baseIRI",datetime:"@comunica/actor-http-memento:datetime",destination:"@comunica/bus-rdf-update-quads:destination",distinctConstruct:"@comunica/actor-init-query:distinctConstruct",explain:"@comunica/actor-init-query:explain",extensionFunctionCreator:"@comunica/actor-init-query:extensionFunctionCreator",extensionFunctions:"@comunica/actor-init-query:extensionFunctions",fetch:"@comunica/bus-http:fetch",functionArgumentsCache:"@comunica/actor-init-query:functionArgumentsCache",httpAuth:"@comunica/bus-http:auth",httpBodyTimeout:"@comunica/bus-http:http-body-timeout",httpIncludeCredentials:"@comunica/bus-http:include-credentials",httpProxyHandler:"@comunica/actor-http-proxy:httpProxyHandler",httpRetryCount:"@comunica/bus-http:http-retry-count",httpRetryDelay:"@comunica/bus-http:http-retry-delay",httpRetryOnServerError:"@comunica/bus-http:http-retry-on-server-error",httpTimeout:"@comunica/bus-http:http-timeout",initialBindings:"@comunica/actor-init-query:initialBindings",lenient:"@comunica/actor-init-query:lenient",log:"@comunica/core:log",noCache:"@comunica/actor-init-query:noCache",queryFormat:"@comunica/actor-init-query:queryFormat",queryTimestamp:"@comunica/actor-init-query:queryTimestamp",readOnly:"@comunica/bus-query-operation:readOnly",recoverBrokenLinks:"@comunica/bus-http-wayback:recover-broken-links",sources:"@comunica/actor-init-query:querySourcesUnidentified",traverse:"@comunica/bus-query-source-identify:traverse",unionDefaultGraph:"@comunica/bus-query-operation:unionDefaultGraph"},name:"urn:comunica:default:context-preprocess/actors#convert-shortcuts",bus:s}),new(Ok()).ActorContextPreprocessSetDefaults({logger:e,name:"urn:comunica:default:context-preprocess/actors#set-defaults",bus:s}),new(xk()).ActorContextPreprocessSourceToDestination({name:"urn:comunica:default:context-preprocess/actors#source-to-destination",bus:s});const $=new(dq()).ActorContextPreprocessQuerySourceSkolemize({name:"urn:comunica:default:context-preprocess/actors#query-source-skolemize",bus:s}),Z=new(ER()).MediatorCombinePipeline({name:"urn:comunica:default:context-preprocess/mediators#main",bus:s});new(Lk()).ActorHashBindingsSha1({name:"urn:comunica:default:hash-bindings/actors#sha1",bus:n});const X=new(cn()).MediatorRace({name:"urn:comunica:default:hash-bindings/mediators#main",bus:n});new(Uk()).ActorHashQuadsSha1({name:"urn:comunica:default:hash-quads/actors#sha1",bus:r});const le=new(cn()).MediatorRace({name:"urn:comunica:default:hash-quads/mediators#main",bus:r});new($k()).ActorOptimizeQueryOperationRewriteCopy({name:"urn:comunica:default:optimize-query-operation/actors#rewrite-copy",bus:a}),new(kk()).ActorOptimizeQueryOperationRewriteMove({name:"urn:comunica:default:optimize-query-operation/actors#rewrite-move",bus:a}),new(Gk()).ActorOptimizeQueryOperationRewriteAdd({name:"urn:comunica:default:optimize-query-operation/actors#rewrite-add",bus:a});const K=new(Jk()).ActorOptimizeQueryOperationGroupSources({name:"urn:comunica:default:optimize-query-operation/actors#group-sources",bus:a});new(Kk()).ActorOptimizeQueryOperationConstructDistinct({name:"urn:comunica:default:optimize-query-operation/actors#construct-distinct",bus:a});const he=new(ER()).MediatorCombinePipeline({filterErrors:!0,name:"urn:comunica:default:optimize-query-operation/mediators#main",bus:a});new(ez()).ActorQueryParseSparql({prefixes:{dbpedia:"http://dbpedia.org/resource/","dbpedia-owl":"http://dbpedia.org/ontology/",dbpprop:"http://dbpedia.org/property/",dc:"http://purl.org/dc/terms/",dc11:"http://purl.org/dc/elements/1.1/",dcterms:"http://purl.org/dc/terms/",foaf:"http://xmlns.com/foaf/0.1/",geo:"http://www.w3.org/2003/01/geo/wgs84_pos#",owl:"http://www.w3.org/2002/07/owl#",rdf:"http://www.w3.org/1999/02/22-rdf-syntax-ns#",rdfs:"http://www.w3.org/2000/01/rdf-schema#",schema:"http://schema.org/",skos:"http://www.w3.org/2008/05/skos#",xsd:"http://www.w3.org/2001/XMLSchema#"},name:"urn:comunica:default:query-parse/actors#sparql",bus:o}),new(OG()).ActorQueryParseGraphql({name:"urn:comunica:default:query-parse/actors#graphql",bus:o});const Re=new(cn()).MediatorRace({name:"urn:comunica:default:query-parse/mediators#main",bus:o});new(qG()).ActorQueryResultSerializeJson({mediaTypePriorities:{"application/json":1},mediaTypeFormats:{"application/json":"https://comunica.linkeddatafragments.org/#results_JSON"},name:"urn:comunica:default:query-result-serialize/actors#json",bus:l}),new(UG()).ActorQueryResultSerializeSimple({mediaTypePriorities:{simple:.9},mediaTypeFormats:{simple:"https://comunica.linkeddatafragments.org/#results_simple"},name:"urn:comunica:default:query-result-serialize/actors#simple",bus:l}),new(HG()).ActorQueryResultSerializeSparqlCsv({mediaTypePriorities:{"text/csv":.75},mediaTypeFormats:{"text/csv":"http://www.w3.org/ns/formats/SPARQL_Results_CSV"},name:"urn:comunica:default:query-result-serialize/actors#csv",bus:l}),new(kG()).ActorQueryResultSerializeSparqlTsv({mediaTypePriorities:{"text/tab-separated-values":.75},mediaTypeFormats:{"text/tab-separated-values":"http://www.w3.org/ns/formats/SPARQL_Results_TSV"},name:"urn:comunica:default:query-result-serialize/actors#sparql-tsv",bus:l}),new(WG()).ActorQueryResultSerializeSparqlXml({mediaTypePriorities:{"application/sparql-results+xml":.8},mediaTypeFormats:{"application/sparql-results+xml":"http://www.w3.org/ns/formats/SPARQL_Results_XML"},name:"urn:comunica:default:query-result-serialize/actors#sparql-xml",bus:l}),new(XG()).ActorQueryResultSerializeTable({columnWidth:50,mediaTypePriorities:{table:.6},mediaTypeFormats:{table:"https://comunica.linkeddatafragments.org/#results_table"},name:"urn:comunica:default:query-result-serialize/actors#table",bus:l}),new(oW()).ActorQueryResultSerializeTree({mediaTypePriorities:{tree:.5},mediaTypeFormats:{tree:"https://comunica.linkeddatafragments.org/#results_tree"},name:"urn:comunica:default:query-result-serialize/actors#tree",bus:l});const ie=new(cn()).MediatorRace({name:"urn:comunica:default:query-result-serialize/mediators#serialize",bus:l}),ae=new(xa()).MediatorCombineUnion({field:"mediaTypes",name:"urn:comunica:default:query-result-serialize/mediators#mediaType",bus:l}),Ee=new(xa()).MediatorCombineUnion({field:"mediaTypeFormats",name:"urn:comunica:default:query-result-serialize/mediators#mediaTypeFormat",bus:l}),De=new(il()).MediatorNumber({field:"filterFactor",type:"max",ignoreErrors:!0,name:"urn:comunica:default:query-source-identify-hypermedia/mediators#main",bus:c}),ge=new(hW()).ActorDereferenceFallback({name:"urn:comunica:default:dereference/actors#fallback",bus:d}),de=new(cn()).MediatorRace({name:"urn:comunica:default:dereference/mediators#main",bus:d}),fe=new(cn()).MediatorRace({name:"urn:comunica:default:dereference-rdf/mediators#main",bus:h});new(mW()).ActorRdfJoinEntriesSortCardinality({name:"urn:comunica:default:rdf-join-entries-sort/actors#cardinality",bus:f});const H=new(cn()).MediatorRace({name:"urn:comunica:default:rdf-join-entries-sort/mediators#main",bus:f});new(wW()).ActorRdfJoinSelectivityVariableCounting({name:"urn:comunica:default:rdf-join-selectivity/actors#variable-counting",bus:p});const N=new(il()).MediatorNumber({field:"accuracy",type:"max",ignoreErrors:!0,name:"urn:comunica:default:rdf-join-selectivity/mediators#main",bus:p});new(AW()).ActorRdfMetadataPrimaryTopic({metadataToData:!1,dataToMetadataOnInvalidMetadataGraph:!0,name:"urn:comunica:default:rdf-metadata/actors#primary-topic",bus:y}),new(OW()).ActorRdfMetadataAll({name:"urn:comunica:default:rdf-metadata/actors#all",bus:y});const R=new(cn()).MediatorRace({name:"urn:comunica:default:rdf-metadata/mediators#main",bus:y});new(IW()).ActorRdfMetadataAccumulateCanContainUndefs({name:"urn:comunica:default:rdf-metadata-accumulate/actors#cancontainundefs",bus:b}),new(DW()).ActorRdfMetadataAccumulateCardinality({name:"urn:comunica:default:rdf-metadata-accumulate/actors#cardinality",bus:b}),new(CW()).ActorRdfMetadataAccumulatePageSize({name:"urn:comunica:default:rdf-metadata-accumulate/actors#pagesize",bus:b}),new(LW()).ActorRdfMetadataAccumulateRequestTime({name:"urn:comunica:default:rdf-metadata-accumulate/actors#requesttime",bus:b});const T=new(xa()).MediatorCombineUnion({field:"metadata",name:"urn:comunica:default:rdf-metadata-accumulate/mediators#main",bus:b});new(BW()).ActorRdfMetadataExtractHydraControls({name:"urn:comunica:default:rdf-metadata-extract/actors#hydra-controls",bus:g}),new(QW()).ActorRdfMetadataExtractHydraCount({predicates:["http://www.w3.org/ns/hydra/core#totalItems","http://rdfs.org/ns/void#triples"],name:"urn:comunica:default:rdf-metadata-extract/actors#hydra-count",bus:g}),new($W()).ActorRdfMetadataExtractHydraPagesize({predicates:["http://www.w3.org/ns/hydra/core#itemsPerPage"],name:"urn:comunica:default:rdf-metadata-extract/actors#hydra-pagesize",bus:g}),new(kW()).ActorRdfMetadataExtractRequestTime({name:"urn:comunica:default:rdf-metadata-extract/actors#request-time",bus:g}),new(GW()).ActorRdfMetadataExtractAllowHttpMethods({name:"urn:comunica:default:rdf-metadata-extract/actors#allow-http-methods",bus:g}),new(JW()).ActorRdfMetadataExtractPutAccepted({name:"urn:comunica:default:rdf-metadata-extract/actors#put-accepted",bus:g}),new(KW()).ActorRdfMetadataExtractPatchSparqlUpdate({name:"urn:comunica:default:rdf-metadata-extract/actors#patch-sparql-update",bus:g}),new(ZW()).ActorRdfMetadataExtractSparqlService({inferHttpsEndpoint:!0,name:"urn:comunica:default:rdf-metadata-extract/actors#sparql-service",bus:g});const x=new(xa()).MediatorCombineUnion({filterErrors:!0,field:"metadata",name:"urn:comunica:default:rdf-metadata-extract/mediators#main",bus:g});new(RJ()).ActorRdfParseN3({mediaTypePriorities:{"application/n-quads":1,"application/n-triples":.8,"application/trig":.95,"text/n3":.35,"text/turtle":.6},mediaTypeFormats:{"application/n-quads":"http://www.w3.org/ns/formats/N-Quads","application/n-triples":"http://www.w3.org/ns/formats/N-Triples","application/trig":"http://www.w3.org/ns/formats/TriG","text/n3":"http://www.w3.org/ns/formats/N3","text/turtle":"http://www.w3.org/ns/formats/Turtle"},priorityScale:1,name:"urn:comunica:default:rdf-parse/actors#n3",bus:m}),new(FJ()).ActorRdfParseRdfXml({mediaTypePriorities:{"application/rdf+xml":1},mediaTypeFormats:{"application/rdf+xml":"http://www.w3.org/ns/formats/RDF_XML"},priorityScale:.5,name:"urn:comunica:default:rdf-parse/actors#rdfxml",bus:m}),new(rX()).ActorRdfParseXmlRdfa({mediaTypePriorities:{"application/xml":1,"image/svg+xml":1,"text/xml":1},mediaTypeFormats:{"application/xml":"http://www.w3.org/ns/formats/RDFa","image/svg+xml":"http://www.w3.org/ns/formats/RDFa","text/xml":"http://www.w3.org/ns/formats/RDFa"},priorityScale:.3,name:"urn:comunica:default:rdf-parse/actors#xmlrdfa",bus:m}),new(oX()).ActorRdfParseShaclc({mediaTypePriorities:{"text/shaclc":1,"text/shaclc-ext":.5},mediaTypeFormats:{"text/shaclc":"http://www.w3.org/ns/formats/Shaclc","text/shaclc-ext":"http://www.w3.org/ns/formats/ShaclcExtended"},priorityScale:.1,name:"urn:comunica:default:rdf-parse/actors#shaclc",bus:m});const B=new(cn()).MediatorRace({name:"urn:comunica:default:rdf-parse/mediators#parse",bus:m}),k=new(xa()).MediatorCombineUnion({field:"mediaTypes",name:"urn:comunica:default:rdf-parse/mediators#mediaType",bus:m});new(lX()).ActorRdfParseHtml({busRdfParseHtml:v,mediaTypePriorities:{"application/xhtml+xml":.9,"text/html":1},mediaTypeFormats:{"application/xhtml+xml":"http://www.w3.org/ns/formats/HTML","text/html":"http://www.w3.org/ns/formats/HTML"},priorityScale:.2,name:"urn:comunica:default:rdf-parse/actors#html",bus:m}),new(wX()).ActorRdfParseHtmlMicrodata({name:"urn:comunica:default:rdf-parse-html/actors#microdata",bus:v}),new(TX()).ActorRdfParseHtmlRdfa({name:"urn:comunica:default:rdf-parse-html/actors#rdfa",bus:v}),new(RX()).ActorRdfResolveHypermediaLinksNext({name:"urn:comunica:default:rdf-resolve-hypermedia-links/actors#next",bus:_});const V=new(cn()).MediatorRace({name:"urn:comunica:default:rdf-resolve-hypermedia-links/mediators#main",bus:_});new(DX()).ActorRdfSerializeN3({mediaTypePriorities:{"application/n-quads":1,"application/n-triples":.8,"application/trig":.95,"text/n3":.35,"text/turtle":.6},mediaTypeFormats:{"application/n-quads":"http://www.w3.org/ns/formats/N-Quads","application/n-triples":"http://www.w3.org/ns/formats/N-Triples","application/trig":"http://www.w3.org/ns/formats/TriG","text/n3":"http://www.w3.org/ns/formats/N3","text/turtle":"http://www.w3.org/ns/formats/Turtle"},name:"urn:comunica:default:rdf-serialize/actors#n3",bus:w}),new(MX()).ActorRdfSerializeJsonLd({jsonStringifyIndentSpaces:2,mediaTypePriorities:{"application/ld+json":1},mediaTypeFormats:{"application/ld+json":"http://www.w3.org/ns/formats/JSON-LD"},priorityScale:.9,name:"urn:comunica:default:rdf-serialize/actors#jsonld",bus:w}),new(ZX()).ActorRdfSerializeShaclc({mediaTypePriorities:{"text/shaclc":1,"text/shaclc-ext":.5},mediaTypeFormats:{"text/shaclc":"http://www.w3.org/ns/formats/Shaclc","text/shaclc-ext":"http://www.w3.org/ns/formats/ShaclcExtended"},priorityScale:.1,name:"urn:comunica:default:rdf-serialize/actors#shaclc",bus:w});const J=new(cn()).MediatorRace({name:"urn:comunica:default:rdf-serialize/mediators#serialize",bus:w}),z=new(xa()).MediatorCombineUnion({field:"mediaTypes",name:"urn:comunica:default:rdf-serialize/mediators#mediaType",bus:w}),Y=new(xa()).MediatorCombineUnion({field:"mediaTypeFormats",name:"urn:comunica:default:rdf-serialize/mediators#mediaTypeFormat",bus:w});new(aK()).ActorRdfResolveHypermediaLinksQueueFifo({name:"urn:comunica:default:rdf-resolve-hypermedia-links-queue/actors#fifo",bus:S});const re=new(cn()).MediatorRace({name:"urn:comunica:default:rdf-resolve-hypermedia-links-queue/mediators#main",bus:S}),ce=new(cn()).MediatorRace({name:"urn:comunica:default:rdf-update-hypermedia/mediators#main",bus:A});new(dK()).ActorRdfUpdateQuadsRdfJsStore({name:"urn:comunica:default:rdf-update-quads/actors#rdfjs-store",bus:D});const Te=new(cn()).MediatorRace({name:"urn:comunica:default:rdf-update-quads/mediators#main",bus:D}),xe=new(_K()).ActorHttpFetch({agentOptions:{keepAlive:!0,maxSockets:5},name:"urn:comunica:default:http/actors#fetch",bus:L}),Le=new(il()).MediatorNumber({field:"time",type:"min",ignoreErrors:!0,name:"urn:comunica:default:http/mediators#no-fallback",bus:L}),qe=new(il()).MediatorNumber({field:"time",type:"min",ignoreErrors:!0,name:"urn:comunica:default:http/mediators#main",bus:O});new(wK()).ActorQueryOperationSource({name:"urn:comunica:default:query-operation/actors#source",bus:E});const G=new(il()).MediatorNumber({field:"httpRequests",type:"min",ignoreErrors:!0,name:"urn:comunica:default:query-operation/mediators#main",bus:E}),F=new(cn()).MediatorRace({name:"urn:comunica:default:query-process/mediators#main",bus:P}),Q=new(cn()).MediatorRace({name:"urn:comunica:default:query-source-identify/mediators#main",bus:M}),te=new(TK()).MediatorJoinCoefficientsFixed({cpuWeight:10,memoryWeight:1,timeWeight:2,ioWeight:10,name:"urn:comunica:default:rdf-join/mediators#main",bus:U}),me=new(N1()).ActorHttpInvalidateListenable({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-context-preprocess-query-source-identify/^3.0.0/components/ActorContextPreprocessQuerySourceIdentify.jsonld#IActorContextPreprocessQuerySourceIdentifyArgs_default_invalidator",bus:j}),Oe=new(OK()).MediatorAll({name:"urn:comunica:default:http-invalidate/mediators#main",bus:j}),Ne=new(N1()).ActorHttpInvalidateListenable({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-rdf-update-quads-hypermedia/^3.0.0/components/ActorRdfUpdateQuadsHypermedia.jsonld#IActorRdfUpdateQuadsHypermediaArgs_default_invalidator",bus:j}),We=new(N1()).ActorHttpInvalidateListenable({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-query-result-serialize-sparql-json/^3.0.0/components/ActionObserverHttp.jsonld#IActionObserverHttpArgs_default_invalidator",bus:j}),Ve=new(N1()).ActorHttpInvalidateListenable({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-query-result-serialize-stats/^3.0.0/components/ActionObserverHttp.jsonld#IActionObserverHttpArgs_default_invalidator",bus:j}),pe=new(xa()).MediatorCombineUnion({field:"mergeHandlers",name:"urn:comunica:default:merge-bindings-context/mediators#main",bus:q});new(DK()).ActorRdfJoinSingle({mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#inner-single",bus:U}),new(CK()).ActorRdfJoinMultiEmpty({mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#inner-multi-empty",bus:U}),new(LK()).ActorRdfJoinMultiBindSource({selectivityModifier:1e-4,blockSize:16,mediatorJoinEntriesSort:H,mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#inner-multi-bind-source",bus:U}),new(HK()).ActorRdfJoinHash({mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#inner-hash",bus:U}),new(VK()).ActorRdfJoinSymmetricHash({mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#inner-symmetric-hash",bus:U}),new(zK()).ActorRdfJoinNestedLoop({mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#inner-nested-loop",bus:U}),new(WK()).ActorRdfJoinMinusHash({mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#minus-hash",bus:U}),new(KK()).ActorRdfJoinMinusHashUndef({mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#minus-hash-undef",bus:U}),new(C1()).ActorRdfJoinOptionalHash({canHandleUndefs:!1,blocking:!1,mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#optional-hash-def-nonblocking",bus:U}),new(C1()).ActorRdfJoinOptionalHash({canHandleUndefs:!1,blocking:!0,mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#optional-hash-def-blocking",bus:U}),new(C1()).ActorRdfJoinOptionalHash({canHandleUndefs:!0,blocking:!1,mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#optional-hash-undef-nonblocking",bus:U}),new(C1()).ActorRdfJoinOptionalHash({canHandleUndefs:!0,blocking:!0,mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#optional-hash-undef-blocking",bus:U}),new(rY()).ActorRdfJoinOptionalNestedLoop({mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#optional-nested-loop",bus:U}),new(sY()).ActorDereferenceRdfParse({mediatorDereference:de,mediatorParse:B,mediatorParseMediatypes:k,mediaMappings:{htm:"text/html",html:"text/html",json:"application/json",jsonld:"application/ld+json",n3:"text/n3",nq:"application/n-quads",nquads:"application/n-quads",nt:"application/n-triples",ntriples:"application/n-triples",owl:"application/rdf+xml",rdf:"application/rdf+xml",rdfxml:"application/rdf+xml",shaclc:"text/shaclc",shaclce:"text/shaclc-ext",shc:"text/shaclc",shce:"text/shaclc-ext",svg:"image/svg+xml",svgz:"image/svg+xml",trig:"application/trig",ttl:"text/turtle",turtle:"text/turtle",xht:"application/xhtml+xml",xhtml:"application/xhtml+xml",xml:"application/xml"},name:"urn:comunica:default:dereference-rdf/actors#parse",bus:h}),new(cY()).ActorRdfParseHtmlScript({mediatorRdfParseMediatypes:k,mediatorRdfParseHandle:B,name:"urn:comunica:default:rdf-parse-html/actors#script",bus:v}),new(dY()).ActorQueryResultSerializeRdf({mediatorRdfSerialize:J,mediatorMediaTypeCombiner:z,mediatorMediaTypeFormatCombiner:Y,name:"urn:comunica:default:query-result-serialize/actors#rdf",bus:l}),new(hY()).ActorHttpWayback({mediatorHttp:Le,name:"urn:comunica:default:http/actors#wayback",bus:O}),new(jY()).ActorRdfParseJsonLd({mediatorHttp:qe,mediaTypePriorities:{"application/json":.15,"application/ld+json":1},mediaTypeFormats:{"application/json":"http://www.w3.org/ns/formats/JSON-LD","application/ld+json":"http://www.w3.org/ns/formats/JSON-LD"},priorityScale:.9,name:"urn:comunica:default:rdf-parse/actors#jsonld",bus:m}),new(FY()).ActorRdfUpdateHypermediaPatchSparqlUpdate({mediatorHttp:qe,name:"urn:comunica:default:rdf-update-hypermedia/actors#patch-sparql-update",bus:A}),new(BY()).ActorRdfUpdateHypermediaPutLdp({mediatorHttp:qe,mediatorRdfSerializeMediatypes:z,mediatorRdfSerialize:J,name:"urn:comunica:default:rdf-update-hypermedia/actors#put-ldp",bus:A}),new(WY()).ActorRdfUpdateHypermediaSparql({mediatorHttp:qe,checkUrlSuffixSparql:!0,checkUrlSuffixUpdate:!0,name:"urn:comunica:default:rdf-update-hypermedia/actors#sparql",bus:A}),new(XY()).ActorQueryOperationBgpJoin({mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#bgp",bus:E}),new(YY()).ActorQueryOperationAsk({mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#ask",bus:E}),new(G7()).ActorQueryOperationConstruct({mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#construct",bus:E}),new(tZ()).ActorQueryOperationDistinctHash({mediatorHashBindings:X,mediatorHashQuads:le,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#distinct",bus:E}),new(nZ()).ActorQueryOperationFromQuad({mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#from",bus:E}),new(aZ()).ActorQueryOperationProject({mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#project",bus:E}),new(oZ()).ActorQueryOperationReducedHash({mediatorHashBindings:X,cacheSize:100,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#reduced",bus:E}),new(cZ()).ActorQueryOperationSlice({mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#slice",bus:E}),new(J7()).ActorQueryOperationUnion({mediatorRdfMetadataAccumulate:T,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#union",bus:E}),new(hZ()).ActorQueryOperationPathAlt({mediatorRdfMetadataAccumulate:T,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#path-alt",bus:E}),new(yZ()).ActorQueryOperationPathInv({mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#path-inv",bus:E}),new(mZ()).ActorQueryOperationPathNps({mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#path-nps",bus:E}),new(_Z()).ActorQueryOperationPathLink({mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#path-link",bus:E}),new(wZ()).ActorQueryOperationClear({mediatorUpdateQuads:Te,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#update-clear",bus:E}),new(TZ()).ActorQueryOperationUpdateCompositeUpdate({mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#update-composite",bus:E}),new(EZ()).ActorQueryOperationCreate({mediatorUpdateQuads:Te,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#update-create",bus:E}),new(RZ()).ActorQueryOperationDrop({mediatorUpdateQuads:Te,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#update-drop",bus:E}),new(IZ()).ActorQueryOperationLoad({mediatorUpdateQuads:Te,mediatorQuerySourceIdentify:Q,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#update-load",bus:E}),new(DZ()).ActorQueryOperationJoin({mediatorJoin:te,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#join",bus:E}),new(CZ()).ActorQueryOperationMinus({mediatorJoin:te,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#minus",bus:E}),new(LZ()).ActorQueryOperationPathSeq({mediatorJoin:te,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#path-seq",bus:E}),new(FZ()).ActorRdfJoinMultiSmallest({mediatorJoinEntriesSort:H,mediatorJoin:te,mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#inner-multi-smallest",bus:U}),new(UZ()).ActorRdfJoinMultiSmallestFilterBindings({selectivityModifier:1e-4,blockSize:64,mediatorJoinEntriesSort:H,mediatorJoin:te,mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#inner-multi-smallest-filter-bindings",bus:U});const we=new(HZ()).ActorOptimizeQueryOperationFilterPushdown({aggressivePushdown:!1,maxIterations:10,splitConjunctive:!0,mergeConjunctive:!0,pushIntoLeftJoins:!0,pushEqualityIntoPatterns:!0,name:"urn:comunica:default:optimize-query-operation/actors#filter-pushdown",bus:a,beforeActors:[K]});new(VZ()).ActorDereferenceHttp({mediatorHttp:qe,maxAcceptHeaderLength:1024,maxAcceptHeaderLengthBrowser:128,name:"urn:comunica:default:dereference/actors#http",bus:d,beforeActors:[ge]}),new(GZ()).ActorHttpProxy({mediatorHttp:qe,name:"urn:comunica:default:http/actors#proxy",bus:L,beforeActors:[xe]}),new(JZ()).ActorContextPreprocessQuerySourceIdentify({cacheSize:100,httpInvalidator:me,mediatorQuerySourceIdentify:Q,mediatorContextPreprocess:Z,name:"urn:comunica:default:context-preprocess/actors#query-source-identify",bus:s,beforeActors:[$]});const W=new aT.ActorInitQuery({mediatorQueryProcess:F,mediatorQueryResultSerialize:ie,mediatorQueryResultSerializeMediaTypeCombiner:ae,mediatorQueryResultSerializeMediaTypeFormatCombiner:Ee,mediatorHttpInvalidate:Oe,defaultQueryInputFormat:"sparql",allowNoSources:!1,name:"urn:comunica:default:init/actors#query",bus:u});new(KZ()).ActorRdfUpdateQuadsHypermedia({cacheSize:100,httpInvalidator:Ne,mediatorDereferenceRdf:fe,mediatorMetadata:R,mediatorMetadataExtract:x,mediatorRdfUpdateHypermedia:ce,name:"urn:comunica:default:rdf-update-quads/actors#hypermedia",bus:D});const Se=new(w5()).ActionObserverHttp({httpInvalidator:We,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-query-result-serialize-sparql-json/^3.0.0/components/ActorQueryResultSerializeSparqlJson.jsonld#ActorQueryResultSerializeSparqlJson_default_observer",bus:L}),Ae=new(E5()).ActionObserverHttp({httpInvalidator:Ve,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-query-result-serialize-stats/^3.0.0/components/ActorQueryResultSerializeStats.jsonld#ActorQueryResultSerializeStats_default_observer",bus:L});new(see()).ActorQuerySourceIdentifyHypermediaQpf({mediatorMetadata:R,mediatorMetadataExtract:x,mediatorDereferenceRdf:fe,mediatorMergeBindingsContext:pe,subjectUri:"http://www.w3.org/1999/02/22-rdf-syntax-ns#subject",predicateUri:"http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate",objectUri:"http://www.w3.org/1999/02/22-rdf-syntax-ns#object",graphUri:"http://www.w3.org/ns/sparql-service-description#graph",name:"urn:comunica:default:query-source-identify-hypermedia/actors#qpf",bus:c}),new(uee()).ActorQuerySourceIdentifyHypermediaSparql({mediatorHttp:qe,mediatorMergeBindingsContext:pe,checkUrlSuffix:!0,forceHttpGet:!1,cacheSize:1024,bindMethod:"values",countTimeout:3e3,name:"urn:comunica:default:rdf-resolve-quad-pattern/actors#sparql",bus:c}),new(Aee()).ActorQuerySourceIdentifyHypermediaNone({mediatorMergeBindingsContext:pe,name:"urn:comunica:default:query-source-identify-hypermedia/actors#none",bus:c}),new(dte()).ActorQueryOperationExtend({mediatorMergeBindingsContext:pe,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#extend",bus:E}),new(hte()).ActorQueryOperationFilter({mediatorMergeBindingsContext:pe,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#filter",bus:E}),new(bte()).ActorQueryOperationGroup({mediatorHashBindings:X,mediatorMergeBindingsContext:pe,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#group",bus:E}),new(gte()).ActorQueryOperationLeftJoin({mediatorJoin:te,mediatorMergeBindingsContext:pe,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#leftjoin",bus:E}),new(vte()).ActorQueryOperationNop({mediatorMergeBindingsContext:pe,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#nop",bus:E}),new(Tte()).ActorQueryOperationOrderBy({mediatorMergeBindingsContext:pe,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#orderby",bus:E}),new(Ete()).ActorQueryOperationService({forceSparqlEndpoint:!1,mediatorMergeBindingsContext:pe,mediatorQuerySourceIdentify:Q,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#service",bus:E}),new(Rte()).ActorQueryOperationValues({mediatorMergeBindingsContext:pe,name:"urn:comunica:default:query-operation/actors#values",bus:E}),new(Ite()).ActorQueryOperationPathOneOrMore({mediatorMergeBindingsContext:pe,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#path-one-or-more",bus:E}),new(Dte()).ActorQueryOperationPathZeroOrMore({mediatorMergeBindingsContext:pe,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#path-zero-or-more",bus:E}),new(Cte()).ActorQueryOperationPathZeroOrOne({mediatorMergeBindingsContext:pe,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#path-zero-or-one",bus:E}),new(Lte()).ActorQueryOperationUpdateDeleteInsert({mediatorUpdateQuads:Te,mediatorMergeBindingsContext:pe,mediatorQueryOperation:G,name:"urn:comunica:default:query-operation/actors#update-delete-insert",bus:E});const je=new(qte()).ActorQueryProcessSequential({mediatorContextPreprocess:Z,mediatorQueryParse:Re,mediatorOptimizeQueryOperation:he,mediatorQueryOperation:G,mediatorMergeBindingsContext:pe,name:"urn:comunica:default:query-process/actors#sequential",bus:P}),He=new(kte()).ActorQuerySourceIdentifyHypermedia({cacheSize:100,maxIterators:64,aggregateTraversalStore:!0,mediatorDereferenceRdf:fe,mediatorMetadata:R,mediatorMetadataExtract:x,mediatorMetadataAccumulate:T,mediatorQuerySourceIdentifyHypermedia:De,mediatorRdfResolveHypermediaLinks:V,mediatorRdfResolveHypermediaLinksQueue:re,mediatorMergeBindingsContext:pe,name:"urn:comunica:default:query-source-identify/actors#hypermedia",bus:M});new(Gte()).ActorRdfJoinNone({mediatorMergeBindingsContext:pe,mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#inner-none",bus:U}),new(BB()).ActorRdfJoinMultiBind({bindOrder:"depth-first",selectivityModifier:1e-4,minMaxCardinalityRatio:60,mediatorJoinEntriesSort:H,mediatorQueryOperation:G,mediatorMergeBindingsContext:pe,mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#inner-multi-bind",bus:U}),new(Xte()).ActorRdfJoinOptionalBind({bindOrder:"depth-first",selectivityModifier:1e-6,mediatorQueryOperation:G,mediatorMergeBindingsContext:pe,mediatorJoinSelectivity:N,name:"urn:comunica:default:rdf-join/actors#optional-bind",bus:U}),new(w5()).ActorQueryResultSerializeSparqlJson({emitMetadata:!0,httpObserver:Se,mediaTypePriorities:{"application/sparql-results+json":.8},mediaTypeFormats:{"application/sparql-results+json":"http://www.w3.org/ns/formats/SPARQL_Results_JSON"},name:"urn:comunica:default:query-result-serialize/actors#sparql-json",bus:l}),new(E5()).ActorQueryResultSerializeStats({httpObserver:Ae,mediaTypePriorities:{stats:.5},mediaTypeFormats:{stats:"https://comunica.linkeddatafragments.org/#results_stats"},name:"urn:comunica:default:query-result-serialize/actors#stats",bus:l}),new(Yte()).ActorQueryProcessExplainParsed({queryProcessor:je,name:"urn:comunica:default:query-process/actors#explain-parsed",bus:P}),new(ere()).ActorQueryProcessExplainLogical({queryProcessor:je,name:"urn:comunica:default:query-process/actors#explain-logical",bus:P}),new(rre()).ActorQueryProcessExplainPhysical({queryProcessor:je,name:"urn:comunica:default:query-process/actors#explain-physical",bus:P});const Ge=new(ire()).ActorOptimizeQueryOperationPruneEmptySourceOperations({useAskIfSupported:!1,name:"urn:comunica:default:optimize-query-operation/actors#prune-empty-source-operations",bus:a,beforeActors:[we]});new(yA()).ActorQuerySourceIdentifyRdfJs({mediatorMergeBindingsContext:pe,name:"urn:comunica:default:query-source-identify/actors#rdfjs",bus:M,beforeActors:[He]}),new(sre()).ActorQuerySourceIdentifySerialized({mediatorRdfParse:B,mediatorQuerySourceIdentify:Q,name:"urn:comunica:default:query-source-identify/actors#serialized",bus:M,beforeActors:[He]});const tt=new(ure()).ActorOptimizeQueryOperationJoinConnected({name:"urn:comunica:default:optimize-query-operation/actors#join-connected",bus:a,beforeActors:[Ge]}),lt=new(lre()).ActorOptimizeQueryOperationBgpToJoin({name:"urn:comunica:default:optimize-query-operation/actors#bgp-to-join",bus:a,beforeActors:[tt]}),ut=new(fre()).ActorOptimizeQueryOperationJoinBgp({name:"urn:comunica:default:optimize-query-operation/actors#join-bgp",bus:a,beforeActors:[lt]}),oe=new(pre()).ActorOptimizeQueryOperationAssignSourcesExhaustive({name:"urn:comunica:default:optimize-query-operation/actors#assign-sources-exhaustive",bus:a,beforeActors:[ut]});return new(bre()).ActorOptimizeQueryOperationDescribeToConstructsSubject({name:"urn:comunica:default:optimize-query-operation/actors#describe-to-constructs-subject",bus:a,beforeActors:[oe]}),W};Object.defineProperty(Eb,"__esModule",{value:!0});Eb.QueryEngine=void 0;const gre=aT,_re=mre;class vre extends gre.QueryEngineBase{constructor(e=_re()){super(e)}}Eb.QueryEngine=vre;(function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Eb,t)})(Z9);var Ks=globalThis&&globalThis.__awaiter||function(t,e,u,s){function n(r){return r instanceof u?r:new u(function(a){a(r)})}return new(u||(u=Promise))(function(r,a){function o(d){try{c(s.next(d))}catch(h){a(h)}}function l(d){try{c(s.throw(d))}catch(h){a(h)}}function c(d){d.done?r(d.value):n(d.value).then(o,l)}c((s=s.apply(t,e||[])).next())})};const lm=new Z9.QueryEngine;function wre(t,e){return Ks(this,void 0,void 0,function*(){let u=yield Sre(e||t);return u=u.replace("{url}",t),yield Tre(u)})}function Sre(t){return Ks(this,void 0,void 0,function*(){var e,u;const n=(e=(yield fetch(t,{method:"HEAD"})).headers.get("Link-Template"))===null||e===void 0?void 0:e.split(",").map(a=>{const o=a.trim().split(";"),l=o[0].trim().slice(1,-1),c=o[1].trim().split("=")[1].trim().slice(1,-1);return{url:l,rel:c}}),r=(u=n==null?void 0:n.find(a=>a.rel==="eventlog"))===null||u===void 0?void 0:u.url;if(!r)throw new Error("No event log found");return console.log("Found event log: "+r),r})}function Tre(t){return Ks(this,void 0,void 0,function*(){const e=` + PREFIX ldes: + PREFIX tree: + PREFIX as: + + SELECT ?member + WHERE { + ?id a ldes:EventStream; + tree:member ?member. + }`;return(yield lm.queryBindings(e,{sources:[t],lenient:!0})).transform({map:s=>Ks(this,void 0,void 0,function*(){const n=s.get("member").value;return yield Are(n)})})})}function Are(t){return Ks(this,void 0,void 0,function*(){const e=` + PREFIX as: + + SELECT ?id ?actorUrl ?actorName ?object ?targetUrl ?targetName ?context + WHERE { + ?id as:actor ?actorUrl; + as:object ?object. + OPTIONAL { ?id as:target ?targetUrl. } + OPTIONAL { ?actorUrl as:name ?actorName. } + OPTIONAL { ?targetUrl as:name ?targetName. } + OPTIONAL { ?id as:context ?context. } + } LIMIT 1`,u=yield(yield lm.queryBindings(e,{sources:[t],lenient:!0})).toArray();u.length!==1&&console.warn(`Found ${u.length} results for content, expected 1.`);const s=u.map(n=>{var r,a,o,l;return{id:n.get("id").value,actorUrl:n.get("actorUrl").value,actorName:(r=n.get("actorName"))===null||r===void 0?void 0:r.value,object:n.get("object").value,targetUrl:(a=n.get("targetUrl"))===null||a===void 0?void 0:a.value,targetName:(o=n.get("targetName"))===null||o===void 0?void 0:o.value,context:(l=n.get("context"))===null||l===void 0?void 0:l.value,types:[],objectTypes:[],objectRelationship:{}}})[0];return s.types=yield LM(s.id,t),s.objectTypes=yield LM(s.object,t),s.objectTypes.includes("https://www.w3.org/ns/activitystreams#Relationship")&&(s.objectRelationship=yield Ere(s.object,t)),s})}function LM(t,e){return Ks(this,void 0,void 0,function*(){if(!t)return[];const u=` + SELECT ?type + WHERE { + <${t}> a ?type. + }`;return(yield(yield lm.queryBindings(u,{sources:[e],lenient:!0})).toArray()).map(n=>n.get("type").value)})}function Ere(t,e){return Ks(this,void 0,void 0,function*(){if(!t)return{object:void 0,relationship:void 0,subject:void 0};const u=` + PREFIX as: + + SELECT ?subject ?relationship ?object + WHERE { + <${t}> as:subject ?subject; + as:relationship ?relationship; + as:object ?object. + } LIMIT 1`;return(yield(yield lm.queryBindings(u,{sources:[e],lenient:!0})).toArray()).map(n=>({subject:n.get("subject").value,relationship:n.get("relationship").value,object:n.get("object").value}))[0]||{}})}const Ore={name:"ScholarlyBrowser",components:{MDBContainer:d$,MDBCard:zH,MDBCardBody:WH,MDBCardText:YH,MDBInput:O$,MDBCardTitle:XH},data(){return{artifactUrl:"",serviceNodeUrl:"",members:[],loading:!1,noEventLog:!1,lastUpdated:0}},created(){this.$watch("$route.query.artifactUrl",()=>{this.artifactUrl=this.$route.query.artifactUrl||"",this.artifactUrl.trim(),this.urlUpdated()}),this.$watch("$route.query.serviceNodeUrl",()=>{this.serviceNodeUrl=this.$route.query.serviceNodeUrl||"",this.serviceNodeUrl.trim(),this.urlUpdated()})},methods:{async urlUpdated(){if(this.noEventLog=!1,this.loading=!1,this.members=[],!(Date.now()-this.lastUpdated<1e3)&&(this.lastUpdated=Date.now(),this.$router.push({query:{artifactUrl:this.artifactUrl,serviceNodeUrl:this.serviceNodeUrl}}),!!this.artifactUrl)){this.loading=!0;try{const t=await wre(this.artifactUrl.trim(),this.serviceNodeUrl.trim());t.on("data",async e=>{e=await e,e.mainTypes=await this.getMainTypes(e.types),e.secondaryTypes=await this.getSecondaryTypes(e.types),e.objectTypes=await Promise.all(await(e==null?void 0:e.objectTypes.map(async u=>await this.getPrefixedProperty(u))))??[],this.members.push(e),this.loading=!0}),t.on("end",()=>{this.loading=!1,this.members=this.members.sort((e,u)=>(console.log(`${e.published}`),e.publishedu.published?1:0))})}catch{this.noEventLog=!0,this.loading=!1;return}}},async getMainTypes(t){return await Promise.all(t.filter(e=>e.startsWith("https://www.w3.org/ns/activitystreams#")).map(async e=>await this.getPrefixedProperty(e)))},async getSecondaryTypes(t){return await Promise.all(t.filter(e=>!e.startsWith("https://www.w3.org/ns/activitystreams#")).map(async e=>await this.getPrefixedProperty(e)))},async getPrefixedProperty(t){const e=await fetch(`https://prefixcc-proxy.smessie.com/?q=${encodeURIComponent(t)}`,{method:"HEAD"});return e.url.includes(`/?q=${encodeURIComponent(t)}`)?t:e.url.split("prefixcc-proxy.smessie.com/")[1]},getStyleByMainType(t){switch(t){case"as:Create":return"success";case"as:Remove":return"dark";case"as:Announce":return"warning";case"as:Offer":return"primary";case"as:Accept":return"info";case"as:Reject":return"danger";case"as:Undo":return"secondary";case"as:Update":default:return"light"}}}},Rre=""+new URL("../forkme_right_gray.png",import.meta.url).href;const xre=(t,e)=>{const u=t.__vccOpts||t;for(const[s,n]of e)u[s]=n;return u},Di=t=>(pQ("data-v-ce99c8e5"),t=t(),yQ(),t),Ire=Di(()=>Bt("a",{href:"https://github.com/MellonScholarlyCommunication/scholarly-browser"},[Bt("img",{loading:"lazy",width:"149",height:"149",src:Rre,class:"attachment-full size-full fork",alt:"Fork me on GitHub","data-recalc-dims":"1"})],-1)),Pre=Di(()=>Bt("h1",null,"Scholarly Browser",-1)),Dre=Di(()=>Bt("small",null,"Provide an optional service node URL to retrieve the event notifications from the service node.",-1)),Nre={key:0,class:"status-message"},Cre={key:1,class:"status-message"},jre=Di(()=>Bt("b",null,"No event log found.",-1)),Lre=Di(()=>Bt("b",null,"Actor: ",-1)),Mre=["href"],Fre=Di(()=>Bt("b",null,"Target: ",-1)),qre=["href"],Bre={key:1},Ure=Di(()=>Bt("b",null,"Context: ",-1)),Qre=["href"],Hre={key:1},$re=Di(()=>Bt("b",null,"Object: ",-1)),Vre=["href"],kre={key:0},zre=Di(()=>Bt("b",null,"Subject: ",-1)),Gre=["href"],Wre=Di(()=>Bt("b",null,"Relationship: ",-1)),Jre=["href"],Xre=Di(()=>Bt("b",null,"Object: ",-1)),Kre=["href"];function Yre(t,e,u,s,n,r){const a=yo("MDBInput"),o=yo("MDBCardText"),l=yo("MDBCardBody"),c=yo("MDBCard"),d=yo("MDBCardTitle"),h=yo("MDBContainer");return jt(),ir(On,null,[Ire,ar(h,null,{default:Lr(()=>[Pre,ar(c,null,{default:Lr(()=>[ar(l,{class:"w-100"},{default:Lr(()=>[ar(o,null,{default:Lr(()=>[ar(a,{label:"Artifact URL",modelValue:n.artifactUrl,"onUpdate:modelValue":e[0]||(e[0]=f=>n.artifactUrl=f),onChange:r.urlUpdated},null,8,["modelValue","onChange"]),ar(a,{label:"Service Node URL",modelValue:n.serviceNodeUrl,"onUpdate:modelValue":e[1]||(e[1]=f=>n.serviceNodeUrl=f),onChange:r.urlUpdated,class:"mt-3"},null,8,["modelValue","onChange"]),Dre]),_:1})]),_:1})]),_:1}),ar(c,null,{default:Lr(()=>[ar(l,{class:"w-100"},{default:Lr(()=>[ar(o,null,{default:Lr(()=>[n.loading?(jt(),ir("p",Nre,"Loading notifications...")):Vr("",!0),n.noEventLog?(jt(),ir("p",Cre,[jre,T0(" Make sure the provided URL contains a ldes:EventStream Link header.")])):Vr("",!0),(jt(!0),ir(On,null,KA(n.members,(f,p)=>(jt(),Ii(c,{key:p,border:r.getStyleByMainType(f.mainTypes[0])},{default:Lr(()=>[ar(l,{class:"w-100",style:{"padding-bottom":"0"}},{default:Lr(()=>[ar(d,null,{default:Lr(()=>[T0(Or(f.mainTypes.join(", ")),1)]),_:2},1024),ar(d,{subtitle:"",class:"mb-2 text-muted"},{default:Lr(()=>[T0(Or(f.secondaryTypes.join(", ")),1)]),_:2},1024),ar(o,null,{default:Lr(()=>[Bt("p",null,[Lre,Bt("a",{href:f.actorUrl},Or(f.actorName??f.actorUrl),9,Mre)]),Bt("p",null,[Fre,f.targetUrl?(jt(),ir("a",{key:0,href:f.targetUrl},Or(f.targetName??f.targetUrl),9,qre)):(jt(),ir("i",Bre,""))]),Bt("p",null,[Ure,f.context?(jt(),ir("a",{key:0,href:"?url="+f.context},Or(f.context),9,Qre)):(jt(),ir("i",Hre,""))]),Bt("p",null,[$re,Bt("a",{href:"?url="+f.object},Or(f.object),9,Vre)]),Bt("ul",null,[(jt(!0),ir(On,null,KA(f.objectTypes,(y,b)=>(jt(),ir("li",{key:b},[T0(Or(y)+" ",1),y==="as:Relationship"?(jt(),ir("ul",kre,[Bt("li",null,[zre,Bt("a",{href:f.objectRelationship.subject},Or(f.objectRelationship.subject),9,Gre)]),Bt("li",null,[Wre,Bt("a",{href:f.objectRelationship.relationship},Or(f.objectRelationship.relationship),9,Jre)]),Bt("li",null,[Xre,Bt("a",{href:f.objectRelationship.object},Or(f.objectRelationship.object),9,Kre)])])):Vr("",!0)]))),128))])]),_:2},1024)]),_:2},1024)]),_:2},1032,["border"]))),128))]),_:1})]),_:1})]),_:1})]),_:1})],64)}const Zre=xre(Ore,[["render",Yre],["__scopeId","data-v-ce99c8e5"]]),QB=xi({__name:"App",setup(t){return(e,u)=>(jt(),ir("main",null,[ar(Zre)]))}});/*! + * vue-router v4.2.5 + * (c) 2023 Eduardo San Martin Morote + * @license MIT + */const To=typeof window<"u";function ene(t){return t.__esModule||t[Symbol.toStringTag]==="Module"}const er=Object.assign;function VS(t,e){const u={};for(const s in e){const n=e[s];u[s]=Ri(n)?n.map(t):t(n)}return u}const Q0=()=>{},Ri=Array.isArray,tne=/\/$/,rne=t=>t.replace(tne,"");function kS(t,e,u="/"){let s,n={},r="",a="";const o=e.indexOf("#");let l=e.indexOf("?");return o=0&&(l=-1),l>-1&&(s=e.slice(0,l),r=e.slice(l+1,o>-1?o:e.length),n=t(r)),o>-1&&(s=s||e.slice(0,o),a=e.slice(o,e.length)),s=sne(s??e,u),{fullPath:s+(r&&"?")+r+a,path:s,query:n,hash:a}}function nne(t,e){const u=e.query?t(e.query):"";return e.path+(u&&"?")+u+(e.hash||"")}function MM(t,e){return!e||!t.toLowerCase().startsWith(e.toLowerCase())?t:t.slice(e.length)||"/"}function ine(t,e,u){const s=e.matched.length-1,n=u.matched.length-1;return s>-1&&s===n&&$o(e.matched[s],u.matched[n])&&HB(e.params,u.params)&&t(e.query)===t(u.query)&&e.hash===u.hash}function $o(t,e){return(t.aliasOf||t)===(e.aliasOf||e)}function HB(t,e){if(Object.keys(t).length!==Object.keys(e).length)return!1;for(const u in t)if(!ane(t[u],e[u]))return!1;return!0}function ane(t,e){return Ri(t)?FM(t,e):Ri(e)?FM(e,t):t===e}function FM(t,e){return Ri(e)?t.length===e.length&&t.every((u,s)=>u===e[s]):t.length===1&&t[0]===e}function sne(t,e){if(t.startsWith("/"))return t;if(!t)return e;const u=e.split("/"),s=t.split("/"),n=s[s.length-1];(n===".."||n===".")&&s.push("");let r=u.length-1,a,o;for(a=0;a1&&r--;else break;return u.slice(0,r).join("/")+"/"+s.slice(a-(a===s.length?1:0)).join("/")}var ay;(function(t){t.pop="pop",t.push="push"})(ay||(ay={}));var H0;(function(t){t.back="back",t.forward="forward",t.unknown=""})(H0||(H0={}));function one(t){if(!t)if(To){const e=document.querySelector("base");t=e&&e.getAttribute("href")||"/",t=t.replace(/^\w+:\/\/[^\/]+/,"")}else t="/";return t[0]!=="/"&&t[0]!=="#"&&(t="/"+t),rne(t)}const une=/^[^#]+#/;function cne(t,e){return t.replace(une,"#")+e}function lne(t,e){const u=document.documentElement.getBoundingClientRect(),s=t.getBoundingClientRect();return{behavior:e.behavior,left:s.left-u.left-(e.left||0),top:s.top-u.top-(e.top||0)}}const dm=()=>({left:window.pageXOffset,top:window.pageYOffset});function dne(t){let e;if("el"in t){const u=t.el,s=typeof u=="string"&&u.startsWith("#"),n=typeof u=="string"?s?document.getElementById(u.slice(1)):document.querySelector(u):u;if(!n)return;e=lne(n,t)}else e=t;"scrollBehavior"in document.documentElement.style?window.scrollTo(e):window.scrollTo(e.left!=null?e.left:window.pageXOffset,e.top!=null?e.top:window.pageYOffset)}function qM(t,e){return(history.state?history.state.position-e:-1)+t}const j3=new Map;function fne(t,e){j3.set(t,e)}function hne(t){const e=j3.get(t);return j3.delete(t),e}let pne=()=>location.protocol+"//"+location.host;function $B(t,e){const{pathname:u,search:s,hash:n}=e,r=t.indexOf("#");if(r>-1){let o=n.includes(t.slice(r))?t.slice(r).length:1,l=n.slice(o);return l[0]!=="/"&&(l="/"+l),MM(l,"")}return MM(u,t)+s+n}function yne(t,e,u,s){let n=[],r=[],a=null;const o=({state:f})=>{const p=$B(t,location),y=u.value,b=e.value;let g=0;if(f){if(u.value=p,e.value=f,a&&a===y){a=null;return}g=b?f.position-b.position:0}else s(p);n.forEach(m=>{m(u.value,y,{delta:g,type:ay.pop,direction:g?g>0?H0.forward:H0.back:H0.unknown})})};function l(){a=u.value}function c(f){n.push(f);const p=()=>{const y=n.indexOf(f);y>-1&&n.splice(y,1)};return r.push(p),p}function d(){const{history:f}=window;f.state&&f.replaceState(er({},f.state,{scroll:dm()}),"")}function h(){for(const f of r)f();r=[],window.removeEventListener("popstate",o),window.removeEventListener("beforeunload",d)}return window.addEventListener("popstate",o),window.addEventListener("beforeunload",d,{passive:!0}),{pauseListeners:l,listen:c,destroy:h}}function BM(t,e,u,s=!1,n=!1){return{back:t,current:e,forward:u,replaced:s,position:window.history.length,scroll:n?dm():null}}function bne(t){const{history:e,location:u}=window,s={value:$B(t,u)},n={value:e.state};n.value||r(s.value,{back:null,current:s.value,forward:null,position:e.length-1,replaced:!0,scroll:null},!0);function r(l,c,d){const h=t.indexOf("#"),f=h>-1?(u.host&&document.querySelector("base")?t:t.slice(h))+l:pne()+t+l;try{e[d?"replaceState":"pushState"](c,"",f),n.value=c}catch(p){console.error(p),u[d?"replace":"assign"](f)}}function a(l,c){const d=er({},e.state,BM(n.value.back,l,n.value.forward,!0),c,{position:n.value.position});r(l,d,!0),s.value=l}function o(l,c){const d=er({},n.value,e.state,{forward:l,scroll:dm()});r(d.current,d,!0);const h=er({},BM(s.value,l,null),{position:d.position+1},c);r(l,h,!1),s.value=l}return{location:s,state:n,push:o,replace:a}}function mne(t){t=one(t);const e=bne(t),u=yne(t,e.state,e.location,e.replace);function s(r,a=!0){a||u.pauseListeners(),history.go(r)}const n=er({location:"",base:t,go:s,createHref:cne.bind(null,t)},e,u);return Object.defineProperty(n,"location",{enumerable:!0,get:()=>e.location.value}),Object.defineProperty(n,"state",{enumerable:!0,get:()=>e.state.value}),n}function gne(t){return typeof t=="string"||t&&typeof t=="object"}function VB(t){return typeof t=="string"||typeof t=="symbol"}const Pa={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0},kB=Symbol("");var UM;(function(t){t[t.aborted=4]="aborted",t[t.cancelled=8]="cancelled",t[t.duplicated=16]="duplicated"})(UM||(UM={}));function Vo(t,e){return er(new Error,{type:t,[kB]:!0},e)}function da(t,e){return t instanceof Error&&kB in t&&(e==null||!!(t.type&e))}const QM="[^/]+?",_ne={sensitive:!1,strict:!1,start:!0,end:!0},vne=/[.+*?^${}()[\]/\\]/g;function wne(t,e){const u=er({},_ne,e),s=[];let n=u.start?"^":"";const r=[];for(const c of t){const d=c.length?[]:[90];u.strict&&!c.length&&(n+="/");for(let h=0;he.length?e.length===1&&e[0]===40+40?1:-1:0}function Tne(t,e){let u=0;const s=t.score,n=e.score;for(;u0&&e[e.length-1]<0}const Ane={type:0,value:""},Ene=/[a-zA-Z0-9_]/;function One(t){if(!t)return[[]];if(t==="/")return[[Ane]];if(!t.startsWith("/"))throw new Error(`Invalid path "${t}"`);function e(p){throw new Error(`ERR (${u})/"${c}": ${p}`)}let u=0,s=u;const n=[];let r;function a(){r&&n.push(r),r=[]}let o=0,l,c="",d="";function h(){c&&(u===0?r.push({type:0,value:c}):u===1||u===2||u===3?(r.length>1&&(l==="*"||l==="+")&&e(`A repeatable param (${c}) must be alone in its segment. eg: '/:ids+.`),r.push({type:1,value:c,regexp:d,repeatable:l==="*"||l==="+",optional:l==="*"||l==="?"})):e("Invalid state to consume buffer"),c="")}function f(){c+=l}for(;o{a(v)}:Q0}function a(d){if(VB(d)){const h=s.get(d);h&&(s.delete(d),u.splice(u.indexOf(h),1),h.children.forEach(a),h.alias.forEach(a))}else{const h=u.indexOf(d);h>-1&&(u.splice(h,1),d.record.name&&s.delete(d.record.name),d.children.forEach(a),d.alias.forEach(a))}}function o(){return u}function l(d){let h=0;for(;h=0&&(d.record.path!==u[h].record.path||!zB(d,u[h]));)h++;u.splice(h,0,d),d.record.name&&!VM(d)&&s.set(d.record.name,d)}function c(d,h){let f,p={},y,b;if("name"in d&&d.name){if(f=s.get(d.name),!f)throw Vo(1,{location:d});b=f.record.name,p=er($M(h.params,f.keys.filter(v=>!v.optional).map(v=>v.name)),d.params&&$M(d.params,f.keys.map(v=>v.name))),y=f.stringify(p)}else if("path"in d)y=d.path,f=u.find(v=>v.re.test(y)),f&&(p=f.parse(y),b=f.record.name);else{if(f=h.name?s.get(h.name):u.find(v=>v.re.test(h.path)),!f)throw Vo(1,{location:d,currentLocation:h});b=f.record.name,p=er({},h.params,d.params),y=f.stringify(p)}const g=[];let m=f;for(;m;)g.unshift(m.record),m=m.parent;return{name:b,path:y,params:p,matched:g,meta:Dne(g)}}return t.forEach(d=>r(d)),{addRoute:r,resolve:c,removeRoute:a,getRoutes:o,getRecordMatcher:n}}function $M(t,e){const u={};for(const s of e)s in t&&(u[s]=t[s]);return u}function Ine(t){return{path:t.path,redirect:t.redirect,name:t.name,meta:t.meta||{},aliasOf:void 0,beforeEnter:t.beforeEnter,props:Pne(t),children:t.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in t?t.components||null:t.component&&{default:t.component}}}function Pne(t){const e={},u=t.props||!1;if("component"in t)e.default=u;else for(const s in t.components)e[s]=typeof u=="object"?u[s]:u;return e}function VM(t){for(;t;){if(t.record.aliasOf)return!0;t=t.parent}return!1}function Dne(t){return t.reduce((e,u)=>er(e,u.meta),{})}function kM(t,e){const u={};for(const s in t)u[s]=s in e?e[s]:t[s];return u}function zB(t,e){return e.children.some(u=>u===t||zB(t,u))}const GB=/#/g,Nne=/&/g,Cne=/\//g,jne=/=/g,Lne=/\?/g,WB=/\+/g,Mne=/%5B/g,Fne=/%5D/g,JB=/%5E/g,qne=/%60/g,XB=/%7B/g,Bne=/%7C/g,KB=/%7D/g,Une=/%20/g;function mA(t){return encodeURI(""+t).replace(Bne,"|").replace(Mne,"[").replace(Fne,"]")}function Qne(t){return mA(t).replace(XB,"{").replace(KB,"}").replace(JB,"^")}function L3(t){return mA(t).replace(WB,"%2B").replace(Une,"+").replace(GB,"%23").replace(Nne,"%26").replace(qne,"`").replace(XB,"{").replace(KB,"}").replace(JB,"^")}function Hne(t){return L3(t).replace(jne,"%3D")}function $ne(t){return mA(t).replace(GB,"%23").replace(Lne,"%3F")}function Vne(t){return t==null?"":$ne(t).replace(Cne,"%2F")}function db(t){try{return decodeURIComponent(""+t)}catch{}return""+t}function kne(t){const e={};if(t===""||t==="?")return e;const s=(t[0]==="?"?t.slice(1):t).split("&");for(let n=0;nr&&L3(r)):[s&&L3(s)]).forEach(r=>{r!==void 0&&(e+=(e.length?"&":"")+u,r!=null&&(e+="="+r))})}return e}function zne(t){const e={};for(const u in t){const s=t[u];s!==void 0&&(e[u]=Ri(s)?s.map(n=>n==null?null:""+n):s==null?s:""+s)}return e}const Gne=Symbol(""),GM=Symbol(""),gA=Symbol(""),YB=Symbol(""),M3=Symbol("");function v0(){let t=[];function e(s){return t.push(s),()=>{const n=t.indexOf(s);n>-1&&t.splice(n,1)}}function u(){t=[]}return{add:e,list:()=>t.slice(),reset:u}}function Ba(t,e,u,s,n){const r=s&&(s.enterCallbacks[n]=s.enterCallbacks[n]||[]);return()=>new Promise((a,o)=>{const l=h=>{h===!1?o(Vo(4,{from:u,to:e})):h instanceof Error?o(h):gne(h)?o(Vo(2,{from:e,to:h})):(r&&s.enterCallbacks[n]===r&&typeof h=="function"&&r.push(h),a())},c=t.call(s&&s.instances[n],e,u,l);let d=Promise.resolve(c);t.length<3&&(d=d.then(l)),d.catch(h=>o(h))})}function zS(t,e,u,s){const n=[];for(const r of t)for(const a in r.components){let o=r.components[a];if(!(e!=="beforeRouteEnter"&&!r.instances[a]))if(Wne(o)){const c=(o.__vccOpts||o)[e];c&&n.push(Ba(c,u,s,r,a))}else{let l=o();n.push(()=>l.then(c=>{if(!c)return Promise.reject(new Error(`Couldn't resolve component "${a}" at "${r.path}"`));const d=ene(c)?c.default:c;r.components[a]=d;const f=(d.__vccOpts||d)[e];return f&&Ba(f,u,s,r,a)()}))}}return n}function Wne(t){return typeof t=="object"||"displayName"in t||"props"in t||"__vccOpts"in t}function WM(t){const e=Ai(gA),u=Ai(YB),s=sr(()=>e.resolve(qt(t.to))),n=sr(()=>{const{matched:l}=s.value,{length:c}=l,d=l[c-1],h=u.matched;if(!d||!h.length)return-1;const f=h.findIndex($o.bind(null,d));if(f>-1)return f;const p=JM(l[c-2]);return c>1&&JM(d)===p&&h[h.length-1].path!==p?h.findIndex($o.bind(null,l[c-2])):f}),r=sr(()=>n.value>-1&&Yne(u.params,s.value.params)),a=sr(()=>n.value>-1&&n.value===u.matched.length-1&&HB(u.params,s.value.params));function o(l={}){return Kne(l)?e[qt(t.replace)?"replace":"push"](qt(t.to)).catch(Q0):Promise.resolve()}return{route:s,href:sr(()=>s.value.href),isActive:r,isExactActive:a,navigate:o}}const Jne=xi({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"}},useLink:WM,setup(t,{slots:e}){const u=mb(WM(t)),{options:s}=Ai(gA),n=sr(()=>({[XM(t.activeClass,s.linkActiveClass,"router-link-active")]:u.isActive,[XM(t.exactActiveClass,s.linkExactActiveClass,"router-link-exact-active")]:u.isExactActive}));return()=>{const r=e.default&&e.default(u);return t.custom?r:X9("a",{"aria-current":u.isExactActive?t.ariaCurrentValue:null,href:u.href,onClick:u.navigate,class:n.value},r)}}}),Xne=Jne;function Kne(t){if(!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey)&&!t.defaultPrevented&&!(t.button!==void 0&&t.button!==0)){if(t.currentTarget&&t.currentTarget.getAttribute){const e=t.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(e))return}return t.preventDefault&&t.preventDefault(),!0}}function Yne(t,e){for(const u in e){const s=e[u],n=t[u];if(typeof s=="string"){if(s!==n)return!1}else if(!Ri(n)||n.length!==s.length||s.some((r,a)=>r!==n[a]))return!1}return!0}function JM(t){return t?t.aliasOf?t.aliasOf.path:t.path:""}const XM=(t,e,u)=>t??e??u,Zne=xi({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(t,{attrs:e,slots:u}){const s=Ai(M3),n=sr(()=>t.route||s.value),r=Ai(GM,0),a=sr(()=>{let c=qt(r);const{matched:d}=n.value;let h;for(;(h=d[c])&&!h.components;)c++;return c}),o=sr(()=>n.value.matched[a.value]);F1(GM,sr(()=>a.value+1)),F1(Gne,o),F1(M3,n);const l=En();return Po(()=>[l.value,o.value,t.name],([c,d,h],[f,p,y])=>{d&&(d.instances[h]=c,p&&p!==d&&c&&c===f&&(d.leaveGuards.size||(d.leaveGuards=p.leaveGuards),d.updateGuards.size||(d.updateGuards=p.updateGuards))),c&&d&&(!p||!$o(d,p)||!f)&&(d.enterCallbacks[h]||[]).forEach(b=>b(c))},{flush:"post"}),()=>{const c=n.value,d=t.name,h=o.value,f=h&&h.components[d];if(!f)return KM(u.default,{Component:f,route:c});const p=h.props[d],y=p?p===!0?c.params:typeof p=="function"?p(c):p:null,g=X9(f,er({},y,e,{onVnodeUnmounted:m=>{m.component.isUnmounted&&(h.instances[d]=null)},ref:l}));return KM(u.default,{Component:g,route:c})||g}}});function KM(t,e){if(!t)return null;const u=t(e);return u.length===1?u[0]:u}const eie=Zne;function tie(t){const e=xne(t.routes,t),u=t.parseQuery||kne,s=t.stringifyQuery||zM,n=t.history,r=v0(),a=v0(),o=v0(),l=nQ(Pa);let c=Pa;To&&t.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const d=VS.bind(null,ge=>""+ge),h=VS.bind(null,Vne),f=VS.bind(null,db);function p(ge,de){let fe,H;return VB(ge)?(fe=e.getRecordMatcher(ge),H=de):H=ge,e.addRoute(H,fe)}function y(ge){const de=e.getRecordMatcher(ge);de&&e.removeRoute(de)}function b(){return e.getRoutes().map(ge=>ge.record)}function g(ge){return!!e.getRecordMatcher(ge)}function m(ge,de){if(de=er({},de||l.value),typeof ge=="string"){const x=kS(u,ge,de.path),B=e.resolve({path:x.path},de),k=n.createHref(x.fullPath);return er(x,B,{params:f(B.params),hash:db(x.hash),redirectedFrom:void 0,href:k})}let fe;if("path"in ge)fe=er({},ge,{path:kS(u,ge.path,de.path).path});else{const x=er({},ge.params);for(const B in x)x[B]==null&&delete x[B];fe=er({},ge,{params:h(x)}),de.params=h(de.params)}const H=e.resolve(fe,de),N=ge.hash||"";H.params=d(f(H.params));const R=nne(s,er({},ge,{hash:Qne(N),path:H.path})),T=n.createHref(R);return er({fullPath:R,hash:N,query:s===zM?zne(ge.query):ge.query||{}},H,{redirectedFrom:void 0,href:T})}function v(ge){return typeof ge=="string"?kS(u,ge,l.value.path):er({},ge)}function _(ge,de){if(c!==ge)return Vo(8,{from:de,to:ge})}function w(ge){return D(ge)}function S(ge){return w(er(v(ge),{replace:!0}))}function A(ge){const de=ge.matched[ge.matched.length-1];if(de&&de.redirect){const{redirect:fe}=de;let H=typeof fe=="function"?fe(ge):fe;return typeof H=="string"&&(H=H.includes("?")||H.includes("#")?H=v(H):{path:H},H.params={}),er({query:ge.query,hash:ge.hash,params:"path"in H?{}:ge.params},H)}}function D(ge,de){const fe=c=m(ge),H=l.value,N=ge.state,R=ge.force,T=ge.replace===!0,x=A(fe);if(x)return D(er(v(x),{state:typeof x=="object"?er({},N,x.state):N,force:R,replace:T}),de||fe);const B=fe;B.redirectedFrom=de;let k;return!R&&ine(s,H,fe)&&(k=Vo(16,{to:B,from:H}),he(H,H,!0,!1)),(k?Promise.resolve(k):E(B,H)).catch(V=>da(V)?da(V,2)?V:K(V):X(V,B,H)).then(V=>{if(V){if(da(V,2))return D(er({replace:T},v(V.to),{state:typeof V.to=="object"?er({},N,V.to.state):N,force:R}),de||B)}else V=M(B,H,!0,T,N);return P(B,H,V),V})}function L(ge,de){const fe=_(ge,de);return fe?Promise.reject(fe):Promise.resolve()}function O(ge){const de=ae.values().next().value;return de&&typeof de.runWithContext=="function"?de.runWithContext(ge):ge()}function E(ge,de){let fe;const[H,N,R]=rie(ge,de);fe=zS(H.reverse(),"beforeRouteLeave",ge,de);for(const x of H)x.leaveGuards.forEach(B=>{fe.push(Ba(B,ge,de))});const T=L.bind(null,ge,de);return fe.push(T),De(fe).then(()=>{fe=[];for(const x of r.list())fe.push(Ba(x,ge,de));return fe.push(T),De(fe)}).then(()=>{fe=zS(N,"beforeRouteUpdate",ge,de);for(const x of N)x.updateGuards.forEach(B=>{fe.push(Ba(B,ge,de))});return fe.push(T),De(fe)}).then(()=>{fe=[];for(const x of R)if(x.beforeEnter)if(Ri(x.beforeEnter))for(const B of x.beforeEnter)fe.push(Ba(B,ge,de));else fe.push(Ba(x.beforeEnter,ge,de));return fe.push(T),De(fe)}).then(()=>(ge.matched.forEach(x=>x.enterCallbacks={}),fe=zS(R,"beforeRouteEnter",ge,de),fe.push(T),De(fe))).then(()=>{fe=[];for(const x of a.list())fe.push(Ba(x,ge,de));return fe.push(T),De(fe)}).catch(x=>da(x,8)?x:Promise.reject(x))}function P(ge,de,fe){o.list().forEach(H=>O(()=>H(ge,de,fe)))}function M(ge,de,fe,H,N){const R=_(ge,de);if(R)return R;const T=de===Pa,x=To?history.state:{};fe&&(H||T?n.replace(ge.fullPath,er({scroll:T&&x&&x.scroll},N)):n.push(ge.fullPath,N)),l.value=ge,he(ge,de,fe,T),K()}let U;function j(){U||(U=n.listen((ge,de,fe)=>{if(!Ee.listening)return;const H=m(ge),N=A(H);if(N){D(er(N,{replace:!0}),H).catch(Q0);return}c=H;const R=l.value;To&&fne(qM(R.fullPath,fe.delta),dm()),E(H,R).catch(T=>da(T,12)?T:da(T,2)?(D(T.to,H).then(x=>{da(x,20)&&!fe.delta&&fe.type===ay.pop&&n.go(-1,!1)}).catch(Q0),Promise.reject()):(fe.delta&&n.go(-fe.delta,!1),X(T,H,R))).then(T=>{T=T||M(H,R,!1),T&&(fe.delta&&!da(T,8)?n.go(-fe.delta,!1):fe.type===ay.pop&&da(T,20)&&n.go(-1,!1)),P(H,R,T)}).catch(Q0)}))}let q=v0(),$=v0(),Z;function X(ge,de,fe){K(ge);const H=$.list();return H.length?H.forEach(N=>N(ge,de,fe)):console.error(ge),Promise.reject(ge)}function le(){return Z&&l.value!==Pa?Promise.resolve():new Promise((ge,de)=>{q.add([ge,de])})}function K(ge){return Z||(Z=!ge,j(),q.list().forEach(([de,fe])=>ge?fe(ge):de()),q.reset()),ge}function he(ge,de,fe,H){const{scrollBehavior:N}=t;if(!To||!N)return Promise.resolve();const R=!fe&&hne(qM(ge.fullPath,0))||(H||!fe)&&history.state&&history.state.scroll||null;return T9().then(()=>N(ge,de,R)).then(T=>T&&dne(T)).catch(T=>X(T,ge,de))}const Re=ge=>n.go(ge);let ie;const ae=new Set,Ee={currentRoute:l,listening:!0,addRoute:p,removeRoute:y,hasRoute:g,getRoutes:b,resolve:m,options:t,push:w,replace:S,go:Re,back:()=>Re(-1),forward:()=>Re(1),beforeEach:r.add,beforeResolve:a.add,afterEach:o.add,onError:$.add,isReady:le,install(ge){const de=this;ge.component("RouterLink",Xne),ge.component("RouterView",eie),ge.config.globalProperties.$router=de,Object.defineProperty(ge.config.globalProperties,"$route",{enumerable:!0,get:()=>qt(l)}),To&&!ie&&l.value===Pa&&(ie=!0,w(n.location).catch(N=>{}));const fe={};for(const N in Pa)Object.defineProperty(fe,N,{get:()=>l.value[N],enumerable:!0});ge.provide(gA,de),ge.provide(YB,p9(fe)),ge.provide(M3,l);const H=ge.unmount;ae.add(ge),ge.unmount=function(){ae.delete(ge),ae.size<1&&(c=Pa,U&&U(),U=null,l.value=Pa,ie=!1,Z=!1),H()}}};function De(ge){return ge.reduce((de,fe)=>de.then(()=>O(fe)),Promise.resolve())}return Ee}function rie(t,e){const u=[],s=[],n=[],r=Math.max(e.matched.length,t.matched.length);for(let a=0;a$o(c,o))?s.push(o):u.push(o));const l=t.matched[a];l&&(e.matched.find(c=>$o(c,l))||n.push(l))}return[u,s,n]}const nie=tie({history:mne("/scholarly-browser/"),routes:[{path:"/",component:QB,props:!0}]}),ZB=NH(QB);ZB.use(nie);ZB.mount("#app"); diff --git a/assets/index-9c895cd1.css b/assets/index-7a57bc8d.css similarity index 99% rename from assets/index-9c895cd1.css rename to assets/index-7a57bc8d.css index 512e2e9..fbf07ff 100644 --- a/assets/index-9c895cd1.css +++ b/assets/index-7a57bc8d.css @@ -20,4 +20,4 @@ * Released under the MIT license * http://opensource.org/licenses/MIT * -*/#mdb-table-flag tr{cursor:pointer}.mdb-flag-selected{border-top-left-radius:5px;border-top-right-radius:5px;text-align:center;max-width:150px;margin:10px auto 0}.mdb-selected-flag-text{margin:0 auto;max-width:150px}i.flag:not(.icon){display:inline-block;width:16px;height:11px;margin:0 .5em 0 0;line-height:11px;text-decoration:inherit;vertical-align:baseline;backface-visibility:hidden}i.flag:before{display:inline-block;width:16px;height:11px;content:"";background:url(https://mdbootstrap.com/img/svg/flags.png) no-repeat -108px -1976px}i.flag-ad:before,i.flag-andorra:before{background-position:0 0!important}i.flag-ae:before,i.flag-united-arab-emirates:before,i.flag-uae:before{background-position:0 -26px!important}i.flag-af:before,i.flag-afghanistan:before{background-position:0 -52px!important}i.flag-ag:before,i.flag-antigua:before{background-position:0 -78px!important}i.flag-ai:before,i.flag-anguilla:before{background-position:0 -104px!important}i.flag-al:before,i.flag-albania:before{background-position:0 -130px!important}i.flag-am:before,i.flag-armenia:before{background-position:0 -156px!important}i.flag-an:before,i.flag-netherlands-antilles:before{background-position:0 -182px!important}i.flag-ao:before,i.flag-angola:before{background-position:0 -208px!important}i.flag-ar:before,i.flag-argentina:before{background-position:0 -234px!important}i.flag-as:before,i.flag-american-samoa:before{background-position:0 -260px!important}i.flag-at:before,i.flag-austria:before{background-position:0 -286px!important}i.flag-au:before,i.flag-australia:before{background-position:0 -312px!important}i.flag-aw:before,i.flag-aruba:before{background-position:0 -338px!important}i.flag-ax:before,i.flag-aland-islands:before{background-position:0 -364px!important}i.flag-az:before,i.flag-azerbaijan:before{background-position:0 -390px!important}i.flag-ba:before,i.flag-bosnia:before{background-position:0 -416px!important}i.flag-bb:before,i.flag-barbados:before{background-position:0 -442px!important}i.flag-bd:before,i.flag-bangladesh:before{background-position:0 -468px!important}i.flag-be:before,i.flag-belgium:before{background-position:0 -494px!important}i.flag-bf:before,i.flag-burkina-faso:before{background-position:0 -520px!important}i.flag-bg:before,i.flag-bulgaria:before{background-position:0 -546px!important}i.flag-bh:before,i.flag-bahrain:before{background-position:0 -572px!important}i.flag-bi:before,i.flag-burundi:before{background-position:0 -598px!important}i.flag-bj:before,i.flag-benin:before{background-position:0 -624px!important}i.flag-bm:before,i.flag-bermuda:before{background-position:0 -650px!important}i.flag-bn:before,i.flag-brunei:before{background-position:0 -676px!important}i.flag-bo:before,i.flag-bolivia:before{background-position:0 -702px!important}i.flag-br:before,i.flag-brazil:before{background-position:0 -728px!important}i.flag-bs:before,i.flag-bahamas:before{background-position:0 -754px!important}i.flag-bt:before,i.flag-bhutan:before{background-position:0 -780px!important}i.flag-bv:before,i.flag-bouvet-island:before{background-position:0 -806px!important}i.flag-bw:before,i.flag-botswana:before{background-position:0 -832px!important}i.flag-by:before,i.flag-belarus:before{background-position:0 -858px!important}i.flag-bz:before,i.flag-belize:before{background-position:0 -884px!important}i.flag-ca:before,i.flag-canada:before{background-position:0 -910px!important}i.flag-cc:before,i.flag-cocos-islands:before{background-position:0 -962px!important}i.flag-cd:before,i.flag-congo:before{background-position:0 -988px!important}i.flag-cf:before,i.flag-central-african-republic:before{background-position:0 -1014px!important}i.flag-cg:before,i.flag-congo-brazzaville:before{background-position:0 -1040px!important}i.flag-ch:before,i.flag-switzerland:before{background-position:0 -1066px!important}i.flag-ci:before,i.flag-cote-divoire:before{background-position:0 -1092px!important}i.flag-ck:before,i.flag-cook-islands:before{background-position:0 -1118px!important}i.flag-cl:before,i.flag-chile:before{background-position:0 -1144px!important}i.flag-cm:before,i.flag-cameroon:before{background-position:0 -1170px!important}i.flag-cn:before,i.flag-china:before{background-position:0 -1196px!important}i.flag-co:before,i.flag-colombia:before{background-position:0 -1222px!important}i.flag-cr:before,i.flag-costa-rica:before{background-position:0 -1248px!important}i.flag-cs:before,i.flag-serbia:before{background-position:0 -1274px!important}i.flag-cu:before,i.flag-cuba:before{background-position:0 -1300px!important}i.flag-cv:before,i.flag-cape-verde:before{background-position:0 -1326px!important}i.flag-cx:before,i.flag-christmas-island:before{background-position:0 -1352px!important}i.flag-cy:before,i.flag-cyprus:before{background-position:0 -1378px!important}i.flag-cz:before,i.flag-czech-republic:before{background-position:0 -1404px!important}i.flag-de:before,i.flag-germany:before{background-position:0 -1430px!important}i.flag-dj:before,i.flag-djibouti:before{background-position:0 -1456px!important}i.flag-dk:before,i.flag-denmark:before{background-position:0 -1482px!important}i.flag-dm:before,i.flag-dominica:before{background-position:0 -1508px!important}i.flag-do:before,i.flag-dominican-republic:before{background-position:0 -1534px!important}i.flag-dz:before,i.flag-algeria:before{background-position:0 -1560px!important}i.flag-ec:before,i.flag-ecuador:before{background-position:0 -1586px!important}i.flag-ee:before,i.flag-estonia:before{background-position:0 -1612px!important}i.flag-eg:before,i.flag-egypt:before{background-position:0 -1638px!important}i.flag-eh:before,i.flag-western-sahara:before{background-position:0 -1664px!important}i.flag-gb-eng:before,i.flag-england:before{background-position:0 -1690px!important}i.flag-er:before,i.flag-eritrea:before{background-position:0 -1716px!important}i.flag-es:before,i.flag-spain:before{background-position:0 -1742px!important}i.flag-et:before,i.flag-ethiopia:before{background-position:0 -1768px!important}i.flag-eu:before,i.flag-european-union:before{background-position:0 -1794px!important}i.flag-fi:before,i.flag-finland:before{background-position:0 -1846px!important}i.flag-fj:before,i.flag-fiji:before{background-position:0 -1872px!important}i.flag-fk:before,i.flag-falkland-islands:before{background-position:0 -1898px!important}i.flag-fm:before,i.flag-micronesia:before{background-position:0 -1924px!important}i.flag-fo:before,i.flag-faroe-islands:before{background-position:0 -1950px!important}i.flag-fr:before,i.flag-france:before{background-position:0 -1976px!important}i.flag-ga:before,i.flag-gabon:before{background-position:-36px 0!important}i.flag-gb:before,i.flag-uk:before,i.flag-united-kingdom:before{background-position:-36px -26px!important}i.flag-gd:before,i.flag-grenada:before{background-position:-36px -52px!important}i.flag-ge:before,i.flag-georgia:before{background-position:-36px -78px!important}i.flag-gf:before,i.flag-french-guiana:before{background-position:-36px -104px!important}i.flag-gh:before,i.flag-ghana:before{background-position:-36px -130px!important}i.flag-gi:before,i.flag-gibraltar:before{background-position:-36px -156px!important}i.flag-gl:before,i.flag-greenland:before{background-position:-36px -182px!important}i.flag-gm:before,i.flag-gambia:before{background-position:-36px -208px!important}i.flag-gn:before,i.flag-guinea:before{background-position:-36px -234px!important}i.flag-gp:before,i.flag-guadeloupe:before{background-position:-36px -260px!important}i.flag-gq:before,i.flag-equatorial-guinea:before{background-position:-36px -286px!important}i.flag-gr:before,i.flag-greece:before{background-position:-36px -312px!important}i.flag-gs:before,i.flag-sandwich-islands:before{background-position:-36px -338px!important}i.flag-gt:before,i.flag-guatemala:before{background-position:-36px -364px!important}i.flag-gu:before,i.flag-guam:before{background-position:-36px -390px!important}i.flag-gw:before,i.flag-guinea-bissau:before{background-position:-36px -416px!important}i.flag-gy:before,i.flag-guyana:before{background-position:-36px -442px!important}i.flag-hk:before,i.flag-hong-kong:before{background-position:-36px -468px!important}i.flag-hm:before,i.flag-heard-island:before{background-position:-36px -494px!important}i.flag-hn:before,i.flag-honduras:before{background-position:-36px -520px!important}i.flag-hr:before,i.flag-croatia:before{background-position:-36px -546px!important}i.flag-ht:before,i.flag-haiti:before{background-position:-36px -572px!important}i.flag-hu:before,i.flag-hungary:before{background-position:-36px -598px!important}i.flag-id:before,i.flag-indonesia:before{background-position:-36px -624px!important}i.flag-ie:before,i.flag-ireland:before{background-position:-36px -650px!important}i.flag-il:before,i.flag-israel:before{background-position:-36px -676px!important}i.flag-in:before,i.flag-india:before{background-position:-36px -702px!important}i.flag-io:before,i.flag-indian-ocean-territory:before{background-position:-36px -728px!important}i.flag-iq:before,i.flag-iraq:before{background-position:-36px -754px!important}i.flag-ir:before,i.flag-iran:before{background-position:-36px -780px!important}i.flag-is:before,i.flag-iceland:before{background-position:-36px -806px!important}i.flag-it:before,i.flag-italy:before{background-position:-36px -832px!important}i.flag-jm:before,i.flag-jamaica:before{background-position:-36px -858px!important}i.flag-jo:before,i.flag-jordan:before{background-position:-36px -884px!important}i.flag-jp:before,i.flag-japan:before{background-position:-36px -910px!important}i.flag-ke:before,i.flag-kenya:before{background-position:-36px -936px!important}i.flag-kg:before,i.flag-kyrgyzstan:before{background-position:-36px -962px!important}i.flag-kh:before,i.flag-cambodia:before{background-position:-36px -988px!important}i.flag-ki:before,i.flag-kiribati:before{background-position:-36px -1014px!important}i.flag-km:before,i.flag-comoros:before{background-position:-36px -1040px!important}i.flag-kn:before,i.flag-saint-kitts-and-nevis:before{background-position:-36px -1066px!important}i.flag-kp:before,i.flag-north-korea:before{background-position:-36px -1092px!important}i.flag-kr:before,i.flag-south-korea:before{background-position:-36px -1118px!important}i.flag-kw:before,i.flag-kuwait:before{background-position:-36px -1144px!important}i.flag-ky:before,i.flag-cayman-islands:before{background-position:-36px -1170px!important}i.flag-kz:before,i.flag-kazakhstan:before{background-position:-36px -1196px!important}i.flag-la:before,i.flag-laos:before{background-position:-36px -1222px!important}i.flag-lb:before,i.flag-lebanon:before{background-position:-36px -1248px!important}i.flag-lc:before,i.flag-saint-lucia:before{background-position:-36px -1274px!important}i.flag-li:before,i.flag-liechtenstein:before{background-position:-36px -1300px!important}i.flag-lk:before,i.flag-sri-lanka:before{background-position:-36px -1326px!important}i.flag-lr:before,i.flag-liberia:before{background-position:-36px -1352px!important}i.flag-ls:before,i.flag-lesotho:before{background-position:-36px -1378px!important}i.flag-lt:before,i.flag-lithuania:before{background-position:-36px -1404px!important}i.flag-lu:before,i.flag-luxembourg:before{background-position:-36px -1430px!important}i.flag-lv:before,i.flag-latvia:before{background-position:-36px -1456px!important}i.flag-ly:before,i.flag-libya:before{background-position:-36px -1482px!important}i.flag-ma:before,i.flag-morocco:before{background-position:-36px -1508px!important}i.flag-mc:before,i.flag-monaco:before{background-position:-36px -1534px!important}i.flag-md:before,i.flag-moldova:before{background-position:-36px -1560px!important}i.flag-me:before,i.flag-montenegro:before{background-position:-36px -1586px!important}i.flag-mg:before,i.flag-madagascar:before{background-position:-36px -1613px!important}i.flag-mh:before,i.flag-marshall-islands:before{background-position:-36px -1639px!important}i.flag-mk:before,i.flag-macedonia:before{background-position:-36px -1665px!important}i.flag-ml:before,i.flag-mali:before{background-position:-36px -1691px!important}i.flag-mm:before,i.flag-myanmar:before,i.flag-burma:before{background-position:-73px -1821px!important}i.flag-mn:before,i.flag-mongolia:before{background-position:-36px -1743px!important}i.flag-mo:before,i.flag-macau:before{background-position:-36px -1769px!important}i.flag-mp:before,i.flag-northern-mariana-islands:before{background-position:-36px -1795px!important}i.flag-mq:before,i.flag-martinique:before{background-position:-36px -1821px!important}i.flag-mr:before,i.flag-mauritania:before{background-position:-36px -1847px!important}i.flag-ms:before,i.flag-montserrat:before{background-position:-36px -1873px!important}i.flag-mt:before,i.flag-malta:before{background-position:-36px -1899px!important}i.flag-mu:before,i.flag-mauritius:before{background-position:-36px -1925px!important}i.flag-mv:before,i.flag-maldives:before{background-position:-36px -1951px!important}i.flag-mw:before,i.flag-malawi:before{background-position:-36px -1977px!important}i.flag-mx:before,i.flag-mexico:before{background-position:-72px 0!important}i.flag-my:before,i.flag-malaysia:before{background-position:-72px -26px!important}i.flag-mz:before,i.flag-mozambique:before{background-position:-72px -52px!important}i.flag-na:before,i.flag-namibia:before{background-position:-72px -78px!important}i.flag-nc:before,i.flag-new-caledonia:before{background-position:-72px -104px!important}i.flag-ne:before,i.flag-niger:before{background-position:-72px -130px!important}i.flag-nf:before,i.flag-norfolk-island:before{background-position:-72px -156px!important}i.flag-ng:before,i.flag-nigeria:before{background-position:-72px -182px!important}i.flag-ni:before,i.flag-nicaragua:before{background-position:-72px -208px!important}i.flag-nl:before,i.flag-netherlands:before{background-position:-72px -234px!important}i.flag-no:before,i.flag-norway:before{background-position:-72px -260px!important}i.flag-np:before,i.flag-nepal:before{background-position:-72px -286px!important}i.flag-nr:before,i.flag-nauru:before{background-position:-72px -312px!important}i.flag-nu:before,i.flag-niue:before{background-position:-72px -338px!important}i.flag-nz:before,i.flag-new-zealand:before{background-position:-72px -364px!important}i.flag-om:before,i.flag-oman:before{background-position:-72px -390px!important}i.flag-pa:before,i.flag-panama:before{background-position:-72px -416px!important}i.flag-pe:before,i.flag-peru:before{background-position:-72px -442px!important}i.flag-pf:before,i.flag-french-polynesia:before{background-position:-72px -468px!important}i.flag-pg:before,i.flag-new-guinea:before{background-position:-72px -494px!important}i.flag-ph:before,i.flag-philippines:before{background-position:-72px -520px!important}i.flag-pk:before,i.flag-pakistan:before{background-position:-72px -546px!important}i.flag-pl:before,i.flag-poland:before{background-position:-72px -572px!important}i.flag-pm:before,i.flag-saint-pierre:before{background-position:-72px -598px!important}i.flag-pn:before,i.flag-pitcairn-islands:before{background-position:-72px -624px!important}i.flag-pr:before,i.flag-puerto-rico:before{background-position:-72px -650px!important}i.flag-ps:before,i.flag-palestine:before{background-position:-72px -676px!important}i.flag-pt:before,i.flag-portugal:before{background-position:-72px -702px!important}i.flag-pw:before,i.flag-palau:before{background-position:-72px -728px!important}i.flag-py:before,i.flag-paraguay:before{background-position:-72px -754px!important}i.flag-qa:before,i.flag-qatar:before{background-position:-72px -780px!important}i.flag-re:before,i.flag-reunion:before{background-position:-72px -806px!important}i.flag-ro:before,i.flag-romania:before{background-position:-72px -832px!important}i.flag-rs:before,i.flag-serbia:before{background-position:-72px -858px!important}i.flag-ru:before,i.flag-russia:before{background-position:-72px -884px!important}i.flag-rw:before,i.flag-rwanda:before{background-position:-72px -910px!important}i.flag-sa:before,i.flag-saudi-arabia:before{background-position:-72px -936px!important}i.flag-sb:before,i.flag-solomon-islands:before{background-position:-72px -962px!important}i.flag-sc:before,i.flag-seychelles:before{background-position:-72px -988px!important}i.flag-gb-sct:before,i.flag-scotland:before{background-position:-72px -1014px!important}i.flag-sd:before,i.flag-sudan:before{background-position:-72px -1040px!important}i.flag-se:before,i.flag-sweden:before{background-position:-72px -1066px!important}i.flag-sg:before,i.flag-singapore:before{background-position:-72px -1092px!important}i.flag-sh:before,i.flag-saint-helena:before{background-position:-72px -1118px!important}i.flag-si:before,i.flag-slovenia:before{background-position:-72px -1144px!important}i.flag-sj:before,i.flag-svalbard:before,i.flag-jan-mayen:before{background-position:-72px -1170px!important}i.flag-sk:before,i.flag-slovakia:before{background-position:-72px -1196px!important}i.flag-sl:before,i.flag-sierra-leone:before{background-position:-72px -1222px!important}i.flag-sm:before,i.flag-san-marino:before{background-position:-72px -1248px!important}i.flag-sn:before,i.flag-senegal:before{background-position:-72px -1274px!important}i.flag-so:before,i.flag-somalia:before{background-position:-72px -1300px!important}i.flag-sr:before,i.flag-suriname:before{background-position:-72px -1326px!important}i.flag-st:before,i.flag-sao-tome:before{background-position:-72px -1352px!important}i.flag-sv:before,i.flag-el-salvador:before{background-position:-72px -1378px!important}i.flag-sy:before,i.flag-syria:before{background-position:-72px -1404px!important}i.flag-sz:before,i.flag-swaziland:before{background-position:-72px -1430px!important}i.flag-tc:before,i.flag-caicos-islands:before{background-position:-72px -1456px!important}i.flag-td:before,i.flag-chad:before{background-position:-72px -1482px!important}i.flag-tf:before,i.flag-french-territories:before{background-position:-72px -1508px!important}i.flag-tg:before,i.flag-togo:before{background-position:-72px -1534px!important}i.flag-th:before,i.flag-thailand:before{background-position:-72px -1560px!important}i.flag-tj:before,i.flag-tajikistan:before{background-position:-72px -1586px!important}i.flag-tk:before,i.flag-tokelau:before{background-position:-72px -1612px!important}i.flag-tl:before,i.flag-timorleste:before{background-position:-72px -1638px!important}i.flag-tm:before,i.flag-turkmenistan:before{background-position:-72px -1664px!important}i.flag-tn:before,i.flag-tunisia:before{background-position:-72px -1690px!important}i.flag-to:before,i.flag-tonga:before{background-position:-72px -1716px!important}i.flag-tr:before,i.flag-turkey:before{background-position:-72px -1742px!important}i.flag-tt:before,i.flag-trinidad:before{background-position:-72px -1768px!important}i.flag-tv:before,i.flag-tuvalu:before{background-position:-72px -1794px!important}i.flag-tw:before,i.flag-taiwan:before{background-position:-72px -1820px!important}i.flag-tz:before,i.flag-tanzania:before{background-position:-72px -1846px!important}i.flag-ua:before,i.flag-ukraine:before{background-position:-72px -1872px!important}i.flag-ug:before,i.flag-uganda:before{background-position:-72px -1898px!important}i.flag-um:before,i.flag-us-minor-islands:before{background-position:-72px -1924px!important}i.flag-us:before,i.flag-america:before,i.flag-united-states:before{background-position:-72px -1950px!important}i.flag-uy:before,i.flag-uruguay:before{background-position:-72px -1976px!important}i.flag-uz:before,i.flag-uzbekistan:before{background-position:-108px 0!important}i.flag-va:before,i.flag-vatican-city:before{background-position:-108px -26px!important}i.flag-vc:before,i.flag-saint-vincent:before{background-position:-108px -52px!important}i.flag-ve:before,i.flag-venezuela:before{background-position:-108px -78px!important}i.flag-vg:before,i.flag-british-virgin-islands:before{background-position:-108px -104px!important}i.flag-vi:before,i.flag-us-virgin-islands:before{background-position:-108px -130px!important}i.flag-vn:before,i.flag-vietnam:before{background-position:-108px -156px!important}i.flag-vu:before,i.flag-vanuatu:before{background-position:-108px -182px!important}i.flag-gb-wls:before,i.flag-wales:before{background-position:-108px -208px!important}i.flag-wf:before,i.flag-wallis-and-futuna:before{background-position:-108px -234px!important}i.flag-ws:before,i.flag-samoa:before{background-position:-108px -260px!important}i.flag-ye:before,i.flag-yemen:before{background-position:-108px -286px!important}i.flag-yt:before,i.flag-mayotte:before{background-position:-108px -312px!important}i.flag-za:before,i.flag-south-africa:before{background-position:-108px -338px!important}i.flag-zm:before,i.flag-zambia:before{background-position:-108px -364px!important}i.flag-zw:before,i.flag-zimbabwe:before{background-position:-108px -390px!important}.bg-fixed{background-attachment:fixed}.bg-image{position:relative;overflow:hidden;background-repeat:no-repeat;background-size:cover;background-position:center center}.mask{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;overflow:hidden;background-attachment:fixed}.hover-overlay .mask{--mdb-image-hover-transition: all .3s ease-in-out;opacity:0;transition:var(--mdb-image-hover-transition)}.hover-overlay .mask:hover{opacity:1}.hover-zoom{--mdb-image-hover-zoom-transition: all .3s linear;--mdb-image-hover-zoom-transform: scale(1.1)}.hover-zoom img,.hover-zoom video{transition:var(--mdb-image-hover-zoom-transition)}.hover-zoom:hover img,.hover-zoom:hover video{transform:var(--mdb-image-hover-zoom-transform)}.hover-shadow,.card.hover-shadow,.hover-shadow-soft,.card.hover-shadow-soft{--mdb-image-hover-shadow-transition: all .3s ease-in-out;transition:var(--mdb-image-hover-shadow-transition)}.hover-shadow:hover,.card.hover-shadow:hover,.hover-shadow-soft:hover,.card.hover-shadow-soft:hover{transition:var(--mdb-image-hover-shadow-transition)}.hover-shadow,.card.hover-shadow{--mdb-image-hover-shadow-box-shadow: 0 2px 15px -3px rgba(0, 0, 0, .16), 0 10px 20px -2px rgba(0, 0, 0, .1);box-shadow:none}.hover-shadow:hover,.card.hover-shadow:hover{box-shadow:var(--mdb-image-hover-shadow-box-shadow)}.hover-shadow-soft,.card.hover-shadow-soft{--mdb-image-hover-shadow-box-shadow-soft: 0 2px 25px -5px rgba(0, 0, 0, .07), 0 25px 21px -5px rgba(0, 0, 0, .04);box-shadow:none}.hover-shadow-soft:hover,.card.hover-shadow-soft:hover{box-shadow:var(--mdb-image-hover-shadow-box-shadow-soft)}.form-control{min-height:auto;padding:4.5px 12px 3.68px;transition:all .1s linear;box-shadow:none}.form-control:focus{box-shadow:none;transition:all .1s linear;border-color:#3b71ca;box-shadow:inset 0 0 0 1px #3b71ca}.form-control.form-control-sm{font-size:.775rem;line-height:1.5}.form-control.form-control-lg{line-height:2.15;border-radius:.25rem}.form-outline{position:relative;width:100%}.form-outline .form-helper{width:100%;position:absolute;font-size:.875em;color:#757575}.form-outline .form-helper .form-counter{text-align:right}.form-outline .trailing{position:absolute;right:10px;left:initial;top:50%;transform:translateY(-50%);pointer-events:none}.form-outline .form-icon-trailing{padding-right:2rem!important}.form-outline .form-control{min-height:auto;padding:.32rem .75rem;border:0;background:rgba(0,0,0,0);transition:all .2s linear}.form-outline .form-control~.form-label{position:absolute;top:0;max-width:90%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;left:.75rem;padding-top:.37rem;pointer-events:none;transform-origin:0 0;transition:all .2s ease-out;color:#0009;margin-bottom:0}.form-outline .form-control~.form-notch{display:flex;position:absolute;left:0;top:0;width:100%;max-width:100%;height:100%;text-align:left;pointer-events:none}.form-outline .form-control~.form-notch div{pointer-events:none;border:1px solid;border-color:#bdbdbd;box-sizing:border-box;background:rgba(0,0,0,0);transition:all .2s linear}.form-outline .form-control~.form-notch .form-notch-leading{left:0;top:0;height:100%;width:.5rem;border-right:none;border-radius:.25rem 0 0 .25rem}.form-outline .form-control~.form-notch .form-notch-middle{flex:0 0 auto;width:auto;max-width:calc(100% - 1rem);height:100%;border-right:none;border-left:none}.form-outline .form-control~.form-notch .form-notch-trailing{flex-grow:1;height:100%;border-left:none;border-radius:0 .25rem .25rem 0}.form-outline .form-control:not(.placeholder-active)::placeholder{opacity:0}.form-outline .form-control:focus::placeholder,.form-outline .form-control.active::placeholder{opacity:1}.form-outline .form-control:focus{box-shadow:none!important}.form-outline .form-control:focus~.form-label,.form-outline .form-control.active~.form-label{transform:translateY(-1rem) translateY(.1rem) scale(.8)}.form-outline .form-control:focus~.form-label{color:#3b71ca}.form-outline .form-control:focus~.form-notch .form-notch-middle,.form-outline .form-control.active~.form-notch .form-notch-middle{border-right:none;border-left:none;border-top:1px solid rgba(0,0,0,0)}.form-outline .form-control:focus~.form-notch .form-notch-middle{border-color:#3b71ca;box-shadow:0 1px #3b71ca;border-top:1px solid rgba(0,0,0,0)}.form-outline .form-control:focus~.form-notch .form-notch-leading,.form-outline .form-control.active~.form-notch .form-notch-leading{border-right:none}.form-outline .form-control:focus~.form-notch .form-notch-leading{border-color:#3b71ca;box-shadow:-1px 0 #3b71ca,0 1px #3b71ca,0 -1px #3b71ca}.form-outline .form-control:focus~.form-notch .form-notch-trailing,.form-outline .form-control.active~.form-notch .form-notch-trailing{border-left:none}.form-outline .form-control:focus~.form-notch .form-notch-trailing{border-color:#3b71ca;box-shadow:1px 0 #3b71ca,0 -1px #3b71ca,0 1px #3b71ca}.form-outline .form-control:disabled,.form-outline .form-control.disabled,.form-outline .form-control[readonly]{background-color:#e9ecef}.form-outline .form-control.form-control-lg{font-size:1rem;line-height:2.15}.form-outline .form-control.form-control-lg~.form-label{padding-top:.7rem}.form-outline .form-control.form-control-lg:focus~.form-label,.form-outline .form-control.form-control-lg.active~.form-label{transform:translateY(-1.25rem) translateY(.1rem) scale(.8)}.form-outline .form-control.form-control-sm{padding-top:.32rem;padding-bottom:.32rem;font-size:.775rem;line-height:1.5}.form-outline .form-control.form-control-sm~.form-label{padding-top:.33rem;font-size:.775rem}.form-outline .form-control.form-control-sm:focus~.form-label,.form-outline .form-control.form-control-sm.active~.form-label{transform:translateY(-.85rem) translateY(.1rem) scale(.8)}.form-outline.form-white .form-control{color:#fff}.form-outline.form-white .form-control~.form-label{color:#fbfbfb}.form-outline.form-white .form-control~.form-notch div{border-color:#fbfbfb}.form-outline.form-white .form-control:focus~.form-label{color:#fff}.form-outline.form-white .form-control:focus~.form-notch .form-notch-middle{border-color:#fff;box-shadow:0 1px #fff;border-top:1px solid rgba(0,0,0,0)}.form-outline.form-white .form-control:focus~.form-notch .form-notch-leading{border-color:#fff;box-shadow:-1px 0 #fff,0 1px #fff,0 -1px #fff}.form-outline.form-white .form-control:focus~.form-notch .form-notch-trailing{border-color:#fff;box-shadow:1px 0 #fff,0 -1px #fff,0 1px #fff}.form-outline.form-white .form-control::placeholder{color:#ffffffb3}.form-outline.form-white .form-control:disabled,.form-outline.form-white .form-control.disabled,.form-outline.form-white .form-control[readonly]{background-color:#ffffff73}.select-input.form-control[readonly]:not([disabled]){background-color:#0000}.form-select{transition:all .2s linear}.form-select:focus{border-color:#3b71ca;outline:0;box-shadow:inset 0 0 0 1px #3b71ca}.form-check{min-height:1.5rem}.form-check-input{position:relative;width:1.125rem;height:1.125rem;background-color:#fff;border:.125rem solid rgba(0,0,0,.25)}.form-check-input:before{content:"";position:absolute;box-shadow:0 0 0 13px #0000;border-radius:50%;width:.875rem;height:.875rem;background-color:#0000;opacity:0;pointer-events:none;transform:scale(0)}.form-check-input:hover{cursor:pointer}.form-check-input:hover:before{opacity:.04;box-shadow:0 0 0 13px #0009}.form-check-input:focus{box-shadow:none;border-color:#00000040;transition:border-color .2s}.form-check-input:focus:before{opacity:.12;box-shadow:0 0 0 13px #0009;transform:scale(1);transition:box-shadow .2s,transform .2s}.form-check-input:checked{border-color:#3b71ca}.form-check-input:checked:before{opacity:.16}.form-check-input:checked:after{content:"";position:absolute}.form-check-input:checked:focus{border-color:#3b71ca}.form-check-input:checked:focus:before{box-shadow:0 0 0 13px #3b71ca;transform:scale(1);transition:box-shadow .2s,transform .2s}.form-check-input:indeterminate:focus:before{box-shadow:0 0 0 13px #3b71ca}.form-check-input[type=checkbox]{border-radius:.25rem;margin-top:.19em;margin-right:6px}.form-check-input[type=checkbox]:focus:after{content:"";position:absolute;width:.875rem;height:.875rem;z-index:1;display:block;border-radius:0;background-color:#fff}.form-check-input[type=checkbox]:checked{background-image:none;background-color:#3b71ca}.form-check-input[type=checkbox]:checked:after{display:block;transform:rotate(45deg);border-width:.125rem;border-color:#fff;width:.375rem;height:.8125rem;border-style:solid;border-top:0;border-left:0;margin-left:.25rem;margin-top:-1px;background-color:#0000}.form-check-input[type=checkbox]:checked:focus{background-color:#3b71ca}.form-check-input[type=checkbox]:indeterminate{border-color:#3b71ca}.form-check-input[type=radio]{border-radius:50%;width:1.25rem;height:1.25rem;margin-top:.125em;margin-right:4px}.form-check-input[type=radio]:before{width:1rem;height:1rem}.form-check-input[type=radio]:after{content:"";position:absolute;width:1rem;height:1rem;z-index:1;display:block;border-radius:50%;background-color:#fff}.form-check-input[type=radio]:checked{background-image:none;background-color:#fff}.form-check-input[type=radio]:checked:after{border-radius:50%;width:.625rem;height:.625rem;border-color:#3b71ca;background-color:#3b71ca;transition:border-color;transform:translate(-50%,-50%);position:absolute;left:50%;top:50%}.form-check-input[type=radio]:checked:focus{background-color:#fff}.form-check-label:hover{cursor:pointer}.form-switch .form-check-input{background-image:none;border-width:0;border-radius:.4375rem;width:2rem;height:.875rem;background-color:#00000040;margin-top:.3em;margin-right:8px}.form-switch .form-check-input:after{content:"";position:absolute;border:none;z-index:2;border-radius:50%;width:1.25rem;height:1.25rem;background-color:#fff;margin-top:-.1875rem;box-shadow:0 0 3px #00000012,0 2px 2px #0000000a;transition:background-color .2s,transform .2s}.form-switch .form-check-input:focus{background-image:none}.form-switch .form-check-input:focus:before{box-shadow:3px -1px 0 13px #0009;transform:scale(1);transition:box-shadow .2s,transform .2s}.form-switch .form-check-input:focus:after{border-radius:50%;width:1.25rem;height:1.25rem}.form-switch .form-check-input:checked{background-image:none}.form-switch .form-check-input:checked:focus{background-image:none}.form-switch .form-check-input:checked:focus:before{margin-left:1.0625rem;box-shadow:3px -1px 0 13px #3b71ca;transform:scale(1);transition:box-shadow .2s,transform .2s}.form-switch .form-check-input:checked[type=checkbox]{background-image:none}.form-switch .form-check-input:checked[type=checkbox]:after{content:"";position:absolute;border:none;z-index:2;border-radius:50%;width:1.25rem;height:1.25rem;background-color:#3b71ca;margin-top:-3px;margin-left:1.0625rem;box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f;transition:background-color .2s,transform .2s}.form-control[type=file]::-webkit-file-upload-button{background-color:#0000}.form-control:hover:not(:disabled):not([readonly])::-webkit-file-upload-button{background-color:#0000}.input-group{flex-wrap:nowrap}.input-group>.form-control{min-height:calc(2.08rem + 2px);height:calc(2.08rem + 2px);padding-top:.27rem;padding-bottom:.27rem;transition:all .2s linear}.input-group>.form-control:focus{transition:all .2s linear;border-color:#3b71ca;outline:0;box-shadow:inset 0 0 0 1px #3b71ca}.input-group-text{background-color:#0000;padding-top:.26rem;padding-bottom:.26rem}.input-group-text>.form-check-input[type=checkbox]{margin-left:1px;margin-right:1px}.input-group-text>.form-check-input[type=radio]{margin-right:0}.input-group-lg>.form-control{height:calc(2.645rem + 2px);font-size:1rem;padding-top:.33rem;padding-bottom:.33rem}.input-group-lg .input-group-text{font-size:1rem}.input-group-sm>.form-control{min-height:calc(1.66rem + 2px);height:calc(1.66rem + 2px);font-size:.775rem;padding-top:.33rem;padding-bottom:.33rem}.input-group-sm .input-group-text{font-size:.775rem;line-height:1.5}.input-group.form-outline .input-group-text{border-left:0}.input-group.form-outline input+.input-group-text{border:0;border-left:1px solid #bdbdbd}.input-group .form-outline:not(:first-child),.input-group .select-wrapper:not(:first-child),.input-group .form-outline:not(:first-child) .form-notch-leading,.input-group .select-wrapper:not(:first-child) .form-notch-leading{border-top-left-radius:0!important;border-bottom-left-radius:0!important}.input-group .form-outline:not(:last-child),.input-group .select-wrapper:not(:last-child),.input-group .form-outline:not(:last-child) .form-notch-trailing,.input-group .select-wrapper:not(:last-child) .form-notch-trailing{border-top-right-radius:0!important;border-bottom-right-radius:0!important}.input-group>[class*=btn-outline-]+[class*=btn-outline-]{border-left:0}.input-group>.btn[class*=btn-outline-]{padding-top:.47rem}.input-group>.btn{padding-top:.59rem}.input-group.input-group-lg .input-group-text{height:calc(2.645rem + 2px)}.input-group .input-group-text{height:calc(2.08rem + 2px)}.input-group .btn{line-height:1}.input-group.input-group-sm .input-group-text{height:calc(1.66rem + 2px)}.was-validated .input-group .invalid-feedback,.was-validated .input-group .valid-feedback,.input-group .invalid-feedback,.input-group .valid-feedback{margin-top:2.5rem}.valid-feedback{position:absolute;display:none;width:auto;margin-top:.25rem;font-size:.875rem;color:#14a44d;margin-top:-.75rem}.valid-tooltip{position:absolute;top:100%;z-index:5;display:none;max-width:100%;padding:6px 16px;margin-top:.1rem;font-size:.875rem;background-color:#14a44de6;border-radius:.25rem!important;color:#fff}.was-validated :valid~.valid-feedback,.was-validated :valid~.valid-tooltip,.is-valid~.valid-feedback,.is-valid~.valid-tooltip{display:block}.was-validated .form-control:valid,.form-control.is-valid{margin-bottom:1rem;background-image:none;border-color:#14a44d}.was-validated .form-control:valid:focus,.form-control.is-valid:focus{border-color:#14a44d;box-shadow:0 0 0 .25rem #14a44d40}.was-validated .form-outline .form-control:valid~.form-label,.form-outline .form-control.is-valid~.form-label{color:#14a44d}.was-validated .form-outline .form-control:valid~.form-notch .form-notch-leading,.was-validated .form-outline .form-control:valid~.form-notch .form-notch-middle,.was-validated .form-outline .form-control:valid~.form-notch .form-notch-trailing,.form-outline .form-control.is-valid~.form-notch .form-notch-leading,.form-outline .form-control.is-valid~.form-notch .form-notch-middle,.form-outline .form-control.is-valid~.form-notch .form-notch-trailing{border-color:#14a44d}.was-validated .form-outline .form-control:valid:focus~.form-notch .form-notch-middle,.was-validated .form-outline .form-control:valid.active~.form-notch .form-notch-middle,.form-outline .form-control.is-valid:focus~.form-notch .form-notch-middle,.form-outline .form-control.is-valid.active~.form-notch .form-notch-middle{border-top:1px solid rgba(0,0,0,0)}.was-validated .form-outline .form-control:valid:focus~.form-notch .form-notch-middle,.form-outline .form-control.is-valid:focus~.form-notch .form-notch-middle{box-shadow:0 1px #14a44d}.was-validated .form-outline .form-control:valid:focus~.form-notch .form-notch-leading,.form-outline .form-control.is-valid:focus~.form-notch .form-notch-leading{box-shadow:-1px 0 #14a44d,0 1px #14a44d,0 -1px #14a44d}.was-validated .form-outline .form-control:valid:focus~.form-notch .form-notch-trailing,.form-outline .form-control.is-valid:focus~.form-notch .form-notch-trailing{box-shadow:1px 0 #14a44d,0 -1px #14a44d,0 1px #14a44d}.was-validated .form-outline .form-control:valid.select-input.focused~.form-notch .form-notch-leading,.form-outline .form-control.is-valid.select-input.focused~.form-notch .form-notch-leading{box-shadow:-1px 0 #14a44d,0 1px #14a44d,0 -1px #14a44d}.was-validated .form-outline .form-control:valid.select-input.focused~.form-notch .form-notch-middle,.form-outline .form-control.is-valid.select-input.focused~.form-notch .form-notch-middle{box-shadow:0 1px #14a44d;border-top:1px solid rgba(0,0,0,0)}.was-validated .form-outline .form-control:valid.select-input.focused~.form-notch .form-notch-trailing,.form-outline .form-control.is-valid.select-input.focused~.form-notch .form-notch-trailing{box-shadow:1px 0 #14a44d,0 -1px #14a44d,0 1px #14a44d}.was-validated .form-select:valid,.form-select.is-valid{border-color:#14a44d}.was-validated .form-select:valid:focus,.form-select.is-valid:focus{border-color:#14a44d;box-shadow:0 0 0 .25rem #14a44d40}.was-validated .form-select:valid~.valid-feedback,.form-select.is-valid~.valid-feedback{margin-top:0}.was-validated .input-group .form-control:valid,.input-group .form-control.is-valid{margin-bottom:0}.was-validated input[type=file].form-control:valid .valid-feedback,input[type=file].form-control.is-valid .valid-feedback{margin-top:0}.was-validated input[type=file].form-control:valid:focus,input[type=file].form-control.is-valid:focus{box-shadow:inset 0 0 0 1px #14a44d;border-color:#14a44d}.was-validated input[type=file].form-control:valid:focus~.form-file-label,input[type=file].form-control.is-valid:focus~.form-file-label{box-shadow:none}.was-validated input[type=file].form-control:valid:focus-within~.form-file-label .form-file-text,.was-validated input[type=file].form-control:valid:focus-within~.form-file-label .form-file-button,input[type=file].form-control.is-valid:focus-within~.form-file-label .form-file-text,input[type=file].form-control.is-valid:focus-within~.form-file-label .form-file-button{border-color:#14a44d}.was-validated .form-check-input:valid,.form-check-input.is-valid{border-color:#14a44d}.was-validated .form-check-input:valid:checked,.form-check-input.is-valid:checked{background-color:#14a44d}.was-validated .form-check-input:valid:checked:focus:before,.form-check-input.is-valid:checked:focus:before{box-shadow:0 0 0 13px #14a44d}.was-validated .form-check-input:valid:focus,.form-check-input.is-valid:focus{box-shadow:none}.was-validated .form-check-input:valid:focus:before,.form-check-input.is-valid:focus:before{box-shadow:0 0 0 13px #14a44d}.was-validated .form-check-input:valid~.form-check-label,.form-check-input.is-valid~.form-check-label{color:#14a44d;margin-bottom:1rem}.was-validated .form-check-input:valid[type=checkbox]:checked:focus,.form-check-input.is-valid[type=checkbox]:checked:focus{background-color:#14a44d;border-color:#14a44d}.was-validated .form-check-input:valid[type=radio]:checked,.form-check-input.is-valid[type=radio]:checked{border-color:#14a44d;background-color:#fff}.was-validated .form-check-input:valid[type=radio]:checked:focus:before,.form-check-input.is-valid[type=radio]:checked:focus:before{box-shadow:0 0 0 13px #14a44d}.was-validated .form-check-input:valid[type=radio]:checked:after,.form-check-input.is-valid[type=radio]:checked:after{border-color:#14a44d;background-color:#14a44d}.form-check-inline .form-check-input~.valid-feedback{margin-left:.5em}.was-validated .form-switch .form-check-input:valid:focus:before,.form-switch .form-check-input.is-valid:focus:before{box-shadow:3px -1px 0 13px #0009}.was-validated .form-switch .form-check-input:valid:checked[type=checkbox]:after,.form-switch .form-check-input.is-valid:checked[type=checkbox]:after{background-color:#14a44d;box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f}.was-validated .form-switch .form-check-input:valid:checked:focus:before,.form-switch .form-check-input.is-valid:checked:focus:before{box-shadow:3px -1px 0 13px #14a44d}.invalid-feedback{position:absolute;display:none;width:auto;margin-top:.25rem;font-size:.875rem;color:#dc4c64;margin-top:-.75rem}.invalid-tooltip{position:absolute;top:100%;z-index:5;display:none;max-width:100%;padding:6px 16px;margin-top:.1rem;font-size:.875rem;background-color:#dc4c64e6;border-radius:.25rem!important;color:#fff}.was-validated :invalid~.invalid-feedback,.was-validated :invalid~.invalid-tooltip,.is-invalid~.invalid-feedback,.is-invalid~.invalid-tooltip{display:block}.was-validated .form-control:invalid,.form-control.is-invalid{margin-bottom:1rem;background-image:none;border-color:#dc4c64}.was-validated .form-control:invalid:focus,.form-control.is-invalid:focus{border-color:#dc4c64;box-shadow:0 0 0 .25rem #dc4c6440}.was-validated .form-outline .form-control:invalid~.form-label,.form-outline .form-control.is-invalid~.form-label{color:#dc4c64}.was-validated .form-outline .form-control:invalid~.form-notch .form-notch-leading,.was-validated .form-outline .form-control:invalid~.form-notch .form-notch-middle,.was-validated .form-outline .form-control:invalid~.form-notch .form-notch-trailing,.form-outline .form-control.is-invalid~.form-notch .form-notch-leading,.form-outline .form-control.is-invalid~.form-notch .form-notch-middle,.form-outline .form-control.is-invalid~.form-notch .form-notch-trailing{border-color:#dc4c64}.was-validated .form-outline .form-control:invalid:focus~.form-notch .form-notch-middle,.was-validated .form-outline .form-control:invalid.active~.form-notch .form-notch-middle,.form-outline .form-control.is-invalid:focus~.form-notch .form-notch-middle,.form-outline .form-control.is-invalid.active~.form-notch .form-notch-middle{border-top:1px solid rgba(0,0,0,0)}.was-validated .form-outline .form-control:invalid:focus~.form-notch .form-notch-middle,.form-outline .form-control.is-invalid:focus~.form-notch .form-notch-middle{box-shadow:0 1px #dc4c64}.was-validated .form-outline .form-control:invalid:focus~.form-notch .form-notch-leading,.form-outline .form-control.is-invalid:focus~.form-notch .form-notch-leading{box-shadow:-1px 0 #dc4c64,0 1px #dc4c64,0 -1px #dc4c64}.was-validated .form-outline .form-control:invalid:focus~.form-notch .form-notch-trailing,.form-outline .form-control.is-invalid:focus~.form-notch .form-notch-trailing{box-shadow:1px 0 #dc4c64,0 -1px #dc4c64,0 1px #dc4c64}.was-validated .form-outline .form-control:invalid.select-input.focused~.form-notch .form-notch-leading,.form-outline .form-control.is-invalid.select-input.focused~.form-notch .form-notch-leading{box-shadow:-1px 0 #dc4c64,0 1px #dc4c64,0 -1px #dc4c64}.was-validated .form-outline .form-control:invalid.select-input.focused~.form-notch .form-notch-middle,.form-outline .form-control.is-invalid.select-input.focused~.form-notch .form-notch-middle{box-shadow:0 1px #dc4c64;border-top:1px solid rgba(0,0,0,0)}.was-validated .form-outline .form-control:invalid.select-input.focused~.form-notch .form-notch-trailing,.form-outline .form-control.is-invalid.select-input.focused~.form-notch .form-notch-trailing{box-shadow:1px 0 #dc4c64,0 -1px #dc4c64,0 1px #dc4c64}.was-validated .form-select:invalid,.form-select.is-invalid{border-color:#dc4c64}.was-validated .form-select:invalid:focus,.form-select.is-invalid:focus{border-color:#dc4c64;box-shadow:0 0 0 .25rem #dc4c6440}.was-validated .form-select:invalid~.invalid-feedback,.form-select.is-invalid~.invalid-feedback{margin-top:0}.was-validated .input-group .form-control:invalid,.input-group .form-control.is-invalid{margin-bottom:0}.was-validated input[type=file].form-control:invalid .invalid-feedback,input[type=file].form-control.is-invalid .invalid-feedback{margin-top:0}.was-validated input[type=file].form-control:invalid:focus,input[type=file].form-control.is-invalid:focus{box-shadow:inset 0 0 0 1px #dc4c64;border-color:#dc4c64}.was-validated input[type=file].form-control:invalid:focus~.form-file-label,input[type=file].form-control.is-invalid:focus~.form-file-label{box-shadow:none}.was-validated input[type=file].form-control:invalid:focus-within~.form-file-label .form-file-text,.was-validated input[type=file].form-control:invalid:focus-within~.form-file-label .form-file-button,input[type=file].form-control.is-invalid:focus-within~.form-file-label .form-file-text,input[type=file].form-control.is-invalid:focus-within~.form-file-label .form-file-button{border-color:#dc4c64}.was-validated .form-check-input:invalid,.form-check-input.is-invalid{border-color:#dc4c64}.was-validated .form-check-input:invalid:checked,.form-check-input.is-invalid:checked{background-color:#dc4c64}.was-validated .form-check-input:invalid:checked:focus:before,.form-check-input.is-invalid:checked:focus:before{box-shadow:0 0 0 13px #dc4c64}.was-validated .form-check-input:invalid:focus,.form-check-input.is-invalid:focus{box-shadow:none}.was-validated .form-check-input:invalid:focus:before,.form-check-input.is-invalid:focus:before{box-shadow:0 0 0 13px #dc4c64}.was-validated .form-check-input:invalid~.form-check-label,.form-check-input.is-invalid~.form-check-label{color:#dc4c64;margin-bottom:1rem}.was-validated .form-check-input:invalid[type=checkbox]:checked:focus,.form-check-input.is-invalid[type=checkbox]:checked:focus{background-color:#dc4c64;border-color:#dc4c64}.was-validated .form-check-input:invalid[type=radio]:checked,.form-check-input.is-invalid[type=radio]:checked{border-color:#dc4c64;background-color:#fff}.was-validated .form-check-input:invalid[type=radio]:checked:focus:before,.form-check-input.is-invalid[type=radio]:checked:focus:before{box-shadow:0 0 0 13px #dc4c64}.was-validated .form-check-input:invalid[type=radio]:checked:after,.form-check-input.is-invalid[type=radio]:checked:after{border-color:#dc4c64;background-color:#dc4c64}.form-check-inline .form-check-input~.invalid-feedback{margin-left:.5em}.was-validated .form-switch .form-check-input:invalid:focus:before,.form-switch .form-check-input.is-invalid:focus:before{box-shadow:3px -1px 0 13px #0009}.was-validated .form-switch .form-check-input:invalid:checked[type=checkbox]:after,.form-switch .form-check-input.is-invalid:checked[type=checkbox]:after{background-color:#dc4c64;box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f}.was-validated .form-switch .form-check-input:invalid:checked:focus:before,.form-switch .form-check-input.is-invalid:checked:focus:before{box-shadow:3px -1px 0 13px #dc4c64}.form-range:focus{box-shadow:none}.form-range:focus::-webkit-slider-thumb{box-shadow:none}.form-range:focus::-moz-range-thumb{box-shadow:none}.form-range:focus::-ms-thumb{box-shadow:none}.form-range::-moz-focus-outer{border:0}.form-range::-webkit-slider-thumb{margin-top:-6px;box-shadow:none;-webkit-appearance:none;-moz-appearance:none;appearance:none}.form-range::-webkit-slider-runnable-track{height:4px;border-radius:0;box-shadow:none}.form-range::-moz-range-thumb{box-shadow:none;-webkit-appearance:none;-moz-appearance:none;appearance:none}.form-range::-moz-range-track{box-shadow:none}.table{--mdb-table-font-size: .9rem;--mdb-table-divider-color: rgba(0, 0, 0, .1);font-size:var(--mdb-table-font-size)}.table th{font-weight:500}.table tbody{font-weight:400}.table>:not(:last-child)>:last-child>*{border-bottom-color:inherit}.table-primary{--mdb-table-color: #000;--mdb-table-bg: #d8e3f4;--mdb-table-border-color: #c2ccdc;--mdb-table-striped-bg: #cdd8e8;--mdb-table-striped-color: #000;--mdb-table-active-bg: #c2ccdc;--mdb-table-active-color: #000;--mdb-table-hover-bg: #c8d2e2;--mdb-table-hover-color: #000;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-secondary{--mdb-table-color: #000;--mdb-table-bg: #ecedf0;--mdb-table-border-color: #d4d5d8;--mdb-table-striped-bg: #e0e1e4;--mdb-table-striped-color: #000;--mdb-table-active-bg: #d4d5d8;--mdb-table-active-color: #000;--mdb-table-hover-bg: #dadbde;--mdb-table-hover-color: #000;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-success{--mdb-table-color: #000;--mdb-table-bg: #d0eddb;--mdb-table-border-color: #bbd5c5;--mdb-table-striped-bg: #c6e1d0;--mdb-table-striped-color: #000;--mdb-table-active-bg: #bbd5c5;--mdb-table-active-color: #000;--mdb-table-hover-bg: #c0dbcb;--mdb-table-hover-color: #000;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-info{--mdb-table-color: #000;--mdb-table-bg: #ddf0f6;--mdb-table-border-color: #c7d8dd;--mdb-table-striped-bg: #d2e4ea;--mdb-table-striped-color: #000;--mdb-table-active-bg: #c7d8dd;--mdb-table-active-color: #000;--mdb-table-hover-bg: #ccdee4;--mdb-table-hover-color: #000;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-warning{--mdb-table-color: #000;--mdb-table-bg: #faecd1;--mdb-table-border-color: #e1d4bc;--mdb-table-striped-bg: #eee0c7;--mdb-table-striped-color: #000;--mdb-table-active-bg: #e1d4bc;--mdb-table-active-color: #000;--mdb-table-hover-bg: #e7dac1;--mdb-table-hover-color: #000;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-danger{--mdb-table-color: #000;--mdb-table-bg: #f8dbe0;--mdb-table-border-color: #dfc5ca;--mdb-table-striped-bg: #ecd0d5;--mdb-table-striped-color: #000;--mdb-table-active-bg: #dfc5ca;--mdb-table-active-color: #000;--mdb-table-hover-bg: #e5cbcf;--mdb-table-hover-color: #000;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-light{--mdb-table-color: #000;--mdb-table-bg: #fbfbfb;--mdb-table-border-color: #e2e2e2;--mdb-table-striped-bg: #eeeeee;--mdb-table-striped-color: #000;--mdb-table-active-bg: #e2e2e2;--mdb-table-active-color: #000;--mdb-table-hover-bg: #e8e8e8;--mdb-table-hover-color: #000;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-dark{--mdb-table-color: #fff;--mdb-table-bg: #332d2d;--mdb-table-border-color: #474242;--mdb-table-striped-bg: #3d3838;--mdb-table-striped-color: #fff;--mdb-table-active-bg: #474242;--mdb-table-active-color: #fff;--mdb-table-hover-bg: #423d3d;--mdb-table-hover-color: #fff;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-hover>tbody>tr{transition:.5s}.table-hover>tbody>tr:hover{--mdb-table-accent-bg: transparent;background-color:var(--mdb-table-hover-bg)}.table-group-divider{border-top:2px solid;border-top-color:inherit}.table-divider-color{border-top-color:var(--mdb-table-divider-color)}.btn{--mdb-btn-padding-top: .625rem;--mdb-btn-padding-bottom: .5rem;--mdb-btn-border-width: 0;--mdb-btn-border-color: none;--mdb-btn-border-radius: .25rem;--mdb-btn-box-shadow: 0 4px 9px -4px rgba(0, 0, 0, .35);--mdb-btn-hover-box-shadow: 0 8px 9px -4px rgba(0, 0, 0, .15), 0 4px 18px 0 rgba(0, 0, 0, .1);--mdb-btn-focus-box-shadow: 0 8px 9px -4px rgba(0, 0, 0, .15), 0 4px 18px 0 rgba(0, 0, 0, .1);--mdb-btn-active-box-shadow: 0 8px 9px -4px rgba(0, 0, 0, .15), 0 4px 18px 0 rgba(0, 0, 0, .1);padding-top:var(--mdb-btn-padding-top);padding-bottom:var(--mdb-btn-padding-bottom);text-transform:uppercase;vertical-align:bottom;border:0;border-radius:var(--mdb-btn-border-radius);box-shadow:var(--mdb-btn-box-shadow)}:not(.btn-check)+.btn:hover,.btn:first-child:hover,.btn:focus-visible,.btn:hover{box-shadow:var(--mdb-btn-hover-box-shadow)}.btn-check:focus-visible+.btn,.btn-check:focus+.btn,.btn:focus{box-shadow:var(--mdb-btn-focus-box-shadow)}.btn-check:checked+.btn,.btn-check:active+.btn,.btn:active,.btn.active,.btn.show{box-shadow:var(--mdb-btn-active-box-shadow)}.btn-check:checked+.btn:focus,.btn-check:active+.btn:focus,.btn:active:focus,.btn.active:focus,.btn.show:focus{box-shadow:var(--mdb-btn-focus-box-shadow)}.btn:disabled,.btn.disabled,fieldset:disabled .btn{box-shadow:var(--mdb-btn-box-shadow)}[class*=btn-outline-]{--mdb-btn-padding-top: .5rem;--mdb-btn-padding-bottom: .375rem;--mdb-btn-padding-x: 1.375rem;--mdb-btn-border-width: 2px;--mdb-btn-line-height: 1.5;padding:var(--mdb-btn-padding-top) var(--mdb-btn-padding-x) var(--mdb-btn-padding-bottom);border-width:var(--mdb-btn-border-width);border-style:solid;box-shadow:none}:not(.btn-check)+[class*=btn-outline-]:hover,[class*=btn-outline-]:first-child:hover,[class*=btn-outline-]:focus-visible,[class*=btn-outline-]:hover{box-shadow:none}.btn-check:focus-visible+[class*=btn-outline-],.btn-check:focus+[class*=btn-outline-],[class*=btn-outline-]:focus{box-shadow:none}.btn-check:checked+[class*=btn-outline-],.btn-check:active+[class*=btn-outline-],[class*=btn-outline-]:active,[class*=btn-outline-].active,[class*=btn-outline-].show{box-shadow:none}.btn-check:checked+[class*=btn-outline-]:focus,.btn-check:active+[class*=btn-outline-]:focus,[class*=btn-outline-]:active:focus,[class*=btn-outline-].active:focus,[class*=btn-outline-].show:focus{box-shadow:none}[class*=btn-outline-]:disabled,[class*=btn-outline-].disabled,fieldset:disabled [class*=btn-outline-]{box-shadow:none}[class*=btn-outline-].btn-lg,.btn-group-lg>[class*=btn-outline-].btn{--mdb-btn-padding-top: .625rem;--mdb-btn-padding-bottom: .5625rem;--mdb-btn-padding-x: 1.5625rem;--mdb-btn-font-size:.875rem;--mdb-btn-line-height: 1.6}[class*=btn-outline-].btn-sm,.btn-group-sm>[class*=btn-outline-].btn{--mdb-btn-padding-top: .25rem;--mdb-btn-padding-bottom: .1875rem;--mdb-btn-padding-x: .875rem;--mdb-btn-font-size:.75rem;--mdb-btn-line-height: 1.5}.btn-secondary{box-shadow:none}:not(.btn-check)+.btn-secondary:hover,.btn-secondary:first-child:hover,.btn-secondary:focus-visible,.btn-secondary:hover{box-shadow:none!important}.btn-check:focus-visible+.btn-secondary,.btn-check:focus+.btn-secondary,.btn-secondary:focus{box-shadow:none}.btn-check:checked+.btn-secondary,.btn-check:active+.btn-secondary,.btn-secondary:active,.btn-secondary.active,.btn-secondary.show{box-shadow:none}.btn-check:checked+.btn-secondary:focus,.btn-check:active+.btn-secondary:focus,.btn-secondary:active:focus,.btn-secondary.active:focus,.btn-secondary.show:focus{box-shadow:none}.btn-secondary:disabled,.btn-secondary.disabled,fieldset:disabled .btn-secondary{box-shadow:none}.btn-primary{--mdb-btn-bg: #3b71ca;--mdb-btn-color: #fff;--mdb-btn-box-shadow: 0 4px 9px -4px #3b71ca;--mdb-btn-hover-bg: #386bc0;--mdb-btn-hover-color: #fff;--mdb-btn-focus-bg: #386bc0;--mdb-btn-focus-color: #fff;--mdb-btn-active-bg: #3566b6;--mdb-btn-active-color: #fff}:not(.btn-check)+.btn-primary:hover,.btn-primary:first-child:hover,.btn-primary:focus-visible,.btn-primary:hover{box-shadow:0 8px 9px -4px #3b71ca4d,0 4px 18px #3b71ca33}.btn-check:focus-visible+.btn-primary,.btn-check:focus+.btn-primary,.btn-primary:focus{box-shadow:0 8px 9px -4px #3b71ca4d,0 4px 18px #3b71ca33;background-color:#386bc0}.btn-check:checked+.btn-primary,.btn-check:active+.btn-primary,.btn-primary:active,.btn-primary.active,.btn-primary.show{box-shadow:0 8px 9px -4px #3b71ca4d,0 4px 18px #3b71ca33}.btn-check:checked+.btn-primary:focus,.btn-check:active+.btn-primary:focus,.btn-primary:active:focus,.btn-primary.active:focus,.btn-primary.show:focus{box-shadow:0 8px 9px -4px #3b71ca4d,0 4px 18px #3b71ca33}.btn-check:checked+.btn-primary:hover,.btn-check:active+.btn-primary:hover,.btn-primary:active:hover,.btn-primary.active:hover,.btn-primary.show:hover{background-color:#3566b6}.btn-primary:disabled,.btn-primary.disabled,fieldset:disabled .btn-primary{box-shadow:0 4px 9px -4px #3b71ca}.btn-secondary{--mdb-btn-bg: #e3ebf7;--mdb-btn-color: #285192;--mdb-btn-box-shadow: 0 4px 9px -4px #e3ebf7;--mdb-btn-hover-bg: #d8dfeb;--mdb-btn-hover-color: #285192;--mdb-btn-focus-bg: #d8dfeb;--mdb-btn-focus-color: #285192;--mdb-btn-active-bg: #ccd4de;--mdb-btn-active-color: #285192}:not(.btn-check)+.btn-secondary:hover,.btn-secondary:first-child:hover,.btn-secondary:focus-visible,.btn-secondary:hover{box-shadow:0 8px 9px -4px #e3ebf74d,0 4px 18px #e3ebf733}.btn-check:focus-visible+.btn-secondary,.btn-check:focus+.btn-secondary,.btn-secondary:focus{box-shadow:0 8px 9px -4px #e3ebf74d,0 4px 18px #e3ebf733;background-color:#d8dfeb}.btn-check:checked+.btn-secondary,.btn-check:active+.btn-secondary,.btn-secondary:active,.btn-secondary.active,.btn-secondary.show{box-shadow:0 8px 9px -4px #e3ebf74d,0 4px 18px #e3ebf733}.btn-check:checked+.btn-secondary:focus,.btn-check:active+.btn-secondary:focus,.btn-secondary:active:focus,.btn-secondary.active:focus,.btn-secondary.show:focus{box-shadow:0 8px 9px -4px #e3ebf74d,0 4px 18px #e3ebf733}.btn-check:checked+.btn-secondary:hover,.btn-check:active+.btn-secondary:hover,.btn-secondary:active:hover,.btn-secondary.active:hover,.btn-secondary.show:hover{background-color:#ccd4de}.btn-secondary:disabled,.btn-secondary.disabled,fieldset:disabled .btn-secondary{box-shadow:0 4px 9px -4px #e3ebf7}.btn-success{--mdb-btn-bg: #14a44d;--mdb-btn-color: #fff;--mdb-btn-box-shadow: 0 4px 9px -4px #14a44d;--mdb-btn-hover-bg: #139c49;--mdb-btn-hover-color: #fff;--mdb-btn-focus-bg: #139c49;--mdb-btn-focus-color: #fff;--mdb-btn-active-bg: #129445;--mdb-btn-active-color: #fff}:not(.btn-check)+.btn-success:hover,.btn-success:first-child:hover,.btn-success:focus-visible,.btn-success:hover{box-shadow:0 8px 9px -4px #14a44d4d,0 4px 18px #14a44d33}.btn-check:focus-visible+.btn-success,.btn-check:focus+.btn-success,.btn-success:focus{box-shadow:0 8px 9px -4px #14a44d4d,0 4px 18px #14a44d33;background-color:#139c49}.btn-check:checked+.btn-success,.btn-check:active+.btn-success,.btn-success:active,.btn-success.active,.btn-success.show{box-shadow:0 8px 9px -4px #14a44d4d,0 4px 18px #14a44d33}.btn-check:checked+.btn-success:focus,.btn-check:active+.btn-success:focus,.btn-success:active:focus,.btn-success.active:focus,.btn-success.show:focus{box-shadow:0 8px 9px -4px #14a44d4d,0 4px 18px #14a44d33}.btn-check:checked+.btn-success:hover,.btn-check:active+.btn-success:hover,.btn-success:active:hover,.btn-success.active:hover,.btn-success.show:hover{background-color:#129445}.btn-success:disabled,.btn-success.disabled,fieldset:disabled .btn-success{box-shadow:0 4px 9px -4px #14a44d}.btn-danger{--mdb-btn-bg: #dc4c64;--mdb-btn-color: #fff;--mdb-btn-box-shadow: 0 4px 9px -4px #dc4c64;--mdb-btn-hover-bg: #d1485f;--mdb-btn-hover-color: #fff;--mdb-btn-focus-bg: #d1485f;--mdb-btn-focus-color: #fff;--mdb-btn-active-bg: #c6445a;--mdb-btn-active-color: #fff}:not(.btn-check)+.btn-danger:hover,.btn-danger:first-child:hover,.btn-danger:focus-visible,.btn-danger:hover{box-shadow:0 8px 9px -4px #dc4c644d,0 4px 18px #dc4c6433}.btn-check:focus-visible+.btn-danger,.btn-check:focus+.btn-danger,.btn-danger:focus{box-shadow:0 8px 9px -4px #dc4c644d,0 4px 18px #dc4c6433;background-color:#d1485f}.btn-check:checked+.btn-danger,.btn-check:active+.btn-danger,.btn-danger:active,.btn-danger.active,.btn-danger.show{box-shadow:0 8px 9px -4px #dc4c644d,0 4px 18px #dc4c6433}.btn-check:checked+.btn-danger:focus,.btn-check:active+.btn-danger:focus,.btn-danger:active:focus,.btn-danger.active:focus,.btn-danger.show:focus{box-shadow:0 8px 9px -4px #dc4c644d,0 4px 18px #dc4c6433}.btn-check:checked+.btn-danger:hover,.btn-check:active+.btn-danger:hover,.btn-danger:active:hover,.btn-danger.active:hover,.btn-danger.show:hover{background-color:#c6445a}.btn-danger:disabled,.btn-danger.disabled,fieldset:disabled .btn-danger{box-shadow:0 4px 9px -4px #dc4c64}.btn-warning{--mdb-btn-bg: #e4a11b;--mdb-btn-color: #fff;--mdb-btn-box-shadow: 0 4px 9px -4px #e4a11b;--mdb-btn-hover-bg: #d9991a;--mdb-btn-hover-color: #fff;--mdb-btn-focus-bg: #d9991a;--mdb-btn-focus-color: #fff;--mdb-btn-active-bg: #cd9118;--mdb-btn-active-color: #fff}:not(.btn-check)+.btn-warning:hover,.btn-warning:first-child:hover,.btn-warning:focus-visible,.btn-warning:hover{box-shadow:0 8px 9px -4px #e4a11b4d,0 4px 18px #e4a11b33}.btn-check:focus-visible+.btn-warning,.btn-check:focus+.btn-warning,.btn-warning:focus{box-shadow:0 8px 9px -4px #e4a11b4d,0 4px 18px #e4a11b33;background-color:#d9991a}.btn-check:checked+.btn-warning,.btn-check:active+.btn-warning,.btn-warning:active,.btn-warning.active,.btn-warning.show{box-shadow:0 8px 9px -4px #e4a11b4d,0 4px 18px #e4a11b33}.btn-check:checked+.btn-warning:focus,.btn-check:active+.btn-warning:focus,.btn-warning:active:focus,.btn-warning.active:focus,.btn-warning.show:focus{box-shadow:0 8px 9px -4px #e4a11b4d,0 4px 18px #e4a11b33}.btn-check:checked+.btn-warning:hover,.btn-check:active+.btn-warning:hover,.btn-warning:active:hover,.btn-warning.active:hover,.btn-warning.show:hover{background-color:#cd9118}.btn-warning:disabled,.btn-warning.disabled,fieldset:disabled .btn-warning{box-shadow:0 4px 9px -4px #e4a11b}.btn-info{--mdb-btn-bg: #54b4d3;--mdb-btn-color: #fff;--mdb-btn-box-shadow: 0 4px 9px -4px #54b4d3;--mdb-btn-hover-bg: #50abc8;--mdb-btn-hover-color: #fff;--mdb-btn-focus-bg: #50abc8;--mdb-btn-focus-color: #fff;--mdb-btn-active-bg: #4ca2be;--mdb-btn-active-color: #fff}:not(.btn-check)+.btn-info:hover,.btn-info:first-child:hover,.btn-info:focus-visible,.btn-info:hover{box-shadow:0 8px 9px -4px #54b4d34d,0 4px 18px #54b4d333}.btn-check:focus-visible+.btn-info,.btn-check:focus+.btn-info,.btn-info:focus{box-shadow:0 8px 9px -4px #54b4d34d,0 4px 18px #54b4d333;background-color:#50abc8}.btn-check:checked+.btn-info,.btn-check:active+.btn-info,.btn-info:active,.btn-info.active,.btn-info.show{box-shadow:0 8px 9px -4px #54b4d34d,0 4px 18px #54b4d333}.btn-check:checked+.btn-info:focus,.btn-check:active+.btn-info:focus,.btn-info:active:focus,.btn-info.active:focus,.btn-info.show:focus{box-shadow:0 8px 9px -4px #54b4d34d,0 4px 18px #54b4d333}.btn-check:checked+.btn-info:hover,.btn-check:active+.btn-info:hover,.btn-info:active:hover,.btn-info.active:hover,.btn-info.show:hover{background-color:#4ca2be}.btn-info:disabled,.btn-info.disabled,fieldset:disabled .btn-info{box-shadow:0 4px 9px -4px #54b4d3}.btn-light{--mdb-btn-bg: #fbfbfb;--mdb-btn-color: #4f4f4f;--mdb-btn-box-shadow: 0 4px 9px -4px #fbfbfb;--mdb-btn-hover-bg: #eeeeee;--mdb-btn-hover-color: #4f4f4f;--mdb-btn-focus-bg: #eeeeee;--mdb-btn-focus-color: #4f4f4f;--mdb-btn-active-bg: #e2e2e2;--mdb-btn-active-color: #4f4f4f}:not(.btn-check)+.btn-light:hover,.btn-light:first-child:hover,.btn-light:focus-visible,.btn-light:hover{box-shadow:0 8px 9px -4px #fbfbfb4d,0 4px 18px #fbfbfb33}.btn-check:focus-visible+.btn-light,.btn-check:focus+.btn-light,.btn-light:focus{box-shadow:0 8px 9px -4px #fbfbfb4d,0 4px 18px #fbfbfb33;background-color:#eee}.btn-check:checked+.btn-light,.btn-check:active+.btn-light,.btn-light:active,.btn-light.active,.btn-light.show{box-shadow:0 8px 9px -4px #fbfbfb4d,0 4px 18px #fbfbfb33}.btn-check:checked+.btn-light:focus,.btn-check:active+.btn-light:focus,.btn-light:active:focus,.btn-light.active:focus,.btn-light.show:focus{box-shadow:0 8px 9px -4px #fbfbfb4d,0 4px 18px #fbfbfb33}.btn-check:checked+.btn-light:hover,.btn-check:active+.btn-light:hover,.btn-light:active:hover,.btn-light.active:hover,.btn-light.show:hover{background-color:#e2e2e2}.btn-light:disabled,.btn-light.disabled,fieldset:disabled .btn-light{box-shadow:0 4px 9px -4px #fbfbfb}.btn-dark{--mdb-btn-bg: #332d2d;--mdb-btn-color: #fff;--mdb-btn-box-shadow: 0 4px 9px -4px #332d2d;--mdb-btn-hover-bg: #302b2b;--mdb-btn-hover-color: #fff;--mdb-btn-focus-bg: #302b2b;--mdb-btn-focus-color: #fff;--mdb-btn-active-bg: #2e2929;--mdb-btn-active-color: #fff}:not(.btn-check)+.btn-dark:hover,.btn-dark:first-child:hover,.btn-dark:focus-visible,.btn-dark:hover{box-shadow:0 8px 9px -4px #332d2d4d,0 4px 18px #332d2d33}.btn-check:focus-visible+.btn-dark,.btn-check:focus+.btn-dark,.btn-dark:focus{box-shadow:0 8px 9px -4px #332d2d4d,0 4px 18px #332d2d33;background-color:#302b2b}.btn-check:checked+.btn-dark,.btn-check:active+.btn-dark,.btn-dark:active,.btn-dark.active,.btn-dark.show{box-shadow:0 8px 9px -4px #332d2d4d,0 4px 18px #332d2d33}.btn-check:checked+.btn-dark:focus,.btn-check:active+.btn-dark:focus,.btn-dark:active:focus,.btn-dark.active:focus,.btn-dark.show:focus{box-shadow:0 8px 9px -4px #332d2d4d,0 4px 18px #332d2d33}.btn-check:checked+.btn-dark:hover,.btn-check:active+.btn-dark:hover,.btn-dark:active:hover,.btn-dark.active:hover,.btn-dark.show:hover{background-color:#2e2929}.btn-dark:disabled,.btn-dark.disabled,fieldset:disabled .btn-dark{box-shadow:0 4px 9px -4px #332d2d}.btn-white{--mdb-btn-bg: #fff;--mdb-btn-color: #000;--mdb-btn-box-shadow: 0 4px 9px -4px #fff;--mdb-btn-hover-bg: #f2f2f2;--mdb-btn-hover-color: #000;--mdb-btn-focus-bg: #f2f2f2;--mdb-btn-focus-color: #000;--mdb-btn-active-bg: #e6e6e6;--mdb-btn-active-color: #000}:not(.btn-check)+.btn-white:hover,.btn-white:first-child:hover,.btn-white:focus-visible,.btn-white:hover{box-shadow:0 8px 9px -4px #ffffff4d,0 4px 18px #fff3}.btn-check:focus-visible+.btn-white,.btn-check:focus+.btn-white,.btn-white:focus{box-shadow:0 8px 9px -4px #ffffff4d,0 4px 18px #fff3;background-color:#f2f2f2}.btn-check:checked+.btn-white,.btn-check:active+.btn-white,.btn-white:active,.btn-white.active,.btn-white.show{box-shadow:0 8px 9px -4px #ffffff4d,0 4px 18px #fff3}.btn-check:checked+.btn-white:focus,.btn-check:active+.btn-white:focus,.btn-white:active:focus,.btn-white.active:focus,.btn-white.show:focus{box-shadow:0 8px 9px -4px #ffffff4d,0 4px 18px #fff3}.btn-check:checked+.btn-white:hover,.btn-check:active+.btn-white:hover,.btn-white:active:hover,.btn-white.active:hover,.btn-white.show:hover{background-color:#e6e6e6}.btn-white:disabled,.btn-white.disabled,fieldset:disabled .btn-white{box-shadow:0 4px 9px -4px #fff}.btn-black{--mdb-btn-bg: #000;--mdb-btn-color: #fff;--mdb-btn-box-shadow: 0 4px 9px -4px #000;--mdb-btn-hover-bg: black;--mdb-btn-hover-color: #fff;--mdb-btn-focus-bg: black;--mdb-btn-focus-color: #fff;--mdb-btn-active-bg: black;--mdb-btn-active-color: #fff}:not(.btn-check)+.btn-black:hover,.btn-black:first-child:hover,.btn-black:focus-visible,.btn-black:hover{box-shadow:0 8px 9px -4px #0000004d,0 4px 18px #0003}.btn-check:focus-visible+.btn-black,.btn-check:focus+.btn-black,.btn-black:focus{box-shadow:0 8px 9px -4px #0000004d,0 4px 18px #0003;background-color:#000}.btn-check:checked+.btn-black,.btn-check:active+.btn-black,.btn-black:active,.btn-black.active,.btn-black.show{box-shadow:0 8px 9px -4px #0000004d,0 4px 18px #0003}.btn-check:checked+.btn-black:focus,.btn-check:active+.btn-black:focus,.btn-black:active:focus,.btn-black.active:focus,.btn-black.show:focus{box-shadow:0 8px 9px -4px #0000004d,0 4px 18px #0003}.btn-check:checked+.btn-black:hover,.btn-check:active+.btn-black:hover,.btn-black:active:hover,.btn-black.active:hover,.btn-black.show:hover{background-color:#000}.btn-black:disabled,.btn-black.disabled,fieldset:disabled .btn-black{box-shadow:0 4px 9px -4px #000}.btn-outline-primary{--mdb-btn-bg: transparent;--mdb-btn-color: #3b71ca;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #386bc0;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #386bc0;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #3566b6;border-color:#3b71ca}:not(.btn-check)+.btn-outline-primary:hover,.btn-outline-primary:first-child:hover,.btn-outline-primary:focus-visible,.btn-outline-primary:hover{border-color:#386bc0}.btn-check:focus-visible+.btn-outline-primary,.btn-check:focus+.btn-outline-primary,.btn-outline-primary:focus{border-color:#386bc0}.btn-check:checked+.btn-outline-primary,.btn-check:active+.btn-outline-primary,.btn-outline-primary:active,.btn-outline-primary.active,.btn-outline-primary.show{border-color:#3566b6}.btn-check:checked+.btn-outline-primary:focus,.btn-check:active+.btn-outline-primary:focus,.btn-outline-primary:active:focus,.btn-outline-primary.active:focus,.btn-outline-primary.show:focus{border-color:#386bc0}.btn-outline-primary:disabled,.btn-outline-primary.disabled,fieldset:disabled .btn-outline-primary{border-color:#3b71ca}.btn-outline-secondary{--mdb-btn-bg: transparent;--mdb-btn-color: #285192;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #264d8b;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #264d8b;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #244983;border-color:#e3ebf7}:not(.btn-check)+.btn-outline-secondary:hover,.btn-outline-secondary:first-child:hover,.btn-outline-secondary:focus-visible,.btn-outline-secondary:hover{border-color:#d8dfeb}.btn-check:focus-visible+.btn-outline-secondary,.btn-check:focus+.btn-outline-secondary,.btn-outline-secondary:focus{border-color:#d8dfeb}.btn-check:checked+.btn-outline-secondary,.btn-check:active+.btn-outline-secondary,.btn-outline-secondary:active,.btn-outline-secondary.active,.btn-outline-secondary.show{border-color:#ccd4de}.btn-check:checked+.btn-outline-secondary:focus,.btn-check:active+.btn-outline-secondary:focus,.btn-outline-secondary:active:focus,.btn-outline-secondary.active:focus,.btn-outline-secondary.show:focus{border-color:#d8dfeb}.btn-outline-secondary:disabled,.btn-outline-secondary.disabled,fieldset:disabled .btn-outline-secondary{border-color:#e3ebf7}.btn-outline-success{--mdb-btn-bg: transparent;--mdb-btn-color: #14a44d;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #139c49;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #139c49;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #129445;border-color:#14a44d}:not(.btn-check)+.btn-outline-success:hover,.btn-outline-success:first-child:hover,.btn-outline-success:focus-visible,.btn-outline-success:hover{border-color:#139c49}.btn-check:focus-visible+.btn-outline-success,.btn-check:focus+.btn-outline-success,.btn-outline-success:focus{border-color:#139c49}.btn-check:checked+.btn-outline-success,.btn-check:active+.btn-outline-success,.btn-outline-success:active,.btn-outline-success.active,.btn-outline-success.show{border-color:#129445}.btn-check:checked+.btn-outline-success:focus,.btn-check:active+.btn-outline-success:focus,.btn-outline-success:active:focus,.btn-outline-success.active:focus,.btn-outline-success.show:focus{border-color:#139c49}.btn-outline-success:disabled,.btn-outline-success.disabled,fieldset:disabled .btn-outline-success{border-color:#14a44d}.btn-outline-danger{--mdb-btn-bg: transparent;--mdb-btn-color: #dc4c64;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #d1485f;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #d1485f;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #c6445a;border-color:#dc4c64}:not(.btn-check)+.btn-outline-danger:hover,.btn-outline-danger:first-child:hover,.btn-outline-danger:focus-visible,.btn-outline-danger:hover{border-color:#d1485f}.btn-check:focus-visible+.btn-outline-danger,.btn-check:focus+.btn-outline-danger,.btn-outline-danger:focus{border-color:#d1485f}.btn-check:checked+.btn-outline-danger,.btn-check:active+.btn-outline-danger,.btn-outline-danger:active,.btn-outline-danger.active,.btn-outline-danger.show{border-color:#c6445a}.btn-check:checked+.btn-outline-danger:focus,.btn-check:active+.btn-outline-danger:focus,.btn-outline-danger:active:focus,.btn-outline-danger.active:focus,.btn-outline-danger.show:focus{border-color:#d1485f}.btn-outline-danger:disabled,.btn-outline-danger.disabled,fieldset:disabled .btn-outline-danger{border-color:#dc4c64}.btn-outline-warning{--mdb-btn-bg: transparent;--mdb-btn-color: #e4a11b;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #d9991a;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #d9991a;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #cd9118;border-color:#e4a11b}:not(.btn-check)+.btn-outline-warning:hover,.btn-outline-warning:first-child:hover,.btn-outline-warning:focus-visible,.btn-outline-warning:hover{border-color:#d9991a}.btn-check:focus-visible+.btn-outline-warning,.btn-check:focus+.btn-outline-warning,.btn-outline-warning:focus{border-color:#d9991a}.btn-check:checked+.btn-outline-warning,.btn-check:active+.btn-outline-warning,.btn-outline-warning:active,.btn-outline-warning.active,.btn-outline-warning.show{border-color:#cd9118}.btn-check:checked+.btn-outline-warning:focus,.btn-check:active+.btn-outline-warning:focus,.btn-outline-warning:active:focus,.btn-outline-warning.active:focus,.btn-outline-warning.show:focus{border-color:#d9991a}.btn-outline-warning:disabled,.btn-outline-warning.disabled,fieldset:disabled .btn-outline-warning{border-color:#e4a11b}.btn-outline-info{--mdb-btn-bg: transparent;--mdb-btn-color: #54b4d3;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #50abc8;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #50abc8;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #4ca2be;border-color:#54b4d3}:not(.btn-check)+.btn-outline-info:hover,.btn-outline-info:first-child:hover,.btn-outline-info:focus-visible,.btn-outline-info:hover{border-color:#50abc8}.btn-check:focus-visible+.btn-outline-info,.btn-check:focus+.btn-outline-info,.btn-outline-info:focus{border-color:#50abc8}.btn-check:checked+.btn-outline-info,.btn-check:active+.btn-outline-info,.btn-outline-info:active,.btn-outline-info.active,.btn-outline-info.show{border-color:#4ca2be}.btn-check:checked+.btn-outline-info:focus,.btn-check:active+.btn-outline-info:focus,.btn-outline-info:active:focus,.btn-outline-info.active:focus,.btn-outline-info.show:focus{border-color:#50abc8}.btn-outline-info:disabled,.btn-outline-info.disabled,fieldset:disabled .btn-outline-info{border-color:#54b4d3}.btn-outline-light{--mdb-btn-bg: transparent;--mdb-btn-color: #fbfbfb;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #eeeeee;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #eeeeee;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #e2e2e2;border-color:#fbfbfb}:not(.btn-check)+.btn-outline-light:hover,.btn-outline-light:first-child:hover,.btn-outline-light:focus-visible,.btn-outline-light:hover{border-color:#eee}.btn-check:focus-visible+.btn-outline-light,.btn-check:focus+.btn-outline-light,.btn-outline-light:focus{border-color:#eee}.btn-check:checked+.btn-outline-light,.btn-check:active+.btn-outline-light,.btn-outline-light:active,.btn-outline-light.active,.btn-outline-light.show{border-color:#e2e2e2}.btn-check:checked+.btn-outline-light:focus,.btn-check:active+.btn-outline-light:focus,.btn-outline-light:active:focus,.btn-outline-light.active:focus,.btn-outline-light.show:focus{border-color:#eee}.btn-outline-light:disabled,.btn-outline-light.disabled,fieldset:disabled .btn-outline-light{border-color:#fbfbfb}.btn-outline-dark{--mdb-btn-bg: transparent;--mdb-btn-color: #332d2d;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #302b2b;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #302b2b;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #2e2929;border-color:#332d2d}:not(.btn-check)+.btn-outline-dark:hover,.btn-outline-dark:first-child:hover,.btn-outline-dark:focus-visible,.btn-outline-dark:hover{border-color:#302b2b}.btn-check:focus-visible+.btn-outline-dark,.btn-check:focus+.btn-outline-dark,.btn-outline-dark:focus{border-color:#302b2b}.btn-check:checked+.btn-outline-dark,.btn-check:active+.btn-outline-dark,.btn-outline-dark:active,.btn-outline-dark.active,.btn-outline-dark.show{border-color:#2e2929}.btn-check:checked+.btn-outline-dark:focus,.btn-check:active+.btn-outline-dark:focus,.btn-outline-dark:active:focus,.btn-outline-dark.active:focus,.btn-outline-dark.show:focus{border-color:#302b2b}.btn-outline-dark:disabled,.btn-outline-dark.disabled,fieldset:disabled .btn-outline-dark{border-color:#332d2d}.btn-outline-white{--mdb-btn-bg: transparent;--mdb-btn-color: #fff;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #f2f2f2;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #f2f2f2;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #e6e6e6;border-color:#fff}:not(.btn-check)+.btn-outline-white:hover,.btn-outline-white:first-child:hover,.btn-outline-white:focus-visible,.btn-outline-white:hover{border-color:#f2f2f2}.btn-check:focus-visible+.btn-outline-white,.btn-check:focus+.btn-outline-white,.btn-outline-white:focus{border-color:#f2f2f2}.btn-check:checked+.btn-outline-white,.btn-check:active+.btn-outline-white,.btn-outline-white:active,.btn-outline-white.active,.btn-outline-white.show{border-color:#e6e6e6}.btn-check:checked+.btn-outline-white:focus,.btn-check:active+.btn-outline-white:focus,.btn-outline-white:active:focus,.btn-outline-white.active:focus,.btn-outline-white.show:focus{border-color:#f2f2f2}.btn-outline-white:disabled,.btn-outline-white.disabled,fieldset:disabled .btn-outline-white{border-color:#fff}.btn-outline-black{--mdb-btn-bg: transparent;--mdb-btn-color: #000;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: black;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: black;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: black;border-color:#000}:not(.btn-check)+.btn-outline-black:hover,.btn-outline-black:first-child:hover,.btn-outline-black:focus-visible,.btn-outline-black:hover{border-color:#000}.btn-check:focus-visible+.btn-outline-black,.btn-check:focus+.btn-outline-black,.btn-outline-black:focus{border-color:#000}.btn-check:checked+.btn-outline-black,.btn-check:active+.btn-outline-black,.btn-outline-black:active,.btn-outline-black.active,.btn-outline-black.show{border-color:#000}.btn-check:checked+.btn-outline-black:focus,.btn-check:active+.btn-outline-black:focus,.btn-outline-black:active:focus,.btn-outline-black.active:focus,.btn-outline-black.show:focus{border-color:#000}.btn-outline-black:disabled,.btn-outline-black.disabled,fieldset:disabled .btn-outline-black{border-color:#000}.btn-link{--mdb-btn-font-weight: 500;--mdb-btn-color: #3b71ca;--mdb-btn-hover-color: #386bc0;--mdb-btn-hover-bg: hsl(0, 0%, 96%);--mdb-btn-focus-color: #3566b6;--mdb-btn-active-color: #3260ac;--mdb-btn-disabled-color: #9e9e9e;--mdb-btn-box-shadow: none;text-decoration:none;box-shadow:var(--mdb-btn-box-shadow)}:not(.btn-check)+.btn-link:hover,.btn-link:first-child:hover,.btn-link:focus-visible,.btn-link:hover{text-decoration:none;box-shadow:var(--mdb-btn-box-shadow)}.btn-check:focus-visible+.btn-link,.btn-check:focus+.btn-link,.btn-link:focus{color:var(--mdb-btn-focus-color);box-shadow:var(--mdb-btn-box-shadow)}.btn-check:checked+.btn-link,.btn-check:active+.btn-link,.btn-link:active,.btn-link.active,.btn-link.show{color:var(--mdb-btn-active-color);box-shadow:var(--mdb-btn-box-shadow)}.btn-check:checked+.btn-link:focus,.btn-check:active+.btn-link:focus,.btn-link:active:focus,.btn-link.active:focus,.btn-link.show:focus{color:var(--mdb-btn-focus-color);box-shadow:var(--mdb-btn-box-shadow)}.btn-link:disabled,.btn-link.disabled,fieldset:disabled .btn-link{box-shadow:var(--mdb-btn-box-shadow)}.btn-tertiary{--mdb-btn-font-weight: 500;--mdb-btn-color: #3b71ca;--mdb-btn-hover-color: #386bc0;--mdb-btn-hover-bg: transparent;--mdb-btn-focus-color: #3566b6;--mdb-btn-active-color: #3260ac;--mdb-btn-disabled-color: #9e9e9e;--mdb-btn-box-shadow: none;padding-left:0;padding-right:0;text-decoration:none;box-shadow:var(--mdb-btn-box-shadow)}:not(.btn-check)+.btn-tertiary:hover,.btn-tertiary:first-child:hover,.btn-tertiary:focus-visible,.btn-tertiary:hover{text-decoration:none;box-shadow:var(--mdb-btn-box-shadow)}.btn-check:focus-visible+.btn-tertiary,.btn-check:focus+.btn-tertiary,.btn-tertiary:focus{color:var(--mdb-btn-focus-color);box-shadow:var(--mdb-btn-box-shadow)}.btn-check:checked+.btn-tertiary,.btn-check:active+.btn-tertiary,.btn-tertiary:active,.btn-tertiary.active,.btn-tertiary.show{color:var(--mdb-btn-active-color);box-shadow:var(--mdb-btn-box-shadow)}.btn-check:checked+.btn-tertiary:focus,.btn-check:active+.btn-tertiary:focus,.btn-tertiary:active:focus,.btn-tertiary.active:focus,.btn-tertiary.show:focus{color:var(--mdb-btn-focus-color);box-shadow:var(--mdb-btn-box-shadow)}.btn-tertiary:disabled,.btn-tertiary.disabled,fieldset:disabled .btn-tertiary{box-shadow:var(--mdb-btn-box-shadow)}.btn-lg,.btn-group-lg>.btn{--mdb-btn-padding-top: .75rem;--mdb-btn-padding-bottom: .6875rem;--mdb-btn-padding-x: 1.6875rem;--mdb-btn-font-size:.875rem;--mdb-btn-line-height: 1.6}.btn-sm,.btn-group-sm>.btn{--mdb-btn-padding-top: .375rem;--mdb-btn-padding-bottom: .3125rem;--mdb-btn-padding-x: 1rem;--mdb-btn-font-size:.75rem;--mdb-btn-line-height: 1.5}.btn-rounded{--mdb-btn-border-radius: 10rem;border-radius:var(--mdb-btn-border-radius)}.btn-floating,[class*=btn-outline-].btn-floating{--mdb-btn-border-radius: 50%;border-radius:var(--mdb-btn-border-radius);padding:0;position:relative}.btn-floating{--mdb-btn-width: 2.3125rem;--mdb-btn-height: 2.3125rem;--mdb-btn-icon-width: 2.3125rem;--mdb-btn-icon-line-height: 2.3125rem;--mdb-btn-width-lg: 2.8125rem;--mdb-btn-height-lg: 2.8125rem;--mdb-btn-icon-width-lg: 2.8125rem;--mdb-btn-icon-line-height-lg: 2.8125rem;--mdb-btn-width-sm: 1.8125rem;--mdb-btn-height-sm: 1.8125rem;--mdb-btn-icon-width-sm: 1.8125rem;--mdb-btn-icon-line-height-sm: 1.8125rem;width:var(--mdb-btn-width);height:var(--mdb-btn-height)}.btn-floating .fas,.btn-floating .far,.btn-floating .fab{width:var(--mdb-btn-icon-width);line-height:var(--mdb-btn-icon-line-height)}.btn-floating.btn-lg,.btn-group-lg>.btn-floating.btn{width:var(--mdb-btn-width-lg);height:var(--mdb-btn-height-lg)}.btn-floating.btn-lg .fas,.btn-group-lg>.btn-floating.btn .fas,.btn-floating.btn-lg .far,.btn-group-lg>.btn-floating.btn .far,.btn-floating.btn-lg .fab,.btn-group-lg>.btn-floating.btn .fab{width:var(--mdb-btn-icon-width-lg);line-height:var(--mdb-btn-icon-line-height-lg)}.btn-floating.btn-sm,.btn-group-sm>.btn-floating.btn{width:var(--mdb-btn-width-sm);height:var(--mdb-btn-height-sm)}.btn-floating.btn-sm .fas,.btn-group-sm>.btn-floating.btn .fas,.btn-floating.btn-sm .far,.btn-group-sm>.btn-floating.btn .far,.btn-floating.btn-sm .fab,.btn-group-sm>.btn-floating.btn .fab{width:var(--mdb-btn-icon-width-sm);line-height:var(--mdb-btn-icon-line-height-sm)}[class*=btn-outline-].btn-floating{--mdb-btn-icon-width: 2.0625rem;--mdb-btn-icon-width-lg: 2.5625rem;--mdb-btn-icon-width-sm: 1.5625rem;--mdb-btn-icon-line-height: 2.0625rem;--mdb-btn-icon-line-height-lg: 2.5625rem;--mdb-btn-icon-line-height-sm: 1.5625rem}[class*=btn-outline-].btn-floating .fas,[class*=btn-outline-].btn-floating .far,[class*=btn-outline-].btn-floating .fab{width:var(--mdb-btn-icon-width);line-height:var(--mdb-btn-icon-line-height)}[class*=btn-outline-].btn-floating.btn-lg .fas,.btn-group-lg>[class*=btn-outline-].btn-floating.btn .fas,[class*=btn-outline-].btn-floating.btn-lg .far,.btn-group-lg>[class*=btn-outline-].btn-floating.btn .far,[class*=btn-outline-].btn-floating.btn-lg .fab,.btn-group-lg>[class*=btn-outline-].btn-floating.btn .fab{width:var(--mdb-btn-icon-width-lg);line-height:var(--mdb-btn-icon-line-height-lg)}[class*=btn-outline-].btn-floating.btn-sm .fas,.btn-group-sm>[class*=btn-outline-].btn-floating.btn .fas,[class*=btn-outline-].btn-floating.btn-sm .far,.btn-group-sm>[class*=btn-outline-].btn-floating.btn .far,[class*=btn-outline-].btn-floating.btn-sm .fab,.btn-group-sm>[class*=btn-outline-].btn-floating.btn .fab{width:var(--mdb-btn-icon-width-sm);line-height:var(--mdb-btn-icon-line-height-sm)}.fixed-action-btn{--mdb-btn-right: 2.1875rem;--mdb-btn-bottom: 2.1875rem;--mdb-btn-zindex: 1030;--mdb-btn-padding-top: .9375rem;--mdb-btn-padding-bottom: 1.25rem;--mdb-btn-padding-x: 1.25rem;--mdb-btn-margin-bottom: 1.5rem;position:fixed;right:var(--mdb-btn-right);bottom:var(--mdb-btn-bottom);z-index:var(--mdb-btn-zindex);display:flex;flex-flow:column-reverse nowrap;align-items:center;padding:var(--mdb-btn-padding-top) var(--mdb-btn-padding-x) var(--mdb-btn-padding-bottom);margin-bottom:0;height:auto;overflow:hidden}.fixed-action-btn>.btn-floating{position:relative;transform:scale(1.2);z-index:10}.fixed-action-btn ul{position:absolute;bottom:0;left:0;right:0;display:flex;flex-direction:column;padding:0;margin:0;text-align:center;opacity:0;transition:transform .4s,opacity .4s;z-index:-1}.fixed-action-btn ul li{z-index:0;display:flex;margin-right:auto;margin-bottom:var(--mdb-btn-margin-bottom);margin-left:auto}.fixed-action-btn ul li:first-of-type{margin-top:calc(var(--mdb-btn-margin-bottom)*.5)}.fixed-action-btn ul a.btn{opacity:0;transition:opacity .4s ease-in}.fixed-action-btn ul a.btn.shown,.fixed-action-btn.active ul{opacity:1}.btn-block{--mdb-btn-margin-top: .5rem;display:block;width:100%}.btn-block+.btn-block{margin-top:var(--mdb-btn-margin-top)}hr.divider-horizontal:not([size]){height:2px}.divider-horizontal{opacity:1;background-color:#f5f5f5;height:2px}.divider-vertical{opacity:1;background-color:#f5f5f5;display:inline-block;width:2px;margin:0 1rem}hr.divider-horizontal-blurry{background-image:linear-gradient(90deg,transparent,hsl(0,0%,40%),transparent);background-color:#0000}hr.divider-vertical-blurry{background-image:linear-gradient(180deg,transparent,hsl(0,0%,40%),transparent);background-color:#0000;width:1px;top:0;right:0}.dropdown-menu{--mdb-dropdown-item-border-radius: .5rem;color:var(--mdb-dropdown-color);margin:0;padding-top:0;padding-bottom:0;border:0;box-shadow:var(--mdb-dropdown-box-shadow);font-size:var(--mdb-dropdown-font-size);top:100%;left:0;margin-top:var(--mdb-dropdown-spacer)}.dropdown-menu>li{border-radius:0}.dropdown-menu>li:first-child{border-top-left-radius:var(--mdb-dropdown-item-border-radius);border-top-right-radius:var(--mdb-dropdown-item-border-radius);border-bottom-left-radius:0;border-bottom-right-radius:0}.dropdown-menu>li:first-child .dropdown-item{border-top-left-radius:var(--mdb-dropdown-item-border-radius);border-top-right-radius:var(--mdb-dropdown-item-border-radius);border-bottom-left-radius:0;border-bottom-right-radius:0}.dropdown-menu>li:not(:first-child):not(:last-child) .dropdown-item{border-radius:0}.dropdown-menu>li:last-child{border-top-left-radius:0;border-top-right-radius:0;border-bottom-left-radius:var(--mdb-dropdown-item-border-radius);border-bottom-right-radius:var(--mdb-dropdown-item-border-radius)}.dropdown-menu>li:last-child .dropdown-item{border-top-left-radius:0;border-top-right-radius:0;border-bottom-left-radius:var(--mdb-dropdown-item-border-radius);border-bottom-right-radius:var(--mdb-dropdown-item-border-radius)}.dropdown-menu.animation{--mdb-dropdown-menu-animated-animation-duration: .55s;--mdb-dropdown-menu-animated-animation-timing-function: ease;display:block;animation-duration:var(--mdb-dropdown-menu-animated-animation-duration);animation-timing-function:var(--mdb-dropdown-menu-animated-animation-timing-function)}.dropdown-item{--mdb-dropdown-state-color: #16181b;--mdb-dropdown-state-background-color: #eee;padding:var(--mdb-dropdown-item-padding-y) var(--mdb-dropdown-item-padding-x);color:var(--mdb-dropdown-color);border-radius:0}.dropdown-item:hover,.dropdown-item:focus{color:var(--mdb-dropdown-state-color);background-color:var(--mdb-dropdown-state-background-color)}.dropdown-item.active,.dropdown-item:active{color:var(--mdb-dropdown-state-color);background-color:var(--mdb-dropdown-state-background-color)}.hidden-arrow.dropdown-toggle:after{display:none}.animation{animation-duration:1s;animation-fill-mode:both;padding:auto}@media (prefers-reduced-motion){.animation{transition:none!important;animation:unset!important}}@keyframes fade-in{0%{opacity:0}to{opacity:1}}.fade-in{animation-name:fade-in}@keyframes fade-out{0%{opacity:1}to{opacity:0}}.fade-out{animation-name:fade-out}.dropdown-divider{--mdb-dropdown-divider-border-top-width: 2px;--mdb-dropdown-divider-border-top-bg: hsl(0, 0%, 96%);border-top:var(--mdb-dropdown-divider-border-top-width) solid var(--mdb-dropdown-divider-border-top-bg);opacity:1}.dropdown-menu INPUT:not(:-webkit-autofill),.dropdown-menu SELECT:not(:-webkit-autofill),.dropdown-menu TEXTAREA:not(:-webkit-autofill){animation-name:none!important}.btn-group,.btn-group-vertical{--mdb-btn-box-shadow: 0 4px 9px -4px rgba(0, 0, 0, .35);--mdb-btn-hover-box-shadow: 0 8px 9px -4px rgba(0, 0, 0, .15), 0 4px 18px 0 rgba(0, 0, 0, .1);--mdb-btn-focus-box-shadow: 0 8px 9px -4px rgba(0, 0, 0, .15), 0 4px 18px 0 rgba(0, 0, 0, .1);--mdb-btn-active-box-shadow: 0 8px 9px -4px rgba(0, 0, 0, .15), 0 4px 18px 0 rgba(0, 0, 0, .1);--mdb-btn-group-transition: color .15s ease-in-out, background-color .15s ease-in-out, border-color .15s ease-in-out, box-shadow .15s ease-in-out;box-shadow:var(--mdb-btn-box-shadow);transition:var(--mdb-btn-group-transition)}.btn-group:hover,.btn-group-vertical:hover{box-shadow:var(--mdb-btn-hover-box-shadow)}.btn-group:focus,.btn-group.focus,.btn-group-vertical:focus,.btn-group-vertical.focus{box-shadow:var(--mdb-btn-focus-box-shadow)}.btn-group:active,.btn-group.active,.btn-group-vertical:active,.btn-group-vertical.active{box-shadow:var(--mdb-btn-active-box-shadow)}.btn-group:active:focus,.btn-group.active:focus,.btn-group-vertical:active:focus,.btn-group-vertical.active:focus{box-shadow:var(--mdb-btn-focus-box-shadow)}.btn-group:disabled,.btn-group.disabled,fieldset:disabled .btn-group,.btn-group-vertical:disabled,.btn-group-vertical.disabled,fieldset:disabled .btn-group-vertical{box-shadow:var(--mdb-btn-box-shadow);border:0}.btn-group>.btn,.btn-group-vertical>.btn{box-shadow:none}:not(.btn-check)+.btn-group>.btn:hover,.btn-group>.btn:first-child:hover,.btn-group>.btn:focus-visible,.btn-group>.btn:hover,:not(.btn-check)+.btn-group-vertical>.btn:hover,.btn-group-vertical>.btn:first-child:hover,.btn-group-vertical>.btn:focus-visible,.btn-group-vertical>.btn:hover{box-shadow:none!important}.btn-check:focus-visible+.btn-group>.btn,.btn-check:focus+.btn-group>.btn,.btn-group>.btn:focus,.btn-check:focus-visible+.btn-group-vertical>.btn,.btn-check:focus+.btn-group-vertical>.btn,.btn-group-vertical>.btn:focus{box-shadow:none}.btn-check:checked+.btn-group>.btn,.btn-check:active+.btn-group>.btn,.btn-group>.btn:active,.btn-group>.btn.active,.btn-group>.btn.show,.btn-check:checked+.btn-group-vertical>.btn,.btn-check:active+.btn-group-vertical>.btn,.btn-group-vertical>.btn:active,.btn-group-vertical>.btn.active,.btn-group-vertical>.btn.show{box-shadow:none}.btn-check:checked+.btn-group>.btn:focus,.btn-check:active+.btn-group>.btn:focus,.btn-group>.btn:active:focus,.btn-group>.btn.active:focus,.btn-group>.btn.show:focus,.btn-check:checked+.btn-group-vertical>.btn:focus,.btn-check:active+.btn-group-vertical>.btn:focus,.btn-group-vertical>.btn:active:focus,.btn-group-vertical>.btn.active:focus,.btn-group-vertical>.btn.show:focus{box-shadow:none}.btn-group>.btn:disabled,.btn-group>.btn.disabled,fieldset:disabled .btn-group>.btn,.btn-group-vertical>.btn:disabled,.btn-group-vertical>.btn.disabled,fieldset:disabled .btn-group-vertical>.btn{box-shadow:none}.btn-group>.btn-group,.btn-group-vertical>.btn-group{box-shadow:none}.btn-group>.btn-link:first-child,.btn-group>.btn-tertiary:first-child,.btn-group-vertical>.btn-link:first-child,.btn-group-vertical>.btn-tertiary:first-child{border-top-left-radius:0;border-bottom-left-radius:0}.btn-group>.btn-link:last-child,.btn-group>.btn-tertiary:last-child,.btn-group-vertical>.btn-link:last-child,.btn-group-vertical>.btn-tertiary:last-child{border-top-right-radius:0;border-bottom-right-radius:0}.btn-group,.btn-group-lg>.btn,.btn-group-sm>.btn{--mdb-btn-border-radius: .25rem;border-radius:var(--mdb-btn-border-radius)}.nav-tabs{border-bottom:0}.nav-tabs .nav-link{--mdb-nav-tabs-link-font-weight: 500;--mdb-nav-tabs-link-font-size: 12px;--mdb-nav-tabs-link-color: rgba(0, 0, 0, .55);--mdb-nav-tabs-link-padding-top: 17px;--mdb-nav-tabs-link-padding-bottom: 16px;--mdb-nav-tabs-link-padding-x: 29px;--mdb-nav-tabs-link-hover-bgc: #f7f7f7;--mdb-nav-tabs-link-border-bottom-width: 2px;--mdb-nav-tabs-link-active-color: #3b71ca;--mdb-nav-tabs-link-active-border-color: #3b71ca;border-width:0;border-bottom:var(--mdb-nav-tabs-link-border-bottom-width) solid rgba(0,0,0,0);border-radius:0;text-transform:uppercase;line-height:1;font-weight:var(--mdb-nav-tabs-link-font-weight);font-size:var(--mdb-nav-tabs-link-font-size);color:var(--mdb-nav-tabs-link-color);padding:var(--mdb-nav-tabs-link-padding-top) var(--mdb-nav-tabs-link-padding-x) var(--mdb-nav-tabs-link-padding-bottom) var(--mdb-nav-tabs-link-padding-x)}.nav-tabs .nav-link:hover{background-color:var(--mdb-nav-tabs-link-hover-bgc);border-color:#0000}.nav-tabs .nav-link:focus{border-color:#0000}.nav-tabs .nav-link.active,.nav-tabs .nav-item.show .nav-link{color:var(--mdb-nav-tabs-link-active-color);border-color:var(--mdb-nav-tabs-link-active-border-color)}.nav-pills{margin-left:-.5rem}.nav-pills .nav-link{--mdb-nav-pills-link-border-radius: .25rem;--mdb-nav-pills-link-font-size: 12px;--mdb-nav-pills-link-padding-top: 17px;--mdb-nav-pills-link-padding-bottom: 16px;--mdb-nav-pills-link-padding-x: 29px;--mdb-nav-pills-link-line-height: 1;--mdb-nav-pills-link-hover-bg: #f7f7f7;--mdb-nav-pills-link-font-weight: 500;--mdb-nav-pills-link-color: rgba(0, 0, 0, .55);--mdb-nav-pills-margin: .5rem;border-radius:var(--mdb-nav-pills-link-border-radius);font-size:var(--mdb-nav-pills-link-font-size);text-transform:uppercase;padding:var(--mdb-nav-pills-link-padding-top) var(--mdb-nav-pills-link-padding-x) var(--mdb-nav-pills-link-padding-bottom) var(--mdb-nav-pills-link-padding-x);line-height:var(--mdb-nav-pills-link-line-height);background-color:var(--mdb-nav-pills-link-hover-bg);font-weight:var(--mdb-nav-pills-link-font-weight);color:var(--mdb-nav-pills-link-color);margin:var(--mdb-nav-pills-margin)}.nav-pills .nav-link.active,.nav-pills .show>.nav-link{--mdb-nav-pills-link-active-bg: #e3ebf7;--mdb-nav-pills-link-active-color: #285192;background-color:var(--mdb-nav-pills-link-active-bg);color:var(--mdb-nav-pills-link-active-color)}.nav-fill .nav-item .nav-link,.nav-justified .nav-item .nav-link{width:auto}.navbar{--mdb-navbar-box-shadow: 0 4px 12px 0 rgba(0, 0, 0, .07), 0 2px 4px rgba(0, 0, 0, .05);--mdb-navbar-padding-top: .5625rem;--mdb-navbar-brand-img-margin-right: .25rem;box-shadow:var(--mdb-navbar-box-shadow);padding-top:var(--mdb-navbar-padding-top)}.navbar-toggler{border:0}.navbar-toggler:focus{box-shadow:none}.navbar-dark .navbar-toggler,.navbar-light .navbar-toggler{border:0}.navbar-brand{display:flex;align-items:center}.navbar-brand img{margin-right:var(--mdb-navbar-brand-img-margin-right)}.navbar-nav .dropdown-menu{position:absolute}.navbar-light .navbar-toggler-icon,.navbar-dark .navbar-toggler-icon{background-image:none}.card{border:0}.card .bg-image{border-top-left-radius:var(--mdb-card-border-radius);border-top-right-radius:var(--mdb-card-border-radius)}.card[class*=bg-] .card-header{--mdb-card-header-border-bottom-color: var(--mdb-border-color-translucent);border-bottom-color:var(--mdb-card-header-border-bottom-color)}.card[class*=bg-] .card-footer{--mdb-card-footer-border-top-color: var(--mdb-border-color-translucent);border-top-color:var(--mdb-card-footer-border-top-color)}.card-header{--mdb-card-header-border-width: 2px;--mdb-card-header-border-color: hsl(0, 0%, 96%);border-bottom:var(--mdb-card-header-border-width) solid var(--mdb-card-header-border-color)}.card-body[class*=bg-]{border-bottom-left-radius:var(--mdb-card-border-radius);border-bottom-right-radius:var(--mdb-card-border-radius)}.card-footer{--mdb-card-footer-border-color: hsl(0, 0%, 96%);--mdb-card-footer-border-width: 2px;border-top:var(--mdb-card-footer-border-width) solid var(--mdb-card-footer-border-color)}.card-img-left{border-top-left-radius:var(--mdb-card-border-radius);border-bottom-left-radius:var(--mdb-card-border-radius)}.navbar .breadcrumb{--mdb-breadcrumb-item-color: rgba(0, 0, 0, .55);--mdb-breadcrumb-item-hover-color: rgba(0, 0, 0, .7);--mdb-breadcrumb-item-before-color: rgba(0, 0, 0, .55);--mdb-breadcrumb-item-transition: color .15s ease-in-out;background-color:#0000;margin-bottom:0}.navbar .breadcrumb .breadcrumb-item a{color:var(--mdb-breadcrumb-item-color);transition:var(--mdb-breadcrumb-item-transition)}.navbar .breadcrumb .breadcrumb-item a:hover,.navbar .breadcrumb .breadcrumb-item a:focus{color:var(--mdb-breadcrumb-item-hover-color)}.navbar .breadcrumb .breadcrumb-item+.breadcrumb-item:before{color:var(--mdb-breadcrumb-item-before-color)}.pagination{--mdb-pagination-border-radius: .25rem;--mdb-pagination-active-box-shadow: 0 4px 9px -4px #e3ebf7;--mdb-pagination-active-transition: all .2s linear;--mdb-pagination-active-font-weight: 500;--mdb-pagination-circle-border-radius: 50%;--mdb-pagination-circle-padding-x: .841rem;--mdb-pagination-circle-padding-l-lg: 1.399414rem;--mdb-pagination-circle-padding-r-lg: 1.399415rem;--mdb-pagination-circle-padding-l-sm: .696rem;--mdb-pagination-circle-padding-r-sm: .688rem}.page-link{background-color:#0000;border:0;outline:0;border-radius:var(--mdb-pagination-border-radius)}.page-link:focus{box-shadow:none}.page-link.active,.active>.page-link{border:0;box-shadow:var(--mdb-pagination-active-box-shadow);transition:var(--mdb-pagination-active-transition);font-weight:var(--mdb-pagination-active-font-weight)}.page-item:not(:first-child) .page-link{margin-left:0}.page-item:first-child .page-link{border-top-left-radius:var(--mdb-pagination-border-radius);border-bottom-left-radius:var(--mdb-pagination-border-radius)}.page-item:last-child .page-link{border-top-right-radius:var(--mdb-pagination-border-radius);border-bottom-right-radius:var(--mdb-pagination-border-radius)}.pagination-circle .page-item:first-child .page-link{border-radius:var(--mdb-pagination-circle-border-radius)}.pagination-circle .page-item:last-child .page-link{border-radius:var(--mdb-pagination-circle-border-radius)}.pagination-circle .page-link{border-radius:var(--mdb-pagination-circle-border-radius);padding-left:var(--mdb-pagination-circle-padding-x);padding-right:var(--mdb-pagination-circle-padding-x)}.pagination-circle.pagination-lg .page-link{padding-left:var(--mdb-pagination-circle-padding-l-lg);padding-right:var(--mdb-pagination-circle-padding-r-lg)}.pagination-circle.pagination-sm .page-link{padding-left:var(--mdb-pagination-circle-padding-l-sm);padding-right:var(--mdb-pagination-circle-padding-r-sm)}.badge-dot{--mdb-badge-border-radius: 4.5px;--mdb-badge-height: 9px;--mdb-badge-width: 9px;--mdb-badge-margin-left: -.3125rem;position:absolute;min-width:0;width:var(--mdb-badge-width);height:var(--mdb-badge-height);border-radius:var(--mdb-badge-border-radius);padding:0;margin-left:var(--mdb-badge-margin-left)}.badge-dot:empty{display:inline-block}.badge-notification{--mdb-badge-font-size: .6rem;--mdb-badge-padding-x: .45em;--mdb-badge-padding-y: .2em;--mdb-badge-margin-top: -.1rem;--mdb-badge-margin-left: -.5rem;position:absolute;font-size:var(--mdb-badge-font-size);padding:var(--mdb-badge-padding-y) var(--mdb-badge-padding-x);margin-top:var(--mdb-badge-margin-top);margin-left:var(--mdb-badge-margin-left)}.badge-primary{background-color:#dfe7f6;color:#2c58a0}.badge-primary i{color:#376fc8}.badge-secondary{background-color:#ebedef;color:#40464f}.badge-secondary i{color:#565e6c}.badge-success{background-color:#d6f0e0;color:#0d6832}.badge-success i{color:#139647}.badge-danger{background-color:#f9e1e5;color:#af233a}.badge-danger i{color:#d62e4a}.badge-warning{background-color:#fbf0da;color:#73510d}.badge-warning i{color:#a17112}.badge-info{background-color:#def1f7;color:#1c657d}.badge-info i{color:#2686a6}.badge-light{background-color:#f5f5f5;color:#4f4f4f}.badge-light i{color:#8c8c8c}.badge-dark{background-color:#332e2e;color:#f5f5f5}.badge-dark i{color:#e8e8e8}.alert{border:0}.alert-absolute{position:absolute}.alert-fixed{--mdb-alert-fixed-z-index: 1070;position:fixed;z-index:var(--mdb-alert-fixed-z-index)}.parent-alert-relative{position:relative}.alert-primary{background-color:#dfe7f6;color:#2c58a0}.alert-primary i{color:#376fc8}.alert-primary .alert-link{color:#2c58a0}.alert-primary .alert-link:hover{color:#234680}.alert-secondary{background-color:#ebedef;color:#40464f}.alert-secondary i{color:#565e6c}.alert-secondary .alert-link{color:#40464f}.alert-secondary .alert-link:hover{color:#33383f}.alert-success{background-color:#d6f0e0;color:#0d6832}.alert-success i{color:#139647}.alert-success .alert-link{color:#0d6832}.alert-success .alert-link:hover{color:#0a5328}.alert-danger{background-color:#f9e1e5;color:#af233a}.alert-danger i{color:#d62e4a}.alert-danger .alert-link{color:#af233a}.alert-danger .alert-link:hover{color:#8c1c2e}.alert-warning{background-color:#fbf0da;color:#73510d}.alert-warning i{color:#a17112}.alert-warning .alert-link{color:#73510d}.alert-warning .alert-link:hover{color:#5c410a}.alert-info{background-color:#def1f7;color:#1c657d}.alert-info i{color:#2686a6}.alert-info .alert-link{color:#1c657d}.alert-info .alert-link:hover{color:#165164}.alert-light{background-color:#f5f5f5;color:#4f4f4f}.alert-light i{color:#8c8c8c}.alert-light .alert-link{color:#4f4f4f}.alert-light .alert-link:hover{color:#3f3f3f}.alert-dark{background-color:#332e2e;color:#f5f5f5}.alert-dark i{color:#e8e8e8}.alert-dark .alert-link{color:#f5f5f5}.alert-dark .alert-link:hover{color:#c4c4c4}.progress{border-radius:0;box-shadow:none}.list-group{--mdb-list-group-item-transition-time: .5s}.list-group-item-action,.list-group-item-action:hover{transition:var(--mdb-list-group-item-transition-time)}.list-group-light{--mdb-list-group-light-item-py: 1rem;--mdb-list-group-light-item-border: 2px solid hsl(0, 0%, 96%);--mdb-list-group-light-item-border-width: 2px;--mdb-list-group-light-active-border-radius: .5rem;--mdb-list-group-light-active-bg: rgb(223, 231, 246);--mdb-list-group-light-active-color: rgb(44, 88, 160)}.list-group-light .list-group-item{padding:var(--mdb-list-group-light-item-py) 0;border:var(--mdb-list-group-light-item-border)}.list-group-light>.list-group-item{border-width:0 0 var(--mdb-list-group-light-item-border-width)}.list-group-light>.list-group-item:last-of-type{border:none}.list-group-light .active{border:none;border-radius:var(--mdb-list-group-light-active-border-radius);background-color:var(--mdb-list-group-light-active-bg);color:var(--mdb-list-group-light-active-color)}.list-group-light .list-group-item-action:hover{border-radius:var(--mdb-list-group-light-active-border-radius)}.list-group-light .list-group-item-action:focus{border-radius:var(--mdb-list-group-light-active-border-radius)}.list-group-small{--mdb-list-group-small-item-py: .5rem}.list-group-small .list-group-item{padding:var(--mdb-list-group-small-item-py) 0}.list-group-item-primary{background-color:#dfe7f6;color:#2c58a0}.list-group-item-primary i{color:#376fc8}.list-group-item-secondary{background-color:#ebedef;color:#40464f}.list-group-item-secondary i{color:#565e6c}.list-group-item-success{background-color:#d6f0e0;color:#0d6832}.list-group-item-success i{color:#139647}.list-group-item-danger{background-color:#f9e1e5;color:#af233a}.list-group-item-danger i{color:#d62e4a}.list-group-item-warning{background-color:#fbf0da;color:#73510d}.list-group-item-warning i{color:#a17112}.list-group-item-info{background-color:#def1f7;color:#1c657d}.list-group-item-info i{color:#2686a6}.list-group-item-light{background-color:#f5f5f5;color:#4f4f4f}.list-group-item-light i{color:#8c8c8c}.list-group-item-dark{background-color:#332e2e;color:#f5f5f5}.list-group-item-dark i{color:#e8e8e8}.btn-close:focus{box-shadow:none}.modal-content{--mdb-modal-box-shadow: 0 2px 15px -3px rgba(0, 0, 0, .07), 0 10px 20px -2px rgba(0, 0, 0, .04);border:0;box-shadow:var(--mdb-modal-box-shadow)}.toast{--mdb-toast-border-bottom-width: 2px;--mdb-toast-btn-close-width: 1.3em;--mdb-toast-btn-close-mr: -.375rem;--mdb-toast-btn-close-ml: .75rem;border:0}.toast .btn-close{width:var(--mdb-toast-btn-close-width)}.toast-header{border-bottom-width:var(--mdb-toast-border-bottom-width)}.toast-header .btn-close{margin-right:var(--mdb-toast-btn-close-mr);margin-left:var(--mdb-toast-btn-close-ml)}.parent-toast-relative{position:relative}.toast-absolute{position:absolute}.toast-fixed{position:fixed;z-index:var(--mdb-toast-zindex)}.toast-primary{background-color:#dfe7f6;color:#2c58a0;border-color:#c7d6f0}.toast-primary i{color:#376fc8}.toast-secondary{background-color:#ebedef;color:#40464f;border-color:#dadee1}.toast-secondary i{color:#565e6c}.toast-success{background-color:#d6f0e0;color:#0d6831;border-color:#c0e7d0}.toast-success i{color:#139647}.toast-danger{background-color:#f9e1e5;color:#af233a;border-color:#f4c8cf}.toast-danger i{color:#d62e4a}.toast-warning{background-color:#fbf0da;color:#73510d;border-color:#f9e4be}.toast-warning i{color:#a17112}.toast-info{background-color:#def1f7;color:#1c657d;border-color:#c6e6f1}.toast-info i{color:#2686a6}.toast-light{background-color:#f5f5f5;color:#4f4f4f;border-color:#e6e6e6}.toast-light i{color:#8c8c8c}.toast-dark{background-color:#332e2e;color:#f5f5f5;border-color:#443c3c}.toast-dark i{color:#e8e8e8}.tooltip{--mdb-tooltip-font-size: 14px}.tooltip.show{opacity:1}.tooltip .tooltip-arrow{display:none}.tooltip-inner{font-size:var(--mdb-tooltip-font-size)}.popover{--mdb-popover-border-bottom-width: 2px}.popover .popover-arrow{display:none}.popover-header{border-bottom:var(--mdb-popover-border-bottom-width) solid var(--mdb-popover-border-color)}.nav-pills.menu-sidebar .nav-link{--mdb-scrollspy-menu-sidebar-font-size: .8rem;--mdb-scrollspy-menu-sidebar-color: #262626;--mdb-scrollspy-menu-sidebar-line-height: 1.1rem;--mdb-scrollspy-menu-sidebar-padding-x: 5px;--mdb-scrollspy-menu-sidebar-font-weight: 400;--mdb-scrollspy-menu-sidebar-transition: all .2s ease-in-out;--mdb-scrollspy-menu-sidebar-margin-y: 3px;font-size:var(--mdb-scrollspy-menu-sidebar-font-size);background-color:#0000;color:var(--mdb-scrollspy-menu-sidebar-color);line-height:var(--mdb-scrollspy-menu-sidebar-line-height);padding:0 var(--mdb-scrollspy-menu-sidebar-padding-x);font-weight:var(--mdb-scrollspy-menu-sidebar-font-weight);transition:var(--mdb-scrollspy-menu-sidebar-transition);text-transform:initial;margin-top:var(--mdb-scrollspy-menu-sidebar-margin-y);margin-bottom:var(--mdb-scrollspy-menu-sidebar-margin-y)}.nav-pills.menu-sidebar .nav-link.active,.nav-pills.menu-sidebar .show>.nav-link{--mdb-scrollspy-menu-sidebar-active-color: #3b71ca;--mdb-scrollspy-menu-sidebar-active-font-weight: 600;--mdb-scrollspy-menu-sidebar-active-border-width: .125rem;--mdb-scrollspy-menu-sidebar-active-border-color: #3b71ca;background-color:#0000;box-shadow:none;color:var(--mdb-scrollspy-menu-sidebar-active-color);font-weight:var(--mdb-scrollspy-menu-sidebar-active-font-weight);border-left:var(--mdb-scrollspy-menu-sidebar-active-border-width) solid var(--mdb-scrollspy-menu-sidebar-active-border-color);border-radius:0}.nav-pills.menu-sidebar .collapsible-scrollspy~.nav{--mdb-scrollspy-collapsible-nav-transition-time: .5s;transition:height var(--mdb-scrollspy-collapsible-nav-transition-time) ease;flex-wrap:nowrap}.ripple-surface{position:relative;overflow:hidden;display:inline-block;vertical-align:bottom}.ripple-surface-unbound{overflow:visible}.ripple-wave{--mdb-ripple-wave-cubicBezier: cubic-bezier(0, 0, .15, 1);--mdb-ripple-wave-border-radius: 50%;--mdb-ripple-wave-opacity: .5;--mdb-ripple-wave-transform: scale(0);--mdb-ripple-wave-z-index: 999;--mdb-ripple-wave-active-transform: scale(1);background-image:radial-gradient(circle,rgba(0,0,0,.2) 0,rgba(0,0,0,.3) 40%,rgba(0,0,0,.4) 50%,rgba(0,0,0,.5) 60%,rgba(0,0,0,0) 70%);border-radius:var(--mdb-ripple-wave-border-radius);opacity:var(--mdb-ripple-wave-opacity);pointer-events:none;position:absolute;touch-action:none;transform:var(--mdb-ripple-wave-transform);transition-property:transform,opacity;transition-timing-function:var(--mdb-ripple-wave-cubicBezier),var(--mdb-ripple-wave-cubicBezier);z-index:var(--mdb-ripple-wave-z-index)}.ripple-wave.active{transform:var(--mdb-ripple-wave-active-transform);opacity:0}.btn .ripple-wave,.input-wrapper .ripple-wave{background-image:radial-gradient(circle,rgba(255,255,255,.2) 0,rgba(255,255,255,.3) 40%,rgba(255,255,255,.4) 50%,rgba(255,255,255,.5) 60%,rgba(255,255,255,0) 70%)}.ripple-surface-primary .ripple-wave{background-image:radial-gradient(circle,rgba(59,113,202,.2) 0,rgba(59,113,202,.3) 40%,rgba(59,113,202,.4) 50%,rgba(59,113,202,.5) 60%,rgba(59,113,202,0) 70%)}.ripple-surface-secondary .ripple-wave{background-image:radial-gradient(circle,rgba(227,235,247,.2) 0,rgba(227,235,247,.3) 40%,rgba(227,235,247,.4) 50%,rgba(227,235,247,.5) 60%,rgba(227,235,247,0) 70%)}.ripple-surface-success .ripple-wave{background-image:radial-gradient(circle,rgba(20,164,77,.2) 0,rgba(20,164,77,.3) 40%,rgba(20,164,77,.4) 50%,rgba(20,164,77,.5) 60%,rgba(20,164,77,0) 70%)}.ripple-surface-danger .ripple-wave{background-image:radial-gradient(circle,rgba(220,76,100,.2) 0,rgba(220,76,100,.3) 40%,rgba(220,76,100,.4) 50%,rgba(220,76,100,.5) 60%,rgba(220,76,100,0) 70%)}.ripple-surface-warning .ripple-wave{background-image:radial-gradient(circle,rgba(228,161,27,.2) 0,rgba(228,161,27,.3) 40%,rgba(228,161,27,.4) 50%,rgba(228,161,27,.5) 60%,rgba(228,161,27,0) 70%)}.ripple-surface-info .ripple-wave{background-image:radial-gradient(circle,rgba(84,180,211,.2) 0,rgba(84,180,211,.3) 40%,rgba(84,180,211,.4) 50%,rgba(84,180,211,.5) 60%,rgba(84,180,211,0) 70%)}.ripple-surface-light .ripple-wave{background-image:radial-gradient(circle,rgba(251,251,251,.2) 0,rgba(251,251,251,.3) 40%,rgba(251,251,251,.4) 50%,rgba(251,251,251,.5) 60%,rgba(251,251,251,0) 70%)}.ripple-surface-dark .ripple-wave{background-image:radial-gradient(circle,rgba(51,45,45,.2) 0,rgba(51,45,45,.3) 40%,rgba(51,45,45,.4) 50%,rgba(51,45,45,.5) 60%,rgba(51,45,45,0) 70%)}.range{--mdb-range-thumb-height: 30px;--mdb-range-thumb-width: 30px;--mdb-range-thumb-top: -35px;--mdb-range-thumb-margin-left: -15px;--mdb-range-thumb-border-radius: 50% 50% 50% 0;--mdb-range-thumb-transform: scale(0);--mdb-range-thumb-transition: transform .2s ease-in-out;--mdb-range-thumb-value-font-size: 12px;--mdb-range-thumb-value-line-height: 30px;--mdb-range-thumb-value-color: rgb(255, 255, 255);--mdb-range-thumb-value-font-weight: 500;--mdb-range-thumb-background: #3b71ca;position:relative}.range .thumb{position:absolute;display:block;height:var(--mdb-range-thumb-height);width:var(--mdb-range-thumb-width);top:var(--mdb-range-thumb-top);margin-left:var(--mdb-range-thumb-margin-left);text-align:center;border-radius:var(--mdb-range-thumb-border-radius);transform:var(--mdb-range-thumb-transform);transform-origin:bottom;transition:var(--mdb-range-thumb-transition)}.range .thumb:after{position:absolute;display:block;content:"";transform:translate(-50%);width:100%;height:100%;top:0;border-radius:var(--mdb-range-thumb-border-radius);transform:rotate(-45deg);background:var(--mdb-range-thumb-background);z-index:-1}.range .thumb .thumb-value{display:block;font-size:var(--mdb-range-thumb-value-font-size);line-height:var(--mdb-range-thumb-value-line-height);color:var(--mdb-range-thumb-value-color);font-weight:var(--mdb-range-thumb-value-font-weight);z-index:2}.range .thumb.thumb-active{transform:scale(1)}.accordion-button:not(.collapsed):focus{box-shadow:var(--mdb-accordion-btn-focus-box-shadow)}.accordion-button:focus{border-color:var(--mdb-accordion-btn-focus-border-color);outline:0;box-shadow:none}.accordion-flush{--mdb-accordion-flush-btn-box-shadow: inset 0 -2px 0 hsl(0, 0%, 96%);--mdb-accordion-flush-border-bottom: 2px solid hsl(0, 0%, 96%)}.accordion-flush .accordion-button:not(.collapsed){box-shadow:var(--mdb-accordion-flush-btn-box-shadow)}.accordion-flush .accordion-item{border-bottom:var(--mdb-accordion-flush-border-bottom)}.accordion.accordion-borderless,.accordion.accordion-flush{--mdb-accordion-bg: transparent;background-color:var(--mdb-accordion-bg)}.accordion-borderless{--mdb-accordion-borderless-btn-border-radius: .5rem;--mdb-accordion-borderless-btn-bg: rgb(223, 231, 246);--mdb-accordion-borderless-btn-color: rgb(44, 88, 160)}.accordion-borderless .accordion-item{border:0}.accordion-borderless .accordion-item .accordion-button{border-radius:var(--mdb-accordion-borderless-btn-border-radius)}.accordion-borderless .accordion-item .accordion-button:not(.collapsed){background-color:var(--mdb-accordion-borderless-btn-bg);color:var(--mdb-accordion-borderless-btn-color);box-shadow:none}.carousel-control-prev-icon:after{content:"";--mdb-carousel-control-icon-font-size: 1.7rem;--mdb-carousel-control-icon-font-weight: 700;font-weight:var(--mdb-carousel-control-icon-font-weight);font-size:var(--mdb-carousel-control-icon-font-size);font-family:"Font Awesome 6 Pro","Font Awesome 6 Free"}.carousel-control-next-icon:after{content:"";--mdb-carousel-control-icon-font-size: 1.7rem;--mdb-carousel-control-icon-font-weight: 700;font-weight:var(--mdb-carousel-control-icon-font-weight);font-size:var(--mdb-carousel-control-icon-font-size);font-family:"Font Awesome 6 Pro","Font Awesome 6 Free"}.form-check-input[type=checkbox]{margin-right:0}.form-check-label{padding-left:.15rem}.badge:not(.badge-dot):not(.badge-notification){margin:0 .12rem}.btn{margin:0 .12rem}.input-group .btn{margin:0}.btn-group>.btn,.btn-group-vertical>.btn{margin:0}.carousel-indicators button{box-sizing:content-box;flex:0 1 auto;width:30px;height:3px;padding:0;margin-right:3px;margin-left:3px;text-indent:-999px;cursor:pointer;background-color:#fff;background-clip:padding-box;border:0;border-top:10px solid rgba(0,0,0,0);border-bottom:10px solid rgba(0,0,0,0);opacity:.5;transition:opacity .6s ease}.carousel-dark .carousel-indicators button{background-color:#000}@media (max-width: 575.98px){.navbar-expand-sm .navbar-collapse{display:none!important}.navbar-expand-sm .navbar-collapse.show{display:block!important}}@media (min-width: 576px){.navbar-expand-sm .collapse.navbar-collapse:not(.show){display:flex!important;height:auto!important}}@media (max-width: 767.98px){.navbar-expand-md .navbar-collapse{display:none!important}.navbar-expand-md .navbar-collapse.show{display:block!important}}@media (min-width: 768px){.navbar-expand-md .collapse.navbar-collapse:not(.show){display:flex!important;height:auto!important}}@media (max-width: 991.98px){.navbar-expand-lg .navbar-collapse{display:none!important}.navbar-expand-lg .navbar-collapse.show{display:block!important}}@media (min-width: 992px){.navbar-expand-lg .collapse.navbar-collapse:not(.show){display:flex!important;height:auto!important}}@media (max-width: 1199.98px){.navbar-expand-xl .navbar-collapse{display:none!important}.navbar-expand-xl .navbar-collapse.show{display:block!important}}@media (min-width: 1200px){.navbar-expand-xl .collapse.navbar-collapse:not(.show){display:flex!important;height:auto!important}}@media (max-width: 1399.98px){.navbar-expand-xxl .navbar-collapse{display:none!important}.navbar-expand-xxl .navbar-collapse.show{display:block!important}}@media (min-width: 1400px){.navbar-expand-xxl .collapse.navbar-collapse:not(.show){display:flex!important;height:auto!important}}.navbar-expand .navbar-collapse{display:none!important}.navbar-expand .navbar-collapse.show{display:block!important}.navbar-expand .collapse.navbar-collapse:not(.show){display:flex!important;height:auto!important}.tooltip .tooltip_arrow{width:0;height:0;border-style:solid;position:absolute;margin:5px}.tooltip[data-popper-placement^=top] .tooltip_arrow{border-width:5px 5px 0 5px;border-color:#6d6d6d rgba(0,0,0,0) rgba(0,0,0,0) rgba(0,0,0,0);bottom:-5px;left:calc(50% - 5px);margin-top:0;margin-bottom:0;left:-5px!important}.tooltip[data-popper-placement^=bottom] .tooltip_arrow{border-width:0 5px 5px 5px;border-color:rgba(0,0,0,0) rgba(0,0,0,0) #6d6d6d rgba(0,0,0,0);top:-5px;left:calc(50% - 5px);margin-top:0;margin-bottom:0;left:-5px!important}.tooltip[data-popper-placement^=right] .tooltip_arrow{border-width:5px 5px 5px 0;border-color:rgba(0,0,0,0) #6d6d6d rgba(0,0,0,0) rgba(0,0,0,0);left:-5px;top:calc(50% - 5px);margin-left:0;margin-right:0;top:-5px!important}.tooltip[data-popper-placement^=left] .tooltip_arrow{border-width:5px 0 5px 5px;border-color:rgba(0,0,0,0) rgba(0,0,0,0) rgba(0,0,0,0) #6d6d6d;right:-5px;top:calc(50% - 5px);margin-left:0;margin-right:0;top:-5px!important}.fade-leave-active,.fade-enter-active{transition:opacity .2s linear}.fade-enter-to,.fade-leave-from{opacity:1}.tooltip{position:absolute}.popover .popover_arrow{width:0;height:0;border-style:solid;position:absolute;margin:5px;color:#0000}.popover[data-popper-placement^=top] .popover_arrow{border-width:10px 10px 0 10px;border-color:#d6d6d6 rgba(0,0,0,0) rgba(0,0,0,0) rgba(0,0,0,0);bottom:-10px;margin-bottom:0;left:-10px!important}.popover[data-popper-placement^=top] .popover_arrow:before{content:"";display:inline-block;position:absolute;left:-10px;bottom:1.5px;border:solid;border-width:10px 10px 0 10px;border-color:#fff rgba(0,0,0,0) rgba(0,0,0,0) rgba(0,0,0,0)}.popover[data-popper-placement^=bottom] .popover_arrow{border-width:0 10px 10px 10px;border-color:rgba(0,0,0,0) rgba(0,0,0,0) #d6d6d6 rgba(0,0,0,0);top:-10px;margin-top:0;left:-10px!important}.popover[data-popper-placement^=bottom] .popover_arrow:before{content:"";display:inline-block;position:absolute;left:-10px;top:1.45px;border:solid;border-width:0 10px 10px 10px;border-color:rgba(0,0,0,0) rgba(0,0,0,0) #fff rgba(0,0,0,0)}.popover[data-popper-placement^=right] .popover_arrow{border-width:10px 10px 10px 0;border-color:rgba(0,0,0,0) #d6d6d6 rgba(0,0,0,0) rgba(0,0,0,0);left:-10px;margin-left:0;top:-10px!important}.popover[data-popper-placement^=right] .popover_arrow:before{content:"";display:inline-block;position:absolute;top:-10px;left:1.45px;border:solid;border-width:10px 10px 10px 0;border-color:rgba(0,0,0,0) #fff rgba(0,0,0,0) rgba(0,0,0,0)}.popover[data-popper-placement^=left] .popover_arrow{border-width:10px 0 10px 10px;border-color:rgba(0,0,0,0) rgba(0,0,0,0) rgba(0,0,0,0) #d6d6d6;right:-10px;margin-right:0;top:-10px!important}.popover[data-popper-placement^=left] .popover_arrow:before{content:"";display:inline-block;position:absolute;top:-10px;right:1.45px;border:solid;border-width:10px 0 10px 10px;border-color:rgba(0,0,0,0) rgba(0,0,0,0) rgba(0,0,0,0) #fff}.popover{position:absolute}.nav-pills.menu-sidebar .nav-link{border-left:0 solid rgba(0,0,0,0)}.valid-feedback{width:auto}.is-valid .form-outline .form-control~.form-label{color:#00b74a}.is-valid .form-outline .form-control~.form-notch .form-notch-leading,.is-valid .form-outline .form-control~.form-notch .form-notch-middle,.is-valid .form-outline .form-control~.form-notch .form-notch-trailing{border-color:#00b74a}.is-valid .form-outline .form-control:focus~.form-notch .form-notch-middle,.is-valid .form-outline .form-control.active~.form-notch .form-notch-middle{border-top:1px solid rgba(0,0,0,0)}.is-valid .form-outline .form-control:focus~.form-notch .form-notch-middle{box-shadow:0 1px #00b74a}.is-valid .form-outline .form-control:focus~.form-notch .form-notch-leading{box-shadow:-1px 0 #00b74a,0 1px #00b74a,0 -1px #00b74a}.is-valid .form-outline .form-control:focus~.form-notch .form-notch-trailing{box-shadow:1px 0 #00b74a,0 -1px #00b74a,0 1px #00b74a}.is-valid .form-outline .form-control.select-input.focused~.form-notch .form-notch-leading{box-shadow:-1px 0 #00b74a,0 1px #00b74a,0 -1px #00b74a}.is-valid .form-outline .form-control.select-input.focused~.form-notch .form-notch-middle{box-shadow:0 1px #00b74a;border-top:1px solid rgba(0,0,0,0)}.is-valid .form-outline .form-control.select-input.focused~.form-notch .form-notch-trailing{box-shadow:1px 0 #00b74a,0 -1px #00b74a,0 1px #00b74a}.is-invalid .form-outline .form-control~.form-label{color:#f93154}.is-invalid .form-outline .form-control~.form-notch .form-notch-leading,.is-invalid .form-outline .form-control~.form-notch .form-notch-middle,.is-invalid .form-outline .form-control~.form-notch .form-notch-trailing{border-color:#f93154}.is-invalid .form-outline .form-control:focus~.form-notch .form-notch-middle,.is-invalid .form-outline .form-control.active~.form-notch .form-notch-middle{border-top:1px solid rgba(0,0,0,0)}.is-invalid .form-outline .form-control:focus~.form-notch .form-notch-middle{box-shadow:0 1px #f93154}.is-invalid .form-outline .form-control:focus~.form-notch .form-notch-leading{box-shadow:-1px 0 #f93154,0 1px #f93154,0 -1px #f93154}.is-invalid .form-outline .form-control:focus~.form-notch .form-notch-trailing{box-shadow:1px 0 #f93154,0 -1px #f93154,0 1px #f93154}.is-invalid .form-outline .form-control.select-input.focused~.form-notch .form-notch-leading{box-shadow:-1px 0 #f93154,0 1px #f93154,0 -1px #f93154}.is-invalid .form-outline .form-control.select-input.focused~.form-notch .form-notch-middle{box-shadow:0 1px #f93154;border-top:1px solid rgba(0,0,0,0)}.is-invalid .form-outline .form-control.select-input.focused~.form-notch .form-notch-trailing{box-shadow:1px 0 #f93154,0 -1px #f93154,0 1px #f93154}.nav-tabs .nav-link,.nav-pills .nav-link{cursor:pointer}.input-group .btn-group{box-shadow:none}.input-group:not(.has-validation)>.btn-group:not(:last-child)>:not(:last-child):not(.dropdown-menu),.input-group:not(.has-validation)>.btn-group:not(:last-child)>.dropdown-toggle:last-child,.input-group:not(.has-validation)>.btn-group:not(:last-child) .dropdown-toggle:nth-last-child(n+1){border-top-right-radius:0;border-bottom-right-radius:0}.input-group.has-validation>.btn-group>:last-child:not(.dropdown-toggle):not(.dropdown-menu),.input-group.has-validation>.btn-group>.dropdown-toggle:last-child{border-top-right-radius:0;border-bottom-right-radius:0}.input-group>.btn-group:last-child>:first-child:not(.dropdown-menu){border-top-left-radius:0;border-bottom-left-radius:0}.input-group-text{min-height:calc(2.08rem + 2px);height:calc(2.08rem + 2px)}.input-group-lg .input-group-text{height:calc(2.645rem + 2px);font-size:1rem}.input-group-sm .input-group-text{min-height:calc(1.66rem + 2px);height:calc(1.66rem + 2px);font-size:.775rem;line-height:1.5}.form-outline .form-control:focus~.form-label~.form-label{transform:none;color:#0009}.modal-scrollbar-measure{position:absolute;top:-9999px;width:50px;height:50px;overflow:scroll}.modal-open{overflow:hidden}.modal-open .modal{overflow-x:hidden;overflow-y:auto}h1[data-v-e979a9d8]{margin-top:2rem}.card[data-v-e979a9d8]{margin-bottom:2rem}.status-message[data-v-e979a9d8]{font-style:italic}.fork[data-v-e979a9d8]{float:right;margin-top:-3em} +*/#mdb-table-flag tr{cursor:pointer}.mdb-flag-selected{border-top-left-radius:5px;border-top-right-radius:5px;text-align:center;max-width:150px;margin:10px auto 0}.mdb-selected-flag-text{margin:0 auto;max-width:150px}i.flag:not(.icon){display:inline-block;width:16px;height:11px;margin:0 .5em 0 0;line-height:11px;text-decoration:inherit;vertical-align:baseline;backface-visibility:hidden}i.flag:before{display:inline-block;width:16px;height:11px;content:"";background:url(https://mdbootstrap.com/img/svg/flags.png) no-repeat -108px -1976px}i.flag-ad:before,i.flag-andorra:before{background-position:0 0!important}i.flag-ae:before,i.flag-united-arab-emirates:before,i.flag-uae:before{background-position:0 -26px!important}i.flag-af:before,i.flag-afghanistan:before{background-position:0 -52px!important}i.flag-ag:before,i.flag-antigua:before{background-position:0 -78px!important}i.flag-ai:before,i.flag-anguilla:before{background-position:0 -104px!important}i.flag-al:before,i.flag-albania:before{background-position:0 -130px!important}i.flag-am:before,i.flag-armenia:before{background-position:0 -156px!important}i.flag-an:before,i.flag-netherlands-antilles:before{background-position:0 -182px!important}i.flag-ao:before,i.flag-angola:before{background-position:0 -208px!important}i.flag-ar:before,i.flag-argentina:before{background-position:0 -234px!important}i.flag-as:before,i.flag-american-samoa:before{background-position:0 -260px!important}i.flag-at:before,i.flag-austria:before{background-position:0 -286px!important}i.flag-au:before,i.flag-australia:before{background-position:0 -312px!important}i.flag-aw:before,i.flag-aruba:before{background-position:0 -338px!important}i.flag-ax:before,i.flag-aland-islands:before{background-position:0 -364px!important}i.flag-az:before,i.flag-azerbaijan:before{background-position:0 -390px!important}i.flag-ba:before,i.flag-bosnia:before{background-position:0 -416px!important}i.flag-bb:before,i.flag-barbados:before{background-position:0 -442px!important}i.flag-bd:before,i.flag-bangladesh:before{background-position:0 -468px!important}i.flag-be:before,i.flag-belgium:before{background-position:0 -494px!important}i.flag-bf:before,i.flag-burkina-faso:before{background-position:0 -520px!important}i.flag-bg:before,i.flag-bulgaria:before{background-position:0 -546px!important}i.flag-bh:before,i.flag-bahrain:before{background-position:0 -572px!important}i.flag-bi:before,i.flag-burundi:before{background-position:0 -598px!important}i.flag-bj:before,i.flag-benin:before{background-position:0 -624px!important}i.flag-bm:before,i.flag-bermuda:before{background-position:0 -650px!important}i.flag-bn:before,i.flag-brunei:before{background-position:0 -676px!important}i.flag-bo:before,i.flag-bolivia:before{background-position:0 -702px!important}i.flag-br:before,i.flag-brazil:before{background-position:0 -728px!important}i.flag-bs:before,i.flag-bahamas:before{background-position:0 -754px!important}i.flag-bt:before,i.flag-bhutan:before{background-position:0 -780px!important}i.flag-bv:before,i.flag-bouvet-island:before{background-position:0 -806px!important}i.flag-bw:before,i.flag-botswana:before{background-position:0 -832px!important}i.flag-by:before,i.flag-belarus:before{background-position:0 -858px!important}i.flag-bz:before,i.flag-belize:before{background-position:0 -884px!important}i.flag-ca:before,i.flag-canada:before{background-position:0 -910px!important}i.flag-cc:before,i.flag-cocos-islands:before{background-position:0 -962px!important}i.flag-cd:before,i.flag-congo:before{background-position:0 -988px!important}i.flag-cf:before,i.flag-central-african-republic:before{background-position:0 -1014px!important}i.flag-cg:before,i.flag-congo-brazzaville:before{background-position:0 -1040px!important}i.flag-ch:before,i.flag-switzerland:before{background-position:0 -1066px!important}i.flag-ci:before,i.flag-cote-divoire:before{background-position:0 -1092px!important}i.flag-ck:before,i.flag-cook-islands:before{background-position:0 -1118px!important}i.flag-cl:before,i.flag-chile:before{background-position:0 -1144px!important}i.flag-cm:before,i.flag-cameroon:before{background-position:0 -1170px!important}i.flag-cn:before,i.flag-china:before{background-position:0 -1196px!important}i.flag-co:before,i.flag-colombia:before{background-position:0 -1222px!important}i.flag-cr:before,i.flag-costa-rica:before{background-position:0 -1248px!important}i.flag-cs:before,i.flag-serbia:before{background-position:0 -1274px!important}i.flag-cu:before,i.flag-cuba:before{background-position:0 -1300px!important}i.flag-cv:before,i.flag-cape-verde:before{background-position:0 -1326px!important}i.flag-cx:before,i.flag-christmas-island:before{background-position:0 -1352px!important}i.flag-cy:before,i.flag-cyprus:before{background-position:0 -1378px!important}i.flag-cz:before,i.flag-czech-republic:before{background-position:0 -1404px!important}i.flag-de:before,i.flag-germany:before{background-position:0 -1430px!important}i.flag-dj:before,i.flag-djibouti:before{background-position:0 -1456px!important}i.flag-dk:before,i.flag-denmark:before{background-position:0 -1482px!important}i.flag-dm:before,i.flag-dominica:before{background-position:0 -1508px!important}i.flag-do:before,i.flag-dominican-republic:before{background-position:0 -1534px!important}i.flag-dz:before,i.flag-algeria:before{background-position:0 -1560px!important}i.flag-ec:before,i.flag-ecuador:before{background-position:0 -1586px!important}i.flag-ee:before,i.flag-estonia:before{background-position:0 -1612px!important}i.flag-eg:before,i.flag-egypt:before{background-position:0 -1638px!important}i.flag-eh:before,i.flag-western-sahara:before{background-position:0 -1664px!important}i.flag-gb-eng:before,i.flag-england:before{background-position:0 -1690px!important}i.flag-er:before,i.flag-eritrea:before{background-position:0 -1716px!important}i.flag-es:before,i.flag-spain:before{background-position:0 -1742px!important}i.flag-et:before,i.flag-ethiopia:before{background-position:0 -1768px!important}i.flag-eu:before,i.flag-european-union:before{background-position:0 -1794px!important}i.flag-fi:before,i.flag-finland:before{background-position:0 -1846px!important}i.flag-fj:before,i.flag-fiji:before{background-position:0 -1872px!important}i.flag-fk:before,i.flag-falkland-islands:before{background-position:0 -1898px!important}i.flag-fm:before,i.flag-micronesia:before{background-position:0 -1924px!important}i.flag-fo:before,i.flag-faroe-islands:before{background-position:0 -1950px!important}i.flag-fr:before,i.flag-france:before{background-position:0 -1976px!important}i.flag-ga:before,i.flag-gabon:before{background-position:-36px 0!important}i.flag-gb:before,i.flag-uk:before,i.flag-united-kingdom:before{background-position:-36px -26px!important}i.flag-gd:before,i.flag-grenada:before{background-position:-36px -52px!important}i.flag-ge:before,i.flag-georgia:before{background-position:-36px -78px!important}i.flag-gf:before,i.flag-french-guiana:before{background-position:-36px -104px!important}i.flag-gh:before,i.flag-ghana:before{background-position:-36px -130px!important}i.flag-gi:before,i.flag-gibraltar:before{background-position:-36px -156px!important}i.flag-gl:before,i.flag-greenland:before{background-position:-36px -182px!important}i.flag-gm:before,i.flag-gambia:before{background-position:-36px -208px!important}i.flag-gn:before,i.flag-guinea:before{background-position:-36px -234px!important}i.flag-gp:before,i.flag-guadeloupe:before{background-position:-36px -260px!important}i.flag-gq:before,i.flag-equatorial-guinea:before{background-position:-36px -286px!important}i.flag-gr:before,i.flag-greece:before{background-position:-36px -312px!important}i.flag-gs:before,i.flag-sandwich-islands:before{background-position:-36px -338px!important}i.flag-gt:before,i.flag-guatemala:before{background-position:-36px -364px!important}i.flag-gu:before,i.flag-guam:before{background-position:-36px -390px!important}i.flag-gw:before,i.flag-guinea-bissau:before{background-position:-36px -416px!important}i.flag-gy:before,i.flag-guyana:before{background-position:-36px -442px!important}i.flag-hk:before,i.flag-hong-kong:before{background-position:-36px -468px!important}i.flag-hm:before,i.flag-heard-island:before{background-position:-36px -494px!important}i.flag-hn:before,i.flag-honduras:before{background-position:-36px -520px!important}i.flag-hr:before,i.flag-croatia:before{background-position:-36px -546px!important}i.flag-ht:before,i.flag-haiti:before{background-position:-36px -572px!important}i.flag-hu:before,i.flag-hungary:before{background-position:-36px -598px!important}i.flag-id:before,i.flag-indonesia:before{background-position:-36px -624px!important}i.flag-ie:before,i.flag-ireland:before{background-position:-36px -650px!important}i.flag-il:before,i.flag-israel:before{background-position:-36px -676px!important}i.flag-in:before,i.flag-india:before{background-position:-36px -702px!important}i.flag-io:before,i.flag-indian-ocean-territory:before{background-position:-36px -728px!important}i.flag-iq:before,i.flag-iraq:before{background-position:-36px -754px!important}i.flag-ir:before,i.flag-iran:before{background-position:-36px -780px!important}i.flag-is:before,i.flag-iceland:before{background-position:-36px -806px!important}i.flag-it:before,i.flag-italy:before{background-position:-36px -832px!important}i.flag-jm:before,i.flag-jamaica:before{background-position:-36px -858px!important}i.flag-jo:before,i.flag-jordan:before{background-position:-36px -884px!important}i.flag-jp:before,i.flag-japan:before{background-position:-36px -910px!important}i.flag-ke:before,i.flag-kenya:before{background-position:-36px -936px!important}i.flag-kg:before,i.flag-kyrgyzstan:before{background-position:-36px -962px!important}i.flag-kh:before,i.flag-cambodia:before{background-position:-36px -988px!important}i.flag-ki:before,i.flag-kiribati:before{background-position:-36px -1014px!important}i.flag-km:before,i.flag-comoros:before{background-position:-36px -1040px!important}i.flag-kn:before,i.flag-saint-kitts-and-nevis:before{background-position:-36px -1066px!important}i.flag-kp:before,i.flag-north-korea:before{background-position:-36px -1092px!important}i.flag-kr:before,i.flag-south-korea:before{background-position:-36px -1118px!important}i.flag-kw:before,i.flag-kuwait:before{background-position:-36px -1144px!important}i.flag-ky:before,i.flag-cayman-islands:before{background-position:-36px -1170px!important}i.flag-kz:before,i.flag-kazakhstan:before{background-position:-36px -1196px!important}i.flag-la:before,i.flag-laos:before{background-position:-36px -1222px!important}i.flag-lb:before,i.flag-lebanon:before{background-position:-36px -1248px!important}i.flag-lc:before,i.flag-saint-lucia:before{background-position:-36px -1274px!important}i.flag-li:before,i.flag-liechtenstein:before{background-position:-36px -1300px!important}i.flag-lk:before,i.flag-sri-lanka:before{background-position:-36px -1326px!important}i.flag-lr:before,i.flag-liberia:before{background-position:-36px -1352px!important}i.flag-ls:before,i.flag-lesotho:before{background-position:-36px -1378px!important}i.flag-lt:before,i.flag-lithuania:before{background-position:-36px -1404px!important}i.flag-lu:before,i.flag-luxembourg:before{background-position:-36px -1430px!important}i.flag-lv:before,i.flag-latvia:before{background-position:-36px -1456px!important}i.flag-ly:before,i.flag-libya:before{background-position:-36px -1482px!important}i.flag-ma:before,i.flag-morocco:before{background-position:-36px -1508px!important}i.flag-mc:before,i.flag-monaco:before{background-position:-36px -1534px!important}i.flag-md:before,i.flag-moldova:before{background-position:-36px -1560px!important}i.flag-me:before,i.flag-montenegro:before{background-position:-36px -1586px!important}i.flag-mg:before,i.flag-madagascar:before{background-position:-36px -1613px!important}i.flag-mh:before,i.flag-marshall-islands:before{background-position:-36px -1639px!important}i.flag-mk:before,i.flag-macedonia:before{background-position:-36px -1665px!important}i.flag-ml:before,i.flag-mali:before{background-position:-36px -1691px!important}i.flag-mm:before,i.flag-myanmar:before,i.flag-burma:before{background-position:-73px -1821px!important}i.flag-mn:before,i.flag-mongolia:before{background-position:-36px -1743px!important}i.flag-mo:before,i.flag-macau:before{background-position:-36px -1769px!important}i.flag-mp:before,i.flag-northern-mariana-islands:before{background-position:-36px -1795px!important}i.flag-mq:before,i.flag-martinique:before{background-position:-36px -1821px!important}i.flag-mr:before,i.flag-mauritania:before{background-position:-36px -1847px!important}i.flag-ms:before,i.flag-montserrat:before{background-position:-36px -1873px!important}i.flag-mt:before,i.flag-malta:before{background-position:-36px -1899px!important}i.flag-mu:before,i.flag-mauritius:before{background-position:-36px -1925px!important}i.flag-mv:before,i.flag-maldives:before{background-position:-36px -1951px!important}i.flag-mw:before,i.flag-malawi:before{background-position:-36px -1977px!important}i.flag-mx:before,i.flag-mexico:before{background-position:-72px 0!important}i.flag-my:before,i.flag-malaysia:before{background-position:-72px -26px!important}i.flag-mz:before,i.flag-mozambique:before{background-position:-72px -52px!important}i.flag-na:before,i.flag-namibia:before{background-position:-72px -78px!important}i.flag-nc:before,i.flag-new-caledonia:before{background-position:-72px -104px!important}i.flag-ne:before,i.flag-niger:before{background-position:-72px -130px!important}i.flag-nf:before,i.flag-norfolk-island:before{background-position:-72px -156px!important}i.flag-ng:before,i.flag-nigeria:before{background-position:-72px -182px!important}i.flag-ni:before,i.flag-nicaragua:before{background-position:-72px -208px!important}i.flag-nl:before,i.flag-netherlands:before{background-position:-72px -234px!important}i.flag-no:before,i.flag-norway:before{background-position:-72px -260px!important}i.flag-np:before,i.flag-nepal:before{background-position:-72px -286px!important}i.flag-nr:before,i.flag-nauru:before{background-position:-72px -312px!important}i.flag-nu:before,i.flag-niue:before{background-position:-72px -338px!important}i.flag-nz:before,i.flag-new-zealand:before{background-position:-72px -364px!important}i.flag-om:before,i.flag-oman:before{background-position:-72px -390px!important}i.flag-pa:before,i.flag-panama:before{background-position:-72px -416px!important}i.flag-pe:before,i.flag-peru:before{background-position:-72px -442px!important}i.flag-pf:before,i.flag-french-polynesia:before{background-position:-72px -468px!important}i.flag-pg:before,i.flag-new-guinea:before{background-position:-72px -494px!important}i.flag-ph:before,i.flag-philippines:before{background-position:-72px -520px!important}i.flag-pk:before,i.flag-pakistan:before{background-position:-72px -546px!important}i.flag-pl:before,i.flag-poland:before{background-position:-72px -572px!important}i.flag-pm:before,i.flag-saint-pierre:before{background-position:-72px -598px!important}i.flag-pn:before,i.flag-pitcairn-islands:before{background-position:-72px -624px!important}i.flag-pr:before,i.flag-puerto-rico:before{background-position:-72px -650px!important}i.flag-ps:before,i.flag-palestine:before{background-position:-72px -676px!important}i.flag-pt:before,i.flag-portugal:before{background-position:-72px -702px!important}i.flag-pw:before,i.flag-palau:before{background-position:-72px -728px!important}i.flag-py:before,i.flag-paraguay:before{background-position:-72px -754px!important}i.flag-qa:before,i.flag-qatar:before{background-position:-72px -780px!important}i.flag-re:before,i.flag-reunion:before{background-position:-72px -806px!important}i.flag-ro:before,i.flag-romania:before{background-position:-72px -832px!important}i.flag-rs:before,i.flag-serbia:before{background-position:-72px -858px!important}i.flag-ru:before,i.flag-russia:before{background-position:-72px -884px!important}i.flag-rw:before,i.flag-rwanda:before{background-position:-72px -910px!important}i.flag-sa:before,i.flag-saudi-arabia:before{background-position:-72px -936px!important}i.flag-sb:before,i.flag-solomon-islands:before{background-position:-72px -962px!important}i.flag-sc:before,i.flag-seychelles:before{background-position:-72px -988px!important}i.flag-gb-sct:before,i.flag-scotland:before{background-position:-72px -1014px!important}i.flag-sd:before,i.flag-sudan:before{background-position:-72px -1040px!important}i.flag-se:before,i.flag-sweden:before{background-position:-72px -1066px!important}i.flag-sg:before,i.flag-singapore:before{background-position:-72px -1092px!important}i.flag-sh:before,i.flag-saint-helena:before{background-position:-72px -1118px!important}i.flag-si:before,i.flag-slovenia:before{background-position:-72px -1144px!important}i.flag-sj:before,i.flag-svalbard:before,i.flag-jan-mayen:before{background-position:-72px -1170px!important}i.flag-sk:before,i.flag-slovakia:before{background-position:-72px -1196px!important}i.flag-sl:before,i.flag-sierra-leone:before{background-position:-72px -1222px!important}i.flag-sm:before,i.flag-san-marino:before{background-position:-72px -1248px!important}i.flag-sn:before,i.flag-senegal:before{background-position:-72px -1274px!important}i.flag-so:before,i.flag-somalia:before{background-position:-72px -1300px!important}i.flag-sr:before,i.flag-suriname:before{background-position:-72px -1326px!important}i.flag-st:before,i.flag-sao-tome:before{background-position:-72px -1352px!important}i.flag-sv:before,i.flag-el-salvador:before{background-position:-72px -1378px!important}i.flag-sy:before,i.flag-syria:before{background-position:-72px -1404px!important}i.flag-sz:before,i.flag-swaziland:before{background-position:-72px -1430px!important}i.flag-tc:before,i.flag-caicos-islands:before{background-position:-72px -1456px!important}i.flag-td:before,i.flag-chad:before{background-position:-72px -1482px!important}i.flag-tf:before,i.flag-french-territories:before{background-position:-72px -1508px!important}i.flag-tg:before,i.flag-togo:before{background-position:-72px -1534px!important}i.flag-th:before,i.flag-thailand:before{background-position:-72px -1560px!important}i.flag-tj:before,i.flag-tajikistan:before{background-position:-72px -1586px!important}i.flag-tk:before,i.flag-tokelau:before{background-position:-72px -1612px!important}i.flag-tl:before,i.flag-timorleste:before{background-position:-72px -1638px!important}i.flag-tm:before,i.flag-turkmenistan:before{background-position:-72px -1664px!important}i.flag-tn:before,i.flag-tunisia:before{background-position:-72px -1690px!important}i.flag-to:before,i.flag-tonga:before{background-position:-72px -1716px!important}i.flag-tr:before,i.flag-turkey:before{background-position:-72px -1742px!important}i.flag-tt:before,i.flag-trinidad:before{background-position:-72px -1768px!important}i.flag-tv:before,i.flag-tuvalu:before{background-position:-72px -1794px!important}i.flag-tw:before,i.flag-taiwan:before{background-position:-72px -1820px!important}i.flag-tz:before,i.flag-tanzania:before{background-position:-72px -1846px!important}i.flag-ua:before,i.flag-ukraine:before{background-position:-72px -1872px!important}i.flag-ug:before,i.flag-uganda:before{background-position:-72px -1898px!important}i.flag-um:before,i.flag-us-minor-islands:before{background-position:-72px -1924px!important}i.flag-us:before,i.flag-america:before,i.flag-united-states:before{background-position:-72px -1950px!important}i.flag-uy:before,i.flag-uruguay:before{background-position:-72px -1976px!important}i.flag-uz:before,i.flag-uzbekistan:before{background-position:-108px 0!important}i.flag-va:before,i.flag-vatican-city:before{background-position:-108px -26px!important}i.flag-vc:before,i.flag-saint-vincent:before{background-position:-108px -52px!important}i.flag-ve:before,i.flag-venezuela:before{background-position:-108px -78px!important}i.flag-vg:before,i.flag-british-virgin-islands:before{background-position:-108px -104px!important}i.flag-vi:before,i.flag-us-virgin-islands:before{background-position:-108px -130px!important}i.flag-vn:before,i.flag-vietnam:before{background-position:-108px -156px!important}i.flag-vu:before,i.flag-vanuatu:before{background-position:-108px -182px!important}i.flag-gb-wls:before,i.flag-wales:before{background-position:-108px -208px!important}i.flag-wf:before,i.flag-wallis-and-futuna:before{background-position:-108px -234px!important}i.flag-ws:before,i.flag-samoa:before{background-position:-108px -260px!important}i.flag-ye:before,i.flag-yemen:before{background-position:-108px -286px!important}i.flag-yt:before,i.flag-mayotte:before{background-position:-108px -312px!important}i.flag-za:before,i.flag-south-africa:before{background-position:-108px -338px!important}i.flag-zm:before,i.flag-zambia:before{background-position:-108px -364px!important}i.flag-zw:before,i.flag-zimbabwe:before{background-position:-108px -390px!important}.bg-fixed{background-attachment:fixed}.bg-image{position:relative;overflow:hidden;background-repeat:no-repeat;background-size:cover;background-position:center center}.mask{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;overflow:hidden;background-attachment:fixed}.hover-overlay .mask{--mdb-image-hover-transition: all .3s ease-in-out;opacity:0;transition:var(--mdb-image-hover-transition)}.hover-overlay .mask:hover{opacity:1}.hover-zoom{--mdb-image-hover-zoom-transition: all .3s linear;--mdb-image-hover-zoom-transform: scale(1.1)}.hover-zoom img,.hover-zoom video{transition:var(--mdb-image-hover-zoom-transition)}.hover-zoom:hover img,.hover-zoom:hover video{transform:var(--mdb-image-hover-zoom-transform)}.hover-shadow,.card.hover-shadow,.hover-shadow-soft,.card.hover-shadow-soft{--mdb-image-hover-shadow-transition: all .3s ease-in-out;transition:var(--mdb-image-hover-shadow-transition)}.hover-shadow:hover,.card.hover-shadow:hover,.hover-shadow-soft:hover,.card.hover-shadow-soft:hover{transition:var(--mdb-image-hover-shadow-transition)}.hover-shadow,.card.hover-shadow{--mdb-image-hover-shadow-box-shadow: 0 2px 15px -3px rgba(0, 0, 0, .16), 0 10px 20px -2px rgba(0, 0, 0, .1);box-shadow:none}.hover-shadow:hover,.card.hover-shadow:hover{box-shadow:var(--mdb-image-hover-shadow-box-shadow)}.hover-shadow-soft,.card.hover-shadow-soft{--mdb-image-hover-shadow-box-shadow-soft: 0 2px 25px -5px rgba(0, 0, 0, .07), 0 25px 21px -5px rgba(0, 0, 0, .04);box-shadow:none}.hover-shadow-soft:hover,.card.hover-shadow-soft:hover{box-shadow:var(--mdb-image-hover-shadow-box-shadow-soft)}.form-control{min-height:auto;padding:4.5px 12px 3.68px;transition:all .1s linear;box-shadow:none}.form-control:focus{box-shadow:none;transition:all .1s linear;border-color:#3b71ca;box-shadow:inset 0 0 0 1px #3b71ca}.form-control.form-control-sm{font-size:.775rem;line-height:1.5}.form-control.form-control-lg{line-height:2.15;border-radius:.25rem}.form-outline{position:relative;width:100%}.form-outline .form-helper{width:100%;position:absolute;font-size:.875em;color:#757575}.form-outline .form-helper .form-counter{text-align:right}.form-outline .trailing{position:absolute;right:10px;left:initial;top:50%;transform:translateY(-50%);pointer-events:none}.form-outline .form-icon-trailing{padding-right:2rem!important}.form-outline .form-control{min-height:auto;padding:.32rem .75rem;border:0;background:rgba(0,0,0,0);transition:all .2s linear}.form-outline .form-control~.form-label{position:absolute;top:0;max-width:90%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;left:.75rem;padding-top:.37rem;pointer-events:none;transform-origin:0 0;transition:all .2s ease-out;color:#0009;margin-bottom:0}.form-outline .form-control~.form-notch{display:flex;position:absolute;left:0;top:0;width:100%;max-width:100%;height:100%;text-align:left;pointer-events:none}.form-outline .form-control~.form-notch div{pointer-events:none;border:1px solid;border-color:#bdbdbd;box-sizing:border-box;background:rgba(0,0,0,0);transition:all .2s linear}.form-outline .form-control~.form-notch .form-notch-leading{left:0;top:0;height:100%;width:.5rem;border-right:none;border-radius:.25rem 0 0 .25rem}.form-outline .form-control~.form-notch .form-notch-middle{flex:0 0 auto;width:auto;max-width:calc(100% - 1rem);height:100%;border-right:none;border-left:none}.form-outline .form-control~.form-notch .form-notch-trailing{flex-grow:1;height:100%;border-left:none;border-radius:0 .25rem .25rem 0}.form-outline .form-control:not(.placeholder-active)::placeholder{opacity:0}.form-outline .form-control:focus::placeholder,.form-outline .form-control.active::placeholder{opacity:1}.form-outline .form-control:focus{box-shadow:none!important}.form-outline .form-control:focus~.form-label,.form-outline .form-control.active~.form-label{transform:translateY(-1rem) translateY(.1rem) scale(.8)}.form-outline .form-control:focus~.form-label{color:#3b71ca}.form-outline .form-control:focus~.form-notch .form-notch-middle,.form-outline .form-control.active~.form-notch .form-notch-middle{border-right:none;border-left:none;border-top:1px solid rgba(0,0,0,0)}.form-outline .form-control:focus~.form-notch .form-notch-middle{border-color:#3b71ca;box-shadow:0 1px #3b71ca;border-top:1px solid rgba(0,0,0,0)}.form-outline .form-control:focus~.form-notch .form-notch-leading,.form-outline .form-control.active~.form-notch .form-notch-leading{border-right:none}.form-outline .form-control:focus~.form-notch .form-notch-leading{border-color:#3b71ca;box-shadow:-1px 0 #3b71ca,0 1px #3b71ca,0 -1px #3b71ca}.form-outline .form-control:focus~.form-notch .form-notch-trailing,.form-outline .form-control.active~.form-notch .form-notch-trailing{border-left:none}.form-outline .form-control:focus~.form-notch .form-notch-trailing{border-color:#3b71ca;box-shadow:1px 0 #3b71ca,0 -1px #3b71ca,0 1px #3b71ca}.form-outline .form-control:disabled,.form-outline .form-control.disabled,.form-outline .form-control[readonly]{background-color:#e9ecef}.form-outline .form-control.form-control-lg{font-size:1rem;line-height:2.15}.form-outline .form-control.form-control-lg~.form-label{padding-top:.7rem}.form-outline .form-control.form-control-lg:focus~.form-label,.form-outline .form-control.form-control-lg.active~.form-label{transform:translateY(-1.25rem) translateY(.1rem) scale(.8)}.form-outline .form-control.form-control-sm{padding-top:.32rem;padding-bottom:.32rem;font-size:.775rem;line-height:1.5}.form-outline .form-control.form-control-sm~.form-label{padding-top:.33rem;font-size:.775rem}.form-outline .form-control.form-control-sm:focus~.form-label,.form-outline .form-control.form-control-sm.active~.form-label{transform:translateY(-.85rem) translateY(.1rem) scale(.8)}.form-outline.form-white .form-control{color:#fff}.form-outline.form-white .form-control~.form-label{color:#fbfbfb}.form-outline.form-white .form-control~.form-notch div{border-color:#fbfbfb}.form-outline.form-white .form-control:focus~.form-label{color:#fff}.form-outline.form-white .form-control:focus~.form-notch .form-notch-middle{border-color:#fff;box-shadow:0 1px #fff;border-top:1px solid rgba(0,0,0,0)}.form-outline.form-white .form-control:focus~.form-notch .form-notch-leading{border-color:#fff;box-shadow:-1px 0 #fff,0 1px #fff,0 -1px #fff}.form-outline.form-white .form-control:focus~.form-notch .form-notch-trailing{border-color:#fff;box-shadow:1px 0 #fff,0 -1px #fff,0 1px #fff}.form-outline.form-white .form-control::placeholder{color:#ffffffb3}.form-outline.form-white .form-control:disabled,.form-outline.form-white .form-control.disabled,.form-outline.form-white .form-control[readonly]{background-color:#ffffff73}.select-input.form-control[readonly]:not([disabled]){background-color:#0000}.form-select{transition:all .2s linear}.form-select:focus{border-color:#3b71ca;outline:0;box-shadow:inset 0 0 0 1px #3b71ca}.form-check{min-height:1.5rem}.form-check-input{position:relative;width:1.125rem;height:1.125rem;background-color:#fff;border:.125rem solid rgba(0,0,0,.25)}.form-check-input:before{content:"";position:absolute;box-shadow:0 0 0 13px #0000;border-radius:50%;width:.875rem;height:.875rem;background-color:#0000;opacity:0;pointer-events:none;transform:scale(0)}.form-check-input:hover{cursor:pointer}.form-check-input:hover:before{opacity:.04;box-shadow:0 0 0 13px #0009}.form-check-input:focus{box-shadow:none;border-color:#00000040;transition:border-color .2s}.form-check-input:focus:before{opacity:.12;box-shadow:0 0 0 13px #0009;transform:scale(1);transition:box-shadow .2s,transform .2s}.form-check-input:checked{border-color:#3b71ca}.form-check-input:checked:before{opacity:.16}.form-check-input:checked:after{content:"";position:absolute}.form-check-input:checked:focus{border-color:#3b71ca}.form-check-input:checked:focus:before{box-shadow:0 0 0 13px #3b71ca;transform:scale(1);transition:box-shadow .2s,transform .2s}.form-check-input:indeterminate:focus:before{box-shadow:0 0 0 13px #3b71ca}.form-check-input[type=checkbox]{border-radius:.25rem;margin-top:.19em;margin-right:6px}.form-check-input[type=checkbox]:focus:after{content:"";position:absolute;width:.875rem;height:.875rem;z-index:1;display:block;border-radius:0;background-color:#fff}.form-check-input[type=checkbox]:checked{background-image:none;background-color:#3b71ca}.form-check-input[type=checkbox]:checked:after{display:block;transform:rotate(45deg);border-width:.125rem;border-color:#fff;width:.375rem;height:.8125rem;border-style:solid;border-top:0;border-left:0;margin-left:.25rem;margin-top:-1px;background-color:#0000}.form-check-input[type=checkbox]:checked:focus{background-color:#3b71ca}.form-check-input[type=checkbox]:indeterminate{border-color:#3b71ca}.form-check-input[type=radio]{border-radius:50%;width:1.25rem;height:1.25rem;margin-top:.125em;margin-right:4px}.form-check-input[type=radio]:before{width:1rem;height:1rem}.form-check-input[type=radio]:after{content:"";position:absolute;width:1rem;height:1rem;z-index:1;display:block;border-radius:50%;background-color:#fff}.form-check-input[type=radio]:checked{background-image:none;background-color:#fff}.form-check-input[type=radio]:checked:after{border-radius:50%;width:.625rem;height:.625rem;border-color:#3b71ca;background-color:#3b71ca;transition:border-color;transform:translate(-50%,-50%);position:absolute;left:50%;top:50%}.form-check-input[type=radio]:checked:focus{background-color:#fff}.form-check-label:hover{cursor:pointer}.form-switch .form-check-input{background-image:none;border-width:0;border-radius:.4375rem;width:2rem;height:.875rem;background-color:#00000040;margin-top:.3em;margin-right:8px}.form-switch .form-check-input:after{content:"";position:absolute;border:none;z-index:2;border-radius:50%;width:1.25rem;height:1.25rem;background-color:#fff;margin-top:-.1875rem;box-shadow:0 0 3px #00000012,0 2px 2px #0000000a;transition:background-color .2s,transform .2s}.form-switch .form-check-input:focus{background-image:none}.form-switch .form-check-input:focus:before{box-shadow:3px -1px 0 13px #0009;transform:scale(1);transition:box-shadow .2s,transform .2s}.form-switch .form-check-input:focus:after{border-radius:50%;width:1.25rem;height:1.25rem}.form-switch .form-check-input:checked{background-image:none}.form-switch .form-check-input:checked:focus{background-image:none}.form-switch .form-check-input:checked:focus:before{margin-left:1.0625rem;box-shadow:3px -1px 0 13px #3b71ca;transform:scale(1);transition:box-shadow .2s,transform .2s}.form-switch .form-check-input:checked[type=checkbox]{background-image:none}.form-switch .form-check-input:checked[type=checkbox]:after{content:"";position:absolute;border:none;z-index:2;border-radius:50%;width:1.25rem;height:1.25rem;background-color:#3b71ca;margin-top:-3px;margin-left:1.0625rem;box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f;transition:background-color .2s,transform .2s}.form-control[type=file]::-webkit-file-upload-button{background-color:#0000}.form-control:hover:not(:disabled):not([readonly])::-webkit-file-upload-button{background-color:#0000}.input-group{flex-wrap:nowrap}.input-group>.form-control{min-height:calc(2.08rem + 2px);height:calc(2.08rem + 2px);padding-top:.27rem;padding-bottom:.27rem;transition:all .2s linear}.input-group>.form-control:focus{transition:all .2s linear;border-color:#3b71ca;outline:0;box-shadow:inset 0 0 0 1px #3b71ca}.input-group-text{background-color:#0000;padding-top:.26rem;padding-bottom:.26rem}.input-group-text>.form-check-input[type=checkbox]{margin-left:1px;margin-right:1px}.input-group-text>.form-check-input[type=radio]{margin-right:0}.input-group-lg>.form-control{height:calc(2.645rem + 2px);font-size:1rem;padding-top:.33rem;padding-bottom:.33rem}.input-group-lg .input-group-text{font-size:1rem}.input-group-sm>.form-control{min-height:calc(1.66rem + 2px);height:calc(1.66rem + 2px);font-size:.775rem;padding-top:.33rem;padding-bottom:.33rem}.input-group-sm .input-group-text{font-size:.775rem;line-height:1.5}.input-group.form-outline .input-group-text{border-left:0}.input-group.form-outline input+.input-group-text{border:0;border-left:1px solid #bdbdbd}.input-group .form-outline:not(:first-child),.input-group .select-wrapper:not(:first-child),.input-group .form-outline:not(:first-child) .form-notch-leading,.input-group .select-wrapper:not(:first-child) .form-notch-leading{border-top-left-radius:0!important;border-bottom-left-radius:0!important}.input-group .form-outline:not(:last-child),.input-group .select-wrapper:not(:last-child),.input-group .form-outline:not(:last-child) .form-notch-trailing,.input-group .select-wrapper:not(:last-child) .form-notch-trailing{border-top-right-radius:0!important;border-bottom-right-radius:0!important}.input-group>[class*=btn-outline-]+[class*=btn-outline-]{border-left:0}.input-group>.btn[class*=btn-outline-]{padding-top:.47rem}.input-group>.btn{padding-top:.59rem}.input-group.input-group-lg .input-group-text{height:calc(2.645rem + 2px)}.input-group .input-group-text{height:calc(2.08rem + 2px)}.input-group .btn{line-height:1}.input-group.input-group-sm .input-group-text{height:calc(1.66rem + 2px)}.was-validated .input-group .invalid-feedback,.was-validated .input-group .valid-feedback,.input-group .invalid-feedback,.input-group .valid-feedback{margin-top:2.5rem}.valid-feedback{position:absolute;display:none;width:auto;margin-top:.25rem;font-size:.875rem;color:#14a44d;margin-top:-.75rem}.valid-tooltip{position:absolute;top:100%;z-index:5;display:none;max-width:100%;padding:6px 16px;margin-top:.1rem;font-size:.875rem;background-color:#14a44de6;border-radius:.25rem!important;color:#fff}.was-validated :valid~.valid-feedback,.was-validated :valid~.valid-tooltip,.is-valid~.valid-feedback,.is-valid~.valid-tooltip{display:block}.was-validated .form-control:valid,.form-control.is-valid{margin-bottom:1rem;background-image:none;border-color:#14a44d}.was-validated .form-control:valid:focus,.form-control.is-valid:focus{border-color:#14a44d;box-shadow:0 0 0 .25rem #14a44d40}.was-validated .form-outline .form-control:valid~.form-label,.form-outline .form-control.is-valid~.form-label{color:#14a44d}.was-validated .form-outline .form-control:valid~.form-notch .form-notch-leading,.was-validated .form-outline .form-control:valid~.form-notch .form-notch-middle,.was-validated .form-outline .form-control:valid~.form-notch .form-notch-trailing,.form-outline .form-control.is-valid~.form-notch .form-notch-leading,.form-outline .form-control.is-valid~.form-notch .form-notch-middle,.form-outline .form-control.is-valid~.form-notch .form-notch-trailing{border-color:#14a44d}.was-validated .form-outline .form-control:valid:focus~.form-notch .form-notch-middle,.was-validated .form-outline .form-control:valid.active~.form-notch .form-notch-middle,.form-outline .form-control.is-valid:focus~.form-notch .form-notch-middle,.form-outline .form-control.is-valid.active~.form-notch .form-notch-middle{border-top:1px solid rgba(0,0,0,0)}.was-validated .form-outline .form-control:valid:focus~.form-notch .form-notch-middle,.form-outline .form-control.is-valid:focus~.form-notch .form-notch-middle{box-shadow:0 1px #14a44d}.was-validated .form-outline .form-control:valid:focus~.form-notch .form-notch-leading,.form-outline .form-control.is-valid:focus~.form-notch .form-notch-leading{box-shadow:-1px 0 #14a44d,0 1px #14a44d,0 -1px #14a44d}.was-validated .form-outline .form-control:valid:focus~.form-notch .form-notch-trailing,.form-outline .form-control.is-valid:focus~.form-notch .form-notch-trailing{box-shadow:1px 0 #14a44d,0 -1px #14a44d,0 1px #14a44d}.was-validated .form-outline .form-control:valid.select-input.focused~.form-notch .form-notch-leading,.form-outline .form-control.is-valid.select-input.focused~.form-notch .form-notch-leading{box-shadow:-1px 0 #14a44d,0 1px #14a44d,0 -1px #14a44d}.was-validated .form-outline .form-control:valid.select-input.focused~.form-notch .form-notch-middle,.form-outline .form-control.is-valid.select-input.focused~.form-notch .form-notch-middle{box-shadow:0 1px #14a44d;border-top:1px solid rgba(0,0,0,0)}.was-validated .form-outline .form-control:valid.select-input.focused~.form-notch .form-notch-trailing,.form-outline .form-control.is-valid.select-input.focused~.form-notch .form-notch-trailing{box-shadow:1px 0 #14a44d,0 -1px #14a44d,0 1px #14a44d}.was-validated .form-select:valid,.form-select.is-valid{border-color:#14a44d}.was-validated .form-select:valid:focus,.form-select.is-valid:focus{border-color:#14a44d;box-shadow:0 0 0 .25rem #14a44d40}.was-validated .form-select:valid~.valid-feedback,.form-select.is-valid~.valid-feedback{margin-top:0}.was-validated .input-group .form-control:valid,.input-group .form-control.is-valid{margin-bottom:0}.was-validated input[type=file].form-control:valid .valid-feedback,input[type=file].form-control.is-valid .valid-feedback{margin-top:0}.was-validated input[type=file].form-control:valid:focus,input[type=file].form-control.is-valid:focus{box-shadow:inset 0 0 0 1px #14a44d;border-color:#14a44d}.was-validated input[type=file].form-control:valid:focus~.form-file-label,input[type=file].form-control.is-valid:focus~.form-file-label{box-shadow:none}.was-validated input[type=file].form-control:valid:focus-within~.form-file-label .form-file-text,.was-validated input[type=file].form-control:valid:focus-within~.form-file-label .form-file-button,input[type=file].form-control.is-valid:focus-within~.form-file-label .form-file-text,input[type=file].form-control.is-valid:focus-within~.form-file-label .form-file-button{border-color:#14a44d}.was-validated .form-check-input:valid,.form-check-input.is-valid{border-color:#14a44d}.was-validated .form-check-input:valid:checked,.form-check-input.is-valid:checked{background-color:#14a44d}.was-validated .form-check-input:valid:checked:focus:before,.form-check-input.is-valid:checked:focus:before{box-shadow:0 0 0 13px #14a44d}.was-validated .form-check-input:valid:focus,.form-check-input.is-valid:focus{box-shadow:none}.was-validated .form-check-input:valid:focus:before,.form-check-input.is-valid:focus:before{box-shadow:0 0 0 13px #14a44d}.was-validated .form-check-input:valid~.form-check-label,.form-check-input.is-valid~.form-check-label{color:#14a44d;margin-bottom:1rem}.was-validated .form-check-input:valid[type=checkbox]:checked:focus,.form-check-input.is-valid[type=checkbox]:checked:focus{background-color:#14a44d;border-color:#14a44d}.was-validated .form-check-input:valid[type=radio]:checked,.form-check-input.is-valid[type=radio]:checked{border-color:#14a44d;background-color:#fff}.was-validated .form-check-input:valid[type=radio]:checked:focus:before,.form-check-input.is-valid[type=radio]:checked:focus:before{box-shadow:0 0 0 13px #14a44d}.was-validated .form-check-input:valid[type=radio]:checked:after,.form-check-input.is-valid[type=radio]:checked:after{border-color:#14a44d;background-color:#14a44d}.form-check-inline .form-check-input~.valid-feedback{margin-left:.5em}.was-validated .form-switch .form-check-input:valid:focus:before,.form-switch .form-check-input.is-valid:focus:before{box-shadow:3px -1px 0 13px #0009}.was-validated .form-switch .form-check-input:valid:checked[type=checkbox]:after,.form-switch .form-check-input.is-valid:checked[type=checkbox]:after{background-color:#14a44d;box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f}.was-validated .form-switch .form-check-input:valid:checked:focus:before,.form-switch .form-check-input.is-valid:checked:focus:before{box-shadow:3px -1px 0 13px #14a44d}.invalid-feedback{position:absolute;display:none;width:auto;margin-top:.25rem;font-size:.875rem;color:#dc4c64;margin-top:-.75rem}.invalid-tooltip{position:absolute;top:100%;z-index:5;display:none;max-width:100%;padding:6px 16px;margin-top:.1rem;font-size:.875rem;background-color:#dc4c64e6;border-radius:.25rem!important;color:#fff}.was-validated :invalid~.invalid-feedback,.was-validated :invalid~.invalid-tooltip,.is-invalid~.invalid-feedback,.is-invalid~.invalid-tooltip{display:block}.was-validated .form-control:invalid,.form-control.is-invalid{margin-bottom:1rem;background-image:none;border-color:#dc4c64}.was-validated .form-control:invalid:focus,.form-control.is-invalid:focus{border-color:#dc4c64;box-shadow:0 0 0 .25rem #dc4c6440}.was-validated .form-outline .form-control:invalid~.form-label,.form-outline .form-control.is-invalid~.form-label{color:#dc4c64}.was-validated .form-outline .form-control:invalid~.form-notch .form-notch-leading,.was-validated .form-outline .form-control:invalid~.form-notch .form-notch-middle,.was-validated .form-outline .form-control:invalid~.form-notch .form-notch-trailing,.form-outline .form-control.is-invalid~.form-notch .form-notch-leading,.form-outline .form-control.is-invalid~.form-notch .form-notch-middle,.form-outline .form-control.is-invalid~.form-notch .form-notch-trailing{border-color:#dc4c64}.was-validated .form-outline .form-control:invalid:focus~.form-notch .form-notch-middle,.was-validated .form-outline .form-control:invalid.active~.form-notch .form-notch-middle,.form-outline .form-control.is-invalid:focus~.form-notch .form-notch-middle,.form-outline .form-control.is-invalid.active~.form-notch .form-notch-middle{border-top:1px solid rgba(0,0,0,0)}.was-validated .form-outline .form-control:invalid:focus~.form-notch .form-notch-middle,.form-outline .form-control.is-invalid:focus~.form-notch .form-notch-middle{box-shadow:0 1px #dc4c64}.was-validated .form-outline .form-control:invalid:focus~.form-notch .form-notch-leading,.form-outline .form-control.is-invalid:focus~.form-notch .form-notch-leading{box-shadow:-1px 0 #dc4c64,0 1px #dc4c64,0 -1px #dc4c64}.was-validated .form-outline .form-control:invalid:focus~.form-notch .form-notch-trailing,.form-outline .form-control.is-invalid:focus~.form-notch .form-notch-trailing{box-shadow:1px 0 #dc4c64,0 -1px #dc4c64,0 1px #dc4c64}.was-validated .form-outline .form-control:invalid.select-input.focused~.form-notch .form-notch-leading,.form-outline .form-control.is-invalid.select-input.focused~.form-notch .form-notch-leading{box-shadow:-1px 0 #dc4c64,0 1px #dc4c64,0 -1px #dc4c64}.was-validated .form-outline .form-control:invalid.select-input.focused~.form-notch .form-notch-middle,.form-outline .form-control.is-invalid.select-input.focused~.form-notch .form-notch-middle{box-shadow:0 1px #dc4c64;border-top:1px solid rgba(0,0,0,0)}.was-validated .form-outline .form-control:invalid.select-input.focused~.form-notch .form-notch-trailing,.form-outline .form-control.is-invalid.select-input.focused~.form-notch .form-notch-trailing{box-shadow:1px 0 #dc4c64,0 -1px #dc4c64,0 1px #dc4c64}.was-validated .form-select:invalid,.form-select.is-invalid{border-color:#dc4c64}.was-validated .form-select:invalid:focus,.form-select.is-invalid:focus{border-color:#dc4c64;box-shadow:0 0 0 .25rem #dc4c6440}.was-validated .form-select:invalid~.invalid-feedback,.form-select.is-invalid~.invalid-feedback{margin-top:0}.was-validated .input-group .form-control:invalid,.input-group .form-control.is-invalid{margin-bottom:0}.was-validated input[type=file].form-control:invalid .invalid-feedback,input[type=file].form-control.is-invalid .invalid-feedback{margin-top:0}.was-validated input[type=file].form-control:invalid:focus,input[type=file].form-control.is-invalid:focus{box-shadow:inset 0 0 0 1px #dc4c64;border-color:#dc4c64}.was-validated input[type=file].form-control:invalid:focus~.form-file-label,input[type=file].form-control.is-invalid:focus~.form-file-label{box-shadow:none}.was-validated input[type=file].form-control:invalid:focus-within~.form-file-label .form-file-text,.was-validated input[type=file].form-control:invalid:focus-within~.form-file-label .form-file-button,input[type=file].form-control.is-invalid:focus-within~.form-file-label .form-file-text,input[type=file].form-control.is-invalid:focus-within~.form-file-label .form-file-button{border-color:#dc4c64}.was-validated .form-check-input:invalid,.form-check-input.is-invalid{border-color:#dc4c64}.was-validated .form-check-input:invalid:checked,.form-check-input.is-invalid:checked{background-color:#dc4c64}.was-validated .form-check-input:invalid:checked:focus:before,.form-check-input.is-invalid:checked:focus:before{box-shadow:0 0 0 13px #dc4c64}.was-validated .form-check-input:invalid:focus,.form-check-input.is-invalid:focus{box-shadow:none}.was-validated .form-check-input:invalid:focus:before,.form-check-input.is-invalid:focus:before{box-shadow:0 0 0 13px #dc4c64}.was-validated .form-check-input:invalid~.form-check-label,.form-check-input.is-invalid~.form-check-label{color:#dc4c64;margin-bottom:1rem}.was-validated .form-check-input:invalid[type=checkbox]:checked:focus,.form-check-input.is-invalid[type=checkbox]:checked:focus{background-color:#dc4c64;border-color:#dc4c64}.was-validated .form-check-input:invalid[type=radio]:checked,.form-check-input.is-invalid[type=radio]:checked{border-color:#dc4c64;background-color:#fff}.was-validated .form-check-input:invalid[type=radio]:checked:focus:before,.form-check-input.is-invalid[type=radio]:checked:focus:before{box-shadow:0 0 0 13px #dc4c64}.was-validated .form-check-input:invalid[type=radio]:checked:after,.form-check-input.is-invalid[type=radio]:checked:after{border-color:#dc4c64;background-color:#dc4c64}.form-check-inline .form-check-input~.invalid-feedback{margin-left:.5em}.was-validated .form-switch .form-check-input:invalid:focus:before,.form-switch .form-check-input.is-invalid:focus:before{box-shadow:3px -1px 0 13px #0009}.was-validated .form-switch .form-check-input:invalid:checked[type=checkbox]:after,.form-switch .form-check-input.is-invalid:checked[type=checkbox]:after{background-color:#dc4c64;box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f}.was-validated .form-switch .form-check-input:invalid:checked:focus:before,.form-switch .form-check-input.is-invalid:checked:focus:before{box-shadow:3px -1px 0 13px #dc4c64}.form-range:focus{box-shadow:none}.form-range:focus::-webkit-slider-thumb{box-shadow:none}.form-range:focus::-moz-range-thumb{box-shadow:none}.form-range:focus::-ms-thumb{box-shadow:none}.form-range::-moz-focus-outer{border:0}.form-range::-webkit-slider-thumb{margin-top:-6px;box-shadow:none;-webkit-appearance:none;-moz-appearance:none;appearance:none}.form-range::-webkit-slider-runnable-track{height:4px;border-radius:0;box-shadow:none}.form-range::-moz-range-thumb{box-shadow:none;-webkit-appearance:none;-moz-appearance:none;appearance:none}.form-range::-moz-range-track{box-shadow:none}.table{--mdb-table-font-size: .9rem;--mdb-table-divider-color: rgba(0, 0, 0, .1);font-size:var(--mdb-table-font-size)}.table th{font-weight:500}.table tbody{font-weight:400}.table>:not(:last-child)>:last-child>*{border-bottom-color:inherit}.table-primary{--mdb-table-color: #000;--mdb-table-bg: #d8e3f4;--mdb-table-border-color: #c2ccdc;--mdb-table-striped-bg: #cdd8e8;--mdb-table-striped-color: #000;--mdb-table-active-bg: #c2ccdc;--mdb-table-active-color: #000;--mdb-table-hover-bg: #c8d2e2;--mdb-table-hover-color: #000;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-secondary{--mdb-table-color: #000;--mdb-table-bg: #ecedf0;--mdb-table-border-color: #d4d5d8;--mdb-table-striped-bg: #e0e1e4;--mdb-table-striped-color: #000;--mdb-table-active-bg: #d4d5d8;--mdb-table-active-color: #000;--mdb-table-hover-bg: #dadbde;--mdb-table-hover-color: #000;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-success{--mdb-table-color: #000;--mdb-table-bg: #d0eddb;--mdb-table-border-color: #bbd5c5;--mdb-table-striped-bg: #c6e1d0;--mdb-table-striped-color: #000;--mdb-table-active-bg: #bbd5c5;--mdb-table-active-color: #000;--mdb-table-hover-bg: #c0dbcb;--mdb-table-hover-color: #000;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-info{--mdb-table-color: #000;--mdb-table-bg: #ddf0f6;--mdb-table-border-color: #c7d8dd;--mdb-table-striped-bg: #d2e4ea;--mdb-table-striped-color: #000;--mdb-table-active-bg: #c7d8dd;--mdb-table-active-color: #000;--mdb-table-hover-bg: #ccdee4;--mdb-table-hover-color: #000;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-warning{--mdb-table-color: #000;--mdb-table-bg: #faecd1;--mdb-table-border-color: #e1d4bc;--mdb-table-striped-bg: #eee0c7;--mdb-table-striped-color: #000;--mdb-table-active-bg: #e1d4bc;--mdb-table-active-color: #000;--mdb-table-hover-bg: #e7dac1;--mdb-table-hover-color: #000;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-danger{--mdb-table-color: #000;--mdb-table-bg: #f8dbe0;--mdb-table-border-color: #dfc5ca;--mdb-table-striped-bg: #ecd0d5;--mdb-table-striped-color: #000;--mdb-table-active-bg: #dfc5ca;--mdb-table-active-color: #000;--mdb-table-hover-bg: #e5cbcf;--mdb-table-hover-color: #000;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-light{--mdb-table-color: #000;--mdb-table-bg: #fbfbfb;--mdb-table-border-color: #e2e2e2;--mdb-table-striped-bg: #eeeeee;--mdb-table-striped-color: #000;--mdb-table-active-bg: #e2e2e2;--mdb-table-active-color: #000;--mdb-table-hover-bg: #e8e8e8;--mdb-table-hover-color: #000;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-dark{--mdb-table-color: #fff;--mdb-table-bg: #332d2d;--mdb-table-border-color: #474242;--mdb-table-striped-bg: #3d3838;--mdb-table-striped-color: #fff;--mdb-table-active-bg: #474242;--mdb-table-active-color: #fff;--mdb-table-hover-bg: #423d3d;--mdb-table-hover-color: #fff;color:var(--mdb-table-color);border-color:var(--mdb-table-border-color)}.table-hover>tbody>tr{transition:.5s}.table-hover>tbody>tr:hover{--mdb-table-accent-bg: transparent;background-color:var(--mdb-table-hover-bg)}.table-group-divider{border-top:2px solid;border-top-color:inherit}.table-divider-color{border-top-color:var(--mdb-table-divider-color)}.btn{--mdb-btn-padding-top: .625rem;--mdb-btn-padding-bottom: .5rem;--mdb-btn-border-width: 0;--mdb-btn-border-color: none;--mdb-btn-border-radius: .25rem;--mdb-btn-box-shadow: 0 4px 9px -4px rgba(0, 0, 0, .35);--mdb-btn-hover-box-shadow: 0 8px 9px -4px rgba(0, 0, 0, .15), 0 4px 18px 0 rgba(0, 0, 0, .1);--mdb-btn-focus-box-shadow: 0 8px 9px -4px rgba(0, 0, 0, .15), 0 4px 18px 0 rgba(0, 0, 0, .1);--mdb-btn-active-box-shadow: 0 8px 9px -4px rgba(0, 0, 0, .15), 0 4px 18px 0 rgba(0, 0, 0, .1);padding-top:var(--mdb-btn-padding-top);padding-bottom:var(--mdb-btn-padding-bottom);text-transform:uppercase;vertical-align:bottom;border:0;border-radius:var(--mdb-btn-border-radius);box-shadow:var(--mdb-btn-box-shadow)}:not(.btn-check)+.btn:hover,.btn:first-child:hover,.btn:focus-visible,.btn:hover{box-shadow:var(--mdb-btn-hover-box-shadow)}.btn-check:focus-visible+.btn,.btn-check:focus+.btn,.btn:focus{box-shadow:var(--mdb-btn-focus-box-shadow)}.btn-check:checked+.btn,.btn-check:active+.btn,.btn:active,.btn.active,.btn.show{box-shadow:var(--mdb-btn-active-box-shadow)}.btn-check:checked+.btn:focus,.btn-check:active+.btn:focus,.btn:active:focus,.btn.active:focus,.btn.show:focus{box-shadow:var(--mdb-btn-focus-box-shadow)}.btn:disabled,.btn.disabled,fieldset:disabled .btn{box-shadow:var(--mdb-btn-box-shadow)}[class*=btn-outline-]{--mdb-btn-padding-top: .5rem;--mdb-btn-padding-bottom: .375rem;--mdb-btn-padding-x: 1.375rem;--mdb-btn-border-width: 2px;--mdb-btn-line-height: 1.5;padding:var(--mdb-btn-padding-top) var(--mdb-btn-padding-x) var(--mdb-btn-padding-bottom);border-width:var(--mdb-btn-border-width);border-style:solid;box-shadow:none}:not(.btn-check)+[class*=btn-outline-]:hover,[class*=btn-outline-]:first-child:hover,[class*=btn-outline-]:focus-visible,[class*=btn-outline-]:hover{box-shadow:none}.btn-check:focus-visible+[class*=btn-outline-],.btn-check:focus+[class*=btn-outline-],[class*=btn-outline-]:focus{box-shadow:none}.btn-check:checked+[class*=btn-outline-],.btn-check:active+[class*=btn-outline-],[class*=btn-outline-]:active,[class*=btn-outline-].active,[class*=btn-outline-].show{box-shadow:none}.btn-check:checked+[class*=btn-outline-]:focus,.btn-check:active+[class*=btn-outline-]:focus,[class*=btn-outline-]:active:focus,[class*=btn-outline-].active:focus,[class*=btn-outline-].show:focus{box-shadow:none}[class*=btn-outline-]:disabled,[class*=btn-outline-].disabled,fieldset:disabled [class*=btn-outline-]{box-shadow:none}[class*=btn-outline-].btn-lg,.btn-group-lg>[class*=btn-outline-].btn{--mdb-btn-padding-top: .625rem;--mdb-btn-padding-bottom: .5625rem;--mdb-btn-padding-x: 1.5625rem;--mdb-btn-font-size:.875rem;--mdb-btn-line-height: 1.6}[class*=btn-outline-].btn-sm,.btn-group-sm>[class*=btn-outline-].btn{--mdb-btn-padding-top: .25rem;--mdb-btn-padding-bottom: .1875rem;--mdb-btn-padding-x: .875rem;--mdb-btn-font-size:.75rem;--mdb-btn-line-height: 1.5}.btn-secondary{box-shadow:none}:not(.btn-check)+.btn-secondary:hover,.btn-secondary:first-child:hover,.btn-secondary:focus-visible,.btn-secondary:hover{box-shadow:none!important}.btn-check:focus-visible+.btn-secondary,.btn-check:focus+.btn-secondary,.btn-secondary:focus{box-shadow:none}.btn-check:checked+.btn-secondary,.btn-check:active+.btn-secondary,.btn-secondary:active,.btn-secondary.active,.btn-secondary.show{box-shadow:none}.btn-check:checked+.btn-secondary:focus,.btn-check:active+.btn-secondary:focus,.btn-secondary:active:focus,.btn-secondary.active:focus,.btn-secondary.show:focus{box-shadow:none}.btn-secondary:disabled,.btn-secondary.disabled,fieldset:disabled .btn-secondary{box-shadow:none}.btn-primary{--mdb-btn-bg: #3b71ca;--mdb-btn-color: #fff;--mdb-btn-box-shadow: 0 4px 9px -4px #3b71ca;--mdb-btn-hover-bg: #386bc0;--mdb-btn-hover-color: #fff;--mdb-btn-focus-bg: #386bc0;--mdb-btn-focus-color: #fff;--mdb-btn-active-bg: #3566b6;--mdb-btn-active-color: #fff}:not(.btn-check)+.btn-primary:hover,.btn-primary:first-child:hover,.btn-primary:focus-visible,.btn-primary:hover{box-shadow:0 8px 9px -4px #3b71ca4d,0 4px 18px #3b71ca33}.btn-check:focus-visible+.btn-primary,.btn-check:focus+.btn-primary,.btn-primary:focus{box-shadow:0 8px 9px -4px #3b71ca4d,0 4px 18px #3b71ca33;background-color:#386bc0}.btn-check:checked+.btn-primary,.btn-check:active+.btn-primary,.btn-primary:active,.btn-primary.active,.btn-primary.show{box-shadow:0 8px 9px -4px #3b71ca4d,0 4px 18px #3b71ca33}.btn-check:checked+.btn-primary:focus,.btn-check:active+.btn-primary:focus,.btn-primary:active:focus,.btn-primary.active:focus,.btn-primary.show:focus{box-shadow:0 8px 9px -4px #3b71ca4d,0 4px 18px #3b71ca33}.btn-check:checked+.btn-primary:hover,.btn-check:active+.btn-primary:hover,.btn-primary:active:hover,.btn-primary.active:hover,.btn-primary.show:hover{background-color:#3566b6}.btn-primary:disabled,.btn-primary.disabled,fieldset:disabled .btn-primary{box-shadow:0 4px 9px -4px #3b71ca}.btn-secondary{--mdb-btn-bg: #e3ebf7;--mdb-btn-color: #285192;--mdb-btn-box-shadow: 0 4px 9px -4px #e3ebf7;--mdb-btn-hover-bg: #d8dfeb;--mdb-btn-hover-color: #285192;--mdb-btn-focus-bg: #d8dfeb;--mdb-btn-focus-color: #285192;--mdb-btn-active-bg: #ccd4de;--mdb-btn-active-color: #285192}:not(.btn-check)+.btn-secondary:hover,.btn-secondary:first-child:hover,.btn-secondary:focus-visible,.btn-secondary:hover{box-shadow:0 8px 9px -4px #e3ebf74d,0 4px 18px #e3ebf733}.btn-check:focus-visible+.btn-secondary,.btn-check:focus+.btn-secondary,.btn-secondary:focus{box-shadow:0 8px 9px -4px #e3ebf74d,0 4px 18px #e3ebf733;background-color:#d8dfeb}.btn-check:checked+.btn-secondary,.btn-check:active+.btn-secondary,.btn-secondary:active,.btn-secondary.active,.btn-secondary.show{box-shadow:0 8px 9px -4px #e3ebf74d,0 4px 18px #e3ebf733}.btn-check:checked+.btn-secondary:focus,.btn-check:active+.btn-secondary:focus,.btn-secondary:active:focus,.btn-secondary.active:focus,.btn-secondary.show:focus{box-shadow:0 8px 9px -4px #e3ebf74d,0 4px 18px #e3ebf733}.btn-check:checked+.btn-secondary:hover,.btn-check:active+.btn-secondary:hover,.btn-secondary:active:hover,.btn-secondary.active:hover,.btn-secondary.show:hover{background-color:#ccd4de}.btn-secondary:disabled,.btn-secondary.disabled,fieldset:disabled .btn-secondary{box-shadow:0 4px 9px -4px #e3ebf7}.btn-success{--mdb-btn-bg: #14a44d;--mdb-btn-color: #fff;--mdb-btn-box-shadow: 0 4px 9px -4px #14a44d;--mdb-btn-hover-bg: #139c49;--mdb-btn-hover-color: #fff;--mdb-btn-focus-bg: #139c49;--mdb-btn-focus-color: #fff;--mdb-btn-active-bg: #129445;--mdb-btn-active-color: #fff}:not(.btn-check)+.btn-success:hover,.btn-success:first-child:hover,.btn-success:focus-visible,.btn-success:hover{box-shadow:0 8px 9px -4px #14a44d4d,0 4px 18px #14a44d33}.btn-check:focus-visible+.btn-success,.btn-check:focus+.btn-success,.btn-success:focus{box-shadow:0 8px 9px -4px #14a44d4d,0 4px 18px #14a44d33;background-color:#139c49}.btn-check:checked+.btn-success,.btn-check:active+.btn-success,.btn-success:active,.btn-success.active,.btn-success.show{box-shadow:0 8px 9px -4px #14a44d4d,0 4px 18px #14a44d33}.btn-check:checked+.btn-success:focus,.btn-check:active+.btn-success:focus,.btn-success:active:focus,.btn-success.active:focus,.btn-success.show:focus{box-shadow:0 8px 9px -4px #14a44d4d,0 4px 18px #14a44d33}.btn-check:checked+.btn-success:hover,.btn-check:active+.btn-success:hover,.btn-success:active:hover,.btn-success.active:hover,.btn-success.show:hover{background-color:#129445}.btn-success:disabled,.btn-success.disabled,fieldset:disabled .btn-success{box-shadow:0 4px 9px -4px #14a44d}.btn-danger{--mdb-btn-bg: #dc4c64;--mdb-btn-color: #fff;--mdb-btn-box-shadow: 0 4px 9px -4px #dc4c64;--mdb-btn-hover-bg: #d1485f;--mdb-btn-hover-color: #fff;--mdb-btn-focus-bg: #d1485f;--mdb-btn-focus-color: #fff;--mdb-btn-active-bg: #c6445a;--mdb-btn-active-color: #fff}:not(.btn-check)+.btn-danger:hover,.btn-danger:first-child:hover,.btn-danger:focus-visible,.btn-danger:hover{box-shadow:0 8px 9px -4px #dc4c644d,0 4px 18px #dc4c6433}.btn-check:focus-visible+.btn-danger,.btn-check:focus+.btn-danger,.btn-danger:focus{box-shadow:0 8px 9px -4px #dc4c644d,0 4px 18px #dc4c6433;background-color:#d1485f}.btn-check:checked+.btn-danger,.btn-check:active+.btn-danger,.btn-danger:active,.btn-danger.active,.btn-danger.show{box-shadow:0 8px 9px -4px #dc4c644d,0 4px 18px #dc4c6433}.btn-check:checked+.btn-danger:focus,.btn-check:active+.btn-danger:focus,.btn-danger:active:focus,.btn-danger.active:focus,.btn-danger.show:focus{box-shadow:0 8px 9px -4px #dc4c644d,0 4px 18px #dc4c6433}.btn-check:checked+.btn-danger:hover,.btn-check:active+.btn-danger:hover,.btn-danger:active:hover,.btn-danger.active:hover,.btn-danger.show:hover{background-color:#c6445a}.btn-danger:disabled,.btn-danger.disabled,fieldset:disabled .btn-danger{box-shadow:0 4px 9px -4px #dc4c64}.btn-warning{--mdb-btn-bg: #e4a11b;--mdb-btn-color: #fff;--mdb-btn-box-shadow: 0 4px 9px -4px #e4a11b;--mdb-btn-hover-bg: #d9991a;--mdb-btn-hover-color: #fff;--mdb-btn-focus-bg: #d9991a;--mdb-btn-focus-color: #fff;--mdb-btn-active-bg: #cd9118;--mdb-btn-active-color: #fff}:not(.btn-check)+.btn-warning:hover,.btn-warning:first-child:hover,.btn-warning:focus-visible,.btn-warning:hover{box-shadow:0 8px 9px -4px #e4a11b4d,0 4px 18px #e4a11b33}.btn-check:focus-visible+.btn-warning,.btn-check:focus+.btn-warning,.btn-warning:focus{box-shadow:0 8px 9px -4px #e4a11b4d,0 4px 18px #e4a11b33;background-color:#d9991a}.btn-check:checked+.btn-warning,.btn-check:active+.btn-warning,.btn-warning:active,.btn-warning.active,.btn-warning.show{box-shadow:0 8px 9px -4px #e4a11b4d,0 4px 18px #e4a11b33}.btn-check:checked+.btn-warning:focus,.btn-check:active+.btn-warning:focus,.btn-warning:active:focus,.btn-warning.active:focus,.btn-warning.show:focus{box-shadow:0 8px 9px -4px #e4a11b4d,0 4px 18px #e4a11b33}.btn-check:checked+.btn-warning:hover,.btn-check:active+.btn-warning:hover,.btn-warning:active:hover,.btn-warning.active:hover,.btn-warning.show:hover{background-color:#cd9118}.btn-warning:disabled,.btn-warning.disabled,fieldset:disabled .btn-warning{box-shadow:0 4px 9px -4px #e4a11b}.btn-info{--mdb-btn-bg: #54b4d3;--mdb-btn-color: #fff;--mdb-btn-box-shadow: 0 4px 9px -4px #54b4d3;--mdb-btn-hover-bg: #50abc8;--mdb-btn-hover-color: #fff;--mdb-btn-focus-bg: #50abc8;--mdb-btn-focus-color: #fff;--mdb-btn-active-bg: #4ca2be;--mdb-btn-active-color: #fff}:not(.btn-check)+.btn-info:hover,.btn-info:first-child:hover,.btn-info:focus-visible,.btn-info:hover{box-shadow:0 8px 9px -4px #54b4d34d,0 4px 18px #54b4d333}.btn-check:focus-visible+.btn-info,.btn-check:focus+.btn-info,.btn-info:focus{box-shadow:0 8px 9px -4px #54b4d34d,0 4px 18px #54b4d333;background-color:#50abc8}.btn-check:checked+.btn-info,.btn-check:active+.btn-info,.btn-info:active,.btn-info.active,.btn-info.show{box-shadow:0 8px 9px -4px #54b4d34d,0 4px 18px #54b4d333}.btn-check:checked+.btn-info:focus,.btn-check:active+.btn-info:focus,.btn-info:active:focus,.btn-info.active:focus,.btn-info.show:focus{box-shadow:0 8px 9px -4px #54b4d34d,0 4px 18px #54b4d333}.btn-check:checked+.btn-info:hover,.btn-check:active+.btn-info:hover,.btn-info:active:hover,.btn-info.active:hover,.btn-info.show:hover{background-color:#4ca2be}.btn-info:disabled,.btn-info.disabled,fieldset:disabled .btn-info{box-shadow:0 4px 9px -4px #54b4d3}.btn-light{--mdb-btn-bg: #fbfbfb;--mdb-btn-color: #4f4f4f;--mdb-btn-box-shadow: 0 4px 9px -4px #fbfbfb;--mdb-btn-hover-bg: #eeeeee;--mdb-btn-hover-color: #4f4f4f;--mdb-btn-focus-bg: #eeeeee;--mdb-btn-focus-color: #4f4f4f;--mdb-btn-active-bg: #e2e2e2;--mdb-btn-active-color: #4f4f4f}:not(.btn-check)+.btn-light:hover,.btn-light:first-child:hover,.btn-light:focus-visible,.btn-light:hover{box-shadow:0 8px 9px -4px #fbfbfb4d,0 4px 18px #fbfbfb33}.btn-check:focus-visible+.btn-light,.btn-check:focus+.btn-light,.btn-light:focus{box-shadow:0 8px 9px -4px #fbfbfb4d,0 4px 18px #fbfbfb33;background-color:#eee}.btn-check:checked+.btn-light,.btn-check:active+.btn-light,.btn-light:active,.btn-light.active,.btn-light.show{box-shadow:0 8px 9px -4px #fbfbfb4d,0 4px 18px #fbfbfb33}.btn-check:checked+.btn-light:focus,.btn-check:active+.btn-light:focus,.btn-light:active:focus,.btn-light.active:focus,.btn-light.show:focus{box-shadow:0 8px 9px -4px #fbfbfb4d,0 4px 18px #fbfbfb33}.btn-check:checked+.btn-light:hover,.btn-check:active+.btn-light:hover,.btn-light:active:hover,.btn-light.active:hover,.btn-light.show:hover{background-color:#e2e2e2}.btn-light:disabled,.btn-light.disabled,fieldset:disabled .btn-light{box-shadow:0 4px 9px -4px #fbfbfb}.btn-dark{--mdb-btn-bg: #332d2d;--mdb-btn-color: #fff;--mdb-btn-box-shadow: 0 4px 9px -4px #332d2d;--mdb-btn-hover-bg: #302b2b;--mdb-btn-hover-color: #fff;--mdb-btn-focus-bg: #302b2b;--mdb-btn-focus-color: #fff;--mdb-btn-active-bg: #2e2929;--mdb-btn-active-color: #fff}:not(.btn-check)+.btn-dark:hover,.btn-dark:first-child:hover,.btn-dark:focus-visible,.btn-dark:hover{box-shadow:0 8px 9px -4px #332d2d4d,0 4px 18px #332d2d33}.btn-check:focus-visible+.btn-dark,.btn-check:focus+.btn-dark,.btn-dark:focus{box-shadow:0 8px 9px -4px #332d2d4d,0 4px 18px #332d2d33;background-color:#302b2b}.btn-check:checked+.btn-dark,.btn-check:active+.btn-dark,.btn-dark:active,.btn-dark.active,.btn-dark.show{box-shadow:0 8px 9px -4px #332d2d4d,0 4px 18px #332d2d33}.btn-check:checked+.btn-dark:focus,.btn-check:active+.btn-dark:focus,.btn-dark:active:focus,.btn-dark.active:focus,.btn-dark.show:focus{box-shadow:0 8px 9px -4px #332d2d4d,0 4px 18px #332d2d33}.btn-check:checked+.btn-dark:hover,.btn-check:active+.btn-dark:hover,.btn-dark:active:hover,.btn-dark.active:hover,.btn-dark.show:hover{background-color:#2e2929}.btn-dark:disabled,.btn-dark.disabled,fieldset:disabled .btn-dark{box-shadow:0 4px 9px -4px #332d2d}.btn-white{--mdb-btn-bg: #fff;--mdb-btn-color: #000;--mdb-btn-box-shadow: 0 4px 9px -4px #fff;--mdb-btn-hover-bg: #f2f2f2;--mdb-btn-hover-color: #000;--mdb-btn-focus-bg: #f2f2f2;--mdb-btn-focus-color: #000;--mdb-btn-active-bg: #e6e6e6;--mdb-btn-active-color: #000}:not(.btn-check)+.btn-white:hover,.btn-white:first-child:hover,.btn-white:focus-visible,.btn-white:hover{box-shadow:0 8px 9px -4px #ffffff4d,0 4px 18px #fff3}.btn-check:focus-visible+.btn-white,.btn-check:focus+.btn-white,.btn-white:focus{box-shadow:0 8px 9px -4px #ffffff4d,0 4px 18px #fff3;background-color:#f2f2f2}.btn-check:checked+.btn-white,.btn-check:active+.btn-white,.btn-white:active,.btn-white.active,.btn-white.show{box-shadow:0 8px 9px -4px #ffffff4d,0 4px 18px #fff3}.btn-check:checked+.btn-white:focus,.btn-check:active+.btn-white:focus,.btn-white:active:focus,.btn-white.active:focus,.btn-white.show:focus{box-shadow:0 8px 9px -4px #ffffff4d,0 4px 18px #fff3}.btn-check:checked+.btn-white:hover,.btn-check:active+.btn-white:hover,.btn-white:active:hover,.btn-white.active:hover,.btn-white.show:hover{background-color:#e6e6e6}.btn-white:disabled,.btn-white.disabled,fieldset:disabled .btn-white{box-shadow:0 4px 9px -4px #fff}.btn-black{--mdb-btn-bg: #000;--mdb-btn-color: #fff;--mdb-btn-box-shadow: 0 4px 9px -4px #000;--mdb-btn-hover-bg: black;--mdb-btn-hover-color: #fff;--mdb-btn-focus-bg: black;--mdb-btn-focus-color: #fff;--mdb-btn-active-bg: black;--mdb-btn-active-color: #fff}:not(.btn-check)+.btn-black:hover,.btn-black:first-child:hover,.btn-black:focus-visible,.btn-black:hover{box-shadow:0 8px 9px -4px #0000004d,0 4px 18px #0003}.btn-check:focus-visible+.btn-black,.btn-check:focus+.btn-black,.btn-black:focus{box-shadow:0 8px 9px -4px #0000004d,0 4px 18px #0003;background-color:#000}.btn-check:checked+.btn-black,.btn-check:active+.btn-black,.btn-black:active,.btn-black.active,.btn-black.show{box-shadow:0 8px 9px -4px #0000004d,0 4px 18px #0003}.btn-check:checked+.btn-black:focus,.btn-check:active+.btn-black:focus,.btn-black:active:focus,.btn-black.active:focus,.btn-black.show:focus{box-shadow:0 8px 9px -4px #0000004d,0 4px 18px #0003}.btn-check:checked+.btn-black:hover,.btn-check:active+.btn-black:hover,.btn-black:active:hover,.btn-black.active:hover,.btn-black.show:hover{background-color:#000}.btn-black:disabled,.btn-black.disabled,fieldset:disabled .btn-black{box-shadow:0 4px 9px -4px #000}.btn-outline-primary{--mdb-btn-bg: transparent;--mdb-btn-color: #3b71ca;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #386bc0;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #386bc0;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #3566b6;border-color:#3b71ca}:not(.btn-check)+.btn-outline-primary:hover,.btn-outline-primary:first-child:hover,.btn-outline-primary:focus-visible,.btn-outline-primary:hover{border-color:#386bc0}.btn-check:focus-visible+.btn-outline-primary,.btn-check:focus+.btn-outline-primary,.btn-outline-primary:focus{border-color:#386bc0}.btn-check:checked+.btn-outline-primary,.btn-check:active+.btn-outline-primary,.btn-outline-primary:active,.btn-outline-primary.active,.btn-outline-primary.show{border-color:#3566b6}.btn-check:checked+.btn-outline-primary:focus,.btn-check:active+.btn-outline-primary:focus,.btn-outline-primary:active:focus,.btn-outline-primary.active:focus,.btn-outline-primary.show:focus{border-color:#386bc0}.btn-outline-primary:disabled,.btn-outline-primary.disabled,fieldset:disabled .btn-outline-primary{border-color:#3b71ca}.btn-outline-secondary{--mdb-btn-bg: transparent;--mdb-btn-color: #285192;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #264d8b;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #264d8b;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #244983;border-color:#e3ebf7}:not(.btn-check)+.btn-outline-secondary:hover,.btn-outline-secondary:first-child:hover,.btn-outline-secondary:focus-visible,.btn-outline-secondary:hover{border-color:#d8dfeb}.btn-check:focus-visible+.btn-outline-secondary,.btn-check:focus+.btn-outline-secondary,.btn-outline-secondary:focus{border-color:#d8dfeb}.btn-check:checked+.btn-outline-secondary,.btn-check:active+.btn-outline-secondary,.btn-outline-secondary:active,.btn-outline-secondary.active,.btn-outline-secondary.show{border-color:#ccd4de}.btn-check:checked+.btn-outline-secondary:focus,.btn-check:active+.btn-outline-secondary:focus,.btn-outline-secondary:active:focus,.btn-outline-secondary.active:focus,.btn-outline-secondary.show:focus{border-color:#d8dfeb}.btn-outline-secondary:disabled,.btn-outline-secondary.disabled,fieldset:disabled .btn-outline-secondary{border-color:#e3ebf7}.btn-outline-success{--mdb-btn-bg: transparent;--mdb-btn-color: #14a44d;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #139c49;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #139c49;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #129445;border-color:#14a44d}:not(.btn-check)+.btn-outline-success:hover,.btn-outline-success:first-child:hover,.btn-outline-success:focus-visible,.btn-outline-success:hover{border-color:#139c49}.btn-check:focus-visible+.btn-outline-success,.btn-check:focus+.btn-outline-success,.btn-outline-success:focus{border-color:#139c49}.btn-check:checked+.btn-outline-success,.btn-check:active+.btn-outline-success,.btn-outline-success:active,.btn-outline-success.active,.btn-outline-success.show{border-color:#129445}.btn-check:checked+.btn-outline-success:focus,.btn-check:active+.btn-outline-success:focus,.btn-outline-success:active:focus,.btn-outline-success.active:focus,.btn-outline-success.show:focus{border-color:#139c49}.btn-outline-success:disabled,.btn-outline-success.disabled,fieldset:disabled .btn-outline-success{border-color:#14a44d}.btn-outline-danger{--mdb-btn-bg: transparent;--mdb-btn-color: #dc4c64;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #d1485f;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #d1485f;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #c6445a;border-color:#dc4c64}:not(.btn-check)+.btn-outline-danger:hover,.btn-outline-danger:first-child:hover,.btn-outline-danger:focus-visible,.btn-outline-danger:hover{border-color:#d1485f}.btn-check:focus-visible+.btn-outline-danger,.btn-check:focus+.btn-outline-danger,.btn-outline-danger:focus{border-color:#d1485f}.btn-check:checked+.btn-outline-danger,.btn-check:active+.btn-outline-danger,.btn-outline-danger:active,.btn-outline-danger.active,.btn-outline-danger.show{border-color:#c6445a}.btn-check:checked+.btn-outline-danger:focus,.btn-check:active+.btn-outline-danger:focus,.btn-outline-danger:active:focus,.btn-outline-danger.active:focus,.btn-outline-danger.show:focus{border-color:#d1485f}.btn-outline-danger:disabled,.btn-outline-danger.disabled,fieldset:disabled .btn-outline-danger{border-color:#dc4c64}.btn-outline-warning{--mdb-btn-bg: transparent;--mdb-btn-color: #e4a11b;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #d9991a;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #d9991a;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #cd9118;border-color:#e4a11b}:not(.btn-check)+.btn-outline-warning:hover,.btn-outline-warning:first-child:hover,.btn-outline-warning:focus-visible,.btn-outline-warning:hover{border-color:#d9991a}.btn-check:focus-visible+.btn-outline-warning,.btn-check:focus+.btn-outline-warning,.btn-outline-warning:focus{border-color:#d9991a}.btn-check:checked+.btn-outline-warning,.btn-check:active+.btn-outline-warning,.btn-outline-warning:active,.btn-outline-warning.active,.btn-outline-warning.show{border-color:#cd9118}.btn-check:checked+.btn-outline-warning:focus,.btn-check:active+.btn-outline-warning:focus,.btn-outline-warning:active:focus,.btn-outline-warning.active:focus,.btn-outline-warning.show:focus{border-color:#d9991a}.btn-outline-warning:disabled,.btn-outline-warning.disabled,fieldset:disabled .btn-outline-warning{border-color:#e4a11b}.btn-outline-info{--mdb-btn-bg: transparent;--mdb-btn-color: #54b4d3;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #50abc8;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #50abc8;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #4ca2be;border-color:#54b4d3}:not(.btn-check)+.btn-outline-info:hover,.btn-outline-info:first-child:hover,.btn-outline-info:focus-visible,.btn-outline-info:hover{border-color:#50abc8}.btn-check:focus-visible+.btn-outline-info,.btn-check:focus+.btn-outline-info,.btn-outline-info:focus{border-color:#50abc8}.btn-check:checked+.btn-outline-info,.btn-check:active+.btn-outline-info,.btn-outline-info:active,.btn-outline-info.active,.btn-outline-info.show{border-color:#4ca2be}.btn-check:checked+.btn-outline-info:focus,.btn-check:active+.btn-outline-info:focus,.btn-outline-info:active:focus,.btn-outline-info.active:focus,.btn-outline-info.show:focus{border-color:#50abc8}.btn-outline-info:disabled,.btn-outline-info.disabled,fieldset:disabled .btn-outline-info{border-color:#54b4d3}.btn-outline-light{--mdb-btn-bg: transparent;--mdb-btn-color: #fbfbfb;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #eeeeee;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #eeeeee;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #e2e2e2;border-color:#fbfbfb}:not(.btn-check)+.btn-outline-light:hover,.btn-outline-light:first-child:hover,.btn-outline-light:focus-visible,.btn-outline-light:hover{border-color:#eee}.btn-check:focus-visible+.btn-outline-light,.btn-check:focus+.btn-outline-light,.btn-outline-light:focus{border-color:#eee}.btn-check:checked+.btn-outline-light,.btn-check:active+.btn-outline-light,.btn-outline-light:active,.btn-outline-light.active,.btn-outline-light.show{border-color:#e2e2e2}.btn-check:checked+.btn-outline-light:focus,.btn-check:active+.btn-outline-light:focus,.btn-outline-light:active:focus,.btn-outline-light.active:focus,.btn-outline-light.show:focus{border-color:#eee}.btn-outline-light:disabled,.btn-outline-light.disabled,fieldset:disabled .btn-outline-light{border-color:#fbfbfb}.btn-outline-dark{--mdb-btn-bg: transparent;--mdb-btn-color: #332d2d;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #302b2b;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #302b2b;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #2e2929;border-color:#332d2d}:not(.btn-check)+.btn-outline-dark:hover,.btn-outline-dark:first-child:hover,.btn-outline-dark:focus-visible,.btn-outline-dark:hover{border-color:#302b2b}.btn-check:focus-visible+.btn-outline-dark,.btn-check:focus+.btn-outline-dark,.btn-outline-dark:focus{border-color:#302b2b}.btn-check:checked+.btn-outline-dark,.btn-check:active+.btn-outline-dark,.btn-outline-dark:active,.btn-outline-dark.active,.btn-outline-dark.show{border-color:#2e2929}.btn-check:checked+.btn-outline-dark:focus,.btn-check:active+.btn-outline-dark:focus,.btn-outline-dark:active:focus,.btn-outline-dark.active:focus,.btn-outline-dark.show:focus{border-color:#302b2b}.btn-outline-dark:disabled,.btn-outline-dark.disabled,fieldset:disabled .btn-outline-dark{border-color:#332d2d}.btn-outline-white{--mdb-btn-bg: transparent;--mdb-btn-color: #fff;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: #f2f2f2;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: #f2f2f2;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: #e6e6e6;border-color:#fff}:not(.btn-check)+.btn-outline-white:hover,.btn-outline-white:first-child:hover,.btn-outline-white:focus-visible,.btn-outline-white:hover{border-color:#f2f2f2}.btn-check:focus-visible+.btn-outline-white,.btn-check:focus+.btn-outline-white,.btn-outline-white:focus{border-color:#f2f2f2}.btn-check:checked+.btn-outline-white,.btn-check:active+.btn-outline-white,.btn-outline-white:active,.btn-outline-white.active,.btn-outline-white.show{border-color:#e6e6e6}.btn-check:checked+.btn-outline-white:focus,.btn-check:active+.btn-outline-white:focus,.btn-outline-white:active:focus,.btn-outline-white.active:focus,.btn-outline-white.show:focus{border-color:#f2f2f2}.btn-outline-white:disabled,.btn-outline-white.disabled,fieldset:disabled .btn-outline-white{border-color:#fff}.btn-outline-black{--mdb-btn-bg: transparent;--mdb-btn-color: #000;--mdb-btn-hover-bg: transparent;--mdb-btn-hover-color: black;--mdb-btn-focus-bg: transparent;--mdb-btn-focus-color: black;--mdb-btn-active-bg: transparent;--mdb-btn-active-color: black;border-color:#000}:not(.btn-check)+.btn-outline-black:hover,.btn-outline-black:first-child:hover,.btn-outline-black:focus-visible,.btn-outline-black:hover{border-color:#000}.btn-check:focus-visible+.btn-outline-black,.btn-check:focus+.btn-outline-black,.btn-outline-black:focus{border-color:#000}.btn-check:checked+.btn-outline-black,.btn-check:active+.btn-outline-black,.btn-outline-black:active,.btn-outline-black.active,.btn-outline-black.show{border-color:#000}.btn-check:checked+.btn-outline-black:focus,.btn-check:active+.btn-outline-black:focus,.btn-outline-black:active:focus,.btn-outline-black.active:focus,.btn-outline-black.show:focus{border-color:#000}.btn-outline-black:disabled,.btn-outline-black.disabled,fieldset:disabled .btn-outline-black{border-color:#000}.btn-link{--mdb-btn-font-weight: 500;--mdb-btn-color: #3b71ca;--mdb-btn-hover-color: #386bc0;--mdb-btn-hover-bg: hsl(0, 0%, 96%);--mdb-btn-focus-color: #3566b6;--mdb-btn-active-color: #3260ac;--mdb-btn-disabled-color: #9e9e9e;--mdb-btn-box-shadow: none;text-decoration:none;box-shadow:var(--mdb-btn-box-shadow)}:not(.btn-check)+.btn-link:hover,.btn-link:first-child:hover,.btn-link:focus-visible,.btn-link:hover{text-decoration:none;box-shadow:var(--mdb-btn-box-shadow)}.btn-check:focus-visible+.btn-link,.btn-check:focus+.btn-link,.btn-link:focus{color:var(--mdb-btn-focus-color);box-shadow:var(--mdb-btn-box-shadow)}.btn-check:checked+.btn-link,.btn-check:active+.btn-link,.btn-link:active,.btn-link.active,.btn-link.show{color:var(--mdb-btn-active-color);box-shadow:var(--mdb-btn-box-shadow)}.btn-check:checked+.btn-link:focus,.btn-check:active+.btn-link:focus,.btn-link:active:focus,.btn-link.active:focus,.btn-link.show:focus{color:var(--mdb-btn-focus-color);box-shadow:var(--mdb-btn-box-shadow)}.btn-link:disabled,.btn-link.disabled,fieldset:disabled .btn-link{box-shadow:var(--mdb-btn-box-shadow)}.btn-tertiary{--mdb-btn-font-weight: 500;--mdb-btn-color: #3b71ca;--mdb-btn-hover-color: #386bc0;--mdb-btn-hover-bg: transparent;--mdb-btn-focus-color: #3566b6;--mdb-btn-active-color: #3260ac;--mdb-btn-disabled-color: #9e9e9e;--mdb-btn-box-shadow: none;padding-left:0;padding-right:0;text-decoration:none;box-shadow:var(--mdb-btn-box-shadow)}:not(.btn-check)+.btn-tertiary:hover,.btn-tertiary:first-child:hover,.btn-tertiary:focus-visible,.btn-tertiary:hover{text-decoration:none;box-shadow:var(--mdb-btn-box-shadow)}.btn-check:focus-visible+.btn-tertiary,.btn-check:focus+.btn-tertiary,.btn-tertiary:focus{color:var(--mdb-btn-focus-color);box-shadow:var(--mdb-btn-box-shadow)}.btn-check:checked+.btn-tertiary,.btn-check:active+.btn-tertiary,.btn-tertiary:active,.btn-tertiary.active,.btn-tertiary.show{color:var(--mdb-btn-active-color);box-shadow:var(--mdb-btn-box-shadow)}.btn-check:checked+.btn-tertiary:focus,.btn-check:active+.btn-tertiary:focus,.btn-tertiary:active:focus,.btn-tertiary.active:focus,.btn-tertiary.show:focus{color:var(--mdb-btn-focus-color);box-shadow:var(--mdb-btn-box-shadow)}.btn-tertiary:disabled,.btn-tertiary.disabled,fieldset:disabled .btn-tertiary{box-shadow:var(--mdb-btn-box-shadow)}.btn-lg,.btn-group-lg>.btn{--mdb-btn-padding-top: .75rem;--mdb-btn-padding-bottom: .6875rem;--mdb-btn-padding-x: 1.6875rem;--mdb-btn-font-size:.875rem;--mdb-btn-line-height: 1.6}.btn-sm,.btn-group-sm>.btn{--mdb-btn-padding-top: .375rem;--mdb-btn-padding-bottom: .3125rem;--mdb-btn-padding-x: 1rem;--mdb-btn-font-size:.75rem;--mdb-btn-line-height: 1.5}.btn-rounded{--mdb-btn-border-radius: 10rem;border-radius:var(--mdb-btn-border-radius)}.btn-floating,[class*=btn-outline-].btn-floating{--mdb-btn-border-radius: 50%;border-radius:var(--mdb-btn-border-radius);padding:0;position:relative}.btn-floating{--mdb-btn-width: 2.3125rem;--mdb-btn-height: 2.3125rem;--mdb-btn-icon-width: 2.3125rem;--mdb-btn-icon-line-height: 2.3125rem;--mdb-btn-width-lg: 2.8125rem;--mdb-btn-height-lg: 2.8125rem;--mdb-btn-icon-width-lg: 2.8125rem;--mdb-btn-icon-line-height-lg: 2.8125rem;--mdb-btn-width-sm: 1.8125rem;--mdb-btn-height-sm: 1.8125rem;--mdb-btn-icon-width-sm: 1.8125rem;--mdb-btn-icon-line-height-sm: 1.8125rem;width:var(--mdb-btn-width);height:var(--mdb-btn-height)}.btn-floating .fas,.btn-floating .far,.btn-floating .fab{width:var(--mdb-btn-icon-width);line-height:var(--mdb-btn-icon-line-height)}.btn-floating.btn-lg,.btn-group-lg>.btn-floating.btn{width:var(--mdb-btn-width-lg);height:var(--mdb-btn-height-lg)}.btn-floating.btn-lg .fas,.btn-group-lg>.btn-floating.btn .fas,.btn-floating.btn-lg .far,.btn-group-lg>.btn-floating.btn .far,.btn-floating.btn-lg .fab,.btn-group-lg>.btn-floating.btn .fab{width:var(--mdb-btn-icon-width-lg);line-height:var(--mdb-btn-icon-line-height-lg)}.btn-floating.btn-sm,.btn-group-sm>.btn-floating.btn{width:var(--mdb-btn-width-sm);height:var(--mdb-btn-height-sm)}.btn-floating.btn-sm .fas,.btn-group-sm>.btn-floating.btn .fas,.btn-floating.btn-sm .far,.btn-group-sm>.btn-floating.btn .far,.btn-floating.btn-sm .fab,.btn-group-sm>.btn-floating.btn .fab{width:var(--mdb-btn-icon-width-sm);line-height:var(--mdb-btn-icon-line-height-sm)}[class*=btn-outline-].btn-floating{--mdb-btn-icon-width: 2.0625rem;--mdb-btn-icon-width-lg: 2.5625rem;--mdb-btn-icon-width-sm: 1.5625rem;--mdb-btn-icon-line-height: 2.0625rem;--mdb-btn-icon-line-height-lg: 2.5625rem;--mdb-btn-icon-line-height-sm: 1.5625rem}[class*=btn-outline-].btn-floating .fas,[class*=btn-outline-].btn-floating .far,[class*=btn-outline-].btn-floating .fab{width:var(--mdb-btn-icon-width);line-height:var(--mdb-btn-icon-line-height)}[class*=btn-outline-].btn-floating.btn-lg .fas,.btn-group-lg>[class*=btn-outline-].btn-floating.btn .fas,[class*=btn-outline-].btn-floating.btn-lg .far,.btn-group-lg>[class*=btn-outline-].btn-floating.btn .far,[class*=btn-outline-].btn-floating.btn-lg .fab,.btn-group-lg>[class*=btn-outline-].btn-floating.btn .fab{width:var(--mdb-btn-icon-width-lg);line-height:var(--mdb-btn-icon-line-height-lg)}[class*=btn-outline-].btn-floating.btn-sm .fas,.btn-group-sm>[class*=btn-outline-].btn-floating.btn .fas,[class*=btn-outline-].btn-floating.btn-sm .far,.btn-group-sm>[class*=btn-outline-].btn-floating.btn .far,[class*=btn-outline-].btn-floating.btn-sm .fab,.btn-group-sm>[class*=btn-outline-].btn-floating.btn .fab{width:var(--mdb-btn-icon-width-sm);line-height:var(--mdb-btn-icon-line-height-sm)}.fixed-action-btn{--mdb-btn-right: 2.1875rem;--mdb-btn-bottom: 2.1875rem;--mdb-btn-zindex: 1030;--mdb-btn-padding-top: .9375rem;--mdb-btn-padding-bottom: 1.25rem;--mdb-btn-padding-x: 1.25rem;--mdb-btn-margin-bottom: 1.5rem;position:fixed;right:var(--mdb-btn-right);bottom:var(--mdb-btn-bottom);z-index:var(--mdb-btn-zindex);display:flex;flex-flow:column-reverse nowrap;align-items:center;padding:var(--mdb-btn-padding-top) var(--mdb-btn-padding-x) var(--mdb-btn-padding-bottom);margin-bottom:0;height:auto;overflow:hidden}.fixed-action-btn>.btn-floating{position:relative;transform:scale(1.2);z-index:10}.fixed-action-btn ul{position:absolute;bottom:0;left:0;right:0;display:flex;flex-direction:column;padding:0;margin:0;text-align:center;opacity:0;transition:transform .4s,opacity .4s;z-index:-1}.fixed-action-btn ul li{z-index:0;display:flex;margin-right:auto;margin-bottom:var(--mdb-btn-margin-bottom);margin-left:auto}.fixed-action-btn ul li:first-of-type{margin-top:calc(var(--mdb-btn-margin-bottom)*.5)}.fixed-action-btn ul a.btn{opacity:0;transition:opacity .4s ease-in}.fixed-action-btn ul a.btn.shown,.fixed-action-btn.active ul{opacity:1}.btn-block{--mdb-btn-margin-top: .5rem;display:block;width:100%}.btn-block+.btn-block{margin-top:var(--mdb-btn-margin-top)}hr.divider-horizontal:not([size]){height:2px}.divider-horizontal{opacity:1;background-color:#f5f5f5;height:2px}.divider-vertical{opacity:1;background-color:#f5f5f5;display:inline-block;width:2px;margin:0 1rem}hr.divider-horizontal-blurry{background-image:linear-gradient(90deg,transparent,hsl(0,0%,40%),transparent);background-color:#0000}hr.divider-vertical-blurry{background-image:linear-gradient(180deg,transparent,hsl(0,0%,40%),transparent);background-color:#0000;width:1px;top:0;right:0}.dropdown-menu{--mdb-dropdown-item-border-radius: .5rem;color:var(--mdb-dropdown-color);margin:0;padding-top:0;padding-bottom:0;border:0;box-shadow:var(--mdb-dropdown-box-shadow);font-size:var(--mdb-dropdown-font-size);top:100%;left:0;margin-top:var(--mdb-dropdown-spacer)}.dropdown-menu>li{border-radius:0}.dropdown-menu>li:first-child{border-top-left-radius:var(--mdb-dropdown-item-border-radius);border-top-right-radius:var(--mdb-dropdown-item-border-radius);border-bottom-left-radius:0;border-bottom-right-radius:0}.dropdown-menu>li:first-child .dropdown-item{border-top-left-radius:var(--mdb-dropdown-item-border-radius);border-top-right-radius:var(--mdb-dropdown-item-border-radius);border-bottom-left-radius:0;border-bottom-right-radius:0}.dropdown-menu>li:not(:first-child):not(:last-child) .dropdown-item{border-radius:0}.dropdown-menu>li:last-child{border-top-left-radius:0;border-top-right-radius:0;border-bottom-left-radius:var(--mdb-dropdown-item-border-radius);border-bottom-right-radius:var(--mdb-dropdown-item-border-radius)}.dropdown-menu>li:last-child .dropdown-item{border-top-left-radius:0;border-top-right-radius:0;border-bottom-left-radius:var(--mdb-dropdown-item-border-radius);border-bottom-right-radius:var(--mdb-dropdown-item-border-radius)}.dropdown-menu.animation{--mdb-dropdown-menu-animated-animation-duration: .55s;--mdb-dropdown-menu-animated-animation-timing-function: ease;display:block;animation-duration:var(--mdb-dropdown-menu-animated-animation-duration);animation-timing-function:var(--mdb-dropdown-menu-animated-animation-timing-function)}.dropdown-item{--mdb-dropdown-state-color: #16181b;--mdb-dropdown-state-background-color: #eee;padding:var(--mdb-dropdown-item-padding-y) var(--mdb-dropdown-item-padding-x);color:var(--mdb-dropdown-color);border-radius:0}.dropdown-item:hover,.dropdown-item:focus{color:var(--mdb-dropdown-state-color);background-color:var(--mdb-dropdown-state-background-color)}.dropdown-item.active,.dropdown-item:active{color:var(--mdb-dropdown-state-color);background-color:var(--mdb-dropdown-state-background-color)}.hidden-arrow.dropdown-toggle:after{display:none}.animation{animation-duration:1s;animation-fill-mode:both;padding:auto}@media (prefers-reduced-motion){.animation{transition:none!important;animation:unset!important}}@keyframes fade-in{0%{opacity:0}to{opacity:1}}.fade-in{animation-name:fade-in}@keyframes fade-out{0%{opacity:1}to{opacity:0}}.fade-out{animation-name:fade-out}.dropdown-divider{--mdb-dropdown-divider-border-top-width: 2px;--mdb-dropdown-divider-border-top-bg: hsl(0, 0%, 96%);border-top:var(--mdb-dropdown-divider-border-top-width) solid var(--mdb-dropdown-divider-border-top-bg);opacity:1}.dropdown-menu INPUT:not(:-webkit-autofill),.dropdown-menu SELECT:not(:-webkit-autofill),.dropdown-menu TEXTAREA:not(:-webkit-autofill){animation-name:none!important}.btn-group,.btn-group-vertical{--mdb-btn-box-shadow: 0 4px 9px -4px rgba(0, 0, 0, .35);--mdb-btn-hover-box-shadow: 0 8px 9px -4px rgba(0, 0, 0, .15), 0 4px 18px 0 rgba(0, 0, 0, .1);--mdb-btn-focus-box-shadow: 0 8px 9px -4px rgba(0, 0, 0, .15), 0 4px 18px 0 rgba(0, 0, 0, .1);--mdb-btn-active-box-shadow: 0 8px 9px -4px rgba(0, 0, 0, .15), 0 4px 18px 0 rgba(0, 0, 0, .1);--mdb-btn-group-transition: color .15s ease-in-out, background-color .15s ease-in-out, border-color .15s ease-in-out, box-shadow .15s ease-in-out;box-shadow:var(--mdb-btn-box-shadow);transition:var(--mdb-btn-group-transition)}.btn-group:hover,.btn-group-vertical:hover{box-shadow:var(--mdb-btn-hover-box-shadow)}.btn-group:focus,.btn-group.focus,.btn-group-vertical:focus,.btn-group-vertical.focus{box-shadow:var(--mdb-btn-focus-box-shadow)}.btn-group:active,.btn-group.active,.btn-group-vertical:active,.btn-group-vertical.active{box-shadow:var(--mdb-btn-active-box-shadow)}.btn-group:active:focus,.btn-group.active:focus,.btn-group-vertical:active:focus,.btn-group-vertical.active:focus{box-shadow:var(--mdb-btn-focus-box-shadow)}.btn-group:disabled,.btn-group.disabled,fieldset:disabled .btn-group,.btn-group-vertical:disabled,.btn-group-vertical.disabled,fieldset:disabled .btn-group-vertical{box-shadow:var(--mdb-btn-box-shadow);border:0}.btn-group>.btn,.btn-group-vertical>.btn{box-shadow:none}:not(.btn-check)+.btn-group>.btn:hover,.btn-group>.btn:first-child:hover,.btn-group>.btn:focus-visible,.btn-group>.btn:hover,:not(.btn-check)+.btn-group-vertical>.btn:hover,.btn-group-vertical>.btn:first-child:hover,.btn-group-vertical>.btn:focus-visible,.btn-group-vertical>.btn:hover{box-shadow:none!important}.btn-check:focus-visible+.btn-group>.btn,.btn-check:focus+.btn-group>.btn,.btn-group>.btn:focus,.btn-check:focus-visible+.btn-group-vertical>.btn,.btn-check:focus+.btn-group-vertical>.btn,.btn-group-vertical>.btn:focus{box-shadow:none}.btn-check:checked+.btn-group>.btn,.btn-check:active+.btn-group>.btn,.btn-group>.btn:active,.btn-group>.btn.active,.btn-group>.btn.show,.btn-check:checked+.btn-group-vertical>.btn,.btn-check:active+.btn-group-vertical>.btn,.btn-group-vertical>.btn:active,.btn-group-vertical>.btn.active,.btn-group-vertical>.btn.show{box-shadow:none}.btn-check:checked+.btn-group>.btn:focus,.btn-check:active+.btn-group>.btn:focus,.btn-group>.btn:active:focus,.btn-group>.btn.active:focus,.btn-group>.btn.show:focus,.btn-check:checked+.btn-group-vertical>.btn:focus,.btn-check:active+.btn-group-vertical>.btn:focus,.btn-group-vertical>.btn:active:focus,.btn-group-vertical>.btn.active:focus,.btn-group-vertical>.btn.show:focus{box-shadow:none}.btn-group>.btn:disabled,.btn-group>.btn.disabled,fieldset:disabled .btn-group>.btn,.btn-group-vertical>.btn:disabled,.btn-group-vertical>.btn.disabled,fieldset:disabled .btn-group-vertical>.btn{box-shadow:none}.btn-group>.btn-group,.btn-group-vertical>.btn-group{box-shadow:none}.btn-group>.btn-link:first-child,.btn-group>.btn-tertiary:first-child,.btn-group-vertical>.btn-link:first-child,.btn-group-vertical>.btn-tertiary:first-child{border-top-left-radius:0;border-bottom-left-radius:0}.btn-group>.btn-link:last-child,.btn-group>.btn-tertiary:last-child,.btn-group-vertical>.btn-link:last-child,.btn-group-vertical>.btn-tertiary:last-child{border-top-right-radius:0;border-bottom-right-radius:0}.btn-group,.btn-group-lg>.btn,.btn-group-sm>.btn{--mdb-btn-border-radius: .25rem;border-radius:var(--mdb-btn-border-radius)}.nav-tabs{border-bottom:0}.nav-tabs .nav-link{--mdb-nav-tabs-link-font-weight: 500;--mdb-nav-tabs-link-font-size: 12px;--mdb-nav-tabs-link-color: rgba(0, 0, 0, .55);--mdb-nav-tabs-link-padding-top: 17px;--mdb-nav-tabs-link-padding-bottom: 16px;--mdb-nav-tabs-link-padding-x: 29px;--mdb-nav-tabs-link-hover-bgc: #f7f7f7;--mdb-nav-tabs-link-border-bottom-width: 2px;--mdb-nav-tabs-link-active-color: #3b71ca;--mdb-nav-tabs-link-active-border-color: #3b71ca;border-width:0;border-bottom:var(--mdb-nav-tabs-link-border-bottom-width) solid rgba(0,0,0,0);border-radius:0;text-transform:uppercase;line-height:1;font-weight:var(--mdb-nav-tabs-link-font-weight);font-size:var(--mdb-nav-tabs-link-font-size);color:var(--mdb-nav-tabs-link-color);padding:var(--mdb-nav-tabs-link-padding-top) var(--mdb-nav-tabs-link-padding-x) var(--mdb-nav-tabs-link-padding-bottom) var(--mdb-nav-tabs-link-padding-x)}.nav-tabs .nav-link:hover{background-color:var(--mdb-nav-tabs-link-hover-bgc);border-color:#0000}.nav-tabs .nav-link:focus{border-color:#0000}.nav-tabs .nav-link.active,.nav-tabs .nav-item.show .nav-link{color:var(--mdb-nav-tabs-link-active-color);border-color:var(--mdb-nav-tabs-link-active-border-color)}.nav-pills{margin-left:-.5rem}.nav-pills .nav-link{--mdb-nav-pills-link-border-radius: .25rem;--mdb-nav-pills-link-font-size: 12px;--mdb-nav-pills-link-padding-top: 17px;--mdb-nav-pills-link-padding-bottom: 16px;--mdb-nav-pills-link-padding-x: 29px;--mdb-nav-pills-link-line-height: 1;--mdb-nav-pills-link-hover-bg: #f7f7f7;--mdb-nav-pills-link-font-weight: 500;--mdb-nav-pills-link-color: rgba(0, 0, 0, .55);--mdb-nav-pills-margin: .5rem;border-radius:var(--mdb-nav-pills-link-border-radius);font-size:var(--mdb-nav-pills-link-font-size);text-transform:uppercase;padding:var(--mdb-nav-pills-link-padding-top) var(--mdb-nav-pills-link-padding-x) var(--mdb-nav-pills-link-padding-bottom) var(--mdb-nav-pills-link-padding-x);line-height:var(--mdb-nav-pills-link-line-height);background-color:var(--mdb-nav-pills-link-hover-bg);font-weight:var(--mdb-nav-pills-link-font-weight);color:var(--mdb-nav-pills-link-color);margin:var(--mdb-nav-pills-margin)}.nav-pills .nav-link.active,.nav-pills .show>.nav-link{--mdb-nav-pills-link-active-bg: #e3ebf7;--mdb-nav-pills-link-active-color: #285192;background-color:var(--mdb-nav-pills-link-active-bg);color:var(--mdb-nav-pills-link-active-color)}.nav-fill .nav-item .nav-link,.nav-justified .nav-item .nav-link{width:auto}.navbar{--mdb-navbar-box-shadow: 0 4px 12px 0 rgba(0, 0, 0, .07), 0 2px 4px rgba(0, 0, 0, .05);--mdb-navbar-padding-top: .5625rem;--mdb-navbar-brand-img-margin-right: .25rem;box-shadow:var(--mdb-navbar-box-shadow);padding-top:var(--mdb-navbar-padding-top)}.navbar-toggler{border:0}.navbar-toggler:focus{box-shadow:none}.navbar-dark .navbar-toggler,.navbar-light .navbar-toggler{border:0}.navbar-brand{display:flex;align-items:center}.navbar-brand img{margin-right:var(--mdb-navbar-brand-img-margin-right)}.navbar-nav .dropdown-menu{position:absolute}.navbar-light .navbar-toggler-icon,.navbar-dark .navbar-toggler-icon{background-image:none}.card{border:0}.card .bg-image{border-top-left-radius:var(--mdb-card-border-radius);border-top-right-radius:var(--mdb-card-border-radius)}.card[class*=bg-] .card-header{--mdb-card-header-border-bottom-color: var(--mdb-border-color-translucent);border-bottom-color:var(--mdb-card-header-border-bottom-color)}.card[class*=bg-] .card-footer{--mdb-card-footer-border-top-color: var(--mdb-border-color-translucent);border-top-color:var(--mdb-card-footer-border-top-color)}.card-header{--mdb-card-header-border-width: 2px;--mdb-card-header-border-color: hsl(0, 0%, 96%);border-bottom:var(--mdb-card-header-border-width) solid var(--mdb-card-header-border-color)}.card-body[class*=bg-]{border-bottom-left-radius:var(--mdb-card-border-radius);border-bottom-right-radius:var(--mdb-card-border-radius)}.card-footer{--mdb-card-footer-border-color: hsl(0, 0%, 96%);--mdb-card-footer-border-width: 2px;border-top:var(--mdb-card-footer-border-width) solid var(--mdb-card-footer-border-color)}.card-img-left{border-top-left-radius:var(--mdb-card-border-radius);border-bottom-left-radius:var(--mdb-card-border-radius)}.navbar .breadcrumb{--mdb-breadcrumb-item-color: rgba(0, 0, 0, .55);--mdb-breadcrumb-item-hover-color: rgba(0, 0, 0, .7);--mdb-breadcrumb-item-before-color: rgba(0, 0, 0, .55);--mdb-breadcrumb-item-transition: color .15s ease-in-out;background-color:#0000;margin-bottom:0}.navbar .breadcrumb .breadcrumb-item a{color:var(--mdb-breadcrumb-item-color);transition:var(--mdb-breadcrumb-item-transition)}.navbar .breadcrumb .breadcrumb-item a:hover,.navbar .breadcrumb .breadcrumb-item a:focus{color:var(--mdb-breadcrumb-item-hover-color)}.navbar .breadcrumb .breadcrumb-item+.breadcrumb-item:before{color:var(--mdb-breadcrumb-item-before-color)}.pagination{--mdb-pagination-border-radius: .25rem;--mdb-pagination-active-box-shadow: 0 4px 9px -4px #e3ebf7;--mdb-pagination-active-transition: all .2s linear;--mdb-pagination-active-font-weight: 500;--mdb-pagination-circle-border-radius: 50%;--mdb-pagination-circle-padding-x: .841rem;--mdb-pagination-circle-padding-l-lg: 1.399414rem;--mdb-pagination-circle-padding-r-lg: 1.399415rem;--mdb-pagination-circle-padding-l-sm: .696rem;--mdb-pagination-circle-padding-r-sm: .688rem}.page-link{background-color:#0000;border:0;outline:0;border-radius:var(--mdb-pagination-border-radius)}.page-link:focus{box-shadow:none}.page-link.active,.active>.page-link{border:0;box-shadow:var(--mdb-pagination-active-box-shadow);transition:var(--mdb-pagination-active-transition);font-weight:var(--mdb-pagination-active-font-weight)}.page-item:not(:first-child) .page-link{margin-left:0}.page-item:first-child .page-link{border-top-left-radius:var(--mdb-pagination-border-radius);border-bottom-left-radius:var(--mdb-pagination-border-radius)}.page-item:last-child .page-link{border-top-right-radius:var(--mdb-pagination-border-radius);border-bottom-right-radius:var(--mdb-pagination-border-radius)}.pagination-circle .page-item:first-child .page-link{border-radius:var(--mdb-pagination-circle-border-radius)}.pagination-circle .page-item:last-child .page-link{border-radius:var(--mdb-pagination-circle-border-radius)}.pagination-circle .page-link{border-radius:var(--mdb-pagination-circle-border-radius);padding-left:var(--mdb-pagination-circle-padding-x);padding-right:var(--mdb-pagination-circle-padding-x)}.pagination-circle.pagination-lg .page-link{padding-left:var(--mdb-pagination-circle-padding-l-lg);padding-right:var(--mdb-pagination-circle-padding-r-lg)}.pagination-circle.pagination-sm .page-link{padding-left:var(--mdb-pagination-circle-padding-l-sm);padding-right:var(--mdb-pagination-circle-padding-r-sm)}.badge-dot{--mdb-badge-border-radius: 4.5px;--mdb-badge-height: 9px;--mdb-badge-width: 9px;--mdb-badge-margin-left: -.3125rem;position:absolute;min-width:0;width:var(--mdb-badge-width);height:var(--mdb-badge-height);border-radius:var(--mdb-badge-border-radius);padding:0;margin-left:var(--mdb-badge-margin-left)}.badge-dot:empty{display:inline-block}.badge-notification{--mdb-badge-font-size: .6rem;--mdb-badge-padding-x: .45em;--mdb-badge-padding-y: .2em;--mdb-badge-margin-top: -.1rem;--mdb-badge-margin-left: -.5rem;position:absolute;font-size:var(--mdb-badge-font-size);padding:var(--mdb-badge-padding-y) var(--mdb-badge-padding-x);margin-top:var(--mdb-badge-margin-top);margin-left:var(--mdb-badge-margin-left)}.badge-primary{background-color:#dfe7f6;color:#2c58a0}.badge-primary i{color:#376fc8}.badge-secondary{background-color:#ebedef;color:#40464f}.badge-secondary i{color:#565e6c}.badge-success{background-color:#d6f0e0;color:#0d6832}.badge-success i{color:#139647}.badge-danger{background-color:#f9e1e5;color:#af233a}.badge-danger i{color:#d62e4a}.badge-warning{background-color:#fbf0da;color:#73510d}.badge-warning i{color:#a17112}.badge-info{background-color:#def1f7;color:#1c657d}.badge-info i{color:#2686a6}.badge-light{background-color:#f5f5f5;color:#4f4f4f}.badge-light i{color:#8c8c8c}.badge-dark{background-color:#332e2e;color:#f5f5f5}.badge-dark i{color:#e8e8e8}.alert{border:0}.alert-absolute{position:absolute}.alert-fixed{--mdb-alert-fixed-z-index: 1070;position:fixed;z-index:var(--mdb-alert-fixed-z-index)}.parent-alert-relative{position:relative}.alert-primary{background-color:#dfe7f6;color:#2c58a0}.alert-primary i{color:#376fc8}.alert-primary .alert-link{color:#2c58a0}.alert-primary .alert-link:hover{color:#234680}.alert-secondary{background-color:#ebedef;color:#40464f}.alert-secondary i{color:#565e6c}.alert-secondary .alert-link{color:#40464f}.alert-secondary .alert-link:hover{color:#33383f}.alert-success{background-color:#d6f0e0;color:#0d6832}.alert-success i{color:#139647}.alert-success .alert-link{color:#0d6832}.alert-success .alert-link:hover{color:#0a5328}.alert-danger{background-color:#f9e1e5;color:#af233a}.alert-danger i{color:#d62e4a}.alert-danger .alert-link{color:#af233a}.alert-danger .alert-link:hover{color:#8c1c2e}.alert-warning{background-color:#fbf0da;color:#73510d}.alert-warning i{color:#a17112}.alert-warning .alert-link{color:#73510d}.alert-warning .alert-link:hover{color:#5c410a}.alert-info{background-color:#def1f7;color:#1c657d}.alert-info i{color:#2686a6}.alert-info .alert-link{color:#1c657d}.alert-info .alert-link:hover{color:#165164}.alert-light{background-color:#f5f5f5;color:#4f4f4f}.alert-light i{color:#8c8c8c}.alert-light .alert-link{color:#4f4f4f}.alert-light .alert-link:hover{color:#3f3f3f}.alert-dark{background-color:#332e2e;color:#f5f5f5}.alert-dark i{color:#e8e8e8}.alert-dark .alert-link{color:#f5f5f5}.alert-dark .alert-link:hover{color:#c4c4c4}.progress{border-radius:0;box-shadow:none}.list-group{--mdb-list-group-item-transition-time: .5s}.list-group-item-action,.list-group-item-action:hover{transition:var(--mdb-list-group-item-transition-time)}.list-group-light{--mdb-list-group-light-item-py: 1rem;--mdb-list-group-light-item-border: 2px solid hsl(0, 0%, 96%);--mdb-list-group-light-item-border-width: 2px;--mdb-list-group-light-active-border-radius: .5rem;--mdb-list-group-light-active-bg: rgb(223, 231, 246);--mdb-list-group-light-active-color: rgb(44, 88, 160)}.list-group-light .list-group-item{padding:var(--mdb-list-group-light-item-py) 0;border:var(--mdb-list-group-light-item-border)}.list-group-light>.list-group-item{border-width:0 0 var(--mdb-list-group-light-item-border-width)}.list-group-light>.list-group-item:last-of-type{border:none}.list-group-light .active{border:none;border-radius:var(--mdb-list-group-light-active-border-radius);background-color:var(--mdb-list-group-light-active-bg);color:var(--mdb-list-group-light-active-color)}.list-group-light .list-group-item-action:hover{border-radius:var(--mdb-list-group-light-active-border-radius)}.list-group-light .list-group-item-action:focus{border-radius:var(--mdb-list-group-light-active-border-radius)}.list-group-small{--mdb-list-group-small-item-py: .5rem}.list-group-small .list-group-item{padding:var(--mdb-list-group-small-item-py) 0}.list-group-item-primary{background-color:#dfe7f6;color:#2c58a0}.list-group-item-primary i{color:#376fc8}.list-group-item-secondary{background-color:#ebedef;color:#40464f}.list-group-item-secondary i{color:#565e6c}.list-group-item-success{background-color:#d6f0e0;color:#0d6832}.list-group-item-success i{color:#139647}.list-group-item-danger{background-color:#f9e1e5;color:#af233a}.list-group-item-danger i{color:#d62e4a}.list-group-item-warning{background-color:#fbf0da;color:#73510d}.list-group-item-warning i{color:#a17112}.list-group-item-info{background-color:#def1f7;color:#1c657d}.list-group-item-info i{color:#2686a6}.list-group-item-light{background-color:#f5f5f5;color:#4f4f4f}.list-group-item-light i{color:#8c8c8c}.list-group-item-dark{background-color:#332e2e;color:#f5f5f5}.list-group-item-dark i{color:#e8e8e8}.btn-close:focus{box-shadow:none}.modal-content{--mdb-modal-box-shadow: 0 2px 15px -3px rgba(0, 0, 0, .07), 0 10px 20px -2px rgba(0, 0, 0, .04);border:0;box-shadow:var(--mdb-modal-box-shadow)}.toast{--mdb-toast-border-bottom-width: 2px;--mdb-toast-btn-close-width: 1.3em;--mdb-toast-btn-close-mr: -.375rem;--mdb-toast-btn-close-ml: .75rem;border:0}.toast .btn-close{width:var(--mdb-toast-btn-close-width)}.toast-header{border-bottom-width:var(--mdb-toast-border-bottom-width)}.toast-header .btn-close{margin-right:var(--mdb-toast-btn-close-mr);margin-left:var(--mdb-toast-btn-close-ml)}.parent-toast-relative{position:relative}.toast-absolute{position:absolute}.toast-fixed{position:fixed;z-index:var(--mdb-toast-zindex)}.toast-primary{background-color:#dfe7f6;color:#2c58a0;border-color:#c7d6f0}.toast-primary i{color:#376fc8}.toast-secondary{background-color:#ebedef;color:#40464f;border-color:#dadee1}.toast-secondary i{color:#565e6c}.toast-success{background-color:#d6f0e0;color:#0d6831;border-color:#c0e7d0}.toast-success i{color:#139647}.toast-danger{background-color:#f9e1e5;color:#af233a;border-color:#f4c8cf}.toast-danger i{color:#d62e4a}.toast-warning{background-color:#fbf0da;color:#73510d;border-color:#f9e4be}.toast-warning i{color:#a17112}.toast-info{background-color:#def1f7;color:#1c657d;border-color:#c6e6f1}.toast-info i{color:#2686a6}.toast-light{background-color:#f5f5f5;color:#4f4f4f;border-color:#e6e6e6}.toast-light i{color:#8c8c8c}.toast-dark{background-color:#332e2e;color:#f5f5f5;border-color:#443c3c}.toast-dark i{color:#e8e8e8}.tooltip{--mdb-tooltip-font-size: 14px}.tooltip.show{opacity:1}.tooltip .tooltip-arrow{display:none}.tooltip-inner{font-size:var(--mdb-tooltip-font-size)}.popover{--mdb-popover-border-bottom-width: 2px}.popover .popover-arrow{display:none}.popover-header{border-bottom:var(--mdb-popover-border-bottom-width) solid var(--mdb-popover-border-color)}.nav-pills.menu-sidebar .nav-link{--mdb-scrollspy-menu-sidebar-font-size: .8rem;--mdb-scrollspy-menu-sidebar-color: #262626;--mdb-scrollspy-menu-sidebar-line-height: 1.1rem;--mdb-scrollspy-menu-sidebar-padding-x: 5px;--mdb-scrollspy-menu-sidebar-font-weight: 400;--mdb-scrollspy-menu-sidebar-transition: all .2s ease-in-out;--mdb-scrollspy-menu-sidebar-margin-y: 3px;font-size:var(--mdb-scrollspy-menu-sidebar-font-size);background-color:#0000;color:var(--mdb-scrollspy-menu-sidebar-color);line-height:var(--mdb-scrollspy-menu-sidebar-line-height);padding:0 var(--mdb-scrollspy-menu-sidebar-padding-x);font-weight:var(--mdb-scrollspy-menu-sidebar-font-weight);transition:var(--mdb-scrollspy-menu-sidebar-transition);text-transform:initial;margin-top:var(--mdb-scrollspy-menu-sidebar-margin-y);margin-bottom:var(--mdb-scrollspy-menu-sidebar-margin-y)}.nav-pills.menu-sidebar .nav-link.active,.nav-pills.menu-sidebar .show>.nav-link{--mdb-scrollspy-menu-sidebar-active-color: #3b71ca;--mdb-scrollspy-menu-sidebar-active-font-weight: 600;--mdb-scrollspy-menu-sidebar-active-border-width: .125rem;--mdb-scrollspy-menu-sidebar-active-border-color: #3b71ca;background-color:#0000;box-shadow:none;color:var(--mdb-scrollspy-menu-sidebar-active-color);font-weight:var(--mdb-scrollspy-menu-sidebar-active-font-weight);border-left:var(--mdb-scrollspy-menu-sidebar-active-border-width) solid var(--mdb-scrollspy-menu-sidebar-active-border-color);border-radius:0}.nav-pills.menu-sidebar .collapsible-scrollspy~.nav{--mdb-scrollspy-collapsible-nav-transition-time: .5s;transition:height var(--mdb-scrollspy-collapsible-nav-transition-time) ease;flex-wrap:nowrap}.ripple-surface{position:relative;overflow:hidden;display:inline-block;vertical-align:bottom}.ripple-surface-unbound{overflow:visible}.ripple-wave{--mdb-ripple-wave-cubicBezier: cubic-bezier(0, 0, .15, 1);--mdb-ripple-wave-border-radius: 50%;--mdb-ripple-wave-opacity: .5;--mdb-ripple-wave-transform: scale(0);--mdb-ripple-wave-z-index: 999;--mdb-ripple-wave-active-transform: scale(1);background-image:radial-gradient(circle,rgba(0,0,0,.2) 0,rgba(0,0,0,.3) 40%,rgba(0,0,0,.4) 50%,rgba(0,0,0,.5) 60%,rgba(0,0,0,0) 70%);border-radius:var(--mdb-ripple-wave-border-radius);opacity:var(--mdb-ripple-wave-opacity);pointer-events:none;position:absolute;touch-action:none;transform:var(--mdb-ripple-wave-transform);transition-property:transform,opacity;transition-timing-function:var(--mdb-ripple-wave-cubicBezier),var(--mdb-ripple-wave-cubicBezier);z-index:var(--mdb-ripple-wave-z-index)}.ripple-wave.active{transform:var(--mdb-ripple-wave-active-transform);opacity:0}.btn .ripple-wave,.input-wrapper .ripple-wave{background-image:radial-gradient(circle,rgba(255,255,255,.2) 0,rgba(255,255,255,.3) 40%,rgba(255,255,255,.4) 50%,rgba(255,255,255,.5) 60%,rgba(255,255,255,0) 70%)}.ripple-surface-primary .ripple-wave{background-image:radial-gradient(circle,rgba(59,113,202,.2) 0,rgba(59,113,202,.3) 40%,rgba(59,113,202,.4) 50%,rgba(59,113,202,.5) 60%,rgba(59,113,202,0) 70%)}.ripple-surface-secondary .ripple-wave{background-image:radial-gradient(circle,rgba(227,235,247,.2) 0,rgba(227,235,247,.3) 40%,rgba(227,235,247,.4) 50%,rgba(227,235,247,.5) 60%,rgba(227,235,247,0) 70%)}.ripple-surface-success .ripple-wave{background-image:radial-gradient(circle,rgba(20,164,77,.2) 0,rgba(20,164,77,.3) 40%,rgba(20,164,77,.4) 50%,rgba(20,164,77,.5) 60%,rgba(20,164,77,0) 70%)}.ripple-surface-danger .ripple-wave{background-image:radial-gradient(circle,rgba(220,76,100,.2) 0,rgba(220,76,100,.3) 40%,rgba(220,76,100,.4) 50%,rgba(220,76,100,.5) 60%,rgba(220,76,100,0) 70%)}.ripple-surface-warning .ripple-wave{background-image:radial-gradient(circle,rgba(228,161,27,.2) 0,rgba(228,161,27,.3) 40%,rgba(228,161,27,.4) 50%,rgba(228,161,27,.5) 60%,rgba(228,161,27,0) 70%)}.ripple-surface-info .ripple-wave{background-image:radial-gradient(circle,rgba(84,180,211,.2) 0,rgba(84,180,211,.3) 40%,rgba(84,180,211,.4) 50%,rgba(84,180,211,.5) 60%,rgba(84,180,211,0) 70%)}.ripple-surface-light .ripple-wave{background-image:radial-gradient(circle,rgba(251,251,251,.2) 0,rgba(251,251,251,.3) 40%,rgba(251,251,251,.4) 50%,rgba(251,251,251,.5) 60%,rgba(251,251,251,0) 70%)}.ripple-surface-dark .ripple-wave{background-image:radial-gradient(circle,rgba(51,45,45,.2) 0,rgba(51,45,45,.3) 40%,rgba(51,45,45,.4) 50%,rgba(51,45,45,.5) 60%,rgba(51,45,45,0) 70%)}.range{--mdb-range-thumb-height: 30px;--mdb-range-thumb-width: 30px;--mdb-range-thumb-top: -35px;--mdb-range-thumb-margin-left: -15px;--mdb-range-thumb-border-radius: 50% 50% 50% 0;--mdb-range-thumb-transform: scale(0);--mdb-range-thumb-transition: transform .2s ease-in-out;--mdb-range-thumb-value-font-size: 12px;--mdb-range-thumb-value-line-height: 30px;--mdb-range-thumb-value-color: rgb(255, 255, 255);--mdb-range-thumb-value-font-weight: 500;--mdb-range-thumb-background: #3b71ca;position:relative}.range .thumb{position:absolute;display:block;height:var(--mdb-range-thumb-height);width:var(--mdb-range-thumb-width);top:var(--mdb-range-thumb-top);margin-left:var(--mdb-range-thumb-margin-left);text-align:center;border-radius:var(--mdb-range-thumb-border-radius);transform:var(--mdb-range-thumb-transform);transform-origin:bottom;transition:var(--mdb-range-thumb-transition)}.range .thumb:after{position:absolute;display:block;content:"";transform:translate(-50%);width:100%;height:100%;top:0;border-radius:var(--mdb-range-thumb-border-radius);transform:rotate(-45deg);background:var(--mdb-range-thumb-background);z-index:-1}.range .thumb .thumb-value{display:block;font-size:var(--mdb-range-thumb-value-font-size);line-height:var(--mdb-range-thumb-value-line-height);color:var(--mdb-range-thumb-value-color);font-weight:var(--mdb-range-thumb-value-font-weight);z-index:2}.range .thumb.thumb-active{transform:scale(1)}.accordion-button:not(.collapsed):focus{box-shadow:var(--mdb-accordion-btn-focus-box-shadow)}.accordion-button:focus{border-color:var(--mdb-accordion-btn-focus-border-color);outline:0;box-shadow:none}.accordion-flush{--mdb-accordion-flush-btn-box-shadow: inset 0 -2px 0 hsl(0, 0%, 96%);--mdb-accordion-flush-border-bottom: 2px solid hsl(0, 0%, 96%)}.accordion-flush .accordion-button:not(.collapsed){box-shadow:var(--mdb-accordion-flush-btn-box-shadow)}.accordion-flush .accordion-item{border-bottom:var(--mdb-accordion-flush-border-bottom)}.accordion.accordion-borderless,.accordion.accordion-flush{--mdb-accordion-bg: transparent;background-color:var(--mdb-accordion-bg)}.accordion-borderless{--mdb-accordion-borderless-btn-border-radius: .5rem;--mdb-accordion-borderless-btn-bg: rgb(223, 231, 246);--mdb-accordion-borderless-btn-color: rgb(44, 88, 160)}.accordion-borderless .accordion-item{border:0}.accordion-borderless .accordion-item .accordion-button{border-radius:var(--mdb-accordion-borderless-btn-border-radius)}.accordion-borderless .accordion-item .accordion-button:not(.collapsed){background-color:var(--mdb-accordion-borderless-btn-bg);color:var(--mdb-accordion-borderless-btn-color);box-shadow:none}.carousel-control-prev-icon:after{content:"";--mdb-carousel-control-icon-font-size: 1.7rem;--mdb-carousel-control-icon-font-weight: 700;font-weight:var(--mdb-carousel-control-icon-font-weight);font-size:var(--mdb-carousel-control-icon-font-size);font-family:"Font Awesome 6 Pro","Font Awesome 6 Free"}.carousel-control-next-icon:after{content:"";--mdb-carousel-control-icon-font-size: 1.7rem;--mdb-carousel-control-icon-font-weight: 700;font-weight:var(--mdb-carousel-control-icon-font-weight);font-size:var(--mdb-carousel-control-icon-font-size);font-family:"Font Awesome 6 Pro","Font Awesome 6 Free"}.form-check-input[type=checkbox]{margin-right:0}.form-check-label{padding-left:.15rem}.badge:not(.badge-dot):not(.badge-notification){margin:0 .12rem}.btn{margin:0 .12rem}.input-group .btn{margin:0}.btn-group>.btn,.btn-group-vertical>.btn{margin:0}.carousel-indicators button{box-sizing:content-box;flex:0 1 auto;width:30px;height:3px;padding:0;margin-right:3px;margin-left:3px;text-indent:-999px;cursor:pointer;background-color:#fff;background-clip:padding-box;border:0;border-top:10px solid rgba(0,0,0,0);border-bottom:10px solid rgba(0,0,0,0);opacity:.5;transition:opacity .6s ease}.carousel-dark .carousel-indicators button{background-color:#000}@media (max-width: 575.98px){.navbar-expand-sm .navbar-collapse{display:none!important}.navbar-expand-sm .navbar-collapse.show{display:block!important}}@media (min-width: 576px){.navbar-expand-sm .collapse.navbar-collapse:not(.show){display:flex!important;height:auto!important}}@media (max-width: 767.98px){.navbar-expand-md .navbar-collapse{display:none!important}.navbar-expand-md .navbar-collapse.show{display:block!important}}@media (min-width: 768px){.navbar-expand-md .collapse.navbar-collapse:not(.show){display:flex!important;height:auto!important}}@media (max-width: 991.98px){.navbar-expand-lg .navbar-collapse{display:none!important}.navbar-expand-lg .navbar-collapse.show{display:block!important}}@media (min-width: 992px){.navbar-expand-lg .collapse.navbar-collapse:not(.show){display:flex!important;height:auto!important}}@media (max-width: 1199.98px){.navbar-expand-xl .navbar-collapse{display:none!important}.navbar-expand-xl .navbar-collapse.show{display:block!important}}@media (min-width: 1200px){.navbar-expand-xl .collapse.navbar-collapse:not(.show){display:flex!important;height:auto!important}}@media (max-width: 1399.98px){.navbar-expand-xxl .navbar-collapse{display:none!important}.navbar-expand-xxl .navbar-collapse.show{display:block!important}}@media (min-width: 1400px){.navbar-expand-xxl .collapse.navbar-collapse:not(.show){display:flex!important;height:auto!important}}.navbar-expand .navbar-collapse{display:none!important}.navbar-expand .navbar-collapse.show{display:block!important}.navbar-expand .collapse.navbar-collapse:not(.show){display:flex!important;height:auto!important}.tooltip .tooltip_arrow{width:0;height:0;border-style:solid;position:absolute;margin:5px}.tooltip[data-popper-placement^=top] .tooltip_arrow{border-width:5px 5px 0 5px;border-color:#6d6d6d rgba(0,0,0,0) rgba(0,0,0,0) rgba(0,0,0,0);bottom:-5px;left:calc(50% - 5px);margin-top:0;margin-bottom:0;left:-5px!important}.tooltip[data-popper-placement^=bottom] .tooltip_arrow{border-width:0 5px 5px 5px;border-color:rgba(0,0,0,0) rgba(0,0,0,0) #6d6d6d rgba(0,0,0,0);top:-5px;left:calc(50% - 5px);margin-top:0;margin-bottom:0;left:-5px!important}.tooltip[data-popper-placement^=right] .tooltip_arrow{border-width:5px 5px 5px 0;border-color:rgba(0,0,0,0) #6d6d6d rgba(0,0,0,0) rgba(0,0,0,0);left:-5px;top:calc(50% - 5px);margin-left:0;margin-right:0;top:-5px!important}.tooltip[data-popper-placement^=left] .tooltip_arrow{border-width:5px 0 5px 5px;border-color:rgba(0,0,0,0) rgba(0,0,0,0) rgba(0,0,0,0) #6d6d6d;right:-5px;top:calc(50% - 5px);margin-left:0;margin-right:0;top:-5px!important}.fade-leave-active,.fade-enter-active{transition:opacity .2s linear}.fade-enter-to,.fade-leave-from{opacity:1}.tooltip{position:absolute}.popover .popover_arrow{width:0;height:0;border-style:solid;position:absolute;margin:5px;color:#0000}.popover[data-popper-placement^=top] .popover_arrow{border-width:10px 10px 0 10px;border-color:#d6d6d6 rgba(0,0,0,0) rgba(0,0,0,0) rgba(0,0,0,0);bottom:-10px;margin-bottom:0;left:-10px!important}.popover[data-popper-placement^=top] .popover_arrow:before{content:"";display:inline-block;position:absolute;left:-10px;bottom:1.5px;border:solid;border-width:10px 10px 0 10px;border-color:#fff rgba(0,0,0,0) rgba(0,0,0,0) rgba(0,0,0,0)}.popover[data-popper-placement^=bottom] .popover_arrow{border-width:0 10px 10px 10px;border-color:rgba(0,0,0,0) rgba(0,0,0,0) #d6d6d6 rgba(0,0,0,0);top:-10px;margin-top:0;left:-10px!important}.popover[data-popper-placement^=bottom] .popover_arrow:before{content:"";display:inline-block;position:absolute;left:-10px;top:1.45px;border:solid;border-width:0 10px 10px 10px;border-color:rgba(0,0,0,0) rgba(0,0,0,0) #fff rgba(0,0,0,0)}.popover[data-popper-placement^=right] .popover_arrow{border-width:10px 10px 10px 0;border-color:rgba(0,0,0,0) #d6d6d6 rgba(0,0,0,0) rgba(0,0,0,0);left:-10px;margin-left:0;top:-10px!important}.popover[data-popper-placement^=right] .popover_arrow:before{content:"";display:inline-block;position:absolute;top:-10px;left:1.45px;border:solid;border-width:10px 10px 10px 0;border-color:rgba(0,0,0,0) #fff rgba(0,0,0,0) rgba(0,0,0,0)}.popover[data-popper-placement^=left] .popover_arrow{border-width:10px 0 10px 10px;border-color:rgba(0,0,0,0) rgba(0,0,0,0) rgba(0,0,0,0) #d6d6d6;right:-10px;margin-right:0;top:-10px!important}.popover[data-popper-placement^=left] .popover_arrow:before{content:"";display:inline-block;position:absolute;top:-10px;right:1.45px;border:solid;border-width:10px 0 10px 10px;border-color:rgba(0,0,0,0) rgba(0,0,0,0) rgba(0,0,0,0) #fff}.popover{position:absolute}.nav-pills.menu-sidebar .nav-link{border-left:0 solid rgba(0,0,0,0)}.valid-feedback{width:auto}.is-valid .form-outline .form-control~.form-label{color:#00b74a}.is-valid .form-outline .form-control~.form-notch .form-notch-leading,.is-valid .form-outline .form-control~.form-notch .form-notch-middle,.is-valid .form-outline .form-control~.form-notch .form-notch-trailing{border-color:#00b74a}.is-valid .form-outline .form-control:focus~.form-notch .form-notch-middle,.is-valid .form-outline .form-control.active~.form-notch .form-notch-middle{border-top:1px solid rgba(0,0,0,0)}.is-valid .form-outline .form-control:focus~.form-notch .form-notch-middle{box-shadow:0 1px #00b74a}.is-valid .form-outline .form-control:focus~.form-notch .form-notch-leading{box-shadow:-1px 0 #00b74a,0 1px #00b74a,0 -1px #00b74a}.is-valid .form-outline .form-control:focus~.form-notch .form-notch-trailing{box-shadow:1px 0 #00b74a,0 -1px #00b74a,0 1px #00b74a}.is-valid .form-outline .form-control.select-input.focused~.form-notch .form-notch-leading{box-shadow:-1px 0 #00b74a,0 1px #00b74a,0 -1px #00b74a}.is-valid .form-outline .form-control.select-input.focused~.form-notch .form-notch-middle{box-shadow:0 1px #00b74a;border-top:1px solid rgba(0,0,0,0)}.is-valid .form-outline .form-control.select-input.focused~.form-notch .form-notch-trailing{box-shadow:1px 0 #00b74a,0 -1px #00b74a,0 1px #00b74a}.is-invalid .form-outline .form-control~.form-label{color:#f93154}.is-invalid .form-outline .form-control~.form-notch .form-notch-leading,.is-invalid .form-outline .form-control~.form-notch .form-notch-middle,.is-invalid .form-outline .form-control~.form-notch .form-notch-trailing{border-color:#f93154}.is-invalid .form-outline .form-control:focus~.form-notch .form-notch-middle,.is-invalid .form-outline .form-control.active~.form-notch .form-notch-middle{border-top:1px solid rgba(0,0,0,0)}.is-invalid .form-outline .form-control:focus~.form-notch .form-notch-middle{box-shadow:0 1px #f93154}.is-invalid .form-outline .form-control:focus~.form-notch .form-notch-leading{box-shadow:-1px 0 #f93154,0 1px #f93154,0 -1px #f93154}.is-invalid .form-outline .form-control:focus~.form-notch .form-notch-trailing{box-shadow:1px 0 #f93154,0 -1px #f93154,0 1px #f93154}.is-invalid .form-outline .form-control.select-input.focused~.form-notch .form-notch-leading{box-shadow:-1px 0 #f93154,0 1px #f93154,0 -1px #f93154}.is-invalid .form-outline .form-control.select-input.focused~.form-notch .form-notch-middle{box-shadow:0 1px #f93154;border-top:1px solid rgba(0,0,0,0)}.is-invalid .form-outline .form-control.select-input.focused~.form-notch .form-notch-trailing{box-shadow:1px 0 #f93154,0 -1px #f93154,0 1px #f93154}.nav-tabs .nav-link,.nav-pills .nav-link{cursor:pointer}.input-group .btn-group{box-shadow:none}.input-group:not(.has-validation)>.btn-group:not(:last-child)>:not(:last-child):not(.dropdown-menu),.input-group:not(.has-validation)>.btn-group:not(:last-child)>.dropdown-toggle:last-child,.input-group:not(.has-validation)>.btn-group:not(:last-child) .dropdown-toggle:nth-last-child(n+1){border-top-right-radius:0;border-bottom-right-radius:0}.input-group.has-validation>.btn-group>:last-child:not(.dropdown-toggle):not(.dropdown-menu),.input-group.has-validation>.btn-group>.dropdown-toggle:last-child{border-top-right-radius:0;border-bottom-right-radius:0}.input-group>.btn-group:last-child>:first-child:not(.dropdown-menu){border-top-left-radius:0;border-bottom-left-radius:0}.input-group-text{min-height:calc(2.08rem + 2px);height:calc(2.08rem + 2px)}.input-group-lg .input-group-text{height:calc(2.645rem + 2px);font-size:1rem}.input-group-sm .input-group-text{min-height:calc(1.66rem + 2px);height:calc(1.66rem + 2px);font-size:.775rem;line-height:1.5}.form-outline .form-control:focus~.form-label~.form-label{transform:none;color:#0009}.modal-scrollbar-measure{position:absolute;top:-9999px;width:50px;height:50px;overflow:scroll}.modal-open{overflow:hidden}.modal-open .modal{overflow-x:hidden;overflow-y:auto}h1[data-v-ce99c8e5]{margin-top:2rem}.card[data-v-ce99c8e5]{margin-bottom:2rem}.status-message[data-v-ce99c8e5]{font-style:italic}.fork[data-v-ce99c8e5]{float:right;margin-top:-3em} diff --git a/assets/index-e9594049.js b/assets/index-e9594049.js deleted file mode 100644 index fc84bc5..0000000 --- a/assets/index-e9594049.js +++ /dev/null @@ -1,216 +0,0 @@ -var BB=Object.defineProperty;var UB=(t,e,u)=>e in t?BB(t,e,{enumerable:!0,configurable:!0,writable:!0,value:u}):t[e]=u;var wr=(t,e,u)=>(UB(t,typeof e!="symbol"?e+"":e,u),u),bg=(t,e,u)=>{if(!e.has(t))throw TypeError("Cannot "+u)};var _e=(t,e,u)=>(bg(t,e,"read from private field"),u?u.call(t):e.get(t)),xt=(t,e,u)=>{if(e.has(t))throw TypeError("Cannot add the same private member more than once");e instanceof WeakSet?e.add(t):e.set(t,u)},_t=(t,e,u,s)=>(bg(t,e,"write to private field"),s?s.call(t,u):e.set(t,u),u);var $y=(t,e,u,s)=>({set _(n){_t(t,e,n,u)},get _(){return _e(t,e,s)}}),ct=(t,e,u)=>(bg(t,e,"access private method"),u);(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const n of document.querySelectorAll('link[rel="modulepreload"]'))s(n);new MutationObserver(n=>{for(const r of n)if(r.type==="childList")for(const a of r.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&s(a)}).observe(document,{childList:!0,subtree:!0});function u(n){const r={};return n.integrity&&(r.integrity=n.integrity),n.referrerPolicy&&(r.referrerPolicy=n.referrerPolicy),n.crossOrigin==="use-credentials"?r.credentials="include":n.crossOrigin==="anonymous"?r.credentials="omit":r.credentials="same-origin",r}function s(n){if(n.ep)return;n.ep=!0;const r=u(n);fetch(n.href,r)}})();function S3(t,e){const u=Object.create(null),s=t.split(",");for(let n=0;n!!u[n.toLowerCase()]:n=>!!u[n]}const yr={},Eo=[],wi=()=>{},HB=()=>!1,$B=/^on[^a-z]/,rb=t=>$B.test(t),T3=t=>t.startsWith("onUpdate:"),Wr=Object.assign,A3=(t,e)=>{const u=t.indexOf(e);u>-1&&t.splice(u,1)},QB=Object.prototype.hasOwnProperty,Qt=(t,e)=>QB.call(t,e),Rt=Array.isArray,Oo=t=>nb(t)==="[object Map]",PM=t=>nb(t)==="[object Set]",Pt=t=>typeof t=="function",qr=t=>typeof t=="string",E3=t=>typeof t=="symbol",Sr=t=>t!==null&&typeof t=="object",DM=t=>Sr(t)&&Pt(t.then)&&Pt(t.catch),NM=Object.prototype.toString,nb=t=>NM.call(t),VB=t=>nb(t).slice(8,-1),CM=t=>nb(t)==="[object Object]",O3=t=>qr(t)&&t!=="NaN"&&t[0]!=="-"&&""+parseInt(t,10)===t,R1=S3(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),ib=t=>{const e=Object.create(null);return u=>e[u]||(e[u]=t(u))},kB=/-(\w)/g,Qi=ib(t=>t.replace(kB,(e,u)=>u?u.toUpperCase():"")),zB=/\B([A-Z])/g,Vo=ib(t=>t.replace(zB,"-$1").toLowerCase()),ab=ib(t=>t.charAt(0).toUpperCase()+t.slice(1)),gg=ib(t=>t?`on${ab(t)}`:""),F0=(t,e)=>!Object.is(t,e),mg=(t,e)=>{for(let u=0;u{Object.defineProperty(t,e,{configurable:!0,enumerable:!1,value:u})},GB=t=>{const e=parseFloat(t);return isNaN(e)?t:e};let RA;const NS=()=>RA||(RA=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function qa(t){if(Rt(t)){const e={};for(let u=0;u{if(u){const s=u.split(JB);s.length>1&&(e[s[0].trim()]=s[1].trim())}}),e}function rn(t){let e="";if(qr(t))e=t;else if(Rt(t))for(let u=0;uqr(t)?t:t==null?"":Rt(t)||Sr(t)&&(t.toString===NM||!Pt(t.toString))?JSON.stringify(t,LM,2):String(t),LM=(t,e)=>e&&e.__v_isRef?LM(t,e.value):Oo(e)?{[`Map(${e.size})`]:[...e.entries()].reduce((u,[s,n])=>(u[`${s} =>`]=n,u),{})}:PM(e)?{[`Set(${e.size})`]:[...e.values()]}:Sr(e)&&!Rt(e)&&!CM(e)?String(e):e;let gi;class eU{constructor(e=!1){this.detached=e,this._active=!0,this.effects=[],this.cleanups=[],this.parent=gi,!e&&gi&&(this.index=(gi.scopes||(gi.scopes=[])).push(this)-1)}get active(){return this._active}run(e){if(this._active){const u=gi;try{return gi=this,e()}finally{gi=u}}}on(){gi=this}off(){gi=this.parent}stop(e){if(this._active){let u,s;for(u=0,s=this.effects.length;u{const e=new Set(t);return e.w=0,e.n=0,e},MM=t=>(t.w&Qa)>0,FM=t=>(t.n&Qa)>0,nU=({deps:t})=>{if(t.length)for(let e=0;e{const{deps:e}=t;if(e.length){let u=0;for(let s=0;s{(d==="length"||d>=l)&&o.push(c)})}else switch(u!==void 0&&o.push(a.get(u)),e){case"add":Rt(t)?O3(u)&&o.push(a.get("length")):(o.push(a.get(Qs)),Oo(t)&&o.push(a.get(LS)));break;case"delete":Rt(t)||(o.push(a.get(Qs)),Oo(t)&&o.push(a.get(LS)));break;case"set":Oo(t)&&o.push(a.get(Qs));break}if(o.length===1)o[0]&&MS(o[0]);else{const l=[];for(const c of o)c&&l.push(...c);MS(R3(l))}}function MS(t,e){const u=Rt(t)?t:[...t];for(const s of u)s.computed&&IA(s);for(const s of u)s.computed||IA(s)}function IA(t,e){(t!==mi||t.allowRecurse)&&(t.scheduler?t.scheduler():t.run())}const aU=S3("__proto__,__v_isRef,__isVue"),UM=new Set(Object.getOwnPropertyNames(Symbol).filter(t=>t!=="arguments"&&t!=="caller").map(t=>Symbol[t]).filter(E3)),sU=I3(),oU=I3(!1,!0),uU=I3(!0),PA=cU();function cU(){const t={};return["includes","indexOf","lastIndexOf"].forEach(e=>{t[e]=function(...u){const s=Gt(this);for(let r=0,a=this.length;r{t[e]=function(...u){ko();const s=Gt(this)[e].apply(this,u);return zo(),s}}),t}function lU(t){const e=Gt(this);return Bn(e,"has",t),e.hasOwnProperty(t)}function I3(t=!1,e=!1){return function(s,n,r){if(n==="__v_isReactive")return!t;if(n==="__v_isReadonly")return t;if(n==="__v_isShallow")return e;if(n==="__v_raw"&&r===(t?e?OU:kM:e?VM:QM).get(s))return s;const a=Rt(s);if(!t){if(a&&Qt(PA,n))return Reflect.get(PA,n,r);if(n==="hasOwnProperty")return lU}const o=Reflect.get(s,n,r);return(E3(n)?UM.has(n):aU(n))||(t||Bn(s,"get",n),e)?o:dn(o)?a&&O3(n)?o:o.value:Sr(o)?t?GM(o):ob(o):o}}const dU=HM(),fU=HM(!0);function HM(t=!1){return function(u,s,n,r){let a=u[s];if(Po(a)&&dn(a)&&!dn(n))return!1;if(!t&&(!Q1(n)&&!Po(n)&&(a=Gt(a),n=Gt(n)),!Rt(u)&&dn(a)&&!dn(n)))return a.value=n,!0;const o=Rt(u)&&O3(s)?Number(s)t,sb=t=>Reflect.getPrototypeOf(t);function Qy(t,e,u=!1,s=!1){t=t.__v_raw;const n=Gt(t),r=Gt(e);u||(e!==r&&Bn(n,"get",e),Bn(n,"get",r));const{has:a}=sb(n),o=s?P3:u?C3:q0;if(a.call(n,e))return o(t.get(e));if(a.call(n,r))return o(t.get(r));t!==n&&t.get(e)}function Vy(t,e=!1){const u=this.__v_raw,s=Gt(u),n=Gt(t);return e||(t!==n&&Bn(s,"has",t),Bn(s,"has",n)),t===n?u.has(t):u.has(t)||u.has(n)}function ky(t,e=!1){return t=t.__v_raw,!e&&Bn(Gt(t),"iterate",Qs),Reflect.get(t,"size",t)}function DA(t){t=Gt(t);const e=Gt(this);return sb(e).has.call(e,t)||(e.add(t),ma(e,"add",t,t)),this}function NA(t,e){e=Gt(e);const u=Gt(this),{has:s,get:n}=sb(u);let r=s.call(u,t);r||(t=Gt(t),r=s.call(u,t));const a=n.call(u,t);return u.set(t,e),r?F0(e,a)&&ma(u,"set",t,e):ma(u,"add",t,e),this}function CA(t){const e=Gt(this),{has:u,get:s}=sb(e);let n=u.call(e,t);n||(t=Gt(t),n=u.call(e,t)),s&&s.call(e,t);const r=e.delete(t);return n&&ma(e,"delete",t,void 0),r}function jA(){const t=Gt(this),e=t.size!==0,u=t.clear();return e&&ma(t,"clear",void 0,void 0),u}function zy(t,e){return function(s,n){const r=this,a=r.__v_raw,o=Gt(a),l=e?P3:t?C3:q0;return!t&&Bn(o,"iterate",Qs),a.forEach((c,d)=>s.call(n,l(c),l(d),r))}}function Gy(t,e,u){return function(...s){const n=this.__v_raw,r=Gt(n),a=Oo(r),o=t==="entries"||t===Symbol.iterator&&a,l=t==="keys"&&a,c=n[t](...s),d=u?P3:e?C3:q0;return!e&&Bn(r,"iterate",l?LS:Qs),{next(){const{value:h,done:f}=c.next();return f?{value:h,done:f}:{value:o?[d(h[0]),d(h[1])]:d(h),done:f}},[Symbol.iterator](){return this}}}}function Oa(t){return function(...e){return t==="delete"?!1:this}}function mU(){const t={get(r){return Qy(this,r)},get size(){return ky(this)},has:Vy,add:DA,set:NA,delete:CA,clear:jA,forEach:zy(!1,!1)},e={get(r){return Qy(this,r,!1,!0)},get size(){return ky(this)},has:Vy,add:DA,set:NA,delete:CA,clear:jA,forEach:zy(!1,!0)},u={get(r){return Qy(this,r,!0)},get size(){return ky(this,!0)},has(r){return Vy.call(this,r,!0)},add:Oa("add"),set:Oa("set"),delete:Oa("delete"),clear:Oa("clear"),forEach:zy(!0,!1)},s={get(r){return Qy(this,r,!0,!0)},get size(){return ky(this,!0)},has(r){return Vy.call(this,r,!0)},add:Oa("add"),set:Oa("set"),delete:Oa("delete"),clear:Oa("clear"),forEach:zy(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(r=>{t[r]=Gy(r,!1,!1),u[r]=Gy(r,!0,!1),e[r]=Gy(r,!1,!0),s[r]=Gy(r,!0,!0)}),[t,u,e,s]}const[_U,vU,wU,SU]=mU();function D3(t,e){const u=e?t?SU:wU:t?vU:_U;return(s,n,r)=>n==="__v_isReactive"?!t:n==="__v_isReadonly"?t:n==="__v_raw"?s:Reflect.get(Qt(u,n)&&n in s?u:s,n,r)}const TU={get:D3(!1,!1)},AU={get:D3(!1,!0)},EU={get:D3(!0,!1)},QM=new WeakMap,VM=new WeakMap,kM=new WeakMap,OU=new WeakMap;function RU(t){switch(t){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function xU(t){return t.__v_skip||!Object.isExtensible(t)?0:RU(VB(t))}function ob(t){return Po(t)?t:N3(t,!1,$M,TU,QM)}function zM(t){return N3(t,!1,gU,AU,VM)}function GM(t){return N3(t,!0,bU,EU,kM)}function N3(t,e,u,s,n){if(!Sr(t)||t.__v_raw&&!(e&&t.__v_isReactive))return t;const r=n.get(t);if(r)return r;const a=xU(t);if(a===0)return t;const o=new Proxy(t,a===2?s:u);return n.set(t,o),o}function Ro(t){return Po(t)?Ro(t.__v_raw):!!(t&&t.__v_isReactive)}function Po(t){return!!(t&&t.__v_isReadonly)}function Q1(t){return!!(t&&t.__v_isShallow)}function WM(t){return Ro(t)||Po(t)}function Gt(t){const e=t&&t.__v_raw;return e?Gt(e):t}function JM(t){return $1(t,"__v_skip",!0),t}const q0=t=>Sr(t)?ob(t):t,C3=t=>Sr(t)?GM(t):t;function XM(t){Ba&&mi&&(t=Gt(t),BM(t.dep||(t.dep=R3())))}function KM(t,e){t=Gt(t);const u=t.dep;u&&MS(u)}function dn(t){return!!(t&&t.__v_isRef===!0)}function En(t){return YM(t,!1)}function IU(t){return YM(t,!0)}function YM(t,e){return dn(t)?t:new PU(t,e)}class PU{constructor(e,u){this.__v_isShallow=u,this.dep=void 0,this.__v_isRef=!0,this._rawValue=u?e:Gt(e),this._value=u?e:q0(e)}get value(){return XM(this),this._value}set value(e){const u=this.__v_isShallow||Q1(e)||Po(e);e=u?e:Gt(e),F0(e,this._rawValue)&&(this._rawValue=e,this._value=u?e:q0(e),KM(this))}}function qt(t){return dn(t)?t.value:t}const DU={get:(t,e,u)=>qt(Reflect.get(t,e,u)),set:(t,e,u,s)=>{const n=t[e];return dn(n)&&!dn(u)?(n.value=u,!0):Reflect.set(t,e,u,s)}};function ZM(t){return Ro(t)?t:new Proxy(t,DU)}class NU{constructor(e,u,s,n){this._setter=u,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this._dirty=!0,this.effect=new x3(e,()=>{this._dirty||(this._dirty=!0,KM(this))}),this.effect.computed=this,this.effect.active=this._cacheable=!n,this.__v_isReadonly=s}get value(){const e=Gt(this);return XM(e),(e._dirty||!e._cacheable)&&(e._dirty=!1,e._value=e.effect.run()),e._value}set value(e){this._setter(e)}}function CU(t,e,u=!1){let s,n;const r=Pt(t);return r?(s=t,n=wi):(s=t.get,n=t.set),new NU(s,n,r||!n,u)}function Ua(t,e,u,s){let n;try{n=s?t(...s):t()}catch(r){ub(r,e,u)}return n}function Si(t,e,u,s){if(Pt(t)){const r=Ua(t,e,u,s);return r&&DM(r)&&r.catch(a=>{ub(a,e,u)}),r}const n=[];for(let r=0;r>>1;U0(ln[s])Ui&&ln.splice(e,1)}function FU(t){Rt(t)?xo.push(...t):(!ba||!ba.includes(t,t.allowRecurse?Fs+1:Fs))&&xo.push(t),r9()}function LA(t,e=B0?Ui+1:0){for(;eU0(u)-U0(s)),Fs=0;Fst.id==null?1/0:t.id,qU=(t,e)=>{const u=U0(t)-U0(e);if(u===0){if(t.pre&&!e.pre)return-1;if(e.pre&&!t.pre)return 1}return u};function i9(t){FS=!1,B0=!0,ln.sort(qU);const e=wi;try{for(Ui=0;Uiqr(p)?p.trim():p)),h&&(n=u.map(GB))}let o,l=s[o=gg(e)]||s[o=gg(Qi(e))];!l&&r&&(l=s[o=gg(Vo(e))]),l&&Si(l,t,6,n);const c=s[o+"Once"];if(c){if(!t.emitted)t.emitted={};else if(t.emitted[o])return;t.emitted[o]=!0,Si(c,t,6,n)}}function a9(t,e,u=!1){const s=e.emitsCache,n=s.get(t);if(n!==void 0)return n;const r=t.emits;let a={},o=!1;if(!Pt(t)){const l=c=>{const d=a9(c,e,!0);d&&(o=!0,Wr(a,d))};!u&&e.mixins.length&&e.mixins.forEach(l),t.extends&&l(t.extends),t.mixins&&t.mixins.forEach(l)}return!r&&!o?(Sr(t)&&s.set(t,null),null):(Rt(r)?r.forEach(l=>a[l]=null):Wr(a,r),Sr(t)&&s.set(t,a),a)}function cb(t,e){return!t||!rb(e)?!1:(e=e.slice(2).replace(/Once$/,""),Qt(t,e[0].toLowerCase()+e.slice(1))||Qt(t,Vo(e))||Qt(t,e))}let nn=null,lb=null;function V1(t){const e=nn;return nn=t,lb=t&&t.type.__scopeId||null,e}function UU(t){lb=t}function HU(){lb=null}function Lr(t,e=nn,u){if(!e||t._n)return t;const s=(...n)=>{s._d&&GA(-1);const r=V1(e);let a;try{a=t(...n)}finally{V1(r),s._d&&GA(1)}return a};return s._n=!0,s._c=!0,s._d=!0,s}function _g(t){const{type:e,vnode:u,proxy:s,withProxy:n,props:r,propsOptions:[a],slots:o,attrs:l,emit:c,render:d,renderCache:h,data:f,setupState:p,ctx:y,inheritAttrs:b}=t;let m,g;const v=V1(t);try{if(u.shapeFlag&4){const w=n||s;m=Bi(d.call(w,w,h,r,p,f,y)),g=l}else{const w=e;m=Bi(w.length>1?w(r,{attrs:l,slots:o,emit:c}):w(r,null)),g=e.props?l:$U(l)}}catch(w){C0.length=0,ub(w,t,1),m=ir(Va)}let _=m;if(g&&b!==!1){const w=Object.keys(g),{shapeFlag:S}=_;w.length&&S&7&&(a&&w.some(T3)&&(g=QU(g,a)),_=Do(_,g))}return u.dirs&&(_=Do(_),_.dirs=_.dirs?_.dirs.concat(u.dirs):u.dirs),u.transition&&(_.transition=u.transition),m=_,V1(v),m}const $U=t=>{let e;for(const u in t)(u==="class"||u==="style"||rb(u))&&((e||(e={}))[u]=t[u]);return e},QU=(t,e)=>{const u={};for(const s in t)(!T3(s)||!(s.slice(9)in e))&&(u[s]=t[s]);return u};function VU(t,e,u){const{props:s,children:n,component:r}=t,{props:a,children:o,patchFlag:l}=e,c=r.emitsOptions;if(e.dirs||e.transition)return!0;if(u&&l>=0){if(l&1024)return!0;if(l&16)return s?MA(s,a,c):!!a;if(l&8){const d=e.dynamicProps;for(let h=0;ht.__isSuspense;function GU(t,e){e&&e.pendingBranch?Rt(t)?e.effects.push(...t):e.effects.push(t):FU(t)}function s9(t,e){return M3(t,null,e)}const Wy={};function Io(t,e,u){return M3(t,e,u)}function M3(t,e,{immediate:u,deep:s,flush:n,onTrack:r,onTrigger:a}=yr){var o;const l=rU()===((o=Gr)==null?void 0:o.scope)?Gr:null;let c,d=!1,h=!1;if(dn(t)?(c=()=>t.value,d=Q1(t)):Ro(t)?(c=()=>t,s=!0):Rt(t)?(h=!0,d=t.some(w=>Ro(w)||Q1(w)),c=()=>t.map(w=>{if(dn(w))return w.value;if(Ro(w))return Hs(w);if(Pt(w))return Ua(w,l,2)})):Pt(t)?e?c=()=>Ua(t,l,2):c=()=>{if(!(l&&l.isUnmounted))return f&&f(),Si(t,l,3,[p])}:c=wi,e&&s){const w=c;c=()=>Hs(w())}let f,p=w=>{f=v.onStop=()=>{Ua(w,l,4)}},y;if($0)if(p=wi,e?u&&Si(e,l,3,[c(),h?[]:void 0,p]):c(),n==="sync"){const w=FH();y=w.__watcherHandles||(w.__watcherHandles=[])}else return wi;let b=h?new Array(t.length).fill(Wy):Wy;const m=()=>{if(v.active)if(e){const w=v.run();(s||d||(h?w.some((S,A)=>F0(S,b[A])):F0(w,b)))&&(f&&f(),Si(e,l,3,[w,b===Wy?void 0:h&&b[0]===Wy?[]:b,p]),b=w)}else v.run()};m.allowRecurse=!!e;let g;n==="sync"?g=m:n==="post"?g=()=>qn(m,l&&l.suspense):(m.pre=!0,l&&(m.id=l.uid),g=()=>L3(m));const v=new x3(c,g);e?u?m():b=v.run():n==="post"?qn(v.run.bind(v),l&&l.suspense):v.run();const _=()=>{v.stop(),l&&l.scope&&A3(l.scope.effects,v)};return y&&y.push(_),_}function WU(t,e,u){const s=this.proxy,n=qr(t)?t.includes(".")?o9(s,t):()=>s[t]:t.bind(s,s);let r;Pt(e)?r=e:(r=e.handler,u=e);const a=Gr;No(this);const o=M3(n,r.bind(s),u);return a?No(a):Vs(),o}function o9(t,e){const u=e.split(".");return()=>{let s=t;for(let n=0;n{Hs(u,e)});else if(CM(t))for(const u in t)Hs(t[u],e);return t}function k1(t,e){const u=nn;if(u===null)return t;const s=pb(u)||u.proxy,n=t.dirs||(t.dirs=[]);for(let r=0;rWr({name:t.name},e,{setup:t}))():t}const D0=t=>!!t.type.__asyncLoader,u9=t=>t.type.__isKeepAlive;function JU(t,e){c9(t,"a",e)}function XU(t,e){c9(t,"da",e)}function c9(t,e,u=Gr){const s=t.__wdc||(t.__wdc=()=>{let n=u;for(;n;){if(n.isDeactivated)return;n=n.parent}return t()});if(db(e,s,u),u){let n=u.parent;for(;n&&n.parent;)u9(n.parent.vnode)&&KU(s,e,u,n),n=n.parent}}function KU(t,e,u,s){const n=db(e,t,s,!0);F3(()=>{A3(s[e],n)},u)}function db(t,e,u=Gr,s=!1){if(u){const n=u[t]||(u[t]=[]),r=e.__weh||(e.__weh=(...a)=>{if(u.isUnmounted)return;ko(),No(u);const o=Si(e,u,t,a);return Vs(),zo(),o});return s?n.unshift(r):n.push(r),r}}const wa=t=>(e,u=Gr)=>(!$0||t==="sp")&&db(t,(...s)=>e(...s),u),YU=wa("bm"),l9=wa("m"),ZU=wa("bu"),d9=wa("u"),eH=wa("bum"),F3=wa("um"),tH=wa("sp"),rH=wa("rtg"),nH=wa("rtc");function iH(t,e=Gr){db("ec",t,e)}const q3="components";function po(t,e){return h9(q3,t,!0,e)||t}const f9=Symbol.for("v-ndc");function Wa(t){return qr(t)?h9(q3,t,!1)||t:t||f9}function h9(t,e,u=!0,s=!1){const n=nn||Gr;if(n){const r=n.type;if(t===q3){const o=jH(r,!1);if(o&&(o===e||o===Qi(e)||o===ab(Qi(e))))return r}const a=FA(n[t]||r[t],e)||FA(n.appContext[t],e);return!a&&s?r:a}}function FA(t,e){return t&&(t[e]||t[Qi(e)]||t[ab(Qi(e))])}function qA(t,e,u,s){let n;const r=u&&u[s];if(Rt(t)||qr(t)){n=new Array(t.length);for(let a=0,o=t.length;ae(a,o,void 0,r&&r[o]));else{const a=Object.keys(t);n=new Array(a.length);for(let o=0,l=a.length;oW1(e)?!(e.type===Va||e.type===Rn&&!p9(e.children)):!0)?t:null}const qS=t=>t?E9(t)?pb(t)||t.proxy:qS(t.parent):null,N0=Wr(Object.create(null),{$:t=>t,$el:t=>t.vnode.el,$data:t=>t.data,$props:t=>t.props,$attrs:t=>t.attrs,$slots:t=>t.slots,$refs:t=>t.refs,$parent:t=>qS(t.parent),$root:t=>qS(t.root),$emit:t=>t.emit,$options:t=>B3(t),$forceUpdate:t=>t.f||(t.f=()=>L3(t.update)),$nextTick:t=>t.n||(t.n=t9.bind(t.proxy)),$watch:t=>WU.bind(t)}),vg=(t,e)=>t!==yr&&!t.__isScriptSetup&&Qt(t,e),aH={get({_:t},e){const{ctx:u,setupState:s,data:n,props:r,accessCache:a,type:o,appContext:l}=t;let c;if(e[0]!=="$"){const p=a[e];if(p!==void 0)switch(p){case 1:return s[e];case 2:return n[e];case 4:return u[e];case 3:return r[e]}else{if(vg(s,e))return a[e]=1,s[e];if(n!==yr&&Qt(n,e))return a[e]=2,n[e];if((c=t.propsOptions[0])&&Qt(c,e))return a[e]=3,r[e];if(u!==yr&&Qt(u,e))return a[e]=4,u[e];BS&&(a[e]=0)}}const d=N0[e];let h,f;if(d)return e==="$attrs"&&Bn(t,"get",e),d(t);if((h=o.__cssModules)&&(h=h[e]))return h;if(u!==yr&&Qt(u,e))return a[e]=4,u[e];if(f=l.config.globalProperties,Qt(f,e))return f[e]},set({_:t},e,u){const{data:s,setupState:n,ctx:r}=t;return vg(n,e)?(n[e]=u,!0):s!==yr&&Qt(s,e)?(s[e]=u,!0):Qt(t.props,e)||e[0]==="$"&&e.slice(1)in t?!1:(r[e]=u,!0)},has({_:{data:t,setupState:e,accessCache:u,ctx:s,appContext:n,propsOptions:r}},a){let o;return!!u[a]||t!==yr&&Qt(t,a)||vg(e,a)||(o=r[0])&&Qt(o,a)||Qt(s,a)||Qt(N0,a)||Qt(n.config.globalProperties,a)},defineProperty(t,e,u){return u.get!=null?t._.accessCache[e]=0:Qt(u,"value")&&this.set(t,e,u.value,null),Reflect.defineProperty(t,e,u)}};function sH(){return oH().attrs}function oH(){const t=PH();return t.setupContext||(t.setupContext=R9(t))}function BA(t){return Rt(t)?t.reduce((e,u)=>(e[u]=null,e),{}):t}let BS=!0;function uH(t){const e=B3(t),u=t.proxy,s=t.ctx;BS=!1,e.beforeCreate&&UA(e.beforeCreate,t,"bc");const{data:n,computed:r,methods:a,watch:o,provide:l,inject:c,created:d,beforeMount:h,mounted:f,beforeUpdate:p,updated:y,activated:b,deactivated:m,beforeDestroy:g,beforeUnmount:v,destroyed:_,unmounted:w,render:S,renderTracked:A,renderTriggered:D,errorCaptured:L,serverPrefetch:E,expose:O,inheritAttrs:P,components:j,directives:U,filters:M}=e;if(c&&cH(c,s,null),a)for(const Z in a){const K=a[Z];Pt(K)&&(s[Z]=K.bind(u))}if(n){const Z=n.call(u,u);Sr(Z)&&(t.data=ob(Z))}if(BS=!0,r)for(const Z in r){const K=r[Z],fe=Pt(K)?K.bind(u,u):Pt(K.get)?K.get.bind(u,u):wi,X=!Pt(K)&&Pt(K.set)?K.set.bind(u):wi,he=sr({get:fe,set:X});Object.defineProperty(s,Z,{enumerable:!0,configurable:!0,get:()=>he.value,set:xe=>he.value=xe})}if(o)for(const Z in o)y9(o[Z],s,u,Z);if(l){const Z=Pt(l)?l.call(u):l;Reflect.ownKeys(Z).forEach(K=>{x1(K,Z[K])})}d&&UA(d,t,"c");function Q(Z,K){Rt(K)?K.forEach(fe=>Z(fe.bind(u))):K&&Z(K.bind(u))}if(Q(YU,h),Q(l9,f),Q(ZU,p),Q(d9,y),Q(JU,b),Q(XU,m),Q(iH,L),Q(nH,A),Q(rH,D),Q(eH,v),Q(F3,w),Q(tH,E),Rt(O))if(O.length){const Z=t.exposed||(t.exposed={});O.forEach(K=>{Object.defineProperty(Z,K,{get:()=>u[K],set:fe=>u[K]=fe})})}else t.exposed||(t.exposed={});S&&t.render===wi&&(t.render=S),P!=null&&(t.inheritAttrs=P),j&&(t.components=j),U&&(t.directives=U)}function cH(t,e,u=wi){Rt(t)&&(t=US(t));for(const s in t){const n=t[s];let r;Sr(n)?"default"in n?r=Ti(n.from||s,n.default,!0):r=Ti(n.from||s):r=Ti(n),dn(r)?Object.defineProperty(e,s,{enumerable:!0,configurable:!0,get:()=>r.value,set:a=>r.value=a}):e[s]=r}}function UA(t,e,u){Si(Rt(t)?t.map(s=>s.bind(e.proxy)):t.bind(e.proxy),e,u)}function y9(t,e,u,s){const n=s.includes(".")?o9(u,s):()=>u[s];if(qr(t)){const r=e[t];Pt(r)&&Io(n,r)}else if(Pt(t))Io(n,t.bind(u));else if(Sr(t))if(Rt(t))t.forEach(r=>y9(r,e,u,s));else{const r=Pt(t.handler)?t.handler.bind(u):e[t.handler];Pt(r)&&Io(n,r,t)}}function B3(t){const e=t.type,{mixins:u,extends:s}=e,{mixins:n,optionsCache:r,config:{optionMergeStrategies:a}}=t.appContext,o=r.get(e);let l;return o?l=o:!n.length&&!u&&!s?l=e:(l={},n.length&&n.forEach(c=>z1(l,c,a,!0)),z1(l,e,a)),Sr(e)&&r.set(e,l),l}function z1(t,e,u,s=!1){const{mixins:n,extends:r}=e;r&&z1(t,r,u,!0),n&&n.forEach(a=>z1(t,a,u,!0));for(const a in e)if(!(s&&a==="expose")){const o=lH[a]||u&&u[a];t[a]=o?o(t[a],e[a]):e[a]}return t}const lH={data:HA,props:$A,emits:$A,methods:g0,computed:g0,beforeCreate:Tn,created:Tn,beforeMount:Tn,mounted:Tn,beforeUpdate:Tn,updated:Tn,beforeDestroy:Tn,beforeUnmount:Tn,destroyed:Tn,unmounted:Tn,activated:Tn,deactivated:Tn,errorCaptured:Tn,serverPrefetch:Tn,components:g0,directives:g0,watch:fH,provide:HA,inject:dH};function HA(t,e){return e?t?function(){return Wr(Pt(t)?t.call(this,this):t,Pt(e)?e.call(this,this):e)}:e:t}function dH(t,e){return g0(US(t),US(e))}function US(t){if(Rt(t)){const e={};for(let u=0;u1)return u&&Pt(e)?e.call(s&&s.proxy):e}}function yH(t,e,u,s=!1){const n={},r={};$1(r,hb,1),t.propsDefaults=Object.create(null),g9(t,e,n,r);for(const a in t.propsOptions[0])a in n||(n[a]=void 0);u?t.props=s?n:zM(n):t.type.props?t.props=n:t.props=r,t.attrs=r}function bH(t,e,u,s){const{props:n,attrs:r,vnode:{patchFlag:a}}=t,o=Gt(n),[l]=t.propsOptions;let c=!1;if((s||a>0)&&!(a&16)){if(a&8){const d=t.vnode.dynamicProps;for(let h=0;h{l=!0;const[f,p]=m9(h,e,!0);Wr(a,f),p&&o.push(...p)};!u&&e.mixins.length&&e.mixins.forEach(d),t.extends&&d(t.extends),t.mixins&&t.mixins.forEach(d)}if(!r&&!l)return Sr(t)&&s.set(t,Eo),Eo;if(Rt(r))for(let d=0;d-1,p[1]=b<0||y-1||Qt(p,"default"))&&o.push(h)}}}const c=[a,o];return Sr(t)&&s.set(t,c),c}function QA(t){return t[0]!=="$"}function VA(t){const e=t&&t.toString().match(/^\s*(function|class) (\w+)/);return e?e[2]:t===null?"null":""}function kA(t,e){return VA(t)===VA(e)}function zA(t,e){return Rt(e)?e.findIndex(u=>kA(u,t)):Pt(e)&&kA(e,t)?0:-1}const _9=t=>t[0]==="_"||t==="$stable",U3=t=>Rt(t)?t.map(Bi):[Bi(t)],gH=(t,e,u)=>{if(e._n)return e;const s=Lr((...n)=>U3(e(...n)),u);return s._c=!1,s},v9=(t,e,u)=>{const s=t._ctx;for(const n in t){if(_9(n))continue;const r=t[n];if(Pt(r))e[n]=gH(n,r,s);else if(r!=null){const a=U3(r);e[n]=()=>a}}},w9=(t,e)=>{const u=U3(e);t.slots.default=()=>u},mH=(t,e)=>{if(t.vnode.shapeFlag&32){const u=e._;u?(t.slots=Gt(e),$1(e,"_",u)):v9(e,t.slots={})}else t.slots={},e&&w9(t,e);$1(t.slots,hb,1)},_H=(t,e,u)=>{const{vnode:s,slots:n}=t;let r=!0,a=yr;if(s.shapeFlag&32){const o=e._;o?u&&o===1?r=!1:(Wr(n,e),!u&&o===1&&delete n._):(r=!e.$stable,v9(e,n)),a=e}else e&&(w9(t,e),a={default:1});if(r)for(const o in n)!_9(o)&&!(o in a)&&delete n[o]};function $S(t,e,u,s,n=!1){if(Rt(t)){t.forEach((f,p)=>$S(f,e&&(Rt(e)?e[p]:e),u,s,n));return}if(D0(s)&&!n)return;const r=s.shapeFlag&4?pb(s.component)||s.component.proxy:s.el,a=n?null:r,{i:o,r:l}=t,c=e&&e.r,d=o.refs===yr?o.refs={}:o.refs,h=o.setupState;if(c!=null&&c!==l&&(qr(c)?(d[c]=null,Qt(h,c)&&(h[c]=null)):dn(c)&&(c.value=null)),Pt(l))Ua(l,o,12,[a,d]);else{const f=qr(l),p=dn(l);if(f||p){const y=()=>{if(t.f){const b=f?Qt(h,l)?h[l]:d[l]:l.value;n?Rt(b)&&A3(b,r):Rt(b)?b.includes(r)||b.push(r):f?(d[l]=[r],Qt(h,l)&&(h[l]=d[l])):(l.value=[r],t.k&&(d[t.k]=l.value))}else f?(d[l]=a,Qt(h,l)&&(h[l]=a)):p&&(l.value=a,t.k&&(d[t.k]=a))};a?(y.id=-1,qn(y,u)):y()}}}const qn=GU;function vH(t){return wH(t)}function wH(t,e){const u=NS();u.__VUE__=!0;const{insert:s,remove:n,patchProp:r,createElement:a,createText:o,createComment:l,setText:c,setElementText:d,parentNode:h,nextSibling:f,setScopeId:p=wi,insertStaticContent:y}=t,b=(R,T,x,B=null,k=null,V=null,J=!1,z=null,Y=!!T.dynamicChildren)=>{if(R===T)return;R&&!hu(R,T)&&(B=ge(R),xe(R,k,V,!0),R=null),T.patchFlag===-2&&(Y=!1,T.dynamicChildren=null);const{type:te,ref:ce,shapeFlag:Ae}=T;switch(te){case fb:m(R,T,x,B);break;case Va:g(R,T,x,B);break;case wg:R==null&&v(T,x,B,J);break;case Rn:j(R,T,x,B,k,V,J,z,Y);break;default:Ae&1?S(R,T,x,B,k,V,J,z,Y):Ae&6?U(R,T,x,B,k,V,J,z,Y):(Ae&64||Ae&128)&&te.process(R,T,x,B,k,V,J,z,Y,oe)}ce!=null&&k&&$S(ce,R&&R.ref,V,T||R,!T)},m=(R,T,x,B)=>{if(R==null)s(T.el=o(T.children),x,B);else{const k=T.el=R.el;T.children!==R.children&&c(k,T.children)}},g=(R,T,x,B)=>{R==null?s(T.el=l(T.children||""),x,B):T.el=R.el},v=(R,T,x,B)=>{[R.el,R.anchor]=y(R.children,T,x,B,R.el,R.anchor)},_=({el:R,anchor:T},x,B)=>{let k;for(;R&&R!==T;)k=f(R),s(R,x,B),R=k;s(T,x,B)},w=({el:R,anchor:T})=>{let x;for(;R&&R!==T;)x=f(R),n(R),R=x;n(T)},S=(R,T,x,B,k,V,J,z,Y)=>{J=J||T.type==="svg",R==null?A(T,x,B,k,V,J,z,Y):E(R,T,k,V,J,z,Y)},A=(R,T,x,B,k,V,J,z)=>{let Y,te;const{type:ce,props:Ae,shapeFlag:Ie,transition:Ee,dirs:qe}=R;if(Y=R.el=a(R.type,V,Ae&&Ae.is,Ae),Ie&8?d(Y,R.children):Ie&16&&L(R.children,Y,null,B,k,V&&ce!=="foreignObject",J,z),qe&&hs(R,null,B,"created"),D(Y,R,R.scopeId,J,B),Ae){for(const F in Ae)F!=="value"&&!R1(F)&&r(Y,F,null,Ae[F],V,R.children,B,k,Ne);"value"in Ae&&r(Y,"value",null,Ae.value),(te=Ae.onVnodeBeforeMount)&&Mi(te,B,R)}qe&&hs(R,null,B,"beforeMount");const G=(!k||k&&!k.pendingBranch)&&Ee&&!Ee.persisted;G&&Ee.beforeEnter(Y),s(Y,T,x),((te=Ae&&Ae.onVnodeMounted)||G||qe)&&qn(()=>{te&&Mi(te,B,R),G&&Ee.enter(Y),qe&&hs(R,null,B,"mounted")},k)},D=(R,T,x,B,k)=>{if(x&&p(R,x),B)for(let V=0;V{for(let te=Y;te{const z=T.el=R.el;let{patchFlag:Y,dynamicChildren:te,dirs:ce}=T;Y|=R.patchFlag&16;const Ae=R.props||yr,Ie=T.props||yr;let Ee;x&&ps(x,!1),(Ee=Ie.onVnodeBeforeUpdate)&&Mi(Ee,x,T,R),ce&&hs(T,R,x,"beforeUpdate"),x&&ps(x,!0);const qe=k&&T.type!=="foreignObject";if(te?O(R.dynamicChildren,te,z,x,B,qe,V):J||K(R,T,z,null,x,B,qe,V,!1),Y>0){if(Y&16)P(z,T,Ae,Ie,x,B,k);else if(Y&2&&Ae.class!==Ie.class&&r(z,"class",null,Ie.class,k),Y&4&&r(z,"style",Ae.style,Ie.style,k),Y&8){const G=T.dynamicProps;for(let F=0;F{Ee&&Mi(Ee,x,T,R),ce&&hs(T,R,x,"updated")},B)},O=(R,T,x,B,k,V,J)=>{for(let z=0;z{if(x!==B){if(x!==yr)for(const z in x)!R1(z)&&!(z in B)&&r(R,z,x[z],null,J,T.children,k,V,Ne);for(const z in B){if(R1(z))continue;const Y=B[z],te=x[z];Y!==te&&z!=="value"&&r(R,z,te,Y,J,T.children,k,V,Ne)}"value"in B&&r(R,"value",x.value,B.value)}},j=(R,T,x,B,k,V,J,z,Y)=>{const te=T.el=R?R.el:o(""),ce=T.anchor=R?R.anchor:o("");let{patchFlag:Ae,dynamicChildren:Ie,slotScopeIds:Ee}=T;Ee&&(z=z?z.concat(Ee):Ee),R==null?(s(te,x,B),s(ce,x,B),L(T.children,x,ce,k,V,J,z,Y)):Ae>0&&Ae&64&&Ie&&R.dynamicChildren?(O(R.dynamicChildren,Ie,x,k,V,J,z),(T.key!=null||k&&T===k.subTree)&&S9(R,T,!0)):K(R,T,x,ce,k,V,J,z,Y)},U=(R,T,x,B,k,V,J,z,Y)=>{T.slotScopeIds=z,R==null?T.shapeFlag&512?k.ctx.activate(T,x,B,J,Y):M(T,x,B,k,V,J,Y):q(R,T,Y)},M=(R,T,x,B,k,V,J)=>{const z=R.component=IH(R,B,k);if(u9(R)&&(z.ctx.renderer=oe),DH(z),z.asyncDep){if(k&&k.registerDep(z,Q),!R.el){const Y=z.subTree=ir(Va);g(null,Y,T,x)}return}Q(z,R,T,x,k,V,J)},q=(R,T,x)=>{const B=T.component=R.component;if(VU(R,T,x))if(B.asyncDep&&!B.asyncResolved){Z(B,T,x);return}else B.next=T,MU(B.update),B.update();else T.el=R.el,B.vnode=T},Q=(R,T,x,B,k,V,J)=>{const z=()=>{if(R.isMounted){let{next:ce,bu:Ae,u:Ie,parent:Ee,vnode:qe}=R,G=ce,F;ps(R,!1),ce?(ce.el=qe.el,Z(R,ce,J)):ce=qe,Ae&&mg(Ae),(F=ce.props&&ce.props.onVnodeBeforeUpdate)&&Mi(F,Ee,ce,qe),ps(R,!0);const H=_g(R),re=R.subTree;R.subTree=H,b(re,H,h(re.el),ge(re),R,k,V),ce.el=H.el,G===null&&kU(R,H.el),Ie&&qn(Ie,k),(F=ce.props&&ce.props.onVnodeUpdated)&&qn(()=>Mi(F,Ee,ce,qe),k)}else{let ce;const{el:Ae,props:Ie}=T,{bm:Ee,m:qe,parent:G}=R,F=D0(T);if(ps(R,!1),Ee&&mg(Ee),!F&&(ce=Ie&&Ie.onVnodeBeforeMount)&&Mi(ce,G,T),ps(R,!0),Ae&&N){const H=()=>{R.subTree=_g(R),N(Ae,R.subTree,R,k,null)};F?T.type.__asyncLoader().then(()=>!R.isUnmounted&&H()):H()}else{const H=R.subTree=_g(R);b(null,H,x,B,R,k,V),T.el=H.el}if(qe&&qn(qe,k),!F&&(ce=Ie&&Ie.onVnodeMounted)){const H=T;qn(()=>Mi(ce,G,H),k)}(T.shapeFlag&256||G&&D0(G.vnode)&&G.vnode.shapeFlag&256)&&R.a&&qn(R.a,k),R.isMounted=!0,T=x=B=null}},Y=R.effect=new x3(z,()=>L3(te),R.scope),te=R.update=()=>Y.run();te.id=R.uid,ps(R,!0),te()},Z=(R,T,x)=>{T.component=R;const B=R.vnode.props;R.vnode=T,R.next=null,bH(R,T.props,B,x),_H(R,T.children,x),ko(),LA(),zo()},K=(R,T,x,B,k,V,J,z,Y=!1)=>{const te=R&&R.children,ce=R?R.shapeFlag:0,Ae=T.children,{patchFlag:Ie,shapeFlag:Ee}=T;if(Ie>0){if(Ie&128){X(te,Ae,x,B,k,V,J,z,Y);return}else if(Ie&256){fe(te,Ae,x,B,k,V,J,z,Y);return}}Ee&8?(ce&16&&Ne(te,k,V),Ae!==te&&d(x,Ae)):ce&16?Ee&16?X(te,Ae,x,B,k,V,J,z,Y):Ne(te,k,V,!0):(ce&8&&d(x,""),Ee&16&&L(Ae,x,B,k,V,J,z,Y))},fe=(R,T,x,B,k,V,J,z,Y)=>{R=R||Eo,T=T||Eo;const te=R.length,ce=T.length,Ae=Math.min(te,ce);let Ie;for(Ie=0;Iece?Ne(R,k,V,!0,!1,Ae):L(T,x,B,k,V,J,z,Y,Ae)},X=(R,T,x,B,k,V,J,z,Y)=>{let te=0;const ce=T.length;let Ae=R.length-1,Ie=ce-1;for(;te<=Ae&&te<=Ie;){const Ee=R[te],qe=T[te]=Y?ja(T[te]):Bi(T[te]);if(hu(Ee,qe))b(Ee,qe,x,null,k,V,J,z,Y);else break;te++}for(;te<=Ae&&te<=Ie;){const Ee=R[Ae],qe=T[Ie]=Y?ja(T[Ie]):Bi(T[Ie]);if(hu(Ee,qe))b(Ee,qe,x,null,k,V,J,z,Y);else break;Ae--,Ie--}if(te>Ae){if(te<=Ie){const Ee=Ie+1,qe=EeIe)for(;te<=Ae;)xe(R[te],k,V,!0),te++;else{const Ee=te,qe=te,G=new Map;for(te=qe;te<=Ie;te++){const ke=T[te]=Y?ja(T[te]):Bi(T[te]);ke.key!=null&&G.set(ke.key,te)}let F,H=0;const re=Ie-qe+1;let be=!1,Re=0;const Ce=new Array(re);for(te=0;te=re){xe(ke,k,V,!0);continue}let me;if(ke.key!=null)me=G.get(ke.key);else for(F=qe;F<=Ie;F++)if(Ce[F-qe]===0&&hu(ke,T[F])){me=F;break}me===void 0?xe(ke,k,V,!0):(Ce[me-qe]=te+1,me>=Re?Re=me:be=!0,b(ke,T[me],x,null,k,V,J,z,Y),H++)}const Qe=be?SH(Ce):Eo;for(F=Qe.length-1,te=re-1;te>=0;te--){const ke=qe+te,me=T[ke],Se=ke+1{const{el:V,type:J,transition:z,children:Y,shapeFlag:te}=R;if(te&6){he(R.component.subTree,T,x,B);return}if(te&128){R.suspense.move(T,x,B);return}if(te&64){J.move(R,T,x,oe);return}if(J===Rn){s(V,T,x);for(let Ae=0;Aez.enter(V),k);else{const{leave:Ae,delayLeave:Ie,afterLeave:Ee}=z,qe=()=>s(V,T,x),G=()=>{Ae(V,()=>{qe(),Ee&&Ee()})};Ie?Ie(V,qe,G):G()}else s(V,T,x)},xe=(R,T,x,B=!1,k=!1)=>{const{type:V,props:J,ref:z,children:Y,dynamicChildren:te,shapeFlag:ce,patchFlag:Ae,dirs:Ie}=R;if(z!=null&&$S(z,null,x,R,!0),ce&256){T.ctx.deactivate(R);return}const Ee=ce&1&&Ie,qe=!D0(R);let G;if(qe&&(G=J&&J.onVnodeBeforeUnmount)&&Mi(G,T,R),ce&6)Oe(R.component,x,B);else{if(ce&128){R.suspense.unmount(x,B);return}Ee&&hs(R,null,T,"beforeUnmount"),ce&64?R.type.remove(R,T,x,k,oe,B):te&&(V!==Rn||Ae>0&&Ae&64)?Ne(te,T,x,!1,!0):(V===Rn&&Ae&384||!k&&ce&16)&&Ne(Y,T,x),B&&ie(R)}(qe&&(G=J&&J.onVnodeUnmounted)||Ee)&&qn(()=>{G&&Mi(G,T,R),Ee&&hs(R,null,T,"unmounted")},x)},ie=R=>{const{type:T,el:x,anchor:B,transition:k}=R;if(T===Rn){ae(x,B);return}if(T===wg){w(R);return}const V=()=>{n(x),k&&!k.persisted&&k.afterLeave&&k.afterLeave()};if(R.shapeFlag&1&&k&&!k.persisted){const{leave:J,delayLeave:z}=k,Y=()=>J(x,V);z?z(R.el,V,Y):Y()}else V()},ae=(R,T)=>{let x;for(;R!==T;)x=f(R),n(R),R=x;n(T)},Oe=(R,T,x)=>{const{bum:B,scope:k,update:V,subTree:J,um:z}=R;B&&mg(B),k.stop(),V&&(V.active=!1,xe(J,R,T,x)),z&&qn(z,T),qn(()=>{R.isUnmounted=!0},T),T&&T.pendingBranch&&!T.isUnmounted&&R.asyncDep&&!R.asyncResolved&&R.suspenseId===T.pendingId&&(T.deps--,T.deps===0&&T.resolve())},Ne=(R,T,x,B=!1,k=!1,V=0)=>{for(let J=V;JR.shapeFlag&6?ge(R.component.subTree):R.shapeFlag&128?R.suspense.next():f(R.anchor||R.el),de=(R,T,x)=>{R==null?T._vnode&&xe(T._vnode,null,null,!0):b(T._vnode||null,R,T,null,null,null,x),LA(),n9(),T._vnode=R},oe={p:b,um:xe,m:he,r:ie,mt:M,mc:L,pc:K,pbc:O,n:ge,o:t};let $,N;return e&&([$,N]=e(oe)),{render:de,hydrate:$,createApp:pH(de,$)}}function ps({effect:t,update:e},u){t.allowRecurse=e.allowRecurse=u}function S9(t,e,u=!1){const s=t.children,n=e.children;if(Rt(s)&&Rt(n))for(let r=0;r>1,t[u[o]]0&&(e[s]=u[r-1]),u[r]=s)}}for(r=u.length,a=u[r-1];r-- >0;)u[r]=a,a=e[a];return u}const TH=t=>t.__isTeleport,Rn=Symbol.for("v-fgt"),fb=Symbol.for("v-txt"),Va=Symbol.for("v-cmt"),wg=Symbol.for("v-stc"),C0=[];let vi=null;function jt(t=!1){C0.push(vi=t?null:[])}function AH(){C0.pop(),vi=C0[C0.length-1]||null}let H0=1;function GA(t){H0+=t}function T9(t){return t.dynamicChildren=H0>0?vi||Eo:null,AH(),H0>0&&vi&&vi.push(t),t}function nr(t,e,u,s,n,r){return T9(Bt(t,e,u,s,n,r,!0))}function xi(t,e,u,s,n){return T9(ir(t,e,u,s,n,!0))}function W1(t){return t?t.__v_isVNode===!0:!1}function hu(t,e){return t.type===e.type&&t.key===e.key}const hb="__vInternal",A9=({key:t})=>t??null,I1=({ref:t,ref_key:e,ref_for:u})=>(typeof t=="number"&&(t=""+t),t!=null?qr(t)||dn(t)||Pt(t)?{i:nn,r:t,k:e,f:!!u}:t:null);function Bt(t,e=null,u=null,s=0,n=null,r=t===Rn?0:1,a=!1,o=!1){const l={__v_isVNode:!0,__v_skip:!0,type:t,props:e,key:e&&A9(e),ref:e&&I1(e),scopeId:lb,slotScopeIds:null,children:u,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:r,patchFlag:s,dynamicProps:n,dynamicChildren:null,appContext:null,ctx:nn};return o?(H3(l,u),r&128&&t.normalize(l)):u&&(l.shapeFlag|=qr(u)?8:16),H0>0&&!a&&vi&&(l.patchFlag>0||r&6)&&l.patchFlag!==32&&vi.push(l),l}const ir=EH;function EH(t,e=null,u=null,s=0,n=null,r=!1){if((!t||t===f9)&&(t=Va),W1(t)){const o=Do(t,e,!0);return u&&H3(o,u),H0>0&&!r&&vi&&(o.shapeFlag&6?vi[vi.indexOf(t)]=o:vi.push(o)),o.patchFlag|=-2,o}if(LH(t)&&(t=t.__vccOpts),e){e=OH(e);let{class:o,style:l}=e;o&&!qr(o)&&(e.class=rn(o)),Sr(l)&&(WM(l)&&!Rt(l)&&(l=Wr({},l)),e.style=qa(l))}const a=qr(t)?1:zU(t)?128:TH(t)?64:Sr(t)?4:Pt(t)?2:0;return Bt(t,e,u,s,n,a,r,!0)}function OH(t){return t?WM(t)||hb in t?Wr({},t):t:null}function Do(t,e,u=!1){const{props:s,ref:n,patchFlag:r,children:a}=t,o=e?QS(s||{},e):s;return{__v_isVNode:!0,__v_skip:!0,type:t.type,props:o,key:o&&A9(o),ref:e&&e.ref?u&&n?Rt(n)?n.concat(I1(e)):[n,I1(e)]:I1(e):n,scopeId:t.scopeId,slotScopeIds:t.slotScopeIds,children:a,target:t.target,targetAnchor:t.targetAnchor,staticCount:t.staticCount,shapeFlag:t.shapeFlag,patchFlag:e&&t.type!==Rn?r===-1?16:r|16:r,dynamicProps:t.dynamicProps,dynamicChildren:t.dynamicChildren,appContext:t.appContext,dirs:t.dirs,transition:t.transition,component:t.component,suspense:t.suspense,ssContent:t.ssContent&&Do(t.ssContent),ssFallback:t.ssFallback&&Do(t.ssFallback),el:t.el,anchor:t.anchor,ctx:t.ctx,ce:t.ce}}function m0(t=" ",e=0){return ir(fb,null,t,e)}function Vr(t="",e=!1){return e?(jt(),xi(Va,null,t)):ir(Va,null,t)}function Bi(t){return t==null||typeof t=="boolean"?ir(Va):Rt(t)?ir(Rn,null,t.slice()):typeof t=="object"?ja(t):ir(fb,null,String(t))}function ja(t){return t.el===null&&t.patchFlag!==-1||t.memo?t:Do(t)}function H3(t,e){let u=0;const{shapeFlag:s}=t;if(e==null)e=null;else if(Rt(e))u=16;else if(typeof e=="object")if(s&65){const n=e.default;n&&(n._c&&(n._d=!1),H3(t,n()),n._c&&(n._d=!0));return}else{u=32;const n=e._;!n&&!(hb in e)?e._ctx=nn:n===3&&nn&&(nn.slots._===1?e._=1:(e._=2,t.patchFlag|=1024))}else Pt(e)?(e={default:e,_ctx:nn},u=32):(e=String(e),s&64?(u=16,e=[m0(e)]):u=8);t.children=e,t.shapeFlag|=u}function QS(...t){const e={};for(let u=0;uGr||nn;let $3,yo,WA="__VUE_INSTANCE_SETTERS__";(yo=NS()[WA])||(yo=NS()[WA]=[]),yo.push(t=>Gr=t),$3=t=>{yo.length>1?yo.forEach(e=>e(t)):yo[0](t)};const No=t=>{$3(t),t.scope.on()},Vs=()=>{Gr&&Gr.scope.off(),$3(null)};function E9(t){return t.vnode.shapeFlag&4}let $0=!1;function DH(t,e=!1){$0=e;const{props:u,children:s}=t.vnode,n=E9(t);yH(t,u,n,e),mH(t,s);const r=n?NH(t,e):void 0;return $0=!1,r}function NH(t,e){const u=t.type;t.accessCache=Object.create(null),t.proxy=JM(new Proxy(t.ctx,aH));const{setup:s}=u;if(s){const n=t.setupContext=s.length>1?R9(t):null;No(t),ko();const r=Ua(s,t,0,[t.props,n]);if(zo(),Vs(),DM(r)){if(r.then(Vs,Vs),e)return r.then(a=>{JA(t,a,e)}).catch(a=>{ub(a,t,0)});t.asyncDep=r}else JA(t,r,e)}else O9(t,e)}function JA(t,e,u){Pt(e)?t.type.__ssrInlineRender?t.ssrRender=e:t.render=e:Sr(e)&&(t.setupState=ZM(e)),O9(t,u)}let XA;function O9(t,e,u){const s=t.type;if(!t.render){if(!e&&XA&&!s.render){const n=s.template||B3(t).template;if(n){const{isCustomElement:r,compilerOptions:a}=t.appContext.config,{delimiters:o,compilerOptions:l}=s,c=Wr(Wr({isCustomElement:r,delimiters:o},a),l);s.render=XA(n,c)}}t.render=s.render||wi}No(t),ko(),uH(t),zo(),Vs()}function CH(t){return t.attrsProxy||(t.attrsProxy=new Proxy(t.attrs,{get(e,u){return Bn(t,"get","$attrs"),e[u]}}))}function R9(t){const e=u=>{t.exposed=u||{}};return{get attrs(){return CH(t)},slots:t.slots,emit:t.emit,expose:e}}function pb(t){if(t.exposed)return t.exposeProxy||(t.exposeProxy=new Proxy(ZM(JM(t.exposed)),{get(e,u){if(u in e)return e[u];if(u in N0)return N0[u](t)},has(e,u){return u in e||u in N0}}))}function jH(t,e=!0){return Pt(t)?t.displayName||t.name:t.name||e&&t.__name}function LH(t){return Pt(t)&&"__vccOpts"in t}const sr=(t,e)=>CU(t,e,$0);function x9(t,e,u){const s=arguments.length;return s===2?Sr(e)&&!Rt(e)?W1(e)?ir(t,null,[e]):ir(t,e):ir(t,null,e):(s>3?u=Array.prototype.slice.call(arguments,2):s===3&&W1(u)&&(u=[u]),ir(t,e,u))}const MH=Symbol.for("v-scx"),FH=()=>Ti(MH),qH="3.3.4",BH="http://www.w3.org/2000/svg",qs=typeof document<"u"?document:null,KA=qs&&qs.createElement("template"),UH={insert:(t,e,u)=>{e.insertBefore(t,u||null)},remove:t=>{const e=t.parentNode;e&&e.removeChild(t)},createElement:(t,e,u,s)=>{const n=e?qs.createElementNS(BH,t):qs.createElement(t,u?{is:u}:void 0);return t==="select"&&s&&s.multiple!=null&&n.setAttribute("multiple",s.multiple),n},createText:t=>qs.createTextNode(t),createComment:t=>qs.createComment(t),setText:(t,e)=>{t.nodeValue=e},setElementText:(t,e)=>{t.textContent=e},parentNode:t=>t.parentNode,nextSibling:t=>t.nextSibling,querySelector:t=>qs.querySelector(t),setScopeId(t,e){t.setAttribute(e,"")},insertStaticContent(t,e,u,s,n,r){const a=u?u.previousSibling:e.lastChild;if(n&&(n===r||n.nextSibling))for(;e.insertBefore(n.cloneNode(!0),u),!(n===r||!(n=n.nextSibling)););else{KA.innerHTML=s?`${t}`:t;const o=KA.content;if(s){const l=o.firstChild;for(;l.firstChild;)o.appendChild(l.firstChild);o.removeChild(l)}e.insertBefore(o,u)}return[a?a.nextSibling:e.firstChild,u?u.previousSibling:e.lastChild]}};function HH(t,e,u){const s=t._vtc;s&&(e=(e?[e,...s]:[...s]).join(" ")),e==null?t.removeAttribute("class"):u?t.setAttribute("class",e):t.className=e}function $H(t,e,u){const s=t.style,n=qr(u);if(u&&!n){if(e&&!qr(e))for(const r in e)u[r]==null&&VS(s,r,"");for(const r in u)VS(s,r,u[r])}else{const r=s.display;n?e!==u&&(s.cssText=u):e&&t.removeAttribute("style"),"_vod"in t&&(s.display=r)}}const YA=/\s*!important$/;function VS(t,e,u){if(Rt(u))u.forEach(s=>VS(t,e,s));else if(u==null&&(u=""),e.startsWith("--"))t.setProperty(e,u);else{const s=QH(t,e);YA.test(u)?t.setProperty(Vo(s),u.replace(YA,""),"important"):t[s]=u}}const ZA=["Webkit","Moz","ms"],Sg={};function QH(t,e){const u=Sg[e];if(u)return u;let s=Qi(e);if(s!=="filter"&&s in t)return Sg[e]=s;s=ab(s);for(let n=0;nTg||(XH.then(()=>Tg=0),Tg=Date.now());function YH(t,e){const u=s=>{if(!s._vts)s._vts=Date.now();else if(s._vts<=u.attached)return;Si(ZH(s,u.value),e,5,[s])};return u.value=t,u.attached=KH(),u}function ZH(t,e){if(Rt(e)){const u=t.stopImmediatePropagation;return t.stopImmediatePropagation=()=>{u.call(t),t._stopped=!0},e.map(s=>n=>!n._stopped&&s&&s(n))}else return e}const rE=/^on[a-z]/,e$=(t,e,u,s,n=!1,r,a,o,l)=>{e==="class"?HH(t,s,n):e==="style"?$H(t,u,s):rb(e)?T3(e)||WH(t,e,u,s,a):(e[0]==="."?(e=e.slice(1),!0):e[0]==="^"?(e=e.slice(1),!1):t$(t,e,s,n))?kH(t,e,s,r,a,o,l):(e==="true-value"?t._trueValue=s:e==="false-value"&&(t._falseValue=s),VH(t,e,s,n))};function t$(t,e,u,s){return s?!!(e==="innerHTML"||e==="textContent"||e in t&&rE.test(e)&&Pt(u)):e==="spellcheck"||e==="draggable"||e==="translate"||e==="form"||e==="list"&&t.tagName==="INPUT"||e==="type"&&t.tagName==="TEXTAREA"||rE.test(e)&&qr(u)?!1:e in t}const r$=Wr({patchProp:e$},UH);let nE;function n$(){return nE||(nE=vH(r$))}const i$=(...t)=>{const e=n$().createApp(...t),{mount:u}=e;return e.mount=s=>{const n=a$(s);if(!n)return;const r=e._component;!Pt(r)&&!r.render&&!r.template&&(r.template=n.innerHTML),n.innerHTML="";const a=u(n,!1,n instanceof SVGElement);return n instanceof Element&&(n.removeAttribute("v-cloak"),n.setAttribute("data-v-app","")),a},e};function a$(t){return qr(t)?document.querySelector(t):t}const s$=["primary","secondary","success","danger","warning","info","light","dark"],o$="rgba({{color}}, 0.2) 0, rgba({{color}}, 0.3) 40%, rgba({{color}}, 0.4) 50%, rgba({{color}}, 0.5) 60%, rgba({{color}}, 0) 70%",u$=[0,0,0],iE=.5,c$=t=>t&&s$.includes(t.toLowerCase()),l$=(t,e)=>{const u=r=>(r.length<7&&(r=`#${r[1]}${r[1]}${r[2]}${r[2]}${r[3]}${r[3]}`),[parseInt(r.substr(1,2),16),parseInt(r.substr(3,2),16),parseInt(r.substr(5,2),16)]),s=r=>{const a=document.body.appendChild(document.createElement("fictum")),o="rgb(1, 2, 3)";return a.style.color=o,a.style.color!==o||(a.style.color=r,a.style.color===o||a.style.color==="")?e:(r=getComputedStyle(a).color,document.body.removeChild(a),r)},n=r=>{const a=r.match(/[.\d]+/g);if(a===null)return;const o=a.map(l=>+Number(l));return o.length=3,o};return typeof t=="string"&&t.toLowerCase()==="transparent"?e:typeof t=="string"&&t[0]==="#"?u(t):(typeof t=="string"&&t.indexOf("rgb")===-1&&(t=s(t)),typeof t=="string"&&t.indexOf("rgb")===0?n(t):e)},d$=({offsetX:t,offsetY:e,height:u,width:s})=>{const n=e<=u/2,r=t<=s/2,a=(h,f)=>Math.sqrt(h**2+f**2),o=e===u/2&&t===s/2,l={first:n===!0&&r===!1,second:n===!0&&r===!0,third:n===!1&&r===!0,fourth:n===!1&&r===!1},c={topLeft:a(t,e),topRight:a(s-t,e),bottomLeft:a(t,u-e),bottomRight:a(s-t,u-e)};let d=0;return o||l.fourth?d=c.topLeft:l.third?d=c.topRight:l.second?d=c.bottomRight:l.first&&(d=c.bottomLeft),d*2},f$=(t,e)=>{for(const u in e)t.style[u]=e[u]},h$=t=>{const e=l$(t,u$);if(t!==""&&e){const u=e.join(",");return`radial-gradient(circle, ${o$.split("{{color}}").join(`${u}`)})`}},p$=(t,e,u)=>{const s=document.createElement("div");s.classList.add("ripple-wave");const n={offsetX:u.centered?e.height/2:e.left,offsetY:u.centered?e.width/2:e.top,height:e.height,width:e.width},r=d$(n),a=u.radius||r/2,o={delay:u.duration&&u.duration*iE,duration:u.duration&&u.duration-u.duration*iE},l={left:u.centered?`${Math.round(e.width/2-a)}px`:`${Math.round(e.left-a)}px`,top:u.centered?`${Math.round(e.height/2-a)}px`:`${Math.round(e.top-a)}px`,height:`${Math.round(u.radius&&u.radius*2||r)}px`,width:`${Math.round(u.radius&&u.radius*2||r)}px`,transitionDelay:`0s, ${o.delay}ms`,transitionDuration:`${u.duration}ms, ${o.duration}ms`};u.unbound&&t.classList.add("ripple-surface-unbound"),c$(u.color)?t.classList.add(`ripple-surface-${u.color}`):l.backgroundImage=h$(u.color),f$(s,l),t.appendChild(s),setTimeout(()=>{s.classList.add("active")},50),setTimeout(()=>{t.removeChild(s)},u.duration?u.duration+1e3:1e3)},I9={mounted(t,e){if(e.value===!1)return;const u={centered:e.value&&e.value.centered||!1,color:e.value&&e.value.color||"",duration:e.value&&e.value.duration||500,radius:e.value&&e.value.radius||0,unbound:e.value&&e.value.unbound||!1};t.classList.add("ripple-surface"),t.waves=s=>{const n={top:s.layerY,left:s.layerX,height:t.offsetHeight,width:t.offsetWidth};p$(t,n,u)},t.addEventListener("click",s=>t.waves(s))},updated(t){t.classList.contains("ripple-surface")||t.classList.add("ripple-surface")},unmounted(t){t.removeEventListener("click",e=>t.waves(e))}},y$={name:"MDBBtn"},b$=Ri({...y$,props:{color:String,size:String,outline:String,rounded:Boolean,floating:Boolean,toggler:Boolean,toggle:Boolean,role:{type:String,default:"button"},type:{type:String,default:"button"},tag:{type:String,default:"button"},block:{type:Boolean,default:!1},ripple:{type:[Object,Boolean],default:t=>t.outline||t.color==="light"||t.color==="link"?{color:"dark"}:!0},picker:Boolean},emits:["update:toggle"],setup(t,{emit:e}){const u=t,s=En(u.toggle),n=sr(()=>[!u.picker&&"btn",u.color&&`btn-${u.color}`,u.size&&`btn-${u.size}`,u.outline&&`btn-outline-${u.outline}`,u.rounded&&"btn-rounded",u.floating&&"btn-floating",u.block&&"btn-block",s.value&&"active"]),r=()=>{u.toggler&&(s.value=!s.value,e("update:toggle",s.value))};return(a,o)=>k1((jt(),xi(Wa(t.tag),{type:t.type,role:t.role,class:rn(qt(n)),onClick:r},{default:Lr(()=>[$i(a.$slots,"default")]),_:3},8,["type","role","class"])),[[qt(I9),t.ripple]])}}),g$={name:"MDBCard"},m$=Ri({...g$,props:{tag:{type:String,default:"div"},border:String,bg:String,text:[String,Array],shadow:String},setup(t){const e=t,u=sr(()=>{const n=e.text;return["card",e.border&&`border border-${e.border}`,e.bg&&`bg-${e.bg}`,e.shadow&&`shadow-${e.shadow}`,e.text&&s(n)]}),s=n=>typeof n=="string"?`text-${n}`:n.map(r=>`text-${r}`.trim()).join(" ");return(n,r)=>(jt(),xi(Wa(t.tag),{class:rn(qt(u))},{default:Lr(()=>[$i(n.$slots,"default")]),_:3},8,["class"]))}}),_$={name:"MDBCardBody"},v$=Ri({..._$,props:{tag:{type:String,default:"div"},text:{type:[String,Array]}},setup(t){const e=t,u=sr(()=>{const n=e.text;return["card-body",e.text&&s(n)]}),s=n=>typeof n=="string"?`text-${n}`:n.map(r=>`text-${r}`.trim()).join(" ");return(n,r)=>(jt(),xi(Wa(t.tag),{class:rn(qt(u))},{default:Lr(()=>[$i(n.$slots,"default")]),_:3},8,["class"]))}}),w$={name:"MDBCardTitle"},S$=Ri({...w$,props:{tag:{type:String,default:"h5"},subtitle:{type:Boolean,default:!1}},setup(t){const e=t,u=sr(()=>e.subtitle?e.tag!=="h5"?e.tag:"h6":e.tag),s=sr(()=>[e.subtitle?"card-subtitle":"card-title"]);return(n,r)=>(jt(),xi(Wa(qt(u)),{class:rn(qt(s))},{default:Lr(()=>[$i(n.$slots,"default")]),_:3},8,["class"]))}}),T$={name:"MDBCardText"},A$=Ri({...T$,props:{tag:{type:String,default:"p"}},setup(t){const e=sr(()=>["card-text"]);return(u,s)=>(jt(),xi(Wa(t.tag),{class:rn(qt(e))},{default:Lr(()=>[$i(u.$slots,"default")]),_:3},8,["class"]))}}),E$=1e6,O$=t=>{do t+=Math.floor(Math.random()*E$);while(document.getElementById(t));return t},R$=/\..*/,x$={mouseenter:"mouseover",mouseleave:"mouseout"},I$=["click","dblclick","mouseup","mousedown","contextmenu","mousewheel","DOMMouseScroll","mouseover","mouseout","mousemove","selectstart","selectend","keydown","keypress","keyup","orientationchange","touchstart","touchmove","touchend","touchcancel","pointerdown","pointermove","pointerup","pointerleave","pointercancel","gesturestart","gesturechange","gestureend","focus","blur","change","reset","select","submit","focusin","focusout","load","unload","beforeunload","resize","move","DOMContentLoaded","readystatechange","error","abort","scroll"];function P9(t,e,u){const s=typeof e=="string",n=s?u:e;let r=t.replace(R$,"");const a=x$[r];return a&&(r=a),I$.indexOf(r)>-1||(r=t),[s,n,r]}function P$(t,e,u,s){if(typeof e!="string"||!t)return;u||(u=s,s=null);const[n,r,a]=P9(e,u,s);t.addEventListener(a,r,n)}function D$(t,e,u,s){t.removeEventListener(e,u,!!s)}const N$=function(t,e,u,s=void 0){P$(t,e,u,s)},C$=function(t,e,u,s=void 0){if(typeof e!="string"||!t)return;const[n,r,a]=P9(e,u,s);D$(t,a,r,n?u:null)};var kS={stopProp(t){t.stopPropagation()},mounted(t,e){const u=n=>{const r=n.target;!t.contains(r)&&t!==r&&e.value(n)};t.clickOutside=u;const s=e.modifiers.mousedown?"mousedown":"click";document.addEventListener(s,n=>{var r;return(r=t.clickOutside)==null?void 0:r.call(t,n)}),document.addEventListener("touchstart",n=>{var r;return(r=t.clickOutside)==null?void 0:r.call(t,n)})},unmounted(t,e){if(!t.clickOutside)return;const u=e.modifiers.mousedown?"mousedown":"click";document.removeEventListener(u,s=>{var n;return(n=t.clickOutside)==null?void 0:n.call(t,s)}),document.removeEventListener("touchstart",s=>{var n;return(n=t.clickOutside)==null?void 0:n.call(t,s)}),delete t.clickOutside}};const j$={key:1,class:"visually-hidden"},L$={name:"MDBDropdownToggle"};({...L$,props:{...b$.props}});const M$={name:"MDBContainer"},F$=Ri({...M$,props:{tag:{type:String,default:"div"},sm:{type:Boolean,default:!1},md:{type:Boolean,default:!1},lg:{type:Boolean,default:!1},xl:{type:Boolean,default:!1},xxl:{type:Boolean,default:!1},fluid:{type:Boolean,default:!1}},setup(t){const e=t,u=sr(()=>[e.fluid?"container-fluid":"",e.sm?"container-sm":"",e.md?"container-md":"",e.lg?"container-lg":"",e.xl?"container-xl":"",e.xxl?"container-xxl":"",!e.fluid&&!e.sm&&!e.md&&!e.lg&&!e.xl&&!e.xxl?"container":""]);return(s,n)=>(jt(),xi(Wa(t.tag),{class:rn(qt(u))},{default:Lr(()=>[$i(s.$slots,"default")]),_:3},8,["class"]))}}),q$=["id","value"],B$=["for"],U$={key:2,class:"form-helper"},H$={key:3,class:"form-helper"},$$={class:"form-counter"},Q$=Bt("div",{class:"form-notch-trailing"},null,-1),V$=["id","value"],k$=["for"],z$={key:1,class:"form-helper"},G$={key:2,class:"form-helper"},W$={class:"form-counter"},J$=Bt("div",{class:"form-notch-trailing"},null,-1),X$={key:9,class:"form-text"},K$={name:"MDBInput",inheritAttrs:!1},Y$=Ri({...K$,props:{id:String,label:String,labelClass:String,modelValue:[String,Number,Date],size:String,formOutline:{type:Boolean,default:!0},wrapperClass:String,inputGroup:{type:[Boolean,String],default:!1},wrap:{type:Boolean,default:!0},formText:String,white:Boolean,validationEvent:String,isValidated:Boolean,isValid:Boolean,validFeedback:String,invalidFeedback:String,tooltipFeedback:{type:Boolean,default:!1},tag:{type:String,default:"div"},helper:String,counter:Boolean,maxlength:{type:Number,default:0}},emits:["update:modelValue","click-outside","on-validate"],setup(t,{expose:e,emit:u}){const s=t,n=sH(),r=En(null),a=En(s.modelValue),o=En(null),l=En(!1),c=En(9),d=En(0),h=s.id||O$("MDBInput-"),f=sr(()=>[s.formOutline&&"form-outline",b.value,s.white&&"form-white",s.wrapperClass]),p=sr(()=>["form-control",s.size?`form-control-${s.size}`:s.inputGroup&&s.inputGroup!==!0&&`form-control-${s.inputGroup}`,(a.value||a.value===0)&&"active",l.value&&"placeholder-active",_.value&&w.value&&"is-valid",_.value&&!w.value&&"is-invalid"]),y=sr(()=>["form-label",s.labelClass]),b=sr(()=>{if(s.inputGroup)return s.inputGroup!==!0?`input-group input-group-${s.inputGroup}`:"input-group"}),m=sr(()=>s.inputGroup&&_.value?{marginBottom:"1rem"}:""),g=sr(()=>s.tooltipFeedback?"valid-tooltip":"valid-feedback"),v=sr(()=>s.tooltipFeedback?"invalid-tooltip":"invalid-feedback"),_=En(s.isValidated),w=En(s.isValid),S=En(""),A=sr(()=>_.value&&!w.value&&s.validationEvent?S.value:s.invalidFeedback),D=X=>{const he=X.target;w.value=he.checkValidity(),w.value||(S.value=he.validationMessage),_.value=!0,u("on-validate",w.value)},L=()=>{s.validationEvent!=="submit"&&typeof r.value!="string"&&N$(r.value,s.validationEvent,D)};function E(){o.value&&(d.value=o.value.clientWidth*.8+8)}function O(){n.placeholder&&!o.value?l.value=!0:l.value=!1}const P=En(null);P.value=typeof a.value=="string"&&a.value?a.value.length:0;function j(X){const he=X.target;if(s.counter){if(he.value.length>s.maxlength){typeof a.value=="string"&&(he.value=a.value);return}P.value=he.value.length}a.value=he.value,u("update:modelValue",a.value)}function U(){u("click-outside")}const M=En(null),q=En(),Q=X=>{q.value.forEach(he=>he.style.opacity=X?"0":"1"),X&&(M.value.style.opacity="1")},Z=n.type&&n.type==="date",K=(X=!1)=>{var he;s.label&&s.formOutline&&((he=q.value)==null?void 0:he.length)>1&&Q(X),Z&&typeof r.value!="string"&&(r.value.type=X?"date":"text")},fe=X=>![...X.parentNode.children].findIndex(he=>he===X);return l9(()=>{if(E(),O(),K(),s.label&&s.formOutline&&(q.value=r.value.parentNode.querySelectorAll(".form-notch")),s.label&&s.formOutline&&!fe(r.value)){const X=parseFloat(getComputedStyle(o.value).left);o.value.style.left=`${X+r.value.offsetLeft}px`,c.value+=r.value.offsetLeft}s.validationEvent&&L()}),d9(()=>{E(),O()}),F3(()=>{typeof r.value!="string"&&C$(r.value,s.validationEvent,D)}),s9(()=>{var X,he;if(s.counter&&typeof s.modelValue=="string"){if(((X=s.modelValue)==null?void 0:X.length)>s.maxlength){a.value=s.modelValue.slice(0,s.maxlength),P.value=s.maxlength;return}P.value=((he=s.modelValue)==null?void 0:he.length)||0}a.value=s.modelValue}),Io(()=>s.isValidated,X=>_.value=X),Io(()=>s.isValid,X=>w.value=X),e({inputRef:r}),(X,he)=>(jt(),nr(Rn,null,[t.wrap?Vr("",!0):k1((jt(),nr("input",QS({key:0,class:qt(p),id:qt(h),value:a.value},X.$attrs,{onInput:j,ref_key:"inputRef",ref:r,onFocus:he[0]||(he[0]=xe=>K(!0)),onBlur:he[1]||(he[1]=xe=>K())}),null,16,q$)),[[qt(kS),U]]),t.label&&!t.wrap?(jt(),nr("label",{key:1,ref_key:"labelRef",ref:o,class:rn(qt(y)),for:qt(h)},Or(t.label),11,B$)):Vr("",!0),!t.wrap&&t.helper?(jt(),nr("div",U$,Or(t.helper),1)):Vr("",!0),!t.wrap&&t.counter?(jt(),nr("div",H$,[Bt("div",$$,Or(P.value)+" / "+Or(t.maxlength),1)])):Vr("",!0),t.wrap?Vr("",!0):$i(X.$slots,"default",{key:4}),!t.wrap&&t.validFeedback?(jt(),nr("div",{key:5,class:rn(qt(g))},Or(t.validFeedback),3)):Vr("",!0),!t.wrap&&qt(A)?(jt(),nr("div",{key:6,class:rn(qt(v))},Or(qt(A)),3)):Vr("",!0),!t.wrap&&t.formOutline?(jt(),nr("div",{key:7,class:"form-notch",ref_key:"notchRef",ref:M},[Bt("div",{class:"form-notch-leading",style:qa({width:`${c.value}px`})},null,4),Bt("div",{class:"form-notch-middle",style:qa({width:`${d.value}px`})},null,4),Q$],512)):Vr("",!0),t.wrap?k1((jt(),xi(Wa(t.tag),{key:8,class:rn(qt(f)),style:qa(qt(m))},{default:Lr(()=>[$i(X.$slots,"prepend"),Bt("input",QS({class:qt(p)},X.$attrs,{id:qt(h),value:a.value,onInput:j,ref_key:"inputRef",ref:r,onFocus:he[2]||(he[2]=xe=>K(!0)),onBlur:he[3]||(he[3]=xe=>K())}),null,16,V$),t.label?(jt(),nr("label",{key:0,ref_key:"labelRef",ref:o,class:rn(qt(y)),for:qt(h)},Or(t.label),11,k$)):Vr("",!0),t.helper?(jt(),nr("div",z$,Or(t.helper),1)):Vr("",!0),t.counter?(jt(),nr("div",G$,[Bt("div",W$,Or(P.value)+" / "+Or(t.maxlength),1)])):Vr("",!0),$i(X.$slots,"default"),t.validFeedback?(jt(),nr("div",{key:3,class:rn(qt(g))},Or(t.validFeedback),3)):Vr("",!0),qt(A)?(jt(),nr("div",{key:4,class:rn(qt(v))},Or(qt(A)),3)):Vr("",!0),t.formOutline?(jt(),nr("div",{key:5,class:"form-notch",ref_key:"notchRef",ref:M},[Bt("div",{class:"form-notch-leading",style:qa({width:`${c.value}px`})},null,4),Bt("div",{class:"form-notch-middle",style:qa({width:`${d.value}px`})},null,4),J$],512)):Vr("",!0)]),_:3},8,["class","style"])),[[qt(kS),U]]):Vr("",!0),t.formText?(jt(),nr("div",X$,Or(t.formText),1)):Vr("",!0)],64))}});var I=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Z$(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function Q3(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var u=function s(){return this instanceof s?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};u.prototype=e.prototype}else u={};return Object.defineProperty(u,"__esModule",{value:!0}),Object.keys(t).forEach(function(s){var n=Object.getOwnPropertyDescriptor(t,s);Object.defineProperty(u,s,n.get?n:{enumerable:!0,get:function(){return t[s]}})}),u}var D9={},yb={},V3={},ey={},N9={},bb={},ot={},ks={},ty="delete",br=5,ai=1<>>0;if(""+u!==e||u===4294967295)return NaN;e=u}return e<0?Co(t)+e:e}function C9(){return!0}function ry(t,e,u){return(t===0&&!L9(t)||u!==void 0&&t<=-u)&&(e===void 0||u!==void 0&&e>=u)}function Go(t,e){return j9(t,e,0)}function ny(t,e){return j9(t,e,e)}function j9(t,e,u){return t===void 0?u:L9(t)?e===1/0?e:Math.max(0,e+t)|0:e===void 0||e===t?t:Math.min(e,t)|0}function L9(t){return t<0||t===0&&1/t===-1/0}var M9="@@__IMMUTABLE_ITERABLE__@@";function fn(t){return!!(t&&t[M9])}var F9="@@__IMMUTABLE_KEYED__@@";function cr(t){return!!(t&&t[F9])}var q9="@@__IMMUTABLE_INDEXED__@@";function an(t){return!!(t&&t[q9])}function Wo(t){return cr(t)||an(t)}var gr=function(e){return fn(e)?e:hn(e)},ci=function(t){function e(u){return cr(u)?u:Xa(u)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e}(gr),Xs=function(t){function e(u){return an(u)?u:li(u)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e}(gr),Jo=function(t){function e(u){return fn(u)&&!Wo(u)?u:Yo(u)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e}(gr);gr.Keyed=ci;gr.Indexed=Xs;gr.Set=Jo;var B9="@@__IMMUTABLE_SEQ__@@";function iy(t){return!!(t&&t[B9])}var U9="@@__IMMUTABLE_RECORD__@@";function Ja(t){return!!(t&&t[U9])}function Yn(t){return fn(t)||Ja(t)}var Xo="@@__IMMUTABLE_ORDERED__@@";function Xn(t){return!!(t&&t[Xo])}var ay=0,Ai=1,oi=2,GS=typeof Symbol=="function"&&Symbol.iterator,H9="@@iterator",gb=GS||H9,kt=function(e){this.next=e};kt.prototype.toString=function(){return"[Iterator]"};kt.KEYS=ay;kt.VALUES=Ai;kt.ENTRIES=oi;kt.prototype.inspect=kt.prototype.toSource=function(){return this.toString()};kt.prototype[gb]=function(){return this};function mr(t,e,u,s){var n=t===0?e:t===1?u:[e,u];return s?s.value=n:s={value:n,done:!1},s}function Dn(){return{value:void 0,done:!0}}function z3(t){return Array.isArray(t)?!0:!!mb(t)}function aE(t){return t&&typeof t.next=="function"}function WS(t){var e=mb(t);return e&&e.call(t)}function mb(t){var e=t&&(GS&&t[GS]||t[H9]);if(typeof e=="function")return e}function eQ(t){var e=mb(t);return e&&e===t.entries}function tQ(t){var e=mb(t);return e&&e===t.keys}var Ko=Object.prototype.hasOwnProperty;function G3(t){return Array.isArray(t)||typeof t=="string"?!0:t&&typeof t=="object"&&Number.isInteger(t.length)&&t.length>=0&&(t.length===0?Object.keys(t).length===1:t.hasOwnProperty(t.length-1))}var hn=function(t){function e(u){return u==null?J3():Yn(u)?u.toSeq():nQ(u)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.toSeq=function(){return this},e.prototype.toString=function(){return this.__toString("Seq {","}")},e.prototype.cacheResult=function(){return!this._cache&&this.__iterateUncached&&(this._cache=this.entrySeq().toArray(),this.size=this._cache.length),this},e.prototype.__iterate=function(s,n){var r=this._cache;if(r){for(var a=r.length,o=0;o!==a;){var l=r[n?a-++o:o++];if(s(l[1],l[0],this)===!1)break}return o}return this.__iterateUncached(s,n)},e.prototype.__iterator=function(s,n){var r=this._cache;if(r){var a=r.length,o=0;return new kt(function(){if(o===a)return Dn();var l=r[n?a-++o:o++];return mr(s,l[0],l[1])})}return this.__iteratorUncached(s,n)},e}(gr),Xa=function(t){function e(u){return u==null?J3().toKeyedSeq():fn(u)?cr(u)?u.toSeq():u.fromEntrySeq():Ja(u)?u.toSeq():X3(u)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.toKeyedSeq=function(){return this},e}(hn),li=function(t){function e(u){return u==null?J3():fn(u)?cr(u)?u.entrySeq():u.toIndexedSeq():Ja(u)?u.toSeq().entrySeq():$9(u)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.of=function(){return e(arguments)},e.prototype.toIndexedSeq=function(){return this},e.prototype.toString=function(){return this.__toString("Seq [","]")},e}(hn),Yo=function(t){function e(u){return(fn(u)&&!Wo(u)?u:li(u)).toSetSeq()}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.of=function(){return e(arguments)},e.prototype.toSetSeq=function(){return this},e}(hn);hn.isSeq=iy;hn.Keyed=Xa;hn.Set=Yo;hn.Indexed=li;hn.prototype[B9]=!0;var zs=function(t){function e(u){this._array=u,this.size=u.length}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.get=function(s,n){return this.has(s)?this._array[ka(this,s)]:n},e.prototype.__iterate=function(s,n){for(var r=this._array,a=r.length,o=0;o!==a;){var l=n?a-++o:o++;if(s(r[l],l,this)===!1)break}return o},e.prototype.__iterator=function(s,n){var r=this._array,a=r.length,o=0;return new kt(function(){if(o===a)return Dn();var l=n?a-++o:o++;return mr(s,l,r[l])})},e}(li),W3=function(t){function e(u){var s=Object.keys(u).concat(Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(u):[]);this._object=u,this._keys=s,this.size=s.length}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.get=function(s,n){return n!==void 0&&!this.has(s)?n:this._object[s]},e.prototype.has=function(s){return Ko.call(this._object,s)},e.prototype.__iterate=function(s,n){for(var r=this._object,a=this._keys,o=a.length,l=0;l!==o;){var c=a[n?o-++l:l++];if(s(r[c],c,this)===!1)break}return l},e.prototype.__iterator=function(s,n){var r=this._object,a=this._keys,o=a.length,l=0;return new kt(function(){if(l===o)return Dn();var c=a[n?o-++l:l++];return mr(s,c,r[c])})},e}(Xa);W3.prototype[Xo]=!0;var rQ=function(t){function e(u){this._collection=u,this.size=u.length||u.size}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.__iterateUncached=function(s,n){if(n)return this.cacheResult().__iterate(s,n);var r=this._collection,a=WS(r),o=0;if(aE(a))for(var l;!(l=a.next()).done&&s(l.value,o++,this)!==!1;);return o},e.prototype.__iteratorUncached=function(s,n){if(n)return this.cacheResult().__iterator(s,n);var r=this._collection,a=WS(r);if(!aE(a))return new kt(Dn);var o=0;return new kt(function(){var l=a.next();return l.done?l:mr(s,o++,l.value)})},e}(li),sE;function J3(){return sE||(sE=new zs([]))}function X3(t){var e=K3(t);if(e)return e.fromEntrySeq();if(typeof t=="object")return new W3(t);throw new TypeError("Expected Array or collection object of [k, v] entries, or keyed object: "+t)}function $9(t){var e=K3(t);if(e)return e;throw new TypeError("Expected Array or collection object of values: "+t)}function nQ(t){var e=K3(t);if(e)return eQ(t)?e.fromEntrySeq():tQ(t)?e.toSetSeq():e;if(typeof t=="object")return new W3(t);throw new TypeError("Expected Array or collection object of values, or keyed object: "+t)}function K3(t){return G3(t)?new zs(t):z3(t)?new rQ(t):void 0}var Q9="@@__IMMUTABLE_MAP__@@";function sy(t){return!!(t&&t[Q9])}function _b(t){return sy(t)&&Xn(t)}function J1(t){return!!(t&&typeof t.equals=="function"&&typeof t.hashCode=="function")}function kr(t,e){if(t===e||t!==t&&e!==e)return!0;if(!t||!e)return!1;if(typeof t.valueOf=="function"&&typeof e.valueOf=="function"){if(t=t.valueOf(),e=e.valueOf(),t===e||t!==t&&e!==e)return!0;if(!t||!e)return!1}return!!(J1(t)&&J1(e)&&t.equals(e))}var pu=typeof Math.imul=="function"&&Math.imul(4294967295,2)===-2?Math.imul:function(e,u){e|=0,u|=0;var s=e&65535,n=u&65535;return s*n+((e>>>16)*n+s*(u>>>16)<<16>>>0)|0};function vb(t){return t>>>1&1073741824|t&3221225471}var iQ=Object.prototype.valueOf;function xn(t){if(t==null)return oE(t);if(typeof t.hashCode=="function")return vb(t.hashCode(t));var e=lQ(t);if(e==null)return oE(e);switch(typeof e){case"boolean":return e?1108378657:1108378656;case"number":return aQ(e);case"string":return e.length>dQ?sQ(e):JS(e);case"object":case"function":return uQ(e);case"symbol":return oQ(e);default:if(typeof e.toString=="function")return JS(e.toString());throw new Error("Value type "+typeof e+" cannot be hashed.")}}function oE(t){return t===null?1108378658:1108378659}function aQ(t){if(t!==t||t===1/0)return 0;var e=t|0;for(e!==t&&(e^=t*4294967295);t>4294967295;)t/=4294967295,e^=t;return vb(e)}function sQ(t){var e=Og[t];return e===void 0&&(e=JS(t),Eg===fQ&&(Eg=0,Og={}),Eg++,Og[t]=e),e}function JS(t){for(var e=0,u=0;u0)switch(t.nodeType){case 1:return t.uniqueID;case 9:return t.documentElement&&t.documentElement.uniqueID}}function lQ(t){return t.valueOf!==iQ&&typeof t.valueOf=="function"?t.valueOf(t):t}function V9(){var t=++Ag;return Ag&1073741824&&(Ag=0),t}var XS=typeof WeakMap=="function",KS;XS&&(KS=new WeakMap);var lE=Object.create(null),Ag=0,Bs="__immutablehash__";typeof Symbol=="function"&&(Bs=Symbol(Bs));var dQ=16,fQ=255,Eg=0,Og={},wb=function(t){function e(u,s){this._iter=u,this._useKeys=s,this.size=u.size}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.get=function(s,n){return this._iter.get(s,n)},e.prototype.has=function(s){return this._iter.has(s)},e.prototype.valueSeq=function(){return this._iter.valueSeq()},e.prototype.reverse=function(){var s=this,n=Y3(this,!0);return this._useKeys||(n.valueSeq=function(){return s._iter.toSeq().reverse()}),n},e.prototype.map=function(s,n){var r=this,a=J9(this,s,n);return this._useKeys||(a.valueSeq=function(){return r._iter.toSeq().map(s,n)}),a},e.prototype.__iterate=function(s,n){var r=this;return this._iter.__iterate(function(a,o){return s(a,o,r)},n)},e.prototype.__iterator=function(s,n){return this._iter.__iterator(s,n)},e}(Xa);wb.prototype[Xo]=!0;var k9=function(t){function e(u){this._iter=u,this.size=u.size}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.includes=function(s){return this._iter.includes(s)},e.prototype.__iterate=function(s,n){var r=this,a=0;return n&&Co(this),this._iter.__iterate(function(o){return s(o,n?r.size-++a:a++,r)},n)},e.prototype.__iterator=function(s,n){var r=this,a=this._iter.__iterator(Ai,n),o=0;return n&&Co(this),new kt(function(){var l=a.next();return l.done?l:mr(s,n?r.size-++o:o++,l.value,l)})},e}(li),z9=function(t){function e(u){this._iter=u,this.size=u.size}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.has=function(s){return this._iter.includes(s)},e.prototype.__iterate=function(s,n){var r=this;return this._iter.__iterate(function(a){return s(a,a,r)},n)},e.prototype.__iterator=function(s,n){var r=this._iter.__iterator(Ai,n);return new kt(function(){var a=r.next();return a.done?a:mr(s,a.value,a.value,a)})},e}(Yo),G9=function(t){function e(u){this._iter=u,this.size=u.size}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.entrySeq=function(){return this._iter.toSeq()},e.prototype.__iterate=function(s,n){var r=this;return this._iter.__iterate(function(a){if(a){fE(a);var o=fn(a);return s(o?a.get(1):a[1],o?a.get(0):a[0],r)}},n)},e.prototype.__iterator=function(s,n){var r=this._iter.__iterator(Ai,n);return new kt(function(){for(;;){var a=r.next();if(a.done)return a;var o=a.value;if(o){fE(o);var l=fn(o);return mr(s,l?o.get(0):o[0],l?o.get(1):o[1],a)}}})},e}(Xa);k9.prototype.cacheResult=wb.prototype.cacheResult=z9.prototype.cacheResult=G9.prototype.cacheResult=tT;function W9(t){var e=Vi(t);return e._iter=t,e.size=t.size,e.flip=function(){return t},e.reverse=function(){var u=t.reverse.apply(this);return u.flip=function(){return t.reverse()},u},e.has=function(u){return t.includes(u)},e.includes=function(u){return t.has(u)},e.cacheResult=tT,e.__iterateUncached=function(u,s){var n=this;return t.__iterate(function(r,a){return u(a,r,n)!==!1},s)},e.__iteratorUncached=function(u,s){if(u===oi){var n=t.__iterator(u,s);return new kt(function(){var r=n.next();if(!r.done){var a=r.value[0];r.value[0]=r.value[1],r.value[1]=a}return r})}return t.__iterator(u===Ai?ay:Ai,s)},e}function J9(t,e,u){var s=Vi(t);return s.size=t.size,s.has=function(n){return t.has(n)},s.get=function(n,r){var a=t.get(n,Ut);return a===Ut?r:e.call(u,a,n,t)},s.__iterateUncached=function(n,r){var a=this;return t.__iterate(function(o,l,c){return n(e.call(u,o,l,c),l,a)!==!1},r)},s.__iteratorUncached=function(n,r){var a=t.__iterator(oi,r);return new kt(function(){var o=a.next();if(o.done)return o;var l=o.value,c=l[0];return mr(n,c,e.call(u,l[1],c,t),o)})},s}function Y3(t,e){var u=this,s=Vi(t);return s._iter=t,s.size=t.size,s.reverse=function(){return t},t.flip&&(s.flip=function(){var n=W9(t);return n.reverse=function(){return t.flip()},n}),s.get=function(n,r){return t.get(e?n:-1-n,r)},s.has=function(n){return t.has(e?n:-1-n)},s.includes=function(n){return t.includes(n)},s.cacheResult=tT,s.__iterate=function(n,r){var a=this,o=0;return r&&Co(t),t.__iterate(function(l,c){return n(l,e?c:r?a.size-++o:o++,a)},!r)},s.__iterator=function(n,r){var a=0;r&&Co(t);var o=t.__iterator(oi,!r);return new kt(function(){var l=o.next();if(l.done)return l;var c=l.value;return mr(n,e?c[0]:r?u.size-++a:a++,c[1],l)})},s}function X9(t,e,u,s){var n=Vi(t);return s&&(n.has=function(r){var a=t.get(r,Ut);return a!==Ut&&!!e.call(u,a,r,t)},n.get=function(r,a){var o=t.get(r,Ut);return o!==Ut&&e.call(u,o,r,t)?o:a}),n.__iterateUncached=function(r,a){var o=this,l=0;return t.__iterate(function(c,d,h){if(e.call(u,c,d,h))return l++,r(c,s?d:l-1,o)},a),l},n.__iteratorUncached=function(r,a){var o=t.__iterator(oi,a),l=0;return new kt(function(){for(;;){var c=o.next();if(c.done)return c;var d=c.value,h=d[0],f=d[1];if(e.call(u,f,h,t))return mr(r,s?h:l++,f,c)}})},n}function hQ(t,e,u){var s=Ya().asMutable();return t.__iterate(function(n,r){s.update(e.call(u,n,r,t),0,function(a){return a+1})}),s.asImmutable()}function pQ(t,e,u){var s=cr(t),n=(Xn(t)?Ei():Ya()).asMutable();t.__iterate(function(a,o){n.update(e.call(u,a,o,t),function(l){return l=l||[],l.push(s?[o,a]:a),l})});var r=eT(t);return n.map(function(a){return ur(t,r(a))}).asImmutable()}function yQ(t,e,u){var s=cr(t),n=[[],[]];t.__iterate(function(a,o){n[e.call(u,a,o,t)?1:0].push(s?[o,a]:a)});var r=eT(t);return n.map(function(a){return ur(t,r(a))})}function Z3(t,e,u,s){var n=t.size;if(ry(e,u,n))return t;if(typeof n>"u"&&(e<0||u<0))return Z3(t.toSeq().cacheResult(),e,u,s);var r=Go(e,n),a=ny(u,n),o=a-r,l;o===o&&(l=o<0?0:o);var c=Vi(t);return c.size=l===0?l:t.size&&l||void 0,!s&&iy(t)&&l>=0&&(c.get=function(d,h){return d=ka(this,d),d>=0&&dl)return Dn();var b=f.next();return s||d===Ai||b.done?b:d===ay?mr(d,y-1,void 0,b):mr(d,y-1,b.value[1],b)})},c}function bQ(t,e,u){var s=Vi(t);return s.__iterateUncached=function(n,r){var a=this;if(r)return this.cacheResult().__iterate(n,r);var o=0;return t.__iterate(function(l,c,d){return e.call(u,l,c,d)&&++o&&n(l,c,a)}),o},s.__iteratorUncached=function(n,r){var a=this;if(r)return this.cacheResult().__iterator(n,r);var o=t.__iterator(oi,r),l=!0;return new kt(function(){if(!l)return Dn();var c=o.next();if(c.done)return c;var d=c.value,h=d[0],f=d[1];return e.call(u,f,h,a)?n===oi?c:mr(n,h,f,c):(l=!1,Dn())})},s}function K9(t,e,u,s){var n=Vi(t);return n.__iterateUncached=function(r,a){var o=this;if(a)return this.cacheResult().__iterate(r,a);var l=!0,c=0;return t.__iterate(function(d,h,f){if(!(l&&(l=e.call(u,d,h,f))))return c++,r(d,s?h:c-1,o)}),c},n.__iteratorUncached=function(r,a){var o=this;if(a)return this.cacheResult().__iterator(r,a);var l=t.__iterator(oi,a),c=!0,d=0;return new kt(function(){var h,f,p;do{if(h=l.next(),h.done)return s||r===Ai?h:r===ay?mr(r,d++,void 0,h):mr(r,d++,h.value[1],h);var y=h.value;f=y[0],p=y[1],c&&(c=e.call(u,p,f,o))}while(c);return r===oi?h:mr(r,f,p,h)})},n}function gQ(t,e){var u=cr(t),s=[t].concat(e).map(function(a){return fn(a)?u&&(a=ci(a)):a=u?X3(a):$9(Array.isArray(a)?a:[a]),a}).filter(function(a){return a.size!==0});if(s.length===0)return t;if(s.length===1){var n=s[0];if(n===t||u&&cr(n)||an(t)&&an(n))return n}var r=new zs(s);return u?r=r.toKeyedSeq():an(t)||(r=r.toSetSeq()),r=r.flatten(!0),r.size=s.reduce(function(a,o){if(a!==void 0){var l=o.size;if(l!==void 0)return a+l}},0),r}function Y9(t,e,u){var s=Vi(t);return s.__iterateUncached=function(n,r){if(r)return this.cacheResult().__iterate(n,r);var a=0,o=!1;function l(c,d){c.__iterate(function(h,f){return(!e||d0}function Xy(t,e,u,s){var n=Vi(t),r=new zs(u).map(function(a){return a.size});return n.size=s?r.max():r.min(),n.__iterate=function(a,o){for(var l=this.__iterator(Ai,o),c,d=0;!(c=l.next()).done&&a(c.value,d++,this)!==!1;);return d},n.__iteratorUncached=function(a,o){var l=u.map(function(h){return h=gr(h),WS(o?h.reverse():h)}),c=0,d=!1;return new kt(function(){var h;return d||(h=l.map(function(f){return f.next()}),d=s?h.every(function(f){return f.done}):h.some(function(f){return f.done})),d?Dn():mr(a,c++,e.apply(null,h.map(function(f){return f.value})))})},n}function ur(t,e){return t===e?t:iy(t)?e:t.constructor(e)}function fE(t){if(t!==Object(t))throw new TypeError("Expected [K, V] tuple: "+t)}function eT(t){return cr(t)?ci:an(t)?Xs:Jo}function Vi(t){return Object.create((cr(t)?Xa:an(t)?li:Yo).prototype)}function tT(){return this._iter.cacheResult?(this._iter.cacheResult(),this.size=this._iter.size,this):hn.prototype.cacheResult.call(this)}function Z9(t,e){return t===void 0&&e===void 0?0:t===void 0?1:e===void 0?-1:t>e?1:t0;)e[u]=arguments[u+1];if(typeof t!="function")throw new TypeError("Invalid merger function: "+t);return iF(this,e,t)}function iF(t,e,u){for(var s=[],n=0;n0;)e[u]=arguments[u+1];return uy(t,e)}function sF(t,e){for(var u=[],s=arguments.length-2;s-- >0;)u[s]=arguments[s+2];return uy(e,u,t)}function oF(t){for(var e=[],u=arguments.length-1;u-- >0;)e[u]=arguments[u+1];return oy(t,e)}function uF(t,e){for(var u=[],s=arguments.length-2;s-- >0;)u[s]=arguments[s+2];return oy(e,u,t)}function oy(t,e,u){return uy(t,e,wQ(u))}function uy(t,e,u){if(!za(t))throw new TypeError("Cannot merge into non-data-structure value: "+t);if(Yn(t))return typeof u=="function"&&t.mergeWith?t.mergeWith.apply(t,[u].concat(e)):t.merge?t.merge.apply(t,e):t.concat.apply(t,e);for(var s=Array.isArray(t),n=t,r=s?Xs:ci,a=s?function(l){n===t&&(n=X1(n)),n.push(l)}:function(l,c){var d=Ko.call(n,c),h=d&&u?u(n[c],l,c):l;(!d||h!==n[c])&&(n===t&&(n=X1(n)),n[c]=h)},o=0;o0;)e[u]=arguments[u+1];return oy(this,e,t)}function fT(t){for(var e=[],u=arguments.length-1;u-- >0;)e[u]=arguments[u+1];return Ka(this,t,_i(),function(s){return uy(s,e)})}function hT(t){for(var e=[],u=arguments.length-1;u-- >0;)e[u]=arguments[u+1];return Ka(this,t,_i(),function(s){return oy(s,e)})}function cy(t){var e=this.asMutable();return t(e),e.wasAltered()?e.__ensureOwner(this.__ownerID):this}function ly(){return this.__ownerID?this:this.__ensureOwner(new k3)}function dy(){return this.__ensureOwner()}function pT(){return this.__altered}var Ya=function(t){function e(u){return u==null?_i():sy(u)&&!Xn(u)?u:_i().withMutations(function(s){var n=t(u);Wn(n.size),n.forEach(function(r,a){return s.set(a,r)})})}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.of=function(){for(var s=[],n=arguments.length;n--;)s[n]=arguments[n];return _i().withMutations(function(r){for(var a=0;a=s.length)throw new Error("Missing value for key: "+s[a]);r.set(s[a],s[a+1])}})},e.prototype.toString=function(){return this.__toString("Map {","}")},e.prototype.get=function(s,n){return this._root?this._root.get(0,void 0,s,n):n},e.prototype.set=function(s,n){return yE(this,s,n)},e.prototype.remove=function(s){return yE(this,s,Ut)},e.prototype.deleteAll=function(s){var n=gr(s);return n.size===0?this:this.withMutations(function(r){n.forEach(function(a){return r.remove(a)})})},e.prototype.clear=function(){return this.size===0?this:this.__ownerID?(this.size=0,this._root=null,this.__hash=void 0,this.__altered=!0,this):_i()},e.prototype.sort=function(s){return Ei(jo(this,s))},e.prototype.sortBy=function(s,n){return Ei(jo(this,n,s))},e.prototype.map=function(s,n){var r=this;return this.withMutations(function(a){a.forEach(function(o,l){a.set(l,s.call(n,o,l,r))})})},e.prototype.__iterator=function(s,n){return new TQ(this,s,n)},e.prototype.__iterate=function(s,n){var r=this,a=0;return this._root&&this._root.iterate(function(o){return a++,s(o[1],o[0],r)},n),a},e.prototype.__ensureOwner=function(s){return s===this.__ownerID?this:s?yT(this.size,this._root,s,this.__hash):this.size===0?_i():(this.__ownerID=s,this.__altered=!1,this)},e}(ci);Ya.isMap=sy;var _r=Ya.prototype;_r[Q9]=!0;_r[ty]=_r.remove;_r.removeAll=_r.deleteAll;_r.setIn=oT;_r.removeIn=_r.deleteIn=cT;_r.update=lT;_r.updateIn=dT;_r.merge=_r.concat=rF;_r.mergeWith=nF;_r.mergeDeep=cF;_r.mergeDeepWith=lF;_r.mergeIn=fT;_r.mergeDeepIn=hT;_r.withMutations=cy;_r.wasAltered=pT;_r.asImmutable=dy;_r["@@transducer/init"]=_r.asMutable=ly;_r["@@transducer/step"]=function(t,e){return t.set(e[0],e[1])};_r["@@transducer/result"]=function(t){return t.asImmutable()};var V0=function(e,u){this.ownerID=e,this.entries=u};V0.prototype.get=function(e,u,s,n){for(var r=this.entries,a=0,o=r.length;a=IQ)return AQ(e,c,n,r);var p=e&&e===this.ownerID,y=p?c:Hi(c);return f?l?d===h-1?y.pop():y[d]=y.pop():y[d]=[n,r]:y.push([n,r]),p?(this.entries=y,this):new V0(e,y)}};var Lo=function(e,u,s){this.ownerID=e,this.bitmap=u,this.nodes=s};Lo.prototype.get=function(e,u,s,n){u===void 0&&(u=xn(s));var r=1<<((e===0?u:u>>>e)&In),a=this.bitmap;return a&r?this.nodes[dF(a&r-1)].get(e+br,u,s,n):n};Lo.prototype.update=function(e,u,s,n,r,a,o){s===void 0&&(s=xn(n));var l=(u===0?s:s>>>u)&In,c=1<=PQ)return OQ(e,p,d,l,b);if(h&&!b&&p.length===2&&bE(p[f^1]))return p[f^1];if(h&&b&&p.length===1&&bE(b))return b;var m=e&&e===this.ownerID,g=h?b?d:d^c:d|c,v=h?b?fF(p,f,b,m):xQ(p,f,m):RQ(p,f,b,m);return m?(this.bitmap=g,this.nodes=v,this):new Lo(e,g,v)};var k0=function(e,u,s){this.ownerID=e,this.count=u,this.nodes=s};k0.prototype.get=function(e,u,s,n){u===void 0&&(u=xn(s));var r=(e===0?u:u>>>e)&In,a=this.nodes[r];return a?a.get(e+br,u,s,n):n};k0.prototype.update=function(e,u,s,n,r,a,o){s===void 0&&(s=xn(n));var l=(u===0?s:s>>>u)&In,c=r===Ut,d=this.nodes,h=d[l];if(c&&!h)return this;var f=bT(h,e,u+br,s,n,r,a,o);if(f===h)return this;var p=this.count;if(!h)p++;else if(!f&&(p--,p>>u)&In,a=(u===0?s:s>>>u)&In,o,l=r===a?[gT(t,e,u+br,s,n)]:(o=new _a(e,s,n),r>>=1)a[o]=u&1?e[r++]:void 0;return a[s]=n,new k0(t,r+1,a)}function dF(t){return t-=t>>1&1431655765,t=(t&858993459)+(t>>2&858993459),t=t+(t>>4)&252645135,t+=t>>8,t+=t>>16,t&127}function fF(t,e,u,s){var n=s?t:Hi(t);return n[e]=u,n}function RQ(t,e,u,s){var n=t.length+1;if(s&&e+1===n)return t[e]=u,t;for(var r=new Array(n),a=0,o=0;o0&&r=0&&s>>u&In;if(n>=this.array.length)return new Ha([],e);var r=n===0,a;if(u>0){var o=this.array[n];if(a=o&&o.removeBefore(e,u-br,s),a===o&&r)return this}if(r&&!a)return this;var l=Fo(this,e);if(!r)for(var c=0;c>>u&In;if(n>=this.array.length)return this;var r;if(u>0){var a=this.array[n];if(r=a&&a.removeAfter(e,u-br,s),r===a&&n===this.array.length-1)return this}var o=Fo(this,e);return o.array.splice(n+1),r&&(o.array[n]=r),o};var j0={};function gE(t,e){var u=t._origin,s=t._capacity,n=G0(s),r=t._tail;return a(t._root,t._level,0);function a(c,d,h){return d===0?o(c,h):l(c,d,h)}function o(c,d){var h=d===n?r&&r.array:c&&c.array,f=d>u?0:u-d,p=s-d;return p>ai&&(p=ai),function(){if(f===p)return j0;var y=e?--p:f++;return h&&h[y]}}function l(c,d,h){var f,p=c&&c.array,y=h>u?0:u-h>>d,b=(s-h>>d)+1;return b>ai&&(b=ai),function(){for(;;){if(f){var m=f();if(m!==j0)return m;f=null}if(y===b)return j0;var g=e?--b:y++;f=a(p&&p[g],d-br,h+(g<=t.size||e<0)return t.withMutations(function(a){e<0?La(a,e).set(0,u):La(a,0,e+1).set(e,u)});e+=t._origin;var s=t._tail,n=t._root,r=zS();return e>=G0(t._capacity)?s=YS(s,t.__ownerID,0,e,u,r):n=YS(n,t.__ownerID,t._level,e,u,r),r.value?t.__ownerID?(t._root=n,t._tail=s,t.__hash=void 0,t.__altered=!0,t):z0(t._origin,t._capacity,t._level,n,s):t}function YS(t,e,u,s,n,r){var a=s>>>u&In,o=t&&a0){var c=t&&t.array[a],d=YS(c,e,u-br,s,n,r);return d===c?t:(l=Fo(t,e),l.array[a]=d,l)}return o&&t.array[a]===n?t:(r&&si(r),l=Fo(t,e),n===void 0&&a===l.array.length-1?l.array.pop():l.array[a]=n,l)}function Fo(t,e){return e&&t&&e===t.ownerID?t:new Ha(t?t.array.slice():[],e)}function pF(t,e){if(e>=G0(t._capacity))return t._tail;if(e<1<0;)u=u.array[e>>>s&In],s-=br;return u}}function La(t,e,u){e!==void 0&&(e|=0),u!==void 0&&(u|=0);var s=t.__ownerID||new k3,n=t._origin,r=t._capacity,a=n+e,o=u===void 0?r:u<0?r+u:n+u;if(a===n&&o===r)return t;if(a>=o)return t.clear();for(var l=t._level,c=t._root,d=0;a+d<0;)c=new Ha(c&&c.array.length?[void 0,c]:[],s),l+=br,d+=1<=1<h?new Ha([],s):p;if(p&&f>h&&abr;m-=br){var g=h>>>m&In;b=b.array[g]=Fo(b.array[g],s)}b.array[h>>>br&In]=p}if(o=f)a-=f,o-=f,l=br,c=null,y=y&&y.removeBefore(s,0,a);else if(a>n||f>>l&In;if(v!==f>>>l&In)break;v&&(d+=(1<n&&(c=c.removeBefore(s,l,a-d)),c&&f>>br<=ai&&n.size>=s.size*2?(l=n.filter(function(c,d){return c!==void 0&&r!==d}),o=l.toKeyedSeq().map(function(c){return c[0]}).flip().toMap(),t.__ownerID&&(o.__ownerID=l.__ownerID=t.__ownerID)):(o=s.remove(e),l=r===n.size-1?n.pop():n.set(r,void 0))}else if(a){if(u===n.get(r)[1])return t;o=s,l=n.set(r,[e,u])}else o=s.set(e,n.size),l=n.set(n.size,[e,u]);return t.__ownerID?(t.size=o.size,t._map=o,t._list=l,t.__hash=void 0,t.__altered=!0,t):mT(o,l)}var yF="@@__IMMUTABLE_STACK__@@";function W0(t){return!!(t&&t[yF])}var fy=function(t){function e(u){return u==null?Ky():W0(u)?u:Ky().pushAll(u)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.of=function(){return this(arguments)},e.prototype.toString=function(){return this.__toString("Stack [","]")},e.prototype.get=function(s,n){var r=this._head;for(s=ka(this,s);r&&s--;)r=r.next;return r?r.value:n},e.prototype.peek=function(){return this._head&&this._head.value},e.prototype.push=function(){var s=arguments;if(arguments.length===0)return this;for(var n=this.size+arguments.length,r=this._head,a=arguments.length-1;a>=0;a--)r={value:s[a],next:r};return this.__ownerID?(this.size=n,this._head=r,this.__hash=void 0,this.__altered=!0,this):v0(n,r)},e.prototype.pushAll=function(s){if(s=t(s),s.size===0)return this;if(this.size===0&&W0(s))return s;Wn(s.size);var n=this.size,r=this._head;return s.__iterate(function(a){n++,r={value:a,next:r}},!0),this.__ownerID?(this.size=n,this._head=r,this.__hash=void 0,this.__altered=!0,this):v0(n,r)},e.prototype.pop=function(){return this.slice(1)},e.prototype.clear=function(){return this.size===0?this:this.__ownerID?(this.size=0,this._head=void 0,this.__hash=void 0,this.__altered=!0,this):Ky()},e.prototype.slice=function(s,n){if(ry(s,n,this.size))return this;var r=Go(s,this.size),a=ny(n,this.size);if(a!==this.size)return t.prototype.slice.call(this,s,n);for(var o=this.size-r,l=this._head;r--;)l=l.next;return this.__ownerID?(this.size=o,this._head=l,this.__hash=void 0,this.__altered=!0,this):v0(o,l)},e.prototype.__ensureOwner=function(s){return s===this.__ownerID?this:s?v0(this.size,this._head,s,this.__hash):this.size===0?Ky():(this.__ownerID=s,this.__altered=!1,this)},e.prototype.__iterate=function(s,n){var r=this;if(n)return new zs(this.toArray()).__iterate(function(l,c){return s(l,c,r)},n);for(var a=0,o=this._head;o&&s(o.value,a++,this)!==!1;)o=o.next;return a},e.prototype.__iterator=function(s,n){if(n)return new zs(this.toArray()).__iterator(s,n);var r=0,a=this._head;return new kt(function(){if(a){var o=a.value;return a=a.next,mr(s,r++,o)}return Dn()})},e}(Xs);fy.isStack=W0;var Nn=fy.prototype;Nn[yF]=!0;Nn.shift=Nn.pop;Nn.unshift=Nn.push;Nn.unshiftAll=Nn.pushAll;Nn.withMutations=cy;Nn.wasAltered=pT;Nn.asImmutable=dy;Nn["@@transducer/init"]=Nn.asMutable=ly;Nn["@@transducer/step"]=function(t,e){return t.unshift(e)};Nn["@@transducer/result"]=function(t){return t.asImmutable()};function v0(t,e,u,s){var n=Object.create(Nn);return n.size=t,n._head=e,n.__ownerID=u,n.__hash=s,n.__altered=!1,n}var wE;function Ky(){return wE||(wE=v0(0))}var bF="@@__IMMUTABLE_SET__@@";function hy(t){return!!(t&&t[bF])}function Ob(t){return hy(t)&&Xn(t)}function _T(t,e){if(t===e)return!0;if(!fn(e)||t.size!==void 0&&e.size!==void 0&&t.size!==e.size||t.__hash!==void 0&&e.__hash!==void 0&&t.__hash!==e.__hash||cr(t)!==cr(e)||an(t)!==an(e)||Xn(t)!==Xn(e))return!1;if(t.size===0&&e.size===0)return!0;var u=!Wo(t);if(Xn(t)){var s=t.entries();return e.every(function(l,c){var d=s.next().value;return d&&kr(d[1],l)&&(u||kr(d[0],c))})&&s.next().done}var n=!1;if(t.size===void 0)if(e.size===void 0)typeof t.cacheResult=="function"&&t.cacheResult();else{n=!0;var r=t;t=e,e=r}var a=!0,o=e.__iterate(function(l,c){if(u?!t.has(l):n?!kr(l,t.get(c,Ut)):!kr(t.get(c,Ut),l))return a=!1,!1});return a&&t.size===o}function Ks(t,e){var u=function(s){t.prototype[s]=e[s]};return Object.keys(e).forEach(u),Object.getOwnPropertySymbols&&Object.getOwnPropertySymbols(e).forEach(u),t}function K1(t){if(!t||typeof t!="object")return t;if(!fn(t)){if(!za(t))return t;t=hn(t)}if(cr(t)){var e={};return t.__iterate(function(s,n){e[n]=K1(s)}),e}var u=[];return t.__iterate(function(s){u.push(K1(s))}),u}var eu=function(t){function e(u){return u==null?w0():hy(u)&&!Xn(u)?u:w0().withMutations(function(s){var n=t(u);Wn(n.size),n.forEach(function(r){return s.add(r)})})}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.of=function(){return this(arguments)},e.fromKeys=function(s){return this(ci(s).keySeq())},e.intersect=function(s){return s=gr(s).toArray(),s.length?sn.intersect.apply(e(s.pop()),s):w0()},e.union=function(s){return s=gr(s).toArray(),s.length?sn.union.apply(e(s.pop()),s):w0()},e.prototype.toString=function(){return this.__toString("Set {","}")},e.prototype.has=function(s){return this._map.has(s)},e.prototype.add=function(s){return Yy(this,this._map.set(s,s))},e.prototype.remove=function(s){return Yy(this,this._map.remove(s))},e.prototype.clear=function(){return Yy(this,this._map.clear())},e.prototype.map=function(s,n){var r=this,a=!1,o=Yy(this,this._map.mapEntries(function(l){var c=l[1],d=s.call(n,c,c,r);return d!==c&&(a=!0),[d,d]},n));return a?o:this},e.prototype.union=function(){for(var s=[],n=arguments.length;n--;)s[n]=arguments[n];return s=s.filter(function(r){return r.size!==0}),s.length===0?this:this.size===0&&!this.__ownerID&&s.length===1?this.constructor(s[0]):this.withMutations(function(r){for(var a=0;a=0&&n=0&&rthis.size?u:this.find(function(s,n){return n===e},void 0,u)},has:function(e){return e=ka(this,e),e>=0&&(this.size!==void 0?this.size===1/0||ee?-1:0}function MQ(t){if(t.size===1/0)return 0;var e=Xn(t),u=cr(t),s=e?1:0,n=t.__iterate(u?e?function(r,a){s=31*s+RE(xn(r),xn(a))|0}:function(r,a){s=s+RE(xn(r),xn(a))|0}:e?function(r){s=31*s+xn(r)|0}:function(r){s=s+xn(r)|0});return FQ(n,s)}function FQ(t,e){return e=pu(e,3432918353),e=pu(e<<15|e>>>-15,461845907),e=pu(e<<13|e>>>-13,5),e=(e+3864292196|0)^t,e=pu(e^e>>>16,2246822507),e=pu(e^e>>>13,3266489909),e=vb(e^e>>>16),e}function RE(t,e){return t^e+2654435769+(t<<6)+(t>>2)|0}var Gs=function(t){function e(u){return u==null?ZS():Ob(u)?u:ZS().withMutations(function(s){var n=Jo(u);Wn(n.size),n.forEach(function(r){return s.add(r)})})}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.of=function(){return this(arguments)},e.fromKeys=function(s){return this(ci(s).keySeq())},e.prototype.toString=function(){return this.__toString("OrderedSet {","}")},e}(eu);Gs.isOrderedSet=Ob;var Ys=Gs.prototype;Ys[Xo]=!0;Ys.zip=tu.zip;Ys.zipWith=tu.zipWith;Ys.zipAll=tu.zipAll;Ys.__empty=ZS;Ys.__make=vF;function vF(t,e){var u=Object.create(Ys);return u.size=t?t.size:0,u._map=t,u.__ownerID=e,u}var xE;function ZS(){return xE||(xE=vF(_0()))}var wF={LeftThenRight:-1,RightThenLeft:1};function qQ(t){if(Ja(t))throw new Error("Can not call `Record` with an immutable Record as default values. Use a plain javascript object instead.");if(Yn(t))throw new Error("Can not call `Record` with an immutable Collection as default values. Use a plain javascript object instead.");if(t===null||typeof t!="object")throw new Error("Can not call `Record` with a non-object as default values. Use a plain javascript object instead.")}var Ur=function(e,u){var s;qQ(e);var n=function(o){var l=this;if(o instanceof n)return o;if(!(this instanceof n))return new n(o);if(!s){s=!0;var c=Object.keys(e),d=r._indices={};r._name=u,r._keys=c,r._defaultValues=e;for(var h=0;h2?[]:void 0,{"":t})}function AF(t,e,u,s,n,r){if(typeof u!="string"&&!Yn(u)&&(G3(u)||z3(u)||Sb(u))){if(~t.indexOf(u))throw new TypeError("Cannot convert circular structure to Immutable");t.push(u),n&&s!==""&&n.push(s);var a=e.call(r,s,hn(u).map(function(o,l){return AF(t,e,o,l,n,u)}),n&&n.slice());return t.pop(),n&&n.pop(),a}return u}function UQ(t,e){return an(e)?e.toList():cr(e)?e.toMap():e.toSet()}var EF="4.3.7",HQ={version:EF,Collection:gr,Iterable:gr,Seq:hn,Map:Ya,OrderedMap:Ei,List:Zo,Stack:fy,Set:eu,OrderedSet:Gs,PairSorting:wF,Record:Ur,Range:vT,Repeat:SF,is:kr,fromJS:TF,hash:xn,isImmutable:Yn,isCollection:fn,isKeyed:cr,isIndexed:an,isAssociative:Wo,isOrdered:Xn,isValueObject:J1,isPlainObject:Sb,isSeq:iy,isList:Eb,isMap:sy,isOrderedMap:_b,isStack:W0,isSet:hy,isOrderedSet:Ob,isRecord:Ja,get:Tb,getIn:Rb,has:nT,hasIn:wT,merge:aF,mergeDeep:oF,mergeWith:sF,mergeDeepWith:uF,remove:iT,removeIn:uT,set:aT,setIn:sT,update:Ab,updateIn:Ka},$Q=gr;const QQ=Object.freeze(Object.defineProperty({__proto__:null,Collection:gr,Iterable:$Q,List:Zo,Map:Ya,OrderedMap:Ei,OrderedSet:Gs,PairSorting:wF,Range:vT,Record:Ur,Repeat:SF,Seq:hn,Set:eu,Stack:fy,default:HQ,fromJS:TF,get:Tb,getIn:Rb,has:nT,hasIn:wT,hash:xn,is:kr,isAssociative:Wo,isCollection:fn,isImmutable:Yn,isIndexed:an,isKeyed:cr,isList:Eb,isMap:sy,isOrdered:Xn,isOrderedMap:_b,isOrderedSet:Ob,isPlainObject:Sb,isRecord:Ja,isSeq:iy,isSet:hy,isStack:W0,isValueObject:J1,merge:aF,mergeDeep:oF,mergeDeepWith:uF,mergeWith:sF,remove:iT,removeIn:uT,set:aT,setIn:sT,update:Ab,updateIn:Ka,version:EF},Symbol.toStringTag,{value:"Module"})),AT=Q3(QQ);Object.defineProperty(ks,"__esModule",{value:!0});ks.ActionContextKey=ks.ActionContext=void 0;const IE=AT;class To{constructor(e={}){this.map=(0,IE.Map)(e)}setDefault(e,u){return this.has(e)?this:this.set(e,u)}set(e,u){return this.setRaw(e.name,u)}setRaw(e,u){return new To(this.map.set(e,u))}delete(e){return new To(this.map.delete(e.name))}get(e){return this.getRaw(e.name)}getRaw(e){return this.map.get(e)}getSafe(e){if(!this.has(e))throw new Error(`Context entry ${e.name} is required but not available`);return this.get(e)}has(e){return this.hasRaw(e.name)}hasRaw(e){return this.map.has(e)}merge(...e){let u=this;for(const s of e)for(const n of s.keys())u=u.set(n,s.get(n));return u}keys(){return[...this.map.keys()].map(e=>new OF(e))}toJS(){return this.map.toJS()}toString(){return`ActionContext(${JSON.stringify(this.map.toJS())})`}[Symbol.for("nodejs.util.inspect.custom")](){return`ActionContext(${JSON.stringify(this.map.toJS(),null," ")})`}static ensureActionContext(e){return e instanceof To?e:new To((0,IE.Map)(e??{}))}}ks.ActionContext=To;class OF{constructor(e){this.name=e}}ks.ActionContextKey=OF;var yy={};Object.defineProperty(yy,"__esModule",{value:!0});yy.Bus=void 0;class VQ{constructor(e){this.actors=[],this.observers=[],this.dependencyLinks=new Map,Object.assign(this,e)}subscribe(e){this.actors.push(e),this.reorderForDependencies()}subscribeObserver(e){this.observers.push(e)}unsubscribe(e){const u=this.actors.indexOf(e);return u>=0?(this.actors.splice(u,1),!0):!1}unsubscribeObserver(e){const u=this.observers.indexOf(e);return u>=0?(this.observers.splice(u,1),!0):!1}publish(e){return this.actors.map(u=>({actor:u,reply:u.test(e)}))}onRun(e,u,s){for(const n of this.observers)n.onRun(e,u,s)}addDependencies(e,u){for(const s of u){let n=this.dependencyLinks.get(s);n||(n=[],this.dependencyLinks.set(s,n)),n.push(e)}this.reorderForDependencies()}reorderForDependencies(){if(this.dependencyLinks.size>0){const e=[];for(const u of this.dependencyLinks.keys()){const s=this.actors.indexOf(u);s>=0&&(this.actors.splice(s,1),e.push(u))}for(;e.length>0;){let u=-1;for(let n=0;n=0&&s.splice(n,1),s.length===0&&delete this.actorsIndex[u]}return super.unsubscribe(e)}publish(e){const u=this.getActionIdentifier(e);return u?[...this.actorsIndex[u]||[],...this.actorsIndex._undefined_||[]].map(n=>({actor:n,reply:n.test(e)})):super.publish(e)}getActorIdentifier(e){return this.actorIdentifierFields.reduce((u,s)=>u[s],e)}getActionIdentifier(e){return this.actionIdentifierFields.reduce((u,s)=>u[s],e)}}xb.BusIndexed=zQ;var by={};Object.defineProperty(by,"__esModule",{value:!0});by.CONTEXT_KEY_LOGGER=void 0;const GQ=ks;by.CONTEXT_KEY_LOGGER=new GQ.ActionContextKey("@comunica/core:log");var Ib={};Object.defineProperty(Ib,"__esModule",{value:!0});Ib.ActionObserver=void 0;class WQ{constructor(e){Object.assign(this,e)}}Ib.ActionObserver=WQ;var Pb={};Object.defineProperty(Pb,"__esModule",{value:!0});Pb.Actor=void 0;const JQ=by;class Ma{constructor(e){this.beforeActors=[],Object.assign(this,e),this.bus.subscribe(this),this.beforeActors.length>0&&this.bus.addDependencies(this,this.beforeActors)}static getContextLogger(e){return e.get(JQ.CONTEXT_KEY_LOGGER)}runObservable(e){const u=this.run(e);return this.bus.onRun(this,e,u),u}async initialize(){return!0}async deinitialize(){return!0}getDefaultLogData(e,u){const s=u?u():{};return s.actor=this.name,s}logTrace(e,u,s){const n=Ma.getContextLogger(e);n&&n.trace(u,this.getDefaultLogData(e,s))}logDebug(e,u,s){const n=Ma.getContextLogger(e);n&&n.debug(u,this.getDefaultLogData(e,s))}logInfo(e,u,s){const n=Ma.getContextLogger(e);n&&n.info(u,this.getDefaultLogData(e,s))}logWarn(e,u,s){const n=Ma.getContextLogger(e);n&&n.warn(u,this.getDefaultLogData(e,s))}logError(e,u,s){const n=Ma.getContextLogger(e);n&&n.error(u,this.getDefaultLogData(e,s))}logFatal(e,u,s){const n=Ma.getContextLogger(e);n&&n.fatal(u,this.getDefaultLogData(e,s))}}Pb.Actor=Ma;var Db={};Object.defineProperty(Db,"__esModule",{value:!0});Db.Mediator=void 0;class XQ{constructor(e){Object.assign(this,e)}publish(e){const u=this.bus.publish(e);if(u.length===0)throw new Error(`No actors are able to reply to a message in the bus ${this.bus.name}`);return u}async mediateActor(e){return await this.mediateWith(e,this.publish(e))}async mediate(e){return(await this.mediateActor(e)).runObservable(e)}}Db.Mediator=XQ;(function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(ks,t),u(yy,t),u(xb,t),u(by,t),u(Ib,t),u(Pb,t),u(Db,t)})(ot);Object.defineProperty(bb,"__esModule",{value:!0});bb.ActorInit=void 0;const KQ=ot;class YQ extends KQ.Actor{constructor(e){super(e)}}bb.ActorInit=YQ;(function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(bb,t)})(N9);Object.defineProperty(ey,"__esModule",{value:!0});ey.ActorInitQueryBase=void 0;const ZQ=N9;class eV extends ZQ.ActorInit{async test(e){return!0}async run(e){throw new Error("ActorInitSparql#run is not supported in the browser.")}}ey.ActorInitQueryBase=eV;var Nb={},Dg={exports:{}},PE;function Sa(){if(PE)return Dg.exports;PE=1;var t=Dg.exports={},e,u;function s(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?e=setTimeout:e=s}catch{e=s}try{typeof clearTimeout=="function"?u=clearTimeout:u=n}catch{u=n}})();function r(b){if(e===setTimeout)return setTimeout(b,0);if((e===s||!e)&&setTimeout)return e=setTimeout,setTimeout(b,0);try{return e(b,0)}catch{try{return e.call(null,b,0)}catch{return e.call(this,b,0)}}}function a(b){if(u===clearTimeout)return clearTimeout(b);if((u===n||!u)&&clearTimeout)return u=clearTimeout,clearTimeout(b);try{return u(b)}catch{try{return u.call(null,b)}catch{return u.call(this,b)}}}var o=[],l=!1,c,d=-1;function h(){!l||!c||(l=!1,c.length?o=c.concat(o):d=-1,o.length&&f())}function f(){if(!l){var b=r(h);l=!0;for(var m=o.length;m;){for(c=o,o=[];++d1)for(var g=1;g"u"&&(globalThis.process=Sa());class rV extends tV.ActorInitQueryBase{}Nb.ActorInitQuery=rV;var Cb={},Lt={},ar={};Object.defineProperty(ar,"__esModule",{value:!0});ar.KeysRdfJoin=ar.KeysMergeBindingsContext=ar.KeysRdfUpdateQuads=ar.KeysQuerySourceIdentify=ar.KeysRdfParseHtmlScript=ar.KeysRdfParseJsonLd=ar.KeysQueryOperation=ar.KeysInitQuery=ar.KeysHttpProxy=ar.KeysHttpMemento=ar.KeysHttpWayback=ar.KeysHttp=ar.KeysCore=void 0;const vt=ot;ar.KeysCore={log:vt.CONTEXT_KEY_LOGGER};ar.KeysHttp={includeCredentials:new vt.ActionContextKey("@comunica/bus-http:include-credentials"),auth:new vt.ActionContextKey("@comunica/bus-http:auth"),fetch:new vt.ActionContextKey("@comunica/bus-http:fetch"),httpTimeout:new vt.ActionContextKey("@comunica/bus-http:http-timeout"),httpBodyTimeout:new vt.ActionContextKey("@comunica/bus-http:http-body-timeout"),httpRetryCount:new vt.ActionContextKey("@comunica/bus-http:http-retry-count"),httpRetryDelay:new vt.ActionContextKey("@comunica/bus-http:http-retry-delay"),httpRetryOnServerError:new vt.ActionContextKey("@comunica/bus-http:http-retry-on-server-error")};ar.KeysHttpWayback={recoverBrokenLinks:new vt.ActionContextKey("@comunica/bus-http:recover-broken-links")};ar.KeysHttpMemento={datetime:new vt.ActionContextKey("@comunica/actor-http-memento:datetime")};ar.KeysHttpProxy={httpProxyHandler:new vt.ActionContextKey("@comunica/actor-http-proxy:httpProxyHandler")};ar.KeysInitQuery={querySourcesUnidentified:new vt.ActionContextKey("@comunica/actor-init-query:querySourcesUnidentified"),initialBindings:new vt.ActionContextKey("@comunica/actor-init-query:initialBindings"),queryFormat:new vt.ActionContextKey("@comunica/actor-init-query:queryFormat"),graphqlSingularizeVariables:new vt.ActionContextKey("@comunica/actor-init-query:singularizeVariables"),lenient:new vt.ActionContextKey("@comunica/actor-init-query:lenient"),queryString:new vt.ActionContextKey("@comunica/actor-init-query:queryString"),query:new vt.ActionContextKey("@comunica/actor-init-query:query"),baseIRI:new vt.ActionContextKey("@comunica/actor-init-query:baseIRI"),functionArgumentsCache:new vt.ActionContextKey("@comunica/actor-init-query:functionArgumentsCache"),queryTimestamp:new vt.ActionContextKey("@comunica/actor-init-query:queryTimestamp"),extensionFunctionCreator:new vt.ActionContextKey("@comunica/actor-init-query:extensionFunctionCreator"),extensionFunctions:new vt.ActionContextKey("@comunica/actor-init-query:extensionFunctions"),cliArgsHandlers:new vt.ActionContextKey("@comunica/actor-init-query:cliArgsHandlers"),explain:new vt.ActionContextKey("@comunica/actor-init-query:explain"),physicalQueryPlanLogger:new vt.ActionContextKey("@comunica/actor-init-query:physicalQueryPlanLogger"),physicalQueryPlanNode:new vt.ActionContextKey("@comunica/actor-init-query:physicalQueryPlanNode"),jsonLdContext:new vt.ActionContextKey("@context"),noCache:new vt.ActionContextKey("@comunica/actor-init-query:noCache")};ar.KeysQueryOperation={operation:new vt.ActionContextKey("@comunica/bus-query-operation:operation"),joinLeftMetadata:new vt.ActionContextKey("@comunica/bus-query-operation:joinLeftMetadata"),joinRightMetadatas:new vt.ActionContextKey("@comunica/bus-query-operation:joinRightMetadatas"),joinBindings:new vt.ActionContextKey("@comunica/bus-query-operation:joinBindings"),readOnly:new vt.ActionContextKey("@comunica/bus-query-operation:readOnly"),isPathArbitraryLengthDistinctKey:new vt.ActionContextKey("@comunica/bus-query-operation:isPathArbitraryLengthDistinct"),limitIndicator:new vt.ActionContextKey("@comunica/bus-query-operation:limitIndicator"),unionDefaultGraph:new vt.ActionContextKey("@comunica/bus-query-operation:unionDefaultGraph"),querySources:new vt.ActionContextKey("@comunica/bus-query-operation:querySources")};ar.KeysRdfParseJsonLd={documentLoader:new vt.ActionContextKey("@comunica/actor-rdf-parse-jsonld:documentLoader"),strictValues:new vt.ActionContextKey("@comunica/actor-rdf-parse-jsonld:strictValues"),parserOptions:new vt.ActionContextKey("@comunica/actor-rdf-parse-jsonld:parserOptions")};ar.KeysRdfParseHtmlScript={processingHtmlScript:new vt.ActionContextKey("@comunica/actor-rdf-parse-html-script:processingHtmlScript"),extractAllScripts:new vt.ActionContextKey("extractAllScripts")};ar.KeysQuerySourceIdentify={sourceIds:new vt.ActionContextKey("@comunica/bus-query-source-identify:sourceIds"),hypermediaSourcesAggregatedStores:new vt.ActionContextKey("@comunica/bus-query-source-identify:hypermediaSourcesAggregatedStores"),traverse:new vt.ActionContextKey("@comunica/bus-query-source-identify:traverse")};ar.KeysRdfUpdateQuads={destination:new vt.ActionContextKey("@comunica/bus-rdf-update-quads:destination")};ar.KeysMergeBindingsContext={sourcesBinding:new vt.ActionContextKey("@comunica/bus-merge-bindings-context:sourcesBinding")};ar.KeysRdfJoin={lastPhysicalJoin:new vt.ActionContextKey("@comunica/bus-rdf-join:lastPhysicalJoin")};(function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(ar,t)})(Lt);Object.defineProperty(Cb,"__esModule",{value:!0});Cb.QueryEngineBase=void 0;const nV=Lt,yu=ot;class Y1{constructor(e){this.actorInitQuery=e}async queryBindings(e,u){return this.queryOfType(e,u,"bindings")}async queryQuads(e,u){return this.queryOfType(e,u,"quads")}async queryBoolean(e,u){return this.queryOfType(e,u,"boolean")}async queryVoid(e,u){return this.queryOfType(e,u,"void")}async queryOfType(e,u,s){const n=await this.query(e,u);if(n.resultType===s)return await n.execute();throw new Error(`Query result type '${s}' was expected, while '${n.resultType}' was found.`)}async query(e,u){const s=await this.queryOrExplain(e,u);if("explain"in s)throw new Error("Tried to explain a query when in query-only mode");return s}async explain(e,u,s){return u.explain=s,await this.queryOrExplain(e,u)}async queryOrExplain(e,u){const s=yu.ActionContext.ensureActionContext(u);s.get(nV.KeysInitQuery.noCache)&&await this.invalidateHttpCache();const{result:n}=await this.actorInitQuery.mediatorQueryProcess.mediate({query:e,context:s});return"explain"in n?n:Y1.internalToFinalResult(n)}async getResultMediaTypes(e){return e=yu.ActionContext.ensureActionContext(e),(await this.actorInitQuery.mediatorQueryResultSerializeMediaTypeCombiner.mediate({context:e,mediaTypes:!0})).mediaTypes}async getResultMediaTypeFormats(e){return e=yu.ActionContext.ensureActionContext(e),(await this.actorInitQuery.mediatorQueryResultSerializeMediaTypeFormatCombiner.mediate({context:e,mediaTypeFormats:!0})).mediaTypeFormats}async resultToString(e,u,s){if(s=yu.ActionContext.ensureActionContext(s),!u)switch(e.resultType){case"bindings":u="application/json";break;case"quads":u="application/trig";break;default:u="simple";break}const n={...await Y1.finalToInternalResult(e),context:s};return(await this.actorInitQuery.mediatorQueryResultSerialize.mediate({context:s,handle:n,handleMediaType:u})).handle}invalidateHttpCache(e,u){return u=yu.ActionContext.ensureActionContext(u),this.actorInitQuery.mediatorHttpInvalidate.mediate({url:e,context:u})}static internalToFinalResult(e){switch(e.type){case"bindings":return{resultType:"bindings",execute:async()=>e.bindingsStream,metadata:async()=>await e.metadata(),context:e.context};case"quads":return{resultType:"quads",execute:async()=>e.quadStream,metadata:async()=>await e.metadata(),context:e.context};case"boolean":return{resultType:"boolean",execute:async()=>e.execute(),context:e.context};case"void":return{resultType:"void",execute:async()=>e.execute(),context:e.context}}}static async finalToInternalResult(e){switch(e.resultType){case"bindings":return{type:"bindings",bindingsStream:await e.execute(),metadata:async()=>await e.metadata()};case"quads":return{type:"quads",quadStream:await e.execute(),metadata:async()=>await e.metadata()};case"boolean":return{type:"boolean",execute:()=>e.execute()};case"void":return{type:"void",execute:()=>e.execute()}}}}Cb.QueryEngineBase=Y1;(function(t){var e=I&&I.__createBinding||(Object.create?function(n,r,a,o){o===void 0&&(o=a);var l=Object.getOwnPropertyDescriptor(r,a);(!l||("get"in l?!r.__esModule:l.writable||l.configurable))&&(l={enumerable:!0,get:function(){return r[a]}}),Object.defineProperty(n,o,l)}:function(n,r,a,o){o===void 0&&(o=a),n[o]=r[a]}),u=I&&I.__exportStar||function(n,r){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(r,a)&&e(r,n,a)};Object.defineProperty(t,"__esModule",{value:!0}),t.QueryEngineBase=void 0,u(ey,t),u(Nb,t);var s=Cb;Object.defineProperty(t,"QueryEngineBase",{enumerable:!0,get:function(){return s.QueryEngineBase}})})(V3);var Ng={},bu={},Cg={},jg={},DE;function iV(){return DE||(DE=1,Object.defineProperty(jg,"__esModule",{value:!0})),jg}var Lg={},NE;function aV(){return NE||(NE=1,Object.defineProperty(Lg,"__esModule",{value:!0})),Lg}var Mg={},CE;function sV(){return CE||(CE=1,Object.defineProperty(Mg,"__esModule",{value:!0})),Mg}var Fg={},jE;function oV(){return jE||(jE=1,Object.defineProperty(Fg,"__esModule",{value:!0})),Fg}var qg={},LE;function uV(){return LE||(LE=1,Object.defineProperty(qg,"__esModule",{value:!0})),qg}var Bg={},ME;function cV(){return ME||(ME=1,Object.defineProperty(Bg,"__esModule",{value:!0})),Bg}var Ug={},FE;function lV(){return FE||(FE=1,Object.defineProperty(Ug,"__esModule",{value:!0})),Ug}var Hg={},qE;function dV(){return qE||(qE=1,Object.defineProperty(Hg,"__esModule",{value:!0})),Hg}var $g={},BE;function fV(){return BE||(BE=1,Object.defineProperty($g,"__esModule",{value:!0})),$g}var Qg={},UE;function hV(){return UE||(UE=1,Object.defineProperty(Qg,"__esModule",{value:!0})),Qg}var Vg={},HE;function pV(){return HE||(HE=1,Object.defineProperty(Vg,"__esModule",{value:!0})),Vg}var kg={},$E;function yV(){return $E||($E=1,Object.defineProperty(kg,"__esModule",{value:!0})),kg}var zg={},QE;function bV(){return QE||(QE=1,Object.defineProperty(zg,"__esModule",{value:!0})),zg}var gu={},VE;function gV(){if(VE)return gu;VE=1,Object.defineProperty(gu,"__esModule",{value:!0}),gu.Logger=void 0;let t=class RF{static getLevelOrdinal(u){return RF.LEVELS[u]}};return gu.Logger=t,t.LEVELS={trace:0,debug:1,info:2,warn:3,error:4,fatal:5},gu}var kE;function mV(){return kE||(kE=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(iV(),t),u(aV(),t),u(sV(),t),u(oV(),t),u(uV(),t),u(cV(),t),u(lV(),t),u(dV(),t),u(fV(),t),u(hV(),t),u(pV(),t),u(yV(),t),u(bV(),t),u(gV(),t)}(Cg)),Cg}var zE;function _V(){if(zE)return bu;zE=1,Object.defineProperty(bu,"__esModule",{value:!0}),bu.LoggerVoid=void 0;const t=mV();let e=class extends t.Logger{debug(){}error(){}fatal(){}info(){}trace(){}warn(){}};return bu.LoggerVoid=e,bu}var GE;function vV(){return GE||(GE=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(_V(),t)}(Ng)),Ng}var Gg={},mu={},Wg={},_u={},WE;function wV(){if(WE)return _u;WE=1,Object.defineProperty(_u,"__esModule",{value:!0}),_u.BlankNodeScoped=void 0;let t=class{constructor(u,s){this.termType="BlankNode",this.value=u,this.skolemized=s}equals(u){return!!u&&u.termType==="BlankNode"&&u.value===this.value}};return _u.BlankNodeScoped=t,_u}var vu={},JE;function SV(){if(JE)return vu;JE=1,Object.defineProperty(vu,"__esModule",{value:!0}),vu.BlankNodeBindingsScoped=void 0;let t=class{constructor(u){this.termType="BlankNode",this.singleBindingsScope=!0,this.value=u}equals(u){return!!u&&u.termType==="BlankNode"&&u.value===this.value}};return vu.BlankNodeBindingsScoped=t,vu}var XE;function ET(){return XE||(XE=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(wV(),t),u(SV(),t)}(Wg)),Wg}var ys={},Jg={},wu={},KE;function xF(){if(KE)return wu;KE=1,Object.defineProperty(wu,"__esModule",{value:!0}),wu.BlankNode=void 0;class t{constructor(u){this.termType="BlankNode",this.value=u}equals(u){return!!u&&u.termType==="BlankNode"&&u.value===this.value}}return wu.BlankNode=t,wu}var Su={},Tu={},YE;function IF(){if(YE)return Tu;YE=1,Object.defineProperty(Tu,"__esModule",{value:!0}),Tu.DefaultGraph=void 0;class t{constructor(){this.termType="DefaultGraph",this.value=""}equals(u){return!!u&&u.termType==="DefaultGraph"}}return Tu.DefaultGraph=t,t.INSTANCE=new t,Tu}var Au={},Eu={},ZE;function OT(){if(ZE)return Eu;ZE=1,Object.defineProperty(Eu,"__esModule",{value:!0}),Eu.NamedNode=void 0;class t{constructor(u){this.termType="NamedNode",this.value=u}equals(u){return!!u&&u.termType==="NamedNode"&&u.value===this.value}}return Eu.NamedNode=t,Eu}var eO;function PF(){if(eO)return Au;eO=1,Object.defineProperty(Au,"__esModule",{value:!0}),Au.Literal=void 0;const t=OT();class e{constructor(s,n){this.termType="Literal",this.value=s,typeof n=="string"?(this.language=n,this.datatype=e.RDF_LANGUAGE_STRING):n?(this.language="",this.datatype=n):(this.language="",this.datatype=e.XSD_STRING)}equals(s){return!!s&&s.termType==="Literal"&&s.value===this.value&&s.language===this.language&&this.datatype.equals(s.datatype)}}return Au.Literal=e,e.RDF_LANGUAGE_STRING=new t.NamedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#langString"),e.XSD_STRING=new t.NamedNode("http://www.w3.org/2001/XMLSchema#string"),Au}var Ou={},tO;function DF(){if(tO)return Ou;tO=1,Object.defineProperty(Ou,"__esModule",{value:!0}),Ou.Quad=void 0;class t{constructor(u,s,n,r){this.termType="Quad",this.value="",this.subject=u,this.predicate=s,this.object=n,this.graph=r}equals(u){return!!u&&(u.termType==="Quad"||!u.termType)&&this.subject.equals(u.subject)&&this.predicate.equals(u.predicate)&&this.object.equals(u.object)&&this.graph.equals(u.graph)}}return Ou.Quad=t,Ou}var Ru={},rO;function NF(){if(rO)return Ru;rO=1,Object.defineProperty(Ru,"__esModule",{value:!0}),Ru.Variable=void 0;class t{constructor(u){this.termType="Variable",this.value=u}equals(u){return!!u&&u.termType==="Variable"&&u.value===this.value}}return Ru.Variable=t,Ru}var nO;function TV(){if(nO)return Su;nO=1,Object.defineProperty(Su,"__esModule",{value:!0}),Su.DataFactory=void 0;const t=xF(),e=IF(),u=PF(),s=OT(),n=DF(),r=NF();let a=0;class o{constructor(c){this.blankNodeCounter=0,c=c||{},this.blankNodePrefix=c.blankNodePrefix||`df_${a++}_`}namedNode(c){return new s.NamedNode(c)}blankNode(c){return new t.BlankNode(c||`${this.blankNodePrefix}${this.blankNodeCounter++}`)}literal(c,d){return new u.Literal(c,d)}variable(c){return new r.Variable(c)}defaultGraph(){return e.DefaultGraph.INSTANCE}quad(c,d,h,f){return new n.Quad(c,d,h,f||this.defaultGraph())}fromTerm(c){switch(c.termType){case"NamedNode":return this.namedNode(c.value);case"BlankNode":return this.blankNode(c.value);case"Literal":return c.language?this.literal(c.value,c.language):c.datatype.equals(u.Literal.XSD_STRING)?this.literal(c.value):this.literal(c.value,this.fromTerm(c.datatype));case"Variable":return this.variable(c.value);case"DefaultGraph":return this.defaultGraph();case"Quad":return this.quad(this.fromTerm(c.subject),this.fromTerm(c.predicate),this.fromTerm(c.object),this.fromTerm(c.graph))}}fromQuad(c){return this.fromTerm(c)}resetBlankNodeCounter(){this.blankNodeCounter=0}}return Su.DataFactory=o,Su}var iO;function Et(){return iO||(iO=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(xF(),t),u(TV(),t),u(IF(),t),u(PF(),t),u(OT(),t),u(DF(),t),u(NF(),t)}(Jg)),Jg}var Xg={},en={},aO;function AV(){if(aO)return en;aO=1,Object.defineProperty(en,"__esModule",{value:!0}),en.stringQuadToQuad=en.quadToStringQuad=en.stringToTerm=en.getLiteralLanguage=en.getLiteralType=en.getLiteralValue=en.termToString=void 0;const t=Et(),e=new t.DataFactory;function u(c){if(c)switch(c.termType){case"NamedNode":return c.value;case"BlankNode":return"_:"+c.value;case"Literal":const d=c;return'"'+d.value+'"'+(d.datatype&&d.datatype.value!=="http://www.w3.org/2001/XMLSchema#string"&&d.datatype.value!=="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString"?"^^"+d.datatype.value:"")+(d.language?"@"+d.language:"");case"Quad":return`<<${u(c.subject)} ${u(c.predicate)} ${u(c.object)}${c.graph.termType==="DefaultGraph"?"":" "+u(c.graph)}>>`;case"Variable":return"?"+c.value;case"DefaultGraph":return c.value}}en.termToString=u;function s(c){const d=/^"([^]*)"/.exec(c);if(!d)throw new Error(c+" is not a literal");return d[1]}en.getLiteralValue=s;function n(c){const d=/^"[^]*"(?:\^\^([^"]+)|(@)[^@"]+)?$/.exec(c);if(!d)throw new Error(c+" is not a literal");return d[1]||(d[2]?"http://www.w3.org/1999/02/22-rdf-syntax-ns#langString":"http://www.w3.org/2001/XMLSchema#string")}en.getLiteralType=n;function r(c){const d=/^"[^]*"(?:@([^@"]+)|\^\^[^"]+)?$/.exec(c);if(!d)throw new Error(c+" is not a literal");return d[1]?d[1].toLowerCase():""}en.getLiteralLanguage=r;function a(c,d){if(d=d||e,!c||!c.length)return d.defaultGraph();switch(c[0]){case"_":return d.blankNode(c.substr(2));case"?":if(!d.variable)throw new Error("Missing 'variable()' method on the given DataFactory");return d.variable(c.substr(1));case'"':const h=r(c),f=d.namedNode(n(c));return d.literal(s(c),h||f);case"<":default:if(c[0]==="<"&&c.length>4&&c[1]==="<"&&c[c.length-1]===">"&&c[c.length-2]===">"){const p=c.slice(2,-2).trim();let y=[],b=0,m=0,g=!1;for(let v=0;v"){if(b===0)throw new Error("Found closing tag without opening tag in "+c);b--}if(_==='"'){let w=!1,S=v;for(;S-- >0&&p[S]==="\\";)w=!w;w||(g=!g)}if(_===" "&&!g&&b===0){for(y.push(p.slice(m,v));p[v+1]===" ";)v+=1;m=v+1}}if(b!==0)throw new Error("Found opening tag without closing tag in "+c);if(y.push(p.slice(m,p.length)),y.length!==3&&y.length!==4)throw new Error("Nested quad syntax error "+c);return y=y.map(v=>v.startsWith("<")&&!v.includes(" ")?v.slice(1,-1):v),d.quad(a(y[0]),a(y[1]),a(y[2]),y[3]?a(y[3]):void 0)}return d.namedNode(c)}}en.stringToTerm=a;function o(c){return{subject:u(c.subject),predicate:u(c.predicate),object:u(c.object),graph:u(c.graph)}}en.quadToStringQuad=o;function l(c,d){return d=d||e,d.quad(a(c.subject,d),a(c.predicate,d),a(c.object,d),a(c.graph,d))}return en.stringQuadToQuad=l,en}var sO;function er(){return sO||(sO=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.termToString=t.stringToTerm=t.stringQuadToQuad=t.quadToStringQuad=t.getLiteralValue=t.getLiteralType=t.getLiteralLanguage=void 0;const e=AV();Object.defineProperty(t,"getLiteralLanguage",{enumerable:!0,get:function(){return e.getLiteralLanguage}}),Object.defineProperty(t,"getLiteralType",{enumerable:!0,get:function(){return e.getLiteralType}}),Object.defineProperty(t,"getLiteralValue",{enumerable:!0,get:function(){return e.getLiteralValue}}),Object.defineProperty(t,"quadToStringQuad",{enumerable:!0,get:function(){return e.quadToStringQuad}}),Object.defineProperty(t,"stringQuadToQuad",{enumerable:!0,get:function(){return e.stringQuadToQuad}}),Object.defineProperty(t,"stringToTerm",{enumerable:!0,get:function(){return e.stringToTerm}}),Object.defineProperty(t,"termToString",{enumerable:!0,get:function(){return e.termToString}})}(Xg)),Xg}var Kg={},bt={},oO;function CF(){if(oO)return bt;oO=1,Object.defineProperty(bt,"__esModule",{value:!0}),bt.matchPatternMappings=bt.matchPatternComplete=bt.matchPattern=bt.matchTerm=bt.getValueNestedPath=bt.someTermsNested=bt.someTerms=bt.everyTermsNested=bt.everyTerms=bt.reduceTermsNested=bt.reduceTerms=bt.mapTermsNested=bt.mapTerms=bt.filterQuadTermNamesNested=bt.filterQuadTermNames=bt.filterTermsNested=bt.filterTerms=bt.forEachTermsNested=bt.forEachTerms=bt.collectNamedTerms=bt.getNamedTerms=bt.getTermsNested=bt.getTerms=bt.TRIPLE_TERM_NAMES=bt.QUAD_TERM_NAMES=void 0;const t=Et(),e=new t.DataFactory;bt.QUAD_TERM_NAMES=["subject","predicate","object","graph"],bt.TRIPLE_TERM_NAMES=["subject","predicate","object"];function u(E,O){return O&&E.graph.termType==="DefaultGraph"?[E.subject,E.predicate,E.object]:[E.subject,E.predicate,E.object,E.graph]}bt.getTerms=u;function s(E,O){const P=[];for(const j of u(E,O))j.termType==="Quad"?s(j,O).forEach(U=>P.push(U)):P.push(j);return P}bt.getTermsNested=s;function n(E){return[{key:"subject",value:E.subject},{key:"predicate",value:E.predicate},{key:"object",value:E.object},{key:"graph",value:E.graph}]}bt.getNamedTerms=n;function r(E,O,P){const j={};return E.forEach(U=>j[U.key]=U.value),O&&(j.subject=j.subject||O("subject"),j.predicate=j.predicate||O("predicate"),j.object=j.object||O("object"),j.graph=j.graph||O("graph")),(P||e).quad(j.subject,j.predicate,j.object,j.graph)}bt.collectNamedTerms=r;function a(E,O){O(E.subject,"subject"),O(E.predicate,"predicate"),O(E.object,"object"),O(E.graph,"graph")}bt.forEachTerms=a;function o(E,O,P=[]){E.subject.termType==="Quad"?o(E.subject,O,[...P,"subject"]):O(E.subject,[...P,"subject"]),E.predicate.termType==="Quad"?o(E.predicate,O,[...P,"predicate"]):O(E.predicate,[...P,"predicate"]),E.object.termType==="Quad"?o(E.object,O,[...P,"object"]):O(E.object,[...P,"object"]),E.graph.termType==="Quad"?o(E.graph,O,[...P,"graph"]):O(E.graph,[...P,"graph"])}bt.forEachTermsNested=o;function l(E,O){const P=[];return O(E.subject,"subject")&&P.push(E.subject),O(E.predicate,"predicate")&&P.push(E.predicate),O(E.object,"object")&&P.push(E.object),O(E.graph,"graph")&&P.push(E.graph),P}bt.filterTerms=l;function c(E,O,P=[]){let j=[];return E.subject.termType==="Quad"?j=[...j,...c(E.subject,O,[...P,"subject"])]:O(E.subject,[...P,"subject"])&&j.push(E.subject),E.predicate.termType==="Quad"?j=[...j,...c(E.predicate,O,[...P,"predicate"])]:O(E.predicate,[...P,"predicate"])&&j.push(E.predicate),E.object.termType==="Quad"?j=[...j,...c(E.object,O,[...P,"object"])]:O(E.object,[...P,"object"])&&j.push(E.object),E.graph.termType==="Quad"?j=[...j,...c(E.graph,O,[...P,"graph"])]:O(E.graph,[...P,"graph"])&&j.push(E.graph),j}bt.filterTermsNested=c;function d(E,O){const P=[];return O(E.subject,"subject")&&P.push("subject"),O(E.predicate,"predicate")&&P.push("predicate"),O(E.object,"object")&&P.push("object"),O(E.graph,"graph")&&P.push("graph"),P}bt.filterQuadTermNames=d;function h(E,O,P=[]){let j=[];const U=[...P,"subject"];E.subject.termType==="Quad"?j=[...j,...h(E.subject,O,U)]:O(E.subject,U)&&j.push(U);const M=[...P,"predicate"];E.predicate.termType==="Quad"?j=[...j,...h(E.predicate,O,M)]:O(E.predicate,M)&&j.push(M);const q=[...P,"object"];E.object.termType==="Quad"?j=[...j,...h(E.object,O,q)]:O(E.object,q)&&j.push(q);const Q=[...P,"graph"];return E.graph.termType==="Quad"?j=[...j,...h(E.graph,O,Q)]:O(E.graph,Q)&&j.push(Q),j}bt.filterQuadTermNamesNested=h;function f(E,O,P){return(P||e).quad(O(E.subject,"subject"),O(E.predicate,"predicate"),O(E.object,"object"),O(E.graph,"graph"))}bt.mapTerms=f;function p(E,O,P,j=[]){return(P||e).quad(E.subject.termType==="Quad"?p(E.subject,O,P,[...j,"subject"]):O(E.subject,[...j,"subject"]),E.predicate.termType==="Quad"?p(E.predicate,O,P,[...j,"predicate"]):O(E.predicate,[...j,"predicate"]),E.object.termType==="Quad"?p(E.object,O,P,[...j,"object"]):O(E.object,[...j,"object"]),E.graph.termType==="Quad"?p(E.graph,O,P,[...j,"graph"]):O(E.graph,[...j,"graph"]))}bt.mapTermsNested=p;function y(E,O,P){let j=P;return j=O(j,E.subject,"subject"),j=O(j,E.predicate,"predicate"),j=O(j,E.object,"object"),O(j,E.graph,"graph")}bt.reduceTerms=y;function b(E,O,P,j=[]){let U=P;return E.subject.termType==="Quad"?U=b(E.subject,O,U,[...j,"subject"]):U=O(U,E.subject,[...j,"subject"]),E.predicate.termType==="Quad"?U=b(E.predicate,O,U,[...j,"predicate"]):U=O(U,E.predicate,[...j,"predicate"]),E.object.termType==="Quad"?U=b(E.object,O,U,[...j,"object"]):U=O(U,E.object,[...j,"object"]),E.graph.termType==="Quad"?U=b(E.graph,O,U,[...j,"graph"]):U=O(U,E.graph,[...j,"graph"]),U}bt.reduceTermsNested=b;function m(E,O){return O(E.subject,"subject")&&O(E.predicate,"predicate")&&O(E.object,"object")&&O(E.graph,"graph")}bt.everyTerms=m;function g(E,O,P=[]){return(E.subject.termType==="Quad"?g(E.subject,O,[...P,"subject"]):O(E.subject,[...P,"subject"]))&&(E.predicate.termType==="Quad"?g(E.predicate,O,[...P,"predicate"]):O(E.predicate,[...P,"predicate"]))&&(E.object.termType==="Quad"?g(E.object,O,[...P,"object"]):O(E.object,[...P,"object"]))&&(E.graph.termType==="Quad"?g(E.graph,O,[...P,"graph"]):O(E.graph,[...P,"graph"]))}bt.everyTermsNested=g;function v(E,O){return O(E.subject,"subject")||O(E.predicate,"predicate")||O(E.object,"object")||O(E.graph,"graph")}bt.someTerms=v;function _(E,O,P=[]){return(E.subject.termType==="Quad"?_(E.subject,O,[...P,"subject"]):O(E.subject,[...P,"subject"]))||(E.predicate.termType==="Quad"?_(E.predicate,O,[...P,"predicate"]):O(E.predicate,[...P,"predicate"]))||(E.object.termType==="Quad"?_(E.object,O,[...P,"object"]):O(E.object,[...P,"object"]))||(E.graph.termType==="Quad"?_(E.graph,O,[...P,"graph"]):O(E.graph,[...P,"graph"]))}bt.someTermsNested=_;function w(E,O){if(O.length===0)return E;if(E.termType==="Quad")return w(E[O[0]],O.slice(1));throw new Error(`Tried to get ${O[0]} from term of type ${E.termType}`)}bt.getValueNestedPath=w;function S(E,O){return!O||O.termType==="Variable"||O.termType==="Quad"&&E.termType==="Quad"&&D(E,O)||O.equals(E)}bt.matchTerm=S;function A(E,O,P,j,U){return S(E.subject,O)&&S(E.predicate,P)&&S(E.object,j)&&S(E.graph,U)}bt.matchPattern=A;function D(E,O){return A(E,O.subject,O.predicate,O.object,O.graph)}bt.matchPatternComplete=D;function L(E,O,P={}){const j={};function U(M,q){return m(M,(Q,Z)=>{var K,fe;const X=q[Z];switch(Q.termType){case"Variable":return P.skipVarMapping&&X.termType==="Variable"||((fe=(K=j[Q.value])===null||K===void 0?void 0:K.equals(X))!==null&&fe!==void 0?fe:(j[Q.value]=X,!0));case"Quad":return X.termType==="Quad"&&U(Q,X);default:return Q.equals(X)}})}return U(O,E)&&(P.returnMappings?j:!0)}return bt.matchPatternMappings=L,bt}var Cr={},uO;function EV(){if(uO)return Cr;uO=1,Object.defineProperty(Cr,"__esModule",{value:!0}),Cr.getQuads=Cr.getDefaultGraphs=Cr.getVariables=Cr.getLiterals=Cr.getBlankNodes=Cr.getNamedNodes=Cr.getTermsOfType=Cr.uniqTerms=Cr.TERM_TYPES=void 0;const t=er();Cr.TERM_TYPES=["NamedNode","BlankNode","Literal","Variable","DefaultGraph","Quad"];function e(c){const d={};return c.filter(h=>{const f=(0,t.termToString)(h);return!(f in d)&&(d[f]=!0)})}Cr.uniqTerms=e;function u(c,d){return c.filter(h=>h.termType===d)}Cr.getTermsOfType=u;function s(c){return u(c,"NamedNode")}Cr.getNamedNodes=s;function n(c){return u(c,"BlankNode")}Cr.getBlankNodes=n;function r(c){return u(c,"Literal")}Cr.getLiterals=r;function a(c){return u(c,"Variable")}Cr.getVariables=a;function o(c){return u(c,"DefaultGraph")}Cr.getDefaultGraphs=o;function l(c){return u(c,"Quad")}return Cr.getQuads=l,Cr}var cO;function un(){return cO||(cO=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(CF(),t),u(EV(),t)}(Kg)),Kg}var Yg={},Zy={},Zg,lO;function OV(){return lO||(lO=1,Zg=function t(e,u){if(e===u)return!0;if(e&&u&&typeof e=="object"&&typeof u=="object"){if(e.constructor!==u.constructor)return!1;var s,n,r;if(Array.isArray(e)){if(s=e.length,s!=u.length)return!1;for(n=s;n--!==0;)if(!t(e[n],u[n]))return!1;return!0}if(e instanceof Map&&u instanceof Map){if(e.size!==u.size)return!1;for(n of e.entries())if(!u.has(n[0]))return!1;for(n of e.entries())if(!t(n[1],u.get(n[0])))return!1;return!0}if(e instanceof Set&&u instanceof Set){if(e.size!==u.size)return!1;for(n of e.entries())if(!u.has(n[0]))return!1;return!0}if(ArrayBuffer.isView(e)&&ArrayBuffer.isView(u)){if(s=e.length,s!=u.length)return!1;for(n=s;n--!==0;)if(e[n]!==u[n])return!1;return!0}if(e.constructor===RegExp)return e.source===u.source&&e.flags===u.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===u.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===u.toString();if(r=Object.keys(e),s=r.length,s!==Object.keys(u).length)return!1;for(n=s;n--!==0;)if(!Object.prototype.hasOwnProperty.call(u,r[n]))return!1;for(n=s;n--!==0;){var a=r[n];if(!t(e[a],u[a]))return!1}return!0}return e!==e&&u!==u}),Zg}var em={},dO;function gy(){return dO||(dO=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.expressionTypes=t.types=void 0,function(e){e.ALT="alt",e.ASK="ask",e.BGP="bgp",e.CONSTRUCT="construct",e.DESCRIBE="describe",e.DISTINCT="distinct",e.EXPRESSION="expression",e.EXTEND="extend",e.FILTER="filter",e.FROM="from",e.GRAPH="graph",e.GROUP="group",e.INV="inv",e.JOIN="join",e.LEFT_JOIN="leftjoin",e.LINK="link",e.MINUS="minus",e.NOP="nop",e.NPS="nps",e.ONE_OR_MORE_PATH="OneOrMorePath",e.ORDER_BY="orderby",e.PATH="path",e.PATTERN="pattern",e.PROJECT="project",e.REDUCED="reduced",e.SEQ="seq",e.SERVICE="service",e.SLICE="slice",e.UNION="union",e.VALUES="values",e.ZERO_OR_MORE_PATH="ZeroOrMorePath",e.ZERO_OR_ONE_PATH="ZeroOrOnePath",e.COMPOSITE_UPDATE="compositeupdate",e.DELETE_INSERT="deleteinsert",e.LOAD="load",e.CLEAR="clear",e.CREATE="create",e.DROP="drop",e.ADD="add",e.MOVE="move",e.COPY="copy"}(t.types||(t.types={})),function(e){e.AGGREGATE="aggregate",e.EXISTENCE="existence",e.NAMED="named",e.OPERATOR="operator",e.TERM="term",e.WILDCARD="wildcard"}(t.expressionTypes||(t.expressionTypes={}))}(em)),em}var e1={},tm={},fO;function jF(){if(fO)return tm;fO=1;let t=class{constructor(){return e||this}equals(s){return s&&this.termType===s.termType}};Object.defineProperty(t.prototype,"value",{enumerable:!0,value:"*"}),Object.defineProperty(t.prototype,"termType",{enumerable:!0,value:"Wildcard"});var e=new t;return tm.Wildcard=t,tm}var rm,hO;function RV(){if(hO)return rm;hO=1;var t=function(){var e=function(He,Be,Ge,Ze){for(Ge=Ge||{},Ze=He.length;Ze--;Ge[He[Ze]]=Be);return Ge},u=[6,12,13,15,16,24,32,36,41,45,100,110,113,115,116,123,126,131,197,224,229,308,329,330,331,332,333],s=[2,247],n=[100,110,113,115,116,123,126,131,329,330,331,332,333],r=[2,409],a=[1,18],o=[1,27],l=[13,16,45,197,224,229,308],c=[28,29,53],d=[28,53],h=[1,42],f=[1,45],p=[1,41],y=[1,44],b=[123,126],m=[1,67],g=[39,45,87],v=[13,16,45,197,224,308],_=[1,87],w=[2,281],S=[1,86],A=[13,16,45,82,87,89,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312],D=[6,28,29,53,63,70,73,81,83,85],L=[6,13,16,28,29,53,63,70,73,81,83,85,87,308],E=[6,13,16,28,29,45,53,63,70,73,81,82,83,85,87,89,197,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,314],O=[6,13,16,28,29,31,39,45,47,48,53,63,70,73,81,82,83,85,87,89,109,112,121,123,126,128,159,160,161,163,164,174,193,197,224,229,231,232,242,246,250,263,265,272,290,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,314,317,318,335,337,338,340,341,342,343,344,345,346],P=[13,16,308],j=[112,132,327,334],U=[13,16,112,132,308],M=[1,111],q=[1,117],Q=[112,132,327,328,334],Z=[13,16,112,132,308,328],K=[28,29,45,53,87],fe=[1,138],X=[1,151],he=[1,128],xe=[1,127],ie=[1,129],ae=[1,140],Oe=[1,141],Ne=[1,142],ge=[1,143],de=[1,144],oe=[1,145],$=[1,147],N=[1,148],R=[2,457],T=[1,158],x=[1,159],B=[1,160],k=[1,152],V=[1,153],J=[1,156],z=[1,171],Y=[1,172],te=[1,173],ce=[1,174],Ae=[1,175],Ie=[1,176],Ee=[1,167],qe=[1,168],G=[1,169],F=[1,170],H=[1,157],re=[1,166],be=[1,161],Re=[1,162],Ce=[1,163],Qe=[1,164],ke=[1,165],me=[6,13,16,29,31,45,82,85,87,89,112,159,160,161,163,164,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,335],Se=[1,195],W=[6,31,73,81,83,85],we=[2,285],Te=[1,199],Le=[1,201],$e=[6,31,70,73,81,83,85],We=[2,283],tt=[1,207],lt=[1,218],ut=[1,223],le=[1,219],C=[1,225],ee=[1,226],pe=[1,224],De=[6,63,70,73,81,83,85],Ue=[1,236],Fe=[2,334],Ye=[1,243],Ve=[1,241],Je=[6,193],nt=[2,349],yt=[2,339],ft=[28,128],et=[47,48,193,272],Ir=[47,48,193,242,272],Ke=[47,48,193,242,246,272],ye=[47,48,193,242,246,250,263,265,272,290,297,298,299,300,301,302,341,342,343,344,345,346],Pe=[39,47,48,193,242,246,250,263,265,272,290,297,298,299,300,301,302,338,341,342,343,344,345,346],Me=[1,271],it=[1,270],at=[6,13,16,29,31,39,45,47,48,70,73,76,78,81,82,83,85,87,89,112,159,160,161,163,164,193,231,242,246,250,263,265,268,269,270,271,272,273,274,276,277,279,280,283,285,290,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,335,338,341,342,343,344,345,346,347,348,349,350,351],Tt=[1,281],Vt=[1,280],tr=[13,16,29,31,39,45,47,48,82,85,87,89,112,159,160,161,163,164,174,193,197,224,229,231,232,242,246,250,263,265,272,290,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,314,317,318,335,338,341,342,343,344,345,346],di=[45,89],yn=[13,16,29,31,39,45,47,48,82,85,87,89,112,159,160,161,163,164,174,193,197,224,229,231,232,242,246,250,263,265,272,290,292,293,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,314,317,318,335,338,341,342,343,344,345,346],or=[13,16,31,82,174,294,295,296,297,298,299,300,301,302,303,304,305,306,308,312],Mn=[31,89],Hr=[48,87],Hn=[6,13,16,45,48,82,87,89,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,337,338],Pr=[6,13,16,39,45,48,82,87,89,231,263,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,337,338,340],fi=[1,313],Mr=[6,85],Ni=[6,31,81,83,85],Zi=[2,361],bn=[2,353],Xr=[1,343],os=[31,112,335],Zn=[13,16,29,31,45,48,82,85,87,89,112,159,160,161,163,164,193,197,224,229,231,232,272,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,317,318,335],ue=[13,16,29,31,45,48,82,85,87,89,112,159,160,161,163,164,193,197,224,229,231,232,272,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,314,317,318,335],ve=[6,109,193],je=[31,112],Xe=[13,16,45,82,87,224,263,265,268,269,270,271,273,274,276,277,279,280,283,285,294,295,296,297,298,299,300,301,302,303,304,305,306,308,312,346,347,348,349,350,351],st=[1,390],ht=[1,391],St=[13,16,87,197,308,314],Ht=[13,16,39,45,82,87,224,263,265,268,269,270,271,273,274,276,277,279,280,283,285,294,295,296,297,298,299,300,301,302,303,304,305,306,308,312,346,347,348,349,350,351],Xt=[1,417],lr=[1,418],vr=[13,16,48,197,229,308],zt=[6,31,85],Fn=[6,13,16,31,45,73,81,83,85,268,269,270,271,273,274,276,277,279,280,283,285,308,346,347,348,349,350,351],ei=[6,13,16,29,31,45,73,76,78,81,82,83,85,87,89,112,159,160,161,163,164,231,268,269,270,271,273,274,276,277,279,280,283,285,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,335,346,347,348,349,350,351],Fr=[29,31,85,112,159,160,161,163,164],gn=[1,443],$n=[1,444],Qn=[1,449],ti=[31,112,193,232,318,335],ea=[13,16,45,48,82,87,89,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312],no=[13,16,31,45,48,82,87,89,112,193,231,232,272,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,317,318,335],Kt=[13,16,29,31,45,48,82,85,87,89,112,159,160,161,163,164,193,231,232,272,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,317,318,335],zr=[13,16,31,48,82,174,294,295,296,297,298,299,300,301,302,303,304,305,306,308,312],ri=[31,45],Aa=[1,507],Iy=[1,508],sA=[6,13,16,29,31,39,45,47,48,63,70,73,76,78,81,82,83,85,87,89,112,159,160,161,163,164,193,231,242,246,250,263,265,268,269,270,271,272,273,274,276,277,279,280,283,285,290,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,335,336,338,341,342,343,344,345,346,347,348,349,350,351],Py=[29,31,85,112,159,160,161,163,164,335],us=[6,13,16,31,45,70,73,81,83,85,87,268,269,270,271,273,274,276,277,279,280,283,285,308,346,347,348,349,350,351],oA=[13,16,31,45,48,82,87,89,112,193,197,231,232,272,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,317,318,335],uA=[2,352],tg=[13,16,197,308,314],cA=[1,565],io=[6,13,16,31,45,76,78,81,83,85,87,268,269,270,271,273,274,276,277,279,280,283,285,308,346,347,348,349,350,351],lA=[13,16,29,31,45,82,85,87,89,112,159,160,161,163,164,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312],ta=[13,16,29,31,45,82,85,87,89,112,159,160,161,163,164,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,335],dA=[13,16,87,308],ra=[2,364],ao=[29,31,85,112,159,160,161,163,164,193,232,318,335],Dy=[31,112,193,232,272,318,335],na=[2,359],fA=[13,16,48,82,174,294,295,296,297,298,299,300,301,302,303,304,305,306,308,312],Ny=[29,31,85,112,159,160,161,163,164,193,232,272,318,335],hA=[13,16,31,45,82,87,89,112,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312],pA=[2,347],rg={trace:function(){},yy:{},symbols_:{error:2,QueryOrUpdate:3,Prologue:4,QueryOrUpdate_group0:5,EOF:6,Query:7,Qry:8,Query_option0:9,Prologue_repetition0:10,BaseDecl:11,BASE:12,IRIREF:13,PrefixDecl:14,PREFIX:15,PNAME_NS:16,SelectClauseWildcard:17,Qry_repetition0:18,WhereClause:19,SolutionModifierNoGroup:20,SelectClauseVars:21,Qry_repetition1:22,SolutionModifier:23,CONSTRUCT:24,ConstructTemplate:25,Qry_repetition2:26,Qry_repetition3:27,WHERE:28,"{":29,Qry_option0:30,"}":31,DESCRIBE:32,Qry_group0:33,Qry_repetition4:34,Qry_option1:35,ASK:36,Qry_repetition5:37,SelectClauseBase:38,"*":39,SelectClauseVars_repetition_plus0:40,SELECT:41,SelectClauseBase_option0:42,SelectClauseItem:43,Var:44,"(":45,Expression:46,AS:47,")":48,SubSelect:49,SubSelect_option0:50,SubSelect_option1:51,DatasetClause:52,FROM:53,DatasetClause_option0:54,iri:55,WhereClause_option0:56,GroupGraphPattern:57,SolutionModifier_option0:58,SolutionModifierNoGroup_option0:59,SolutionModifierNoGroup_option1:60,SolutionModifierNoGroup_option2:61,GroupClause:62,GROUP:63,BY:64,GroupClause_repetition_plus0:65,GroupCondition:66,BuiltInCall:67,FunctionCall:68,HavingClause:69,HAVING:70,HavingClause_repetition_plus0:71,OrderClause:72,ORDER:73,OrderClause_repetition_plus0:74,OrderCondition:75,ASC:76,BrackettedExpression:77,DESC:78,Constraint:79,LimitOffsetClauses:80,LIMIT:81,INTEGER:82,OFFSET:83,ValuesClause:84,VALUES:85,InlineData:86,VAR:87,InlineData_repetition0:88,NIL:89,InlineData_repetition1:90,InlineData_repetition_plus2:91,InlineData_repetition3:92,DataBlock:93,DataBlockValueList:94,DataBlockValueList_repetition_plus0:95,Update:96,Update_repetition0:97,Update1:98,Update_option0:99,LOAD:100,Update1_option0:101,Update1_option1:102,Update1_group0:103,Update1_option2:104,GraphRefAll:105,Update1_group1:106,Update1_option3:107,GraphOrDefault:108,TO:109,CREATE:110,Update1_option4:111,GRAPH:112,INSERTDATA:113,QuadPattern:114,DELETEDATA:115,DELETEWHERE:116,Update1_option5:117,InsertDeleteClause:118,Update1_repetition0:119,IntoGraphClause:120,INTO:121,GraphRef:122,DELETE:123,InsertDeleteClause_option0:124,InsertClause:125,INSERT:126,UsingClause:127,USING:128,UsingClause_option0:129,WithClause:130,WITH:131,DEFAULT:132,GraphOrDefault_option0:133,GraphRefAll_group0:134,Quads:135,Quads_option0:136,Quads_repetition0:137,QuadsNotTriples:138,VarOrIri:139,QuadsNotTriples_option0:140,QuadsNotTriples_option1:141,QuadsNotTriples_option2:142,TriplesTemplate:143,TriplesTemplate_repetition0:144,TriplesSameSubject:145,TriplesTemplate_option0:146,GroupGraphPatternSub:147,GroupGraphPatternSub_option0:148,GroupGraphPatternSub_repetition0:149,GroupGraphPatternSubTail:150,GraphPatternNotTriples:151,GroupGraphPatternSubTail_option0:152,GroupGraphPatternSubTail_option1:153,TriplesBlock:154,TriplesBlock_repetition0:155,TriplesSameSubjectPath:156,TriplesBlock_option0:157,GroupOrUnionGraphPattern:158,OPTIONAL:159,MINUS:160,SERVICE:161,GraphPatternNotTriples_option0:162,FILTER:163,BIND:164,InlineDataOneVar:165,InlineDataFull:166,InlineDataOneVar_repetition0:167,InlineDataFull_repetition0:168,InlineDataFull_repetition_plus1:169,InlineDataFull_repetition2:170,DataBlockValue:171,Literal:172,QuotedTriple:173,UNDEF:174,GroupOrUnionGraphPattern_repetition0:175,ArgList:176,ArgList_option0:177,ArgList_repetition0:178,ExpressionList:179,ExpressionList_repetition0:180,ConstructTemplate_option0:181,ConstructTriples:182,ConstructTriples_repetition0:183,ConstructTriples_option0:184,VarOrTermOrQuotedTP:185,PropertyListNotEmpty:186,TriplesNode:187,PropertyList:188,PropertyList_option0:189,VerbObjectList:190,PropertyListNotEmpty_repetition0:191,SemiOptionalVerbObjectList:192,";":193,SemiOptionalVerbObjectList_option0:194,Verb:195,ObjectList:196,a:197,ObjectList_repetition0:198,Object:199,GraphNode:200,Object_option0:201,PropertyListPathNotEmpty:202,TriplesNodePath:203,TriplesSameSubjectPath_option0:204,O:205,PropertyListPathNotEmpty_repetition0:206,PropertyListPathNotEmptyTail:207,O_group0:208,ObjectListPath:209,ObjectListPath_repetition0:210,ObjectPath:211,GraphNodePath:212,ObjectPath_option0:213,Path:214,Path_repetition0:215,PathSequence:216,PathSequence_repetition0:217,PathEltOrInverse:218,PathElt:219,PathPrimary:220,PathElt_option0:221,PathEltOrInverse_option0:222,IriOrA:223,"!":224,PathNegatedPropertySet:225,PathOneInPropertySet:226,PathNegatedPropertySet_repetition0:227,PathNegatedPropertySet_option0:228,"^":229,TriplesNode_repetition_plus0:230,"[":231,"]":232,TriplesNodePath_repetition_plus0:233,VarOrTermOrQuotedTPExpr:234,VarOrTerm:235,GraphTerm:236,BlankNode:237,ConditionalOrExpression:238,ConditionalAndExpression:239,ConditionalOrExpression_repetition0:240,ConditionalOrExpressionTail:241,"||":242,RelationalExpression:243,ConditionalAndExpression_repetition0:244,ConditionalAndExpressionTail:245,"&&":246,NumericExpression:247,RelationalExpression_group0:248,RelationalExpression_option0:249,IN:250,MultiplicativeExpression:251,NumericExpression_repetition0:252,AdditiveExpressionTail:253,AdditiveExpressionTail_group0:254,NumericLiteralPositive:255,AdditiveExpressionTail_repetition0:256,NumericLiteralNegative:257,AdditiveExpressionTail_repetition1:258,UnaryExpression:259,MultiplicativeExpression_repetition0:260,MultiplicativeExpressionTail:261,MultiplicativeExpressionTail_group0:262,"+":263,PrimaryExpression:264,"-":265,ExprQuotedTP:266,Aggregate:267,FUNC_ARITY0:268,FUNC_ARITY1:269,FUNC_ARITY1_SPARQL_STAR:270,FUNC_ARITY2:271,",":272,FUNC_ARITY3:273,FUNC_ARITY3_SPARQL_STAR:274,BuiltInCall_group0:275,BOUND:276,BNODE:277,BuiltInCall_option0:278,EXISTS:279,COUNT:280,Aggregate_option0:281,Aggregate_group0:282,FUNC_AGGREGATE:283,Aggregate_option1:284,GROUP_CONCAT:285,Aggregate_option2:286,Aggregate_option3:287,GroupConcatSeparator:288,SEPARATOR:289,"=":290,String:291,LANGTAG:292,"^^":293,DECIMAL:294,DOUBLE:295,BOOLEAN:296,INTEGER_POSITIVE:297,DECIMAL_POSITIVE:298,DOUBLE_POSITIVE:299,INTEGER_NEGATIVE:300,DECIMAL_NEGATIVE:301,DOUBLE_NEGATIVE:302,STRING_LITERAL1:303,STRING_LITERAL2:304,STRING_LITERAL_LONG1:305,STRING_LITERAL_LONG2:306,PrefixedName:307,PNAME_LN:308,BLANK_NODE_LABEL:309,ANON:310,QuotedTP:311,"<<":312,qtSubjectOrObject:313,">>":314,DataValueTerm:315,AnnotationPattern:316,"{|":317,"|}":318,AnnotationPatternPath:319,ExprVarOrTerm:320,QueryOrUpdate_group0_option0:321,Prologue_repetition0_group0:322,Qry_group0_repetition_plus0:323,SelectClauseBase_option0_group0:324,DISTINCT:325,REDUCED:326,NAMED:327,SILENT:328,CLEAR:329,DROP:330,ADD:331,MOVE:332,COPY:333,ALL:334,".":335,UNION:336,"|":337,"/":338,PathElt_option0_group0:339,"?":340,"!=":341,"<":342,">":343,"<=":344,">=":345,NOT:346,CONCAT:347,COALESCE:348,SUBSTR:349,REGEX:350,REPLACE:351,$accept:0,$end:1},terminals_:{2:"error",6:"EOF",12:"BASE",13:"IRIREF",15:"PREFIX",16:"PNAME_NS",24:"CONSTRUCT",28:"WHERE",29:"{",31:"}",32:"DESCRIBE",36:"ASK",39:"*",41:"SELECT",45:"(",47:"AS",48:")",53:"FROM",63:"GROUP",64:"BY",70:"HAVING",73:"ORDER",76:"ASC",78:"DESC",81:"LIMIT",82:"INTEGER",83:"OFFSET",85:"VALUES",87:"VAR",89:"NIL",100:"LOAD",109:"TO",110:"CREATE",112:"GRAPH",113:"INSERTDATA",115:"DELETEDATA",116:"DELETEWHERE",121:"INTO",123:"DELETE",126:"INSERT",128:"USING",131:"WITH",132:"DEFAULT",159:"OPTIONAL",160:"MINUS",161:"SERVICE",163:"FILTER",164:"BIND",174:"UNDEF",193:";",197:"a",224:"!",229:"^",231:"[",232:"]",242:"||",246:"&&",250:"IN",263:"+",265:"-",268:"FUNC_ARITY0",269:"FUNC_ARITY1",270:"FUNC_ARITY1_SPARQL_STAR",271:"FUNC_ARITY2",272:",",273:"FUNC_ARITY3",274:"FUNC_ARITY3_SPARQL_STAR",276:"BOUND",277:"BNODE",279:"EXISTS",280:"COUNT",283:"FUNC_AGGREGATE",285:"GROUP_CONCAT",289:"SEPARATOR",290:"=",292:"LANGTAG",293:"^^",294:"DECIMAL",295:"DOUBLE",296:"BOOLEAN",297:"INTEGER_POSITIVE",298:"DECIMAL_POSITIVE",299:"DOUBLE_POSITIVE",300:"INTEGER_NEGATIVE",301:"DECIMAL_NEGATIVE",302:"DOUBLE_NEGATIVE",303:"STRING_LITERAL1",304:"STRING_LITERAL2",305:"STRING_LITERAL_LONG1",306:"STRING_LITERAL_LONG2",308:"PNAME_LN",309:"BLANK_NODE_LABEL",310:"ANON",312:"<<",314:">>",317:"{|",318:"|}",325:"DISTINCT",326:"REDUCED",327:"NAMED",328:"SILENT",329:"CLEAR",330:"DROP",331:"ADD",332:"MOVE",333:"COPY",334:"ALL",335:".",336:"UNION",337:"|",338:"/",340:"?",341:"!=",342:"<",343:">",344:"<=",345:">=",346:"NOT",347:"CONCAT",348:"COALESCE",349:"SUBSTR",350:"REGEX",351:"REPLACE"},productions_:[0,[3,3],[7,2],[4,1],[11,2],[14,3],[8,4],[8,4],[8,5],[8,7],[8,5],[8,4],[17,2],[21,2],[38,2],[43,1],[43,5],[49,4],[49,4],[52,3],[19,2],[23,2],[20,3],[62,3],[66,1],[66,1],[66,3],[66,5],[66,1],[69,2],[72,3],[75,2],[75,2],[75,1],[75,1],[80,2],[80,2],[80,4],[80,4],[84,2],[86,4],[86,4],[86,6],[86,2],[94,3],[96,3],[98,4],[98,3],[98,5],[98,4],[98,2],[98,2],[98,2],[98,5],[120,2],[118,3],[118,1],[125,2],[127,3],[130,2],[108,1],[108,2],[122,2],[105,1],[105,1],[114,3],[135,2],[138,7],[143,3],[57,3],[57,3],[147,2],[150,3],[154,3],[151,1],[151,2],[151,2],[151,3],[151,4],[151,2],[151,6],[151,1],[93,1],[93,1],[165,4],[166,4],[166,6],[171,1],[171,1],[171,1],[171,1],[158,2],[79,1],[79,1],[79,1],[68,2],[176,1],[176,5],[179,1],[179,4],[25,3],[182,3],[145,2],[145,2],[188,1],[186,2],[192,2],[190,2],[195,1],[195,1],[196,2],[199,2],[156,2],[156,2],[202,2],[207,1],[207,2],[205,2],[209,2],[211,2],[214,2],[216,2],[219,2],[218,2],[220,1],[220,2],[220,3],[225,1],[225,1],[225,4],[226,1],[226,2],[187,3],[187,3],[203,3],[203,3],[200,1],[200,1],[212,1],[212,1],[234,1],[235,1],[235,1],[139,1],[139,1],[44,1],[236,1],[236,1],[236,1],[236,1],[46,1],[238,2],[241,2],[239,2],[245,2],[243,1],[243,3],[243,4],[247,2],[253,2],[253,2],[253,2],[251,2],[261,2],[259,2],[259,2],[259,2],[259,1],[264,1],[264,1],[264,1],[264,1],[264,1],[264,1],[264,1],[77,3],[67,1],[67,2],[67,4],[67,4],[67,6],[67,8],[67,8],[67,2],[67,4],[67,2],[67,4],[67,3],[267,5],[267,5],[267,6],[288,4],[172,1],[172,2],[172,3],[172,1],[172,1],[172,1],[172,1],[172,1],[172,1],[255,1],[255,1],[255,1],[257,1],[257,1],[257,1],[291,1],[291,1],[291,1],[291,1],[55,1],[55,1],[307,1],[307,1],[237,1],[237,1],[311,5],[173,5],[313,1],[313,1],[313,1],[313,1],[313,1],[315,1],[315,1],[315,1],[185,1],[185,1],[185,1],[316,3],[319,3],[266,5],[320,1],[320,1],[320,1],[223,1],[223,1],[321,0],[321,1],[5,1],[5,1],[5,1],[9,0],[9,1],[322,1],[322,1],[10,0],[10,2],[18,0],[18,2],[22,0],[22,2],[26,0],[26,2],[27,0],[27,2],[30,0],[30,1],[323,1],[323,2],[33,1],[33,1],[34,0],[34,2],[35,0],[35,1],[37,0],[37,2],[40,1],[40,2],[324,1],[324,1],[42,0],[42,1],[50,0],[50,1],[51,0],[51,1],[54,0],[54,1],[56,0],[56,1],[58,0],[58,1],[59,0],[59,1],[60,0],[60,1],[61,0],[61,1],[65,1],[65,2],[71,1],[71,2],[74,1],[74,2],[88,0],[88,2],[90,0],[90,2],[91,1],[91,2],[92,0],[92,2],[95,1],[95,2],[97,0],[97,4],[99,0],[99,2],[101,0],[101,1],[102,0],[102,1],[103,1],[103,1],[104,0],[104,1],[106,1],[106,1],[106,1],[107,0],[107,1],[111,0],[111,1],[117,0],[117,1],[119,0],[119,2],[124,0],[124,1],[129,0],[129,1],[133,0],[133,1],[134,1],[134,1],[134,1],[136,0],[136,1],[137,0],[137,2],[140,0],[140,1],[141,0],[141,1],[142,0],[142,1],[144,0],[144,3],[146,0],[146,1],[148,0],[148,1],[149,0],[149,2],[152,0],[152,1],[153,0],[153,1],[155,0],[155,3],[157,0],[157,1],[162,0],[162,1],[167,0],[167,2],[168,0],[168,2],[169,1],[169,2],[170,0],[170,2],[175,0],[175,3],[177,0],[177,1],[178,0],[178,3],[180,0],[180,3],[181,0],[181,1],[183,0],[183,3],[184,0],[184,1],[189,0],[189,1],[191,0],[191,2],[194,0],[194,1],[198,0],[198,3],[201,0],[201,1],[204,0],[204,1],[206,0],[206,2],[208,1],[208,1],[210,0],[210,3],[213,0],[213,1],[215,0],[215,3],[217,0],[217,3],[339,1],[339,1],[339,1],[221,0],[221,1],[222,0],[222,1],[227,0],[227,3],[228,0],[228,1],[230,1],[230,2],[233,1],[233,2],[240,0],[240,2],[244,0],[244,2],[248,1],[248,1],[248,1],[248,1],[248,1],[248,1],[249,0],[249,1],[252,0],[252,2],[254,1],[254,1],[256,0],[256,2],[258,0],[258,2],[260,0],[260,2],[262,1],[262,1],[275,1],[275,1],[275,1],[275,1],[275,1],[278,0],[278,1],[281,0],[281,1],[282,1],[282,1],[284,0],[284,1],[286,0],[286,1],[287,0],[287,1]],performAction:function(Be,Ge,Ze,pt,mt,ne,Vn){var se=ne.length-1;switch(mt){case 1:if(ne[se-1]=ne[se-1]||{},Ct.base&&(ne[se-1].base=Ct.base),Ct.base="",ne[se-1].prefixes=Ct.prefixes,Ct.prefixes=null,Ct.pathOnly){if(ne[se-1].type==="path"||"termType"in ne[se-1])return ne[se-1];throw new Error("Received full SPARQL query in path only mode")}else if(ne[se-1].type==="path"||"termType"in ne[se-1])throw new Error("Received only path in full SPARQL mode");if(ne[se-1].type==="update"){const Dt={};for(const Jt of ne[se-1].updates)if(Jt.updateType==="insert"){const It={};for(const Yr of Jt.insert)if(Yr.type==="bgp"||Yr.type==="graph")for(const Zr of Yr.triples)Zr.subject.termType==="BlankNode"&&(It[Zr.subject.value]=!0),Zr.predicate.termType==="BlankNode"&&(It[Zr.predicate.value]=!0),Zr.object.termType==="BlankNode"&&(It[Zr.object.value]=!0);for(const Yr of Object.keys(It)){if(Dt[Yr])throw new Error("Detected reuse blank node across different INSERT DATA clauses");Dt[Yr]=!0}}}return ne[se-1];case 2:this.$={...ne[se-1],...ne[se],type:"query"};break;case 4:Ct.base=lu(ne[se]);break;case 5:Ct.prefixes||(Ct.prefixes={}),ne[se-1]=ne[se-1].substr(0,ne[se-1].length-1),ne[se]=lu(ne[se]),Ct.prefixes[ne[se-1]]=ne[se];break;case 6:this.$={...ne[se-3],...ds(ne[se-2]),...ne[se-1],...ne[se]};break;case 7:if(!Ct.skipValidation&&(lg(ne[se-3].variables.map(Jt=>cg(Jt.expression))).some(Jt=>Jt.aggregation==="count"&&!(Jt.expression instanceof Cy))||ne[se].group)){for(const Jt of ne[se-3].variables)if(Jt.termType==="Variable"){if(!ne[se].group||!ne[se].group.map(It=>lo(It)).includes(lo(Jt)))throw Error("Projection of ungrouped variable (?"+lo(Jt)+")")}else if(cg(Jt.expression).length===0){const It=MB(Jt.expression);for(const Yr of It)if(!ne[se].group||!ne[se].group.map||!ne[se].group.map(Zr=>lo(Zr)).includes(lo(Yr)))throw Error("Use of ungrouped variable in projection of operation (?"+lo(Yr)+")")}}const fo=ne[se-1].where.filter(Dt=>Dt.type==="query");if(fo.length>0){const Dt=ne[se-3].variables.filter(It=>It.variable&&It.variable.value).map(It=>It.variable.value),Jt=lg(fo.map(It=>It.variables)).map(It=>It.value||It.variable.value);for(const It of Dt)if(Jt.indexOf(It)>=0)throw Error("Target id of 'AS' (?"+It+") already used in subquery")}this.$=Dr(ne[se-3],ds(ne[se-2]),ne[se-1],ne[se]);break;case 8:this.$=Dr({queryType:"CONSTRUCT",template:ne[se-3]},ds(ne[se-2]),ne[se-1],ne[se]);break;case 9:this.$=Dr({queryType:"CONSTRUCT",template:ne[se-2]=ne[se-2]?ne[se-2].triples:[]},ds(ne[se-5]),{where:[{type:"bgp",triples:so([],ne[se-2])}]},ne[se]);break;case 10:this.$=Dr({queryType:"DESCRIBE",variables:ne[se-3]==="*"?[new Cy]:ne[se-3]},ds(ne[se-2]),ne[se-1],ne[se]);break;case 11:this.$=Dr({queryType:"ASK"},ds(ne[se-2]),ne[se-1],ne[se]);break;case 12:this.$=Dr(ne[se-1],{variables:[new Cy]});break;case 13:const pg=ne[se].map(Dt=>Dt.value||Dt.variable.value),By=FB(pg);if(By.length>0)throw Error("Two or more of the resulting columns have the same name (?"+By[0]+")");this.$=Dr(ne[se-1],{variables:ne[se]});break;case 14:this.$=Dr({queryType:"SELECT"},ne[se]&&(ne[se-1]=mn(ne[se]),ne[se]={},ne[se][ne[se-1]]=!0,ne[se]));break;case 16:case 27:this.$=oo(ne[se-3],{variable:ne[se-1]});break;case 17:case 18:this.$=Dr(ne[se-3],ne[se-2],ne[se-1],ne[se],{type:"query"});break;case 19:case 58:this.$={iri:ne[se],named:!!ne[se-1]};break;case 20:this.$={where:ne[se].patterns};break;case 21:this.$=Dr(ne[se-1],ne[se]);break;case 22:this.$=Dr(ne[se-2],ne[se-1],ne[se]);break;case 23:this.$={group:ne[se]};break;case 24:case 25:case 28:case 31:case 33:case 34:this.$=oo(ne[se]);break;case 26:this.$=oo(ne[se-1]);break;case 29:this.$={having:ne[se]};break;case 30:this.$={order:ne[se]};break;case 32:this.$=oo(ne[se],{descending:!0});break;case 35:this.$={limit:co(ne[se])};break;case 36:this.$={offset:co(ne[se])};break;case 37:this.$={limit:co(ne[se-2]),offset:co(ne[se])};break;case 38:this.$={limit:co(ne[se]),offset:co(ne[se-2])};break;case 39:case 43:this.$={type:"values",values:ne[se]};break;case 40:case 84:this.$=ne[se-1].map(Dt=>({[ne[se-3]]:Dt}));break;case 41:case 85:this.$=ne[se-1].map(()=>({}));break;case 42:case 86:var Ea=ne[se-4].length;ne[se-4]=ne[se-4].map(ng),this.$=ne[se-1].map(function(Dt){if(Dt.length!==Ea)throw Error("Inconsistent VALUES length");for(var Jt={},It=0;ItJt.type==="bind")){const Jt=ne[se-1].indexOf(Dt),It=new Set;for(const Yr of ne[se-1].slice(0,Jt))(Yr.type==="group"||Yr.type==="bgp")&&TA(Yr).forEach(Zr=>It.add(Zr));if(It.has(Dt.variable.value))throw Error("Variable used to bind is already bound (?"+Dt.variable.value+")")}this.$={type:"group",patterns:ne[se-1]};break;case 71:this.$=ne[se-1]?Ci([ne[se-1]],ne[se]):Ci(ne[se]);break;case 72:this.$=ne[se]?[ne[se-2],ne[se]]:ne[se-2];break;case 75:this.$=Dr(ne[se],{type:"optional"});break;case 76:this.$=Dr(ne[se],{type:"minus"});break;case 77:this.$=Dr(ne[se],{type:"graph",name:ne[se-1]});break;case 78:this.$=Dr(ne[se],{type:"service",name:ne[se-1],silent:!!ne[se-2]});break;case 79:this.$={type:"filter",expression:ne[se]};break;case 80:this.$={type:"bind",variable:ne[se-1],expression:ne[se-3]};break;case 89:this.$=fu(ne[se]);break;case 90:this.$=void 0;break;case 91:this.$=ne[se-1].length?{type:"union",patterns:Ci(ne[se-1].map(ag),[ag(ne[se])])}:ne[se];break;case 95:this.$={...ne[se],function:ne[se-1]};break;case 96:this.$={type:"functionCall",args:[]};break;case 97:this.$={type:"functionCall",args:ls(ne[se-2],ne[se-1]),distinct:!!ne[se-3]};break;case 98:case 115:case 128:case 247:case 249:case 251:case 253:case 255:case 263:case 267:case 297:case 299:case 303:case 307:case 328:case 341:case 349:case 355:case 361:case 367:case 369:case 373:case 375:case 379:case 381:case 385:case 391:case 395:case 401:case 405:case 409:case 411:case 420:case 428:case 430:case 440:case 444:case 446:case 448:this.$=[];break;case 99:this.$=ls(ne[se-2],ne[se-1]);break;case 101:this.$=Ci(ne[se-2],[ne[se-1]]);break;case 102:case 112:this.$=fg(ne[se].map(Dt=>Dr(ia(ne[se-1]),Dt)));break;case 103:this.$=fg(so(ne[se].map(Dt=>Dr(ia(ne[se-1].entity),Dt)),ne[se-1].triples));break;case 105:this.$=Ci([ne[se-1]],ne[se]);break;case 106:this.$=Ci(ne[se]);break;case 107:this.$=ug(ne[se-1],ne[se]);break;case 109:case 237:this.$=Ct.factory.namedNode(OB);break;case 110:case 118:this.$=ls(ne[se-1],ne[se]);break;case 111:this.$=ne[se]?{annotation:ne[se],object:ne[se-1]}:ne[se-1];break;case 113:this.$=ne[se]?fg(so(ne[se].map(Dt=>Dr(ia(ne[se-1].entity),Dt)),ne[se-1].triples)):ne[se-1].triples;break;case 114:this.$=ug(...ne[se-1],ne[se]);break;case 116:this.$=ug(...ne[se]);break;case 117:case 159:case 163:this.$=[ne[se-1],ne[se]];break;case 119:this.$=ne[se]?{object:ne[se-1],annotation:ne[se]}:ne[se-1];break;case 120:this.$=ne[se-1].length?uo("|",ls(ne[se-1],ne[se])):ne[se];break;case 121:this.$=ne[se-1].length?uo("/",ls(ne[se-1],ne[se])):ne[se];break;case 122:this.$=ne[se]?uo(ne[se],[ne[se-1]]):ne[se-1];break;case 123:this.$=ne[se-1]?uo(ne[se-1],[ne[se]]):ne[se];break;case 125:case 131:this.$=uo(ne[se-1],[ne[se]]);break;case 129:this.$=uo("|",ls(ne[se-2],ne[se-1]));break;case 132:case 134:this.$=jB(ne[se-1]);break;case 133:case 135:this.$=LB(ne[se-1]);break;case 140:this.$={entity:ne[se],triples:[]};break;case 145:this.$=ng(ne[se]);break;case 149:this.$=Ct.factory.namedNode(yA);break;case 151:case 153:case 158:case 162:this.$=ig(ne[se-1],ne[se]);break;case 152:this.$=["||",ne[se]];break;case 154:this.$=["&&",ne[se]];break;case 156:this.$=Kr(ne[se-1],[ne[se-2],ne[se]]);break;case 157:this.$=Kr(ne[se-2]?"notin":"in",[ne[se-3],ne[se]]);break;case 160:this.$=["+",ig(ne[se-1],ne[se])];break;case 161:var Fy=ji(ne[se-1].value.replace("-",""),ne[se-1].datatype);this.$=["-",ig(Fy,ne[se])];break;case 164:this.$=Kr("UPLUS",[ne[se]]);break;case 165:this.$=Kr(ne[se-1],[ne[se]]);break;case 166:this.$=Kr("UMINUS",[ne[se]]);break;case 177:this.$=Kr(mn(ne[se-1]));break;case 178:this.$=Kr(mn(ne[se-3]),[ne[se-1]]);break;case 179:this.$=fu(Kr(mn(ne[se-3]),[ne[se-1]]));break;case 180:this.$=Kr(mn(ne[se-5]),[ne[se-3],ne[se-1]]);break;case 181:this.$=Kr(mn(ne[se-7]),[ne[se-5],ne[se-3],ne[se-1]]);break;case 182:this.$=fu(Kr(mn(ne[se-7]),[ne[se-5],ne[se-3],ne[se-1]]));break;case 183:this.$=Kr(mn(ne[se-1]),ne[se]);break;case 184:this.$=Kr("bound",[ng(ne[se-1])]);break;case 185:this.$=Kr(ne[se-1],[]);break;case 186:this.$=Kr(ne[se-3],[ne[se-1]]);break;case 187:this.$=Kr(ne[se-2]?"notexists":"exists",[ag(ne[se])]);break;case 188:case 189:this.$=oo(ne[se-1],{type:"aggregate",aggregation:mn(ne[se-4]),distinct:!!ne[se-2]});break;case 190:this.$=oo(ne[se-2],{type:"aggregate",aggregation:mn(ne[se-5]),distinct:!!ne[se-3],separator:typeof ne[se-1]=="string"?ne[se-1]:" "});break;case 192:this.$=ji(ne[se]);break;case 193:this.$=PB(ne[se-1],mn(ne[se].substr(1)));break;case 194:this.$=ji(ne[se-2],ne[se]);break;case 195:case 204:this.$=ji(ne[se],bA);break;case 196:case 205:this.$=ji(ne[se],gA);break;case 197:case 206:this.$=ji(mn(ne[se]),mA);break;case 200:this.$=ji(ne[se].toLowerCase(),IB);break;case 201:this.$=ji(ne[se].substr(1),bA);break;case 202:this.$=ji(ne[se].substr(1),gA);break;case 203:this.$=ji(ne[se].substr(1).toLowerCase(),mA);break;case 207:case 208:this.$=SA(ne[se],1);break;case 209:case 210:this.$=SA(ne[se],3);break;case 211:this.$=Ct.factory.namedNode(lu(ne[se]));break;case 213:var qy=ne[se].indexOf(":"),Nr=ne[se].substr(0,qy),Li=Ct.prefixes[Nr];if(!Li)throw new Error("Unknown prefix: "+Nr);var fs=lu(Li+ne[se].substr(qy+1));this.$=Ct.factory.namedNode(fs);break;case 214:if(ne[se]=ne[se].substr(0,ne[se].length-1),!(ne[se]in Ct.prefixes))throw new Error("Unknown prefix: "+ne[se]);var fs=lu(Ct.prefixes[ne[se]]);this.$=Ct.factory.namedNode(fs);break;case 215:this.$=du(ne[se].replace(/^(_:)/,""));break;case 216:this.$=du();break;case 217:case 218:case 232:this.$=fu(sg(ne[se-3],ne[se-2],ne[se-1]));break;case 230:case 231:this.$=fu(ne[se-1]);break;case 248:case 250:case 252:case 254:case 256:case 260:case 264:case 268:case 270:case 292:case 294:case 296:case 298:case 300:case 302:case 304:case 306:case 329:case 342:case 356:case 368:case 370:case 372:case 374:case 392:case 402:case 425:case 427:case 429:case 431:case 441:case 445:case 447:case 449:ne[se-1].push(ne[se]);break;case 259:case 269:case 291:case 293:case 295:case 301:case 305:case 371:case 424:case 426:this.$=[ne[se]];break;case 308:ne[se-3].push(ne[se-2]);break;case 350:case 362:case 376:case 380:case 382:case 386:case 396:case 406:case 410:case 412:case 421:ne[se-2].push(ne[se-1]);break}},table:[e(u,s,{3:1,4:2,10:3}),{1:[3]},e(n,[2,307],{5:4,7:5,321:6,214:7,8:8,96:9,215:10,17:11,21:12,97:16,38:17,6:[2,238],13:r,16:r,45:r,197:r,224:r,229:r,308:r,24:[1,13],32:[1,14],36:[1,15],41:a}),e([6,13,16,24,32,36,41,45,100,110,113,115,116,123,126,131,197,224,229,308,329,330,331,332,333],[2,3],{322:19,11:20,14:21,12:[1,22],15:[1,23]}),{6:[1,24]},{6:[2,240]},{6:[2,241]},{6:[2,242]},{6:[2,243],9:25,84:26,85:o},{6:[2,239]},e(l,[2,411],{216:28,217:29}),e(c,[2,249],{18:30}),e(c,[2,251],{22:31}),e(d,[2,255],{25:32,27:33,29:[1,34]}),{13:h,16:f,33:35,39:[1,37],44:39,55:40,87:p,139:38,307:43,308:y,323:36},e(c,[2,267],{37:46}),e(b,[2,326],{98:47,103:49,106:50,117:55,130:61,100:[1,48],110:[1,51],113:[1,52],115:[1,53],116:[1,54],131:[1,62],329:[1,56],330:[1,57],331:[1,58],332:[1,59],333:[1,60]}),{39:[1,63],40:64,43:65,44:66,45:m,87:p},e(g,[2,273],{42:68,324:69,325:[1,70],326:[1,71]}),e(u,[2,248]),e(u,[2,245]),e(u,[2,246]),{13:[1,72]},{16:[1,73]},{1:[2,1]},{6:[2,2]},{6:[2,244]},{45:[1,77],85:[1,78],86:74,87:[1,75],89:[1,76]},e([6,13,16,45,48,82,87,89,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312],[2,120],{337:[1,79]}),e(v,[2,418],{218:80,222:81,229:[1,82]}),{19:83,28:_,29:w,52:84,53:S,56:85},{19:88,28:_,29:w,52:89,53:S,56:85},e(c,[2,253],{26:90}),{28:[1,91],52:92,53:S},e(A,[2,385],{181:93,182:94,183:95,31:[2,383]}),e(D,[2,263],{34:96}),e(D,[2,261],{44:39,55:40,307:43,139:97,13:h,16:f,87:p,308:y}),e(D,[2,262]),e(L,[2,259]),e(E,[2,143]),e(E,[2,144]),e([6,13,16,28,29,31,39,45,47,48,53,63,70,73,76,78,81,82,83,85,87,89,112,159,160,161,163,164,193,197,224,229,231,232,242,246,250,263,265,268,269,270,271,272,273,274,276,277,279,280,283,285,290,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,314,317,318,335,338,341,342,343,344,345,346,347,348,349,350,351],[2,145]),e(O,[2,211]),e(O,[2,212]),e(O,[2,213]),e(O,[2,214]),{19:98,28:_,29:w,52:99,53:S,56:85},{6:[2,309],99:100,193:[1,101]},e(P,[2,311],{101:102,328:[1,103]}),e(j,[2,317],{104:104,328:[1,105]}),e(U,[2,322],{107:106,328:[1,107]}),{111:108,112:[2,324],328:[1,109]},{29:M,114:110},{29:M,114:112},{29:M,114:113},{118:114,123:[1,115],125:116,126:q},e(Q,[2,315]),e(Q,[2,316]),e(Z,[2,319]),e(Z,[2,320]),e(Z,[2,321]),e(b,[2,327]),{13:h,16:f,55:118,307:43,308:y},e(c,[2,12]),e(c,[2,13],{44:66,43:119,45:m,87:p}),e(K,[2,269]),e(K,[2,15]),{13:h,16:f,44:136,45:fe,46:120,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(g,[2,14]),e(g,[2,274]),e(g,[2,271]),e(g,[2,272]),e(u,[2,4]),{13:[1,177]},e(me,[2,39]),{29:[1,178]},{29:[1,179]},{87:[1,181],91:180},{45:[1,187],87:[1,185],89:[1,186],93:182,165:183,166:184},e(l,[2,410]),e([6,13,16,45,48,82,87,89,231,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,337],[2,121],{338:[1,188]}),{13:h,16:f,45:[1,193],55:194,197:Se,219:189,220:190,223:191,224:[1,192],307:43,308:y},e(v,[2,419]),e(W,we,{20:196,59:197,69:198,70:Te}),e(c,[2,250]),{29:Le,57:200},e(P,[2,279],{54:202,327:[1,203]}),{29:[2,282]},e($e,We,{23:204,58:205,62:206,63:tt}),e(c,[2,252]),{19:208,28:_,29:w,52:209,53:S,56:85},{29:[1,210]},e(d,[2,256]),{31:[1,211]},{31:[2,384]},{13:h,16:f,44:215,45:lt,55:220,82:X,87:p,89:ut,145:212,172:221,185:213,187:214,231:le,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:pe},e(De,[2,265],{56:85,35:227,52:228,19:229,28:_,29:w,53:S}),e(L,[2,260]),e($e,We,{58:205,62:206,23:230,63:tt}),e(c,[2,268]),{6:[2,45]},e(u,s,{10:3,4:231}),{13:h,16:f,55:232,307:43,308:y},e(P,[2,312]),{105:233,112:Ue,122:234,132:[1,237],134:235,327:[1,238],334:[1,239]},e(j,[2,318]),e(P,Fe,{108:240,133:242,112:Ye,132:Ve}),e(U,[2,323]),{112:[1,244]},{112:[2,325]},e(Je,[2,50]),e(A,nt,{135:245,136:246,143:247,144:248,31:yt,112:yt}),e(Je,[2,51]),e(Je,[2,52]),e(ft,[2,328],{119:249}),{29:M,114:250},e(ft,[2,56]),{29:M,114:251},e(b,[2,59]),e(K,[2,270]),{47:[1,252]},e(et,[2,150]),e(Ir,[2,428],{240:253}),e(Ke,[2,430],{244:254}),e(Ke,[2,155],{248:255,249:256,250:[2,438],290:[1,257],341:[1,258],342:[1,259],343:[1,260],344:[1,261],345:[1,262],346:[1,263]}),e(ye,[2,440],{252:264}),e(Pe,[2,448],{260:265}),{13:h,16:f,44:136,45:fe,55:133,67:132,68:134,77:131,82:X,87:p,172:135,255:154,257:155,264:266,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},{13:h,16:f,44:136,45:fe,55:133,67:132,68:134,77:131,82:X,87:p,172:135,255:154,257:155,264:267,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},{13:h,16:f,44:136,45:fe,55:133,67:132,68:134,77:131,82:X,87:p,172:135,255:154,257:155,264:268,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(Pe,[2,167]),e(Pe,[2,168]),e(Pe,[2,169]),e(Pe,[2,170],{176:269,45:Me,89:it}),e(Pe,[2,171]),e(Pe,[2,172]),e(Pe,[2,173]),e(Pe,[2,174]),{13:h,16:f,44:136,45:fe,46:272,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(at,[2,176]),{89:[1,273]},{45:[1,274]},{45:[1,275]},{45:[1,276]},{45:[1,277]},{45:[1,278]},{45:Tt,89:Vt,179:279},{45:[1,282]},{45:[1,284],89:[1,283]},{279:[1,285]},e(tr,[2,192],{292:[1,286],293:[1,287]}),e(tr,[2,195]),e(tr,[2,196]),e(tr,[2,197]),e(tr,[2,198]),e(tr,[2,199]),e(tr,[2,200]),{13:h,16:f,44:39,55:40,82:X,87:p,139:289,172:291,255:154,257:155,266:290,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,320:288},{45:[1,292]},{45:[1,293]},{45:[1,294]},e(di,[2,452]),e(di,[2,453]),e(di,[2,454]),e(di,[2,455]),e(di,[2,456]),{279:[2,458]},e(yn,[2,207]),e(yn,[2,208]),e(yn,[2,209]),e(yn,[2,210]),e(tr,[2,201]),e(tr,[2,202]),e(tr,[2,203]),e(tr,[2,204]),e(tr,[2,205]),e(tr,[2,206]),e(u,[2,5]),e(or,[2,297],{88:295}),e(Mn,[2,299],{90:296}),{48:[1,297],87:[1,298]},e(Hr,[2,301]),e(me,[2,43]),e(me,[2,82]),e(me,[2,83]),{29:[1,299]},{29:[1,300]},{87:[1,302],169:301},e(l,[2,412]),e(Hn,[2,123]),e(Hn,[2,416],{221:303,339:304,39:[1,306],263:[1,307],340:[1,305]}),e(Pr,[2,124]),{13:h,16:f,45:[1,311],55:194,89:[1,310],197:Se,223:312,225:308,226:309,229:fi,307:43,308:y},e(l,r,{215:10,214:314}),e(Pr,[2,236]),e(Pr,[2,237]),e(Mr,[2,6]),e(Ni,[2,287],{60:315,72:316,73:[1,317]}),e(W,[2,286]),{13:h,16:f,45:fe,55:323,67:321,68:322,71:318,77:320,79:319,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,307:43,308:y,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e([6,31,63,70,73,81,83,85],[2,20]),e(A,Zi,{38:17,49:324,147:325,17:326,21:327,148:328,154:329,155:330,29:bn,31:bn,85:bn,112:bn,159:bn,160:bn,161:bn,163:bn,164:bn,41:a}),{13:h,16:f,55:331,307:43,308:y},e(P,[2,280]),e(Mr,[2,7]),e(W,we,{59:197,69:198,20:332,70:Te}),e($e,[2,284]),{64:[1,333]},e($e,We,{58:205,62:206,23:334,63:tt}),e(c,[2,254]),e(A,nt,{144:248,30:335,143:336,31:[2,257]}),e(c,[2,100]),{31:[2,387],184:337,335:[1,338]},{13:h,16:f,44:39,55:40,87:p,139:342,186:339,190:340,195:341,197:Xr,307:43,308:y},e(os,[2,389],{44:39,55:40,307:43,190:340,195:341,139:342,188:344,189:345,186:346,13:h,16:f,87:p,197:Xr,308:y}),e(Zn,[2,227]),e(Zn,[2,228]),e(Zn,[2,229]),{13:h,16:f,44:215,45:lt,55:220,82:X,87:p,89:ut,172:221,185:351,187:350,200:348,230:347,231:le,234:349,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:pe},{13:h,16:f,44:39,55:40,87:p,139:342,186:352,190:340,195:341,197:Xr,307:43,308:y},e(Zn,[2,146]),e(Zn,[2,147]),e(Zn,[2,148]),e(Zn,[2,149]),{13:h,16:f,44:354,55:355,82:X,87:p,172:357,237:356,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:358,312:pe,313:353},e(ue,[2,215]),e(ue,[2,216]),e($e,We,{58:205,62:206,23:359,63:tt}),e(D,[2,264]),e(De,[2,266]),e(Mr,[2,11]),e(n,[2,308],{6:[2,310]}),e(Je,[2,313],{102:360,120:361,121:[1,362]}),e(Je,[2,47]),e(Je,[2,63]),e(Je,[2,64]),{13:h,16:f,55:363,307:43,308:y},e(Je,[2,336]),e(Je,[2,337]),e(Je,[2,338]),{109:[1,364]},e(ve,[2,60]),{13:h,16:f,55:365,307:43,308:y},e(P,[2,335]),{13:h,16:f,55:366,307:43,308:y},{31:[1,367]},e(je,[2,341],{137:368}),e(je,[2,340]),{13:h,16:f,44:215,45:lt,55:220,82:X,87:p,89:ut,145:369,172:221,185:213,187:214,231:le,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:pe},{28:[1,370],127:371,128:[1,372]},e(ft,[2,330],{124:373,125:374,126:q}),e(ft,[2,57]),{44:375,87:p},e(et,[2,151],{241:376,242:[1,377]}),e(Ir,[2,153],{245:378,246:[1,379]}),{13:h,16:f,44:136,45:fe,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,247:380,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},{250:[1,381]},e(Xe,[2,432]),e(Xe,[2,433]),e(Xe,[2,434]),e(Xe,[2,435]),e(Xe,[2,436]),e(Xe,[2,437]),{250:[2,439]},e([47,48,193,242,246,250,272,290,341,342,343,344,345,346],[2,158],{253:382,254:383,255:384,257:385,263:[1,386],265:[1,387],297:z,298:Y,299:te,300:ce,301:Ae,302:Ie}),e(ye,[2,162],{261:388,262:389,39:st,338:ht}),e(Pe,[2,164]),e(Pe,[2,165]),e(Pe,[2,166]),e(at,[2,95]),e(at,[2,96]),e(Xe,[2,377],{177:392,325:[1,393]}),{48:[1,394]},e(at,[2,177]),{13:h,16:f,44:136,45:fe,46:395,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},{13:h,16:f,44:136,45:fe,46:396,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},{13:h,16:f,44:136,45:fe,46:397,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},{13:h,16:f,44:136,45:fe,46:398,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},{13:h,16:f,44:136,45:fe,46:399,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(at,[2,183]),e(at,[2,98]),e(Xe,[2,381],{180:400}),{87:[1,401]},e(at,[2,185]),{13:h,16:f,44:136,45:fe,46:402,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},{29:Le,57:403},e(tr,[2,193]),{13:h,16:f,55:404,307:43,308:y},{13:h,16:f,44:39,55:40,87:p,139:342,195:405,197:Xr,307:43,308:y},e(St,[2,233]),e(St,[2,234]),e(St,[2,235]),e(Ht,[2,459],{281:406,325:[1,407]}),e(Xe,[2,463],{284:408,325:[1,409]}),e(Xe,[2,465],{286:410,325:[1,411]}),{13:h,16:f,31:[1,412],55:414,82:X,171:413,172:415,173:416,174:Xt,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:lr},{31:[1,419],89:[1,420]},{29:[1,421]},e(Hr,[2,302]),e(or,[2,367],{167:422}),e(Mn,[2,369],{168:423}),{48:[1,424],87:[1,425]},e(Hr,[2,371]),e(Hn,[2,122]),e(Hn,[2,417]),e(Hn,[2,413]),e(Hn,[2,414]),e(Hn,[2,415]),e(Pr,[2,125]),e(Pr,[2,127]),e(Pr,[2,128]),e(vr,[2,420],{227:426}),e(Pr,[2,130]),{13:h,16:f,55:194,197:Se,223:427,307:43,308:y},{48:[1,428]},e(zt,[2,289],{61:429,80:430,81:[1,431],83:[1,432]}),e(Ni,[2,288]),{64:[1,433]},e(W,[2,29],{307:43,267:139,275:146,278:149,77:320,67:321,68:322,55:323,79:434,13:h,16:f,45:fe,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,276:$,277:N,279:R,280:T,283:x,285:B,308:y,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke}),e(Fn,[2,293]),e(ei,[2,92]),e(ei,[2,93]),e(ei,[2,94]),{45:Me,89:it,176:269},{31:[1,435]},{31:[1,436]},{19:437,28:_,29:w,56:85},{19:438,28:_,29:w,56:85},e(Fr,[2,355],{149:439}),e(Fr,[2,354]),{13:h,16:f,44:215,45:gn,55:220,82:X,87:p,89:ut,156:440,172:221,185:441,203:442,231:$n,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:pe},e(D,[2,19]),e(zt,[2,21]),{13:h,16:f,44:450,45:Qn,55:323,65:445,66:446,67:447,68:448,87:p,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,307:43,308:y,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(Mr,[2,8]),{31:[1,451]},{31:[2,258]},{31:[2,101]},e(A,[2,386],{31:[2,388]}),e(os,[2,102]),e(ti,[2,391],{191:452}),e(A,[2,395],{196:453,198:454}),e(A,[2,108]),e(A,[2,109]),e(os,[2,103]),e(os,[2,104]),e(os,[2,390]),{13:h,16:f,44:215,45:lt,48:[1,455],55:220,82:X,87:p,89:ut,172:221,185:351,187:350,200:456,231:le,234:349,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:pe},e(ea,[2,424]),e(no,[2,136]),e(no,[2,137]),e(Kt,[2,140]),{232:[1,457]},{13:h,16:f,44:39,55:40,87:p,139:342,195:458,197:Xr,307:43,308:y},e(St,[2,219]),e(St,[2,220]),e(St,[2,221]),e(St,[2,222]),e(St,[2,223]),e(Mr,[2,10]),e(Je,[2,46]),e(Je,[2,314]),{112:Ue,122:459},e(Je,[2,62]),e(P,Fe,{133:242,108:460,112:Ye,132:Ve}),e(ve,[2,61]),e(Je,[2,49]),e([6,28,126,128,193],[2,65]),{31:[2,66],112:[1,462],138:461},e(je,[2,351],{146:463,335:[1,464]}),{29:Le,57:465},e(ft,[2,329]),e(P,[2,332],{129:466,327:[1,467]}),e(ft,[2,55]),e(ft,[2,331]),{48:[1,468]},e(Ir,[2,429]),{13:h,16:f,44:136,45:fe,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,239:469,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(Ke,[2,431]),{13:h,16:f,44:136,45:fe,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,243:470,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(Ke,[2,156]),{45:Tt,89:Vt,179:471},e(ye,[2,441]),{13:h,16:f,44:136,45:fe,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,251:472,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(Pe,[2,444],{256:473}),e(Pe,[2,446],{258:474}),e(Xe,[2,442]),e(Xe,[2,443]),e(Pe,[2,449]),{13:h,16:f,44:136,45:fe,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,255:154,257:155,259:475,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(Xe,[2,450]),e(Xe,[2,451]),e(Xe,[2,379],{178:476}),e(Xe,[2,378]),e([6,13,16,29,31,39,45,47,48,73,76,78,81,82,83,85,87,89,112,159,160,161,163,164,193,231,242,246,250,263,265,268,269,270,271,272,273,274,276,277,279,280,283,285,290,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,312,335,338,341,342,343,344,345,346,347,348,349,350,351],[2,175]),{48:[1,477]},{48:[1,478]},{272:[1,479]},{272:[1,480]},{272:[1,481]},{13:h,16:f,44:136,45:fe,46:482,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},{48:[1,483]},{48:[1,484]},e(at,[2,187]),e(tr,[2,194]),{13:h,16:f,44:39,55:40,82:X,87:p,139:289,172:291,255:154,257:155,266:290,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,320:485},{13:h,16:f,39:[1,487],44:136,45:fe,46:488,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,282:486,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(Ht,[2,460]),{13:h,16:f,44:136,45:fe,46:489,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(Xe,[2,464]),{13:h,16:f,44:136,45:fe,46:490,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(Xe,[2,466]),e(me,[2,40]),e(or,[2,298]),e(zr,[2,87]),e(zr,[2,88]),e(zr,[2,89]),e(zr,[2,90]),{13:h,16:f,55:492,82:X,172:493,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,311:494,312:pe,315:491},e(me,[2,41]),e(Mn,[2,300]),e(ri,[2,303],{92:495}),{13:h,16:f,31:[1,496],55:414,82:X,171:497,172:415,173:416,174:Xt,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:lr},{31:[1,498],89:[1,499]},{29:[1,500]},e(Hr,[2,372]),{13:h,16:f,48:[2,422],55:194,197:Se,223:312,226:502,228:501,229:fi,307:43,308:y},e(Pr,[2,131]),e(Pr,[2,126]),e(zt,[2,22]),e(zt,[2,290]),{82:[1,503]},{82:[1,504]},{13:h,16:f,44:510,45:fe,55:323,67:321,68:322,74:505,75:506,76:Aa,77:320,78:Iy,79:509,87:p,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,307:43,308:y,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(Fn,[2,294]),e(sA,[2,69]),e(sA,[2,70]),e(W,we,{59:197,69:198,20:511,70:Te}),e($e,We,{58:205,62:206,23:512,63:tt}),{29:[2,375],31:[2,71],84:522,85:o,112:[1,518],150:513,151:514,158:515,159:[1,516],160:[1,517],161:[1,519],163:[1,520],164:[1,521],175:523},e(Fr,[2,363],{157:524,335:[1,525]}),e(l,r,{215:10,202:526,205:527,208:528,214:529,44:530,87:p}),e(Py,[2,399],{215:10,205:527,208:528,214:529,44:530,204:531,202:532,13:r,16:r,45:r,197:r,224:r,229:r,308:r,87:p}),{13:h,16:f,44:215,45:gn,55:220,82:X,87:p,89:ut,172:221,185:351,203:536,212:534,231:$n,233:533,234:535,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:pe},e(l,r,{215:10,205:527,208:528,214:529,44:530,202:537,87:p}),e($e,[2,23],{307:43,267:139,275:146,278:149,55:323,67:447,68:448,44:450,66:538,13:h,16:f,45:Qn,87:p,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,276:$,277:N,279:R,280:T,283:x,285:B,308:y,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke}),e(us,[2,291]),e(us,[2,24]),e(us,[2,25]),{13:h,16:f,44:136,45:fe,46:539,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(us,[2,28]),e($e,We,{58:205,62:206,23:540,63:tt}),e([31,112,232,318,335],[2,105],{192:541,193:[1,542]}),e(ti,[2,107]),{13:h,16:f,44:215,45:lt,55:220,82:X,87:p,89:ut,172:221,185:351,187:350,199:543,200:544,231:le,234:349,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:pe},e(oA,[2,132]),e(ea,[2,425]),e(oA,[2,133]),{13:h,16:f,44:354,55:355,82:X,87:p,172:357,237:356,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:358,312:pe,313:545},e(Je,[2,54]),e(Je,[2,48]),e(je,[2,342]),{13:h,16:f,44:39,55:40,87:p,139:546,307:43,308:y},e(je,[2,68]),e(A,[2,350],{31:uA,112:uA}),e(Je,[2,53]),{13:h,16:f,55:547,307:43,308:y},e(P,[2,333]),e(K,[2,16]),e(Ir,[2,152]),e(Ke,[2,154]),e(Ke,[2,157]),e(ye,[2,159]),e(ye,[2,160],{262:389,261:548,39:st,338:ht}),e(ye,[2,161],{262:389,261:549,39:st,338:ht}),e(Pe,[2,163]),{13:h,16:f,44:136,45:fe,46:550,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(at,[2,178]),e(at,[2,179]),{13:h,16:f,44:136,45:fe,46:551,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},{13:h,16:f,44:136,45:fe,46:552,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},{13:h,16:f,44:136,45:fe,46:553,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},{48:[1,554],272:[1,555]},e(at,[2,184]),e(at,[2,186]),{314:[1,556]},{48:[1,557]},{48:[2,461]},{48:[2,462]},{48:[1,558]},{48:[2,467],193:[1,561],287:559,288:560},{13:h,16:f,55:194,197:Se,223:562,307:43,308:y},e(tg,[2,224]),e(tg,[2,225]),e(tg,[2,226]),{31:[1,563],45:cA,94:564},e(me,[2,84]),e(or,[2,368]),e(me,[2,85]),e(Mn,[2,370]),e(ri,[2,373],{170:566}),{48:[1,567]},{48:[2,423],337:[1,568]},e(zt,[2,35],{83:[1,569]}),e(zt,[2,36],{81:[1,570]}),e(Ni,[2,30],{307:43,267:139,275:146,278:149,77:320,67:321,68:322,55:323,79:509,44:510,75:571,13:h,16:f,45:fe,76:Aa,78:Iy,87:p,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,276:$,277:N,279:R,280:T,283:x,285:B,308:y,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke}),e(io,[2,295]),{45:fe,77:572},{45:fe,77:573},e(io,[2,33]),e(io,[2,34]),{31:[2,275],50:574,84:575,85:o},{31:[2,277],51:576,84:577,85:o},e(Fr,[2,356]),e(lA,[2,357],{152:578,335:[1,579]}),e(ta,[2,74]),{29:Le,57:580},{29:Le,57:581},{13:h,16:f,44:39,55:40,87:p,139:582,307:43,308:y},e(dA,[2,365],{162:583,328:[1,584]}),{13:h,16:f,45:fe,55:323,67:321,68:322,77:320,79:585,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,307:43,308:y,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},{45:[1,586]},e(ta,[2,81]),{29:Le,57:587},e(Fr,[2,73]),e(A,[2,362],{29:ra,31:ra,85:ra,112:ra,159:ra,160:ra,161:ra,163:ra,164:ra}),e(Py,[2,112]),e(ao,[2,401],{206:588}),e(A,[2,405],{209:589,210:590}),e(A,[2,403]),e(A,[2,404]),e(Py,[2,113]),e(Py,[2,400]),{13:h,16:f,44:215,45:gn,48:[1,591],55:220,82:X,87:p,89:ut,172:221,185:351,203:536,212:592,231:$n,234:535,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:pe},e(ea,[2,426]),e(Kt,[2,138]),e(Kt,[2,139]),{232:[1,593]},e(us,[2,292]),{47:[1,595],48:[1,594]},e(Mr,[2,9]),e(ti,[2,392]),e(ti,[2,393],{44:39,55:40,307:43,195:341,139:342,194:596,190:597,13:h,16:f,87:p,197:Xr,308:y}),e(ti,[2,110],{272:[1,598]}),e(Dy,[2,397],{201:599,316:600,317:[1,601]}),{314:[1,602]},{29:[1,603]},e(ft,[2,58]),e(Pe,[2,445]),e(Pe,[2,447]),{48:[1,604],272:[1,605]},{48:[1,606]},{272:[1,607]},{272:[1,608]},e(at,[2,99]),e(Xe,[2,382]),e([13,16,39,47,48,87,193,197,242,246,250,263,265,272,290,297,298,299,300,301,302,308,314,338,341,342,343,344,345,346],[2,232]),e(at,[2,188]),e(at,[2,189]),{48:[1,609]},{48:[2,468]},{289:[1,610]},{13:h,16:f,55:492,82:X,172:493,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,311:494,312:pe,315:611},e(me,[2,42]),e(ri,[2,304]),{13:h,16:f,55:414,82:X,95:612,171:613,172:415,173:416,174:Xt,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:lr},{31:[1,614],45:cA,94:615},e(Pr,[2,129]),e(vr,[2,421]),{82:[1,616]},{82:[1,617]},e(io,[2,296]),e(io,[2,31]),e(io,[2,32]),{31:[2,17]},{31:[2,276]},{31:[2,18]},{31:[2,278]},e(A,Zi,{155:330,153:618,154:619,29:na,31:na,85:na,112:na,159:na,160:na,161:na,163:na,164:na}),e(lA,[2,358]),e(ta,[2,75]),e(ta,[2,76]),{29:Le,57:620},{13:h,16:f,44:39,55:40,87:p,139:621,307:43,308:y},e(dA,[2,366]),e(ta,[2,79]),{13:h,16:f,44:136,45:fe,46:622,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(ta,[2,91],{336:[1,623]}),e([29,31,85,112,159,160,161,163,164,232,318,335],[2,114],{207:624,193:[1,625]}),e(ao,[2,117]),{13:h,16:f,44:215,45:gn,55:220,82:X,87:p,89:ut,172:221,185:351,203:536,211:626,212:627,231:$n,234:535,236:216,237:222,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,309:C,310:ee,311:217,312:pe},e(Zn,[2,134]),e(ea,[2,427]),e(Zn,[2,135]),e(us,[2,26]),{44:628,87:p},e(ti,[2,106]),e(ti,[2,394]),e(A,[2,396]),e(Dy,[2,111]),e(Dy,[2,398]),{13:h,16:f,44:39,55:40,87:p,139:342,186:629,190:340,195:341,197:Xr,307:43,308:y},e(ue,[2,217]),e(A,nt,{144:248,140:630,143:631,31:[2,343]}),e(at,[2,97]),e(Xe,[2,380]),e(at,[2,180]),{13:h,16:f,44:136,45:fe,46:632,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},{13:h,16:f,44:136,45:fe,46:633,55:133,67:132,68:134,77:131,82:X,87:p,172:135,224:he,238:121,239:122,243:123,247:124,251:125,255:154,257:155,259:126,263:xe,264:130,265:ie,266:137,267:139,268:ae,269:Oe,270:Ne,271:ge,273:de,274:oe,275:146,276:$,277:N,278:149,279:R,280:T,283:x,285:B,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:H,346:re,347:be,348:Re,349:Ce,350:Qe,351:ke},e(at,[2,190]),{290:[1,634]},{314:[1,635]},{13:h,16:f,48:[1,636],55:414,82:X,171:637,172:415,173:416,174:Xt,255:154,257:155,291:150,294:k,295:V,296:J,297:z,298:Y,299:te,300:ce,301:Ae,302:Ie,303:Ee,304:qe,305:G,306:F,307:43,308:y,312:lr},e(fA,[2,305]),e(me,[2,86]),e(ri,[2,374]),e(zt,[2,37]),e(zt,[2,38]),e(Fr,[2,72]),e(Fr,[2,360]),e(ta,[2,77]),{29:Le,57:638},{47:[1,639]},{29:[2,376]},e(ao,[2,402]),e(ao,[2,115],{215:10,208:528,214:529,44:530,205:640,13:r,16:r,45:r,197:r,224:r,229:r,308:r,87:p}),e(ao,[2,118],{272:[1,641]}),e(Ny,[2,407],{213:642,319:643,317:[1,644]}),{48:[1,645]},{318:[1,646]},{31:[1,647]},{31:[2,344]},{48:[1,648]},{48:[1,649]},{291:650,303:Ee,304:qe,305:G,306:F},e(zr,[2,218]),e(ri,[2,44]),e(fA,[2,306]),e(ta,[2,78]),{44:651,87:p},e(ao,[2,116]),e(A,[2,406]),e(Ny,[2,119]),e(Ny,[2,408]),e(l,r,{215:10,205:527,208:528,214:529,44:530,202:652,87:p}),e(us,[2,27]),e(Dy,[2,230]),e(hA,[2,345],{141:653,335:[1,654]}),e(at,[2,181]),e(at,[2,182]),{48:[2,191]},{48:[1,655]},{318:[1,656]},e(A,nt,{144:248,142:657,143:658,31:pA,112:pA}),e(hA,[2,346]),e(ta,[2,80]),e(Ny,[2,231]),e(je,[2,67]),e(je,[2,348])],defaultActions:{5:[2,240],6:[2,241],7:[2,242],9:[2,239],24:[2,1],25:[2,2],26:[2,244],87:[2,282],94:[2,384],100:[2,45],109:[2,325],166:[2,458],263:[2,439],336:[2,258],337:[2,101],487:[2,461],488:[2,462],560:[2,468],574:[2,17],575:[2,276],576:[2,18],577:[2,278],623:[2,376],631:[2,344],650:[2,191]},parseError:function(Be,Ge){if(Ge.recoverable)this.trace(Be);else{var Ze=new Error(Be);throw Ze.hash=Ge,Ze}},parse:function(Be){var Ge=this,Ze=[0],pt=[null],mt=[],ne=this.table,Vn="",se=0,Ea=0,My=2,Fy=1,qy=mt.slice.call(arguments,1),Nr=Object.create(this.lexer),Li={yy:{}};for(var fs in this.yy)Object.prototype.hasOwnProperty.call(this.yy,fs)&&(Li.yy[fs]=this.yy[fs]);Nr.setInput(Be,Li.yy),Li.yy.lexer=Nr,Li.yy.parser=this,typeof Nr.yylloc>"u"&&(Nr.yylloc={});var fo=Nr.yylloc;mt.push(fo);var pg=Nr.options&&Nr.options.ranges;typeof Li.yy.parseError=="function"?this.parseError=Li.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var By=function(){var ho;return ho=Nr.lex()||Fy,typeof ho!="number"&&(ho=Ge.symbols_[ho]||ho),ho},Dt,Jt,It,Yr,Zr={},Uy,aa,OA,Hy;;){if(Jt=Ze[Ze.length-1],this.defaultActions[Jt]?It=this.defaultActions[Jt]:((Dt===null||typeof Dt>"u")&&(Dt=By()),It=ne[Jt]&&ne[Jt][Dt]),typeof It>"u"||!It.length||!It[0]){var yg="";Hy=[];for(Uy in ne[Jt])this.terminals_[Uy]&&Uy>My&&Hy.push("'"+this.terminals_[Uy]+"'");Nr.showPosition?yg="Parse error on line "+(se+1)+`: -`+Nr.showPosition()+` -Expecting `+Hy.join(", ")+", got '"+(this.terminals_[Dt]||Dt)+"'":yg="Parse error on line "+(se+1)+": Unexpected "+(Dt==Fy?"end of input":"'"+(this.terminals_[Dt]||Dt)+"'"),this.parseError(yg,{text:Nr.match,token:this.terminals_[Dt]||Dt,line:Nr.yylineno,loc:fo,expected:Hy})}if(It[0]instanceof Array&&It.length>1)throw new Error("Parse Error: multiple actions possible at state: "+Jt+", token: "+Dt);switch(It[0]){case 1:Ze.push(Dt),pt.push(Nr.yytext),mt.push(Nr.yylloc),Ze.push(It[1]),Dt=null,Ea=Nr.yyleng,Vn=Nr.yytext,se=Nr.yylineno,fo=Nr.yylloc;break;case 2:if(aa=this.productions_[It[1]][1],Zr.$=pt[pt.length-aa],Zr._$={first_line:mt[mt.length-(aa||1)].first_line,last_line:mt[mt.length-1].last_line,first_column:mt[mt.length-(aa||1)].first_column,last_column:mt[mt.length-1].last_column},pg&&(Zr._$.range=[mt[mt.length-(aa||1)].range[0],mt[mt.length-1].range[1]]),Yr=this.performAction.apply(Zr,[Vn,Ea,se,Li.yy,It[1],pt,mt].concat(qy)),typeof Yr<"u")return Yr;aa&&(Ze=Ze.slice(0,-1*aa*2),pt=pt.slice(0,-1*aa),mt=mt.slice(0,-1*aa)),Ze.push(this.productions_[It[1]][0]),pt.push(Zr.$),mt.push(Zr._$),OA=ne[Ze[Ze.length-2]][Ze[Ze.length-1]],Ze.push(OA);break;case 3:return!0}}return!0}},Cy=jF().Wildcard,jy="http://www.w3.org/1999/02/22-rdf-syntax-ns#",OB=jy+"type",RB=jy+"first",xB=jy+"rest",yA=jy+"nil",Ly="http://www.w3.org/2001/XMLSchema#",bA=Ly+"integer",gA=Ly+"decimal",mA=Ly+"double",IB=Ly+"boolean",cs="",_A="",vA="";function mn(He){return He.toLowerCase()}function ls(He,Be){return He.push(Be),He}function so(He,Be){return He.push.apply(He,Be),He}function Dr(He){He||(He={});for(var Be=1,Ge=arguments.length,Ze;Be>10),56320+(ne&1023))}else{var Vn=NB[mt];if(!Vn)throw new Error;return Vn}})}catch{return""}if(CB.exec(He))throw new Error("Invalid unicode codepoint of surrogate pair without corresponding codepoint in "+He);return He}function jB(He){var Be=du(),Ge=Be,Ze=[],pt,mt=[];He.forEach(function(Ea){Ze.push(Ea.entity),so(mt,Ea.triples)});for(var ne=0,Vn=0,se=Ze.length,pt=Array(se*2);ne0&&Ze instanceof Array?lg(Ze,Be-1,Ge):Ge.push(Ze);return Ge}function dg(He){return He.termType==="Variable"}function TA(He){if(He.triples){const Be=[];for(const Ge of He.triples)dg(Ge.subject)&&Be.push(Ge.subject.value),dg(Ge.predicate)&&Be.push(Ge.predicate.value),dg(Ge.object)&&Be.push(Ge.object.value);return Be}else if(He.patterns){const Be=[];for(const Ge of He.patterns)Be.push(...TA(Ge));return Be}return[]}function FB(He){const Be=He.slice().sort(),Ge=[];for(let Ze=0;Ze{const Ze=ia(Ge.subject,Ge.predicate,Ge.object);Be.push(Ze),Ge.annotations&&AA(sg(Ge.subject,Ge.predicate,Ge.object),Ge.annotations,Be)}),Be}return He}function EA(He){for(const Be of He){if(Be.type==="graph"&&Be.name.termType==="Variable")throw new Error("Detected illegal variable in GRAPH");if(Be.type==="bgp"||Be.type==="graph"){for(const Ge of Be.triples)if(Ge.subject.termType==="Variable"||Ge.predicate.termType==="Variable"||Ge.object.termType==="Variable")throw new Error("Detected illegal variable in BGP")}}return He}function hg(He){for(const Be of He)if(Be.type==="bgp"){for(const Ge of Be.triples)if(Ge.subject.termType==="BlankNode"||Ge.predicate.termType==="BlankNode"||Ge.object.termType==="BlankNode")throw new Error("Detected illegal blank node in BGP")}return He}var qB=function(){var He={EOF:1,parseError:function(Ge,Ze){if(this.yy.parser)this.yy.parser.parseError(Ge,Ze);else throw new Error(Ge)},setInput:function(Be,Ge){return this.yy=Ge||this.yy||{},this._input=Be,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var Be=this._input[0];this.yytext+=Be,this.yyleng++,this.offset++,this.match+=Be,this.matched+=Be;var Ge=Be.match(/(?:\r\n?|\n).*/g);return Ge?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),Be},unput:function(Be){var Ge=Be.length,Ze=Be.split(/(?:\r\n?|\n)/g);this._input=Be+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-Ge),this.offset-=Ge;var pt=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),Ze.length-1&&(this.yylineno-=Ze.length-1);var mt=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:Ze?(Ze.length===pt.length?this.yylloc.first_column:0)+pt[pt.length-Ze.length].length-Ze[0].length:this.yylloc.first_column-Ge},this.options.ranges&&(this.yylloc.range=[mt[0],mt[0]+this.yyleng-Ge]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). -`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},less:function(Be){this.unput(this.match.slice(Be))},pastInput:function(){var Be=this.matched.substr(0,this.matched.length-this.match.length);return(Be.length>20?"...":"")+Be.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var Be=this.match;return Be.length<20&&(Be+=this._input.substr(0,20-Be.length)),(Be.substr(0,20)+(Be.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var Be=this.pastInput(),Ge=new Array(Be.length+1).join("-");return Be+this.upcomingInput()+` -`+Ge+"^"},test_match:function(Be,Ge){var Ze,pt,mt;if(this.options.backtrack_lexer&&(mt={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(mt.yylloc.range=this.yylloc.range.slice(0))),pt=Be[0].match(/(?:\r\n?|\n).*/g),pt&&(this.yylineno+=pt.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:pt?pt[pt.length-1].length-pt[pt.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+Be[0].length},this.yytext+=Be[0],this.match+=Be[0],this.matches=Be,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(Be[0].length),this.matched+=Be[0],Ze=this.performAction.call(this,this.yy,this,Ge,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),Ze)return Ze;if(this._backtrack){for(var ne in mt)this[ne]=mt[ne];return!1}return!1},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var Be,Ge,Ze,pt;this._more||(this.yytext="",this.match="");for(var mt=this._currentRules(),ne=0;neGe[0].length)){if(Ge=Ze,pt=ne,this.options.backtrack_lexer){if(Be=this.test_match(Ze,mt[ne]),Be!==!1)return Be;if(this._backtrack){Ge=!1;continue}else return!1}else if(!this.options.flex)break}return Ge?(Be=this.test_match(Ge,mt[pt]),Be!==!1?Be:!1):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text. -`+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var Ge=this.next();return Ge||this.lex()},begin:function(Ge){this.conditionStack.push(Ge)},popState:function(){var Ge=this.conditionStack.length-1;return Ge>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(Ge){return Ge=this.conditionStack.length-1-Math.abs(Ge||0),Ge>=0?this.conditionStack[Ge]:"INITIAL"},pushState:function(Ge){this.begin(Ge)},stateStackSize:function(){return this.conditionStack.length},options:{flex:!0,"case-insensitive":!0},performAction:function(Ge,Ze,pt,mt){switch(pt){case 0:break;case 1:return 12;case 2:return 15;case 3:return 41;case 4:return 325;case 5:return 326;case 6:return 45;case 7:return 47;case 8:return 48;case 9:return 39;case 10:return 24;case 11:return 28;case 12:return 29;case 13:return 31;case 14:return 32;case 15:return 36;case 16:return 53;case 17:return 327;case 18:return 63;case 19:return 64;case 20:return 70;case 21:return 73;case 22:return 76;case 23:return 78;case 24:return 81;case 25:return 83;case 26:return 85;case 27:return 193;case 28:return 100;case 29:return 328;case 30:return 121;case 31:return 329;case 32:return 330;case 33:return 110;case 34:return 331;case 35:return 109;case 36:return 332;case 37:return 333;case 38:return 113;case 39:return 115;case 40:return 116;case 41:return 131;case 42:return 123;case 43:return 126;case 44:return 128;case 45:return 132;case 46:return 112;case 47:return 334;case 48:return 335;case 49:return 159;case 50:return 161;case 51:return 164;case 52:return 174;case 53:return 160;case 54:return 336;case 55:return 163;case 56:return 312;case 57:return 314;case 58:return 317;case 59:return 318;case 60:return 272;case 61:return 197;case 62:return 337;case 63:return 338;case 64:return 229;case 65:return 340;case 66:return 263;case 67:return 224;case 68:return 231;case 69:return 232;case 70:return 242;case 71:return 246;case 72:return 290;case 73:return 341;case 74:return 342;case 75:return 343;case 76:return 344;case 77:return 345;case 78:return 250;case 79:return 346;case 80:return 265;case 81:return 276;case 82:return 277;case 83:return 268;case 84:return 269;case 85:return 270;case 86:return 271;case 87:return 347;case 88:return 348;case 89:return 273;case 90:return 274;case 91:return 350;case 92:return 349;case 93:return 351;case 94:return 279;case 95:return 280;case 96:return 283;case 97:return 285;case 98:return 289;case 99:return 293;case 100:return 296;case 101:return 13;case 102:return 16;case 103:return 308;case 104:return 309;case 105:return 87;case 106:return 292;case 107:return 82;case 108:return 294;case 109:return 295;case 110:return 297;case 111:return 298;case 112:return 299;case 113:return 300;case 114:return 301;case 115:return 302;case 116:return"EXPONENT";case 117:return 303;case 118:return 304;case 119:return 305;case 120:return 306;case 121:return 89;case 122:return 310;case 123:return 6;case 124:return"INVALID";case 125:console.log(Ze.yytext);break}},rules:[/^(?:\s+|(#[^\n\r]*))/i,/^(?:BASE)/i,/^(?:PREFIX)/i,/^(?:SELECT)/i,/^(?:DISTINCT)/i,/^(?:REDUCED)/i,/^(?:\()/i,/^(?:AS)/i,/^(?:\))/i,/^(?:\*)/i,/^(?:CONSTRUCT)/i,/^(?:WHERE)/i,/^(?:\{)/i,/^(?:\})/i,/^(?:DESCRIBE)/i,/^(?:ASK)/i,/^(?:FROM)/i,/^(?:NAMED)/i,/^(?:GROUP)/i,/^(?:BY)/i,/^(?:HAVING)/i,/^(?:ORDER)/i,/^(?:ASC)/i,/^(?:DESC)/i,/^(?:LIMIT)/i,/^(?:OFFSET)/i,/^(?:VALUES)/i,/^(?:;)/i,/^(?:LOAD)/i,/^(?:SILENT)/i,/^(?:INTO)/i,/^(?:CLEAR)/i,/^(?:DROP)/i,/^(?:CREATE)/i,/^(?:ADD)/i,/^(?:TO)/i,/^(?:MOVE)/i,/^(?:COPY)/i,/^(?:INSERT((\s+|(#[^\n\r]*)\n\r?)+)DATA)/i,/^(?:DELETE((\s+|(#[^\n\r]*)\n\r?)+)DATA)/i,/^(?:DELETE((\s+|(#[^\n\r]*)\n\r?)+)WHERE)/i,/^(?:WITH)/i,/^(?:DELETE)/i,/^(?:INSERT)/i,/^(?:USING)/i,/^(?:DEFAULT)/i,/^(?:GRAPH)/i,/^(?:ALL)/i,/^(?:\.)/i,/^(?:OPTIONAL)/i,/^(?:SERVICE)/i,/^(?:BIND)/i,/^(?:UNDEF)/i,/^(?:MINUS)/i,/^(?:UNION)/i,/^(?:FILTER)/i,/^(?:<<)/i,/^(?:>>)/i,/^(?:\{\|)/i,/^(?:\|\})/i,/^(?:,)/i,/^(?:a)/i,/^(?:\|)/i,/^(?:\/)/i,/^(?:\^)/i,/^(?:\?)/i,/^(?:\+)/i,/^(?:!)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:\|\|)/i,/^(?:&&)/i,/^(?:=)/i,/^(?:!=)/i,/^(?:<)/i,/^(?:>)/i,/^(?:<=)/i,/^(?:>=)/i,/^(?:IN)/i,/^(?:NOT)/i,/^(?:-)/i,/^(?:BOUND)/i,/^(?:BNODE)/i,/^(?:(RAND|NOW|UUID|STRUUID))/i,/^(?:(LANG|DATATYPE|IRI|URI|ABS|CEIL|FLOOR|ROUND|STRLEN|STR|UCASE|LCASE|ENCODE_FOR_URI|YEAR|MONTH|DAY|HOURS|MINUTES|SECONDS|TIMEZONE|TZ|MD5|SHA1|SHA256|SHA384|SHA512|isIRI|isURI|isBLANK|isLITERAL|isNUMERIC))/i,/^(?:(SUBJECT|PREDICATE|OBJECT|isTRIPLE))/i,/^(?:(LANGMATCHES|CONTAINS|STRSTARTS|STRENDS|STRBEFORE|STRAFTER|STRLANG|STRDT|sameTerm))/i,/^(?:CONCAT)/i,/^(?:COALESCE)/i,/^(?:IF)/i,/^(?:TRIPLE)/i,/^(?:REGEX)/i,/^(?:SUBSTR)/i,/^(?:REPLACE)/i,/^(?:EXISTS)/i,/^(?:COUNT)/i,/^(?:SUM|MIN|MAX|AVG|SAMPLE)/i,/^(?:GROUP_CONCAT)/i,/^(?:SEPARATOR)/i,/^(?:\^\^)/i,/^(?:true|false)/i,/^(?:(<(?:[^<>\"\{\}\|\^`\\\u0000-\u0020])*>))/i,/^(?:((([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])(?:(?:(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040])|\.)*(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040]))?)?:))/i,/^(?:(((([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])(?:(?:(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040])|\.)*(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040]))?)?:)((?:((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|:|[0-9]|((%([0-9A-Fa-f])([0-9A-Fa-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%))))(?:(?:(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040])|\.|:|((%([0-9A-Fa-f])([0-9A-Fa-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%))))*(?:(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040])|:|((%([0-9A-Fa-f])([0-9A-Fa-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%)))))?)))/i,/^(?:(_:(?:((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|[0-9])(?:(?:(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040])|\.)*(((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040]))?))/i,/^(?:([\?\$]((?:((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|[0-9])(?:((?:([A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|[0-9]|\u00B7|[\u0300-\u036F\u203F-\u2040])*)))/i,/^(?:(@[a-zA-Z]+(?:-[a-zA-Z0-9]+)*))/i,/^(?:([0-9]+))/i,/^(?:([0-9]*\.[0-9]+))/i,/^(?:([0-9]+\.[0-9]*([eE][+-]?[0-9]+)|\.([0-9])+([eE][+-]?[0-9]+)|([0-9])+([eE][+-]?[0-9]+)))/i,/^(?:(\+([0-9]+)))/i,/^(?:(\+([0-9]*\.[0-9]+)))/i,/^(?:(\+([0-9]+\.[0-9]*([eE][+-]?[0-9]+)|\.([0-9])+([eE][+-]?[0-9]+)|([0-9])+([eE][+-]?[0-9]+))))/i,/^(?:(-([0-9]+)))/i,/^(?:(-([0-9]*\.[0-9]+)))/i,/^(?:(-([0-9]+\.[0-9]*([eE][+-]?[0-9]+)|\.([0-9])+([eE][+-]?[0-9]+)|([0-9])+([eE][+-]?[0-9]+))))/i,/^(?:([eE][+-]?[0-9]+))/i,/^(?:('(?:(?:[^\u0027\u005C\u000A\u000D])|(\\[tbnrf\\\"']|\\u([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])|\\U([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])))*'))/i,/^(?:("(?:(?:[^\u0022\u005C\u000A\u000D])|(\\[tbnrf\\\"']|\\u([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])|\\U([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])))*"))/i,/^(?:('''(?:(?:'|'')?(?:[^'\\]|(\\[tbnrf\\\"']|\\u([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])|\\U([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f]))))*'''))/i,/^(?:("""(?:(?:"|"")?(?:[^\"\\]|(\\[tbnrf\\\"']|\\u([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])|\\U([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f])([0-9A-Fa-f]))))*"""))/i,/^(?:(\((\u0020|\u0009|\u000D|\u000A)*\)))/i,/^(?:(\[(\u0020|\u0009|\u000D|\u000A)*\]))/i,/^(?:$)/i,/^(?:.)/i,/^(?:.)/i],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125],inclusive:!0}}};return He}();rg.lexer=qB;function Ct(){this.yy={}}return Ct.prototype=rg,rg.Parser=Ct,new Ct}();return rm=t,rm}var nm,pO;function xV(){if(pO)return nm;pO=1;var t="http://www.w3.org/2001/XMLSchema#integer",e="http://www.w3.org/2001/XMLSchema#string";function u(h){this._options=h=h||{};var f=h.prefixes||{};this._prefixByIri={};var p=[];for(var y in f){var b=f[y];o(b)&&(this._prefixByIri[b]=y,p.push(b))}var m=p.join("|").replace(/[\]\/\(\)\*\+\?\.\\\$]/g,"\\$&");this._prefixRegex=new RegExp("^("+m+")([a-zA-Z][\\-_a-zA-Z0-9]*)$"),this._usedPrefixes={},this._sparqlStar=h.sparqlStar,this._indent=o(h.indent)?h.indent:" ",this._newline=o(h.newline)?h.newline:` -`,this._explicitDatatype=!!h.explicitDatatype}u.prototype.toQuery=function(h){var f="";return h.queryType&&(f+=h.queryType.toUpperCase()+" "),h.reduced&&(f+="REDUCED "),h.distinct&&(f+="DISTINCT "),h.variables?f+=d(h.variables,void 0,function(p){return l(p)?this.toEntity(p):"("+this.toExpression(p.expression)+" AS "+a(p.variable)+")"},this)+" ":h.template&&(f+=this.group(h.template,!0)+this._newline),h.from&&(f+=this.graphs("FROM ",h.from.default)+this.graphs("FROM NAMED ",h.from.named)),h.where&&(f+="WHERE "+this.group(h.where,!0)+this._newline),h.updates&&(f+=d(h.updates,";"+this._newline,this.toUpdate,this)),h.group&&(f+="GROUP BY "+d(h.group,void 0,function(p){var y=l(p.expression)?this.toEntity(p.expression):"("+this.toExpression(p.expression)+")";return p.variable?"("+y+" AS "+a(p.variable)+")":y},this)+this._newline),h.having&&(f+="HAVING ("+d(h.having,void 0,this.toExpression,this)+")"+this._newline),h.order&&(f+="ORDER BY "+d(h.order,void 0,function(p){var y="("+this.toExpression(p.expression)+")";return p.descending?"DESC "+y:y},this)+this._newline),h.offset&&(f+="OFFSET "+h.offset+this._newline),h.limit&&(f+="LIMIT "+h.limit+this._newline),h.values&&(f+=this.values(h)),f=this.baseAndPrefixes(h)+f,f.trim()},u.prototype.baseAndPrefixes=function(h){var f=h.base?"BASE <"+h.base+">"+this._newline:"",p="";for(var y in h.prefixes)(this._options.allPrefixes||this._usedPrefixes[y])&&(p+="PREFIX "+y+": <"+h.prefixes[y]+">"+this._newline);return f+p},u.prototype.toPattern=function(h){var f=h.type||h instanceof Array&&"array"||(h.subject&&h.predicate&&h.object?"triple":"");if(!(f in this))throw new Error("Unknown entry type: "+f);return this[f](h)},u.prototype.triple=function(h){return this.toEntity(h.subject)+" "+this.toEntity(h.predicate)+" "+this.toEntity(h.object)+"."},u.prototype.array=function(h){return d(h,this._newline,this.toPattern,this)},u.prototype.bgp=function(h){return this.encodeTriples(h.triples)},u.prototype.encodeTriples=function(h){if(!h.length)return"";for(var f=[],p=void 0,y=void 0,b=0;b":case">=":case"<=":case"&&":case"||":case"=":case"!=":case"+":case"-":case"*":case"/":return(l(p[0])?this.toEntity(p[0]):"("+this.toExpression(p[0])+")")+" "+f+" "+(l(p[1])?this.toEntity(p[1]):"("+this.toExpression(p[1])+")");case"!":return"!("+this.toExpression(p[0])+")";case"uplus":return"+("+this.toExpression(p[0])+")";case"uminus":return"-("+this.toExpression(p[0])+")";case"notin":f="NOT IN";case"in":return this.toExpression(p[0])+" "+f+"("+(o(p[1])?p[1]:d(p[1],", ",this.toExpression,this))+")";case"notexists":f="NOT EXISTS";case"exists":return f+" "+this.group(p[0],!0);default:return f+"("+d(p,", ",this.toExpression,this)+")"}default:throw new Error("Unknown expression type: "+h.type)}},u.prototype.toEntity=function(h){if(l(h))switch(h.termType){case"Wildcard":return"*";case"Variable":return a(h);case"BlankNode":return"_:"+h.value;case"Literal":var f=h.value||"",p=h.language||"",y=h.datatype;if(h='"'+f.replace(s,n)+'"',p)h+="@"+p;else if(y){if(!this._explicitDatatype)switch(y.value){case e:return h;case t:if(/^\d+$/.test(f))return f+" "}h+="^^"+this.encodeIRI(y.value)}return h;case"Quad":if(!this._sparqlStar)throw new Error("SPARQL* support is not enabled");return h.graph&&h.graph.termType!=="DefaultGraph"?"<< GRAPH "+this.toEntity(h.graph)+" { "+this.toEntity(h.subject)+" "+this.toEntity(h.predicate)+" "+this.toEntity(h.object)+" } >>":"<< "+this.toEntity(h.subject)+" "+this.toEntity(h.predicate)+" "+this.toEntity(h.object)+" >>";default:return this.encodeIRI(h.value)}else{var b=h.items.map(this.toEntity,this),m=h.pathType;switch(m){case"^":case"!":return m+b[0];case"*":case"+":case"?":return"("+b[0]+m+")";default:return"("+b.join(m)+")"}}};var s=/["\\\t\n\r\b\f]/g,n=function(h){return r[h]},r={"\\":"\\\\",'"':'\\"'," ":"\\t","\n":"\\n","\r":"\\r","\b":"\\b","\f":"\\f"};u.prototype.encodeIRI=function(h){var f=this._prefixRegex.exec(h);if(f){var p=this._prefixByIri[f[1]];return this._usedPrefixes[p]=!0,p+":"+f[2]}return"<"+h+">"},u.prototype.toUpdate=function(h){switch(h.type||h.updateType){case"load":return"LOAD"+(h.source?" "+this.toEntity(h.source):"")+(h.destination?" INTO GRAPH "+this.toEntity(h.destination):"");case"insert":return"INSERT DATA "+this.group(h.insert,!0);case"delete":return"DELETE DATA "+this.group(h.delete,!0);case"deletewhere":return"DELETE WHERE "+this.group(h.delete,!0);case"insertdelete":return(h.graph?"WITH "+this.toEntity(h.graph)+this._newline:"")+(h.delete.length?"DELETE "+this.group(h.delete,!0)+this._newline:"")+(h.insert.length?"INSERT "+this.group(h.insert,!0)+this._newline:"")+(h.using?this.graphs("USING ",h.using.default):"")+(h.using?this.graphs("USING NAMED ",h.using.named):"")+"WHERE "+this.group(h.where,!0);case"add":case"copy":case"move":return h.type.toUpperCase()+" "+(h.silent?"SILENT ":"")+(h.source.default?"DEFAULT":this.toEntity(h.source.name))+" TO "+this.toEntity(h.destination.name);case"create":case"clear":case"drop":return h.type.toUpperCase()+(h.silent?" SILENT ":" ")+(h.graph.default?"DEFAULT":h.graph.named?"NAMED":h.graph.all?"ALL":"GRAPH "+this.toEntity(h.graph.name));default:throw new Error("Unknown update query type: "+h.type)}},u.prototype.indent=function(h){return h.replace(/^/gm,this._indent)};function a(h){return"?"+h.value}function o(h){return typeof h=="string"}function l(h){return typeof h.termType=="string"}function c(h,f){if(!h||!l(h)||!f||!l(f)||h.termType!==f.termType)return!1;switch(h.termType){case"Literal":return h.value===f.value&&h.language===f.language&&c(h.datatype,f.datatype);case"Quad":return c(h.subject,f.subject)&&c(h.predicate,f.predicate)&&c(h.object,f.object)&&c(h.graph,f.graph);default:return h.value===f.value}}function d(h,f,p,y){return h.map(p,y).join(o(f)?f:" ")}return nm=function(f={}){return{stringify:function(p){var y=Object.create(f);return y.prefixes=p.prefixes,new u(y).toQuery(p)},createGenerator:function(){return new u(f)}}},nm}var im,yO;function my(){if(yO)return im;yO=1;var t=RV().Parser,e=xV(),u=jF().Wildcard,{DataFactory:s}=Et();return im={Parser:function({prefixes:n,baseIRI:r,factory:a,sparqlStar:o,skipValidation:l,skipUngroupedVariableCheck:c,pathOnly:d}={}){var h={};for(var f in n||{})h[f]=n[f];var p=new t;return p.parse=function(){return t.base=r||"",t.prefixes=Object.create(h),t.factory=a||new s,t.sparqlStar=!!o,t.pathOnly=!!d,t.skipValidation=!!l||!!c,t.prototype.parse.apply(p,arguments)},p._resetBlanks=t._resetBlanks,p},Generator:e,Wildcard:u},im}var bO;function jb(){if(bO)return e1;bO=1;var t=I&&I.__createBinding||(Object.create?function(l,c,d,h){h===void 0&&(h=d);var f=Object.getOwnPropertyDescriptor(c,d);(!f||("get"in f?!c.__esModule:f.writable||f.configurable))&&(f={enumerable:!0,get:function(){return c[d]}}),Object.defineProperty(l,h,f)}:function(l,c,d,h){h===void 0&&(h=d),l[h]=c[d]}),e=I&&I.__setModuleDefault||(Object.create?function(l,c){Object.defineProperty(l,"default",{enumerable:!0,value:c})}:function(l,c){l.default=c}),u=I&&I.__importStar||function(l){if(l&&l.__esModule)return l;var c={};if(l!=null)for(var d in l)d!=="default"&&Object.prototype.hasOwnProperty.call(l,d)&&t(c,l,d);return e(c,l),c};Object.defineProperty(e1,"__esModule",{value:!0});const s=u(gy()),n=Et(),r=er(),a=my();class o{constructor(c){this.dataFactory=c||new n.DataFactory,this.stringType=this.createTerm("http://www.w3.org/2001/XMLSchema#string")}createAlt(c,d=!0){return this.flattenMulti({type:s.types.ALT,input:c},d)}createAsk(c){return{type:s.types.ASK,input:c}}createBoundAggregate(c,d,h,f,p){const y=this.createAggregateExpression(d,h,f,p);return y.variable=c,y}createBgp(c){return{type:s.types.BGP,patterns:c}}createConstruct(c,d){return{type:s.types.CONSTRUCT,input:c,template:d}}createDescribe(c,d){return{type:s.types.DESCRIBE,input:c,terms:d}}createDistinct(c){return{type:s.types.DISTINCT,input:c}}createExtend(c,d,h){return{type:s.types.EXTEND,input:c,variable:d,expression:h}}createFrom(c,d,h){return{type:s.types.FROM,input:c,default:d,named:h}}createFilter(c,d){return{type:s.types.FILTER,input:c,expression:d}}createGraph(c,d){return{type:s.types.GRAPH,input:c,name:d}}createGroup(c,d,h){return{type:s.types.GROUP,input:c,variables:d,aggregates:h}}createInv(c){return{type:s.types.INV,path:c}}createJoin(c,d=!0){return this.flattenMulti({type:s.types.JOIN,input:c},d)}createLeftJoin(c,d,h){return h?{type:s.types.LEFT_JOIN,input:[c,d],expression:h}:{type:s.types.LEFT_JOIN,input:[c,d]}}createLink(c){return{type:s.types.LINK,iri:c}}createMinus(c,d){return{type:s.types.MINUS,input:[c,d]}}createNop(){return{type:s.types.NOP}}createNps(c){return{type:s.types.NPS,iris:c}}createOneOrMorePath(c){return{type:s.types.ONE_OR_MORE_PATH,path:c}}createOrderBy(c,d){return{type:s.types.ORDER_BY,input:c,expressions:d}}createPath(c,d,h,f){return f?{type:s.types.PATH,subject:c,predicate:d,object:h,graph:f}:{type:s.types.PATH,subject:c,predicate:d,object:h,graph:this.dataFactory.defaultGraph()}}createPattern(c,d,h,f){const p=this.dataFactory.quad(c,d,h,f);return p.type=s.types.PATTERN,p}createProject(c,d){return{type:s.types.PROJECT,input:c,variables:d}}createReduced(c){return{type:s.types.REDUCED,input:c}}createSeq(c,d=!0){return this.flattenMulti({type:s.types.SEQ,input:c},d)}createService(c,d,h){return{type:s.types.SERVICE,input:c,name:d,silent:!!h}}createSlice(c,d,h){return d=d||0,h!==void 0?{type:s.types.SLICE,input:c,start:d,length:h}:{type:s.types.SLICE,input:c,start:d}}createUnion(c,d=!0){return this.flattenMulti({type:s.types.UNION,input:c},d)}createValues(c,d){return{type:s.types.VALUES,variables:c,bindings:d}}createZeroOrMorePath(c){return{type:s.types.ZERO_OR_MORE_PATH,path:c}}createZeroOrOnePath(c){return{type:s.types.ZERO_OR_ONE_PATH,path:c}}createAggregateExpression(c,d,h,f){return f?{type:s.types.EXPRESSION,expressionType:s.expressionTypes.AGGREGATE,aggregator:c,expression:d,separator:f,distinct:h}:{type:s.types.EXPRESSION,expressionType:s.expressionTypes.AGGREGATE,aggregator:c,expression:d,distinct:h}}createExistenceExpression(c,d){return{type:s.types.EXPRESSION,expressionType:s.expressionTypes.EXISTENCE,not:c,input:d}}createNamedExpression(c,d){return{type:s.types.EXPRESSION,expressionType:s.expressionTypes.NAMED,name:c,args:d}}createOperatorExpression(c,d){return{type:s.types.EXPRESSION,expressionType:s.expressionTypes.OPERATOR,operator:c,args:d}}createTermExpression(c){return{type:s.types.EXPRESSION,expressionType:s.expressionTypes.TERM,term:c}}createWildcardExpression(){return{type:s.types.EXPRESSION,expressionType:s.expressionTypes.WILDCARD,wildcard:new a.Wildcard}}createTerm(c){return c[0]==="$"&&(c=c.replace("$","?")),(0,r.stringToTerm)(c,this.dataFactory)}createCompositeUpdate(c){return{type:s.types.COMPOSITE_UPDATE,updates:c}}createDeleteInsert(c,d,h){const f={type:s.types.DELETE_INSERT};return c&&(f.delete=c),d&&(f.insert=d),h&&(f.where=h),f}createLoad(c,d,h){const f={type:s.types.LOAD,source:c};return d&&(f.destination=d),this.addSilent(f,!!h)}createClear(c,d){return this.addSilent({type:s.types.CLEAR,source:c},!!d)}createCreate(c,d){return this.addSilent({type:s.types.CREATE,source:c},!!d)}createDrop(c,d){return this.addSilent({type:s.types.DROP,source:c},!!d)}createAdd(c,d,h){return this.addSilent({type:s.types.ADD,source:c,destination:d},!!h)}createMove(c,d,h){return this.addSilent({type:s.types.MOVE,source:c,destination:d},!!h)}createCopy(c,d,h){return this.addSilent({type:s.types.COPY,source:c,destination:d},!!h)}addSilent(c,d){return d&&(c.silent=d),c}flattenMulti(c,d){if(!d)return c;const h=c.type,f=c.input;let p=[];for(const y of f)y.type===h?p.push(...y.input):p.push(y);return c.input=p,c}}return e1.default=o,e1}var t1={},gO;function RT(){if(gO)return t1;gO=1;var t=I&&I.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(t1,"__esModule",{value:!0});const e=gy(),u=t(jb()),s=un();class n{static flatten(a){return Array.prototype.concat(...a).filter(o=>o)}static objectify(a){if(a.termType){if(a.termType==="Quad")return{type:"pattern",termType:"Quad",subject:n.objectify(a.subject),predicate:n.objectify(a.predicate),object:n.objectify(a.object),graph:n.objectify(a.graph)};{let o={termType:a.termType,value:a.value};return a.language&&(o.language=a.language),a.datatype&&(o.datatype=n.objectify(a.datatype)),o}}if(Array.isArray(a))return a.map(o=>n.objectify(o));if(a===Object(a)){let o={};for(let l of Object.keys(a))o[l]=n.objectify(a[l]);return o}return a}static inScopeVariables(a){const o=[];function l(d){o.find(h=>d.value===h.value)||o.push(d)}function c(d){d.subject.termType==="Variable"&&l(d.subject),d.predicate.termType==="Variable"&&l(d.predicate),d.object.termType==="Variable"&&l(d.object),d.graph.termType==="Variable"&&l(d.graph),d.subject.termType==="Quad"&&c(d.subject),d.predicate.termType==="Quad"&&c(d.predicate),d.object.termType==="Quad"&&c(d.object),d.graph.termType==="Quad"&&c(d.graph)}return n.recurseOperation(a,{[e.types.EXPRESSION]:d=>(d.expressionType===e.expressionTypes.AGGREGATE&&d.variable&&l(d.variable),!0),[e.types.EXTEND]:d=>(l(d.variable),!0),[e.types.GRAPH]:d=>(d.name.termType==="Variable"&&l(d.name),!0),[e.types.GROUP]:d=>(d.variables.forEach(l),!0),[e.types.PATH]:d=>(d.subject.termType==="Variable"&&l(d.subject),d.object.termType==="Variable"&&l(d.object),d.graph.termType==="Variable"&&l(d.graph),d.subject.termType==="Quad"&&c(d.subject),d.object.termType==="Quad"&&c(d.object),d.graph.termType==="Quad"&&c(d.graph),!0),[e.types.PATTERN]:d=>(c(d),!0),[e.types.PROJECT]:d=>(d.variables.forEach(l),!1),[e.types.SERVICE]:d=>(d.name.termType==="Variable"&&l(d.name),!0),[e.types.VALUES]:d=>(d.variables.forEach(l),!0)}),o}static recurseOperation(a,o){let l=a,c=!0;const d=o[a.type];if(d&&(c=d(a)),!c)return;let h=f=>n.recurseOperation(f,o);switch(l.type){case e.types.ALT:l.input.map(h);break;case e.types.ASK:h(l.input);break;case e.types.BGP:l.patterns.forEach(h);break;case e.types.CONSTRUCT:h(l.input),l.template.map(h);break;case e.types.DESCRIBE:h(l.input);break;case e.types.DISTINCT:h(l.input);break;case e.types.EXPRESSION:l.expressionType===e.expressionTypes.EXISTENCE&&h(l.input);break;case e.types.EXTEND:h(l.input),h(l.expression);break;case e.types.FILTER:h(l.input),h(l.expression);break;case e.types.FROM:h(l.input);break;case e.types.GRAPH:h(l.input);break;case e.types.GROUP:h(l.input),l.aggregates.forEach(h);break;case e.types.INV:h(l.path);break;case e.types.JOIN:l.input.map(h);break;case e.types.LEFT_JOIN:l.input.map(h),l.expression&&h(l.expression);break;case e.types.LINK:break;case e.types.MINUS:l.input.map(h);break;case e.types.NOP:break;case e.types.NPS:break;case e.types.ONE_OR_MORE_PATH:h(l.path);break;case e.types.ORDER_BY:h(l.input),l.expressions.forEach(h);break;case e.types.PATH:h(l.predicate);break;case e.types.PATTERN:break;case e.types.PROJECT:h(l.input);break;case e.types.REDUCED:h(l.input);break;case e.types.SEQ:l.input.map(h);break;case e.types.SERVICE:h(l.input);break;case e.types.SLICE:h(l.input);break;case e.types.UNION:l.input.map(h);break;case e.types.VALUES:break;case e.types.ZERO_OR_MORE_PATH:h(l.path);break;case e.types.ZERO_OR_ONE_PATH:h(l.path);break;case e.types.COMPOSITE_UPDATE:l.updates.forEach(f=>h(f));break;case e.types.DELETE_INSERT:l.delete&&l.delete.forEach(f=>h(f)),l.insert&&l.insert.forEach(f=>h(f)),l.where&&h(l.where);break;case e.types.LOAD:break;case e.types.CLEAR:break;case e.types.CREATE:break;case e.types.DROP:break;case e.types.ADD:break;case e.types.MOVE:break;case e.types.COPY:break;default:throw new Error(`Unknown Operation type ${l.type}`)}}static mapOperation(a,o,l){let c=a,d=!0,h=!0;l=l||new u.default;const f=o[a.type];if(f){const b=f(a,l);c=b.result,d=b.recurse,h=b.copyMetadata!==!1}let p;if(h&&(c.metadata||a.metadata)&&(p={...c.metadata,...a.metadata}),!d)return p&&(c.metadata=p),c;let y=b=>n.mapOperation(b,o,l);switch(c.type){case e.types.ALT:c=l.createAlt(c.input.map(y));break;case e.types.ASK:c=l.createAsk(y(c.input));break;case e.types.BGP:c=l.createBgp(c.patterns.map(y));break;case e.types.CONSTRUCT:c=l.createConstruct(y(c.input),c.template.map(y));break;case e.types.DESCRIBE:c=l.createDescribe(y(c.input),c.terms);break;case e.types.DISTINCT:c=l.createDistinct(y(c.input));break;case e.types.EXPRESSION:c=n.mapExpression(c,o,l);break;case e.types.EXTEND:c=l.createExtend(y(c.input),c.variable,y(c.expression));break;case e.types.FILTER:c=l.createFilter(y(c.input),y(c.expression));break;case e.types.FROM:c=l.createFrom(y(c.input),[...c.default],[...c.named]);break;case e.types.GRAPH:c=l.createGraph(y(c.input),c.name);break;case e.types.GROUP:c=l.createGroup(y(c.input),[].concat(c.variables),c.aggregates.map(y));break;case e.types.INV:c=l.createInv(y(c.path));break;case e.types.JOIN:c=l.createJoin(c.input.map(y));break;case e.types.LEFT_JOIN:c=l.createLeftJoin(y(c.input[0]),y(c.input[1]),c.expression?y(c.expression):void 0);break;case e.types.LINK:c=l.createLink(c.iri);break;case e.types.MINUS:c=l.createMinus(y(c.input[0]),y(c.input[1]));break;case e.types.NOP:c=l.createNop();break;case e.types.NPS:c=l.createNps([].concat(c.iris));break;case e.types.ONE_OR_MORE_PATH:c=l.createOneOrMorePath(y(c.path));break;case e.types.ORDER_BY:c=l.createOrderBy(y(c.input),c.expressions.map(y));break;case e.types.PATH:c=l.createPath(c.subject,y(c.predicate),c.object,c.graph);break;case e.types.PATTERN:c=l.createPattern(c.subject,c.predicate,c.object,c.graph);break;case e.types.PROJECT:c=l.createProject(y(c.input),[...c.variables]);break;case e.types.REDUCED:c=l.createReduced(y(c.input));break;case e.types.SEQ:c=l.createSeq(c.input.map(y));break;case e.types.SERVICE:c=l.createService(y(c.input),c.name,c.silent);break;case e.types.SLICE:c=l.createSlice(y(c.input),c.start,c.length);break;case e.types.UNION:c=l.createUnion(c.input.map(y));break;case e.types.VALUES:c=l.createValues([].concat(c.variables),c.bindings.map(b=>Object.assign({},b)));break;case e.types.ZERO_OR_MORE_PATH:c=l.createZeroOrMorePath(y(c.path));break;case e.types.ZERO_OR_ONE_PATH:c=l.createZeroOrOnePath(y(c.path));break;case e.types.COMPOSITE_UPDATE:c=l.createCompositeUpdate(c.updates.map(y));break;case e.types.DELETE_INSERT:c=l.createDeleteInsert(c.delete?c.delete.map(y):void 0,c.insert?c.insert.map(y):void 0,c.where?y(c.where):void 0);break;case e.types.LOAD:c=l.createLoad(c.source,c.destination,c.silent);break;case e.types.CLEAR:c=l.createClear(c.source,c.silent);break;case e.types.CREATE:c=l.createCreate(c.source,c.silent);break;case e.types.DROP:c=l.createDrop(c.source,c.silent);break;case e.types.ADD:c=l.createAdd(c.source,c.destination);break;case e.types.MOVE:c=l.createMove(c.source,c.destination);break;case e.types.COPY:c=l.createCopy(c.source,c.destination);break;default:throw new Error(`Unknown Operation type ${c.type}`)}return p&&(c.metadata=p),c}static mapExpression(a,o,l){let c=a,d=!0;l=l||new u.default;const h=o[a.expressionType];if(h&&({result:c,recurse:d}=h(a,l)),!d)return c;let f=p=>n.mapOperation(p,o,l);switch(a.expressionType){case e.expressionTypes.AGGREGATE:return a.variable?l.createBoundAggregate(a.variable,a.aggregator,f(a.expression),a.distinct,a.separator):l.createAggregateExpression(a.aggregator,f(a.expression),a.distinct,a.separator);case e.expressionTypes.EXISTENCE:return l.createExistenceExpression(a.not,f(a.input));case e.expressionTypes.NAMED:return l.createNamedExpression(a.name,a.args.map(f));case e.expressionTypes.OPERATOR:return l.createOperatorExpression(a.operator,a.args.map(f));case e.expressionTypes.TERM:return l.createTermExpression(a.term);case e.expressionTypes.WILDCARD:return l.createWildcardExpression();default:throw new Error(`Unknown Expression type ${a.expressionType}`)}}static cloneOperation(a){return n.mapOperation(a,{})}static cloneExpression(a){return n.mapExpression(a,{})}static createUniqueVariable(a,o,l){let c=0,d=a;for(;o[d];)d=`${a}${c++}`;return l.variable(d)}static isSimpleTerm(a){return a.termType!==void 0&&a.termType!=="Quad"&&a.termType!=="Wildcard"}static isQuad(a){return a.termType==="Quad"}static hasQuadVariables(a){return(0,s.someTermsNested)(a,o=>o.termType==="Variable")}static isWildcard(a){return a.termType==="Wildcard"}}return t1.default=n,t1}var mO;function IV(){if(mO)return Zy;mO=1;var t=I&&I.__createBinding||(Object.create?function(N,R,T,x){x===void 0&&(x=T);var B=Object.getOwnPropertyDescriptor(R,T);(!B||("get"in B?!R.__esModule:B.writable||B.configurable))&&(B={enumerable:!0,get:function(){return R[T]}}),Object.defineProperty(N,x,B)}:function(N,R,T,x){x===void 0&&(x=T),N[x]=R[T]}),e=I&&I.__setModuleDefault||(Object.create?function(N,R){Object.defineProperty(N,"default",{enumerable:!0,value:R})}:function(N,R){N.default=R}),u=I&&I.__importStar||function(N){if(N&&N.__esModule)return N;var R={};if(N!=null)for(var T in N)T!=="default"&&Object.prototype.hasOwnProperty.call(N,T)&&t(R,N,T);return e(R,N),R},s=I&&I.__importDefault||function(N){return N&&N.__esModule?N:{default:N}};Object.defineProperty(Zy,"__esModule",{value:!0});const n=OV(),r=er(),a=u(gy()),o=s(jb()),l=s(RT()),c=my().Parser,d=a.types;let h=new Set,f=0,p=!1,y;function b(N,R){R=R||{},y=new o.default(R.dataFactory);let T;if(g(N)){let x=new c(R);x._resetBlanks(),T=x.parse(N)}else T=N;return m(T,R.quads,R.blankToVariable)}Zy.default=b;function m(N,R,T){if(h=new Set,f=0,p=!!R,!N.type)return y.createNop();if(N.type!=="query"&&N.type!=="update")throw new Error("Translate only works on complete query or update objects.");let x;if(S(N),N.type==="query"){const B={type:"group",patterns:N.where||[]};x=D(B),x=X(N,x)}else N.type==="update"&&(x=ie(N));return T&&(x=$(x)),x}function g(N){return typeof N=="string"}function v(N){return!!(N!=null&&N.termType)}function _(N){return N.subject&&N.predicate&&N.object}function w(N){return(N==null?void 0:N.termType)==="Variable"}function S(N){if(v(N))w(N)&&h.add(`?${N.value}`);else if(Array.isArray(N))for(const R of N)S(R);else if(N&&typeof N=="object")for(let R of Object.keys(N))R.startsWith("?")?h.add(R):R.startsWith("$")&&h.add(`?${R.slice(1)}`),S(N[R])}function A(N){let R={};if(_(N)){const T=[A(N.subject),A(N.predicate),A(N.object),N.graph?A(N.graph):{}];Object.assign(R,...T)}else if(v(N))w(N)&&(R[N.value]=N);else if(N.type==="bgp"){const T=N.triples;Object.assign(R,...T.map(A))}else if(N.type==="path")Object.assign(R,...N.items.map(A));else if(N.type==="group"||N.type==="union"||N.type==="optional")Object.assign(R,...N.patterns.map(A));else if(N.type==="service"||N.type==="graph")Object.assign(R,A(N.name)),Object.assign(R,...N.patterns.map(A));else if(N.type==="bind")Object.assign(R,A(N.variable));else if(N.type==="values"){if(N.values.length>0){const T=Object.keys(N.values[0]).map(x=>y.createTerm(x));Object.assign(R,...T.map(A))}}else if(N.type==="query"&&(N.queryType==="SELECT"||N.queryType==="DESCRIBE")){N.where&&N.variables.some(l.default.isWildcard)&&Object.assign(R,...N.where.map(A));for(const T of N.variables)w(T)?Object.assign(R,A(T)):T.variable&&Object.assign(R,A(T.variable));if(N.queryType==="SELECT"){if(N.group)for(const T of N.group)T.variable&&Object.assign(R,A(T.variable));if(N.values){const T={type:"values",values:N.values};Object.assign(R,A(T))}}}return R}function D(N){if(N.type==="bgp")return E(N);if(N.type==="union")return y.createUnion(N.patterns.map(R=>(R.type!=="group"&&(R={type:"group",patterns:[R]}),D(R))));if(N.type==="graph"){const R={type:"group",patterns:N.patterns};let T=D(R);return p?T=Q(T,N.name):T=y.createGraph(T,N.name),T}if(N.type==="values")return fe(N);if(N.type==="query")return m(N,p,!1);if(N.type==="group"){let R=[],T=[];for(let k of N.patterns)(k.type==="filter"?R:T).push(k);let x=T.reduce(Z,y.createBgp([])),B=R.map(k=>L(k.expression));return B.length>0&&(x=y.createFilter(x,B.reduce((k,V)=>y.createOperatorExpression("&&",[k,V])))),x}throw new Error(`Unexpected type: ${N.type}`)}function L(N){if(l.default.isSimpleTerm(N))return y.createTermExpression(N);if(l.default.isQuad(N))return l.default.hasQuadVariables(N)?y.createOperatorExpression("triple",[L(N.subject),L(N.predicate),L(N.object)]):y.createTermExpression(N);if(l.default.isWildcard(N))return y.createWildcardExpression();if("aggregation"in N)return y.createAggregateExpression(N.aggregation,L(N.expression),!!N.distinct,N.separator);if("function"in N)return y.createNamedExpression(N.function,N.args.map(L));if("operator"in N)return N.operator==="exists"||N.operator==="notexists"?y.createExistenceExpression(N.operator==="notexists",D(N.args[0])):((N.operator==="in"||N.operator==="notin")&&(N.args=[N.args[0]].concat(N.args[1])),y.createOperatorExpression(N.operator,N.args.map(L)));throw new Error(`Unknown expression: ${JSON.stringify(N)}`)}function E(N){let R=[],T=[];for(let x of N.triples)if("pathType"in x.predicate){let B=O(x);for(let k of B)k.type===d.PATH?(R.length>0&&T.push(y.createBgp(R)),R=[],T.push(k)):R.push(k)}else R.push(M(x));return R.length>0&&T.push(y.createBgp(R)),T.length===1?T[0]:y.createJoin(T)}function O(N){let R=N.subject,T=P(N.predicate),x=N.object;return j(R,T,x)}function P(N){if(l.default.isSimpleTerm(N)){if(N.termType==="NamedNode")return y.createLink(N);throw new Error(`Path predicate should be a NamedNode, got ${JSON.stringify(N)}`)}if(N.pathType==="^")return y.createInv(P(N.items[0]));if(N.pathType==="!"){let R=[],T=[],x;"pathType"in N.items[0]&&N.items[0].pathType==="|"?x=N.items[0].items:x=N.items;for(let V of x)if(l.default.isSimpleTerm(V))R.push(V);else if(V.pathType==="^")T.push(V.items[0]);else throw new Error(`Unexpected item: ${JSON.stringify(V)}`);let B=y.createNps(R),k=y.createInv(y.createNps(T));return T.length===0?B:R.length===0?k:y.createAlt([B,k])}if(N.pathType==="/")return y.createSeq(N.items.map(P));if(N.pathType==="|")return y.createAlt(N.items.map(P));if(N.pathType==="*")return y.createZeroOrMorePath(P(N.items[0]));if(N.pathType==="+")return y.createOneOrMorePath(P(N.items[0]));if(N.pathType==="?")return y.createZeroOrOnePath(P(N.items[0]));throw new Error(`Unable to translate path expression ${JSON.stringify(N)}`)}function j(N,R,T){if(R.type===d.LINK)return[y.createPattern(N,R.iri,T)];if(R.type===d.INV)return j(T,R.path,N);if(R.type===d.SEQ){let x=N;return l.default.flatten(R.input.map((B,k)=>{const V=k===R.input.length-1?T:U(),J=j(x,B,V);return V.termType==="Variable"&&(x=V),J}))}return[y.createPath(N,R,T)]}function U(){let N=`?var${f++}`;return h.has(N)?U():(h.add(N),y.createTerm(N))}function M(N){if("pathType"in N.predicate)throw new Error("Trying to translate property path to quad.");return y.createPattern(N.subject,N.predicate,N.object,N.graph)}let q=Object.values(d);function Q(N,R,T){if(N.type===d.GRAPH){if(T)throw new Error("Recursing through nested GRAPH statements with a replacement is impossible.");N=Q(N.input,N.name)}else if(N.type!==d.SERVICE)if(N.type===d.BGP)N.patterns=N.patterns.map(x=>(T&&(x.subject.equals(R)&&(x.subject=T),x.predicate.equals(R)&&(x.predicate=T),x.object.equals(R)&&(x.object=T)),x.graph.termType==="DefaultGraph"&&(x.graph=R),x));else if(N.type===d.PATH)T&&(N.subject.equals(R)&&(N.subject=T),N.object.equals(R)&&(N.object=T)),N.graph.termType==="DefaultGraph"&&(N.graph=R);else if(N.type===d.PROJECT&&!T)N.variables.some(x=>x.equals(R))||(T=U()),N.input=Q(N.input,R,T);else if(N.type===d.EXTEND&&!T)N.variable.equals(R)&&(T=U()),N.input=Q(N.input,R,T);else for(let x of Object.keys(N))Array.isArray(N[x])?N[x]=N[x].map(B=>Q(B,R,T)):q.indexOf(N[x].type)>=0?N[x]=Q(N[x],R,T):T&&w(N[x])&&N[x].equals(R)&&(N[x]=T);return N}function Z(N,R){if(R.type==="optional"){const T=D({type:"group",patterns:R.patterns});T.type===d.FILTER?N=y.createLeftJoin(N,T.input,T.expression):N=y.createLeftJoin(N,T)}else if(R.type==="minus"){const T=D({type:"group",patterns:R.patterns});N=y.createMinus(N,T)}else if(R.type==="bind")N=y.createExtend(N,R.variable,L(R.expression));else if(R.type==="service"){const T={type:"group",patterns:R.patterns},x=y.createService(D(T),R.name,R.silent);N=K(N,x)}else{const T=D(R);N=K(N,T)}return N}function K(N,R){return N.type===d.BGP&&R.type===d.BGP?N=y.createBgp([...N.patterns,...R.patterns]):N.type===d.BGP&&N.patterns.length===0?N=R:R.type===d.BGP&&R.patterns.length===0||(N=y.createJoin([N,R])),N}function fe(N){let R=(N.values.length===0?[]:Object.keys(N.values[0])).map(y.createTerm.bind(y)),T=N.values.map(x=>{let B=Object.keys(x);B=B.filter(V=>x[V]!==void 0);let k={};for(let V of B)k[V]=x[V];return k});return y.createValues(R,T)}function X(N,R){const T=N,x=[],B={};if(T.variables=T.variables&&T.variables.map(V=>he(V,B)),T.having=T.having&&T.having.map(V=>he(V,B)),T.order=T.order&&T.order.map(V=>he(V,B)),T.group||Object.keys(B).length>0){const V=Object.keys(B).map(z=>xe(B[z],y.createTerm(z))),J=[];if(T.group)for(const z of T.group)if(l.default.isSimpleTerm(z.expression))J.push(z.expression);else{const Y="variable"in z?z.variable:U();R=y.createExtend(R,Y,L(z.expression)),J.push(Y)}R=y.createGroup(R,J,V)}if(T.having)for(let V of T.having)R=y.createFilter(R,L(V));N.values&&(R=y.createJoin([R,fe(N)]));let k=[];if(N.queryType==="SELECT"||N.queryType==="DESCRIBE")if(N.variables.some(V=>V&&l.default.isWildcard(V)))k=Object.values(A(N)).sort((V,J)=>V.value.localeCompare(J.value));else for(let V of N.variables)w(V)||!("variable"in V)?k.push(V):V.variable&&(k.push(V.variable),x.push(V));for(let V of x)R=y.createExtend(R,V.variable,L(V.expression));return T.order&&(R=y.createOrderBy(R,T.order.map(V=>{let J=L(V.expression);return V.descending&&(J=y.createOperatorExpression("desc",[J])),J}))),N.queryType==="SELECT"&&(R=y.createProject(R,k)),T.distinct&&(R=y.createDistinct(R)),T.reduced&&(R=y.createReduced(R)),N.queryType==="CONSTRUCT"?R=y.createConstruct(R,(N.template||[]).map(M)):N.queryType==="ASK"?R=y.createAsk(R):N.queryType==="DESCRIBE"&&(R=y.createDescribe(R,k)),(T.offset||T.limit)&&(R=y.createSlice(R,T.offset||0,T.limit)),T.from&&(R=y.createFrom(R,T.from.default,T.from.named)),R}function he(N,R){if("type"in N&&N.type==="aggregate"){let T=!1,x;for(let B of Object.keys(R))if(n(R[B],N)){x=y.createTerm(B),T=!0;break}return T||(x=U(),R[(0,r.termToString)(x)]=N),x}return"expression"in N&&N.expression?{...N,expression:he(N.expression,R)}:"args"in N&&N.args?{...N,args:N.args.map(T=>he(T,R))}:N}function xe(N,R){if(N.type!=="aggregate"||!N.aggregation)throw new Error(`Unexpected input: ${JSON.stringify(N)}`);const T=L(N);return T.variable=R,T}function ie(N){return N.updates.length===1?ae(N.updates[0]):y.createCompositeUpdate(N.updates.map(ae))}function ae(N){if("type"in N){if(N.type==="load")return de(N);if(N.type==="clear"||N.type==="create"||N.type==="drop")return ge(N);if(N.type==="add"||N.type==="copy"||N.type==="move")return oe(N)}else if(N.updateType==="insertdelete"||N.updateType==="deletewhere"||N.updateType==="delete"||N.updateType==="insert")return Oe(N);throw new Error(`Unknown update type ${JSON.stringify(N)}`)}function Oe(N){if(!p)throw new Error("INSERT/DELETE operations are only supported with quads option enabled");let R=[],T=[],x;if(N.delete&&(R=l.default.flatten(N.delete.map(B=>Ne(B,N.graph)))),N.insert&&(T=l.default.flatten(N.insert.map(B=>Ne(B,N.graph)))),N.where&&N.where.length>0){x=D({type:"group",patterns:N.where});const B=N.using;B?x=y.createFrom(x,B.default,B.named):N.graph&&(x=Q(x,N.graph))}else N.updateType==="deletewhere"&&R.length>0&&(x=y.createBgp(R));return y.createDeleteInsert(R.length>0?R:void 0,T.length>0?T:void 0,x)}function Ne(N,R){let T=R;N.type==="graph"&&(T=N.name);let x=N.triples;return T&&(x=x.map(B=>Object.assign(B,{graph:T}))),x.map(M)}function ge(N){let R;switch(l.default.isSimpleTerm(N.graph)?R=N.graph:N.graph.all?R="ALL":N.graph.default?R="DEFAULT":N.graph.named?R="NAMED":R=N.graph.name,N.type){case"clear":return y.createClear(R,N.silent);case"create":return y.createCreate(R,N.silent);case"drop":return y.createDrop(R,N.silent)}}function de(N){return y.createLoad(N.source,N.destination,N.silent)}function oe(N){const R=N.source.default?"DEFAULT":N.source.name,T=N.destination.default?"DEFAULT":N.destination.name;switch(N.type){case"copy":return y.createCopy(R,T,N.silent);case"move":return y.createMove(R,T,N.silent);case"add":return y.createAdd(R,T,N.silent)}}function $(N){const R={},T=Array.from(h).reduce((B,k)=>(B[k]=!0,B),{});return l.default.mapOperation(N,{[a.types.DELETE_INSERT]:B=>({result:y.createDeleteInsert(B.delete,B.insert,B.where&&$(B.where)),recurse:!1}),[a.types.PATH]:(B,k)=>({result:k.createPath(x(B.subject),B.predicate,x(B.object),x(B.graph)),recurse:!1}),[a.types.PATTERN]:(B,k)=>({result:k.createPattern(x(B.subject),x(B.predicate),x(B.object),x(B.graph)),recurse:!1}),[a.types.CONSTRUCT]:B=>({result:y.createConstruct($(B.input),B.template),recurse:!1})});function x(B){if(B.termType==="BlankNode"){let k=R[B.value];return k||(k=l.default.createUniqueVariable(B.value,T,y.dataFactory),T[k.value]=!0,R[B.value]=k),k}return B}}return Zy}var bs={},am={},Mt={},sm={},rr={},om,_O;function _y(){if(_O)return om;_O=1,om=t;function t(e,u){if(!e)throw new Error(u||"Assertion failed")}return t.equal=function(u,s,n){if(u!=s)throw new Error(n||"Assertion failed: "+u+" != "+s)},om}var r1={exports:{}},vO;function PV(){return vO||(vO=1,typeof Object.create=="function"?r1.exports=function(e,u){u&&(e.super_=u,e.prototype=Object.create(u.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:r1.exports=function(e,u){if(u){e.super_=u;var s=function(){};s.prototype=u.prototype,e.prototype=new s,e.prototype.constructor=e}}),r1.exports}var wO;function ki(){if(wO)return rr;wO=1;var t=_y(),e=PV();rr.inherits=e;function u(j,U){return(j.charCodeAt(U)&64512)!==55296||U<0||U+1>=j.length?!1:(j.charCodeAt(U+1)&64512)===56320}function s(j,U){if(Array.isArray(j))return j.slice();if(!j)return[];var M=[];if(typeof j=="string")if(U){if(U==="hex")for(j=j.replace(/[^a-z0-9]+/ig,""),j.length%2!==0&&(j="0"+j),Q=0;Q>6|192,M[q++]=Z&63|128):u(j,Q)?(Z=65536+((Z&1023)<<10)+(j.charCodeAt(++Q)&1023),M[q++]=Z>>18|240,M[q++]=Z>>12&63|128,M[q++]=Z>>6&63|128,M[q++]=Z&63|128):(M[q++]=Z>>12|224,M[q++]=Z>>6&63|128,M[q++]=Z&63|128)}else for(Q=0;Q>>24|j>>>8&65280|j<<8&16711680|(j&255)<<24;return U>>>0}rr.htonl=r;function a(j,U){for(var M="",q=0;q>>0}return Z}rr.join32=c;function d(j,U){for(var M=new Array(j.length*4),q=0,Q=0;q>>24,M[Q+1]=Z>>>16&255,M[Q+2]=Z>>>8&255,M[Q+3]=Z&255):(M[Q+3]=Z>>>24,M[Q+2]=Z>>>16&255,M[Q+1]=Z>>>8&255,M[Q]=Z&255)}return M}rr.split32=d;function h(j,U){return j>>>U|j<<32-U}rr.rotr32=h;function f(j,U){return j<>>32-U}rr.rotl32=f;function p(j,U){return j+U>>>0}rr.sum32=p;function y(j,U,M){return j+U+M>>>0}rr.sum32_3=y;function b(j,U,M,q){return j+U+M+q>>>0}rr.sum32_4=b;function m(j,U,M,q,Q){return j+U+M+q+Q>>>0}rr.sum32_5=m;function g(j,U,M,q){var Q=j[U],Z=j[U+1],K=q+Z>>>0,fe=(K>>0,j[U+1]=K}rr.sum64=g;function v(j,U,M,q){var Q=U+q>>>0,Z=(Q>>0}rr.sum64_hi=v;function _(j,U,M,q){var Q=U+q;return Q>>>0}rr.sum64_lo=_;function w(j,U,M,q,Q,Z,K,fe){var X=0,he=U;he=he+q>>>0,X+=he>>0,X+=he>>0,X+=he>>0}rr.sum64_4_hi=w;function S(j,U,M,q,Q,Z,K,fe){var X=U+q+Z+fe;return X>>>0}rr.sum64_4_lo=S;function A(j,U,M,q,Q,Z,K,fe,X,he){var xe=0,ie=U;ie=ie+q>>>0,xe+=ie>>0,xe+=ie>>0,xe+=ie>>0,xe+=ie>>0}rr.sum64_5_hi=A;function D(j,U,M,q,Q,Z,K,fe,X,he){var xe=U+q+Z+fe+he;return xe>>>0}rr.sum64_5_lo=D;function L(j,U,M){var q=U<<32-M|j>>>M;return q>>>0}rr.rotr64_hi=L;function E(j,U,M){var q=j<<32-M|U>>>M;return q>>>0}rr.rotr64_lo=E;function O(j,U,M){return j>>>M}rr.shr64_hi=O;function P(j,U,M){var q=j<<32-M|U>>>M;return q>>>0}return rr.shr64_lo=P,rr}var um={},SO;function vy(){if(SO)return um;SO=1;var t=ki(),e=_y();function u(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}return um.BlockHash=u,u.prototype.update=function(n,r){if(n=t.toArray(n,r),this.pending?this.pending=this.pending.concat(n):this.pending=n,this.pendingTotal+=n.length,this.pending.length>=this._delta8){n=this.pending;var a=n.length%this._delta8;this.pending=n.slice(n.length-a,n.length),this.pending.length===0&&(this.pending=null),n=t.join32(n,0,n.length-a,this.endian);for(var o=0;o>>24&255,o[l++]=n>>>16&255,o[l++]=n>>>8&255,o[l++]=n&255}else for(o[l++]=n&255,o[l++]=n>>>8&255,o[l++]=n>>>16&255,o[l++]=n>>>24&255,o[l++]=0,o[l++]=0,o[l++]=0,o[l++]=0,c=8;c>>3}Fi.g0_256=l;function c(d){return e(d,17)^e(d,19)^d>>>10}return Fi.g1_256=c,Fi}var cm,AO;function DV(){if(AO)return cm;AO=1;var t=ki(),e=vy(),u=LF(),s=t.rotl32,n=t.sum32,r=t.sum32_5,a=u.ft_1,o=e.BlockHash,l=[1518500249,1859775393,2400959708,3395469782];function c(){if(!(this instanceof c))return new c;o.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}return t.inherits(c,o),cm=c,c.blockSize=512,c.outSize=160,c.hmacStrength=80,c.padLength=64,c.prototype._update=function(h,f){for(var p=this.W,y=0;y<16;y++)p[y]=h[f+y];for(;ythis.blockSize&&(n=new this.Hash().update(n).digest()),e(n.length<=this.blockSize);for(var r=n.length;ru.someTerms(A,D=>D.termType==="BlankNode"||D.termType==="Quad"&&u.getTermsNested(D).some(L=>L.termType==="BlankNode")))}Mt.getQuadsWithBlankNodes=c;function d(S){return S.filter(A=>u.everyTerms(A,D=>D.termType!=="BlankNode"&&!(D.termType==="Quad"&&u.getTermsNested(D).some(L=>L.termType==="BlankNode"))))}Mt.getQuadsWithoutBlankNodes=d;function h(S){const A={};for(const D of S)A[JSON.stringify(e.quadToStringQuad(D))]=!0;return A}Mt.indexGraph=h;function f(S){return Object.keys(S).map(A=>e.stringQuadToQuad(JSON.parse(A)))}Mt.deindexGraph=f;function p(S){return f(h(S))}Mt.uniqGraph=p;function y(S){return u.uniqTerms(S.map(A=>u.getBlankNodes(u.getTermsNested(A))).reduce((A,D)=>A.concat(D),[]))}Mt.getGraphBlankNodes=y;function b(S,A,D){const L=Object.assign({},D),E={};let O=!0;for(;O;){const P=Object.keys(L).length;for(const U of A){const M=e.termToString(U);if(!L[M]){const[q,Q]=m(U,S,L);q&&(L[M]=Q),E[M]=Q}}const j={};for(const U in E){const M=E[U];j[M]===void 0?j[M]=U:j[M]=!1}for(const U in j){const M=j[U];M&&(L[M]=U)}O=P!==Object.keys(L).length}return[L,E]}Mt.hashTerms=b;function m(S,A,D){const L=[];let E=!0;for(const P of A){const j=u.getTermsNested(P);if(j.some(U=>U.equals(S))){L.push(v(P,D,S));for(const U of j)!w(U,D)&&!U.equals(S)&&(E=!1)}}const O=g(L.sort().join(""));return[E,O]}Mt.hashTerm=m;function g(S){return t.sha1().update(S).digest("hex")}Mt.sha1hex=g;function v(S,A,D){return u.getTerms(S).map(L=>_(L,A,D)).join("|")}Mt.quadToSignature=v;function _(S,A,D){return S.equals(D)?"@self":S.termType==="BlankNode"?A[e.termToString(S)]||"@blank":S.termType==="Quad"?`<${v(S,A,D)}>`:e.termToString(S)}Mt.termToSignature=_;function w(S,A){return S.termType!=="BlankNode"&&!(S.termType==="Quad"&&u.getTermsNested(S).some(D=>!w(D,A)))||!!A[e.termToString(S)]}return Mt.isTermGrounded=w,Mt}var jO;function qV(){return jO||(jO=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(FV(),t)}(am)),am}var LO;function BV(){if(LO)return bs;LO=1;var t=I&&I.__createBinding||(Object.create?function(W,we,Te,Le){Le===void 0&&(Le=Te);var $e=Object.getOwnPropertyDescriptor(we,Te);(!$e||("get"in $e?!we.__esModule:$e.writable||$e.configurable))&&($e={enumerable:!0,get:function(){return we[Te]}}),Object.defineProperty(W,Le,$e)}:function(W,we,Te,Le){Le===void 0&&(Le=Te),W[Le]=we[Te]}),e=I&&I.__setModuleDefault||(Object.create?function(W,we){Object.defineProperty(W,"default",{enumerable:!0,value:we})}:function(W,we){W.default=we}),u=I&&I.__importStar||function(W){if(W&&W.__esModule)return W;var we={};if(W!=null)for(var Te in W)Te!=="default"&&Object.prototype.hasOwnProperty.call(W,Te)&&t(we,W,Te);return e(we,W),we},s=I&&I.__importDefault||function(W){return W&&W.__esModule?W:{default:W}};Object.defineProperty(bs,"__esModule",{value:!0}),bs.toSparqlJs=bs.toSparql=void 0;const n=qV(),r=er(),a=my(),o=u(gy()),l=s(jb()),c=s(RT()),d=o.types,h=o.expressionTypes;let f;const p=new l.default;function y(W,we={}){return new a.Generator(we).stringify(b(W))}bs.toSparql=y;function b(W){m(),W=ke(W);let we=g(W);return we.type==="group"?we.patterns[0]:we}bs.toSparqlJs=b;function m(){f={project:!1,extend:[],group:[],aggregates:[],order:[]}}function g(W){switch(W.type!==d.EXTEND&&W.type!==d.ORDER_BY&&W.type!==d.GRAPH&&(f.project=!1),W.type){case d.EXPRESSION:return v(W);case d.ASK:return de(W,d.ASK);case d.BGP:return U(W);case d.CONSTRUCT:return M(W);case d.DESCRIBE:return de(W,d.DESCRIBE);case d.DISTINCT:return q(W);case d.EXTEND:return Q(W);case d.FROM:return Z(W);case d.FILTER:return K(W);case d.GRAPH:return fe(W);case d.GROUP:return X(W);case d.JOIN:return he(W);case d.LEFT_JOIN:return xe(W);case d.MINUS:return ie(W);case d.NOP:return{};case d.ORDER_BY:return ae(W);case d.PATH:return Oe(W);case d.PATTERN:return Ne(W);case d.PROJECT:return de(W,d.PROJECT);case d.REDUCED:return $(W);case d.SERVICE:return N(W);case d.SLICE:return R(W);case d.UNION:return T(W);case d.VALUES:return x(W);case d.COMPOSITE_UPDATE:return Ae(W);case d.DELETE_INSERT:return Ie(W);case d.LOAD:return Ee(W);case d.CLEAR:return qe(W);case d.CREATE:return G(W);case d.DROP:return F(W);case d.ADD:return re(W);case d.MOVE:return be(W);case d.COPY:return Re(W)}throw new Error(`Unknown Operation type ${W.type}`)}function v(W){switch(W.expressionType){case h.AGGREGATE:return S(W);case h.EXISTENCE:return A(W);case h.NAMED:return D(W);case h.OPERATOR:return L(W);case h.TERM:return E(W);case h.WILDCARD:return O(W)}throw new Error(`Unknown Expression Operation type ${W.expressionType}`)}function _(W){switch(W.type){case d.ALT:return B(W);case d.INV:return k(W);case d.LINK:return V(W);case d.NPS:return J(W);case d.ONE_OR_MORE_PATH:return z(W);case d.SEQ:return Y(W);case d.ZERO_OR_MORE_PATH:return te(W);case d.ZERO_OR_ONE_PATH:return ce(W)}throw new Error(`Unknown Path type ${W.type}`)}function w(W){return(0,r.termToString)(W)}function S(W){const we={expression:v(W.expression),type:"aggregate",aggregation:W.aggregator,distinct:W.distinct};return W.separator&&(we.separator=W.separator),we}function A(W){return{type:"operation",operator:W.not?"notexists":"exists",args:[{type:"group",patterns:c.default.flatten([g(W.input)])}]}}function D(W){return{type:"functionCall",function:W.name,args:W.args.map(v)}}function L(W){if(W.operator==="desc"){const Te={expression:v(W.args[0])};return Te.descending=!0,Te}const we={type:"operation",operator:W.operator,args:W.args.map(v)};return(we.operator==="in"||we.operator==="notin")&&(we.args=[we.args[0]].concat([we.args.slice(1)])),we}function E(W){return W.term}function O(W){return W.wildcard}function P(W){return Array.isArray(W)?W.length===1?W[0]:{type:"group",patterns:W}:W}function j(W){return W}function U(W){let we=W.patterns.map(Ne);return we.length===0?null:{type:"bgp",triples:we}}function M(W){return{type:"query",prefixes:{},queryType:"CONSTRUCT",template:W.template.map(Ne),where:c.default.flatten([g(W.input)])}}function q(W){let we=g(W.input);return we.patterns[0].distinct=!0,we}function Q(W){return f.project?(f.extend.push(W),g(W.input)):c.default.flatten([g(W.input),{type:"bind",variable:W.variable,expression:v(W.expression)}])}function Z(W){const we=g(W.input);let Te=we;return we.type==="group"&&(Te=we.patterns[0]),Te.from={default:W.default,named:W.named},we}function K(W){return{type:"group",patterns:c.default.flatten([g(W.input),{type:"filter",expression:v(W.expression)}])}}function fe(W){return{type:"graph",patterns:c.default.flatten([g(W.input)]),name:W.name}}function X(W){const we=g(W.input),Te=W.aggregates.map(j);return f.aggregates.push(...Te),f.group.push(...W.variables),we}function he(W){return c.default.flatten(W.input.map(g)).reduce((Te,Le)=>(Le.type!=="bgp"||Te.length==0||Te[Te.length-1].type!=="bgp"?Te.push(Le):Te[Te.length-1].triples.push(...Le.triples),Te),[])}function xe(W){const we={type:"optional",patterns:[g(W.input[1])]};return W.expression&&we.patterns.push({type:"filter",expression:v(W.expression)}),we.patterns=c.default.flatten(we.patterns),c.default.flatten([g(W.input[0]),we])}function ie(W){let we=g(W.input[1]);return we.type==="group"&&(we=we.patterns),Array.isArray(we)||(we=[we]),c.default.flatten([g(W.input[0]),{type:"minus",patterns:we}])}function ae(W){return f.order.push(...W.expressions),g(W.input)}function Oe(W){return{type:"bgp",triples:[{subject:W.subject,predicate:_(W.predicate),object:W.object}]}}function Ne(W){return{subject:W.subject,predicate:W.predicate,object:W.object}}function ge(W,we){let Te=c.default.isSimpleTerm(W)?w(W):W;if(typeof Te=="string"){if(we[Te])return we[Te]}else if(Array.isArray(W))W=W.map(Le=>ge(Le,we));else for(let Le of Object.keys(W))W[Le]=ge(W[Le],we);return W}function de(W,we){const Te={type:"query",prefixes:{}},Le=Te;let $e;we===d.PROJECT?(Te.queryType="SELECT",$e=W.variables):we===d.ASK?Te.queryType="ASK":we===d.DESCRIBE&&(Te.queryType="DESCRIBE",$e=W.terms);const We=f.extend,tt=f.group,lt=f.aggregates,ut=f.order;m(),f.project=!0;let le=c.default.flatten([g(W.input)]);le.length===1&&le[0].type==="group"&&(le=le[0].patterns),Te.where=le;let C={};for(let De of f.aggregates)C[w(De.variable)]=v(De);let ee={};for(let De=f.extend.length-1;De>=0;--De){let Ue=f.extend[De];ee[w(Ue.variable)]=ge(v(Ue.expression),C)}f.group.length>0&&(Le.group=f.group.map(De=>{let Ue=w(De);if(ee[Ue]){let Fe=ee[Ue];return delete ee[Ue],{variable:De,expression:Fe}}return{expression:De}})),f.order.length>0&&(Le.order=f.order.map(g).map(De=>De.descending?De:{expression:De})),$e&&(Le.variables=$e.map(De=>{let Ue=w(De);if(ee[Ue]){let Fe=ee[Ue];return delete ee[Ue],{variable:De,expression:Fe}}return De}),Le.variables.length===0&&(Le.variables=[new a.Wildcard]));const pe=Object.entries(ee);if(pe.length>0){Le.where=Le.where||[];for(const[De,Ue]of pe)Le.where.push({type:"bind",variable:(0,r.stringToTerm)(De),expression:Ue})}if(Te.where.length>0&&Te.where[Te.where.length-1].type==="filter"){const De=Te.where[Te.where.length-1];oe(De,Object.keys(C))&&(Le.having=c.default.flatten([ge(De.expression,C)]),Te.where.splice(-1))}return f.extend=We,f.group=tt,f.aggregates=lt,f.order=ut,{type:"group",patterns:[Le]}}function oe(W,we){return c.default.isSimpleTerm(W)?we.indexOf(w(W))>=0:Array.isArray(W)?W.some(Te=>oe(Te,we)):W===Object(W)?Object.keys(W).some(Te=>oe(W[Te],we)):we.indexOf(W)>=0}function $(W){let we=g(W.input);return we.patterns[0].reduced=!0,we}function N(W){let we=g(W.input);return we.type==="group"&&(we=we.patterns),Array.isArray(we)||(we=[we]),{type:"service",name:W.name,silent:W.silent,patterns:we}}function R(W){let we=g(W.input),Te=we;return we.type&&we.type==="group"&&(Te=we.patterns[0]),W.start!==0&&(Te.offset=W.start),W.length!==void 0&&(Te.limit=W.length),we}function T(W){return{type:"union",patterns:W.input.map(g).map(P)}}function x(W){return{type:"values",values:W.bindings.map(we=>{let Te={};for(let Le of W.variables){let $e=`?${Le.value}`;we[$e]?Te[$e]=we[$e]:Te[$e]=void 0}return Te})}}function B(W){const we=W.input.map(_);return we.every(Te=>"pathType"in Te&&Te.pathType==="!")?{type:"path",pathType:"!",items:[{type:"path",pathType:"|",items:c.default.flatten(we.map(Te=>Te.items))}]}:{type:"path",pathType:"|",items:we}}function k(W){if(W.path.type===d.NPS){const we=W.path.iris.map(Te=>({type:"path",pathType:"^",items:[Te]}));return we.length<=1?{type:"path",pathType:"!",items:we}:{type:"path",pathType:"!",items:[{type:"path",pathType:"|",items:we}]}}return{type:"path",pathType:"^",items:[_(W.path)]}}function V(W){return W.iri}function J(W){return W.iris.length<=1?{type:"path",pathType:"!",items:W.iris}:{type:"path",pathType:"!",items:[{type:"path",pathType:"|",items:W.iris}]}}function z(W){return{type:"path",pathType:"+",items:[_(W.path)]}}function Y(W){return{type:"path",pathType:"/",items:W.input.map(_)}}function te(W){return{type:"path",pathType:"*",items:[_(W.path)]}}function ce(W){return{type:"path",pathType:"?",items:[_(W.path)]}}function Ae(W){const we=W.updates.map(Te=>g(Te).updates[0]);return{prefixes:{},type:"update",updates:we}}function Ie(W){var we;let Te=W.where,Le;if(Te&&Te.type===d.FROM){let We=Te;Te=We.input,Le={default:We.default,named:We.named}}const $e=[{updateType:"insertdelete",delete:Qe(W.delete||[]),insert:Qe(W.insert||[])}];if(Le&&($e[0].using=Le),!Te||Te.type===d.BGP&&Te.patterns.length===0)$e[0].where=[];else{const We=[];let tt=g(me(Te,We));if(tt.type==="group"?$e[0].where=tt.patterns:$e[0].where=[tt],We.length>0){if(We.length!==1)throw new Error("This is unexpected and might indicate an error in graph handling for updates.");((we=We[0])===null||we===void 0?void 0:we.value)!==""&&($e[0].where=[{type:"graph",patterns:$e[0].where,name:We[0]}])}}return!W.delete&&!W.where?($e[0].updateType="insert",delete $e[0].delete,delete $e[0].where):!W.insert&&!W.where?(delete $e[0].insert,delete $e[0].where,W.delete.some(We=>We.subject.termType==="Variable"||We.predicate.termType==="Variable"||We.object.termType==="Variable")?$e[0].updateType="deletewhere":$e[0].updateType="delete"):!W.insert&&W.where&&W.where.type==="bgp"&&(0,n.isomorphic)(W.delete,W.where.patterns)&&(delete $e[0].where,$e[0].updateType="deletewhere"),{prefixes:{},type:"update",updates:$e}}function Ee(W){const we=[{type:"load",silent:!!W.silent,source:W.source}];return W.destination&&(we[0].destination=W.destination),{prefixes:{},type:"update",updates:we}}function qe(W){return H(W,"clear")}function G(W){return H(W,"create")}function F(W){return H(W,"drop")}function H(W,we){const Te=[{type:we,silent:!!W.silent}];return W.source==="DEFAULT"?Te[0].graph={default:!0}:W.source==="NAMED"?Te[0].graph={named:!0}:W.source==="ALL"?Te[0].graph={all:!0}:Te[0].graph={type:"graph",name:W.source},{prefixes:{},type:"update",updates:Te}}function re(W){return Ce(W,"add")}function be(W){return Ce(W,"move")}function Re(W){return Ce(W,"copy")}function Ce(W,we){const Te=[{type:we,silent:!!W.silent}];return Te[0].source=W.source==="DEFAULT"?{type:"graph",default:!0}:{type:"graph",name:W.source},Te[0].destination=W.destination==="DEFAULT"?{type:"graph",default:!0}:{type:"graph",name:W.destination},{prefixes:{},type:"update",updates:Te}}function Qe(W){if(!W)return[];const we={};return W.forEach(Te=>{const Le=Te.graph.value;we[Le]||(we[Le]=[]),we[Le].push(Te)}),Object.keys(we).map(Te=>Te===""?{type:"bgp",triples:we[Te].map(Ne)}:{type:"graph",triples:we[Te].map(Ne),name:we[Te][0].graph})}function ke(W){return me(W,[])}function me(W,we){if(Array.isArray(W))return W.map(tt=>me(tt,we));if(!W.type||W.type===d.DELETE_INSERT)return W;if((W.type===d.PATTERN||W.type===d.PATH)&&W.graph)return we.push(W.graph),W.graph.name!==""?W.type===d.PATTERN?p.createPattern(W.subject,W.predicate,W.object):p.createPath(W.subject,W.predicate,W.object):W;const Te={},Le={},$e={};for(let tt of Object.keys(W)){const lt=[];if(Te[tt]=me(W[tt],lt),lt.length>0){Le[tt]=lt;for(const ut of lt)$e[ut.value]=ut}}const We=Object.keys($e);if(We.length>0)if(We.length===1&&![d.PROJECT,d.SERVICE].includes(W.type))we.push($e[We[0]]);else{if(W.type===d.BGP)return Se(W,Le.patterns);for(let tt of Object.keys(Le)){const lt=Te[tt];Array.isArray(lt)?Te[tt]=lt.map((ut,le)=>Le[tt][0].value===""?ut:p.createGraph(ut,Le[tt][le])):Le[tt][0].value!==""&&(Te[tt]=p.createGraph(lt,Le[tt][0]))}}return Te}function Se(W,we){var Te;const Le={};for(let tt=0;ttd.termType==="Variable")?(0,u.mapTermsNested)(l,d=>a(d,c)):l}ys.materializeTerm=a;function o(l,c,d,h={}){return h={strictTargetVariables:"strictTargetVariables"in h?h.strictTargetVariables:!1,bindFilter:"bindFilter"in h?h.bindFilter:!0},s.Util.mapOperation(l,{path(f,p){return{recurse:!1,result:Object.assign(p.createPath(a(f.subject,c),f.predicate,a(f.object,c),a(f.graph,c)),{metadata:f.metadata})}},pattern(f,p){return{recurse:!1,result:Object.assign(p.createPattern(a(f.subject,c),a(f.predicate,c),a(f.object,c),a(f.graph,c)),{metadata:f.metadata})}},extend(f){if(c.has(f.variable)){if(h.strictTargetVariables)throw new Error(`Tried to bind variable ${(0,e.termToString)(f.variable)} in a BIND operator.`);return{recurse:!0,result:o(f.input,c,d,h)}}return{recurse:!0,result:f}},group(f,p){if(h.strictTargetVariables){for(const b of f.variables)if(c.has(b))throw new Error(`Tried to bind variable ${(0,e.termToString)(b)} in a GROUP BY operator.`);return{recurse:!0,result:f}}const y=f.variables.filter(b=>!c.has(b));return{recurse:!0,result:p.createGroup(f.input,y,f.aggregates)}},project(f,p){if(h.strictTargetVariables){for(const m of f.variables)if(c.has(m))throw new Error(`Tried to bind variable ${(0,e.termToString)(m)} in a SELECT operator.`);return{recurse:!0,result:f}}const y=f.variables.filter(m=>!c.has(m)),b=d.bindings(f.variables.map(m=>{const g=c.get(m);if(g)return[m,g]}).filter(Boolean));return{recurse:!1,result:p.createProject(o(f.input,b,d,h),y)}},values(f,p){if(h.strictTargetVariables){for(const y of f.variables)if(c.has(y))throw new Error(`Tried to bind variable ${(0,e.termToString)(y)} in a VALUES operator.`)}else{const y=f.variables.filter(m=>!c.has(m)),b=f.bindings.map(m=>{const g={...m};let v=!0;return c.forEach((_,w)=>{const S=(0,e.termToString)(w);S in g&&(_.equals(g[S])||(v=!1),delete g[S])}),v?g:void 0}).filter(Boolean);return{recurse:!0,result:p.createValues(y,b)}}return{recurse:!1,result:f}},expression(f,p){if(!h.bindFilter)return{recurse:!1,result:f};if(f.expressionType==="term")return{recurse:!1,result:p.createTermExpression(a(f.term,c))};if(f.expressionType==="operator")return f.operator==="bound"&&f.args.length===1&&f.args[0].expressionType==="term"&&[...c.keys()].some(y=>f.args[0].term.equals(y))?{recurse:!1,result:p.createTermExpression(r)}:{recurse:!0,result:f};if(f.expressionType==="aggregate"&&"variable"in f&&c.has(f.variable)){if(h.strictTargetVariables)throw new Error(`Tried to bind ${(0,e.termToString)(f.variable)} in a ${f.aggregator} aggregate.`);return{recurse:!0,result:f}}return{recurse:!0,result:f}}})}return ys.materializeOperation=o,ys}var qO;function BF(){if(qO)return mu;qO=1,Object.defineProperty(mu,"__esModule",{value:!0}),mu.ActorQueryOperation=void 0;const t=Lt,e=ot,u=ET(),s=qF();let n=0,r=class qi extends e.Actor{constructor(o){super(o)}static getSafeBindings(o){return qi.validateQueryOutput(o,"bindings"),o}static getSafeQuads(o){return qi.validateQueryOutput(o,"quads"),o}static getSafeBoolean(o){return qi.validateQueryOutput(o,"boolean"),o}static getSafeVoid(o){return qi.validateQueryOutput(o,"void"),o}static validateQueryOutput(o,l){if(o.type!==l)throw new Error(`Invalid query output type: Expected '${l}' but got '${o.type}'`)}static getBaseExpressionContext(o){const l=o.get(t.KeysInitQuery.queryTimestamp),c=o.get(t.KeysInitQuery.baseIRI),d=o.get(t.KeysInitQuery.functionArgumentsCache)??{};if(o.has(t.KeysInitQuery.extensionFunctionCreator)&&o.has(t.KeysInitQuery.extensionFunctions))throw new Error("Illegal simultaneous usage of extensionFunctionCreator and extensionFunctions in context");let h=o.get(t.KeysInitQuery.extensionFunctionCreator);const f=o.get(t.KeysInitQuery.extensionFunctions);return f&&(h=p=>f[p.value]),{now:l,baseIRI:c,extensionFunctionCreator:h,functionArgumentsCache:d}}static getExpressionContext(o,l){return{...this.getBaseExpressionContext(o),bnode:c=>new u.BlankNodeBindingsScoped(c??`BNODE_${n++}`)}}static getAsyncExpressionContext(o,l,c){return{...this.getBaseExpressionContext(o),bnode:d=>Promise.resolve(new u.BlankNodeBindingsScoped(d??`BNODE_${n++}`)),exists:qi.createExistenceResolver(o,l,c)}}static createExistenceResolver(o,l,c){return async(d,h)=>{const f=(0,s.materializeOperation)(d.input,h,c),p=await l.mediate({operation:f,context:o}),y=qi.getSafeBindings(p);return d.not!==((await y.bindingsStream.take(1).toArray()).length===1)}}static throwOnReadOnly(o){if(o.get(t.KeysQueryOperation.readOnly))throw new Error("Attempted a write operation in read-only mode")}static getOperationSource(o){var l;return(l=o.metadata)==null?void 0:l.scopedSource}static assignOperationSource(o,l){return o={...o},o.metadata=o.metadata?{...o.metadata}:{},o.metadata.scopedSource=l,o}static removeOperationSource(o){var l;(l=o.metadata)==null||delete l.scopedSource,o.metadata&&Object.keys(o.metadata).length===0&&delete o.metadata}static doesShapeAcceptOperation(o,l,c){return o.type==="conjunction"?o.children.every(d=>qi.doesShapeAcceptOperation(d,l,c)):o.type==="disjunction"?o.children.some(d=>qi.doesShapeAcceptOperation(d,l,c)):o.type==="arity"?qi.doesShapeAcceptOperation(o.child,l,c):((c==null?void 0:c.joinBindings)&&!o.joinBindings)??((c==null?void 0:c.filterBindings)&&!o.filterBindings)?!1:o.operation.operationType==="type"?o.operation.type==="project"||o.operation.type===l.type:o.operation.pattern.type===l.type}};return mu.ActorQueryOperation=r,mu}var xu={},bm={},Iu={},BO;function UV(){if(BO)return Iu;BO=1,Object.defineProperty(Iu,"__esModule",{value:!0}),Iu.MetadataValidationState=void 0;let t=class{constructor(){this.invalidateListeners=[],this.valid=!0}addInvalidateListener(u){this.invalidateListeners.push(u)}invalidate(){if(this.valid){this.valid=!1;for(const u of this.invalidateListeners)u()}}};return Iu.MetadataValidationState=t,Iu}var kn={},UO;function HV(){if(UO)return kn;UO=1,Object.defineProperty(kn,"__esModule",{value:!0}),kn.cachifyMetadata=kn.validateMetadataBindings=kn.validateMetadataQuads=kn.getMetadataBindings=kn.getMetadataQuads=void 0;function t(r){return n(()=>new Promise((a,o)=>{r.getProperty("metadata",l=>a(l)),r.on("error",o)}).then(a=>u(a)))}kn.getMetadataQuads=t;function e(r){return n(()=>new Promise((a,o)=>{r.getProperty("metadata",l=>a(l)),r.on("error",o)}).then(a=>("canContainUndefs"in a||(a.canContainUndefs=!1),s(a))))}kn.getMetadataBindings=e;function u(r){for(const a of["cardinality"])if(!(a in r))throw new Error(`Invalid metadata: missing ${a} in ${JSON.stringify(r)}`);return r}kn.validateMetadataQuads=u;function s(r){for(const a of["cardinality","canContainUndefs","variables"])if(!(a in r))throw new Error(`Invalid metadata: missing ${a} in ${JSON.stringify(r)}`);return r}kn.validateMetadataBindings=s;function n(r){let a;return()=>(a||(a=r(),a.then(o=>o.state.addInvalidateListener(()=>{a=void 0})).catch(()=>{})),a)}return kn.cachifyMetadata=n,kn}var HO;function jn(){return HO||(HO=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(UV(),t),u(HV(),t)}(bm)),bm}var $O;function UF(){if($O)return xu;$O=1,Object.defineProperty(xu,"__esModule",{value:!0}),xu.ActorQueryOperationTyped=void 0;const t=Lt,e=jn(),u=BF();let s=class extends u.ActorQueryOperation{constructor(r,a){if(super({...r,operationName:a}),!this.operationName)throw new Error('A valid "operationName" argument must be provided.')}async test(r){if(!r.operation)throw new Error("Missing field 'operation' in a query operation action.");if(r.operation.type!==this.operationName)throw new Error(`Actor ${this.name} only supports ${this.operationName} operations, but got ${r.operation.type}`);const a=r.operation;return this.testOperation(a,r.context)}async run(r){const a=r.context.get(t.KeysInitQuery.physicalQueryPlanLogger);a&&(a.logOperation(r.operation.type,void 0,r.operation,r.context.get(t.KeysInitQuery.physicalQueryPlanNode),this.name,{}),r.context=r.context.set(t.KeysInitQuery.physicalQueryPlanNode,r.operation));const o=r.operation,l=r.context.set(t.KeysQueryOperation.operation,o),c=await this.runOperation(o,l);return"metadata"in c&&(c.metadata=(0,e.cachifyMetadata)(c.metadata)),c}};return xu.ActorQueryOperationTyped=s,xu}var Pu={},QO;function $V(){if(QO)return Pu;QO=1,Object.defineProperty(Pu,"__esModule",{value:!0}),Pu.ActorQueryOperationTypedMediated=void 0;const t=UF();let e=class extends t.ActorQueryOperationTyped{constructor(s,n){super(s,n)}};return Pu.ActorQueryOperationTypedMediated=e,Pu}var Du={},VO;function QV(){if(VO)return Du;VO=1,Object.defineProperty(Du,"__esModule",{value:!0}),Du.BusQueryOperation=void 0;const t=ot;let e=class extends t.BusIndexed{constructor(s){super({...s,actorIdentifierFields:["operationName"],actionIdentifierFields:["operation","type"]})}};return Du.BusQueryOperation=e,Du}var Nu={},gm={},n1={exports:{}},kO;function wy(){if(kO)return n1.exports;kO=1;var t=typeof Reflect=="object"?Reflect:null,e=t&&typeof t.apply=="function"?t.apply:function(S,A,D){return Function.prototype.apply.call(S,A,D)},u;t&&typeof t.ownKeys=="function"?u=t.ownKeys:Object.getOwnPropertySymbols?u=function(S){return Object.getOwnPropertyNames(S).concat(Object.getOwnPropertySymbols(S))}:u=function(S){return Object.getOwnPropertyNames(S)};function s(w){console&&console.warn&&console.warn(w)}var n=Number.isNaN||function(S){return S!==S};function r(){r.init.call(this)}n1.exports=r,n1.exports.once=g,r.EventEmitter=r,r.prototype._events=void 0,r.prototype._eventsCount=0,r.prototype._maxListeners=void 0;var a=10;function o(w){if(typeof w!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof w)}Object.defineProperty(r,"defaultMaxListeners",{enumerable:!0,get:function(){return a},set:function(w){if(typeof w!="number"||w<0||n(w))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+w+".");a=w}}),r.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},r.prototype.setMaxListeners=function(S){if(typeof S!="number"||S<0||n(S))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+S+".");return this._maxListeners=S,this};function l(w){return w._maxListeners===void 0?r.defaultMaxListeners:w._maxListeners}r.prototype.getMaxListeners=function(){return l(this)},r.prototype.emit=function(S){for(var A=[],D=1;D0&&(O=A[0]),O instanceof Error)throw O;var P=new Error("Unhandled error."+(O?" ("+O.message+")":""));throw P.context=O,P}var j=E[S];if(j===void 0)return!1;if(typeof j=="function")e(j,this,A);else for(var U=j.length,M=y(j,U),D=0;D0&&O.length>L&&!O.warned){O.warned=!0;var P=new Error("Possible EventEmitter memory leak detected. "+O.length+" "+String(S)+" listeners added. Use emitter.setMaxListeners() to increase limit");P.name="MaxListenersExceededWarning",P.emitter=w,P.type=S,P.count=O.length,s(P)}return w}r.prototype.addListener=function(S,A){return c(this,S,A,!1)},r.prototype.on=r.prototype.addListener,r.prototype.prependListener=function(S,A){return c(this,S,A,!0)};function d(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function h(w,S,A){var D={fired:!1,wrapFn:void 0,target:w,type:S,listener:A},L=d.bind(D);return L.listener=A,D.wrapFn=L,L}r.prototype.once=function(S,A){return o(A),this.on(S,h(this,S,A)),this},r.prototype.prependOnceListener=function(S,A){return o(A),this.prependListener(S,h(this,S,A)),this},r.prototype.removeListener=function(S,A){var D,L,E,O,P;if(o(A),L=this._events,L===void 0)return this;if(D=L[S],D===void 0)return this;if(D===A||D.listener===A)--this._eventsCount===0?this._events=Object.create(null):(delete L[S],L.removeListener&&this.emit("removeListener",S,D.listener||A));else if(typeof D!="function"){for(E=-1,O=D.length-1;O>=0;O--)if(D[O]===A||D[O].listener===A){P=D[O].listener,E=O;break}if(E<0)return this;E===0?D.shift():b(D,E),D.length===1&&(L[S]=D[0]),L.removeListener!==void 0&&this.emit("removeListener",S,P||A)}return this},r.prototype.off=r.prototype.removeListener,r.prototype.removeAllListeners=function(S){var A,D,L;if(D=this._events,D===void 0)return this;if(D.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):D[S]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete D[S]),this;if(arguments.length===0){var E=Object.keys(D),O;for(L=0;L=0;L--)this.removeListener(S,A[L]);return this};function f(w,S,A){var D=w._events;if(D===void 0)return[];var L=D[S];return L===void 0?[]:typeof L=="function"?A?[L.listener||L]:[L]:A?m(L):y(L,L.length)}r.prototype.listeners=function(S){return f(this,S,!0)},r.prototype.rawListeners=function(S){return f(this,S,!1)},r.listenerCount=function(w,S){return typeof w.listenerCount=="function"?w.listenerCount(S):p.call(w,S)},r.prototype.listenerCount=p;function p(w){var S=this._events;if(S!==void 0){var A=S[w];if(typeof A=="function")return 1;if(A!==void 0)return A.length}return 0}r.prototype.eventNames=function(){return this._eventsCount>0?u(this._events):[]};function y(w,S){for(var A=new Array(S),D=0;Dt.then(a),s=typeof setImmediate=="function"?setImmediate:a=>setTimeout(a,0);let n=0,r=null;return a=>{r!==null?r.push(a):++n<100?u(a):(r=[a],s(()=>{for(const o of r)u(o);r=null,n=0}))}}return ju.createTaskScheduler=e,ju}var WO;function Nt(){return WO||(WO=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.isIterator=t.isIterable=t.isSourceExpression=t.isPromise=t.isEventEmitter=t.isFunction=t.range=t.union=t.fromIterable=t.fromIterator=t.fromArray=t.single=t.empty=t.wrap=t.WrappingIterator=t.ClonedIterator=t.UnionIterator=t.MultiTransformIterator=t.SimpleTransformIterator=t.TransformIterator=t.BufferedIterator=t.MappingIterator=t.DESTINATION=t.identity=t.IntegerIterator=t.ArrayIterator=t.SingletonIterator=t.EmptyIterator=t.AsyncIterator=t.DESTROYED=t.ENDED=t.CLOSED=t.CLOSING=t.OPEN=t.INIT=t.setTaskScheduler=t.getTaskScheduler=t.scheduleTask=t.LinkedList=void 0;const e=wy(),u=VV();Object.defineProperty(t,"LinkedList",{enumerable:!0,get:function(){return u.LinkedList}});let n=kV().createTaskScheduler();function r(R){n(R)}t.scheduleTask=r;function a(){return n}t.getTaskScheduler=a;function o(R){n=R}t.setTaskScheduler=o,t.INIT=1,t.OPEN=2,t.CLOSING=4,t.CLOSED=8,t.ENDED=16,t.DESTROYED=32;class l extends e.EventEmitter{constructor(T=t.OPEN){super(),this._readable=!1,this._state=T,this.on("newListener",c)}_changeState(T,x=!1){const B=T>this._state&&this._statethis.emit("end")):this.emit("end"))),B}read(){return null}forEach(T,x){this.on("data",Oe(T,x))}close(){this._changeState(t.CLOSED)&&this._endAsync()}destroy(T){this.done||this._destroy(T,x=>{T=T||x,T&&this.emit("error",T),this._end(!0)})}_destroy(T,x){x()}_end(T=!1){this._changeState(T?t.DESTROYED:t.ENDED)&&(this._readable=!1,this.removeAllListeners("readable"),this.removeAllListeners("data"),this.removeAllListeners("end"))}_endAsync(){n(()=>this._end())}get readable(){return this._readable}set readable(T){T=!!T&&!this.done,this._readable!==T&&(this._readable=T,T&&n(()=>this.emit("readable")))}get closed(){return this._state>=t.CLOSING}get ended(){return this._state===t.ENDED}get destroyed(){return this._state===t.DESTROYED}get done(){return this._state>=t.ENDED}toString(){const T=this._toStringDetails();return`[${this.constructor.name}${T?` ${T}`:""}]`}_toStringDetails(){return""}toArray(T){const x=[],B=typeof(T==null?void 0:T.limit)=="number"?T.limit:1/0;return this.ended||B<=0?Promise.resolve(x):new Promise((k,V)=>{const J=()=>k(x),z=Y=>{x.push(Y),x.length>=B&&(this.removeListener("error",V),this.removeListener("data",z),this.removeListener("end",J),k(x))};this.on("error",V),this.on("data",z),this.on("end",J)})}getProperty(T,x){const B=this._properties;if(!x)return B&&B[T];if(B&&T in B)n(()=>x(B[T]));else{let k;(k=this._propertyCallbacks)||(this._propertyCallbacks=k=Object.create(null)),T in k?k[T].push(x):k[T]=[x]}}setProperty(T,x){const B=this._properties||(this._properties=Object.create(null));B[T]=x;const k=this._propertyCallbacks||{},V=k[T];if(V){delete k[T],n(()=>{for(const J of V)J(x)});for(T in k)return;delete this._propertyCallbacks}}getProperties(){const T=this._properties,x={};for(const B in T)x[B]=T[B];return x}setProperties(T){for(const x in T)this.setProperty(x,T[x])}copyProperties(T,x){for(const B of x)T.getProperty(B,k=>this.setProperty(B,k))}transform(T){return new O(this,T)}map(T,x){return new g(this,Oe(T,x))}filter(T,x){return this.map(function(B){return T.call(x||this,B)?B:null})}uniq(T=m){const x=new Set;return this.filter(function(B){const k=T.call(this,B);return x.has(k)?!1:(x.add(k),!0)})}prepend(T){return this.transform({prepend:T})}append(T){return this.transform({append:T})}surround(T,x){return this.transform({prepend:T,append:x})}skip(T){return this.map(x=>T-- >0?null:x)}take(T){return this.transform({limit:T})}range(T,x){return this.transform({offset:T,limit:Math.max(x-T+1,0)})}clone(){return new M(this)}[Symbol.asyncIterator](){const T=this;let x=null,B=null,k=null;T.addListener("readable",V),T.addListener("end",V),T.addListener("error",J);function V(){if(x!==null)if(k!==null)J(k);else if(T.done)x({done:!0,value:void 0}),x=B=null,z();else{const Y=T.read();Y!==null&&(x({done:!1,value:Y}),x=B=null)}}function J(Y){B!==null?(B(Y),x=B=k=null,z()):k===null&&(k=Y)}function z(){T.removeListener("readable",V),T.removeListener("end",V),T.removeListener("error",J)}return{next(){return new Promise((Y,te)=>{x=Y,B=te,V()})}}}}t.AsyncIterator=l;function c(R){R==="data"&&(this.removeListener("newListener",c),h(this,"readable",d),this.readable&&n(()=>d.call(this)))}function d(){let R;for(;this.listenerCount("data")!==0&&(R=this.read())!==null;)this.emit("data",R);this.listenerCount("data")===0&&!this.done&&(this.removeListener("readable",d),h(this,"newListener",c))}function h(R,T,x){R.listeners(T).includes(x)||R.on(T,x)}class f extends l{constructor(){super(),this._changeState(t.ENDED,!0)}}t.EmptyIterator=f;class p extends l{constructor(T){super(),this._item=T,T===null?this.close():this.readable=!0}read(){const T=this._item;return this._item=null,this.close(),T}_toStringDetails(){return this._item===null?"":`(${this._item})`}}t.SingletonIterator=p;class y extends l{constructor(T=[],{autoStart:x=!0,preserve:B=!0}={}){super();const k=B||!Array.isArray(T)?[...T]:T;this._index=0,this._sourceStarted=x!==!1,this._truncateThreshold=B?-1:64,this._sourceStarted&&k.length===0?this.close():this._buffer=k,this.readable=!0}read(){this._sourceStarted||(this._sourceStarted=!0);let T=null;return this._buffer&&(this._index=x&&this.close(),Promise.resolve(V)}}t.ArrayIterator=y;class b extends l{constructor({start:T=0,step:x=1,end:B}={}){super(),Number.isFinite(T)&&(T=Math.trunc(T)),this._next=T,Number.isFinite(x)&&(x=Math.trunc(x)),this._step=x;const k=x>=0,V=k?1/0:-1/0;Number.isFinite(B)?B=Math.trunc(B):B!==-V&&(B=V),this._last=B,!Number.isFinite(T)||(k?T>B:T=0?k>B:kthis._init(x)),this._sourceStarted=x!==!1}get maxBufferSize(){return this._maxBufferSize}set maxBufferSize(T){T!==1/0&&(T=Number.isFinite(T)?Math.max(Math.trunc(T),1):4),this._maxBufferSize!==T&&(this._maxBufferSize=T,this._state===t.OPEN&&this._fillBuffer())}_init(T){let x=!1;this._reading=!0,this._begin(()=>{if(x)throw new Error("done callback called multiple times");x=!0,this._reading=!1,this._changeState(t.OPEN),T?this._fillBufferAsync():this.readable=!0})}_begin(T){T()}read(){if(this.done)return null;this._sourceStarted||(this._sourceStarted=!0);const T=this._buffer;let x;return T.empty?(x=null,this.readable=!1):x=T.shift(),!this._reading&&T.length0&&(this._pushedCount=0,this._reading=!0,this._read(T,()=>{if(!T)throw new Error("done callback called multiple times");T=0,this._reading=!1,this.closed?this._completeClose():this._pushedCount&&(this.readable=!0,this._buffer.length{this._reading=!1,this._fillBuffer()}))}close(){this._reading?this._changeState(t.CLOSING):this._completeClose()}_completeClose(){this._changeState(t.CLOSED)&&(this._reading=!0,this._flush(()=>{if(!this._reading)throw new Error("done callback called multiple times");this._reading=!1,this._buffer.empty&&this._endAsync()}))}_destroy(T,x){this._buffer.clear(),x()}_flush(T){T()}_toStringDetails(){const T=this._buffer;return`{${T.empty?"":`next: ${T.first}, `}buffer: ${T.length}}`}}t.BufferedIterator=_;class w extends _{constructor(T,x=T||{}){super(x),this._boundPush=B=>this._push(B),oe(T)||(T=x.source),ge(T)?this.source=T:T&&(this._createSource=de(T)?()=>T:T,this._sourceStarted&&this._loadSourceAsync()),this._optional=!!x.optional,this._destroySource=x.destroySource!==!1}get source(){return Ne(this._createSource)&&this._loadSourceAsync(),this._source}set source(T){const x=this._source=this._validateSource(T);x[t.DESTINATION]=this,this.done?this._destroySource&&x.destroy():x.done?this.close():(x.on("end",L),x.on("readable",E),x.on("error",A))}_loadSourceAsync(){Ne(this._createSource)&&(Promise.resolve(this._createSource()).then(T=>{delete this._createSource,this.source=T,this._fillBuffer()},T=>this.emit("error",T)),this._createSource=null)}_validateSource(T,x=!1){if(this._source||typeof this._createSource<"u")throw new Error("The source cannot be changed after it has been set");return v(T,x)}_read(T,x){const B=()=>{this._pushedCountthis._readAndTransform(B,x)):x()};this._readAndTransform(B,x)}_readAndTransform(T,x){let B;const k=this.source;!k||k.done||(B=k.read())===null?x():this._optional?this._optionalTransform(B,T):this._transform(B,T,this._boundPush)}_optionalTransform(T,x){const B=this._pushedCount;this._transform(T,()=>{B===this._pushedCount&&this._push(T),x()},this._boundPush)}_transform(T,x,B){B(T),x()}_closeWhenDone(){this.close()}_end(T){const x=this._source;x&&(x.removeListener("end",L),x.removeListener("error",A),x.removeListener("readable",E),delete x[t.DESTINATION],this._destroySource&&x.destroy()),super._end(T)}}t.TransformIterator=w;function S(){this[t.DESTINATION].readable=!0}function A(R){this[t.DESTINATION].emit("error",R)}function D(){this[t.DESTINATION].close()}function L(){this[t.DESTINATION]._closeWhenDone()}function E(){this[t.DESTINATION]._sourceStarted!==!1&&this[t.DESTINATION]._fillBuffer()}class O extends w{constructor(T,x){if(super(T,x),this._offset=0,this._limit=1/0,this._filter=B=>!0,x=x||(oe(T)?null:T),x){const B=Ne(x)?x:x.transform,{limit:k,offset:V,filter:J,map:z,prepend:Y,append:te}=x;V===1/0||k===-1/0?this._limit=0:(Number.isFinite(V)&&(this._offset=Math.max(Math.trunc(V),0)),Number.isFinite(k)&&(this._limit=Math.max(Math.trunc(k),0)),Ne(J)&&(this._filter=J),Ne(z)&&(this._map=z),this._transform=Ne(B)?B:null),Y&&(this._prepender=ge(Y)?Y:X(Y)),te&&(this._appender=ge(te)?te:X(te))}}_read(T,x){const B=()=>this._readAndTransformSimple(T,k,x);this._readAndTransformSimple(T,k,x);function k(){n(B)}}_readAndTransformSimple(T,x,B){let k;const{source:V}=this;if(!V||V.done){B();return}for(this._limit===0&&this.close();!this.closed&&this._pushedCount"u"?k:this._map(k);if(J===null)this._optional&&this._push(k);else if(!Ne(this._transform))this._push(J);else{this._optional?this._optionalTransform(J,x):this._transform(J,x,this._boundPush);return}--this._limit===0&&this.close()}B()}_begin(T){this._insert(this._prepender,T),delete this._prepender}_flush(T){this._insert(this._appender,T),delete this._appender}_insert(T,x){const B=V=>this._push(V);!T||T.done?x():(T.on("data",B),T.on("end",k));function k(){T.removeListener("data",B),T.removeListener("end",k),x()}}}t.SimpleTransformIterator=O;class P extends w{constructor(T,x){if(super(T,x),this._transformerQueue=[],x){const B=Ne(x)?x:x.multiTransform;B&&(this._createTransformer=B)}}_read(T,x){const B=this._transformerQueue,k=this._optional;let V,J;for(;(V=B[0])&&V.transformer.done;){k&&V.item!==null&&(T--,this._push(V.item)),B.shift();const{transformer:Y}=V;Y.removeListener("end",E),Y.removeListener("readable",E),Y.removeListener("error",A)}const{source:z}=this;for(;z&&!z.done&&B.length0&&(J=Y.read())!==null;)this._push(J),k&&(V.item=null)}else z&&z.done&&this.close();x()}_createTransformer(T){return new p(T)}_closeWhenDone(){this._transformerQueue.length||this.close()}_end(T){if(super._end(T),this._destroySource)for(const x of this._transformerQueue)x.transformer.destroy()}}t.MultiTransformIterator=P;class j extends _{constructor(T,x={}){super(x),this._sources=[],this._currentSource=-1;const B=x.autoStart!==!1;if(ge(T))T.on("error",k=>this.emit("error",k)),this._pending={loading:!1,sources:T},B&&this._loadSources();else if(Array.isArray(T)&&T.length>0)for(const k of T)this._addSource(k);else B&&this.close();this._destroySources=x.destroySources!==!1}_loadSources(){const T=this._pending.sources;this._pending.loading=!0,T.done?(delete this._pending,this.close()):(T.on("data",x=>{this._addSource(x),this._fillBufferAsync()}),T.on("end",()=>{delete this._pending,this._fillBuffer()}))}_addSource(T){de(T)&&(T=Z(T)),T.done||(this._sources.push(T),T[t.DESTINATION]=this,T.on("error",A),T.on("readable",E),T.on("end",U))}_removeEmptySources(){this._sources=this._sources.filter((T,x)=>(T.done&&x<=this._currentSource&&this._currentSource--,!T.done)),this._fillBuffer()}_read(T,x){var B;((B=this._pending)===null||B===void 0?void 0:B.loading)===!1&&this._loadSources();let k=0,V;for(;k!==(k=T);)for(let J=0;J0;J++)this._currentSource=(this._currentSource+1)%this._sources.length,(V=this._sources[this._currentSource].read())!==null&&(T--,this._push(V));!this._pending&&this._sources.length===0&&this.close(),x()}_end(T=!1){if(super._end(T),this._destroySources){for(const x of this._sources)x.destroy();this._pending&&(this._pending.sources.destroy(),delete this._pending)}}}t.UnionIterator=j;function U(){this[t.DESTINATION]._removeEmptySources()}class M extends w{constructor(T){super(T,{autoStart:!1}),this._readPosition=0,this._reading=!1,T&&(this.readable=!0)}_init(){}close(){l.prototype.close.call(this)}get source(){return super.source}set source(T){const x=this._source=this._validateSource(T),B=x&&x[t.DESTINATION]||(x[t.DESTINATION]=new q(x));this.done?this._destroySource&&x.destroy():B.endsAt(0)?this.close():(B.register(this),(x._sourceStarted===!1||B.readAt(0)!==null)&&(this.readable=!0));const k=this._propertyCallbacks;for(const V in k){const J=k[V];for(const z of J)this._getSourceProperty(V,z)}}_validateSource(T,x=!1){const B=T&&T[t.DESTINATION];return super._validateSource(T,!B||B instanceof q)}getProperty(T,x){const{source:B}=this,k=this._properties,V=k&&T in k;if(!x)return V?k&&k[T]:B&&B.getProperty(T);super.getProperty(T,x),B&&!V&&this._getSourceProperty(T,x)}_getSourceProperty(T,x){this.source.getProperty(T,B=>{(!this._properties||!(T in this._properties))&&x(B)})}getProperties(){const T=this.source?this.source.getProperties():{},x=this._properties;for(const B in x)T[B]=x[B];return T}_toStringDetails(){return`{source: ${this.source?this.source.toString():"none"}}`}read(){this._sourceStarted||(this._sourceStarted=!0);const T=this.source;let x=null;if(!this.done&&T){const B=T[t.DESTINATION];(x=B.readAt(this._readPosition))!==null?this._readPosition++:this.readable=!1,B.endsAt(this._readPosition)&&this.close()}return x}_end(T){const x=this.source,B=x==null?void 0:x[t.DESTINATION];B&&B.unregister(this),_.prototype._end.call(this,T)}}t.ClonedIterator=M;class q{constructor(T){if(this._history=[],this._trackers=new Set,this._source=T,!T.done){const x=()=>{for(const V of this._trackers)V.readable=!0},B=V=>{for(const J of this._trackers)J.emit("error",V)},k=()=>{for(const V of this._trackers)V._sourceStarted!==!1&&V._readPosition===this._history.length&&V.close();this._trackers.clear(),T.removeListener("end",k),T.removeListener("error",B),T.removeListener("readable",x)};T.on("end",k),T.on("error",B),T.on("readable",x)}}register(T){this._source.done||this._trackers.add(T)}unregister(T){this._trackers.delete(T)}readAt(T){let x=null;return T{this._source=null,this.source=B}).catch(B=>this.emit("error",B))):T&&(this.source=T)}set source(T){let x=T;if(this._source!==null)throw new Error("The source cannot be changed after it has been set");if($(x)&&(x=x[Symbol.iterator]()),N(x)){let B=x;x=new e.EventEmitter,x.read=()=>{if(B!==null){let k;for(;!(k=B.next()).done;)if(k.value!==null)return k.value;B=null,this.close()}return null}}else x=v(x);if(this.done){this._destroySource&&Ne(x.destroy)&&x.destroy();return}x[t.DESTINATION]=this,x.on("end",D),x.on("error",A),x.on("readable",S),this._source=x,this.readable=x.readable!==!1}read(){if(this._source!==null&&this._source.readable!==!1){const T=this._source.read();if(T!==null)return T;this.readable=!1}return null}_end(T=!1){this._source!==null&&(this._source.removeListener("end",D),this._source.removeListener("error",A),this._source.removeListener("readable",S),delete this._source[t.DESTINATION],this._destroySource&&Ne(this._source.destroy)&&this._source.destroy(),this._source=null),super._end(T)}}t.WrappingIterator=Q;function Z(R,T){if(T&&("autoStart"in T||"optional"in T||"source"in T||"maxBufferSize"in T))return R&&!ge(R)&&(R=new Q(R)),new w(R,T);if(!R)return K();if(de(R))return new Q(R,T);if(R instanceof l)return R;if(Array.isArray(R))return X(R);if($(R)||N(R)||ge(R))return new Q(R,T);throw new TypeError(`Invalid source: ${R}`)}t.wrap=Z;function K(){return new f}t.empty=K;function fe(R){return new p(R)}t.single=fe;function X(R){return new y(R)}t.fromArray=X;function he(R){return new Q(R)}t.fromIterator=he;function xe(R){return new Q(R)}t.fromIterable=xe;function ie(R){return new j(R)}t.union=ie;function ae(R,T,x){return new b({start:R,end:T,step:x})}t.range=ae;function Oe(R,T){return T?R.bind(T):R}function Ne(R){return typeof R=="function"}t.isFunction=Ne;function ge(R){return Ne(R==null?void 0:R.on)}t.isEventEmitter=ge;function de(R){return Ne(R==null?void 0:R.then)}t.isPromise=de;function oe(R){return R&&(ge(R)||de(R)||Ne(R))}t.isSourceExpression=oe;function $(R){return R&&Symbol.iterator in R}t.isIterable=$;function N(R){return Ne(R==null?void 0:R.next)}t.isIterator=N}(gm)),gm}var JO;function zV(){if(JO)return Nu;JO=1,Object.defineProperty(Nu,"__esModule",{value:!0}),Nu.ClosableTransformIterator=void 0;const t=Nt();let e=class extends t.TransformIterator{constructor(s,n){super(s,n),this.onClose=n.onClose}_end(s){this.onClose(),super._end(s)}};return Nu.ClosableTransformIterator=e,Nu}var XO;function wt(){return XO||(XO=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(BF(),t),u(UF(),t),u($V(),t),u(qF(),t),u(QV(),t),u(zV(),t)}(Gg)),Gg}var mm={},Lu={},_m={},Mu={},KO;function GV(){if(KO)return Mu;KO=1,Object.defineProperty(Mu,"__esModule",{value:!0}),Mu.ActorContextPreprocess=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return Mu.ActorContextPreprocess=e,Mu}var YO;function Sy(){return YO||(YO=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(GV(),t)}(_m)),_m}var ZO;function WV(){if(ZO)return Lu;ZO=1,Object.defineProperty(Lu,"__esModule",{value:!0}),Lu.ActorContextPreprocessConvertShortcuts=void 0;const t=Sy(),e=ot;let u=class HF extends t.ActorContextPreprocess{constructor(n){super(n)}async test(n){return!0}async run(n){return{context:HF.expandShortcuts(n.context,this.contextKeyShortcuts)}}static expandShortcuts(n,r){for(const a of n.keys())r[a.name]&&(n=n.set(new e.ActionContextKey(r[a.name]),n.get(a)).delete(a));return n}};return Lu.ActorContextPreprocessConvertShortcuts=u,Lu}var eR;function JV(){return eR||(eR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(WV(),t)}(mm)),mm}var vm={},Fu={},tR;function XV(){if(tR)return Fu;tR=1,Object.defineProperty(Fu,"__esModule",{value:!0}),Fu.ActorContextPreprocessSetDefaults=void 0;const t=Sy(),e=Lt;let u=class extends t.ActorContextPreprocess{constructor(n){super(n),this.defaultFunctionArgumentsCache={}}async test(n){return!0}async run(n){let r=n.context;if(n.initialize){r=r.setDefault(e.KeysInitQuery.queryTimestamp,new Date).setDefault(e.KeysQuerySourceIdentify.sourceIds,new Map).setDefault(e.KeysCore.log,this.logger).setDefault(e.KeysInitQuery.functionArgumentsCache,this.defaultFunctionArgumentsCache).setDefault(e.KeysQuerySourceIdentify.hypermediaSourcesAggregatedStores,new Map);let a={language:"sparql",version:"1.1"};r.has(e.KeysInitQuery.queryFormat)?(a=r.get(e.KeysInitQuery.queryFormat),a.language==="graphql"&&(r=r.setDefault(e.KeysInitQuery.graphqlSingularizeVariables,{}))):r=r.set(e.KeysInitQuery.queryFormat,a)}return{context:r}}};return Fu.ActorContextPreprocessSetDefaults=u,Fu}var rR;function KV(){return rR||(rR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(XV(),t)}(vm)),vm}var wm={},qu={},nR;function YV(){if(nR)return qu;nR=1,Object.defineProperty(qu,"__esModule",{value:!0}),qu.ActorContextPreprocessSourceToDestination=void 0;const t=Sy(),e=Lt;let u=class extends t.ActorContextPreprocess{constructor(n){super(n)}async test(n){return!0}async run(n){if(n.context.get(e.KeysInitQuery.querySourcesUnidentified)&&!n.context.get(e.KeysRdfUpdateQuads.destination)){const r=n.context.get(e.KeysInitQuery.querySourcesUnidentified);if(r.length===1)return{context:n.context.set(e.KeysRdfUpdateQuads.destination,r[0])}}return n}};return qu.ActorContextPreprocessSourceToDestination=u,qu}var iR;function ZV(){return iR||(iR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(YV(),t)}(wm)),wm}var Sm={},Bu={},Uu={},Tm={},aR;function IT(){return aR||(aR=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.deskolemizeOperation=t.deskolemizeQuad=t.deskolemizeTermNestedThrowing=t.deskolemizeTerm=t.skolemizeBindingsStream=t.skolemizeQuadStream=t.skolemizeBindings=t.skolemizeQuad=t.skolemizeTerm=t.getSourceId=t.SKOLEM_PREFIX=void 0;const e=ET(),u=Et(),s=un(),n=Ot(),r=new u.DataFactory;t.SKOLEM_PREFIX="urn:comunica_skolem:source_";function a(m,g){let v=m.get(g.referenceValue);return v===void 0&&(v=`${m.size}`,m.set(g.referenceValue,v)),v}t.getSourceId=a;function o(m,g){return m.termType==="BlankNode"?new e.BlankNodeScoped(`bc_${g}_${m.value}`,r.namedNode(`${t.SKOLEM_PREFIX}${g}:${m.value}`)):m}t.skolemizeTerm=o;function l(m,g){return(0,s.mapTermsNested)(m,v=>o(v,g))}t.skolemizeQuad=l;function c(m,g){return m.map(v=>v.termType==="Quad"?l(v,g):o(v,g))}t.skolemizeBindings=c;function d(m,g){const v=m.map(w=>l(w,g));function _(){m.getProperty("metadata",w=>{v.setProperty("metadata",w),w.state.addInvalidateListener(_)})}return _(),v}t.skolemizeQuadStream=d;function h(m,g){const v=m.map(w=>c(w,g));function _(){m.getProperty("metadata",w=>{v.setProperty("metadata",w),w.state.addInvalidateListener(_)})}return _(),v}t.skolemizeBindingsStream=h;function f(m,g){if(m.termType==="BlankNode"&&"skolemized"in m&&(m=m.skolemized),m.termType==="NamedNode"&&m.value.startsWith(t.SKOLEM_PREFIX)){const v=m.value.indexOf(":",t.SKOLEM_PREFIX.length);if(m.value.slice(t.SKOLEM_PREFIX.length,v)===g){const w=m.value.slice(v+1,m.value.length);return r.blankNode(w)}return null}return m}t.deskolemizeTerm=f;function p(m,g){if(m.termType==="Quad")return(0,s.mapTermsNested)(m,_=>{const w=f(_,g);if(!w)throw new Error("Skolemized term is not in scope for this source");return w});const v=f(m,g);if(v===null)throw new Error("Skolemized term is not in scope for this source");return v}t.deskolemizeTermNestedThrowing=p;function y(m,g){return(0,s.mapTermsNested)(m,v=>f(v,g)??v)}t.deskolemizeQuad=y;function b(m,g){try{return n.Util.mapOperation(m,{[n.Algebra.types.PATTERN](v,_){return{result:Object.assign(_.createPattern(p(v.subject,g),p(v.predicate,g),p(v.object,g),p(v.graph,g)),{metadata:v.metadata}),recurse:!1}},[n.Algebra.types.PATH](v,_){return{result:Object.assign(_.createPath(p(v.subject,g),v.predicate,p(v.object,g),p(v.graph,g)),{metadata:v.metadata}),recurse:!1}}})}catch{}}t.deskolemizeOperation=b}(Tm)),Tm}var sR;function $F(){if(sR)return Uu;sR=1,Object.defineProperty(Uu,"__esModule",{value:!0}),Uu.QuerySourceSkolemized=void 0;const t=jn(),e=Nt(),u=IT();let s=class{constructor(r,a){this.innerSource=r,this.sourceId=a}async getSelectorShape(r){return this.innerSource.getSelectorShape(r)}queryBindings(r,a,o){const l=(0,u.deskolemizeOperation)(r,this.sourceId);if(!l){const c=new e.ArrayIterator([],{autoStart:!1});return c.setProperty("metadata",{state:new t.MetadataValidationState,cardinality:{type:"exact",value:0},canContainUndefs:!1,variables:[]}),c}return(0,u.skolemizeBindingsStream)(this.innerSource.queryBindings(l,a,o),this.sourceId)}queryBoolean(r,a){return this.innerSource.queryBoolean(r,a)}queryQuads(r,a){const o=(0,u.deskolemizeOperation)(r,this.sourceId);if(!o){const l=new e.ArrayIterator([],{autoStart:!1});return l.setProperty("metadata",{state:new t.MetadataValidationState,cardinality:{type:"exact",value:0}}),l}return(0,u.skolemizeQuadStream)(this.innerSource.queryQuads(o,a),this.sourceId)}queryVoid(r,a){return this.innerSource.queryVoid(r,a)}get referenceValue(){return this.innerSource.referenceValue}toString(){return`${this.innerSource.toString()}(SkolemID:${this.sourceId})`}};return Uu.QuerySourceSkolemized=s,Uu}var oR;function ek(){if(oR)return Bu;oR=1,Object.defineProperty(Bu,"__esModule",{value:!0}),Bu.ActorContextPreprocessQuerySourceSkolemize=void 0;const t=Sy(),e=Lt,u=$F(),s=IT();let n=class extends t.ActorContextPreprocess{constructor(a){super(a)}async test(a){return!0}async run(a){let o=a.context;if(o.has(e.KeysQueryOperation.querySources)){o.has(e.KeysQuerySourceIdentify.sourceIds)||(o=o.set(e.KeysQuerySourceIdentify.sourceIds,new Map));const l=o.getSafe(e.KeysQuerySourceIdentify.sourceIds);let c=o.getSafe(e.KeysQueryOperation.querySources);c=c.map(d=>({source:new u.QuerySourceSkolemized(d.source,(0,s.getSourceId)(l,d.source)),context:d.context})),o=o.set(e.KeysQueryOperation.querySources,c)}return{context:o}}};return Bu.ActorContextPreprocessQuerySourceSkolemize=n,Bu}var uR;function QF(){return uR||(uR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(ek(),t),u($F(),t),u(IT(),t)}(Sm)),Sm}var Am={},Hu={},cR;function tk(){if(cR)return Hu;cR=1,Object.defineProperty(Hu,"__esModule",{value:!0}),Hu.MediatorCombinePipeline=void 0;const t=ot;let e=class extends t.Mediator{constructor(s){super(s)}async mediate(s){let n;try{n=this.publish(s)}catch{return s}if(this.filterErrors){const a=[];for(const o of n)try{await o.reply,a.push(o)}catch{}n=a}if(n=await Promise.all(n.map(async({actor:a,reply:o})=>({actor:a,reply:await o}))),this.order){const a=o=>{const l=this.field?o[this.field]:o;if(typeof l!="number")throw new TypeError("Cannot order elements that are not numbers.");return l};n=n.sort((o,l)=>(this.order==="increasing"?1:-1)*(a(o.reply)-a(l.reply)))}let r=s;for(const{actor:a}of n)r={...r,...await a.runObservable(r)};return r}mediateWith(){throw new Error("Method not supported.")}};return Hu.MediatorCombinePipeline=e,Hu}var lR;function dR(){return lR||(lR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(tk(),t)}(Am)),Am}var Em={},$u={},Om={},Qu={},fR;function rk(){if(fR)return Qu;fR=1,Object.defineProperty(Qu,"__esModule",{value:!0}),Qu.ActorHashBindings=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return Qu.ActorHashBindings=e,Qu}var hR;function nk(){return hR||(hR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(rk(),t)}(Om)),Om}var Rm,pR;function ik(){return pR||(pR=1,Rm=function t(e){if(typeof e=="number"&&isNaN(e))throw new Error("NaN is not allowed");if(typeof e=="number"&&!isFinite(e))throw new Error("Infinity is not allowed");return e===null||typeof e!="object"?JSON.stringify(e):e.toJSON instanceof Function?t(e.toJSON()):Array.isArray(e)?`[${e.reduce((n,r,a)=>`${n}${a===0?"":","}${t(r===void 0||typeof r=="symbol"?null:r)}`,"")}]`:`{${Object.keys(e).sort().reduce((s,n)=>{if(e[n]===void 0||typeof e[n]=="symbol")return s;const r=s.length===0?"":",";return`${s}${r}${t(n)}:${t(e[n])}`},"")}}`}),Rm}var yR;function ak(){if(yR)return $u;yR=1,Object.defineProperty($u,"__esModule",{value:!0}),$u.ActorHashBindingsSha1=void 0;const t=nk(),e=xT(),u=er(),s=ik();let n=class extends t.ActorHashBindings{async test(a){if(!a.allowHashCollisions)throw new Error(`Actor ${this.name} can not provide hash functions without hash collisions`);return!0}async run(a){return{hashFunction:o=>(0,e.sha1)().update(s(Object.fromEntries([...o].map(([l,c])=>[(0,u.termToString)(l),(0,u.termToString)(c)])))).digest("hex"),hashCollisions:!0}}};return $u.ActorHashBindingsSha1=n,$u}var bR;function sk(){return bR||(bR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(ak(),t)}(Em)),Em}var xm={},Vu={},gR;function ok(){if(gR)return Vu;gR=1,Object.defineProperty(Vu,"__esModule",{value:!0}),Vu.MediatorRace=void 0;const t=ot;let e=class extends t.Mediator{constructor(s){super(s)}mediateWith(s,n){return new Promise((r,a)=>{const o=[];for(const l of n)l.reply.then(()=>{r(l.actor)}).catch(c=>{o.push(c),o.length===n.length&&a(new Error(`${this.name} mediated over all rejecting actors: -${o.map(d=>d.message).join(` -`)}`))})})}};return Vu.MediatorRace=e,Vu}var mR;function _n(){return mR||(mR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(ok(),t)}(xm)),xm}var Im={},ku={},Pm={},zu={},_R;function uk(){if(_R)return zu;_R=1,Object.defineProperty(zu,"__esModule",{value:!0}),zu.ActorOptimizeQueryOperation=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return zu.ActorOptimizeQueryOperation=e,zu}var vR;function Ii(){return vR||(vR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(uk(),t)}(Pm)),Pm}var wR;function ck(){if(wR)return ku;wR=1,Object.defineProperty(ku,"__esModule",{value:!0}),ku.ActorOptimizeQueryOperationRewriteCopy=void 0;const t=Ii(),e=Ot();let u=class extends t.ActorOptimizeQueryOperation{constructor(n){super(n)}async test(n){return!0}async run(n){return{operation:e.Util.mapOperation(n.operation,{[e.Algebra.types.COPY](a,o){let l;return typeof a.destination=="string"&&typeof a.source=="string"&&a.destination===a.source||typeof a.destination!="string"&&typeof a.source!="string"&&a.destination.equals(a.source)?l=o.createCompositeUpdate([]):l=o.createCompositeUpdate([o.createDrop(a.destination,!0),o.createAdd(a.source,a.destination,a.silent)]),{result:l,recurse:!1}}}),context:n.context}}};return ku.ActorOptimizeQueryOperationRewriteCopy=u,ku}var SR;function lk(){return SR||(SR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(ck(),t)}(Im)),Im}var Dm={},Gu={},TR;function dk(){if(TR)return Gu;TR=1,Object.defineProperty(Gu,"__esModule",{value:!0}),Gu.ActorOptimizeQueryOperationRewriteMove=void 0;const t=Ii(),e=Ot();let u=class extends t.ActorOptimizeQueryOperation{constructor(n){super(n)}async test(n){return!0}async run(n){return{operation:e.Util.mapOperation(n.operation,{[e.Algebra.types.MOVE](a,o){let l;if(typeof a.destination=="string"&&typeof a.source=="string"&&a.destination===a.source||typeof a.destination!="string"&&typeof a.source!="string"&&a.destination.equals(a.source))l=o.createCompositeUpdate([]);else{const c=[o.createDrop(a.destination,!0),o.createAdd(a.source,a.destination,a.silent),o.createDrop(a.source)];l=o.createCompositeUpdate(c)}return{result:l,recurse:!1}}}),context:n.context}}};return Gu.ActorOptimizeQueryOperationRewriteMove=u,Gu}var AR;function fk(){return AR||(AR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(dk(),t)}(Dm)),Dm}var Nm={},Wu={},ER;function hk(){if(ER)return Wu;ER=1,Object.defineProperty(Wu,"__esModule",{value:!0}),Wu.ActorOptimizeQueryOperationRewriteAdd=void 0;const t=Ii(),e=Et(),u=Ot(),s=new e.DataFactory;let n=class extends t.ActorOptimizeQueryOperation{constructor(a){super(a)}async test(a){return!0}async run(a){return{operation:u.Util.mapOperation(a.operation,{[u.Algebra.types.ADD](l,c){const d=l.destination==="DEFAULT"?s.defaultGraph():l.destination,h=l.source==="DEFAULT"?s.defaultGraph():l.source;return{result:c.createDeleteInsert(void 0,[c.createPattern(s.variable("s"),s.variable("p"),s.variable("o"),d)],c.createPattern(s.variable("s"),s.variable("p"),s.variable("o"),h)),recurse:!1}}}),context:a.context}}};return Wu.ActorOptimizeQueryOperationRewriteAdd=n,Wu}var OR;function pk(){return OR||(OR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(hk(),t)}(Nm)),Nm}var Cm={},Ju={},RR;function yk(){if(RR)return Ju;RR=1,Object.defineProperty(Ju,"__esModule",{value:!0}),Ju.ActorOptimizeQueryOperationGroupSources=void 0;const t=Ii(),e=wt(),u=Ot(),s=new u.Factory;let n=class extends t.ActorOptimizeQueryOperation{constructor(a){super(a)}async test(a){if(e.ActorQueryOperation.getOperationSource(a.operation))throw new Error(`Actor ${this.name} does not work with top-level operation sources.`);return!0}async run(a){return{operation:await this.groupOperation(a.operation,a.context),context:a.context}}async groupOperation(a,o){var h;if(e.ActorQueryOperation.getOperationSource(a)??!("input"in a))return a;if(!Array.isArray(a.input)){const f=await this.groupOperation(a.input,o);if((h=f.metadata)!=null&&h.scopedSource){const p=e.ActorQueryOperation.getOperationSource(f);e.ActorQueryOperation.doesShapeAcceptOperation(await p.source.getSelectorShape(o),a)&&(this.logDebug(o,`Hoist 1 source-specific operation into a single ${a.type} operation for ${p.source.toString()}`),e.ActorQueryOperation.removeOperationSource(f),a=e.ActorQueryOperation.assignOperationSource(a,p))}return{...a,input:f}}const l=await Promise.all(a.input.map(f=>this.groupOperation(f,o))),c=this.clusterOperationsWithEqualSources(l);if(c.length===1){const f=c[0],p=e.ActorQueryOperation.getOperationSource(c[0][0]);return{...await this.moveSourceAnnotationUpwardsIfPossible(a,f,p,o),input:f}}if(c.length===l.length)return{...a,input:l};let d;switch(a.type){case u.Algebra.types.JOIN:d=s.createJoin.bind(s);break;case u.Algebra.types.UNION:d=s.createUnion.bind(s);break;case u.Algebra.types.ALT:d=s.createAlt.bind(s);break;case u.Algebra.types.SEQ:d=s.createSeq.bind(s);break;default:throw new Error(`Unsupported operation '${a.type}' detected while grouping sources`)}return await this.groupOperationMulti(c,d,o)}async groupOperationMulti(a,o,l){let c=!0;const d=await Promise.all(a.map(async h=>{const f=e.ActorQueryOperation.getOperationSource(h[0]),p=await this.moveSourceAnnotationUpwardsIfPossible(o(h,!0),h,f,l);return e.ActorQueryOperation.getOperationSource(p)&&(c=!1),p}));return o(d,c)}clusterOperationsWithEqualSources(a){const o=new Map,l=[];for(const d of a){const h=e.ActorQueryOperation.getOperationSource(d);h?(o.has(h)||o.set(h,[]),o.get(h).push(d)):l.push(d)}const c=[];l.length>0&&c.push(l);for(const[d,h]of o.entries())c.push(h.map(f=>e.ActorQueryOperation.assignOperationSource(f,d)));return c}async moveSourceAnnotationUpwardsIfPossible(a,o,l,c){if(l&&e.ActorQueryOperation.doesShapeAcceptOperation(await l.source.getSelectorShape(c),a)){this.logDebug(c,`Hoist ${o.length} source-specific operations into a single ${a.type} operation for ${l.source.toString()}`),a=e.ActorQueryOperation.assignOperationSource(a,l);for(const d of o)e.ActorQueryOperation.removeOperationSource(d)}return a}};return Ju.ActorOptimizeQueryOperationGroupSources=n,Ju}var xR;function bk(){return xR||(xR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(yk(),t)}(Cm)),Cm}var jm={},Xu={},Lm={},Ku={},IR;function gk(){if(IR)return Ku;IR=1,Object.defineProperty(Ku,"__esModule",{value:!0}),Ku.ActorQueryParse=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return Ku.ActorQueryParse=e,Ku}var PR;function VF(){return PR||(PR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(gk(),t)}(Lm)),Lm}var DR;function mk(){if(DR)return Xu;DR=1,Object.defineProperty(Xu,"__esModule",{value:!0}),Xu.ActorQueryParseSparql=void 0;const t=VF(),e=Ot(),u=my();let s=class extends t.ActorQueryParse{constructor(r){super(r),this.prefixes=Object.freeze(this.prefixes)}async test(r){if(r.queryFormat&&r.queryFormat.language!=="sparql")throw new Error("This actor can only parse SPARQL queries");return!0}async run(r){const o=new u.Parser({prefixes:this.prefixes,baseIRI:r.baseIRI,sparqlStar:!0}).parse(r.query);return{baseIRI:o.type==="query"?o.base:void 0,operation:(0,e.translate)(o,{quads:!0,prefixes:this.prefixes,blankToVariable:!0,baseIRI:r.baseIRI})}}};return Xu.ActorQueryParseSparql=s,Xu}var NR;function _k(){return NR||(NR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(mk(),t)}(jm)),jm}var Mm={},Yu={},Fm={},qm={},Bm={},Zu={},CR;function ru(){if(CR)return Zu;CR=1,Object.defineProperty(Zu,"__esModule",{value:!0}),Zu.DirectiveNodeHandlerAdapter=void 0;let t=class{constructor(u,s,n){this.targetKind=u,this.util=s,this.settings=n}getDirectiveConditionalValue(u,s){const n=this.util.getArgument(u.arguments,"if");if(!n)throw new Error(`The directive ${u.name.value} is missing an if-argument.`);const r=this.util.handleNodeValue(n.value,n.name.value,s);if(r.terms.length!==1)throw new Error(`Can not apply the directive ${u.name.value} with a list.`);return r.terms[0]}isDirectiveScopeAll(u){const s=this.util.getArgument(u.arguments,"scope");return s&&s.value.kind==="EnumValue"&&s.value.value==="all"}};return Zu.DirectiveNodeHandlerAdapter=t,Zu}var ec={},jR;function vk(){if(jR)return ec;jR=1,Object.defineProperty(ec,"__esModule",{value:!0}),ec.DirectiveNodeHandlerInclude=void 0;const t=ru();let e=class extends t.DirectiveNodeHandlerAdapter{constructor(s,n){super("include",s,n)}handle(s,n){const r=this.getDirectiveConditionalValue(s.directive,n);return r.termType==="Literal"&&r.value==="false"?{ignore:!0}:{}}};return ec.DirectiveNodeHandlerInclude=e,ec}var tc={},LR;function wk(){if(LR)return tc;LR=1,Object.defineProperty(tc,"__esModule",{value:!0}),tc.DirectiveNodeHandlerOptional=void 0;const t=ru();let e=class extends t.DirectiveNodeHandlerAdapter{constructor(s,n){super("optional",s,n)}handle(s,n){return{operationOverrider:r=>this.util.operationFactory.createLeftJoin(this.util.operationFactory.createBgp([]),r)}}};return tc.DirectiveNodeHandlerOptional=e,tc}var rc={},Um={},MR;function Ty(){return MR||(MR=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.SingularizeState=void 0,function(e){e[e.SINGLE=0]="SINGLE",e[e.PLURAL=1]="PLURAL"}(t.SingularizeState||(t.SingularizeState={}))}(Um)),Um}var FR;function Sk(){if(FR)return rc;FR=1,Object.defineProperty(rc,"__esModule",{value:!0}),rc.DirectiveNodeHandlerPlural=void 0;const t=Ty(),e=ru();let u=class extends e.DirectiveNodeHandlerAdapter{constructor(n,r){super("plural",n,r)}handle(n,r){return this.isDirectiveScopeAll(n.directive)&&(r.singularizeState=t.SingularizeState.PLURAL),delete r.singularizeVariables[this.util.nameToVariable(n.fieldLabel,r).value],{}}};return rc.DirectiveNodeHandlerPlural=u,rc}var nc={},qR;function Tk(){if(qR)return nc;qR=1,Object.defineProperty(nc,"__esModule",{value:!0}),nc.DirectiveNodeHandlerSingle=void 0;const t=Ty(),e=ru();let u=class extends e.DirectiveNodeHandlerAdapter{constructor(n,r){super("single",n,r)}handle(n,r){return this.isDirectiveScopeAll(n.directive)&&(r.singularizeState=t.SingularizeState.SINGLE),r.singularizeVariables[this.util.nameToVariable(n.fieldLabel,r).value]=!0,{}}};return nc.DirectiveNodeHandlerSingle=u,nc}var ic={},BR;function Ak(){if(BR)return ic;BR=1,Object.defineProperty(ic,"__esModule",{value:!0}),ic.DirectiveNodeHandlerSkip=void 0;const t=ru();let e=class extends t.DirectiveNodeHandlerAdapter{constructor(s,n){super("skip",s,n)}handle(s,n){const r=this.getDirectiveConditionalValue(s.directive,n);return r.termType==="Literal"&&r.value==="true"?{ignore:!0}:{}}};return ic.DirectiveNodeHandlerSkip=e,ic}var UR;function kF(){return UR||(UR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(ru(),t),u(vk(),t),u(wk(),t),u(Sk(),t),u(Tk(),t),u(Ak(),t)}(Bm)),Bm}var Hm={},ac={},HR;function zi(){if(HR)return ac;HR=1,Object.defineProperty(ac,"__esModule",{value:!0}),ac.NodeValueHandlerAdapter=void 0;let t=class{constructor(u,s,n){this.targetKind=u,this.util=s,this.settings=n}};return ac.NodeValueHandlerAdapter=t,ac}var sc={},$R;function Ek(){if($R)return sc;$R=1,Object.defineProperty(sc,"__esModule",{value:!0}),sc.NodeValueHandlerBoolean=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("BooleanValue",s,n),this.datatype=this.util.dataFactory.namedNode("http://www.w3.org/2001/XMLSchema#boolean")}handle(s,n,r){return{terms:[this.util.dataFactory.literal(s.value?"true":"false",this.datatype)]}}};return sc.NodeValueHandlerBoolean=e,sc}var oc={},QR;function Ok(){if(QR)return oc;QR=1,Object.defineProperty(oc,"__esModule",{value:!0}),oc.NodeValueHandlerEnum=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("EnumValue",s,n)}handle(s,n,r){return{terms:[this.util.valueToNamedNode(s.value,r.context)]}}};return oc.NodeValueHandlerEnum=e,oc}var uc={},VR;function Rk(){if(VR)return uc;VR=1,Object.defineProperty(uc,"__esModule",{value:!0}),uc.NodeValueHandlerFloat=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("FloatValue",s,n),this.datatype=this.util.dataFactory.namedNode("http://www.w3.org/2001/XMLSchema#float")}handle(s,n,r){return{terms:[this.util.dataFactory.literal(s.value,this.datatype)]}}};return uc.NodeValueHandlerFloat=e,uc}var cc={},kR;function xk(){if(kR)return cc;kR=1,Object.defineProperty(cc,"__esModule",{value:!0}),cc.NodeValueHandlerInt=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("IntValue",s,n),this.datatype=this.util.dataFactory.namedNode("http://www.w3.org/2001/XMLSchema#integer")}handle(s,n,r){return{terms:[this.util.dataFactory.literal(s.value,this.datatype)]}}};return cc.NodeValueHandlerInt=e,cc}var lc={},zR;function Ik(){if(zR)return lc;zR=1,Object.defineProperty(lc,"__esModule",{value:!0}),lc.NodeValueHandlerList=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("ListValue",s,n),this.nodeFirst=this.util.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#first"),this.nodeRest=this.util.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#rest"),this.nodeNil=this.util.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#nil")}handle(s,n,r){const a=[];let o=[];for(const l of s.values){const c=this.util.handleNodeValue(l,n,r);for(const d of c.terms)a.push(d);c.auxiliaryPatterns&&(o=o.concat(c.auxiliaryPatterns))}if(this.settings.arraysToRdfLists){const l=this.util.dataFactory.blankNode();let c=l,d=a.length;for(const h of a){o.push(this.util.operationFactory.createPattern(c,this.nodeFirst,h,r.graph));const f=--d===0?this.nodeNil:this.util.dataFactory.blankNode();o.push(this.util.operationFactory.createPattern(c,this.nodeRest,f,r.graph)),c=f}return{terms:[l],auxiliaryPatterns:o}}else return{terms:a,auxiliaryPatterns:o}}};return lc.NodeValueHandlerList=e,lc}var dc={},GR;function Pk(){if(GR)return dc;GR=1,Object.defineProperty(dc,"__esModule",{value:!0}),dc.NodeValueHandlerNull=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("NullValue",s,n),this.nil=this.util.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#nil")}handle(s,n,r){return{terms:[this.nil]}}};return dc.NodeValueHandlerNull=e,dc}var fc={},WR;function Dk(){if(WR)return fc;WR=1,Object.defineProperty(fc,"__esModule",{value:!0}),fc.NodeValueHandlerObject=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("ObjectValue",s,n)}handle(s,n,r){const a=this.util.dataFactory.blankNode();let o=[];for(const l of s.fields){const c=this.util.handleNodeValue(l.value,n,r);for(const d of c.terms)o.push(this.util.createQuadPattern(a,l.name,d,r.graph,r.context));c.auxiliaryPatterns&&(o=o.concat(c.auxiliaryPatterns))}return{terms:[a],auxiliaryPatterns:o}}};return fc.NodeValueHandlerObject=e,fc}var hc={},JR;function Nk(){if(JR)return hc;JR=1,Object.defineProperty(hc,"__esModule",{value:!0}),hc.NodeValueHandlerString=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("StringValue",s,n)}handle(s,n,r){const a=r.context.getContextRaw()[n];let o,l;return a&&typeof a!="string"&&(a["@language"]?o=a["@language"]:a["@type"]&&(l=this.util.dataFactory.namedNode(a["@type"]))),{terms:[this.util.dataFactory.literal(s.value,o||l)]}}};return hc.NodeValueHandlerString=e,hc}var pc={},XR;function Ck(){if(XR)return pc;XR=1,Object.defineProperty(pc,"__esModule",{value:!0}),pc.NodeValueHandlerVariable=void 0;const t=zi();let e=class extends t.NodeValueHandlerAdapter{constructor(s,n){super("Variable",s,n)}handle(s,n,r){const a=s.name.value,o=r.variablesDict[a],l=r.variablesMetaDict[a];if(!o){if(!r.ignoreUnknownVariables&&(!l||l.mandatory))throw new Error(`Undefined variable: ${a}`);{const c=this.util.dataFactory.variable(a);return r.terminalVariables.map(d=>d.value).indexOf(a)<0&&r.terminalVariables.push(c),{terms:[c]}}}if(o.kind==="Variable")throw new Error(`Variable refers to another variable: ${a}`);if(l)if(l.list){if(o.kind!=="ListValue")throw new Error(`Expected a list, but got ${o.kind} for ${a}`);if(l.type){const c=o;for(const d of c.values)if(d.kind!==l.type)throw new Error(`Expected ${l.type}, but got ${d.kind} for ${a}`)}}else l.type;return this.util.handleNodeValue(o,n,r)}};return pc.NodeValueHandlerVariable=e,pc}var KR;function jk(){return KR||(KR=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(zi(),t),u(Ek(),t),u(Ok(),t),u(Rk(),t),u(xk(),t),u(Ik(),t),u(Pk(),t),u(Dk(),t),u(Nk(),t),u(Ck(),t)}(Hm)),Hm}var yc={},YR;function Lb(){if(YR)return yc;YR=1,Object.defineProperty(yc,"__esModule",{value:!0}),yc.NodeHandlerAdapter=void 0;let t=class{constructor(u,s,n){this.targetKind=u,this.util=s,this.settings=n}getNodeQuadContextSelectionSet(u,s,n){const r={};if(u){for(const a of u.selections)if(a.kind==="Field"){const o=a;this.handleNodeQuadContextField(o,n,r,"id","subject"),this.handleNodeQuadContextField(o,n,r,"graph","graph")}}return r}handleNodeQuadContextField(u,s,n,r,a){if(!n[a]&&u.name.value===r){if(!n[a]){const o=this.util.getArgument(u.arguments,"_");if(o){const l=this.util.handleNodeValue(o.value,u.name.value,s);if(l.terms.length!==1)throw new Error(`Only single values can be set as ${r}, but got ${l.terms.length} at ${u.name.value}`);n[a]=l.terms[0],l.auxiliaryPatterns&&(n.auxiliaryPatterns||(n.auxiliaryPatterns=[]),n.auxiliaryPatterns.concat(l.auxiliaryPatterns))}}if(!n[a]){const o=this.util.nameToVariable(this.util.getFieldLabel(u),s);s.terminalVariables.push(o),n[a]=o}}}getDirectiveOutputs(u,s,n){const r=[];if(u)for(const a of u){const o=this.util.handleDirectiveNode({directive:a,fieldLabel:s},n);if(o){if(o.ignore)return null;r.push(o)}}return r}handleDirectiveOutputs(u,s){for(const n of u){if(n.ignore)return this.util.operationFactory.createBgp([]);n.operationOverrider&&(s=n.operationOverrider(s))}return s}};return yc.NodeHandlerAdapter=t,yc}var bc={},ZR;function PT(){if(ZR)return bc;ZR=1,Object.defineProperty(bc,"__esModule",{value:!0}),bc.NodeHandlerDefinitionAdapter=void 0;const t=Lb();let e=class extends t.NodeHandlerAdapter{constructor(s,n,r){super(s,n,r)}};return bc.NodeHandlerDefinitionAdapter=e,bc}var gc={},ex;function Lk(){if(ex)return gc;ex=1,Object.defineProperty(gc,"__esModule",{value:!0}),gc.NodeHandlerDefinitionFragment=void 0;const t=PT();let e=class extends t.NodeHandlerDefinitionAdapter{constructor(s,n){super("FragmentDefinition",s,n)}handle(s,n){throw new Error("Illegal state: fragment definitions must be indexed and removed before processing")}};return gc.NodeHandlerDefinitionFragment=e,gc}var mc={},tx;function Mk(){if(tx)return mc;tx=1,Object.defineProperty(mc,"__esModule",{value:!0}),mc.NodeHandlerDefinitionOperation=void 0;const t=PT();let e=class extends t.NodeHandlerDefinitionAdapter{constructor(s,n){super("OperationDefinition",s,n)}handle(s,n){if(s.operation!=="query")throw new Error("Unsupported definition operation: "+s.operation);if(s.variableDefinitions)for(const o of s.variableDefinitions){const l=o.variable.name.value;o.defaultValue&&(n.variablesDict[l]||(n.variablesDict[l]=o.defaultValue));let c=o.type;const d=c.kind==="NonNullType";d&&(c=c.type);const h=c.kind==="ListType";h&&(c=c.type);const f=c.name.value;n.variablesMetaDict[l]={mandatory:d,list:h,type:f}}const r=this.getDirectiveOutputs(s.directives,s.name?s.name.value:"",n);if(!r)return this.util.operationFactory.createBgp([]);const a=this.util.joinOperations(s.selectionSet.selections.map(o=>this.util.handleNode(o,n)));return this.handleDirectiveOutputs(r,a)}};return mc.NodeHandlerDefinitionOperation=e,mc}var _c={},rx;function Fk(){if(rx)return _c;rx=1,Object.defineProperty(_c,"__esModule",{value:!0}),_c.NodeHandlerDocument=void 0;const t=Ot(),e=Lb();let u=class extends e.NodeHandlerAdapter{constructor(n,r){super("Document",n,r)}handle(n,r){const a=n.definitions.map(l=>{const c=this.getNodeQuadContextDefinitionNode(l,Object.assign(Object.assign({},r),{ignoreUnknownVariables:!0})),d=Object.assign(Object.assign({},r),{graph:c.graph||r.graph,subject:c.subject||this.util.dataFactory.blankNode()});let h=this.util.handleNode(l,d);return c&&c.auxiliaryPatterns&&(h=this.util.joinOperations([h,this.util.operationFactory.createBgp(c.auxiliaryPatterns)])),h}),o=this.util.operationFactory.createProject(a.length===1?a[0]:this.util.operationFactory.createUnion(a),r.terminalVariables);return this.translateBlankNodesToVariables(o)}getNodeQuadContextDefinitionNode(n,r){if(n.kind==="OperationDefinition")return this.getNodeQuadContextSelectionSet(n.selectionSet,n.name?n.name.value:"",r);throw new Error(`Unsupported definition: ${n.kind}`)}translateBlankNodesToVariables(n){const r=this,a={},o=Array.from(n.variables).reduce((c,d)=>(c[d.value]=!0,c),{});return t.Util.mapOperation(n,{path:(c,d)=>({recurse:!1,result:d.createPath(l(c.subject),c.predicate,l(c.object),l(c.graph))}),pattern:(c,d)=>({recurse:!1,result:d.createPattern(l(c.subject),l(c.predicate),l(c.object),l(c.graph))})});function l(c){if(c.termType==="BlankNode"){let d=a[c.value];return d||(d=t.Util.createUniqueVariable(c.value,o,r.util.dataFactory),o[d.value]=!0,a[c.value]=d),d}return c}}};return _c.NodeHandlerDocument=u,_c}var vc={},nx;function Mb(){if(nx)return vc;nx=1,Object.defineProperty(vc,"__esModule",{value:!0}),vc.NodeHandlerSelectionAdapter=void 0;const t=Ot(),e=Ty(),u=Lb();let s=class extends u.NodeHandlerAdapter{constructor(r,a,o){super(r,a,o)}getNodeQuadContextFieldNode(r,a,o){return this.getNodeQuadContextSelectionSet(r.selectionSet,a,Object.assign(Object.assign({},o),{path:this.util.appendFieldToPath(o.path,a)}))}fieldToOperation(r,a,o,l){const c=o;let d=0,h;if((a.name.value==="id"||a.name.value==="graph")&&(o=!1,a.arguments))for(const S of a.arguments)S.name.value==="_"&&this.util.handleNodeValue(S.value,a.name.value,r);const f=this.util.getFieldLabel(a);if(r.singularizeState===e.SingularizeState.SINGLE&&(r.singularizeVariables[this.util.nameToVariable(f,r).value]=!0),o){const S=this.handleMetaField(r,f,l);if(S)return S}const p=l?[this.util.operationFactory.createBgp(l)]:[],y=this.getNodeQuadContextFieldNode(a,f,r);let b=y.subject||this.util.nameToVariable(f,r),m=y.graph||r.graph;y.auxiliaryPatterns&&p.push(this.util.operationFactory.createBgp(y.auxiliaryPatterns));let g=!0,v=null;if(o&&a.arguments&&a.arguments.length){for(const S of a.arguments)if(S.name.value==="_"){const A=this.util.handleNodeValue(S.value,a.name.value,r);v=A.terms,p.push(this.util.operationFactory.createBgp(A.terms.map(D=>this.util.createQuadPattern(r.subject,a.name,D,r.graph,r.context)))),A.auxiliaryPatterns&&p.push(this.util.operationFactory.createBgp(A.auxiliaryPatterns)),o=!1;break}else if(S.name.value==="graph"){const A=this.util.handleNodeValue(S.value,a.name.value,r);if(A.terms.length!==1)throw new Error(`Only single values can be set as graph, but got ${A.terms.length} at ${a.name.value}`);m=A.terms[0],r=Object.assign(Object.assign({},r),{graph:m}),A.auxiliaryPatterns&&p.push(this.util.operationFactory.createBgp(A.auxiliaryPatterns));break}else if(S.name.value==="alt"){let A=S.value;A.kind!=="ListValue"&&(A={kind:"ListValue",values:[A]}),p.push(this.util.createQuadPath(r.subject,a.name,A,b,r.graph,r.context)),g=!1;break}}if(o&&g&&p.push(this.util.operationFactory.createBgp([this.util.createQuadPattern(r.subject,a.name,b,r.graph,r.context)])),a.arguments&&a.arguments.length){for(const S of a.arguments)if(!(S.name.value==="_"||S.name.value==="graph"||S.name.value==="alt"))if(S.name.value==="first"){if(S.value.kind!=="IntValue")throw new Error("Invalid value type for 'first' argument: "+S.value.kind);h=parseInt(S.value.value,10)}else if(S.name.value==="offset"){if(S.value.kind!=="IntValue")throw new Error("Invalid value type for 'offset' argument: "+S.value.kind);d=parseInt(S.value.value,10)}else{const A=this.util.handleNodeValue(S.value,S.name.value,r);p.push(this.util.operationFactory.createBgp(A.terms.map(D=>this.util.createQuadPattern(b,S.name,D,r.graph,r.context)))),A.auxiliaryPatterns&&p.push(this.util.operationFactory.createBgp(A.auxiliaryPatterns))}}const _=this.getDirectiveOutputs(a.directives,f,r);if(!_)return this.util.operationFactory.createBgp([]);let w=this.util.joinOperations(p);if(a.selectionSet&&a.selectionSet.selections.length){if(v){if(v.length!==1)throw new Error(`Only single values can be set as id, but got ${v.length} at ${a.name.value}`);b=v[0]}const S=Object.assign(Object.assign(Object.assign({},r),c?{path:this.util.appendFieldToPath(r.path,f)}:{}),{graph:m,subject:c?b:r.subject});let A=!1;const D=a.selectionSet.selections.filter(E=>E.kind==="Field"&&E.name.value==="totalCount"?(A=!0,!1):!0);let L=this.util.joinOperations(p.concat(D.map(E=>this.util.handleNode(E,S))));if(A){const E=this.util.dataFactory.variable("var"+this.settings.expressionVariableCounter++),O=this.util.dataFactory.variable(b.value+this.settings.variableDelimiter+"totalCount"),P=this.util.operationFactory.createBoundAggregate(E,"count",this.util.operationFactory.createTermExpression(b),!1),j=this.util.operationFactory.createProject(this.util.operationFactory.createExtend(this.util.operationFactory.createGroup(w,[],[P]),O,this.util.operationFactory.createTermExpression(E)),[O]);r.terminalVariables.push(O),D.length?L=this.util.operationFactory.createJoin([this.util.operationFactory.createProject(L,[]),j]):L=j}w=L}else o&&b.termType==="Variable"&&r.terminalVariables.push(b);return(d||h)&&(w=this.util.operationFactory.createSlice(this.util.operationFactory.createProject(w,t.Util.inScopeVariables(w)),d,h)),this.handleDirectiveOutputs(_,w)}handleMetaField(r,a,o){if(a==="__typename"){const l=this.util.nameToVariable(a,r);return r.terminalVariables.push(l),this.util.operationFactory.createBgp([this.util.operationFactory.createPattern(r.subject,this.util.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),this.util.nameToVariable(a,r),r.graph)].concat(o||[]))}}};return vc.NodeHandlerSelectionAdapter=s,vc}var wc={},ix;function qk(){if(ix)return wc;ix=1,Object.defineProperty(wc,"__esModule",{value:!0}),wc.NodeHandlerSelectionField=void 0;const t=Mb();let e=class extends t.NodeHandlerSelectionAdapter{constructor(s,n){super("Field",s,n)}handle(s,n){return this.fieldToOperation(n,s,!0)}};return wc.NodeHandlerSelectionField=e,wc}var Sc={},ax;function Bk(){if(ax)return Sc;ax=1,Object.defineProperty(Sc,"__esModule",{value:!0}),Sc.NodeHandlerSelectionFragmentSpread=void 0;const t=Mb();let e=class extends t.NodeHandlerSelectionAdapter{constructor(s,n){super("FragmentSpread",s,n)}handle(s,n){const r=n.fragmentDefinitions[s.name.value];if(!r)throw new Error("Undefined fragment definition: "+s.name.value);const a={alias:void 0,arguments:void 0,directives:r.directives,kind:"Field",name:s.name,selectionSet:r.selectionSet},o=[this.util.newTypePattern(n.subject,r.typeCondition,n)];return this.util.operationFactory.createLeftJoin(this.util.operationFactory.createBgp([]),this.fieldToOperation(n,a,!1,o))}};return Sc.NodeHandlerSelectionFragmentSpread=e,Sc}var Tc={},sx;function Uk(){if(sx)return Tc;sx=1,Object.defineProperty(Tc,"__esModule",{value:!0}),Tc.NodeHandlerSelectionInlineFragment=void 0;const t=Mb();let e=class extends t.NodeHandlerSelectionAdapter{constructor(s,n){super("InlineFragment",s,n)}handle(s,n){const r={alias:void 0,arguments:void 0,directives:s.directives,kind:"Field",name:{kind:"Name",value:n.subject.value},selectionSet:s.selectionSet},a=s.typeCondition?[this.util.newTypePattern(n.subject,s.typeCondition,n)]:[];return this.util.operationFactory.createLeftJoin(this.util.operationFactory.createBgp([]),this.fieldToOperation(n,r,!1,a))}};return Tc.NodeHandlerSelectionInlineFragment=e,Tc}var ox;function zF(){return ox||(ox=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(kF(),t),u(jk(),t),u(Lb(),t),u(PT(),t),u(Lk(),t),u(Mk(),t),u(Fk(),t),u(Mb(),t),u(qk(),t),u(Bk(),t),u(Uk(),t)}(qm)),qm}var Ac={},GF=typeof Symbol=="function"&&Symbol.toStringTag!=null?Symbol.toStringTag:"@@toStringTag",Hk=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):void 0;const e3=Hk;function D1(t){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?D1=function(u){return typeof u}:D1=function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},D1(t)}var $k=10,WF=2;function JF(t){return Fb(t,[])}function Fb(t,e){switch(D1(t)){case"string":return JSON.stringify(t);case"function":return t.name?"[function ".concat(t.name,"]"):"[function]";case"object":return t===null?"null":Qk(t,e);default:return String(t)}}function Qk(t,e){if(e.indexOf(t)!==-1)return"[Circular]";var u=[].concat(e,[t]),s=zk(t);if(s!==void 0){var n=s.call(t);if(n!==t)return typeof n=="string"?n:Fb(n,u)}else if(Array.isArray(t))return kk(t,u);return Vk(t,u)}function Vk(t,e){var u=Object.keys(t);if(u.length===0)return"{}";if(e.length>WF)return"["+Gk(t)+"]";var s=u.map(function(n){var r=Fb(t[n],e);return n+": "+r});return"{ "+s.join(", ")+" }"}function kk(t,e){if(t.length===0)return"[]";if(e.length>WF)return"[Array]";for(var u=Math.min($k,t.length),s=t.length-u,n=[],r=0;r1&&n.push("... ".concat(s," more items")),"["+n.join(", ")+"]"}function zk(t){var e=t[String(e3)];if(typeof e=="function")return e;if(typeof t.inspect=="function")return t.inspect}function Gk(t){var e=Object.prototype.toString.call(t).replace(/^\[object /,"").replace(/]$/,"");if(e==="Object"&&typeof t.constructor=="function"){var u=t.constructor.name;if(typeof u=="string"&&u!=="")return u}return e}function $m(t,e){var u=!!t;if(!u)throw new Error(e)}const Wk=function(e,u){return e instanceof u};function ux(t,e){for(var u=0;u1&&arguments[1]!==void 0?arguments[1]:"GraphQL request",s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{line:1,column:1};typeof e=="string"||$m(0,"Body must be a string. Received: ".concat(JF(e),".")),this.body=e,this.name=u,this.locationOffset=s,this.locationOffset.line>0||$m(0,"line in locationOffset is 1-indexed and must be positive."),this.locationOffset.column>0||$m(0,"column in locationOffset is 1-indexed and must be positive.")}return Jk(t,[{key:GF,get:function(){return"Source"}}]),t}();function Xk(t){return Wk(t,DT)}function Z1(t,e){for(var u=/\r\n|[\n\r]/g,s=1,n=e+1,r;(r=u.exec(t.body))&&r.index120){for(var f=Math.floor(l/80),p=l%80,y=[],b=0;b",EOF:"",BANG:"!",DOLLAR:"$",AMP:"&",PAREN_L:"(",PAREN_R:")",SPREAD:"...",COLON:":",EQUALS:"=",AT:"@",BRACKET_L:"[",BRACKET_R:"]",BRACE_L:"{",PIPE:"|",BRACE_R:"}",NAME:"Name",INT:"Int",FLOAT:"Float",STRING:"String",BLOCK_STRING:"BlockString",COMMENT:"Comment"});function C1(t){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?C1=function(u){return typeof u}:C1=function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},C1(t)}function Yk(t){return C1(t)=="object"&&t!==null}function j1(t){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?j1=function(u){return typeof u}:j1=function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},j1(t)}function lx(t,e){var u=Object.keys(t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);e&&(s=s.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),u.push.apply(u,s)}return u}function Zk(t){for(var e=1;e"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch{return!1}}function az(t){return Function.toString.call(t).indexOf("[native code]")!==-1}function J0(t,e){return J0=Object.setPrototypeOf||function(s,n){return s.__proto__=n,s},J0(t,e)}function X0(t){return X0=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},X0(t)}var sz=function(t){nz(u,t);var e=iz(u);function u(s,n,r,a,o,l,c){var d,h,f,p;tz(this,u),p=e.call(this,s),p.name="GraphQLError",p.originalError=l??void 0,p.nodes=fx(Array.isArray(n)?n:n?[n]:void 0);for(var y=[],b=0,m=(g=p.nodes)!==null&&g!==void 0?g:[];b0},name:{enumerable:!1},nodes:{enumerable:!1},source:{enumerable:!1},positions:{enumerable:!1},originalError:{enumerable:!1}}),l!=null&&l.stack?(Object.defineProperty(S0(p),"stack",{value:l.stack,writable:!0,configurable:!0}),KF(p)):(Error.captureStackTrace?Error.captureStackTrace(S0(p),u):Object.defineProperty(S0(p),"stack",{value:Error().stack,writable:!0,configurable:!0}),p)}return rz(u,[{key:"toString",value:function(){return oz(this)}},{key:GF,get:function(){return"Object"}}]),u}(t3(Error));function fx(t){return t===void 0||t.length===0?void 0:t}function oz(t){var e=t.message;if(t.nodes)for(var u=0,s=t.nodes;un&&px(e[r-1]);)--r;return e.slice(n,r).join(` -`)}function px(t){for(var e=0;e1&&arguments[1]!==void 0?arguments[1]:"",u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,s=t.indexOf(` -`)===-1,n=t[0]===" "||t[0]===" ",r=t[t.length-1]==='"',a=t[t.length-1]==="\\",o=!s||r||a||u,l="";return o&&!(s&&n)&&(l+=` -`+e),l+=e?t.replace(/\n/g,` -`+e):t,o&&(l+=` -`),'"""'+l.replace(/"""/g,'\\"""')+'"""'}var eq=function(){function t(u){var s=new Er(ze.SOF,0,0,0,0,null);this.source=u,this.lastToken=s,this.token=s,this.line=1,this.lineStart=0}var e=t.prototype;return e.advance=function(){this.lastToken=this.token;var s=this.token=this.lookahead();return s},e.lookahead=function(){var s=this.token;if(s.kind!==ze.EOF)do{var n;s=(n=s.next)!==null&&n!==void 0?n:s.next=hz(this,s)}while(s.kind===ze.COMMENT);return s},t}();function fz(t){return t===ze.BANG||t===ze.DOLLAR||t===ze.AMP||t===ze.PAREN_L||t===ze.PAREN_R||t===ze.SPREAD||t===ze.COLON||t===ze.EQUALS||t===ze.AT||t===ze.BRACKET_L||t===ze.BRACKET_R||t===ze.BRACE_L||t===ze.PIPE||t===ze.BRACE_R}function Ws(t){return isNaN(t)?ze.EOF:t<127?JSON.stringify(String.fromCharCode(t)):'"\\u'.concat(("00"+t.toString(16).toUpperCase()).slice(-4),'"')}function hz(t,e){for(var u=t.source,s=u.body,n=s.length,r=e.end;r31||a===9));return new Er(ze.COMMENT,e,o,u,s,n,r.slice(e+1,o))}function bz(t,e,u,s,n,r){var a=t.body,o=u,l=e,c=!1;if(o===45&&(o=a.charCodeAt(++l)),o===48){if(o=a.charCodeAt(++l),o>=48&&o<=57)throw Jn(t,l,"Invalid number, unexpected digit after 0: ".concat(Ws(o),"."))}else l=Qm(t,l,o),o=a.charCodeAt(l);if(o===46&&(c=!0,o=a.charCodeAt(++l),l=Qm(t,l,o),o=a.charCodeAt(l)),(o===69||o===101)&&(c=!0,o=a.charCodeAt(++l),(o===43||o===45)&&(o=a.charCodeAt(++l)),l=Qm(t,l,o),o=a.charCodeAt(l)),o===46||wz(o))throw Jn(t,l,"Invalid number, expected digit but got: ".concat(Ws(o),"."));return new Er(c?ze.FLOAT:ze.INT,e,l,s,n,r,a.slice(e,l))}function Qm(t,e,u){var s=t.body,n=e,r=u;if(r>=48&&r<=57){do r=s.charCodeAt(++n);while(r>=48&&r<=57);return n}throw Jn(t,n,"Invalid number, expected digit but got: ".concat(Ws(r),"."))}function gz(t,e,u,s,n){for(var r=t.body,a=e+1,o=a,l=0,c="";a=48&&t<=57?t-48:t>=65&&t<=70?t-55:t>=97&&t<=102?t-87:-1}function vz(t,e,u,s,n){for(var r=t.body,a=r.length,o=e+1,l=0;o!==a&&!isNaN(l=r.charCodeAt(o))&&(l===95||l>=48&&l<=57||l>=65&&l<=90||l>=97&&l<=122);)++o;return new Er(ze.NAME,e,o,u,s,n,r.slice(e,o))}function wz(t){return t===95||t>=65&&t<=90||t>=97&&t<=122}var tq=Object.freeze({QUERY:"QUERY",MUTATION:"MUTATION",SUBSCRIPTION:"SUBSCRIPTION",FIELD:"FIELD",FRAGMENT_DEFINITION:"FRAGMENT_DEFINITION",FRAGMENT_SPREAD:"FRAGMENT_SPREAD",INLINE_FRAGMENT:"INLINE_FRAGMENT",VARIABLE_DEFINITION:"VARIABLE_DEFINITION",SCHEMA:"SCHEMA",SCALAR:"SCALAR",OBJECT:"OBJECT",FIELD_DEFINITION:"FIELD_DEFINITION",ARGUMENT_DEFINITION:"ARGUMENT_DEFINITION",INTERFACE:"INTERFACE",UNION:"UNION",ENUM:"ENUM",ENUM_VALUE:"ENUM_VALUE",INPUT_OBJECT:"INPUT_OBJECT",INPUT_FIELD_DEFINITION:"INPUT_FIELD_DEFINITION"});function Sz(t,e){var u=new jT(t,e);return u.parseDocument()}function Tz(t,e){var u=new jT(t,e);u.expectToken(ze.SOF);var s=u.parseValueLiteral(!1);return u.expectToken(ze.EOF),s}function Az(t,e){var u=new jT(t,e);u.expectToken(ze.SOF);var s=u.parseTypeReference();return u.expectToken(ze.EOF),s}var jT=function(){function t(u,s){var n=Xk(u)?u:new DT(u);this._lexer=new eq(n),this._options=s}var e=t.prototype;return e.parseName=function(){var s=this.expectToken(ze.NAME);return{kind:rt.NAME,value:s.value,loc:this.loc(s)}},e.parseDocument=function(){var s=this._lexer.token;return{kind:rt.DOCUMENT,definitions:this.many(ze.SOF,this.parseDefinition,ze.EOF),loc:this.loc(s)}},e.parseDefinition=function(){if(this.peek(ze.NAME))switch(this._lexer.token.value){case"query":case"mutation":case"subscription":return this.parseOperationDefinition();case"fragment":return this.parseFragmentDefinition();case"schema":case"scalar":case"type":case"interface":case"union":case"enum":case"input":case"directive":return this.parseTypeSystemDefinition();case"extend":return this.parseTypeSystemExtension()}else{if(this.peek(ze.BRACE_L))return this.parseOperationDefinition();if(this.peekDescription())return this.parseTypeSystemDefinition()}throw this.unexpected()},e.parseOperationDefinition=function(){var s=this._lexer.token;if(this.peek(ze.BRACE_L))return{kind:rt.OPERATION_DEFINITION,operation:"query",name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet(),loc:this.loc(s)};var n=this.parseOperationType(),r;return this.peek(ze.NAME)&&(r=this.parseName()),{kind:rt.OPERATION_DEFINITION,operation:n,name:r,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(s)}},e.parseOperationType=function(){var s=this.expectToken(ze.NAME);switch(s.value){case"query":return"query";case"mutation":return"mutation";case"subscription":return"subscription"}throw this.unexpected(s)},e.parseVariableDefinitions=function(){return this.optionalMany(ze.PAREN_L,this.parseVariableDefinition,ze.PAREN_R)},e.parseVariableDefinition=function(){var s=this._lexer.token;return{kind:rt.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(ze.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(ze.EQUALS)?this.parseValueLiteral(!0):void 0,directives:this.parseDirectives(!0),loc:this.loc(s)}},e.parseVariable=function(){var s=this._lexer.token;return this.expectToken(ze.DOLLAR),{kind:rt.VARIABLE,name:this.parseName(),loc:this.loc(s)}},e.parseSelectionSet=function(){var s=this._lexer.token;return{kind:rt.SELECTION_SET,selections:this.many(ze.BRACE_L,this.parseSelection,ze.BRACE_R),loc:this.loc(s)}},e.parseSelection=function(){return this.peek(ze.SPREAD)?this.parseFragment():this.parseField()},e.parseField=function(){var s=this._lexer.token,n=this.parseName(),r,a;return this.expectOptionalToken(ze.COLON)?(r=n,a=this.parseName()):a=n,{kind:rt.FIELD,alias:r,name:a,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(ze.BRACE_L)?this.parseSelectionSet():void 0,loc:this.loc(s)}},e.parseArguments=function(s){var n=s?this.parseConstArgument:this.parseArgument;return this.optionalMany(ze.PAREN_L,n,ze.PAREN_R)},e.parseArgument=function(){var s=this._lexer.token,n=this.parseName();return this.expectToken(ze.COLON),{kind:rt.ARGUMENT,name:n,value:this.parseValueLiteral(!1),loc:this.loc(s)}},e.parseConstArgument=function(){var s=this._lexer.token;return{kind:rt.ARGUMENT,name:this.parseName(),value:(this.expectToken(ze.COLON),this.parseValueLiteral(!0)),loc:this.loc(s)}},e.parseFragment=function(){var s=this._lexer.token;this.expectToken(ze.SPREAD);var n=this.expectOptionalKeyword("on");return!n&&this.peek(ze.NAME)?{kind:rt.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(!1),loc:this.loc(s)}:{kind:rt.INLINE_FRAGMENT,typeCondition:n?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(s)}},e.parseFragmentDefinition=function(){var s,n=this._lexer.token;return this.expectKeyword("fragment"),((s=this._options)===null||s===void 0?void 0:s.experimentalFragmentVariables)===!0?{kind:rt.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(n)}:{kind:rt.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(n)}},e.parseFragmentName=function(){if(this._lexer.token.value==="on")throw this.unexpected();return this.parseName()},e.parseValueLiteral=function(s){var n=this._lexer.token;switch(n.kind){case ze.BRACKET_L:return this.parseList(s);case ze.BRACE_L:return this.parseObject(s);case ze.INT:return this._lexer.advance(),{kind:rt.INT,value:n.value,loc:this.loc(n)};case ze.FLOAT:return this._lexer.advance(),{kind:rt.FLOAT,value:n.value,loc:this.loc(n)};case ze.STRING:case ze.BLOCK_STRING:return this.parseStringLiteral();case ze.NAME:switch(this._lexer.advance(),n.value){case"true":return{kind:rt.BOOLEAN,value:!0,loc:this.loc(n)};case"false":return{kind:rt.BOOLEAN,value:!1,loc:this.loc(n)};case"null":return{kind:rt.NULL,loc:this.loc(n)};default:return{kind:rt.ENUM,value:n.value,loc:this.loc(n)}}case ze.DOLLAR:if(!s)return this.parseVariable();break}throw this.unexpected()},e.parseStringLiteral=function(){var s=this._lexer.token;return this._lexer.advance(),{kind:rt.STRING,value:s.value,block:s.kind===ze.BLOCK_STRING,loc:this.loc(s)}},e.parseList=function(s){var n=this,r=this._lexer.token,a=function(){return n.parseValueLiteral(s)};return{kind:rt.LIST,values:this.any(ze.BRACKET_L,a,ze.BRACKET_R),loc:this.loc(r)}},e.parseObject=function(s){var n=this,r=this._lexer.token,a=function(){return n.parseObjectField(s)};return{kind:rt.OBJECT,fields:this.any(ze.BRACE_L,a,ze.BRACE_R),loc:this.loc(r)}},e.parseObjectField=function(s){var n=this._lexer.token,r=this.parseName();return this.expectToken(ze.COLON),{kind:rt.OBJECT_FIELD,name:r,value:this.parseValueLiteral(s),loc:this.loc(n)}},e.parseDirectives=function(s){for(var n=[];this.peek(ze.AT);)n.push(this.parseDirective(s));return n},e.parseDirective=function(s){var n=this._lexer.token;return this.expectToken(ze.AT),{kind:rt.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(s),loc:this.loc(n)}},e.parseTypeReference=function(){var s=this._lexer.token,n;return this.expectOptionalToken(ze.BRACKET_L)?(n=this.parseTypeReference(),this.expectToken(ze.BRACKET_R),n={kind:rt.LIST_TYPE,type:n,loc:this.loc(s)}):n=this.parseNamedType(),this.expectOptionalToken(ze.BANG)?{kind:rt.NON_NULL_TYPE,type:n,loc:this.loc(s)}:n},e.parseNamedType=function(){var s=this._lexer.token;return{kind:rt.NAMED_TYPE,name:this.parseName(),loc:this.loc(s)}},e.parseTypeSystemDefinition=function(){var s=this.peekDescription()?this._lexer.lookahead():this._lexer.token;if(s.kind===ze.NAME)switch(s.value){case"schema":return this.parseSchemaDefinition();case"scalar":return this.parseScalarTypeDefinition();case"type":return this.parseObjectTypeDefinition();case"interface":return this.parseInterfaceTypeDefinition();case"union":return this.parseUnionTypeDefinition();case"enum":return this.parseEnumTypeDefinition();case"input":return this.parseInputObjectTypeDefinition();case"directive":return this.parseDirectiveDefinition()}throw this.unexpected(s)},e.peekDescription=function(){return this.peek(ze.STRING)||this.peek(ze.BLOCK_STRING)},e.parseDescription=function(){if(this.peekDescription())return this.parseStringLiteral()},e.parseSchemaDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("schema");var r=this.parseDirectives(!0),a=this.many(ze.BRACE_L,this.parseOperationTypeDefinition,ze.BRACE_R);return{kind:rt.SCHEMA_DEFINITION,description:n,directives:r,operationTypes:a,loc:this.loc(s)}},e.parseOperationTypeDefinition=function(){var s=this._lexer.token,n=this.parseOperationType();this.expectToken(ze.COLON);var r=this.parseNamedType();return{kind:rt.OPERATION_TYPE_DEFINITION,operation:n,type:r,loc:this.loc(s)}},e.parseScalarTypeDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("scalar");var r=this.parseName(),a=this.parseDirectives(!0);return{kind:rt.SCALAR_TYPE_DEFINITION,description:n,name:r,directives:a,loc:this.loc(s)}},e.parseObjectTypeDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("type");var r=this.parseName(),a=this.parseImplementsInterfaces(),o=this.parseDirectives(!0),l=this.parseFieldsDefinition();return{kind:rt.OBJECT_TYPE_DEFINITION,description:n,name:r,interfaces:a,directives:o,fields:l,loc:this.loc(s)}},e.parseImplementsInterfaces=function(){var s;if(!this.expectOptionalKeyword("implements"))return[];if(((s=this._options)===null||s===void 0?void 0:s.allowLegacySDLImplementsInterfaces)===!0){var n=[];this.expectOptionalToken(ze.AMP);do n.push(this.parseNamedType());while(this.expectOptionalToken(ze.AMP)||this.peek(ze.NAME));return n}return this.delimitedMany(ze.AMP,this.parseNamedType)},e.parseFieldsDefinition=function(){var s;return((s=this._options)===null||s===void 0?void 0:s.allowLegacySDLEmptyFields)===!0&&this.peek(ze.BRACE_L)&&this._lexer.lookahead().kind===ze.BRACE_R?(this._lexer.advance(),this._lexer.advance(),[]):this.optionalMany(ze.BRACE_L,this.parseFieldDefinition,ze.BRACE_R)},e.parseFieldDefinition=function(){var s=this._lexer.token,n=this.parseDescription(),r=this.parseName(),a=this.parseArgumentDefs();this.expectToken(ze.COLON);var o=this.parseTypeReference(),l=this.parseDirectives(!0);return{kind:rt.FIELD_DEFINITION,description:n,name:r,arguments:a,type:o,directives:l,loc:this.loc(s)}},e.parseArgumentDefs=function(){return this.optionalMany(ze.PAREN_L,this.parseInputValueDef,ze.PAREN_R)},e.parseInputValueDef=function(){var s=this._lexer.token,n=this.parseDescription(),r=this.parseName();this.expectToken(ze.COLON);var a=this.parseTypeReference(),o;this.expectOptionalToken(ze.EQUALS)&&(o=this.parseValueLiteral(!0));var l=this.parseDirectives(!0);return{kind:rt.INPUT_VALUE_DEFINITION,description:n,name:r,type:a,defaultValue:o,directives:l,loc:this.loc(s)}},e.parseInterfaceTypeDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("interface");var r=this.parseName(),a=this.parseImplementsInterfaces(),o=this.parseDirectives(!0),l=this.parseFieldsDefinition();return{kind:rt.INTERFACE_TYPE_DEFINITION,description:n,name:r,interfaces:a,directives:o,fields:l,loc:this.loc(s)}},e.parseUnionTypeDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("union");var r=this.parseName(),a=this.parseDirectives(!0),o=this.parseUnionMemberTypes();return{kind:rt.UNION_TYPE_DEFINITION,description:n,name:r,directives:a,types:o,loc:this.loc(s)}},e.parseUnionMemberTypes=function(){return this.expectOptionalToken(ze.EQUALS)?this.delimitedMany(ze.PIPE,this.parseNamedType):[]},e.parseEnumTypeDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("enum");var r=this.parseName(),a=this.parseDirectives(!0),o=this.parseEnumValuesDefinition();return{kind:rt.ENUM_TYPE_DEFINITION,description:n,name:r,directives:a,values:o,loc:this.loc(s)}},e.parseEnumValuesDefinition=function(){return this.optionalMany(ze.BRACE_L,this.parseEnumValueDefinition,ze.BRACE_R)},e.parseEnumValueDefinition=function(){var s=this._lexer.token,n=this.parseDescription(),r=this.parseName(),a=this.parseDirectives(!0);return{kind:rt.ENUM_VALUE_DEFINITION,description:n,name:r,directives:a,loc:this.loc(s)}},e.parseInputObjectTypeDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("input");var r=this.parseName(),a=this.parseDirectives(!0),o=this.parseInputFieldsDefinition();return{kind:rt.INPUT_OBJECT_TYPE_DEFINITION,description:n,name:r,directives:a,fields:o,loc:this.loc(s)}},e.parseInputFieldsDefinition=function(){return this.optionalMany(ze.BRACE_L,this.parseInputValueDef,ze.BRACE_R)},e.parseTypeSystemExtension=function(){var s=this._lexer.lookahead();if(s.kind===ze.NAME)switch(s.value){case"schema":return this.parseSchemaExtension();case"scalar":return this.parseScalarTypeExtension();case"type":return this.parseObjectTypeExtension();case"interface":return this.parseInterfaceTypeExtension();case"union":return this.parseUnionTypeExtension();case"enum":return this.parseEnumTypeExtension();case"input":return this.parseInputObjectTypeExtension()}throw this.unexpected(s)},e.parseSchemaExtension=function(){var s=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");var n=this.parseDirectives(!0),r=this.optionalMany(ze.BRACE_L,this.parseOperationTypeDefinition,ze.BRACE_R);if(n.length===0&&r.length===0)throw this.unexpected();return{kind:rt.SCHEMA_EXTENSION,directives:n,operationTypes:r,loc:this.loc(s)}},e.parseScalarTypeExtension=function(){var s=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");var n=this.parseName(),r=this.parseDirectives(!0);if(r.length===0)throw this.unexpected();return{kind:rt.SCALAR_TYPE_EXTENSION,name:n,directives:r,loc:this.loc(s)}},e.parseObjectTypeExtension=function(){var s=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");var n=this.parseName(),r=this.parseImplementsInterfaces(),a=this.parseDirectives(!0),o=this.parseFieldsDefinition();if(r.length===0&&a.length===0&&o.length===0)throw this.unexpected();return{kind:rt.OBJECT_TYPE_EXTENSION,name:n,interfaces:r,directives:a,fields:o,loc:this.loc(s)}},e.parseInterfaceTypeExtension=function(){var s=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");var n=this.parseName(),r=this.parseImplementsInterfaces(),a=this.parseDirectives(!0),o=this.parseFieldsDefinition();if(r.length===0&&a.length===0&&o.length===0)throw this.unexpected();return{kind:rt.INTERFACE_TYPE_EXTENSION,name:n,interfaces:r,directives:a,fields:o,loc:this.loc(s)}},e.parseUnionTypeExtension=function(){var s=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");var n=this.parseName(),r=this.parseDirectives(!0),a=this.parseUnionMemberTypes();if(r.length===0&&a.length===0)throw this.unexpected();return{kind:rt.UNION_TYPE_EXTENSION,name:n,directives:r,types:a,loc:this.loc(s)}},e.parseEnumTypeExtension=function(){var s=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");var n=this.parseName(),r=this.parseDirectives(!0),a=this.parseEnumValuesDefinition();if(r.length===0&&a.length===0)throw this.unexpected();return{kind:rt.ENUM_TYPE_EXTENSION,name:n,directives:r,values:a,loc:this.loc(s)}},e.parseInputObjectTypeExtension=function(){var s=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");var n=this.parseName(),r=this.parseDirectives(!0),a=this.parseInputFieldsDefinition();if(r.length===0&&a.length===0)throw this.unexpected();return{kind:rt.INPUT_OBJECT_TYPE_EXTENSION,name:n,directives:r,fields:a,loc:this.loc(s)}},e.parseDirectiveDefinition=function(){var s=this._lexer.token,n=this.parseDescription();this.expectKeyword("directive"),this.expectToken(ze.AT);var r=this.parseName(),a=this.parseArgumentDefs(),o=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");var l=this.parseDirectiveLocations();return{kind:rt.DIRECTIVE_DEFINITION,description:n,name:r,arguments:a,repeatable:o,locations:l,loc:this.loc(s)}},e.parseDirectiveLocations=function(){return this.delimitedMany(ze.PIPE,this.parseDirectiveLocation)},e.parseDirectiveLocation=function(){var s=this._lexer.token,n=this.parseName();if(tq[n.value]!==void 0)return n;throw this.unexpected(s)},e.loc=function(s){var n;if(((n=this._options)===null||n===void 0?void 0:n.noLocation)!==!0)return new CT(s,this._lexer.lastToken,this._lexer.source)},e.peek=function(s){return this._lexer.token.kind===s},e.expectToken=function(s){var n=this._lexer.token;if(n.kind===s)return this._lexer.advance(),n;throw Jn(this._lexer.source,n.start,"Expected ".concat(rq(s),", found ").concat(Vm(n),"."))},e.expectOptionalToken=function(s){var n=this._lexer.token;if(n.kind===s)return this._lexer.advance(),n},e.expectKeyword=function(s){var n=this._lexer.token;if(n.kind===ze.NAME&&n.value===s)this._lexer.advance();else throw Jn(this._lexer.source,n.start,'Expected "'.concat(s,'", found ').concat(Vm(n),"."))},e.expectOptionalKeyword=function(s){var n=this._lexer.token;return n.kind===ze.NAME&&n.value===s?(this._lexer.advance(),!0):!1},e.unexpected=function(s){var n=s??this._lexer.token;return Jn(this._lexer.source,n.start,"Unexpected ".concat(Vm(n),"."))},e.any=function(s,n,r){this.expectToken(s);for(var a=[];!this.expectOptionalToken(r);)a.push(n.call(this));return a},e.optionalMany=function(s,n,r){if(this.expectOptionalToken(s)){var a=[];do a.push(n.call(this));while(!this.expectOptionalToken(r));return a}return[]},e.many=function(s,n,r){this.expectToken(s);var a=[];do a.push(n.call(this));while(!this.expectOptionalToken(r));return a},e.delimitedMany=function(s,n){this.expectOptionalToken(s);var r=[];do r.push(n.call(this));while(this.expectOptionalToken(s));return r},t}();function Vm(t){var e=t.value;return rq(t.kind)+(e!=null?' "'.concat(e,'"'):"")}function rq(t){return fz(t)?'"'.concat(t,'"'):t}var Ez={Name:[],Document:["definitions"],OperationDefinition:["name","variableDefinitions","directives","selectionSet"],VariableDefinition:["variable","type","defaultValue","directives"],Variable:["name"],SelectionSet:["selections"],Field:["alias","name","arguments","directives","selectionSet"],Argument:["name","value"],FragmentSpread:["name","directives"],InlineFragment:["typeCondition","directives","selectionSet"],FragmentDefinition:["name","variableDefinitions","typeCondition","directives","selectionSet"],IntValue:[],FloatValue:[],StringValue:[],BooleanValue:[],NullValue:[],EnumValue:[],ListValue:["values"],ObjectValue:["fields"],ObjectField:["name","value"],Directive:["name","arguments"],NamedType:["name"],ListType:["type"],NonNullType:["type"],SchemaDefinition:["description","directives","operationTypes"],OperationTypeDefinition:["type"],ScalarTypeDefinition:["description","name","directives"],ObjectTypeDefinition:["description","name","interfaces","directives","fields"],FieldDefinition:["description","name","arguments","type","directives"],InputValueDefinition:["description","name","type","defaultValue","directives"],InterfaceTypeDefinition:["description","name","interfaces","directives","fields"],UnionTypeDefinition:["description","name","directives","types"],EnumTypeDefinition:["description","name","directives","values"],EnumValueDefinition:["description","name","directives"],InputObjectTypeDefinition:["description","name","directives","fields"],DirectiveDefinition:["description","name","arguments","locations"],SchemaExtension:["directives","operationTypes"],ScalarTypeExtension:["name","directives"],ObjectTypeExtension:["name","interfaces","directives","fields"],InterfaceTypeExtension:["name","interfaces","directives","fields"],UnionTypeExtension:["name","directives","types"],EnumTypeExtension:["name","directives","values"],InputObjectTypeExtension:["name","directives","fields"]},Ao=Object.freeze({});function nq(t,e){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Ez,s=void 0,n=Array.isArray(t),r=[t],a=-1,o=[],l=void 0,c=void 0,d=void 0,h=[],f=[],p=t;do{a++;var y=a===r.length,b=y&&o.length!==0;if(y){if(c=f.length===0?void 0:h[h.length-1],l=d,d=f.pop(),b){if(n)l=l.slice();else{for(var m={},g=0,v=Object.keys(l);gxz&&(l=o+Ar(`( -`,M1(dt(n,` -`)),` -)`)),dt([l,dt(r," "),a]," ")},Argument:function(e){var u=e.name,s=e.value;return u+": "+s},FragmentSpread:function(e){var u=e.name,s=e.directives;return"..."+u+Ar(" ",dt(s," "))},InlineFragment:function(e){var u=e.typeCondition,s=e.directives,n=e.selectionSet;return dt(["...",Ar("on ",u),dt(s," "),n]," ")},FragmentDefinition:function(e){var u=e.name,s=e.typeCondition,n=e.variableDefinitions,r=e.directives,a=e.selectionSet;return"fragment ".concat(u).concat(Ar("(",dt(n,", "),")")," ")+"on ".concat(s," ").concat(Ar("",dt(r," ")," "))+a},IntValue:function(e){var u=e.value;return u},FloatValue:function(e){var u=e.value;return u},StringValue:function(e,u){var s=e.value,n=e.block;return n?dz(s,u==="description"?"":" "):JSON.stringify(s)},BooleanValue:function(e){var u=e.value;return u?"true":"false"},NullValue:function(){return"null"},EnumValue:function(e){var u=e.value;return u},ListValue:function(e){var u=e.values;return"["+dt(u,", ")+"]"},ObjectValue:function(e){var u=e.fields;return"{"+dt(u,", ")+"}"},ObjectField:function(e){var u=e.name,s=e.value;return u+": "+s},Directive:function(e){var u=e.name,s=e.arguments;return"@"+u+Ar("(",dt(s,", "),")")},NamedType:function(e){var u=e.name;return u},ListType:function(e){var u=e.type;return"["+u+"]"},NonNullType:function(e){var u=e.type;return u+"!"},SchemaDefinition:hi(function(t){var e=t.directives,u=t.operationTypes;return dt(["schema",dt(e," "),pi(u)]," ")}),OperationTypeDefinition:function(e){var u=e.operation,s=e.type;return u+": "+s},ScalarTypeDefinition:hi(function(t){var e=t.name,u=t.directives;return dt(["scalar",e,dt(u," ")]," ")}),ObjectTypeDefinition:hi(function(t){var e=t.name,u=t.interfaces,s=t.directives,n=t.fields;return dt(["type",e,Ar("implements ",dt(u," & ")),dt(s," "),pi(n)]," ")}),FieldDefinition:hi(function(t){var e=t.name,u=t.arguments,s=t.type,n=t.directives;return e+(yx(u)?Ar(`( -`,M1(dt(u,` -`)),` -)`):Ar("(",dt(u,", "),")"))+": "+s+Ar(" ",dt(n," "))}),InputValueDefinition:hi(function(t){var e=t.name,u=t.type,s=t.defaultValue,n=t.directives;return dt([e+": "+u,Ar("= ",s),dt(n," ")]," ")}),InterfaceTypeDefinition:hi(function(t){var e=t.name,u=t.interfaces,s=t.directives,n=t.fields;return dt(["interface",e,Ar("implements ",dt(u," & ")),dt(s," "),pi(n)]," ")}),UnionTypeDefinition:hi(function(t){var e=t.name,u=t.directives,s=t.types;return dt(["union",e,dt(u," "),s&&s.length!==0?"= "+dt(s," | "):""]," ")}),EnumTypeDefinition:hi(function(t){var e=t.name,u=t.directives,s=t.values;return dt(["enum",e,dt(u," "),pi(s)]," ")}),EnumValueDefinition:hi(function(t){var e=t.name,u=t.directives;return dt([e,dt(u," ")]," ")}),InputObjectTypeDefinition:hi(function(t){var e=t.name,u=t.directives,s=t.fields;return dt(["input",e,dt(u," "),pi(s)]," ")}),DirectiveDefinition:hi(function(t){var e=t.name,u=t.arguments,s=t.repeatable,n=t.locations;return"directive @"+e+(yx(u)?Ar(`( -`,M1(dt(u,` -`)),` -)`):Ar("(",dt(u,", "),")"))+(s?" repeatable":"")+" on "+dt(n," | ")}),SchemaExtension:function(e){var u=e.directives,s=e.operationTypes;return dt(["extend schema",dt(u," "),pi(s)]," ")},ScalarTypeExtension:function(e){var u=e.name,s=e.directives;return dt(["extend scalar",u,dt(s," ")]," ")},ObjectTypeExtension:function(e){var u=e.name,s=e.interfaces,n=e.directives,r=e.fields;return dt(["extend type",u,Ar("implements ",dt(s," & ")),dt(n," "),pi(r)]," ")},InterfaceTypeExtension:function(e){var u=e.name,s=e.interfaces,n=e.directives,r=e.fields;return dt(["extend interface",u,Ar("implements ",dt(s," & ")),dt(n," "),pi(r)]," ")},UnionTypeExtension:function(e){var u=e.name,s=e.directives,n=e.types;return dt(["extend union",u,dt(s," "),n&&n.length!==0?"= "+dt(n," | "):""]," ")},EnumTypeExtension:function(e){var u=e.name,s=e.directives,n=e.values;return dt(["extend enum",u,dt(s," "),pi(n)]," ")},InputObjectTypeExtension:function(e){var u=e.name,s=e.directives,n=e.fields;return dt(["extend input",u,dt(s," "),pi(n)]," ")}};function hi(t){return function(e){return dt([e.description,t(e)],` -`)}}function dt(t){var e,u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";return(e=t==null?void 0:t.filter(function(s){return s}).join(u))!==null&&e!==void 0?e:""}function pi(t){return Ar(`{ -`,M1(dt(t,` -`)),` -}`)}function Ar(t,e){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"";return e!=null&&e!==""?t+e+u:""}function M1(t){return Ar(" ",t.replace(/\n/g,` - `))}function Pz(t){return t.indexOf(` -`)!==-1}function yx(t){return t!=null&&t.some(Pz)}function Dz(t){return iq(t)||aq(t)||oq(t)}function iq(t){return t.kind===rt.OPERATION_DEFINITION||t.kind===rt.FRAGMENT_DEFINITION}function Nz(t){return t.kind===rt.FIELD||t.kind===rt.FRAGMENT_SPREAD||t.kind===rt.INLINE_FRAGMENT}function Cz(t){return t.kind===rt.VARIABLE||t.kind===rt.INT||t.kind===rt.FLOAT||t.kind===rt.STRING||t.kind===rt.BOOLEAN||t.kind===rt.NULL||t.kind===rt.ENUM||t.kind===rt.LIST||t.kind===rt.OBJECT}function jz(t){return t.kind===rt.NAMED_TYPE||t.kind===rt.LIST_TYPE||t.kind===rt.NON_NULL_TYPE}function aq(t){return t.kind===rt.SCHEMA_DEFINITION||sq(t)||t.kind===rt.DIRECTIVE_DEFINITION}function sq(t){return t.kind===rt.SCALAR_TYPE_DEFINITION||t.kind===rt.OBJECT_TYPE_DEFINITION||t.kind===rt.INTERFACE_TYPE_DEFINITION||t.kind===rt.UNION_TYPE_DEFINITION||t.kind===rt.ENUM_TYPE_DEFINITION||t.kind===rt.INPUT_OBJECT_TYPE_DEFINITION}function oq(t){return t.kind===rt.SCHEMA_EXTENSION||uq(t)}function uq(t){return t.kind===rt.SCALAR_TYPE_EXTENSION||t.kind===rt.OBJECT_TYPE_EXTENSION||t.kind===rt.INTERFACE_TYPE_EXTENSION||t.kind===rt.UNION_TYPE_EXTENSION||t.kind===rt.ENUM_TYPE_EXTENSION||t.kind===rt.INPUT_OBJECT_TYPE_EXTENSION}const Lz=Object.freeze(Object.defineProperty({__proto__:null,BREAK:Ao,DirectiveLocation:tq,Kind:rt,Lexer:eq,Location:CT,Source:DT,Token:Er,TokenKind:ze,getLocation:Z1,getVisitFn:eb,isDefinitionNode:Dz,isExecutableDefinitionNode:iq,isSelectionNode:Nz,isTypeDefinitionNode:sq,isTypeExtensionNode:uq,isTypeNode:jz,isTypeSystemDefinitionNode:aq,isTypeSystemExtensionNode:oq,isValueNode:Cz,parse:Sz,parseType:Az,parseValue:Tz,print:Rz,printLocation:XF,printSourceLocation:NT,visit:nq,visitInParallel:Oz},Symbol.toStringTag,{value:"Module"})),Mz=Q3(Lz);var Ec={},km={},Oc={},bx={},gx;function cq(){return gx||(gx=1,function(){(function(t){(function(e){var u={searchParams:"URLSearchParams"in t,iterable:"Symbol"in t&&"iterator"in Symbol,blob:"FileReader"in t&&"Blob"in t&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in t,arrayBuffer:"ArrayBuffer"in t};function s(E){return E&&DataView.prototype.isPrototypeOf(E)}if(u.arrayBuffer)var n=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],r=ArrayBuffer.isView||function(E){return E&&n.indexOf(Object.prototype.toString.call(E))>-1};function a(E){if(typeof E!="string"&&(E=String(E)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(E))throw new TypeError("Invalid character in header field name");return E.toLowerCase()}function o(E){return typeof E!="string"&&(E=String(E)),E}function l(E){var O={next:function(){var P=E.shift();return{done:P===void 0,value:P}}};return u.iterable&&(O[Symbol.iterator]=function(){return O}),O}function c(E){this.map={},E instanceof c?E.forEach(function(O,P){this.append(P,O)},this):Array.isArray(E)?E.forEach(function(O){this.append(O[0],O[1])},this):E&&Object.getOwnPropertyNames(E).forEach(function(O){this.append(O,E[O])},this)}c.prototype.append=function(E,O){E=a(E),O=o(O);var P=this.map[E];this.map[E]=P?P+", "+O:O},c.prototype.delete=function(E){delete this.map[a(E)]},c.prototype.get=function(E){return E=a(E),this.has(E)?this.map[E]:null},c.prototype.has=function(E){return this.map.hasOwnProperty(a(E))},c.prototype.set=function(E,O){this.map[a(E)]=o(O)},c.prototype.forEach=function(E,O){for(var P in this.map)this.map.hasOwnProperty(P)&&E.call(O,this.map[P],P,this)},c.prototype.keys=function(){var E=[];return this.forEach(function(O,P){E.push(P)}),l(E)},c.prototype.values=function(){var E=[];return this.forEach(function(O){E.push(O)}),l(E)},c.prototype.entries=function(){var E=[];return this.forEach(function(O,P){E.push([P,O])}),l(E)},u.iterable&&(c.prototype[Symbol.iterator]=c.prototype.entries);function d(E){if(E.bodyUsed)return Promise.reject(new TypeError("Already read"));E.bodyUsed=!0}function h(E){return new Promise(function(O,P){E.onload=function(){O(E.result)},E.onerror=function(){P(E.error)}})}function f(E){var O=new FileReader,P=h(O);return O.readAsArrayBuffer(E),P}function p(E){var O=new FileReader,P=h(O);return O.readAsText(E),P}function y(E){for(var O=new Uint8Array(E),P=new Array(O.length),j=0;j-1?O:E}function _(E,O){O=O||{};var P=O.body;if(E instanceof _){if(E.bodyUsed)throw new TypeError("Already read");this.url=E.url,this.credentials=E.credentials,O.headers||(this.headers=new c(E.headers)),this.method=E.method,this.mode=E.mode,this.signal=E.signal,!P&&E._bodyInit!=null&&(P=E._bodyInit,E.bodyUsed=!0)}else this.url=String(E);if(this.credentials=O.credentials||this.credentials||"same-origin",(O.headers||!this.headers)&&(this.headers=new c(O.headers)),this.method=v(O.method||this.method||"GET"),this.mode=O.mode||this.mode||null,this.signal=O.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&P)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(P)}_.prototype.clone=function(){return new _(this,{body:this._bodyInit})};function w(E){var O=new FormData;return E.trim().split("&").forEach(function(P){if(P){var j=P.split("="),U=j.shift().replace(/\+/g," "),M=j.join("=").replace(/\+/g," ");O.append(decodeURIComponent(U),decodeURIComponent(M))}}),O}function S(E){var O=new c,P=E.replace(/\r?\n[\t ]+/g," ");return P.split(/\r?\n/).forEach(function(j){var U=j.split(":"),M=U.shift().trim();if(M){var q=U.join(":").trim();O.append(M,q)}}),O}m.call(_.prototype);function A(E,O){O||(O={}),this.type="default",this.status=O.status===void 0?200:O.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in O?O.statusText:"OK",this.headers=new c(O.headers),this.url=O.url||"",this._initBody(E)}m.call(A.prototype),A.prototype.clone=function(){return new A(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new c(this.headers),url:this.url})},A.error=function(){var E=new A(null,{status:0,statusText:""});return E.type="error",E};var D=[301,302,303,307,308];A.redirect=function(E,O){if(D.indexOf(O)===-1)throw new RangeError("Invalid status code");return new A(null,{status:O,headers:{location:E}})},e.DOMException=t.DOMException;try{new e.DOMException}catch{e.DOMException=function(O,P){this.message=O,this.name=P;var j=Error(O);this.stack=j.stack},e.DOMException.prototype=Object.create(Error.prototype),e.DOMException.prototype.constructor=e.DOMException}function L(E,O){return new Promise(function(P,j){var U=new _(E,O);if(U.signal&&U.signal.aborted)return j(new e.DOMException("Aborted","AbortError"));var M=new XMLHttpRequest;function q(){M.abort()}M.onload=function(){var Q={status:M.status,statusText:M.statusText,headers:S(M.getAllResponseHeaders()||"")};Q.url="responseURL"in M?M.responseURL:Q.headers.get("X-Request-URL");var Z="response"in M?M.response:M.responseText;P(new A(Z,Q))},M.onerror=function(){j(new TypeError("Network request failed"))},M.ontimeout=function(){j(new TypeError("Network request failed"))},M.onabort=function(){j(new e.DOMException("Aborted","AbortError"))},M.open(U.method,U.url,!0),U.credentials==="include"?M.withCredentials=!0:U.credentials==="omit"&&(M.withCredentials=!1),"responseType"in M&&u.blob&&(M.responseType="blob"),U.headers.forEach(function(Q,Z){M.setRequestHeader(Z,Q)}),U.signal&&(U.signal.addEventListener("abort",q),M.onreadystatechange=function(){M.readyState===4&&U.signal.removeEventListener("abort",q)}),M.send(typeof U._bodyInit>"u"?null:U._bodyInit)})}return L.polyfill=!0,t.fetch||(t.fetch=L,t.Headers=c,t.Request=_,t.Response=A),e.Headers=c,e.Request=_,e.Response=A,e.fetch=L,Object.defineProperty(e,"__esModule",{value:!0}),e})({})})(typeof self<"u"?self:I)}()),bx}var zm={},sa={},mx;function Fz(){if(mx)return sa;mx=1,Object.defineProperty(sa,"__esModule",{value:!0}),sa.removeDotSegmentsOfPath=sa.removeDotSegments=sa.resolve=void 0;function t(n,r){r=r||"";const a=r.indexOf("#");if(a>0&&(r=r.substr(0,a)),!n.length){if(r.indexOf(":")<0)throw new Error(`Found invalid baseIRI '${r}' for value '${n}'`);return r}if(n.startsWith("?")){const p=r.indexOf("?");return p>0&&(r=r.substr(0,p)),r+n}if(n.startsWith("#"))return r+n;if(!r.length){const p=n.indexOf(":");if(p<0)throw new Error(`Found invalid relative IRI '${n}' for a missing baseIRI`);return u(n,p)}const o=n.indexOf(":");if(o>=0)return u(n,o);const l=r.indexOf(":");if(l<0)throw new Error(`Found invalid baseIRI '${r}' for value '${n}'`);const c=r.substr(0,l+1);if(n.indexOf("//")===0)return c+u(n,o);let d;if(r.indexOf("//",l)===l+1){if(d=r.indexOf("/",l+3),d<0)return r.length>l+3?r+"/"+u(n,o):c+u(n,o)}else if(d=r.indexOf("/",l+1),d<0)return c+u(n,o);if(n.indexOf("/")===0)return r.substr(0,d)+e(n);let h=r.substr(d);const f=h.lastIndexOf("/");return f>=0&&fo.join("")).join("/")}sa.removeDotSegments=e;function u(n,r){let a=r+1;r>=0?n[r+1]==="/"&&n[r+2]==="/"&&(a=r+3):n[0]==="/"&&n[1]==="/"&&(a=2);const o=n.indexOf("/",a);if(o<0)return n;const l=n.substr(0,o),c=n.substr(o);return l+e(c)}sa.removeDotSegmentsOfPath=u;function s(n){return!n||n==="#"||n==="?"||n==="/"}return sa}var _x;function Pi(){return _x||(_x=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Fz(),t)}(zm)),zm}var Gm={},vx;function Ay(){return vx||(vx=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ERROR_CODES=t.ErrorCoded=void 0;class e extends Error{constructor(s,n){super(s),this.code=n}}t.ErrorCoded=e,function(u){u.COLLIDING_KEYWORDS="colliding keywords",u.CONFLICTING_INDEXES="conflicting indexes",u.CYCLIC_IRI_MAPPING="cyclic IRI mapping",u.INVALID_ID_VALUE="invalid @id value",u.INVALID_INDEX_VALUE="invalid @index value",u.INVALID_NEST_VALUE="invalid @nest value",u.INVALID_PREFIX_VALUE="invalid @prefix value",u.INVALID_PROPAGATE_VALUE="invalid @propagate value",u.INVALID_REVERSE_VALUE="invalid @reverse value",u.INVALID_IMPORT_VALUE="invalid @import value",u.INVALID_VERSION_VALUE="invalid @version value",u.INVALID_BASE_IRI="invalid base IRI",u.INVALID_CONTAINER_MAPPING="invalid container mapping",u.INVALID_CONTEXT_ENTRY="invalid context entry",u.INVALID_CONTEXT_NULLIFICATION="invalid context nullification",u.INVALID_DEFAULT_LANGUAGE="invalid default language",u.INVALID_INCLUDED_VALUE="invalid @included value",u.INVALID_IRI_MAPPING="invalid IRI mapping",u.INVALID_JSON_LITERAL="invalid JSON literal",u.INVALID_KEYWORD_ALIAS="invalid keyword alias",u.INVALID_LANGUAGE_MAP_VALUE="invalid language map value",u.INVALID_LANGUAGE_MAPPING="invalid language mapping",u.INVALID_LANGUAGE_TAGGED_STRING="invalid language-tagged string",u.INVALID_LANGUAGE_TAGGED_VALUE="invalid language-tagged value",u.INVALID_LOCAL_CONTEXT="invalid local context",u.INVALID_REMOTE_CONTEXT="invalid remote context",u.INVALID_REVERSE_PROPERTY="invalid reverse property",u.INVALID_REVERSE_PROPERTY_MAP="invalid reverse property map",u.INVALID_REVERSE_PROPERTY_VALUE="invalid reverse property value",u.INVALID_SCOPED_CONTEXT="invalid scoped context",u.INVALID_SCRIPT_ELEMENT="invalid script element",u.INVALID_SET_OR_LIST_OBJECT="invalid set or list object",u.INVALID_TERM_DEFINITION="invalid term definition",u.INVALID_TYPE_MAPPING="invalid type mapping",u.INVALID_TYPE_VALUE="invalid type value",u.INVALID_TYPED_VALUE="invalid typed value",u.INVALID_VALUE_OBJECT="invalid value object",u.INVALID_VALUE_OBJECT_VALUE="invalid value object value",u.INVALID_VOCAB_MAPPING="invalid vocab mapping",u.IRI_CONFUSED_WITH_PREFIX="IRI confused with prefix",u.KEYWORD_REDEFINITION="keyword redefinition",u.LOADING_DOCUMENT_FAILED="loading document failed",u.LOADING_REMOTE_CONTEXT_FAILED="loading remote context failed",u.MULTIPLE_CONTEXT_LINK_HEADERS="multiple context link headers",u.PROCESSING_MODE_CONFLICT="processing mode conflict",u.PROTECTED_TERM_REDEFINITION="protected term redefinition",u.CONTEXT_OVERFLOW="context overflow",u.INVALID_BASE_DIRECTION="invalid base direction",u.RECURSIVE_CONTEXT_INCLUSION="recursive context inclusion",u.INVALID_STREAMING_KEY_ORDER="invalid streaming key order",u.INVALID_EMBEDDED_NODE="invalid embedded node",u.INVALID_ANNOTATION="invalid annotation"}(t.ERROR_CODES||(t.ERROR_CODES={}))}(Gm)),Gm}var Rc={},Wm,wx;function lq(){if(wx)return Wm;wx=1;var t=/^utf-?8|ascii|utf-?16-?le|ucs-?2|base-?64|latin-?1$/i,e=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,u=/\s|\uFEFF|\xA0/,s=/\r?\n[\x20\x09]+/g,n=/[;,"]/,r=/[;,"]|\s/,a=/^[!#$%&'*+\-\.^_`|~\da-zA-Z]+$/,o={IDLE:1,URI:2,ATTR:4};function l(y){return y.replace(e,"")}function c(y){return u.test(y)}function d(y,b){for(;c(y[b]);)b++;return b}function h(y){return r.test(y)||!a.test(y)}function f(y,b){return Object.keys(y).length===Object.keys(b).length&&Object.keys(y).every(m=>m in b&&y[m]===b[m])}class p{constructor(b){this.refs=[],b&&this.parse(b)}rel(b){for(var m=[],g=b.toLowerCase(),v=0;vf(m,b))||this.refs.push(b),this}has(b,m){b=b.toLowerCase(),m=m.toLowerCase();for(var g=0;g",_);if(S===-1)throw new Error("Expected end of URI delimiter at offset "+_);w={uri:b.slice(_+1,S)},_=S,g=o.URI}else throw new Error('Unexpected character "'+b[_]+'" at offset '+_);_++}else if(g===o.URI)if(c(b[_])){_++;continue}else if(b[_]===";")g=o.ATTR,_++;else if(b[_]===",")g=o.IDLE,_++;else throw new Error('Unexpected character "'+b[_]+'" at offset '+_);else if(g===o.ATTR){if(b[_]===";"||c(b[_])){_++;continue}var S=b.indexOf("=",_);S===-1&&(S=b.indexOf(";",_)),S===-1&&(S=b.length);var A=l(b.slice(_,S)).toLowerCase(),D="";if(_=S+1,_=d(b,_),b[_]==='"')for(_++;_"),b.push(m);return b.join(", ")}}return p.isCompatibleEncoding=function(y){return t.test(y)},p.parse=function(y,b){return new p().parse(y,b)},p.isSingleOccurenceAttr=function(y){return y==="rel"||y==="type"||y==="media"||y==="title"||y==="title*"},p.isTokenAttr=function(y){return y==="rel"||y==="type"||y==="anchor"},p.escapeQuotes=function(y){return y.replace(/"/g,'\\"')},p.expandRelations=function(y){var b=y.rel.split(" ");return b.map(function(m){var g=Object.assign({},y);return g.rel=m,g})},p.parseExtendedValue=function(y){var b=/([^']+)?(?:'([^']*)')?(.+)/.exec(y);return{language:b[2].toLowerCase(),encoding:p.isCompatibleEncoding(b[1])?null:b[1].toLowerCase(),value:p.isCompatibleEncoding(b[1])?decodeURIComponent(b[3]):b[3]}},p.formatExtendedAttribute=function(y,b){var m=(b.encoding||"utf-8").toUpperCase(),g=b.language||"en",v="";return Buffer.isBuffer(b.value)&&p.isCompatibleEncoding(m)?v=b.value.toString(m):Buffer.isBuffer(b.value)?v=b.value.toString("hex").replace(/[0-9a-f]{2}/gi,"%$1"):v=encodeURIComponent(b.value),y+"="+m+"'"+g+"'"+v},p.formatAttribute=function(y,b){return Array.isArray(b)?b.map(m=>p.formatAttribute(y,m)).join("; "):y[y.length-1]==="*"||typeof b!="string"?p.formatExtendedAttribute(y,b):(p.isTokenAttr(y)?b=h(b)?'"'+p.escapeQuotes(b)+'"':p.escapeQuotes(b):h(b)&&(b=encodeURIComponent(b),b=b.replace(/%20/g," ").replace(/%2C/g,",").replace(/%3B/g,";"),b='"'+b+'"'),y+"="+b)},Wm=p,Wm}var Sx;function dq(){if(Sx)return Rc;Sx=1,Object.defineProperty(Rc,"__esModule",{value:!0}),Rc.FetchDocumentLoader=void 0,cq();const t=Ay(),e=lq(),u=Pi();let s=class{constructor(r){this.fetcher=r}async load(r){const a=await(this.fetcher||fetch)(r,{headers:new Headers({accept:"application/ld+json"})});if(a.ok&&a.headers){let o=a.headers.get("Content-Type");if(o){const l=o.indexOf(";");l>0&&(o=o.substr(0,l))}if(o==="application/ld+json")return await a.json();if(a.headers.has("Link")){let l;if(a.headers.forEach((c,d)=>{if(d==="link"){const h=(0,e.parse)(c);for(const f of h.get("type","application/ld+json"))if(f.rel==="alternate"){if(l)throw new Error("Multiple JSON-LD alternate links were found on "+r);l=(0,u.resolve)(f.uri,r)}}}),l)return this.load(l)}throw new t.ErrorCoded(`Unsupported JSON-LD media type ${o}`,t.ERROR_CODES.LOADING_DOCUMENT_FAILED)}else throw new Error(a.statusText||`Status code: ${a.status}`)}};return Rc.FetchDocumentLoader=s,Rc}var Jm={},xc={},Tx;function LT(){if(Tx)return xc;Tx=1,Object.defineProperty(xc,"__esModule",{value:!0}),xc.Util=void 0;class t{static isCompactIri(u){return u.indexOf(":")>0&&!(u&&u[0]==="#")}static getPrefix(u,s){if(u&&u[0]==="#")return null;const n=u.indexOf(":");if(n>=0){if(u.length>n+1&&u.charAt(n+1)==="/"&&u.charAt(n+2)==="/")return null;const r=u.substr(0,n);if(r==="_")return null;if(s[r])return r}return null}static getContextValueId(u){if(u===null||typeof u=="string")return u;const s=u["@id"];return s||null}static isSimpleTermDefinitionPrefix(u,s){return!t.isPotentialKeyword(u)&&(s.allowPrefixNonGenDelims||typeof u=="string"&&(u[0]==="_"||t.isPrefixIriEndingWithGenDelim(u)))}static isPotentialKeyword(u){return typeof u=="string"&&t.KEYWORD_REGEX.test(u)}static isPrefixIriEndingWithGenDelim(u){return t.ENDS_WITH_GEN_DELIM.test(u)}static isPrefixValue(u){return u&&(typeof u=="string"||u&&typeof u=="object")}static isValidIri(u){return!!(u&&t.IRI_REGEX.test(u))}static isValidIriWeak(u){return!!u&&u[0]!==":"&&t.IRI_REGEX_WEAK.test(u)}static isValidKeyword(u){return t.VALID_KEYWORDS[u]}static isTermProtected(u,s){const n=u[s];return typeof n!="string"&&n&&n["@protected"]}static hasProtectedTerms(u){for(const s of Object.keys(u))if(t.isTermProtected(u,s))return!0;return!1}static isReservedInternalKeyword(u){return u.startsWith("@__")}static deepEqual(u,s){const n=Object.keys(u),r=Object.keys(s);return n.length!==r.length?!1:n.every(a=>{const o=u[a],l=s[a];return o===l||o!==null&&l!==null&&typeof o=="object"&&typeof l=="object"&&this.deepEqual(o,l)})}}return t.IRI_REGEX=/^([A-Za-z][A-Za-z0-9+-.]*|_):[^ "<>{}|\\\[\]`#]*(#[^#]*)?$/,t.IRI_REGEX_WEAK=/(?::[^:])|\//,t.KEYWORD_REGEX=/^@[a-z]+$/i,t.ENDS_WITH_GEN_DELIM=/[:/?#\[\]@]$/,t.REGEX_LANGUAGE_TAG=/^[a-zA-Z]+(-[a-zA-Z0-9]+)*$/,t.REGEX_DIRECTION_TAG=/^(ltr)|(rtl)$/,t.VALID_KEYWORDS={"@annotation":!0,"@base":!0,"@container":!0,"@context":!0,"@direction":!0,"@graph":!0,"@id":!0,"@import":!0,"@included":!0,"@index":!0,"@json":!0,"@language":!0,"@list":!0,"@nest":!0,"@none":!0,"@prefix":!0,"@propagate":!0,"@protected":!0,"@reverse":!0,"@set":!0,"@type":!0,"@value":!0,"@version":!0,"@vocab":!0},t.EXPAND_KEYS_BLACKLIST=["@base","@vocab","@language","@version","@direction"],t.ALIAS_DOMAIN_BLACKLIST=["@container","@graph","@id","@index","@list","@nest","@none","@prefix","@reverse","@set","@type","@value","@version"],t.ALIAS_RANGE_BLACKLIST=["@context","@preserve"],t.CONTAINERS=["@list","@set","@index","@language","@graph","@id","@type"],t.CONTAINERS_1_0=["@list","@set","@index"],xc.Util=t,xc}var Ax;function fq(){return Ax||(Ax=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.defaultExpandOptions=t.JsonLdContextNormalized=void 0;const e=Pi(),u=Ay(),s=LT();class n{constructor(a){this.contextRaw=a}getContextRaw(){return this.contextRaw}expandTerm(a,o,l=t.defaultExpandOptions){const c=this.contextRaw[a];if(c===null||c&&c["@id"]===null)return null;let d=!0;if(c&&o){const m=s.Util.getContextValueId(c);if(m&&m!==a)if(typeof m!="string"||!s.Util.isValidIri(m)&&!s.Util.isValidKeyword(m))s.Util.isPotentialKeyword(m)||(d=!1);else return m}const h=s.Util.getPrefix(a,this.contextRaw),f=this.contextRaw["@vocab"],p=(!!f||f==="")&&f.indexOf(":")<0,y=this.contextRaw["@base"],b=s.Util.isPotentialKeyword(a);if(h){const m=this.contextRaw[h],g=s.Util.getContextValueId(m);if(g){if(typeof m=="string"||!l.allowPrefixForcing){if(!s.Util.isSimpleTermDefinitionPrefix(g,l))return a}else if(g[0]!=="_"&&!b&&!m["@prefix"]&&!(a in this.contextRaw))return a;return g+a.substr(h.length+1)}}else if(o&&(f||f===""||l.allowVocabRelativeToBase&&y&&p)&&!b&&!s.Util.isCompactIri(a))if(p){if(l.allowVocabRelativeToBase)return(f||y?(0,e.resolve)(f,y):"")+a;throw new u.ErrorCoded(`Relative vocab expansion for term '${a}' with vocab '${f}' is not allowed.`,u.ERROR_CODES.INVALID_VOCAB_MAPPING)}else return f+a;else if(!o&&y&&!b&&!s.Util.isCompactIri(a))return(0,e.resolve)(a,y);if(d)return a;throw new u.ErrorCoded(`Invalid IRI mapping found for context entry '${a}': '${JSON.stringify(c)}'`,u.ERROR_CODES.INVALID_IRI_MAPPING)}compactIri(a,o){if(o&&this.contextRaw["@vocab"]&&a.startsWith(this.contextRaw["@vocab"]))return a.substr(this.contextRaw["@vocab"].length);if(!o&&this.contextRaw["@base"]&&a.startsWith(this.contextRaw["@base"]))return a.substr(this.contextRaw["@base"].length);const l={prefix:"",suffix:a};for(const c in this.contextRaw){const d=this.contextRaw[c];if(d&&!s.Util.isPotentialKeyword(c)){const h=s.Util.getContextValueId(d);if(a.startsWith(h)){const f=a.substr(h.length);if(f)f.length=0&&(h!=="@type"||typeof d[h]=="object"&&!(d[h]["@protected"]||d[h]["@container"]==="@set")))throw new e.ErrorCoded(`Keywords can not be aliased to something else. -Tried mapping ${h} to ${JSON.stringify(f)}`,e.ERROR_CODES.KEYWORD_REDEFINITION);if(n.Util.ALIAS_RANGE_BLACKLIST.indexOf(n.Util.getContextValueId(f))>=0)throw new e.ErrorCoded(`Aliasing to certain keywords is not allowed. -Tried mapping ${h} to ${JSON.stringify(f)}`,e.ERROR_CODES.INVALID_KEYWORD_ALIAS);if(f&&n.Util.isPotentialKeyword(n.Util.getContextValueId(f))&&f["@prefix"]===!0)throw new e.ErrorCoded(`Tried to use keyword aliases as prefix: '${h}': '${JSON.stringify(f)}'`,e.ERROR_CODES.INVALID_TERM_DEFINITION);for(;n.Util.isPrefixValue(d[h]);){const p=d[h];let y=!1;if(typeof p=="string")d[h]=o.expandTerm(p,!0),y=y||p!==d[h];else{const b=p["@id"],m=p["@type"],g=!("@prefix"in p)||n.Util.isValidIri(h);if("@id"in p)b!=null&&typeof b=="string"&&(d[h]=Object.assign(Object.assign({},d[h]),{"@id":o.expandTerm(b,!0)}),y=y||b!==d[h]["@id"]);else if(!n.Util.isPotentialKeyword(h)&&g){const v=o.expandTerm(h,!0);v!==h&&(d[h]=Object.assign(Object.assign({},d[h]),{"@id":v}),y=!0)}if(m&&typeof m=="string"&&m!=="@vocab"&&(!p["@container"]||!p["@container"]["@type"])&&g){let v=o.expandTerm(m,!0);l&&m===v&&(v=o.expandTerm(m,!1)),v!==m&&(y=!0,d[h]=Object.assign(Object.assign({},d[h]),{"@type":v}))}}if(!y)break}}}normalize(o,{processingMode:l,normalizeLanguageTags:c}){if(c||l===1)for(const d of Object.keys(o))if(d==="@language"&&typeof o[d]=="string")o[d]=o[d].toLowerCase();else{const h=o[d];if(h&&typeof h=="object"&&typeof h["@language"]=="string"){const f=h["@language"].toLowerCase();f!==h["@language"]&&(o[d]=Object.assign(Object.assign({},h),{"@language":f}))}}}containersToHash(o){for(const l of Object.keys(o)){const c=o[l];if(c&&typeof c=="object"){if(typeof c["@container"]=="string")o[l]=Object.assign(Object.assign({},c),{"@container":{[c["@container"]]:!0}});else if(Array.isArray(c["@container"])){const d={};for(const h of c["@container"])d[h]=!0;o[l]=Object.assign(Object.assign({},c),{"@container":d})}}}}applyScopedProtected(o,{processingMode:l},c){if(l&&l>=1.1&&o["@protected"]){for(const d of Object.keys(o))if(!n.Util.isReservedInternalKeyword(d)&&!n.Util.isPotentialKeyword(d)&&!n.Util.isTermProtected(o,d)){const h=o[d];h&&typeof h=="object"?"@protected"in o[d]||(o[d]=Object.assign(Object.assign({},o[d]),{"@protected":!0})):(o[d]={"@id":h,"@protected":!0},n.Util.isSimpleTermDefinitionPrefix(h,c)&&(o[d]=Object.assign(Object.assign({},o[d]),{"@prefix":!0})))}delete o["@protected"]}}validateKeywordRedefinitions(o,l,c,d){for(const h of d??Object.keys(l))if(n.Util.isTermProtected(o,h)&&(typeof l[h]=="string"?l[h]={"@id":l[h],"@protected":!0}:l[h]=Object.assign(Object.assign({},l[h]),{"@protected":!0}),!n.Util.deepEqual(o[h],l[h])))throw new e.ErrorCoded(`Attempted to override the protected keyword ${h} from ${JSON.stringify(n.Util.getContextValueId(o[h]))} to ${JSON.stringify(n.Util.getContextValueId(l[h]))}`,e.ERROR_CODES.PROTECTED_TERM_REDEFINITION)}validate(o,{processingMode:l}){for(const c of Object.keys(o)){if(n.Util.isReservedInternalKeyword(c))continue;if(c==="")throw new e.ErrorCoded(`The empty term is not allowed, got: '${c}': '${JSON.stringify(o[c])}'`,e.ERROR_CODES.INVALID_TERM_DEFINITION);const d=o[c],h=typeof d;if(n.Util.isPotentialKeyword(c)){switch(c.substr(1)){case"vocab":if(d!==null&&h!=="string")throw new e.ErrorCoded(`Found an invalid @vocab IRI: ${d}`,e.ERROR_CODES.INVALID_VOCAB_MAPPING);break;case"base":if(d!==null&&h!=="string")throw new e.ErrorCoded(`Found an invalid @base IRI: ${o[c]}`,e.ERROR_CODES.INVALID_BASE_IRI);break;case"language":d!==null&&Ds.validateLanguage(d,!0,e.ERROR_CODES.INVALID_DEFAULT_LANGUAGE);break;case"version":if(d!==null&&h!=="number")throw new e.ErrorCoded(`Found an invalid @version number: ${d}`,e.ERROR_CODES.INVALID_VERSION_VALUE);break;case"direction":d!==null&&Ds.validateDirection(d,!0);break;case"propagate":if(l===1)throw new e.ErrorCoded(`Found an illegal @propagate keyword: ${d}`,e.ERROR_CODES.INVALID_CONTEXT_ENTRY);if(d!==null&&h!=="boolean")throw new e.ErrorCoded(`Found an invalid @propagate value: ${d}`,e.ERROR_CODES.INVALID_PROPAGATE_VALUE);break}if(n.Util.isValidKeyword(c)&&n.Util.isValidKeyword(n.Util.getContextValueId(d)))throw new e.ErrorCoded(`Illegal keyword alias in term value, found: '${c}': '${n.Util.getContextValueId(d)}'`,e.ERROR_CODES.KEYWORD_REDEFINITION);continue}if(d!==null)switch(h){case"string":if(n.Util.getPrefix(d,o)===c)throw new e.ErrorCoded(`Detected cyclical IRI mapping in context entry: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.CYCLIC_IRI_MAPPING);if(n.Util.isValidIriWeak(c)){if(d==="@type")throw new e.ErrorCoded(`IRIs can not be mapped to @type, found: '${c}': '${d}'`,e.ERROR_CODES.INVALID_IRI_MAPPING);if(n.Util.isValidIri(d)&&d!==new s.JsonLdContextNormalized(o).expandTerm(c))throw new e.ErrorCoded(`IRIs can not be mapped to other IRIs, found: '${c}': '${d}'`,e.ERROR_CODES.INVALID_IRI_MAPPING)}break;case"object":if(!n.Util.isCompactIri(c)&&!("@id"in d)&&(d["@type"]==="@id"?!o["@base"]:!o["@vocab"]))throw new e.ErrorCoded(`Missing @id in context entry: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_IRI_MAPPING);for(const f of Object.keys(d)){const p=d[f];if(p)switch(f){case"@id":if(n.Util.isValidKeyword(p)&&p!=="@type"&&p!=="@id"&&p!=="@graph"&&p!=="@nest")throw new e.ErrorCoded(`Illegal keyword alias in term value, found: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_IRI_MAPPING);if(n.Util.isValidIriWeak(c)){if(p==="@type")throw new e.ErrorCoded(`IRIs can not be mapped to @type, found: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_IRI_MAPPING);if(n.Util.isValidIri(p)&&p!==new s.JsonLdContextNormalized(o).expandTerm(c))throw new e.ErrorCoded(`IRIs can not be mapped to other IRIs, found: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_IRI_MAPPING)}if(typeof p!="string")throw new e.ErrorCoded(`Detected non-string @id in context entry: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_IRI_MAPPING);if(n.Util.getPrefix(p,o)===c)throw new e.ErrorCoded(`Detected cyclical IRI mapping in context entry: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.CYCLIC_IRI_MAPPING);break;case"@type":if(d["@container"]==="@type"&&p!=="@id"&&p!=="@vocab")throw new e.ErrorCoded(`@container: @type only allows @type: @id or @vocab, but got: '${c}': '${p}'`,e.ERROR_CODES.INVALID_TYPE_MAPPING);if(typeof p!="string")throw new e.ErrorCoded(`The value of an '@type' must be a string, got '${JSON.stringify(h)}'`,e.ERROR_CODES.INVALID_TYPE_MAPPING);if(p!=="@id"&&p!=="@vocab"&&(l===1||p!=="@json")&&(l===1||p!=="@none")&&(p[0]==="_"||!n.Util.isValidIri(p)))throw new e.ErrorCoded(`A context @type must be an absolute IRI, found: '${c}': '${p}'`,e.ERROR_CODES.INVALID_TYPE_MAPPING);break;case"@reverse":if(typeof p=="string"&&d["@id"]&&d["@id"]!==p)throw new e.ErrorCoded(`Found non-matching @id and @reverse term values in '${c}':'${p}' and '${d["@id"]}'`,e.ERROR_CODES.INVALID_REVERSE_PROPERTY);if("@nest"in d)throw new e.ErrorCoded(`@nest is not allowed in the reverse property '${c}'`,e.ERROR_CODES.INVALID_REVERSE_PROPERTY);break;case"@container":if(l===1&&(Object.keys(p).length>1||n.Util.CONTAINERS_1_0.indexOf(Object.keys(p)[0])<0))throw new e.ErrorCoded(`Invalid term @container for '${c}' ('${Object.keys(p)}') in 1.0, must be only one of ${n.Util.CONTAINERS_1_0.join(", ")}`,e.ERROR_CODES.INVALID_CONTAINER_MAPPING);for(const y of Object.keys(p)){if(y==="@list"&&d["@reverse"])throw new e.ErrorCoded(`Term value can not be @container: @list and @reverse at the same time on '${c}'`,e.ERROR_CODES.INVALID_REVERSE_PROPERTY);if(n.Util.CONTAINERS.indexOf(y)<0)throw new e.ErrorCoded(`Invalid term @container for '${c}' ('${y}'), must be one of ${n.Util.CONTAINERS.join(", ")}`,e.ERROR_CODES.INVALID_CONTAINER_MAPPING)}break;case"@language":Ds.validateLanguage(p,!0,e.ERROR_CODES.INVALID_LANGUAGE_MAPPING);break;case"@direction":Ds.validateDirection(p,!0);break;case"@prefix":if(p!==null&&typeof p!="boolean")throw new e.ErrorCoded(`Found an invalid term @prefix boolean in: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_PREFIX_VALUE);if(!("@id"in d)&&!n.Util.isValidIri(c))throw new e.ErrorCoded(`Invalid @prefix definition for '${c}' ('${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_TERM_DEFINITION);break;case"@index":if(l===1||!d["@container"]||!d["@container"]["@index"])throw new e.ErrorCoded(`Attempt to add illegal key to value object: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_TERM_DEFINITION);break;case"@nest":if(n.Util.isPotentialKeyword(p)&&p!=="@nest")throw new e.ErrorCoded(`Found an invalid term @nest value in: '${c}': '${JSON.stringify(d)}'`,e.ERROR_CODES.INVALID_NEST_VALUE)}}break;default:throw new e.ErrorCoded(`Found an invalid term value: '${c}': '${d}'`,e.ERROR_CODES.INVALID_TERM_DEFINITION)}}}applyBaseEntry(o,l,c){return typeof o=="string"||(c&&!("@base"in o)&&l.parentContext&&typeof l.parentContext=="object"&&"@base"in l.parentContext&&(o["@base"]=l.parentContext["@base"],l.parentContext["@__baseDocument"]&&(o["@__baseDocument"]=!0)),l.baseIRI&&!l.external&&("@base"in o?o["@base"]!==null&&typeof o["@base"]=="string"&&!n.Util.isValidIri(o["@base"])&&(o["@base"]=(0,t.resolve)(o["@base"],l.parentContext&&l.parentContext["@base"]||l.baseIRI)):(o["@base"]=l.baseIRI,o["@__baseDocument"]=!0))),o}normalizeContextIri(o,l){if(!n.Util.isValidIri(o))try{o=(0,t.resolve)(o,l)}catch{throw new Error(`Invalid context IRI: ${o}`)}return this.redirectSchemaOrgHttps&&o.startsWith("http://schema.org")&&(o="https://schema.org/"),o}async parseInnerContexts(o,l,c){for(const d of c??Object.keys(o)){const h=o[d];if(h&&typeof h=="object"&&"@context"in h&&h["@context"]!==null&&!l.ignoreScopedContexts){if(this.validateContext)try{const f=Object.assign(Object.assign({},o),{[d]:Object.assign({},o[d])});delete f[d]["@context"],await this.parse(h["@context"],Object.assign(Object.assign({},l),{external:!1,parentContext:f,ignoreProtection:!0,ignoreRemoteScopedContexts:!0,ignoreScopedContexts:!0}))}catch(f){throw new e.ErrorCoded(f.message,e.ERROR_CODES.INVALID_SCOPED_CONTEXT)}o[d]=Object.assign(Object.assign({},h),{"@context":(await this.parse(h["@context"],Object.assign(Object.assign({},l),{external:!1,minimalProcessing:!0,ignoreRemoteScopedContexts:!0,parentContext:o}))).getContextRaw()})}}return o}async parse(o,l={},c={}){const{baseIRI:d,parentContext:h,external:f,processingMode:p=Ds.DEFAULT_PROCESSING_MODE,normalizeLanguageTags:y,ignoreProtection:b,minimalProcessing:m}=l,g=l.remoteContexts||{};if(Object.keys(g).length>=this.remoteContextsDepthLimit)throw new e.ErrorCoded("Detected an overflow in remote context inclusions: "+Object.keys(g),e.ERROR_CODES.CONTEXT_OVERFLOW);if(o==null){if(!b&&h&&n.Util.hasProtectedTerms(h))throw new e.ErrorCoded("Illegal context nullification when terms are protected",e.ERROR_CODES.INVALID_CONTEXT_NULLIFICATION);return new s.JsonLdContextNormalized(this.applyBaseEntry({},l,!1))}else if(typeof o=="string"){const v=this.normalizeContextIri(o,d),_=this.getOverriddenLoad(v,l);if(_)return new s.JsonLdContextNormalized(_);const w=await this.parse(await this.load(v),Object.assign(Object.assign({},l),{baseIRI:v,external:!0,remoteContexts:Object.assign(Object.assign({},g),{[v]:!0})}));return this.applyBaseEntry(w.getContextRaw(),l,!0),w}else if(Array.isArray(o)){const v=[],_=await Promise.all(o.map((S,A)=>{if(typeof S=="string"){const D=this.normalizeContextIri(S,d);v[A]=D;const L=this.getOverriddenLoad(D,l);return L||this.load(D)}else return S}));if(m)return new s.JsonLdContextNormalized(_);const w=await _.reduce((S,A,D)=>S.then(L=>this.parse(A,Object.assign(Object.assign({},l),{baseIRI:v[D]||l.baseIRI,external:!!v[D]||l.external,parentContext:L.getContextRaw(),remoteContexts:v[D]?Object.assign(Object.assign({},g),{[v[D]]:!0}):g}),{skipValidation:D<_.length-1})),Promise.resolve(new s.JsonLdContextNormalized(h||{})));return this.applyBaseEntry(w.getContextRaw(),l,!0),w}else if(typeof o=="object"){if("@context"in o)return await this.parse(o["@context"],l);if(o=Object.assign({},o),f&&delete o["@base"],this.applyBaseEntry(o,l,!0),this.containersToHash(o),m)return new s.JsonLdContextNormalized(o);let v={};if("@import"in o)if(p>=1.1){if(typeof o["@import"]!="string")throw new e.ErrorCoded("An @import value must be a string, but got "+typeof o["@import"],e.ERROR_CODES.INVALID_IMPORT_VALUE);v=await this.loadImportContext(this.normalizeContextIri(o["@import"],d)),delete o["@import"]}else throw new e.ErrorCoded("Context importing is not supported in JSON-LD 1.0",e.ERROR_CODES.INVALID_CONTEXT_ENTRY);this.applyScopedProtected(v,{processingMode:p},s.defaultExpandOptions);const _=Object.assign(v,o);this.idifyReverseTerms(_),this.normalize(_,{processingMode:p,normalizeLanguageTags:y}),this.applyScopedProtected(_,{processingMode:p},s.defaultExpandOptions);const w=Object.keys(_),S=[];if(typeof h=="object")for(const D in h)D in _?S.push(D):_[D]=h[D];await this.parseInnerContexts(_,l,w);const A=new s.JsonLdContextNormalized(_);return(_&&_["@version"]||Ds.DEFAULT_PROCESSING_MODE)>=1.1&&(o["@vocab"]&&typeof o["@vocab"]=="string"||o["@vocab"]==="")&&(h&&"@vocab"in h&&o["@vocab"].indexOf(":")<0?_["@vocab"]=h["@vocab"]+o["@vocab"]:(n.Util.isCompactIri(o["@vocab"])||o["@vocab"]in _)&&(_["@vocab"]=A.expandTerm(o["@vocab"],!0))),this.expandPrefixedTerms(A,this.expandContentTypeToBase,w),!b&&h&&p>=1.1&&this.validateKeywordRedefinitions(h,_,s.defaultExpandOptions,S),this.validateContext&&!c.skipValidation&&this.validate(_,{processingMode:p}),A}else throw new e.ErrorCoded(`Tried parsing a context that is not a string, array or object, but got ${o}`,e.ERROR_CODES.INVALID_LOCAL_CONTEXT)}async load(o){const l=this.documentCache[o];if(l)return l;let c;try{c=await this.documentLoader.load(o)}catch(d){throw new e.ErrorCoded(`Failed to load remote context ${o}: ${d.message}`,e.ERROR_CODES.LOADING_REMOTE_CONTEXT_FAILED)}if(!("@context"in c))throw new e.ErrorCoded(`Missing @context in remote context at ${o}`,e.ERROR_CODES.INVALID_REMOTE_CONTEXT);return this.documentCache[o]=c["@context"]}getOverriddenLoad(o,l){if(o in(l.remoteContexts||{})){if(l.ignoreRemoteScopedContexts)return o;throw new e.ErrorCoded("Detected a cyclic context inclusion of "+o,e.ERROR_CODES.RECURSIVE_CONTEXT_INCLUSION)}return null}async loadImportContext(o){let l=await this.load(o);if(typeof l!="object"||Array.isArray(l))throw new e.ErrorCoded("An imported context must be a single object: "+o,e.ERROR_CODES.INVALID_REMOTE_CONTEXT);if("@import"in l)throw new e.ErrorCoded("An imported context can not import another context: "+o,e.ERROR_CODES.INVALID_CONTEXT_ENTRY);return l=Object.assign({},l),this.containersToHash(l),l}};return r.DEFAULT_PROCESSING_MODE=1.1,Oc.ContextParser=r,Oc}var Xm={},Ox;function Bz(){return Ox||(Ox=1,Object.defineProperty(Xm,"__esModule",{value:!0})),Xm}var Km={},Rx;function Uz(){return Rx||(Rx=1,Object.defineProperty(Km,"__esModule",{value:!0})),Km}var xx;function Jr(){return xx||(xx=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(qz(),t),u(Ay(),t),u(dq(),t),u(Bz(),t),u(Uz(),t),u(fq(),t),u(LT(),t)}(km)),km}var Ix;function hq(){if(Ix)return Ec;Ix=1,Object.defineProperty(Ec,"__esModule",{value:!0}),Ec.Util=void 0;const t=Et(),e=Jr(),u=Ot();class s{constructor(r){this.nodeHandlers={},this.nodeValueHandlers={},this.directiveNodeHandlers={},this.settings=r,this.dataFactory=r.dataFactory||new t.DataFactory,this.operationFactory=new u.Factory(this.dataFactory),this.contextParser=new e.ContextParser}registerNodeHandler(r){this.nodeHandlers[r.targetKind]=r}registerNodeValueHandler(r){this.nodeValueHandlers[r.targetKind]=r}registerDirectiveNodeHandler(r){this.directiveNodeHandlers[r.targetKind]=r}handleNode(r,a){const o=this.nodeHandlers[r.kind];if(!o)throw new Error(`Unsupported GraphQL node '${r.kind}'`);return o.handle(r,a)}handleNodeValue(r,a,o){const l=this.nodeValueHandlers[r.kind];if(!l)throw new Error(`Unsupported GraphQL value node '${r.kind}'`);return l.handle(r,a,o)}handleDirectiveNode(r,a){const o=this.directiveNodeHandlers[r.directive.name.value];return o?o.handle(r,a):null}joinOperations(r){if(r.length===1)return r[0];const a=[],o=[];for(const l of r)l.type==="bgp"?a.push(l):o.push(l);if(a.length===r.length)return this.joinOperationsAsBgp(a);if(a.length===r.length-1&&o[0].type==="leftjoin"&&o[0].input[0].type==="bgp"){const l=o[0];return a.push(l.input[0]),this.operationFactory.createLeftJoin(this.joinOperationsAsBgp(a),l.input[1])}else return o.length===r.length?this.joinOperationsAsNestedJoin(o):this.joinOperationsAsNestedJoin([this.joinOperationsAsBgp(a),this.joinOperationsAsNestedJoin(o)])}joinOperationsAsBgp(r){return this.operationFactory.createBgp([].concat.apply([],r.map(a=>a.patterns)))}joinOperationsAsNestedJoin(r){return this.operationFactory.createJoin(r)}appendFieldToPath(r,a){return r.concat([a])}getFieldLabel(r){return(r.alias?r.alias:r.name).value}nameToVariable(r,a){return this.dataFactory.variable((a.path.length?a.path.join(this.settings.variableDelimiter)+this.settings.variableDelimiter:"")+r)}valueToNamedNode(r,a){const o=a.expandTerm(r,!0);if(this.settings.requireContext&&!o)throw new Error("No context entry was found for "+r);return this.dataFactory.namedNode(o||r)}getArgument(r,a){if(r){for(const o of r)if(o.name.value===a)return o}}newTypePattern(r,a,o){return this.operationFactory.createPattern(r,this.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),this.valueToNamedNode(a.name.value,o.context),o.graph)}createQuadPattern(r,a,o,l,c){const d=this.valueToNamedNode(a.value,c);return c&&c.getContextRaw()[a.value]&&c.getContextRaw()[a.value]["@reverse"]?this.operationFactory.createPattern(o,d,r,l):this.operationFactory.createPattern(r,d,o,l)}createQuadPath(r,a,o,l,c,d){const h=this.valueToNamedNode(a.value,d);let f=this.operationFactory.createLink(h);for(const p of o.values){if(p.kind!=="EnumValue")throw new Error("Invalid value type for 'alt' argument, must be EnumValue, but got "+p.kind);f=this.operationFactory.createAlt([f,this.operationFactory.createLink(this.valueToNamedNode(p.value,d))])}return d&&d.getContextRaw()[a.value]&&d.getContextRaw()[a.value]["@reverse"]?this.operationFactory.createPath(l,f,r,c):this.operationFactory.createPath(r,f,l,c)}}return Ec.Util=s,Ec}var Px;function Hz(){if(Px)return Ac;Px=1;var t=I&&I.__awaiter||function(o,l,c,d){function h(f){return f instanceof c?f:new c(function(p){p(f)})}return new(c||(c=Promise))(function(f,p){function y(g){try{m(d.next(g))}catch(v){p(v)}}function b(g){try{m(d.throw(g))}catch(v){p(v)}}function m(g){g.done?f(g.value):h(g.value).then(y,b)}m((d=d.apply(o,l||[])).next())})};Object.defineProperty(Ac,"__esModule",{value:!0}),Ac.Converter=void 0;const e=Mz,u=zF(),s=kF(),n=Ty(),r=hq();class a{constructor(l){l=l||{},l.variableDelimiter=l.variableDelimiter||"_",l.expressionVariableCounter=l.expressionVariableCounter||0,this.util=new r.Util(l),this.initializeNodeHandlers(l)}static registerNodeHandlers(l,c){l.registerNodeHandler(new u.NodeHandlerDocument(l,c)),l.registerNodeHandler(new u.NodeHandlerDefinitionOperation(l,c)),l.registerNodeHandler(new u.NodeHandlerDefinitionFragment(l,c)),l.registerNodeHandler(new u.NodeHandlerSelectionFragmentSpread(l,c)),l.registerNodeHandler(new u.NodeHandlerSelectionInlineFragment(l,c)),l.registerNodeHandler(new u.NodeHandlerSelectionField(l,c))}static registerNodeValueHandlers(l,c){l.registerNodeValueHandler(new u.NodeValueHandlerVariable(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerInt(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerFloat(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerString(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerBoolean(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerNull(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerEnum(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerList(l,c)),l.registerNodeValueHandler(new u.NodeValueHandlerObject(l,c))}static registerDirectiveNodeHandlers(l,c){l.registerDirectiveNodeHandler(new s.DirectiveNodeHandlerInclude(l,c)),l.registerDirectiveNodeHandler(new s.DirectiveNodeHandlerOptional(l,c)),l.registerDirectiveNodeHandler(new s.DirectiveNodeHandlerPlural(l,c)),l.registerDirectiveNodeHandler(new s.DirectiveNodeHandlerSingle(l,c)),l.registerDirectiveNodeHandler(new s.DirectiveNodeHandlerSkip(l,c))}graphqlToSparqlAlgebra(l,c,d){return t(this,void 0,void 0,function*(){return this.graphqlToSparqlAlgebraRawContext(l,yield this.util.contextParser.parse(c),d)})}graphqlToSparqlAlgebraRawContext(l,c,d){d=d||{};const h=typeof l=="string"?(0,e.parse)(l):l,f=this.indexFragments(h),p={context:c,fragmentDefinitions:f,graph:this.util.dataFactory.defaultGraph(),path:[],singularizeState:n.SingularizeState.PLURAL,singularizeVariables:d.singularizeVariables||{},subject:null,terminalVariables:[],variablesDict:d.variablesDict||{},variablesMetaDict:{}};return this.util.handleNode(h,p)}indexFragments(l){const c={},d=[];for(const h of l.definitions)h.kind==="FragmentDefinition"?c[h.name.value]=h:d.push(h);return l.definitions=d,c}initializeNodeHandlers(l){a.registerNodeHandlers(this.util,l),a.registerNodeValueHandlers(this.util,l),a.registerDirectiveNodeHandlers(this.util,l)}}return Ac.Converter=a,Ac}var Ym={},Dx;function $z(){return Dx||(Dx=1,Object.defineProperty(Ym,"__esModule",{value:!0})),Ym}var Nx;function Qz(){return Nx||(Nx=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(zF(),t),u(Hz(),t),u(Ty(),t),u($z(),t),u(hq(),t)}(Fm)),Fm}var Cx;function Vz(){if(Cx)return Yu;Cx=1,Object.defineProperty(Yu,"__esModule",{value:!0}),Yu.ActorQueryParseGraphql=void 0;const t=VF(),e=Lt,u=Qz();let s=class extends t.ActorQueryParse{constructor(r){super(r),this.graphqlToSparql=new u.Converter({requireContext:!0})}async test(r){var a;if(((a=r.queryFormat)==null?void 0:a.language)!=="graphql")throw new Error("This actor can only parse GraphQL queries");return!0}async run(r){const a=r.context.get(e.KeysInitQuery.jsonLdContext)||{},o={singularizeVariables:r.context.get(e.KeysInitQuery.graphqlSingularizeVariables)};return{operation:await this.graphqlToSparql.graphqlToSparqlAlgebra(r.query,a,o)}}};return Yu.ActorQueryParseGraphql=s,Yu}var jx;function kz(){return jx||(jx=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Vz(),t)}(Mm)),Mm}var Zm={},Ic={},e_={},Pc={},t_={},Dc={},Lx;function pq(){if(Lx)return Dc;Lx=1,Object.defineProperty(Dc,"__esModule",{value:!0}),Dc.ActorAbstractMediaTyped=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}async run(s){if("handle"in s){const n=s;return{handle:await this.runHandle(n.handle,n.handleMediaType,s.context)}}if("mediaTypes"in s)return{mediaTypes:await this.getMediaTypes(s.context)};if("mediaTypeFormats"in s)return{mediaTypeFormats:await this.getMediaTypeFormats(s.context)};throw new Error("Either a handle, mediaTypes or mediaTypeFormats action needs to be provided")}async test(s){if("handle"in s){const n=s;return{handle:await this.testHandle(n.handle,n.handleMediaType,s.context)}}if("mediaTypes"in s)return{mediaTypes:await this.testMediaType(s.context)};if("mediaTypeFormats"in s)return{mediaTypeFormats:await this.testMediaTypeFormats(s.context)};throw new Error("Either a handle, mediaTypes or mediaTypeFormats action needs to be provided")}};return Dc.ActorAbstractMediaTyped=e,Dc}var Nc={},Mx;function zz(){if(Mx)return Nc;Mx=1,Object.defineProperty(Nc,"__esModule",{value:!0}),Nc.ActorAbstractMediaTypedFixed=void 0;const t=pq();let e=class extends t.ActorAbstractMediaTyped{constructor(s){super(s);const n=this.priorityScale||this.priorityScale===0?this.priorityScale:1;if(this.mediaTypePriorities)for(const[r,[a,o]]of Object.entries(this.mediaTypePriorities).entries())this.mediaTypePriorities[a]=n*o;this.mediaTypePriorities=Object.freeze(this.mediaTypePriorities),this.mediaTypeFormats=Object.freeze(this.mediaTypeFormats)}async testHandle(s,n,r){if(!n||!(n in this.mediaTypePriorities))throw new Error(`Unrecognized media type: ${n}`);return await this.testHandleChecked(s,r)}async testMediaType(s){return!0}async getMediaTypes(s){return this.mediaTypePriorities}async testMediaTypeFormats(s){return!0}async getMediaTypeFormats(s){return this.mediaTypeFormats}};return Nc.ActorAbstractMediaTypedFixed=e,Nc}var Fx;function nu(){return Fx||(Fx=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(pq(),t),u(zz(),t)}(t_)),t_}var qx;function Gz(){if(qx)return Pc;qx=1,Object.defineProperty(Pc,"__esModule",{value:!0}),Pc.ActorQueryResultSerialize=void 0;const t=nu();let e=class extends t.ActorAbstractMediaTyped{constructor(s){super(s)}};return Pc.ActorQueryResultSerialize=e,Pc}var Cc={},Bx;function Wz(){if(Bx)return Cc;Bx=1,Object.defineProperty(Cc,"__esModule",{value:!0}),Cc.ActorQueryResultSerializeFixedMediaTypes=void 0;const t=nu();let e=class extends t.ActorAbstractMediaTypedFixed{constructor(s){super(s)}async testHandleChecked(s,n){return!0}};return Cc.ActorQueryResultSerializeFixedMediaTypes=e,Cc}var Ux;function Gi(){return Ux||(Ux=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Gz(),t),u(Wz(),t)}(e_)),e_}var r_={exports:{}},n_={exports:{}},i_={},jc={},Hx;function Jz(){if(Hx)return jc;Hx=1,jc.byteLength=o,jc.toByteArray=c,jc.fromByteArray=f;for(var t=[],e=[],u=typeof Uint8Array<"u"?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",n=0,r=s.length;n0)throw new Error("Invalid string. Length must be a multiple of 4");var b=p.indexOf("=");b===-1&&(b=y);var m=b===y?0:4-b%4;return[b,m]}function o(p){var y=a(p),b=y[0],m=y[1];return(b+m)*3/4-m}function l(p,y,b){return(y+b)*3/4-b}function c(p){var y,b=a(p),m=b[0],g=b[1],v=new u(l(p,m,g)),_=0,w=g>0?m-4:m,S;for(S=0;S>16&255,v[_++]=y>>8&255,v[_++]=y&255;return g===2&&(y=e[p.charCodeAt(S)]<<2|e[p.charCodeAt(S+1)]>>4,v[_++]=y&255),g===1&&(y=e[p.charCodeAt(S)]<<10|e[p.charCodeAt(S+1)]<<4|e[p.charCodeAt(S+2)]>>2,v[_++]=y>>8&255,v[_++]=y&255),v}function d(p){return t[p>>18&63]+t[p>>12&63]+t[p>>6&63]+t[p&63]}function h(p,y,b){for(var m,g=[],v=y;vw?w:_+v));return m===1?(y=p[b-1],g.push(t[y>>2]+t[y<<4&63]+"==")):m===2&&(y=(p[b-2]<<8)+p[b-1],g.push(t[y>>10]+t[y>>4&63]+t[y<<2&63]+"=")),g.join("")}return jc}var a1={};/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh */var $x;function Xz(){return $x||($x=1,a1.read=function(t,e,u,s,n){var r,a,o=n*8-s-1,l=(1<>1,d=-7,h=u?n-1:0,f=u?-1:1,p=t[e+h];for(h+=f,r=p&(1<<-d)-1,p>>=-d,d+=o;d>0;r=r*256+t[e+h],h+=f,d-=8);for(a=r&(1<<-d)-1,r>>=-d,d+=s;d>0;a=a*256+t[e+h],h+=f,d-=8);if(r===0)r=1-c;else{if(r===l)return a?NaN:(p?-1:1)*(1/0);a=a+Math.pow(2,s),r=r-c}return(p?-1:1)*a*Math.pow(2,r-s)},a1.write=function(t,e,u,s,n,r){var a,o,l,c=r*8-n-1,d=(1<>1,f=n===23?Math.pow(2,-24)-Math.pow(2,-77):0,p=s?0:r-1,y=s?1:-1,b=e<0||e===0&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(o=isNaN(e)?1:0,a=d):(a=Math.floor(Math.log(e)/Math.LN2),e*(l=Math.pow(2,-a))<1&&(a--,l*=2),a+h>=1?e+=f/l:e+=f*Math.pow(2,1-h),e*l>=2&&(a++,l/=2),a+h>=d?(o=0,a=d):a+h>=1?(o=(e*l-1)*Math.pow(2,n),a=a+h):(o=e*Math.pow(2,h-1)*Math.pow(2,n),a=0));n>=8;t[u+p]=o&255,p+=y,o/=256,n-=8);for(a=a<0;t[u+p]=a&255,p+=y,a/=256,c-=8);t[u+p-y]|=b*128}),a1}/*! - * The buffer module from node.js, for the browser. - * - * @author Feross Aboukhadijeh - * @license MIT - */var Qx;function Wi(){return Qx||(Qx=1,function(t){const e=Jz(),u=Xz(),s=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=o,t.SlowBuffer=v,t.INSPECT_MAX_BYTES=50;const n=2147483647;t.kMaxLength=n,o.TYPED_ARRAY_SUPPORT=r(),!o.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function r(){try{const G=new Uint8Array(1),F={foo:function(){return 42}};return Object.setPrototypeOf(F,Uint8Array.prototype),Object.setPrototypeOf(G,F),G.foo()===42}catch{return!1}}Object.defineProperty(o.prototype,"parent",{enumerable:!0,get:function(){if(o.isBuffer(this))return this.buffer}}),Object.defineProperty(o.prototype,"offset",{enumerable:!0,get:function(){if(o.isBuffer(this))return this.byteOffset}});function a(G){if(G>n)throw new RangeError('The value "'+G+'" is invalid for option "size"');const F=new Uint8Array(G);return Object.setPrototypeOf(F,o.prototype),F}function o(G,F,H){if(typeof G=="number"){if(typeof F=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return h(G)}return l(G,F,H)}o.poolSize=8192;function l(G,F,H){if(typeof G=="string")return f(G,F);if(ArrayBuffer.isView(G))return y(G);if(G==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof G);if(ce(G,ArrayBuffer)||G&&ce(G.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(ce(G,SharedArrayBuffer)||G&&ce(G.buffer,SharedArrayBuffer)))return b(G,F,H);if(typeof G=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const re=G.valueOf&&G.valueOf();if(re!=null&&re!==G)return o.from(re,F,H);const be=m(G);if(be)return be;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof G[Symbol.toPrimitive]=="function")return o.from(G[Symbol.toPrimitive]("string"),F,H);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof G)}o.from=function(G,F,H){return l(G,F,H)},Object.setPrototypeOf(o.prototype,Uint8Array.prototype),Object.setPrototypeOf(o,Uint8Array);function c(G){if(typeof G!="number")throw new TypeError('"size" argument must be of type number');if(G<0)throw new RangeError('The value "'+G+'" is invalid for option "size"')}function d(G,F,H){return c(G),G<=0?a(G):F!==void 0?typeof H=="string"?a(G).fill(F,H):a(G).fill(F):a(G)}o.alloc=function(G,F,H){return d(G,F,H)};function h(G){return c(G),a(G<0?0:g(G)|0)}o.allocUnsafe=function(G){return h(G)},o.allocUnsafeSlow=function(G){return h(G)};function f(G,F){if((typeof F!="string"||F==="")&&(F="utf8"),!o.isEncoding(F))throw new TypeError("Unknown encoding: "+F);const H=_(G,F)|0;let re=a(H);const be=re.write(G,F);return be!==H&&(re=re.slice(0,be)),re}function p(G){const F=G.length<0?0:g(G.length)|0,H=a(F);for(let re=0;re=n)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+n.toString(16)+" bytes");return G|0}function v(G){return+G!=G&&(G=0),o.alloc(+G)}o.isBuffer=function(F){return F!=null&&F._isBuffer===!0&&F!==o.prototype},o.compare=function(F,H){if(ce(F,Uint8Array)&&(F=o.from(F,F.offset,F.byteLength)),ce(H,Uint8Array)&&(H=o.from(H,H.offset,H.byteLength)),!o.isBuffer(F)||!o.isBuffer(H))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(F===H)return 0;let re=F.length,be=H.length;for(let Re=0,Ce=Math.min(re,be);Rebe.length?(o.isBuffer(Ce)||(Ce=o.from(Ce)),Ce.copy(be,Re)):Uint8Array.prototype.set.call(be,Ce,Re);else if(o.isBuffer(Ce))Ce.copy(be,Re);else throw new TypeError('"list" argument must be an Array of Buffers');Re+=Ce.length}return be};function _(G,F){if(o.isBuffer(G))return G.length;if(ArrayBuffer.isView(G)||ce(G,ArrayBuffer))return G.byteLength;if(typeof G!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof G);const H=G.length,re=arguments.length>2&&arguments[2]===!0;if(!re&&H===0)return 0;let be=!1;for(;;)switch(F){case"ascii":case"latin1":case"binary":return H;case"utf8":case"utf-8":return V(G).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return H*2;case"hex":return H>>>1;case"base64":return Y(G).length;default:if(be)return re?-1:V(G).length;F=(""+F).toLowerCase(),be=!0}}o.byteLength=_;function w(G,F,H){let re=!1;if((F===void 0||F<0)&&(F=0),F>this.length||((H===void 0||H>this.length)&&(H=this.length),H<=0)||(H>>>=0,F>>>=0,H<=F))return"";for(G||(G="utf8");;)switch(G){case"hex":return fe(this,F,H);case"utf8":case"utf-8":return M(this,F,H);case"ascii":return Z(this,F,H);case"latin1":case"binary":return K(this,F,H);case"base64":return U(this,F,H);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return X(this,F,H);default:if(re)throw new TypeError("Unknown encoding: "+G);G=(G+"").toLowerCase(),re=!0}}o.prototype._isBuffer=!0;function S(G,F,H){const re=G[F];G[F]=G[H],G[H]=re}o.prototype.swap16=function(){const F=this.length;if(F%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let H=0;HH&&(F+=" ... "),""},s&&(o.prototype[s]=o.prototype.inspect),o.prototype.compare=function(F,H,re,be,Re){if(ce(F,Uint8Array)&&(F=o.from(F,F.offset,F.byteLength)),!o.isBuffer(F))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof F);if(H===void 0&&(H=0),re===void 0&&(re=F?F.length:0),be===void 0&&(be=0),Re===void 0&&(Re=this.length),H<0||re>F.length||be<0||Re>this.length)throw new RangeError("out of range index");if(be>=Re&&H>=re)return 0;if(be>=Re)return-1;if(H>=re)return 1;if(H>>>=0,re>>>=0,be>>>=0,Re>>>=0,this===F)return 0;let Ce=Re-be,Qe=re-H;const ke=Math.min(Ce,Qe),me=this.slice(be,Re),Se=F.slice(H,re);for(let W=0;W2147483647?H=2147483647:H<-2147483648&&(H=-2147483648),H=+H,Ae(H)&&(H=be?0:G.length-1),H<0&&(H=G.length+H),H>=G.length){if(be)return-1;H=G.length-1}else if(H<0)if(be)H=0;else return-1;if(typeof F=="string"&&(F=o.from(F,re)),o.isBuffer(F))return F.length===0?-1:D(G,F,H,re,be);if(typeof F=="number")return F=F&255,typeof Uint8Array.prototype.indexOf=="function"?be?Uint8Array.prototype.indexOf.call(G,F,H):Uint8Array.prototype.lastIndexOf.call(G,F,H):D(G,[F],H,re,be);throw new TypeError("val must be string, number or Buffer")}function D(G,F,H,re,be){let Re=1,Ce=G.length,Qe=F.length;if(re!==void 0&&(re=String(re).toLowerCase(),re==="ucs2"||re==="ucs-2"||re==="utf16le"||re==="utf-16le")){if(G.length<2||F.length<2)return-1;Re=2,Ce/=2,Qe/=2,H/=2}function ke(Se,W){return Re===1?Se[W]:Se.readUInt16BE(W*Re)}let me;if(be){let Se=-1;for(me=H;meCe&&(H=Ce-Qe),me=H;me>=0;me--){let Se=!0;for(let W=0;Wbe&&(re=be)):re=be;const Re=F.length;re>Re/2&&(re=Re/2);let Ce;for(Ce=0;Ce>>0,isFinite(re)?(re=re>>>0,be===void 0&&(be="utf8")):(be=re,re=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const Re=this.length-H;if((re===void 0||re>Re)&&(re=Re),F.length>0&&(re<0||H<0)||H>this.length)throw new RangeError("Attempt to write outside buffer bounds");be||(be="utf8");let Ce=!1;for(;;)switch(be){case"hex":return L(this,F,H,re);case"utf8":case"utf-8":return E(this,F,H,re);case"ascii":case"latin1":case"binary":return O(this,F,H,re);case"base64":return P(this,F,H,re);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return j(this,F,H,re);default:if(Ce)throw new TypeError("Unknown encoding: "+be);be=(""+be).toLowerCase(),Ce=!0}},o.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function U(G,F,H){return F===0&&H===G.length?e.fromByteArray(G):e.fromByteArray(G.slice(F,H))}function M(G,F,H){H=Math.min(G.length,H);const re=[];let be=F;for(;be239?4:Re>223?3:Re>191?2:1;if(be+Qe<=H){let ke,me,Se,W;switch(Qe){case 1:Re<128&&(Ce=Re);break;case 2:ke=G[be+1],(ke&192)===128&&(W=(Re&31)<<6|ke&63,W>127&&(Ce=W));break;case 3:ke=G[be+1],me=G[be+2],(ke&192)===128&&(me&192)===128&&(W=(Re&15)<<12|(ke&63)<<6|me&63,W>2047&&(W<55296||W>57343)&&(Ce=W));break;case 4:ke=G[be+1],me=G[be+2],Se=G[be+3],(ke&192)===128&&(me&192)===128&&(Se&192)===128&&(W=(Re&15)<<18|(ke&63)<<12|(me&63)<<6|Se&63,W>65535&&W<1114112&&(Ce=W))}}Ce===null?(Ce=65533,Qe=1):Ce>65535&&(Ce-=65536,re.push(Ce>>>10&1023|55296),Ce=56320|Ce&1023),re.push(Ce),be+=Qe}return Q(re)}const q=4096;function Q(G){const F=G.length;if(F<=q)return String.fromCharCode.apply(String,G);let H="",re=0;for(;rere)&&(H=re);let be="";for(let Re=F;Rere&&(F=re),H<0?(H+=re,H<0&&(H=0)):H>re&&(H=re),HH)throw new RangeError("Trying to access beyond buffer length")}o.prototype.readUintLE=o.prototype.readUIntLE=function(F,H,re){F=F>>>0,H=H>>>0,re||he(F,H,this.length);let be=this[F],Re=1,Ce=0;for(;++Ce>>0,H=H>>>0,re||he(F,H,this.length);let be=this[F+--H],Re=1;for(;H>0&&(Re*=256);)be+=this[F+--H]*Re;return be},o.prototype.readUint8=o.prototype.readUInt8=function(F,H){return F=F>>>0,H||he(F,1,this.length),this[F]},o.prototype.readUint16LE=o.prototype.readUInt16LE=function(F,H){return F=F>>>0,H||he(F,2,this.length),this[F]|this[F+1]<<8},o.prototype.readUint16BE=o.prototype.readUInt16BE=function(F,H){return F=F>>>0,H||he(F,2,this.length),this[F]<<8|this[F+1]},o.prototype.readUint32LE=o.prototype.readUInt32LE=function(F,H){return F=F>>>0,H||he(F,4,this.length),(this[F]|this[F+1]<<8|this[F+2]<<16)+this[F+3]*16777216},o.prototype.readUint32BE=o.prototype.readUInt32BE=function(F,H){return F=F>>>0,H||he(F,4,this.length),this[F]*16777216+(this[F+1]<<16|this[F+2]<<8|this[F+3])},o.prototype.readBigUInt64LE=Ee(function(F){F=F>>>0,T(F,"offset");const H=this[F],re=this[F+7];(H===void 0||re===void 0)&&x(F,this.length-8);const be=H+this[++F]*2**8+this[++F]*2**16+this[++F]*2**24,Re=this[++F]+this[++F]*2**8+this[++F]*2**16+re*2**24;return BigInt(be)+(BigInt(Re)<>>0,T(F,"offset");const H=this[F],re=this[F+7];(H===void 0||re===void 0)&&x(F,this.length-8);const be=H*2**24+this[++F]*2**16+this[++F]*2**8+this[++F],Re=this[++F]*2**24+this[++F]*2**16+this[++F]*2**8+re;return(BigInt(be)<>>0,H=H>>>0,re||he(F,H,this.length);let be=this[F],Re=1,Ce=0;for(;++Ce=Re&&(be-=Math.pow(2,8*H)),be},o.prototype.readIntBE=function(F,H,re){F=F>>>0,H=H>>>0,re||he(F,H,this.length);let be=H,Re=1,Ce=this[F+--be];for(;be>0&&(Re*=256);)Ce+=this[F+--be]*Re;return Re*=128,Ce>=Re&&(Ce-=Math.pow(2,8*H)),Ce},o.prototype.readInt8=function(F,H){return F=F>>>0,H||he(F,1,this.length),this[F]&128?(255-this[F]+1)*-1:this[F]},o.prototype.readInt16LE=function(F,H){F=F>>>0,H||he(F,2,this.length);const re=this[F]|this[F+1]<<8;return re&32768?re|4294901760:re},o.prototype.readInt16BE=function(F,H){F=F>>>0,H||he(F,2,this.length);const re=this[F+1]|this[F]<<8;return re&32768?re|4294901760:re},o.prototype.readInt32LE=function(F,H){return F=F>>>0,H||he(F,4,this.length),this[F]|this[F+1]<<8|this[F+2]<<16|this[F+3]<<24},o.prototype.readInt32BE=function(F,H){return F=F>>>0,H||he(F,4,this.length),this[F]<<24|this[F+1]<<16|this[F+2]<<8|this[F+3]},o.prototype.readBigInt64LE=Ee(function(F){F=F>>>0,T(F,"offset");const H=this[F],re=this[F+7];(H===void 0||re===void 0)&&x(F,this.length-8);const be=this[F+4]+this[F+5]*2**8+this[F+6]*2**16+(re<<24);return(BigInt(be)<>>0,T(F,"offset");const H=this[F],re=this[F+7];(H===void 0||re===void 0)&&x(F,this.length-8);const be=(H<<24)+this[++F]*2**16+this[++F]*2**8+this[++F];return(BigInt(be)<>>0,H||he(F,4,this.length),u.read(this,F,!0,23,4)},o.prototype.readFloatBE=function(F,H){return F=F>>>0,H||he(F,4,this.length),u.read(this,F,!1,23,4)},o.prototype.readDoubleLE=function(F,H){return F=F>>>0,H||he(F,8,this.length),u.read(this,F,!0,52,8)},o.prototype.readDoubleBE=function(F,H){return F=F>>>0,H||he(F,8,this.length),u.read(this,F,!1,52,8)};function xe(G,F,H,re,be,Re){if(!o.isBuffer(G))throw new TypeError('"buffer" argument must be a Buffer instance');if(F>be||FG.length)throw new RangeError("Index out of range")}o.prototype.writeUintLE=o.prototype.writeUIntLE=function(F,H,re,be){if(F=+F,H=H>>>0,re=re>>>0,!be){const Qe=Math.pow(2,8*re)-1;xe(this,F,H,re,Qe,0)}let Re=1,Ce=0;for(this[H]=F&255;++Ce>>0,re=re>>>0,!be){const Qe=Math.pow(2,8*re)-1;xe(this,F,H,re,Qe,0)}let Re=re-1,Ce=1;for(this[H+Re]=F&255;--Re>=0&&(Ce*=256);)this[H+Re]=F/Ce&255;return H+re},o.prototype.writeUint8=o.prototype.writeUInt8=function(F,H,re){return F=+F,H=H>>>0,re||xe(this,F,H,1,255,0),this[H]=F&255,H+1},o.prototype.writeUint16LE=o.prototype.writeUInt16LE=function(F,H,re){return F=+F,H=H>>>0,re||xe(this,F,H,2,65535,0),this[H]=F&255,this[H+1]=F>>>8,H+2},o.prototype.writeUint16BE=o.prototype.writeUInt16BE=function(F,H,re){return F=+F,H=H>>>0,re||xe(this,F,H,2,65535,0),this[H]=F>>>8,this[H+1]=F&255,H+2},o.prototype.writeUint32LE=o.prototype.writeUInt32LE=function(F,H,re){return F=+F,H=H>>>0,re||xe(this,F,H,4,4294967295,0),this[H+3]=F>>>24,this[H+2]=F>>>16,this[H+1]=F>>>8,this[H]=F&255,H+4},o.prototype.writeUint32BE=o.prototype.writeUInt32BE=function(F,H,re){return F=+F,H=H>>>0,re||xe(this,F,H,4,4294967295,0),this[H]=F>>>24,this[H+1]=F>>>16,this[H+2]=F>>>8,this[H+3]=F&255,H+4};function ie(G,F,H,re,be){R(F,re,be,G,H,7);let Re=Number(F&BigInt(4294967295));G[H++]=Re,Re=Re>>8,G[H++]=Re,Re=Re>>8,G[H++]=Re,Re=Re>>8,G[H++]=Re;let Ce=Number(F>>BigInt(32)&BigInt(4294967295));return G[H++]=Ce,Ce=Ce>>8,G[H++]=Ce,Ce=Ce>>8,G[H++]=Ce,Ce=Ce>>8,G[H++]=Ce,H}function ae(G,F,H,re,be){R(F,re,be,G,H,7);let Re=Number(F&BigInt(4294967295));G[H+7]=Re,Re=Re>>8,G[H+6]=Re,Re=Re>>8,G[H+5]=Re,Re=Re>>8,G[H+4]=Re;let Ce=Number(F>>BigInt(32)&BigInt(4294967295));return G[H+3]=Ce,Ce=Ce>>8,G[H+2]=Ce,Ce=Ce>>8,G[H+1]=Ce,Ce=Ce>>8,G[H]=Ce,H+8}o.prototype.writeBigUInt64LE=Ee(function(F,H=0){return ie(this,F,H,BigInt(0),BigInt("0xffffffffffffffff"))}),o.prototype.writeBigUInt64BE=Ee(function(F,H=0){return ae(this,F,H,BigInt(0),BigInt("0xffffffffffffffff"))}),o.prototype.writeIntLE=function(F,H,re,be){if(F=+F,H=H>>>0,!be){const ke=Math.pow(2,8*re-1);xe(this,F,H,re,ke-1,-ke)}let Re=0,Ce=1,Qe=0;for(this[H]=F&255;++Re>0)-Qe&255;return H+re},o.prototype.writeIntBE=function(F,H,re,be){if(F=+F,H=H>>>0,!be){const ke=Math.pow(2,8*re-1);xe(this,F,H,re,ke-1,-ke)}let Re=re-1,Ce=1,Qe=0;for(this[H+Re]=F&255;--Re>=0&&(Ce*=256);)F<0&&Qe===0&&this[H+Re+1]!==0&&(Qe=1),this[H+Re]=(F/Ce>>0)-Qe&255;return H+re},o.prototype.writeInt8=function(F,H,re){return F=+F,H=H>>>0,re||xe(this,F,H,1,127,-128),F<0&&(F=255+F+1),this[H]=F&255,H+1},o.prototype.writeInt16LE=function(F,H,re){return F=+F,H=H>>>0,re||xe(this,F,H,2,32767,-32768),this[H]=F&255,this[H+1]=F>>>8,H+2},o.prototype.writeInt16BE=function(F,H,re){return F=+F,H=H>>>0,re||xe(this,F,H,2,32767,-32768),this[H]=F>>>8,this[H+1]=F&255,H+2},o.prototype.writeInt32LE=function(F,H,re){return F=+F,H=H>>>0,re||xe(this,F,H,4,2147483647,-2147483648),this[H]=F&255,this[H+1]=F>>>8,this[H+2]=F>>>16,this[H+3]=F>>>24,H+4},o.prototype.writeInt32BE=function(F,H,re){return F=+F,H=H>>>0,re||xe(this,F,H,4,2147483647,-2147483648),F<0&&(F=4294967295+F+1),this[H]=F>>>24,this[H+1]=F>>>16,this[H+2]=F>>>8,this[H+3]=F&255,H+4},o.prototype.writeBigInt64LE=Ee(function(F,H=0){return ie(this,F,H,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),o.prototype.writeBigInt64BE=Ee(function(F,H=0){return ae(this,F,H,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function Oe(G,F,H,re,be,Re){if(H+re>G.length)throw new RangeError("Index out of range");if(H<0)throw new RangeError("Index out of range")}function Ne(G,F,H,re,be){return F=+F,H=H>>>0,be||Oe(G,F,H,4),u.write(G,F,H,re,23,4),H+4}o.prototype.writeFloatLE=function(F,H,re){return Ne(this,F,H,!0,re)},o.prototype.writeFloatBE=function(F,H,re){return Ne(this,F,H,!1,re)};function ge(G,F,H,re,be){return F=+F,H=H>>>0,be||Oe(G,F,H,8),u.write(G,F,H,re,52,8),H+8}o.prototype.writeDoubleLE=function(F,H,re){return ge(this,F,H,!0,re)},o.prototype.writeDoubleBE=function(F,H,re){return ge(this,F,H,!1,re)},o.prototype.copy=function(F,H,re,be){if(!o.isBuffer(F))throw new TypeError("argument should be a Buffer");if(re||(re=0),!be&&be!==0&&(be=this.length),H>=F.length&&(H=F.length),H||(H=0),be>0&&be=this.length)throw new RangeError("Index out of range");if(be<0)throw new RangeError("sourceEnd out of bounds");be>this.length&&(be=this.length),F.length-H>>0,re=re===void 0?this.length:re>>>0,F||(F=0);let Re;if(typeof F=="number")for(Re=H;Re2**32?be=$(String(H)):typeof H=="bigint"&&(be=String(H),(H>BigInt(2)**BigInt(32)||H<-(BigInt(2)**BigInt(32)))&&(be=$(be)),be+="n"),re+=` It must be ${F}. Received ${be}`,re},RangeError);function $(G){let F="",H=G.length;const re=G[0]==="-"?1:0;for(;H>=re+4;H-=3)F=`_${G.slice(H-3,H)}${F}`;return`${G.slice(0,H)}${F}`}function N(G,F,H){T(F,"offset"),(G[F]===void 0||G[F+H]===void 0)&&x(F,G.length-(H+1))}function R(G,F,H,re,be,Re){if(G>H||G3?F===0||F===BigInt(0)?Qe=`>= 0${Ce} and < 2${Ce} ** ${(Re+1)*8}${Ce}`:Qe=`>= -(2${Ce} ** ${(Re+1)*8-1}${Ce}) and < 2 ** ${(Re+1)*8-1}${Ce}`:Qe=`>= ${F}${Ce} and <= ${H}${Ce}`,new de.ERR_OUT_OF_RANGE("value",Qe,G)}N(re,be,Re)}function T(G,F){if(typeof G!="number")throw new de.ERR_INVALID_ARG_TYPE(F,"number",G)}function x(G,F,H){throw Math.floor(G)!==G?(T(G,H),new de.ERR_OUT_OF_RANGE(H||"offset","an integer",G)):F<0?new de.ERR_BUFFER_OUT_OF_BOUNDS:new de.ERR_OUT_OF_RANGE(H||"offset",`>= ${H?1:0} and <= ${F}`,G)}const B=/[^+/0-9A-Za-z-_]/g;function k(G){if(G=G.split("=")[0],G=G.trim().replace(B,""),G.length<2)return"";for(;G.length%4!==0;)G=G+"=";return G}function V(G,F){F=F||1/0;let H;const re=G.length;let be=null;const Re=[];for(let Ce=0;Ce55295&&H<57344){if(!be){if(H>56319){(F-=3)>-1&&Re.push(239,191,189);continue}else if(Ce+1===re){(F-=3)>-1&&Re.push(239,191,189);continue}be=H;continue}if(H<56320){(F-=3)>-1&&Re.push(239,191,189),be=H;continue}H=(be-55296<<10|H-56320)+65536}else be&&(F-=3)>-1&&Re.push(239,191,189);if(be=null,H<128){if((F-=1)<0)break;Re.push(H)}else if(H<2048){if((F-=2)<0)break;Re.push(H>>6|192,H&63|128)}else if(H<65536){if((F-=3)<0)break;Re.push(H>>12|224,H>>6&63|128,H&63|128)}else if(H<1114112){if((F-=4)<0)break;Re.push(H>>18|240,H>>12&63|128,H>>6&63|128,H&63|128)}else throw new Error("Invalid code point")}return Re}function J(G){const F=[];for(let H=0;H>8,be=H%256,Re.push(be),Re.push(re);return Re}function Y(G){return e.toByteArray(k(G))}function te(G,F,H,re){let be;for(be=0;be=F.length||be>=G.length);++be)F[be+H]=G[be];return be}function ce(G,F){return G instanceof F||G!=null&&G.constructor!=null&&G.constructor.name!=null&&G.constructor.name===F.name}function Ae(G){return G!==G}const Ie=function(){const G="0123456789abcdef",F=new Array(256);for(let H=0;H<16;++H){const re=H*16;for(let be=0;be<16;++be)F[re+be]=G[H]+G[be]}return F}();function Ee(G){return typeof BigInt>"u"?qe:G}function qe(){throw new Error("BigInt not supported")}}(i_)),i_}var a_,Vx;function Rr(){return Vx||(Vx=1,a_={ArrayIsArray(t){return Array.isArray(t)},ArrayPrototypeIncludes(t,e){return t.includes(e)},ArrayPrototypeIndexOf(t,e){return t.indexOf(e)},ArrayPrototypeJoin(t,e){return t.join(e)},ArrayPrototypeMap(t,e){return t.map(e)},ArrayPrototypePop(t,e){return t.pop(e)},ArrayPrototypePush(t,e){return t.push(e)},ArrayPrototypeSlice(t,e,u){return t.slice(e,u)},Error,FunctionPrototypeCall(t,e,...u){return t.call(e,...u)},FunctionPrototypeSymbolHasInstance(t,e){return Function.prototype[Symbol.hasInstance].call(t,e)},MathFloor:Math.floor,Number,NumberIsInteger:Number.isInteger,NumberIsNaN:Number.isNaN,NumberMAX_SAFE_INTEGER:Number.MAX_SAFE_INTEGER,NumberMIN_SAFE_INTEGER:Number.MIN_SAFE_INTEGER,NumberParseInt:Number.parseInt,ObjectDefineProperties(t,e){return Object.defineProperties(t,e)},ObjectDefineProperty(t,e,u){return Object.defineProperty(t,e,u)},ObjectGetOwnPropertyDescriptor(t,e){return Object.getOwnPropertyDescriptor(t,e)},ObjectKeys(t){return Object.keys(t)},ObjectSetPrototypeOf(t,e){return Object.setPrototypeOf(t,e)},Promise,PromisePrototypeCatch(t,e){return t.catch(e)},PromisePrototypeThen(t,e,u){return t.then(e,u)},PromiseReject(t){return Promise.reject(t)},PromiseResolve(t){return Promise.resolve(t)},ReflectApply:Reflect.apply,RegExpPrototypeTest(t,e){return t.test(e)},SafeSet:Set,String,StringPrototypeSlice(t,e,u){return t.slice(e,u)},StringPrototypeToLowerCase(t){return t.toLowerCase()},StringPrototypeToUpperCase(t){return t.toUpperCase()},StringPrototypeTrim(t){return t.trim()},Symbol,SymbolFor:Symbol.for,SymbolAsyncIterator:Symbol.asyncIterator,SymbolHasInstance:Symbol.hasInstance,SymbolIterator:Symbol.iterator,SymbolDispose:Symbol.dispose||Symbol("Symbol.dispose"),SymbolAsyncDispose:Symbol.asyncDispose||Symbol("Symbol.asyncDispose"),TypedArrayPrototypeSet(t,e,u){return t.set(e,u)},Boolean,Uint8Array}),a_}var s_={exports:{}},Lc={exports:{}},kx;function Uo(){if(kx)return Lc.exports;kx=1;const{AbortController:t,AbortSignal:e}=typeof self<"u"?self:typeof window<"u"?window:void 0;return Lc.exports=t,Lc.exports.AbortSignal=e,Lc.exports.default=t,Lc.exports}var zx;function Pn(){return zx||(zx=1,function(t){const e=Wi(),{kResistStopPropagation:u,SymbolDispose:s}=Rr(),n=globalThis.AbortSignal||Uo().AbortSignal,r=globalThis.AbortController||Uo().AbortController,a=Object.getPrototypeOf(async function(){}).constructor,o=globalThis.Blob||e.Blob,l=typeof o<"u"?function(p){return p instanceof o}:function(p){return!1},c=(f,p)=>{if(f!==void 0&&(f===null||typeof f!="object"||!("aborted"in f)))throw new ERR_INVALID_ARG_TYPE(p,"AbortSignal",f)},d=(f,p)=>{if(typeof f!="function")throw new ERR_INVALID_ARG_TYPE(p,"Function",f)};class h extends Error{constructor(p){if(!Array.isArray(p))throw new TypeError(`Expected input to be an Array, got ${typeof p}`);let y="";for(let b=0;b{f=b,p=m}),resolve:f,reject:p}},promisify(f){return new Promise((p,y)=>{f((b,...m)=>b?y(b):p(...m))})},debuglog(){return function(){}},format(f,...p){return f.replace(/%([sdifj])/g,function(...[y,b]){const m=p.shift();return b==="f"?m.toFixed(6):b==="j"?JSON.stringify(m):b==="s"&&typeof m=="object"?`${m.constructor!==Object?m.constructor.name:""} {}`.trim():m.toString()})},inspect(f){switch(typeof f){case"string":if(f.includes("'"))if(f.includes('"')){if(!f.includes("`")&&!f.includes("${"))return`\`${f}\``}else return`"${f}"`;return`'${f}'`;case"number":return isNaN(f)?"NaN":Object.is(f,-0)?String(f):f;case"bigint":return`${String(f)}n`;case"boolean":case"undefined":return String(f);case"object":return"{}"}},types:{isAsyncFunction(f){return f instanceof a},isArrayBufferView(f){return ArrayBuffer.isView(f)}},isBlob:l,deprecate(f,p){return f},addAbortListener:wy().addAbortListener||function(p,y){if(p===void 0)throw new ERR_INVALID_ARG_TYPE("signal","AbortSignal",p);c(p,"signal"),d(y,"listener");let b;return p.aborted?queueMicrotask(()=>y()):(p.addEventListener("abort",y,{__proto__:null,once:!0,[u]:!0}),b=()=>{p.removeEventListener("abort",y)}),{__proto__:null,[s](){var m;(m=b)===null||m===void 0||m()}}},AbortSignalAny:n.any||function(p){if(p.length===1)return p[0];const y=new r,b=()=>y.abort();return p.forEach(m=>{c(m,"signals"),m.addEventListener("abort",b,{once:!0})}),y.signal.addEventListener("abort",()=>{p.forEach(m=>m.removeEventListener("abort",b))},{once:!0}),y.signal}},t.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")}(s_)),s_.exports}var s1={},o_,Gx;function Un(){if(Gx)return o_;Gx=1;const{format:t,inspect:e,AggregateError:u}=Pn(),s=globalThis.AggregateError||u,n=Symbol("kIsNodeError"),r=["string","function","number","object","Function","Object","boolean","bigint","symbol"],a=/^([A-Z][a-z0-9]*)+$/,o="__node_internal_",l={};function c(m,g){if(!m)throw new l.ERR_INTERNAL_ASSERTION(g)}function d(m){let g="",v=m.length;const _=m[0]==="-"?1:0;for(;v>=_+4;v-=3)g=`_${m.slice(v-3,v)}${g}`;return`${m.slice(0,v)}${g}`}function h(m,g,v){if(typeof g=="function")return c(g.length<=v.length,`Code: ${m}; The provided arguments length (${v.length}) does not match the required ones (${g.length}).`),g(...v);const _=(g.match(/%[dfijoOs]/g)||[]).length;return c(_===v.length,`Code: ${m}; The provided arguments length (${v.length}) does not match the required ones (${_}).`),v.length===0?g:t(g,...v)}function f(m,g,v){v||(v=Error);class _ extends v{constructor(...S){super(h(m,g,S))}toString(){return`${this.name} [${m}]: ${this.message}`}}Object.defineProperties(_.prototype,{name:{value:v.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${m}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),_.prototype.code=m,_.prototype[n]=!0,l[m]=_}function p(m){const g=o+m.name;return Object.defineProperty(m,"name",{value:g}),m}function y(m,g){if(m&&g&&m!==g){if(Array.isArray(g.errors))return g.errors.push(m),g;const v=new s([g,m],g.message);return v.code=g.code,v}return m||g}class b extends Error{constructor(g="The operation was aborted",v=void 0){if(v!==void 0&&typeof v!="object")throw new l.ERR_INVALID_ARG_TYPE("options","Object",v);super(g,v),this.code="ABORT_ERR",this.name="AbortError"}}return f("ERR_ASSERTION","%s",Error),f("ERR_INVALID_ARG_TYPE",(m,g,v)=>{c(typeof m=="string","'name' must be a string"),Array.isArray(g)||(g=[g]);let _="The ";m.endsWith(" argument")?_+=`${m} `:_+=`"${m}" ${m.includes(".")?"property":"argument"} `,_+="must be ";const w=[],S=[],A=[];for(const L of g)c(typeof L=="string","All expected entries have to be of type string"),r.includes(L)?w.push(L.toLowerCase()):a.test(L)?S.push(L):(c(L!=="object",'The value "object" should be written as "Object"'),A.push(L));if(S.length>0){const L=w.indexOf("object");L!==-1&&(w.splice(w,L,1),S.push("Object"))}if(w.length>0){switch(w.length){case 1:_+=`of type ${w[0]}`;break;case 2:_+=`one of type ${w[0]} or ${w[1]}`;break;default:{const L=w.pop();_+=`one of type ${w.join(", ")}, or ${L}`}}(S.length>0||A.length>0)&&(_+=" or ")}if(S.length>0){switch(S.length){case 1:_+=`an instance of ${S[0]}`;break;case 2:_+=`an instance of ${S[0]} or ${S[1]}`;break;default:{const L=S.pop();_+=`an instance of ${S.join(", ")}, or ${L}`}}A.length>0&&(_+=" or ")}switch(A.length){case 0:break;case 1:A[0].toLowerCase()!==A[0]&&(_+="an "),_+=`${A[0]}`;break;case 2:_+=`one of ${A[0]} or ${A[1]}`;break;default:{const L=A.pop();_+=`one of ${A.join(", ")}, or ${L}`}}if(v==null)_+=`. Received ${v}`;else if(typeof v=="function"&&v.name)_+=`. Received function ${v.name}`;else if(typeof v=="object"){var D;if((D=v.constructor)!==null&&D!==void 0&&D.name)_+=`. Received an instance of ${v.constructor.name}`;else{const L=e(v,{depth:-1});_+=`. Received ${L}`}}else{let L=e(v,{colors:!1});L.length>25&&(L=`${L.slice(0,25)}...`),_+=`. Received type ${typeof v} (${L})`}return _},TypeError),f("ERR_INVALID_ARG_VALUE",(m,g,v="is invalid")=>{let _=e(g);return _.length>128&&(_=_.slice(0,128)+"..."),`The ${m.includes(".")?"property":"argument"} '${m}' ${v}. Received ${_}`},TypeError),f("ERR_INVALID_RETURN_VALUE",(m,g,v)=>{var _;const w=v!=null&&(_=v.constructor)!==null&&_!==void 0&&_.name?`instance of ${v.constructor.name}`:`type ${typeof v}`;return`Expected ${m} to be returned from the "${g}" function but got ${w}.`},TypeError),f("ERR_MISSING_ARGS",(...m)=>{c(m.length>0,"At least one arg needs to be specified");let g;const v=m.length;switch(m=(Array.isArray(m)?m:[m]).map(_=>`"${_}"`).join(" or "),v){case 1:g+=`The ${m[0]} argument`;break;case 2:g+=`The ${m[0]} and ${m[1]} arguments`;break;default:{const _=m.pop();g+=`The ${m.join(", ")}, and ${_} arguments`}break}return`${g} must be specified`},TypeError),f("ERR_OUT_OF_RANGE",(m,g,v)=>{c(g,'Missing "range" argument');let _;return Number.isInteger(v)&&Math.abs(v)>2**32?_=d(String(v)):typeof v=="bigint"?(_=String(v),(v>2n**32n||v<-(2n**32n))&&(_=d(_)),_+="n"):_=e(v),`The value of "${m}" is out of range. It must be ${g}. Received ${_}`},RangeError),f("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error),f("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error),f("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error),f("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error),f("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error),f("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),f("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error),f("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error),f("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error),f("ERR_STREAM_WRITE_AFTER_END","write after end",Error),f("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError),o_={AbortError:b,aggregateTwoErrors:p(y),hideStackFrames:p,codes:l},o_}var u_,Wx;function Ey(){if(Wx)return u_;Wx=1;const{ArrayIsArray:t,ArrayPrototypeIncludes:e,ArrayPrototypeJoin:u,ArrayPrototypeMap:s,NumberIsInteger:n,NumberIsNaN:r,NumberMAX_SAFE_INTEGER:a,NumberMIN_SAFE_INTEGER:o,NumberParseInt:l,ObjectPrototypeHasOwnProperty:c,RegExpPrototypeExec:d,String:h,StringPrototypeToUpperCase:f,StringPrototypeTrim:p}=Rr(),{hideStackFrames:y,codes:{ERR_SOCKET_BAD_PORT:b,ERR_INVALID_ARG_TYPE:m,ERR_INVALID_ARG_VALUE:g,ERR_OUT_OF_RANGE:v,ERR_UNKNOWN_SIGNAL:_}}=Un(),{normalizeEncoding:w}=Pn(),{isAsyncFunction:S,isArrayBufferView:A}=Pn().types,D={};function L(z){return z===(z|0)}function E(z){return z===z>>>0}const O=/^[0-7]+$/,P="must be a 32-bit unsigned integer or an octal string";function j(z,Y,te){if(typeof z>"u"&&(z=te),typeof z=="string"){if(d(O,z)===null)throw new g(Y,z,P);z=l(z,8)}return q(z,Y),z}const U=y((z,Y,te=o,ce=a)=>{if(typeof z!="number")throw new m(Y,"number",z);if(!n(z))throw new v(Y,"an integer",z);if(zce)throw new v(Y,`>= ${te} && <= ${ce}`,z)}),M=y((z,Y,te=-2147483648,ce=2147483647)=>{if(typeof z!="number")throw new m(Y,"number",z);if(!n(z))throw new v(Y,"an integer",z);if(zce)throw new v(Y,`>= ${te} && <= ${ce}`,z)}),q=y((z,Y,te=!1)=>{if(typeof z!="number")throw new m(Y,"number",z);if(!n(z))throw new v(Y,"an integer",z);const ce=te?1:0,Ae=4294967295;if(zAe)throw new v(Y,`>= ${ce} && <= ${Ae}`,z)});function Q(z,Y){if(typeof z!="string")throw new m(Y,"string",z)}function Z(z,Y,te=void 0,ce){if(typeof z!="number")throw new m(Y,"number",z);if(te!=null&&zce||(te!=null||ce!=null)&&r(z))throw new v(Y,`${te!=null?`>= ${te}`:""}${te!=null&&ce!=null?" && ":""}${ce!=null?`<= ${ce}`:""}`,z)}const K=y((z,Y,te)=>{if(!e(te,z)){const Ae="must be one of: "+u(s(te,Ie=>typeof Ie=="string"?`'${Ie}'`:h(Ie)),", ");throw new g(Y,z,Ae)}});function fe(z,Y){if(typeof z!="boolean")throw new m(Y,"boolean",z)}function X(z,Y,te){return z==null||!c(z,Y)?te:z[Y]}const he=y((z,Y,te=null)=>{const ce=X(te,"allowArray",!1),Ae=X(te,"allowFunction",!1);if(!X(te,"nullable",!1)&&z===null||!ce&&t(z)||typeof z!="object"&&(!Ae||typeof z!="function"))throw new m(Y,"Object",z)}),xe=y((z,Y)=>{if(z!=null&&typeof z!="object"&&typeof z!="function")throw new m(Y,"a dictionary",z)}),ie=y((z,Y,te=0)=>{if(!t(z))throw new m(Y,"Array",z);if(z.length{if(!A(z))throw new m(Y,["Buffer","TypedArray","DataView"],z)});function oe(z,Y){const te=w(Y),ce=z.length;if(te==="hex"&&ce%2!==0)throw new g("encoding",Y,`is invalid for data of length ${ce}`)}function $(z,Y="Port",te=!0){if(typeof z!="number"&&typeof z!="string"||typeof z=="string"&&p(z).length===0||+z!==+z>>>0||z>65535||z===0&&!te)throw new b(Y,z,te);return z|0}const N=y((z,Y)=>{if(z!==void 0&&(z===null||typeof z!="object"||!("aborted"in z)))throw new m(Y,"AbortSignal",z)}),R=y((z,Y)=>{if(typeof z!="function")throw new m(Y,"Function",z)}),T=y((z,Y)=>{if(typeof z!="function"||S(z))throw new m(Y,"Function",z)}),x=y((z,Y)=>{if(z!==void 0)throw new m(Y,"undefined",z)});function B(z,Y,te){if(!e(te,z))throw new m(Y,`('${u(te,"|")}')`,z)}const k=/^(?:<[^>]*>)(?:\s*;\s*[^;"\s]+(?:=(")?[^;"\s]*\1)?)*$/;function V(z,Y){if(typeof z>"u"||!d(k,z))throw new g(Y,z,'must be an array or string of format "; rel=preload; as=style"')}function J(z){if(typeof z=="string")return V(z,"hints"),z;if(t(z)){const Y=z.length;let te="";if(Y===0)return te;for(let ce=0;ce; rel=preload; as=style"')}return u_={isInt32:L,isUint32:E,parseFileMode:j,validateArray:ie,validateStringArray:ae,validateBooleanArray:Oe,validateAbortSignalArray:Ne,validateBoolean:fe,validateBuffer:de,validateDictionary:xe,validateEncoding:oe,validateFunction:R,validateInt32:M,validateInteger:U,validateNumber:Z,validateObject:he,validateOneOf:K,validatePlainFunction:T,validatePort:$,validateSignalName:ge,validateString:Q,validateUint32:q,validateUndefined:x,validateUnion:B,validateAbortSignal:N,validateLinkHeaderValue:J},u_}var o1={exports:{}},c_,Jx;function Ta(){if(Jx)return c_;Jx=1;const{SymbolAsyncIterator:t,SymbolIterator:e,SymbolFor:u}=Rr(),s=u("nodejs.stream.destroyed"),n=u("nodejs.stream.errored"),r=u("nodejs.stream.readable"),a=u("nodejs.stream.writable"),o=u("nodejs.stream.disturbed"),l=u("nodejs.webstream.isClosedPromise"),c=u("nodejs.webstream.controllerErrorFunction");function d(X,he=!1){var xe;return!!(X&&typeof X.pipe=="function"&&typeof X.on=="function"&&(!he||typeof X.pause=="function"&&typeof X.resume=="function")&&(!X._writableState||((xe=X._readableState)===null||xe===void 0?void 0:xe.readable)!==!1)&&(!X._writableState||X._readableState))}function h(X){var he;return!!(X&&typeof X.write=="function"&&typeof X.on=="function"&&(!X._readableState||((he=X._writableState)===null||he===void 0?void 0:he.writable)!==!1))}function f(X){return!!(X&&typeof X.pipe=="function"&&X._readableState&&typeof X.on=="function"&&typeof X.write=="function")}function p(X){return X&&(X._readableState||X._writableState||typeof X.write=="function"&&typeof X.on=="function"||typeof X.pipe=="function"&&typeof X.on=="function")}function y(X){return!!(X&&!p(X)&&typeof X.pipeThrough=="function"&&typeof X.getReader=="function"&&typeof X.cancel=="function")}function b(X){return!!(X&&!p(X)&&typeof X.getWriter=="function"&&typeof X.abort=="function")}function m(X){return!!(X&&!p(X)&&typeof X.readable=="object"&&typeof X.writable=="object")}function g(X){return y(X)||b(X)||m(X)}function v(X,he){return X==null?!1:he===!0?typeof X[t]=="function":he===!1?typeof X[e]=="function":typeof X[t]=="function"||typeof X[e]=="function"}function _(X){if(!p(X))return null;const he=X._writableState,xe=X._readableState,ie=he||xe;return!!(X.destroyed||X[s]||ie!=null&&ie.destroyed)}function w(X){if(!h(X))return null;if(X.writableEnded===!0)return!0;const he=X._writableState;return he!=null&&he.errored?!1:typeof(he==null?void 0:he.ended)!="boolean"?null:he.ended}function S(X,he){if(!h(X))return null;if(X.writableFinished===!0)return!0;const xe=X._writableState;return xe!=null&&xe.errored?!1:typeof(xe==null?void 0:xe.finished)!="boolean"?null:!!(xe.finished||he===!1&&xe.ended===!0&&xe.length===0)}function A(X){if(!d(X))return null;if(X.readableEnded===!0)return!0;const he=X._readableState;return!he||he.errored?!1:typeof(he==null?void 0:he.ended)!="boolean"?null:he.ended}function D(X,he){if(!d(X))return null;const xe=X._readableState;return xe!=null&&xe.errored?!1:typeof(xe==null?void 0:xe.endEmitted)!="boolean"?null:!!(xe.endEmitted||he===!1&&xe.ended===!0&&xe.length===0)}function L(X){return X&&X[r]!=null?X[r]:typeof(X==null?void 0:X.readable)!="boolean"?null:_(X)?!1:d(X)&&X.readable&&!D(X)}function E(X){return X&&X[a]!=null?X[a]:typeof(X==null?void 0:X.writable)!="boolean"?null:_(X)?!1:h(X)&&X.writable&&!w(X)}function O(X,he){return p(X)?_(X)?!0:!((he==null?void 0:he.readable)!==!1&&L(X)||(he==null?void 0:he.writable)!==!1&&E(X)):null}function P(X){var he,xe;return p(X)?X.writableErrored?X.writableErrored:(he=(xe=X._writableState)===null||xe===void 0?void 0:xe.errored)!==null&&he!==void 0?he:null:null}function j(X){var he,xe;return p(X)?X.readableErrored?X.readableErrored:(he=(xe=X._readableState)===null||xe===void 0?void 0:xe.errored)!==null&&he!==void 0?he:null:null}function U(X){if(!p(X))return null;if(typeof X.closed=="boolean")return X.closed;const he=X._writableState,xe=X._readableState;return typeof(he==null?void 0:he.closed)=="boolean"||typeof(xe==null?void 0:xe.closed)=="boolean"?(he==null?void 0:he.closed)||(xe==null?void 0:xe.closed):typeof X._closed=="boolean"&&M(X)?X._closed:null}function M(X){return typeof X._closed=="boolean"&&typeof X._defaultKeepAlive=="boolean"&&typeof X._removedConnection=="boolean"&&typeof X._removedContLen=="boolean"}function q(X){return typeof X._sent100=="boolean"&&M(X)}function Q(X){var he;return typeof X._consuming=="boolean"&&typeof X._dumped=="boolean"&&((he=X.req)===null||he===void 0?void 0:he.upgradeOrConnect)===void 0}function Z(X){if(!p(X))return null;const he=X._writableState,xe=X._readableState,ie=he||xe;return!ie&&q(X)||!!(ie&&ie.autoDestroy&&ie.emitClose&&ie.closed===!1)}function K(X){var he;return!!(X&&((he=X[o])!==null&&he!==void 0?he:X.readableDidRead||X.readableAborted))}function fe(X){var he,xe,ie,ae,Oe,Ne,ge,de,oe,$;return!!(X&&((he=(xe=(ie=(ae=(Oe=(Ne=X[n])!==null&&Ne!==void 0?Ne:X.readableErrored)!==null&&Oe!==void 0?Oe:X.writableErrored)!==null&&ae!==void 0?ae:(ge=X._readableState)===null||ge===void 0?void 0:ge.errorEmitted)!==null&&ie!==void 0?ie:(de=X._writableState)===null||de===void 0?void 0:de.errorEmitted)!==null&&xe!==void 0?xe:(oe=X._readableState)===null||oe===void 0?void 0:oe.errored)!==null&&he!==void 0?he:!(($=X._writableState)===null||$===void 0)&&$.errored))}return c_={isDestroyed:_,kIsDestroyed:s,isDisturbed:K,kIsDisturbed:o,isErrored:fe,kIsErrored:n,isReadable:L,kIsReadable:r,kIsClosedPromise:l,kControllerErrorFunction:c,kIsWritable:a,isClosed:U,isDuplexNodeStream:f,isFinished:O,isIterable:v,isReadableNodeStream:d,isReadableStream:y,isReadableEnded:A,isReadableFinished:D,isReadableErrored:j,isNodeStream:p,isWebStream:g,isWritable:E,isWritableNodeStream:h,isWritableStream:b,isWritableEnded:w,isWritableFinished:S,isWritableErrored:P,isServerRequest:Q,isServerResponse:q,willEmitClose:Z,isTransformStream:m},c_}var Xx;function Za(){if(Xx)return o1.exports;Xx=1;const t=Sa(),{AbortError:e,codes:u}=Un(),{ERR_INVALID_ARG_TYPE:s,ERR_STREAM_PREMATURE_CLOSE:n}=u,{kEmptyObject:r,once:a}=Pn(),{validateAbortSignal:o,validateFunction:l,validateObject:c,validateBoolean:d}=Ey(),{Promise:h,PromisePrototypeThen:f,SymbolDispose:p}=Rr(),{isClosed:y,isReadable:b,isReadableNodeStream:m,isReadableStream:g,isReadableFinished:v,isReadableErrored:_,isWritable:w,isWritableNodeStream:S,isWritableStream:A,isWritableFinished:D,isWritableErrored:L,isNodeStream:E,willEmitClose:O,kIsClosedPromise:P}=Ta();let j;function U(K){return K.setHeader&&typeof K.abort=="function"}const M=()=>{};function q(K,fe,X){var he,xe;if(arguments.length===2?(X=fe,fe=r):fe==null?fe=r:c(fe,"options"),l(X,"callback"),o(fe.signal,"options.signal"),X=a(X),g(K)||A(K))return Q(K,fe,X);if(!E(K))throw new s("stream",["ReadableStream","WritableStream","Stream"],K);const ie=(he=fe.readable)!==null&&he!==void 0?he:m(K),ae=(xe=fe.writable)!==null&&xe!==void 0?xe:S(K),Oe=K._writableState,Ne=K._readableState,ge=()=>{K.writable||$()};let de=O(K)&&m(K)===ie&&S(K)===ae,oe=D(K,!1);const $=()=>{oe=!0,K.destroyed&&(de=!1),!(de&&(!K.readable||ie))&&(!ie||N)&&X.call(K)};let N=v(K,!1);const R=()=>{N=!0,K.destroyed&&(de=!1),!(de&&(!K.writable||ae))&&(!ae||oe)&&X.call(K)},T=z=>{X.call(K,z)};let x=y(K);const B=()=>{x=!0;const z=L(K)||_(K);if(z&&typeof z!="boolean")return X.call(K,z);if(ie&&!N&&m(K,!0)&&!v(K,!1))return X.call(K,new n);if(ae&&!oe&&!D(K,!1))return X.call(K,new n);X.call(K)},k=()=>{x=!0;const z=L(K)||_(K);if(z&&typeof z!="boolean")return X.call(K,z);X.call(K)},V=()=>{K.req.on("finish",$)};U(K)?(K.on("complete",$),de||K.on("abort",B),K.req?V():K.on("request",V)):ae&&!Oe&&(K.on("end",ge),K.on("close",ge)),!de&&typeof K.aborted=="boolean"&&K.on("aborted",B),K.on("end",R),K.on("finish",$),fe.error!==!1&&K.on("error",T),K.on("close",B),x?t.nextTick(B):Oe!=null&&Oe.errorEmitted||Ne!=null&&Ne.errorEmitted?de||t.nextTick(k):(!ie&&(!de||b(K))&&(oe||w(K)===!1)||!ae&&(!de||w(K))&&(N||b(K)===!1)||Ne&&K.req&&K.aborted)&&t.nextTick(k);const J=()=>{X=M,K.removeListener("aborted",B),K.removeListener("complete",$),K.removeListener("abort",B),K.removeListener("request",V),K.req&&K.req.removeListener("finish",$),K.removeListener("end",ge),K.removeListener("close",ge),K.removeListener("finish",$),K.removeListener("end",R),K.removeListener("error",T),K.removeListener("close",B)};if(fe.signal&&!x){const z=()=>{const Y=X;J(),Y.call(K,new e(void 0,{cause:fe.signal.reason}))};if(fe.signal.aborted)t.nextTick(z);else{j=j||Pn().addAbortListener;const Y=j(fe.signal,z),te=X;X=a((...ce)=>{Y[p](),te.apply(K,ce)})}}return J}function Q(K,fe,X){let he=!1,xe=M;if(fe.signal)if(xe=()=>{he=!0,X.call(K,new e(void 0,{cause:fe.signal.reason}))},fe.signal.aborted)t.nextTick(xe);else{j=j||Pn().addAbortListener;const ae=j(fe.signal,xe),Oe=X;X=a((...Ne)=>{ae[p](),Oe.apply(K,Ne)})}const ie=(...ae)=>{he||t.nextTick(()=>X.apply(K,ae))};return f(K[P].promise,ie,ie),M}function Z(K,fe){var X;let he=!1;return fe===null&&(fe=r),(X=fe)!==null&&X!==void 0&&X.cleanup&&(d(fe.cleanup,"cleanup"),he=fe.cleanup),new h((xe,ie)=>{const ae=q(K,fe,Oe=>{he&&ae(),Oe?ie(Oe):xe()})})}return o1.exports=q,o1.exports.finished=Z,o1.exports}var l_,Kx;function iu(){if(Kx)return l_;Kx=1;const t=Sa(),{aggregateTwoErrors:e,codes:{ERR_MULTIPLE_CALLBACK:u},AbortError:s}=Un(),{Symbol:n}=Rr(),{kIsDestroyed:r,isDestroyed:a,isFinished:o,isServerRequest:l}=Ta(),c=n("kDestroy"),d=n("kConstruct");function h(O,P,j){O&&(O.stack,P&&!P.errored&&(P.errored=O),j&&!j.errored&&(j.errored=O))}function f(O,P){const j=this._readableState,U=this._writableState,M=U||j;return U!=null&&U.destroyed||j!=null&&j.destroyed?(typeof P=="function"&&P(),this):(h(O,U,j),U&&(U.destroyed=!0),j&&(j.destroyed=!0),M.constructed?p(this,O,P):this.once(c,function(q){p(this,e(q,O),P)}),this)}function p(O,P,j){let U=!1;function M(q){if(U)return;U=!0;const Q=O._readableState,Z=O._writableState;h(q,Z,Q),Z&&(Z.closed=!0),Q&&(Q.closed=!0),typeof j=="function"&&j(q),q?t.nextTick(y,O,q):t.nextTick(b,O)}try{O._destroy(P||null,M)}catch(q){M(q)}}function y(O,P){m(O,P),b(O)}function b(O){const P=O._readableState,j=O._writableState;j&&(j.closeEmitted=!0),P&&(P.closeEmitted=!0),(j!=null&&j.emitClose||P!=null&&P.emitClose)&&O.emit("close")}function m(O,P){const j=O._readableState,U=O._writableState;U!=null&&U.errorEmitted||j!=null&&j.errorEmitted||(U&&(U.errorEmitted=!0),j&&(j.errorEmitted=!0),O.emit("error",P))}function g(){const O=this._readableState,P=this._writableState;O&&(O.constructed=!0,O.closed=!1,O.closeEmitted=!1,O.destroyed=!1,O.errored=null,O.errorEmitted=!1,O.reading=!1,O.ended=O.readable===!1,O.endEmitted=O.readable===!1),P&&(P.constructed=!0,P.destroyed=!1,P.closed=!1,P.closeEmitted=!1,P.errored=null,P.errorEmitted=!1,P.finalCalled=!1,P.prefinished=!1,P.ended=P.writable===!1,P.ending=P.writable===!1,P.finished=P.writable===!1)}function v(O,P,j){const U=O._readableState,M=O._writableState;if(M!=null&&M.destroyed||U!=null&&U.destroyed)return this;U!=null&&U.autoDestroy||M!=null&&M.autoDestroy?O.destroy(P):P&&(P.stack,M&&!M.errored&&(M.errored=P),U&&!U.errored&&(U.errored=P),j?t.nextTick(m,O,P):m(O,P))}function _(O,P){if(typeof O._construct!="function")return;const j=O._readableState,U=O._writableState;j&&(j.constructed=!1),U&&(U.constructed=!1),O.once(d,P),!(O.listenerCount(d)>1)&&t.nextTick(w,O)}function w(O){let P=!1;function j(U){if(P){v(O,U??new u);return}P=!0;const M=O._readableState,q=O._writableState,Q=q||M;M&&(M.constructed=!0),q&&(q.constructed=!0),Q.destroyed?O.emit(c,U):U?v(O,U,!0):t.nextTick(S,O)}try{O._construct(U=>{t.nextTick(j,U)})}catch(U){t.nextTick(j,U)}}function S(O){O.emit(d)}function A(O){return(O==null?void 0:O.setHeader)&&typeof O.abort=="function"}function D(O){O.emit("close")}function L(O,P){O.emit("error",P),t.nextTick(D,O)}function E(O,P){!O||a(O)||(!P&&!o(O)&&(P=new s),l(O)?(O.socket=null,O.destroy(P)):A(O)?O.abort():A(O.req)?O.req.abort():typeof O.destroy=="function"?O.destroy(P):typeof O.close=="function"?O.close():P?t.nextTick(L,O,P):t.nextTick(D,O),O.destroyed||(O[r]=!0))}return l_={construct:_,destroyer:E,destroy:f,undestroy:g,errorOrDestroy:v},l_}var d_,Yx;function MT(){if(Yx)return d_;Yx=1;const{ArrayIsArray:t,ObjectSetPrototypeOf:e}=Rr(),{EventEmitter:u}=wy();function s(r){u.call(this,r)}e(s.prototype,u.prototype),e(s,u),s.prototype.pipe=function(r,a){const o=this;function l(b){r.writable&&r.write(b)===!1&&o.pause&&o.pause()}o.on("data",l);function c(){o.readable&&o.resume&&o.resume()}r.on("drain",c),!r._isStdio&&(!a||a.end!==!1)&&(o.on("end",h),o.on("close",f));let d=!1;function h(){d||(d=!0,r.end())}function f(){d||(d=!0,typeof r.destroy=="function"&&r.destroy())}function p(b){y(),u.listenerCount(this,"error")===0&&this.emit("error",b)}n(o,"error",p),n(r,"error",p);function y(){o.removeListener("data",l),r.removeListener("drain",c),o.removeListener("end",h),o.removeListener("close",f),o.removeListener("error",p),r.removeListener("error",p),o.removeListener("end",y),o.removeListener("close",y),r.removeListener("close",y)}return o.on("end",y),o.on("close",y),r.on("close",y),r.emit("pipe",o),r};function n(r,a,o){if(typeof r.prependListener=="function")return r.prependListener(a,o);!r._events||!r._events[a]?r.on(a,o):t(r._events[a])?r._events[a].unshift(o):r._events[a]=[o,r._events[a]]}return d_={Stream:s,prependListener:n},d_}var f_={exports:{}},Zx;function qb(){return Zx||(Zx=1,function(t){const{SymbolDispose:e}=Rr(),{AbortError:u,codes:s}=Un(),{isNodeStream:n,isWebStream:r,kControllerErrorFunction:a}=Ta(),o=Za(),{ERR_INVALID_ARG_TYPE:l}=s;let c;const d=(h,f)=>{if(typeof h!="object"||!("aborted"in h))throw new l(f,"AbortSignal",h)};t.exports.addAbortSignal=function(f,p){if(d(f,"signal"),!n(p)&&!r(p))throw new l("stream",["ReadableStream","WritableStream","Stream"],p);return t.exports.addAbortSignalNoValidate(f,p)},t.exports.addAbortSignalNoValidate=function(h,f){if(typeof h!="object"||!("aborted"in h))return f;const p=n(f)?()=>{f.destroy(new u(void 0,{cause:h.reason}))}:()=>{f[a](new u(void 0,{cause:h.reason}))};if(h.aborted)p();else{c=c||Pn().addAbortListener;const y=c(h,p);o(f,y[e])}return f}}(f_)),f_.exports}var h_,eI;function Kz(){if(eI)return h_;eI=1;const{StringPrototypeSlice:t,SymbolIterator:e,TypedArrayPrototypeSet:u,Uint8Array:s}=Rr(),{Buffer:n}=Wi(),{inspect:r}=Pn();return h_=class{constructor(){this.head=null,this.tail=null,this.length=0}push(o){const l={data:o,next:null};this.length>0?this.tail.next=l:this.head=l,this.tail=l,++this.length}unshift(o){const l={data:o,next:this.head};this.length===0&&(this.tail=l),this.head=l,++this.length}shift(){if(this.length===0)return;const o=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,o}clear(){this.head=this.tail=null,this.length=0}join(o){if(this.length===0)return"";let l=this.head,c=""+l.data;for(;(l=l.next)!==null;)c+=o+l.data;return c}concat(o){if(this.length===0)return n.alloc(0);const l=n.allocUnsafe(o>>>0);let c=this.head,d=0;for(;c;)u(l,c.data,d),d+=c.data.length,c=c.next;return l}consume(o,l){const c=this.head.data;if(oh.length)l+=h,o-=h.length;else{o===h.length?(l+=h,++d,c.next?this.head=c.next:this.head=this.tail=null):(l+=t(h,0,o),this.head=c,c.data=t(h,o));break}++d}while((c=c.next)!==null);return this.length-=d,l}_getBuffer(o){const l=n.allocUnsafe(o),c=o;let d=this.head,h=0;do{const f=d.data;if(o>f.length)u(l,f,c-o),o-=f.length;else{o===f.length?(u(l,f,c-o),++h,d.next?this.head=d.next:this.head=this.tail=null):(u(l,new s(f.buffer,f.byteOffset,o),c-o),this.head=d,d.data=f.slice(o));break}++h}while((d=d.next)!==null);return this.length-=h,l}[Symbol.for("nodejs.util.inspect.custom")](o,l){return r(this,{...l,depth:0,customInspect:!1})}},h_}var p_,tI;function Bb(){if(tI)return p_;tI=1;const{MathFloor:t,NumberIsInteger:e}=Rr(),{validateInteger:u}=Ey(),{ERR_INVALID_ARG_VALUE:s}=Un().codes;let n=16*1024,r=16;function a(d,h,f){return d.highWaterMark!=null?d.highWaterMark:h?d[f]:null}function o(d){return d?r:n}function l(d,h){u(h,"value",0),d?r=h:n=h}function c(d,h,f,p){const y=a(h,p,f);if(y!=null){if(!e(y)||y<0){const b=p?`options.${f}`:"options.highWaterMark";throw new s(b,y)}return t(y)}return o(d.objectMode)}return p_={getHighWaterMark:c,getDefaultHighWaterMark:o,setDefaultHighWaterMark:l},p_}var y_={},u1={exports:{}};/*! safe-buffer. MIT License. Feross Aboukhadijeh */var rI;function Yz(){return rI||(rI=1,function(t,e){var u=Wi(),s=u.Buffer;function n(a,o){for(var l in a)o[l]=a[l]}s.from&&s.alloc&&s.allocUnsafe&&s.allocUnsafeSlow?t.exports=u:(n(u,e),e.Buffer=r);function r(a,o,l){return s(a,o,l)}r.prototype=Object.create(s.prototype),n(s,r),r.from=function(a,o,l){if(typeof a=="number")throw new TypeError("Argument must not be a number");return s(a,o,l)},r.alloc=function(a,o,l){if(typeof a!="number")throw new TypeError("Argument must be a number");var c=s(a);return o!==void 0?typeof l=="string"?c.fill(o,l):c.fill(o):c.fill(0),c},r.allocUnsafe=function(a){if(typeof a!="number")throw new TypeError("Argument must be a number");return s(a)},r.allocUnsafeSlow=function(a){if(typeof a!="number")throw new TypeError("Argument must be a number");return u.SlowBuffer(a)}}(u1,u1.exports)),u1.exports}var nI;function Zz(){if(nI)return y_;nI=1;var t=Yz().Buffer,e=t.isEncoding||function(g){switch(g=""+g,g&&g.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function u(g){if(!g)return"utf8";for(var v;;)switch(g){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return g;default:if(v)return;g=(""+g).toLowerCase(),v=!0}}function s(g){var v=u(g);if(typeof v!="string"&&(t.isEncoding===e||!e(g)))throw new Error("Unknown encoding: "+g);return v||g}y_.StringDecoder=n;function n(g){this.encoding=s(g);var v;switch(this.encoding){case"utf16le":this.text=h,this.end=f,v=4;break;case"utf8":this.fillLast=l,v=4;break;case"base64":this.text=p,this.end=y,v=3;break;default:this.write=b,this.end=m;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=t.allocUnsafe(v)}n.prototype.write=function(g){if(g.length===0)return"";var v,_;if(this.lastNeed){if(v=this.fillLast(g),v===void 0)return"";_=this.lastNeed,this.lastNeed=0}else _=0;return _>5===6?2:g>>4===14?3:g>>3===30?4:g>>6===2?-1:-2}function a(g,v,_){var w=v.length-1;if(w<_)return 0;var S=r(v[w]);return S>=0?(S>0&&(g.lastNeed=S-1),S):--w<_||S===-2?0:(S=r(v[w]),S>=0?(S>0&&(g.lastNeed=S-2),S):--w<_||S===-2?0:(S=r(v[w]),S>=0?(S>0&&(S===2?S=0:g.lastNeed=S-3),S):0))}function o(g,v,_){if((v[0]&192)!==128)return g.lastNeed=0,"�";if(g.lastNeed>1&&v.length>1){if((v[1]&192)!==128)return g.lastNeed=1,"�";if(g.lastNeed>2&&v.length>2&&(v[2]&192)!==128)return g.lastNeed=2,"�"}}function l(g){var v=this.lastTotal-this.lastNeed,_=o(this,g);if(_!==void 0)return _;if(this.lastNeed<=g.length)return g.copy(this.lastChar,v,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);g.copy(this.lastChar,v,0,g.length),this.lastNeed-=g.length}function c(g,v){var _=a(this,g,v);if(!this.lastNeed)return g.toString("utf8",v);this.lastTotal=_;var w=g.length-(_-this.lastNeed);return g.copy(this.lastChar,0,w),g.toString("utf8",v,w)}function d(g){var v=g&&g.length?this.write(g):"";return this.lastNeed?v+"�":v}function h(g,v){if((g.length-v)%2===0){var _=g.toString("utf16le",v);if(_){var w=_.charCodeAt(_.length-1);if(w>=55296&&w<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=g[g.length-2],this.lastChar[1]=g[g.length-1],_.slice(0,-1)}return _}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=g[g.length-1],g.toString("utf16le",v,g.length-1)}function f(g){var v=g&&g.length?this.write(g):"";if(this.lastNeed){var _=this.lastTotal-this.lastNeed;return v+this.lastChar.toString("utf16le",0,_)}return v}function p(g,v){var _=(g.length-v)%3;return _===0?g.toString("base64",v):(this.lastNeed=3-_,this.lastTotal=3,_===1?this.lastChar[0]=g[g.length-1]:(this.lastChar[0]=g[g.length-2],this.lastChar[1]=g[g.length-1]),g.toString("base64",v,g.length-_))}function y(g){var v=g&&g.length?this.write(g):"";return this.lastNeed?v+this.lastChar.toString("base64",0,3-this.lastNeed):v}function b(g){return g.toString(this.encoding)}function m(g){return g&&g.length?this.write(g):""}return y_}var b_,iI;function yq(){if(iI)return b_;iI=1;const t=Sa(),{PromisePrototypeThen:e,SymbolAsyncIterator:u,SymbolIterator:s}=Rr(),{Buffer:n}=Wi(),{ERR_INVALID_ARG_TYPE:r,ERR_STREAM_NULL_VALUES:a}=Un().codes;function o(l,c,d){let h;if(typeof c=="string"||c instanceof n)return new l({objectMode:!0,...d,read(){this.push(c),this.push(null)}});let f;if(c&&c[u])f=!0,h=c[u]();else if(c&&c[s])f=!1,h=c[s]();else throw new r("iterable",["Iterable"],c);const p=new l({objectMode:!0,highWaterMark:1,...d});let y=!1;p._read=function(){y||(y=!0,m())},p._destroy=function(g,v){e(b(g),()=>t.nextTick(v,g),_=>t.nextTick(v,_||g))};async function b(g){const v=g!=null,_=typeof h.throw=="function";if(v&&_){const{value:w,done:S}=await h.throw(g);if(await w,S)return}if(typeof h.return=="function"){const{value:w}=await h.return();await w}}async function m(){for(;;){try{const{value:g,done:v}=f?await h.next():h.next();if(v)p.push(null);else{const _=g&&typeof g.then=="function"?await g:g;if(_===null)throw y=!1,new a;if(p.push(_))continue;y=!1}}catch(g){p.destroy(g)}break}}return p}return b_=o,b_}var g_,aI;function Ub(){if(aI)return g_;aI=1;const t=Sa(),{ArrayPrototypeIndexOf:e,NumberIsInteger:u,NumberIsNaN:s,NumberParseInt:n,ObjectDefineProperties:r,ObjectKeys:a,ObjectSetPrototypeOf:o,Promise:l,SafeSet:c,SymbolAsyncDispose:d,SymbolAsyncIterator:h,Symbol:f}=Rr();g_=ce,ce.ReadableState=te;const{EventEmitter:p}=wy(),{Stream:y,prependListener:b}=MT(),{Buffer:m}=Wi(),{addAbortSignal:g}=qb(),v=Za();let _=Pn().debuglog("stream",le=>{_=le});const w=Kz(),S=iu(),{getHighWaterMark:A,getDefaultHighWaterMark:D}=Bb(),{aggregateTwoErrors:L,codes:{ERR_INVALID_ARG_TYPE:E,ERR_METHOD_NOT_IMPLEMENTED:O,ERR_OUT_OF_RANGE:P,ERR_STREAM_PUSH_AFTER_EOF:j,ERR_STREAM_UNSHIFT_AFTER_END_EVENT:U},AbortError:M}=Un(),{validateObject:q}=Ey(),Q=f("kPaused"),{StringDecoder:Z}=Zz(),K=yq();o(ce.prototype,y.prototype),o(ce,y);const fe=()=>{},{errorOrDestroy:X}=S,he=1,xe=2,ie=4,ae=8,Oe=16,Ne=32,ge=64,de=128,oe=256,$=512,N=1024,R=2048,T=4096,x=8192,B=16384,k=32768,V=65536,J=1<<17,z=1<<18;function Y(le){return{enumerable:!1,get(){return(this.state&le)!==0},set(C){C?this.state|=le:this.state&=~le}}}r(te.prototype,{objectMode:Y(he),ended:Y(xe),endEmitted:Y(ie),reading:Y(ae),constructed:Y(Oe),sync:Y(Ne),needReadable:Y(ge),emittedReadable:Y(de),readableListening:Y(oe),resumeScheduled:Y($),errorEmitted:Y(N),emitClose:Y(R),autoDestroy:Y(T),destroyed:Y(x),closed:Y(B),closeEmitted:Y(k),multiAwaitDrain:Y(V),readingMore:Y(J),dataEmitted:Y(z)});function te(le,C,ee){typeof ee!="boolean"&&(ee=C instanceof va()),this.state=R|T|Oe|Ne,le&&le.objectMode&&(this.state|=he),ee&&le&&le.readableObjectMode&&(this.state|=he),this.highWaterMark=le?A(this,le,"readableHighWaterMark",ee):D(!1),this.buffer=new w,this.length=0,this.pipes=[],this.flowing=null,this[Q]=null,le&&le.emitClose===!1&&(this.state&=~R),le&&le.autoDestroy===!1&&(this.state&=~T),this.errored=null,this.defaultEncoding=le&&le.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.decoder=null,this.encoding=null,le&&le.encoding&&(this.decoder=new Z(le.encoding),this.encoding=le.encoding)}function ce(le){if(!(this instanceof ce))return new ce(le);const C=this instanceof va();this._readableState=new te(le,this,C),le&&(typeof le.read=="function"&&(this._read=le.read),typeof le.destroy=="function"&&(this._destroy=le.destroy),typeof le.construct=="function"&&(this._construct=le.construct),le.signal&&!C&&g(le.signal,this)),y.call(this,le),S.construct(this,()=>{this._readableState.needReadable&&be(this,this._readableState)})}ce.prototype.destroy=S.destroy,ce.prototype._undestroy=S.undestroy,ce.prototype._destroy=function(le,C){C(le)},ce.prototype[p.captureRejectionSymbol]=function(le){this.destroy(le)},ce.prototype[d]=function(){let le;return this.destroyed||(le=this.readableEnded?null:new M,this.destroy(le)),new l((C,ee)=>v(this,pe=>pe&&pe!==le?ee(pe):C(null)))},ce.prototype.push=function(le,C){return Ae(this,le,C,!1)},ce.prototype.unshift=function(le,C){return Ae(this,le,C,!0)};function Ae(le,C,ee,pe){_("readableAddChunk",C);const De=le._readableState;let Ue;if(De.state&he||(typeof C=="string"?(ee=ee||De.defaultEncoding,De.encoding!==ee&&(pe&&De.encoding?C=m.from(C,ee).toString(De.encoding):(C=m.from(C,ee),ee=""))):C instanceof m?ee="":y._isUint8Array(C)?(C=y._uint8ArrayToBuffer(C),ee=""):C!=null&&(Ue=new E("chunk",["string","Buffer","Uint8Array"],C))),Ue)X(le,Ue);else if(C===null)De.state&=~ae,F(le,De);else if(De.state&he||C&&C.length>0)if(pe)if(De.state&ie)X(le,new U);else{if(De.destroyed||De.errored)return!1;Ie(le,De,C,!0)}else if(De.ended)X(le,new j);else{if(De.destroyed||De.errored)return!1;De.state&=~ae,De.decoder&&!ee?(C=De.decoder.write(C),De.objectMode||C.length!==0?Ie(le,De,C,!1):be(le,De)):Ie(le,De,C,!1)}else pe||(De.state&=~ae,be(le,De));return!De.ended&&(De.length0?(C.state&V?C.awaitDrainWriters.clear():C.awaitDrainWriters=null,C.dataEmitted=!0,le.emit("data",ee)):(C.length+=C.objectMode?1:ee.length,pe?C.buffer.unshift(ee):C.buffer.push(ee),C.state&ge&&H(le)),be(le,C)}ce.prototype.isPaused=function(){const le=this._readableState;return le[Q]===!0||le.flowing===!1},ce.prototype.setEncoding=function(le){const C=new Z(le);this._readableState.decoder=C,this._readableState.encoding=this._readableState.decoder.encoding;const ee=this._readableState.buffer;let pe="";for(const De of ee)pe+=C.write(De);return ee.clear(),pe!==""&&ee.push(pe),this._readableState.length=pe.length,this};const Ee=1073741824;function qe(le){if(le>Ee)throw new P("size","<= 1GiB",le);return le--,le|=le>>>1,le|=le>>>2,le|=le>>>4,le|=le>>>8,le|=le>>>16,le++,le}function G(le,C){return le<=0||C.length===0&&C.ended?0:C.state&he?1:s(le)?C.flowing&&C.length?C.buffer.first().length:C.length:le<=C.length?le:C.ended?C.length:0}ce.prototype.read=function(le){_("read",le),le===void 0?le=NaN:u(le)||(le=n(le,10));const C=this._readableState,ee=le;if(le>C.highWaterMark&&(C.highWaterMark=qe(le)),le!==0&&(C.state&=~de),le===0&&C.needReadable&&((C.highWaterMark!==0?C.length>=C.highWaterMark:C.length>0)||C.ended))return _("read: emitReadable",C.length,C.ended),C.length===0&&C.ended?$e(this):H(this),null;if(le=G(le,C),le===0&&C.ended)return C.length===0&&$e(this),null;let pe=(C.state&ge)!==0;if(_("need readable",pe),(C.length===0||C.length-le0?De=Le(le,C):De=null,De===null?(C.needReadable=C.length<=C.highWaterMark,le=0):(C.length-=le,C.multiAwaitDrain?C.awaitDrainWriters.clear():C.awaitDrainWriters=null),C.length===0&&(C.ended||(C.needReadable=!0),ee!==le&&C.ended&&$e(this)),De!==null&&!C.errorEmitted&&!C.closeEmitted&&(C.dataEmitted=!0,this.emit("data",De)),De};function F(le,C){if(_("onEofChunk"),!C.ended){if(C.decoder){const ee=C.decoder.end();ee&&ee.length&&(C.buffer.push(ee),C.length+=C.objectMode?1:ee.length)}C.ended=!0,C.sync?H(le):(C.needReadable=!1,C.emittedReadable=!0,re(le))}}function H(le){const C=le._readableState;_("emitReadable",C.needReadable,C.emittedReadable),C.needReadable=!1,C.emittedReadable||(_("emitReadable",C.flowing),C.emittedReadable=!0,t.nextTick(re,le))}function re(le){const C=le._readableState;_("emitReadable_",C.destroyed,C.length,C.ended),!C.destroyed&&!C.errored&&(C.length||C.ended)&&(le.emit("readable"),C.emittedReadable=!1),C.needReadable=!C.flowing&&!C.ended&&C.length<=C.highWaterMark,W(le)}function be(le,C){!C.readingMore&&C.constructed&&(C.readingMore=!0,t.nextTick(Re,le,C))}function Re(le,C){for(;!C.reading&&!C.ended&&(C.length1&&pe.pipes.includes(le)&&(_("false write response, pause",pe.awaitDrainWriters.size),pe.awaitDrainWriters.add(le)),ee.pause()),Ve||(Ve=Ce(ee,le),le.on("drain",Ve))}ee.on("data",ft);function ft(Pe){_("ondata");const Me=le.write(Pe);_("dest.write",Me),Me===!1&&yt()}function et(Pe){if(_("onerror",Pe),ye(),le.removeListener("error",et),le.listenerCount("error")===0){const Me=le._writableState||le._readableState;Me&&!Me.errorEmitted?X(le,Pe):le.emit("error",Pe)}}b(le,"error",et);function Ir(){le.removeListener("finish",Ke),ye()}le.once("close",Ir);function Ke(){_("onfinish"),le.removeListener("close",Ir),ye()}le.once("finish",Ke);function ye(){_("unpipe"),ee.unpipe(le)}return le.emit("pipe",ee),le.writableNeedDrain===!0?yt():pe.flowing||(_("pipe resume"),ee.resume()),le};function Ce(le,C){return function(){const pe=le._readableState;pe.awaitDrainWriters===C?(_("pipeOnDrain",1),pe.awaitDrainWriters=null):pe.multiAwaitDrain&&(_("pipeOnDrain",pe.awaitDrainWriters.size),pe.awaitDrainWriters.delete(C)),(!pe.awaitDrainWriters||pe.awaitDrainWriters.size===0)&&le.listenerCount("data")&&le.resume()}}ce.prototype.unpipe=function(le){const C=this._readableState,ee={hasUnpiped:!1};if(C.pipes.length===0)return this;if(!le){const De=C.pipes;C.pipes=[],this.pause();for(let Ue=0;Ue0,pe.flowing!==!1&&this.resume()):le==="readable"&&!pe.endEmitted&&!pe.readableListening&&(pe.readableListening=pe.needReadable=!0,pe.flowing=!1,pe.emittedReadable=!1,_("on readable",pe.length,pe.reading),pe.length?H(this):pe.reading||t.nextTick(ke,this)),ee},ce.prototype.addListener=ce.prototype.on,ce.prototype.removeListener=function(le,C){const ee=y.prototype.removeListener.call(this,le,C);return le==="readable"&&t.nextTick(Qe,this),ee},ce.prototype.off=ce.prototype.removeListener,ce.prototype.removeAllListeners=function(le){const C=y.prototype.removeAllListeners.apply(this,arguments);return(le==="readable"||le===void 0)&&t.nextTick(Qe,this),C};function Qe(le){const C=le._readableState;C.readableListening=le.listenerCount("readable")>0,C.resumeScheduled&&C[Q]===!1?C.flowing=!0:le.listenerCount("data")>0?le.resume():C.readableListening||(C.flowing=null)}function ke(le){_("readable nexttick read 0"),le.read(0)}ce.prototype.resume=function(){const le=this._readableState;return le.flowing||(_("resume"),le.flowing=!le.readableListening,me(this,le)),le[Q]=!1,this};function me(le,C){C.resumeScheduled||(C.resumeScheduled=!0,t.nextTick(Se,le,C))}function Se(le,C){_("resume",C.reading),C.reading||le.read(0),C.resumeScheduled=!1,le.emit("resume"),W(le),C.flowing&&!C.reading&&le.read(0)}ce.prototype.pause=function(){return _("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(_("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState[Q]=!0,this};function W(le){const C=le._readableState;for(_("flow",C.flowing);C.flowing&&le.read()!==null;);}ce.prototype.wrap=function(le){let C=!1;le.on("data",pe=>{!this.push(pe)&&le.pause&&(C=!0,le.pause())}),le.on("end",()=>{this.push(null)}),le.on("error",pe=>{X(this,pe)}),le.on("close",()=>{this.destroy()}),le.on("destroy",()=>{this.destroy()}),this._read=()=>{C&&le.resume&&(C=!1,le.resume())};const ee=a(le);for(let pe=1;pe{De=Fe?L(De,Fe):null,ee(),ee=fe});try{for(;;){const Fe=le.destroyed?null:le.read();if(Fe!==null)yield Fe;else{if(De)throw De;if(De===null)return;await new l(pe)}}}catch(Fe){throw De=L(De,Fe),De}finally{(De||(C==null?void 0:C.destroyOnReturn)!==!1)&&(De===void 0||le._readableState.autoDestroy)?S.destroyer(le,null):(le.off("readable",pe),Ue())}}r(ce.prototype,{readable:{__proto__:null,get(){const le=this._readableState;return!!le&&le.readable!==!1&&!le.destroyed&&!le.errorEmitted&&!le.endEmitted},set(le){this._readableState&&(this._readableState.readable=!!le)}},readableDidRead:{__proto__:null,enumerable:!1,get:function(){return this._readableState.dataEmitted}},readableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._readableState.readable!==!1&&(this._readableState.destroyed||this._readableState.errored)&&!this._readableState.endEmitted)}},readableHighWaterMark:{__proto__:null,enumerable:!1,get:function(){return this._readableState.highWaterMark}},readableBuffer:{__proto__:null,enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}},readableFlowing:{__proto__:null,enumerable:!1,get:function(){return this._readableState.flowing},set:function(le){this._readableState&&(this._readableState.flowing=le)}},readableLength:{__proto__:null,enumerable:!1,get(){return this._readableState.length}},readableObjectMode:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.objectMode:!1}},readableEncoding:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.encoding:null}},errored:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.errored:null}},closed:{__proto__:null,get(){return this._readableState?this._readableState.closed:!1}},destroyed:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.destroyed:!1},set(le){this._readableState&&(this._readableState.destroyed=le)}},readableEnded:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.endEmitted:!1}}}),r(te.prototype,{pipesCount:{__proto__:null,get(){return this.pipes.length}},paused:{__proto__:null,get(){return this[Q]!==!1},set(le){this[Q]=!!le}}}),ce._fromList=Le;function Le(le,C){if(C.length===0)return null;let ee;return C.objectMode?ee=C.buffer.shift():!le||le>=C.length?(C.decoder?ee=C.buffer.join(""):C.buffer.length===1?ee=C.buffer.first():ee=C.buffer.concat(C.length),C.buffer.clear()):ee=C.buffer.consume(le,C.decoder),ee}function $e(le){const C=le._readableState;_("endReadable",C.endEmitted),C.endEmitted||(C.ended=!0,t.nextTick(We,C,le))}function We(le,C){if(_("endReadableNT",le.endEmitted,le.length),!le.errored&&!le.closeEmitted&&!le.endEmitted&&le.length===0){if(le.endEmitted=!0,C.emit("end"),C.writable&&C.allowHalfOpen===!1)t.nextTick(tt,C);else if(le.autoDestroy){const ee=C._writableState;(!ee||ee.autoDestroy&&(ee.finished||ee.writable===!1))&&C.destroy()}}}function tt(le){le.writable&&!le.writableEnded&&!le.destroyed&&le.end()}ce.from=function(le,C){return K(ce,le,C)};let lt;function ut(){return lt===void 0&&(lt={}),lt}return ce.fromWeb=function(le,C){return ut().newStreamReadableFromReadableStream(le,C)},ce.toWeb=function(le,C){return ut().newReadableStreamFromStreamReadable(le,C)},ce.wrap=function(le,C){var ee,pe;return new ce({objectMode:(ee=(pe=le.readableObjectMode)!==null&&pe!==void 0?pe:le.objectMode)!==null&&ee!==void 0?ee:!0,...C,destroy(De,Ue){S.destroyer(le,De),Ue(De)}}).wrap(le)},g_}var m_,sI;function FT(){if(sI)return m_;sI=1;const t=Sa(),{ArrayPrototypeSlice:e,Error:u,FunctionPrototypeSymbolHasInstance:s,ObjectDefineProperty:n,ObjectDefineProperties:r,ObjectSetPrototypeOf:a,StringPrototypeToLowerCase:o,Symbol:l,SymbolHasInstance:c}=Rr();m_=q,q.WritableState=U;const{EventEmitter:d}=wy(),h=MT().Stream,{Buffer:f}=Wi(),p=iu(),{addAbortSignal:y}=qb(),{getHighWaterMark:b,getDefaultHighWaterMark:m}=Bb(),{ERR_INVALID_ARG_TYPE:g,ERR_METHOD_NOT_IMPLEMENTED:v,ERR_MULTIPLE_CALLBACK:_,ERR_STREAM_CANNOT_PIPE:w,ERR_STREAM_DESTROYED:S,ERR_STREAM_ALREADY_FINISHED:A,ERR_STREAM_NULL_VALUES:D,ERR_STREAM_WRITE_AFTER_END:L,ERR_UNKNOWN_ENCODING:E}=Un().codes,{errorOrDestroy:O}=p;a(q.prototype,h.prototype),a(q,h);function P(){}const j=l("kOnFinished");function U(T,x,B){typeof B!="boolean"&&(B=x instanceof va()),this.objectMode=!!(T&&T.objectMode),B&&(this.objectMode=this.objectMode||!!(T&&T.writableObjectMode)),this.highWaterMark=T?b(this,T,"writableHighWaterMark",B):m(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;const k=!!(T&&T.decodeStrings===!1);this.decodeStrings=!k,this.defaultEncoding=T&&T.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=X.bind(void 0,x),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,M(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!T||T.emitClose!==!1,this.autoDestroy=!T||T.autoDestroy!==!1,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[j]=[]}function M(T){T.buffered=[],T.bufferedIndex=0,T.allBuffers=!0,T.allNoop=!0}U.prototype.getBuffer=function(){return e(this.buffered,this.bufferedIndex)},n(U.prototype,"bufferedRequestCount",{__proto__:null,get(){return this.buffered.length-this.bufferedIndex}});function q(T){const x=this instanceof va();if(!x&&!s(q,this))return new q(T);this._writableState=new U(T,this,x),T&&(typeof T.write=="function"&&(this._write=T.write),typeof T.writev=="function"&&(this._writev=T.writev),typeof T.destroy=="function"&&(this._destroy=T.destroy),typeof T.final=="function"&&(this._final=T.final),typeof T.construct=="function"&&(this._construct=T.construct),T.signal&&y(T.signal,this)),h.call(this,T),p.construct(this,()=>{const B=this._writableState;B.writing||ae(this,B),de(this,B)})}n(q,c,{__proto__:null,value:function(T){return s(this,T)?!0:this!==q?!1:T&&T._writableState instanceof U}}),q.prototype.pipe=function(){O(this,new w)};function Q(T,x,B,k){const V=T._writableState;if(typeof B=="function")k=B,B=V.defaultEncoding;else{if(!B)B=V.defaultEncoding;else if(B!=="buffer"&&!f.isEncoding(B))throw new E(B);typeof k!="function"&&(k=P)}if(x===null)throw new D;if(!V.objectMode)if(typeof x=="string")V.decodeStrings!==!1&&(x=f.from(x,B),B="buffer");else if(x instanceof f)B="buffer";else if(h._isUint8Array(x))x=h._uint8ArrayToBuffer(x),B="buffer";else throw new g("chunk",["string","Buffer","Uint8Array"],x);let J;return V.ending?J=new L:V.destroyed&&(J=new S("write")),J?(t.nextTick(k,J),O(T,J,!0),J):(V.pendingcb++,Z(T,V,x,B,k))}q.prototype.write=function(T,x,B){return Q(this,T,x,B)===!0},q.prototype.cork=function(){this._writableState.corked++},q.prototype.uncork=function(){const T=this._writableState;T.corked&&(T.corked--,T.writing||ae(this,T))},q.prototype.setDefaultEncoding=function(x){if(typeof x=="string"&&(x=o(x)),!f.isEncoding(x))throw new E(x);return this._writableState.defaultEncoding=x,this};function Z(T,x,B,k,V){const J=x.objectMode?1:B.length;x.length+=J;const z=x.lengthB.bufferedIndex&&ae(T,B),k?B.afterWriteTickInfo!==null&&B.afterWriteTickInfo.cb===V?B.afterWriteTickInfo.count++:(B.afterWriteTickInfo={count:1,cb:V,stream:T,state:B},t.nextTick(he,B.afterWriteTickInfo)):xe(T,B,1,V))}function he({stream:T,state:x,count:B,cb:k}){return x.afterWriteTickInfo=null,xe(T,x,B,k)}function xe(T,x,B,k){for(!x.ending&&!T.destroyed&&x.length===0&&x.needDrain&&(x.needDrain=!1,T.emit("drain"));B-- >0;)x.pendingcb--,k();x.destroyed&&ie(x),de(T,x)}function ie(T){if(T.writing)return;for(let V=T.bufferedIndex;V1&&T._writev){x.pendingcb-=J-1;const Y=x.allNoop?P:ce=>{for(let Ae=z;Ae256?(B.splice(0,z),x.bufferedIndex=0):x.bufferedIndex=z}x.bufferProcessing=!1}q.prototype._write=function(T,x,B){if(this._writev)this._writev([{chunk:T,encoding:x}],B);else throw new v("_write()")},q.prototype._writev=null,q.prototype.end=function(T,x,B){const k=this._writableState;typeof T=="function"?(B=T,T=null,x=null):typeof x=="function"&&(B=x,x=null);let V;if(T!=null){const J=Q(this,T,x);J instanceof u&&(V=J)}return k.corked&&(k.corked=1,this.uncork()),V||(!k.errored&&!k.ending?(k.ending=!0,de(this,k,!0),k.ended=!0):k.finished?V=new A("end"):k.destroyed&&(V=new S("end"))),typeof B=="function"&&(V||k.finished?t.nextTick(B,V):k[j].push(B)),this};function Oe(T){return T.ending&&!T.destroyed&&T.constructed&&T.length===0&&!T.errored&&T.buffered.length===0&&!T.finished&&!T.writing&&!T.errorEmitted&&!T.closeEmitted}function Ne(T,x){let B=!1;function k(V){if(B){O(T,V??_());return}if(B=!0,x.pendingcb--,V){const J=x[j].splice(0);for(let z=0;z{Oe(V)?oe(k,V):V.pendingcb--},T,x)):Oe(x)&&(x.pendingcb++,oe(T,x))))}function oe(T,x){x.pendingcb--,x.finished=!0;const B=x[j].splice(0);for(let k=0;k{if(ie!=null)throw new y("nully","body",ie)},ie=>{b(he,ie)});return he=new E({objectMode:!0,readable:!1,write:Z,final(ie){K(async()=>{try{await xe,t.nextTick(ie,null)}catch(ae){t.nextTick(ie,ae)}})},destroy:fe})}throw new y("Iterable, AsyncIterable or AsyncFunction",M,Q)}if(A(U))return j(U.arrayBuffer());if(n(U))return w(E,U,{objectMode:!0,writable:!1});if(c(U==null?void 0:U.readable)&&d(U==null?void 0:U.writable))return E.fromWeb(U);if(typeof(U==null?void 0:U.writable)=="object"||typeof(U==null?void 0:U.readable)=="object"){const Q=U!=null&&U.readable?a(U==null?void 0:U.readable)?U==null?void 0:U.readable:j(U.readable):void 0,Z=U!=null&&U.writable?o(U==null?void 0:U.writable)?U==null?void 0:U.writable:j(U.writable):void 0;return P({readable:Q,writable:Z})}const q=U==null?void 0:U.then;if(typeof q=="function"){let Q;return L(q,U,Z=>{Z!=null&&Q.push(Z),Q.push(null)},Z=>{b(Q,Z)}),Q=new E({objectMode:!0,writable:!1,read(){}})}throw new p(M,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],U)};function O(j){let{promise:U,resolve:M}=_();const q=new D,Q=q.signal;return{value:j(async function*(){for(;;){const K=U;U=null;const{chunk:fe,done:X,cb:he}=await K;if(t.nextTick(he),X)return;if(Q.aborted)throw new f(void 0,{cause:Q.reason});({promise:U,resolve:M}=_()),yield fe}}(),{signal:Q}),write(K,fe,X){const he=M;M=null,he({chunk:K,done:!1,cb:X})},final(K){const fe=M;M=null,fe({done:!0,cb:K})},destroy(K,fe){q.abort(),fe(K)}}}function P(j){const U=j.readable&&typeof j.readable.read!="function"?g.wrap(j.readable):j.readable,M=j.writable;let q=!!u(U),Q=!!s(M),Z,K,fe,X,he;function xe(ie){const ae=X;X=null,ae?ae(ie):ie&&he.destroy(ie)}return he=new E({readableObjectMode:!!(U!=null&&U.readableObjectMode),writableObjectMode:!!(M!=null&&M.writableObjectMode),readable:q,writable:Q}),Q&&(h(M,ie=>{Q=!1,ie&&b(U,ie),xe(ie)}),he._write=function(ie,ae,Oe){M.write(ie,ae)?Oe():Z=Oe},he._final=function(ie){M.end(),K=ie},M.on("drain",function(){if(Z){const ie=Z;Z=null,ie()}}),M.on("finish",function(){if(K){const ie=K;K=null,ie()}})),q&&(h(U,ie=>{q=!1,ie&&b(U,ie),xe(ie)}),U.on("readable",function(){if(fe){const ie=fe;fe=null,ie()}}),U.on("end",function(){he.push(null)}),he._read=function(){for(;;){const ie=U.read();if(ie===null){fe=he._read;return}if(!he.push(ie))return}}),he._destroy=function(ie,ae){!ie&&X!==null&&(ie=new f),fe=null,Z=null,K=null,X===null?ae(ie):(X=ae,b(M,ie),b(U,ie))},he}return __}var v_,uI;function va(){if(uI)return v_;uI=1;const{ObjectDefineProperties:t,ObjectGetOwnPropertyDescriptor:e,ObjectKeys:u,ObjectSetPrototypeOf:s}=Rr();v_=a;const n=Ub(),r=FT();s(a.prototype,n.prototype),s(a,n);{const d=u(r.prototype);for(let h=0;h{if(d){c?c(d):this.destroy(d);return}h!=null&&this.push(h),this.push(null),c&&c()}):(this.push(null),c&&c())}function l(){this._final!==o&&o.call(this)}return a.prototype._final=o,a.prototype._transform=function(c,d,h){throw new u("_transform()")},a.prototype._write=function(c,d,h){const f=this._readableState,p=this._writableState,y=f.length;this._transform(c,d,(b,m)=>{if(b){h(b);return}m!=null&&this.push(m),p.ended||y===f.length||f.length{Ne=!0});const ge=r(ie,{readable:ae,writable:Oe},de=>{Ne=!de});return{destroy:de=>{Ne||(Ne=!0,o.destroyer(ie,de||new p("pipe")))},cleanup:ge}}function q(ie){return m(ie[ie.length-1],"streams[stream.length - 1]"),ie.pop()}function Q(ie){if(v(ie))return ie;if(w(ie))return Z(ie);throw new d("val",["Readable","Iterable","AsyncIterable"],ie)}async function*Z(ie){j||(j=Ub()),yield*j.prototype[s].call(ie)}async function K(ie,ae,Oe,{end:Ne}){let ge,de=null;const oe=R=>{if(R&&(ge=R),de){const T=de;de=null,T()}},$=()=>new u((R,T)=>{ge?T(ge):de=()=>{ge?T(ge):R()}});ae.on("drain",oe);const N=r(ae,{readable:!1},oe);try{ae.writableNeedDrain&&await $();for await(const R of ie)ae.write(R)||await $();Ne&&(ae.end(),await $()),Oe()}catch(R){Oe(ge!==R?c(ge,R):R)}finally{N(),ae.off("drain",oe)}}async function fe(ie,ae,Oe,{end:Ne}){A(ae)&&(ae=ae.writable);const ge=ae.getWriter();try{for await(const de of ie)await ge.ready,ge.write(de).catch(()=>{});await ge.ready,Ne&&await ge.close(),Oe()}catch(de){try{await ge.abort(de),Oe(de)}catch(oe){Oe(oe)}}}function X(...ie){return he(ie,a(q(ie)))}function he(ie,ae,Oe){if(ie.length===1&&e(ie[0])&&(ie=ie[0]),ie.length<2)throw new f("streams");const Ne=new O,ge=Ne.signal,de=Oe==null?void 0:Oe.signal,oe=[];g(de,"options.signal");function $(){V(new b)}U=U||Pn().addAbortListener;let N;de&&(N=U(de,$));let R,T;const x=[];let B=0;function k(te){V(te,--B===0)}function V(te,ce){var Ae;if(te&&(!R||R.code==="ERR_STREAM_PREMATURE_CLOSE")&&(R=te),!(!R&&!ce)){for(;x.length;)x.shift()(R);(Ae=N)===null||Ae===void 0||Ae[n](),Ne.abort(),ce&&(R||oe.forEach(Ie=>Ie()),t.nextTick(ae,R,T))}}let J;for(let te=0;te0,Ee=Ae||(Oe==null?void 0:Oe.end)!==!1,qe=te===ie.length-1;if(S(ce)){let G=function(F){F&&F.name!=="AbortError"&&F.code!=="ERR_STREAM_PREMATURE_CLOSE"&&k(F)};if(Ee){const{destroy:F,cleanup:H}=M(ce,Ae,Ie);x.push(F),_(ce)&&qe&&oe.push(H)}ce.on("error",G),_(ce)&&qe&&oe.push(()=>{ce.removeListener("error",G)})}if(te===0)if(typeof ce=="function"){if(J=ce({signal:ge}),!v(J))throw new h("Iterable, AsyncIterable or Stream","source",J)}else v(ce)||w(ce)||A(ce)?J=ce:J=l.from(ce);else if(typeof ce=="function"){if(A(J)){var z;J=Q((z=J)===null||z===void 0?void 0:z.readable)}else J=Q(J);if(J=ce(J,{signal:ge}),Ae){if(!v(J,!0))throw new h("AsyncIterable",`transform[${te-1}]`,J)}else{var Y;P||(P=gq());const G=new P({objectMode:!0}),F=(Y=J)===null||Y===void 0?void 0:Y.then;if(typeof F=="function")B++,F.call(J,be=>{T=be,be!=null&&G.write(be),Ee&&G.end(),t.nextTick(k)},be=>{G.destroy(be),t.nextTick(k,be)});else if(v(J,!0))B++,K(J,G,k,{end:Ee});else if(L(J)||A(J)){const be=J.readable||J;B++,K(be,G,k,{end:Ee})}else throw new h("AsyncIterable or Promise","destination",J);J=G;const{destroy:H,cleanup:re}=M(J,!1,!0);x.push(H),qe&&oe.push(re)}}else if(S(ce)){if(w(J)){B+=2;const G=xe(J,ce,k,{end:Ee});_(ce)&&qe&&oe.push(G)}else if(A(J)||L(J)){const G=J.readable||J;B++,K(G,ce,k,{end:Ee})}else if(v(J))B++,K(J,ce,k,{end:Ee});else throw new d("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],J);J=ce}else if(D(ce)){if(w(J))B++,fe(Q(J),ce,k,{end:Ee});else if(L(J)||v(J))B++,fe(J,ce,k,{end:Ee});else if(A(J))B++,fe(J.readable,ce,k,{end:Ee});else throw new d("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],J);J=ce}else J=l.from(ce)}return(ge!=null&&ge.aborted||de!=null&&de.aborted)&&t.nextTick($),J}function xe(ie,ae,Oe,{end:Ne}){let ge=!1;if(ae.on("close",()=>{ge||Oe(new y)}),ie.pipe(ae,{end:!1}),Ne){let de=function(){ge=!0,ae.end()};E(ie)?t.nextTick(de):ie.once("end",de)}else Oe();return r(ie,{readable:!0,writable:!1},de=>{const oe=ie._readableState;de&&de.code==="ERR_STREAM_PREMATURE_CLOSE"&&oe&&oe.ended&&!oe.errored&&!oe.errorEmitted?ie.once("end",Oe).once("error",Oe):Oe(de)}),r(ae,{readable:!1,writable:!0},Oe)}return T_={pipelineImpl:he,pipeline:X},T_}var A_,fI;function mq(){if(fI)return A_;fI=1;const{pipeline:t}=qT(),e=va(),{destroyer:u}=iu(),{isNodeStream:s,isReadable:n,isWritable:r,isWebStream:a,isTransformStream:o,isWritableStream:l,isReadableStream:c}=Ta(),{AbortError:d,codes:{ERR_INVALID_ARG_VALUE:h,ERR_MISSING_ARGS:f}}=Un(),p=Za();return A_=function(...b){if(b.length===0)throw new f("streams");if(b.length===1)return e.from(b[0]);const m=[...b];if(typeof b[0]=="function"&&(b[0]=e.from(b[0])),typeof b[b.length-1]=="function"){const P=b.length-1;b[P]=e.from(b[P])}for(let P=0;P0&&!(r(b[P])||l(b[P])||o(b[P])))throw new h(`streams[${P}]`,m[P],"must be writable")}let g,v,_,w,S;function A(P){const j=w;w=null,j?j(P):P?S.destroy(P):!O&&!E&&S.destroy()}const D=b[0],L=t(b,A),E=!!(r(D)||l(D)||o(D)),O=!!(n(L)||c(L)||o(L));if(S=new e({writableObjectMode:!!(D!=null&&D.writableObjectMode),readableObjectMode:!!(L!=null&&L.readableObjectMode),writable:E,readable:O}),E){if(s(D))S._write=function(j,U,M){D.write(j,U)?M():g=M},S._final=function(j){D.end(),v=j},D.on("drain",function(){if(g){const j=g;g=null,j()}});else if(a(D)){const U=(o(D)?D.writable:D).getWriter();S._write=async function(M,q,Q){try{await U.ready,U.write(M).catch(()=>{}),Q()}catch(Z){Q(Z)}},S._final=async function(M){try{await U.ready,U.close().catch(()=>{}),v=M}catch(q){M(q)}}}const P=o(L)?L.readable:L;p(P,()=>{if(v){const j=v;v=null,j()}})}if(O){if(s(L))L.on("readable",function(){if(_){const P=_;_=null,P()}}),L.on("end",function(){S.push(null)}),S._read=function(){for(;;){const P=L.read();if(P===null){_=S._read;return}if(!S.push(P))return}};else if(a(L)){const j=(o(L)?L.readable:L).getReader();S._read=async function(){for(;;)try{const{value:U,done:M}=await j.read();if(!S.push(U))return;if(M){S.push(null);return}}catch{return}}}}return S._destroy=function(P,j){!P&&w!==null&&(P=new d),_=null,g=null,v=null,w===null?j(P):(w=j,s(L)&&u(L,P))},S},A_}var hI;function tG(){if(hI)return s1;hI=1;const t=globalThis.AbortController||Uo().AbortController,{codes:{ERR_INVALID_ARG_VALUE:e,ERR_INVALID_ARG_TYPE:u,ERR_MISSING_ARGS:s,ERR_OUT_OF_RANGE:n},AbortError:r}=Un(),{validateAbortSignal:a,validateInteger:o,validateObject:l}=Ey(),c=Rr().Symbol("kWeak"),d=Rr().Symbol("kResistStopPropagation"),{finished:h}=Za(),f=mq(),{addAbortSignalNoValidate:p}=qb(),{isWritable:y,isNodeStream:b}=Ta(),{deprecate:m}=Pn(),{ArrayPrototypePush:g,Boolean:v,MathFloor:_,Number:w,NumberIsNaN:S,Promise:A,PromiseReject:D,PromiseResolve:L,PromisePrototypeThen:E,Symbol:O}=Rr(),P=O("kEmpty"),j=O("kEof");function U(de,oe){if(oe!=null&&l(oe,"options"),(oe==null?void 0:oe.signal)!=null&&a(oe.signal,"options.signal"),b(de)&&!y(de))throw new e("stream",de,"must be writable");const $=f(this,de);return oe!=null&&oe.signal&&p(oe.signal,$),$}function M(de,oe){if(typeof de!="function")throw new u("fn",["Function","AsyncFunction"],de);oe!=null&&l(oe,"options"),(oe==null?void 0:oe.signal)!=null&&a(oe.signal,"options.signal");let $=1;(oe==null?void 0:oe.concurrency)!=null&&($=_(oe.concurrency));let N=$-1;return(oe==null?void 0:oe.highWaterMark)!=null&&(N=_(oe.highWaterMark)),o($,"options.concurrency",1),o(N,"options.highWaterMark",0),N+=$,(async function*(){const T=Pn().AbortSignalAny([oe==null?void 0:oe.signal].filter(v)),x=this,B=[],k={signal:T};let V,J,z=!1,Y=0;function te(){z=!0,ce()}function ce(){Y-=1,Ae()}function Ae(){J&&!z&&Y<$&&B.length=N||Y>=$)&&await new A(qe=>{J=qe})}B.push(j)}catch(Ee){const qe=D(Ee);E(qe,ce,te),B.push(qe)}finally{z=!0,V&&(V(),V=null)}}Ie();try{for(;;){for(;B.length>0;){const Ee=await B[0];if(Ee===j)return;if(T.aborted)throw new r;Ee!==P&&(yield Ee),B.shift(),Ae()}await new A(Ee=>{V=Ee})}}finally{z=!0,J&&(J(),J=null)}}).call(this)}function q(de=void 0){return de!=null&&l(de,"options"),(de==null?void 0:de.signal)!=null&&a(de.signal,"options.signal"),(async function*(){let $=0;for await(const R of this){var N;if(de!=null&&(N=de.signal)!==null&&N!==void 0&&N.aborted)throw new r({cause:de.signal.reason});yield[$++,R]}}).call(this)}async function Q(de,oe=void 0){for await(const $ of X.call(this,de,oe))return!0;return!1}async function Z(de,oe=void 0){if(typeof de!="function")throw new u("fn",["Function","AsyncFunction"],de);return!await Q.call(this,async(...$)=>!await de(...$),oe)}async function K(de,oe){for await(const $ of X.call(this,de,oe))return $}async function fe(de,oe){if(typeof de!="function")throw new u("fn",["Function","AsyncFunction"],de);async function $(N,R){return await de(N,R),P}for await(const N of M.call(this,$,oe));}function X(de,oe){if(typeof de!="function")throw new u("fn",["Function","AsyncFunction"],de);async function $(N,R){return await de(N,R)?N:P}return M.call(this,$,oe)}class he extends s{constructor(){super("reduce"),this.message="Reduce of an empty stream requires an initial value"}}async function xe(de,oe,$){var N;if(typeof de!="function")throw new u("reducer",["Function","AsyncFunction"],de);$!=null&&l($,"options"),($==null?void 0:$.signal)!=null&&a($.signal,"options.signal");let R=arguments.length>1;if($!=null&&(N=$.signal)!==null&&N!==void 0&&N.aborted){const V=new r(void 0,{cause:$.signal.reason});throw this.once("error",()=>{}),await h(this.destroy(V)),V}const T=new t,x=T.signal;if($!=null&&$.signal){const V={once:!0,[c]:this,[d]:!0};$.signal.addEventListener("abort",()=>T.abort(),V)}let B=!1;try{for await(const V of this){var k;if(B=!0,$!=null&&(k=$.signal)!==null&&k!==void 0&&k.aborted)throw new r;R?oe=await de(oe,V,{signal:x}):(oe=V,R=!0)}if(!B&&!R)throw new he}finally{T.abort()}return oe}async function ie(de){de!=null&&l(de,"options"),(de==null?void 0:de.signal)!=null&&a(de.signal,"options.signal");const oe=[];for await(const N of this){var $;if(de!=null&&($=de.signal)!==null&&$!==void 0&&$.aborted)throw new r(void 0,{cause:de.signal.reason});g(oe,N)}return oe}function ae(de,oe){const $=M.call(this,de,oe);return(async function*(){for await(const R of $)yield*R}).call(this)}function Oe(de){if(de=w(de),S(de))return 0;if(de<0)throw new n("number",">= 0",de);return de}function Ne(de,oe=void 0){return oe!=null&&l(oe,"options"),(oe==null?void 0:oe.signal)!=null&&a(oe.signal,"options.signal"),de=Oe(de),(async function*(){var N;if(oe!=null&&(N=oe.signal)!==null&&N!==void 0&&N.aborted)throw new r;for await(const T of this){var R;if(oe!=null&&(R=oe.signal)!==null&&R!==void 0&&R.aborted)throw new r;de--<=0&&(yield T)}}).call(this)}function ge(de,oe=void 0){return oe!=null&&l(oe,"options"),(oe==null?void 0:oe.signal)!=null&&a(oe.signal,"options.signal"),de=Oe(de),(async function*(){var N;if(oe!=null&&(N=oe.signal)!==null&&N!==void 0&&N.aborted)throw new r;for await(const T of this){var R;if(oe!=null&&(R=oe.signal)!==null&&R!==void 0&&R.aborted)throw new r;if(de-- >0&&(yield T),de<=0)return}}).call(this)}return s1.streamReturningOperators={asIndexedPairs:m(q,"readable.asIndexedPairs will be removed in a future version."),drop:Ne,filter:X,flatMap:ae,map:M,take:ge,compose:U},s1.promiseReturningOperators={every:Z,forEach:fe,reduce:xe,toArray:ie,some:Q,find:K},s1}var E_,pI;function _q(){if(pI)return E_;pI=1;const{ArrayPrototypePop:t,Promise:e}=Rr(),{isIterable:u,isNodeStream:s,isWebStream:n}=Ta(),{pipelineImpl:r}=qT(),{finished:a}=Za();vq();function o(...l){return new e((c,d)=>{let h,f;const p=l[l.length-1];if(p&&typeof p=="object"&&!s(p)&&!u(p)&&!n(p)){const y=t(l);h=y.signal,f=y.end}r(l,(y,b)=>{y?d(y):c(b)},{signal:h,end:f})})}return E_={finished:a,pipeline:o},E_}var yI;function vq(){if(yI)return n_.exports;yI=1;const{Buffer:t}=Wi(),{ObjectDefineProperty:e,ObjectKeys:u,ReflectApply:s}=Rr(),{promisify:{custom:n}}=Pn(),{streamReturningOperators:r,promiseReturningOperators:a}=tG(),{codes:{ERR_ILLEGAL_CONSTRUCTOR:o}}=Un(),l=mq(),{setDefaultHighWaterMark:c,getDefaultHighWaterMark:d}=Bb(),{pipeline:h}=qT(),{destroyer:f}=iu(),p=Za(),y=_q(),b=Ta(),m=n_.exports=MT().Stream;m.isDestroyed=b.isDestroyed,m.isDisturbed=b.isDisturbed,m.isErrored=b.isErrored,m.isReadable=b.isReadable,m.isWritable=b.isWritable,m.Readable=Ub();for(const v of u(r)){let w=function(...S){if(new.target)throw o();return m.Readable.from(s(_,this,S))};const _=r[v];e(w,"name",{__proto__:null,value:_.name}),e(w,"length",{__proto__:null,value:_.length}),e(m.Readable.prototype,v,{__proto__:null,value:w,enumerable:!1,configurable:!0,writable:!0})}for(const v of u(a)){let w=function(...S){if(new.target)throw o();return s(_,this,S)};const _=a[v];e(w,"name",{__proto__:null,value:_.name}),e(w,"length",{__proto__:null,value:_.length}),e(m.Readable.prototype,v,{__proto__:null,value:w,enumerable:!1,configurable:!0,writable:!0})}m.Writable=FT(),m.Duplex=va(),m.Transform=bq(),m.PassThrough=gq(),m.pipeline=h;const{addAbortSignal:g}=qb();return m.addAbortSignal=g,m.finished=p,m.destroy=f,m.compose=l,m.setDefaultHighWaterMark=c,m.getDefaultHighWaterMark=d,e(m,"promises",{__proto__:null,configurable:!0,enumerable:!0,get(){return y}}),e(h,n,{__proto__:null,enumerable:!0,get(){return y.pipeline}}),e(p,n,{__proto__:null,enumerable:!0,get(){return y.finished}}),m.Stream=m,m._isUint8Array=function(_){return _ instanceof Uint8Array},m._uint8ArrayToBuffer=function(_){return t.from(_.buffer,_.byteOffset,_.byteLength)},n_.exports}var bI;function Wt(){return bI||(bI=1,function(t){const e=vq(),u=_q(),s=e.Readable.destroy;t.exports=e.Readable,t.exports._uint8ArrayToBuffer=e._uint8ArrayToBuffer,t.exports._isUint8Array=e._isUint8Array,t.exports.isDisturbed=e.isDisturbed,t.exports.isErrored=e.isErrored,t.exports.isReadable=e.isReadable,t.exports.Readable=e.Readable,t.exports.Writable=e.Writable,t.exports.Duplex=e.Duplex,t.exports.Transform=e.Transform,t.exports.PassThrough=e.PassThrough,t.exports.addAbortSignal=e.addAbortSignal,t.exports.finished=e.finished,t.exports.destroy=e.destroy,t.exports.destroy=s,t.exports.pipeline=e.pipeline,t.exports.compose=e.compose,Object.defineProperty(e,"promises",{configurable:!0,enumerable:!0,get(){return u}}),t.exports.Stream=e.Stream,t.exports.default=t.exports}(r_)),r_.exports}var gI;function rG(){if(gI)return Ic;gI=1,Object.defineProperty(Ic,"__esModule",{value:!0}),Ic.ActorQueryResultSerializeJson=void 0;const t=Gi(),e=Nt(),u=er(),s=Wt();let n=class extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(a){super(a)}async testHandleChecked(a,o){if(!["bindings","quads","boolean"].includes(a.type))throw new Error("This actor can only handle bindings or quad streams.");return!0}async runHandle(a,o,l){const c=new s.Readable;if(c._read=()=>{},a.type==="bindings"||a.type==="quads"){let d=a.type==="bindings"?(0,e.wrap)(a.bindingsStream).map(f=>JSON.stringify(Object.fromEntries([...f].map(([p,y])=>[p.value,u.termToString(y)])))):(0,e.wrap)(a.quadStream).map(f=>JSON.stringify(u.quadToStringQuad(f))),h=!0;d=d.map(f=>{const p=`${h?"":","} -${f}`;return h=!1,p}).prepend(["["]).append([` -] -`]),c.wrap(d)}else try{c.push(`${JSON.stringify(await a.execute())} -`),c.push(null)}catch(d){setTimeout(()=>c.emit("error",d))}return{data:c}}};return Ic.ActorQueryResultSerializeJson=n,Ic}var mI;function nG(){return mI||(mI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(rG(),t)}(Zm)),Zm}var O_={},Mc={},_I;function iG(){if(_I)return Mc;_I=1,Object.defineProperty(Mc,"__esModule",{value:!0}),Mc.ActorQueryResultSerializeSimple=void 0;const t=Gi(),e=Nt(),u=er(),s=Wt();let n=class vo extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(a){super(a)}async testHandleChecked(a,o){if(!["bindings","quads","boolean","void"].includes(a.type))throw new Error("This actor can only handle bindings streams, quad streams, booleans, or updates.");return!0}static termToString(a){return a.termType==="Quad"?(0,u.termToString)(a):a.value}async runHandle(a,o,l){const c=new s.Readable;return a.type==="bindings"?c.wrap(a.bindingsStream.map(d=>`${[...d].map(([h,f])=>`?${h.value}: ${vo.termToString(f)}`).join(` -`)} - -`)):a.type==="quads"?c.wrap(a.quadStream.map(d=>`subject: ${vo.termToString(d.subject)} -predicate: ${vo.termToString(d.predicate)} -object: ${vo.termToString(d.object)} -graph: ${vo.termToString(d.graph)} - -`)):c.wrap((0,e.wrap)(a.type==="boolean"?a.execute().then(d=>[`${d} -`]):a.execute().then(()=>[`ok -`]))),{data:c}}};return Mc.ActorQueryResultSerializeSimple=n,Mc}var vI;function aG(){return vI||(vI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(iG(),t)}(O_)),O_}var R_={},Fc={},wI;function sG(){if(wI)return Fc;wI=1,Object.defineProperty(Fc,"__esModule",{value:!0}),Fc.ActorQueryResultSerializeSparqlCsv=void 0;const t=Gi(),e=Wt();let u=class T0 extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(n){super(n)}static bindingToCsvBindings(n){if(!n)return"";let r=n.value;if(n.termType==="Literal")r=`${r}`;else if(n.termType==="BlankNode")r=`_:${r}`;else if(n.termType==="Quad"){let a=T0.bindingToCsvBindings(n.object);n.object.termType==="Literal"&&(a=`"${a.replaceAll('"','""')}"`),r=`<< ${T0.bindingToCsvBindings(n.subject)} ${T0.bindingToCsvBindings(n.predicate)} ${a} >>`}else r=`<${r}>`;return/[",\n\r]/u.test(r)&&(r=`"${r.replaceAll('"','""')}"`),r}async testHandleChecked(n,r){if(n.type!=="bindings")throw new Error("This actor can only handle bindings streams.");return!0}async runHandle(n,r,a){const o=n,l=new e.Readable,c=await o.metadata();return l.push(`${c.variables.map(d=>d.value).join(",")}\r -`),l.wrap(o.bindingsStream.map(d=>`${c.variables.map(h=>T0.bindingToCsvBindings(d.get(h))).join(",")}\r -`)),{data:l}}};return Fc.ActorQueryResultSerializeSparqlCsv=u,Fc}var SI;function oG(){return SI||(SI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(sG(),t)}(R_)),R_}var x_={},qc={},I_={},tn={},TI;function uG(){if(TI)return tn;TI=1,Object.defineProperty(tn,"__esModule",{value:!0}),tn.stringQuadToQuad=tn.quadToStringQuad=tn.stringToTerm=tn.getLiteralLanguage=tn.getLiteralType=tn.getLiteralValue=tn.termToString=void 0;const t=Et(),e=new t.DataFactory;function u(y){if(y)switch(y.termType){case"NamedNode":return`<${c(y.value)}>`;case"BlankNode":return`_:${y.value}`;case"Literal":{const b=y;return`"${d(b.value)}"${b.datatype&&b.datatype.value!=="http://www.w3.org/2001/XMLSchema#string"&&b.datatype.value!=="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString"?`^^<${b.datatype.value}>`:""}${b.language?`@${b.language}`:""}`}case"Quad":return`<<${u(y.subject)} ${u(y.predicate)} ${u(y.object)}${y.graph.termType==="DefaultGraph"?"":` ${u(y.graph)}`}>>`;case"Variable":return`?${y.value}`;case"DefaultGraph":return y.value}}tn.termToString=u;function s(y){const b=/^"([^]*)"((\^\^.*)|(@.*))?$/u.exec(y);if(!b)throw new Error(`${y} is not a literal`);return b[1].replace(/\\"/ug,'"')}tn.getLiteralValue=s;function n(y){const b=/^"[^]*"(?:\^\^<([^"]+)>|(@)[^@"]+)?$/u.exec(y);if(!b)throw new Error(`${y} is not a literal`);return b[1]||(b[2]?"http://www.w3.org/1999/02/22-rdf-syntax-ns#langString":"http://www.w3.org/2001/XMLSchema#string")}tn.getLiteralType=n;function r(y){const b=/^"[^]*"(?:@([^@"]+)|\^\^[^"]+)?$/u.exec(y);if(!b)throw new Error(`${y} is not a literal`);return b[1]?b[1].toLowerCase():""}tn.getLiteralLanguage=r;function a(y,b){if(b=b||e,!y||y.length===0)return b.defaultGraph();switch(y[0]){case"_":return b.blankNode(y.slice(2));case"?":if(!b.variable)throw new Error("Missing 'variable()' method on the given DataFactory");return b.variable(y.slice(1));case'"':{const m=r(y),g=b.namedNode(n(y));return b.literal(s(y),m||g)}case"<":default:if(y.startsWith("<<")&&y.endsWith(">>")){const m=y.slice(2,-2),g=[];let v=0,_=0;for(let w=0;w"){if(v===0)throw new Error(`Found closing tag without opening tag in ${y}`);v--}S===" "&&v===0&&(g.push(m.slice(_,w)),_=w+1)}if(v!==0)throw new Error(`Found opening tag without closing tag in ${y}`);if(g.push(m.slice(_,m.length)),g.length!==3&&g.length!==4)throw new Error(`Nested quad syntax error ${y}`);return b.quad(a(g[0]),a(g[1]),a(g[2]),g[3]?a(g[3]):void 0)}if(!y.startsWith("<")||!y.endsWith(">"))throw new Error(`Detected invalid iri for named node (must be wrapped in <>): ${y}`);return b.namedNode(y.slice(1,-1))}}tn.stringToTerm=a;function o(y){return{subject:u(y.subject),predicate:u(y.predicate),object:u(y.object),graph:u(y.graph)}}tn.quadToStringQuad=o;function l(y,b){return b=b||e,b.quad(a(y.subject,b),a(y.predicate,b),a(y.object,b),a(y.graph,b))}tn.stringQuadToQuad=l;function c(y){return y.replace(h,p)}function d(y){return h.test(y)&&(y=y.replace(h,p)),y}const h=/["\\\t\n\r\b\f\u0000-\u0019]|[\uD800-\uDBFF][\uDC00-\uDFFF]/g,f=new Map([["\\","\\\\"],['"','\\"'],[" ","\\t"],[` -`,"\\n"],["\r","\\r"],["\b","\\b"],["\f","\\f"]]);function p(y){const b=f.get(y);if(!b){if(y.length===1){const g=y.charCodeAt(0).toString(16);return`${"\\u0000".slice(0,-g.length)}${g}`}const m=((y.charCodeAt(0)-55296)*1024+y.charCodeAt(1)+9216).toString(16);return`${"\\U00000000".slice(0,-m.length)}${m}`}return b}return tn}var AI;function Oy(){return AI||(AI=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.termToString=t.stringToTerm=t.stringQuadToQuad=t.quadToStringQuad=t.getLiteralValue=t.getLiteralType=t.getLiteralLanguage=void 0;const e=uG();Object.defineProperty(t,"getLiteralLanguage",{enumerable:!0,get:function(){return e.getLiteralLanguage}}),Object.defineProperty(t,"getLiteralType",{enumerable:!0,get:function(){return e.getLiteralType}}),Object.defineProperty(t,"getLiteralValue",{enumerable:!0,get:function(){return e.getLiteralValue}}),Object.defineProperty(t,"quadToStringQuad",{enumerable:!0,get:function(){return e.quadToStringQuad}}),Object.defineProperty(t,"stringQuadToQuad",{enumerable:!0,get:function(){return e.stringQuadToQuad}}),Object.defineProperty(t,"stringToTerm",{enumerable:!0,get:function(){return e.stringToTerm}}),Object.defineProperty(t,"termToString",{enumerable:!0,get:function(){return e.termToString}})}(I_)),I_}var EI;function cG(){if(EI)return qc;EI=1,Object.defineProperty(qc,"__esModule",{value:!0}),qc.ActorQueryResultSerializeSparqlTsv=void 0;const t=Gi(),e=Oy(),u=Wt();let s=class wq extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(r){super(r)}static bindingToTsvBindings(r){return r?(0,e.termToString)(r).replaceAll(" ","\\t").replaceAll(` -`,"\\n").replaceAll("\r","\\r"):""}async testHandleChecked(r,a){if(r.type!=="bindings")throw new Error("This actor can only handle bindings streams.");return!0}async runHandle(r,a,o){const l=r,c=new u.Readable,d=await l.metadata();return c.push(`${d.variables.map(h=>h.value).join(" ")} -`),c.wrap(l.bindingsStream.map(h=>`${d.variables.map(f=>wq.bindingToTsvBindings(h.get(f))).join(" ")} -`)),{data:c}}};return qc.ActorQueryResultSerializeSparqlTsv=s,qc}var OI;function lG(){return OI||(OI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(cG(),t)}(x_)),x_}var P_={},Bc={},Uc={},RI;function dG(){if(RI)return Uc;RI=1,Object.defineProperty(Uc,"__esModule",{value:!0}),Uc.XmlSerializer=void 0;let t=class{constructor(){this.stack=[]}open(u,s){const n=`${this.identation()+this.formatTag(u,s,"open")} -`;return this.stack.push(u),n}close(){const u=this.stack.pop();if(u===void 0)throw new Error("There is no tag left to close");return`${this.identation()+this.formatTag(u,{},"close")} -`}serializeNode(u){if(u.children===void 0)return`${this.identation()+this.formatTag(u.name,u.attributes,"self-closing")} -`;if(typeof u.children=="string")return`${this.identation()+this.formatTag(u.name,u.attributes,"open")+this.escape(u.children)+this.formatTag(u.name,{},"close")} -`;const s=[];s.push(`${this.identation()+this.formatTag(u.name,u.attributes,"open")} -`),this.stack.push(u.name);for(const n of u.children)s.push(this.serializeNode(n));return this.stack.pop(),s.push(`${this.identation()+this.formatTag(u.name,{},"close")} -`),s.join("")}identation(){return this.stack.map(u=>" ").join("")}formatTag(u,s,n){return`<${n==="close"?"/":""}${u}${Object.entries(s??{}).map(r=>` ${r[0]}="${this.escape(r[1])}"`)}${n==="self-closing"?"/":""}>`}escape(u){return u.replaceAll(/["&'<>]/gu,s=>{switch(s){case"<":return"<";case">":return">";case"&":return"&";case"'":return"'";case'"':return"""}})}};return Uc.XmlSerializer=t,t.header=` -`,Uc}var xI;function fG(){if(xI)return Bc;xI=1,Object.defineProperty(Bc,"__esModule",{value:!0}),Bc.ActorQueryResultSerializeSparqlXml=void 0;const t=Gi(),e=Nt(),u=Wt(),s=dG();let n=class Sq extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(a){super(a)}static bindingToXmlBindings(a,o){return{name:"binding",attributes:{name:o.value},children:[this.valueToXmlValue(a)]}}static valueToXmlValue(a){let o;switch(a.termType){case"Literal":return a.language?o={"xml:lang":a.language}:a.datatype&&a.datatype.value!=="http://www.w3.org/2001/XMLSchema#string"?o={datatype:a.datatype.value}:o={},{name:"literal",attributes:o,children:a.value};case"BlankNode":return{name:"bnode",children:a.value};case"Quad":return{name:"triple",children:[{name:"subject",children:[this.valueToXmlValue(a.subject)]},{name:"predicate",children:[this.valueToXmlValue(a.predicate)]},{name:"object",children:[this.valueToXmlValue(a.object)]}]};default:return{name:"uri",children:a.value}}}async testHandleChecked(a,o){if(!["bindings","boolean"].includes(a.type))throw new Error("This actor can only handle bindings streams or booleans.");return!0}async runHandle(a,o,l){const c=new u.Readable;c._read=()=>{};const d=new s.XmlSerializer,h=await a.metadata();if(c.push(s.XmlSerializer.header),c.push(d.open("sparql",{xmlns:"http://www.w3.org/2005/sparql-results#"})),c.push(d.serializeNode({name:"head",children:h.variables.map(f=>({name:"variable",attributes:{name:f.value}}))})),a.type==="bindings"){function*f(){yield d.close(),yield d.close()}c.push(d.open("results"));const p=(0,e.wrap)(a.bindingsStream).map(y=>d.serializeNode({name:"result",children:[...y].map(([b,m])=>Sq.bindingToXmlBindings(m,b))})).append((0,e.wrap)(f()));c.wrap(p)}else try{const f=await a.execute();c.push(d.serializeNode({name:"boolean",children:f.toString()})),c.push(d.close()),setTimeout(()=>c.push(null))}catch(f){setTimeout(()=>c.emit("error",f))}return{data:c}}};return Bc.ActorQueryResultSerializeSparqlXml=n,Bc}var II;function hG(){return II||(II=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(fG(),t)}(P_)),P_}var D_={},Hc={},PI;function pG(){if(PI)return Hc;PI=1,Object.defineProperty(Hc,"__esModule",{value:!0}),Hc.ActorQueryResultSerializeTable=void 0;const t=Gi(),e=Et(),u=er(),s=un(),n=Wt(),r=new e.DataFactory,a=s.QUAD_TERM_NAMES.map(l=>r.variable(l));let o=class r3 extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(c){super(c),this.padding=r3.repeat(" ",this.columnWidth)}static repeat(c,d){return c.repeat(d)}async testHandleChecked(c,d){if(!["bindings","quads"].includes(c.type))throw new Error("This actor can only handle bindings or quad streams.");return!0}termToString(c){return c.termType==="Quad"?(0,u.termToString)(c):c.value}pad(c){return c.length<=this.columnWidth?c+this.padding.slice(c.length):`${c.slice(0,this.columnWidth-1)}…`}pushHeader(c,d){const h=d.map(f=>this.pad(f.value)).join(" ");c.push(`${h} -${r3.repeat("-",h.length)} -`)}createRow(c,d){return`${c.map(h=>d.has(h)?this.termToString(d.get(h)):"").map(h=>this.pad(h)).join(" ")} -`}async runHandle(c,d,h){const f=new n.Readable;let p;if(c.type==="bindings"){p=c.bindingsStream.map(b=>this.createRow(y,b));const y=(await c.metadata()).variables;this.pushHeader(f,y)}else p=c.quadStream.map(y=>`${(0,s.getTerms)(y).map(b=>this.pad(this.termToString(b))).join(" ")} -`),this.pushHeader(f,a);return f.wrap(p),{data:f}}};return Hc.ActorQueryResultSerializeTable=o,Hc}var DI;function yG(){return DI||(DI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(pG(),t)}(D_)),D_}var N_={},$c={},C_={},Qc={},j_={},L_={},Vc={},kc={},NI;function Ho(){if(NI)return kc;NI=1,Object.defineProperty(kc,"__esModule",{value:!0}),kc.Translator=void 0;let t=class{constructor(){this.supportedRdfDatatypes=[],this.fromRdfHandlers={},this.toRdfHandlers={}}static incorrectRdfDataType(u){throw new Error(`Invalid RDF ${u.datatype.value} value: '${u.value}'`)}registerHandler(u,s,n){for(const r of s)this.supportedRdfDatatypes.push(r),this.fromRdfHandlers[r.value]=u;for(const r of n){let a=this.toRdfHandlers[r];a||(this.toRdfHandlers[r]=a=[]),a.push(u)}}fromRdf(u,s){const n=this.fromRdfHandlers[u.datatype.value];return n?n.fromRdf(u,s):u.value}toRdf(u,s){const n=this.toRdfHandlers[typeof u];if(n)for(const r of n){const a=r.toRdf(u,s);if(a)return a}throw new Error(`Invalid JavaScript value: '${u}'`)}getSupportedRdfDatatypes(){return this.supportedRdfDatatypes}getSupportedJavaScriptPrimitives(){return Object.keys(this.toRdfHandlers)}};return kc.Translator=t,kc}var CI;function bG(){if(CI)return Vc;CI=1,Object.defineProperty(Vc,"__esModule",{value:!0}),Vc.TypeHandlerBoolean=void 0;const t=Ho();let e=class Tq{fromRdf(s,n){switch(s.value){case"true":return!0;case"false":return!1;case"1":return!0;case"0":return!1}return n&&t.Translator.incorrectRdfDataType(s),!1}toRdf(s,{datatype:n,dataFactory:r}){return r.literal(s?"true":"false",n||r.namedNode(Tq.TYPE))}};return e.TYPE="http://www.w3.org/2001/XMLSchema#boolean",Vc.TypeHandlerBoolean=e,Vc}var zc={},jI;function gG(){if(jI)return zc;jI=1,Object.defineProperty(zc,"__esModule",{value:!0}),zc.TypeHandlerDate=void 0;const t=Ho();let e=class n3{fromRdf(s,n){switch(n&&!s.value.match(n3.VALIDATORS[s.datatype.value.substr(33,s.datatype.value.length)])&&t.Translator.incorrectRdfDataType(s),s.datatype.value){case"http://www.w3.org/2001/XMLSchema#gDay":return new Date(0,0,parseInt(s.value,10));case"http://www.w3.org/2001/XMLSchema#gMonthDay":const r=s.value.split("-");return new Date(0,parseInt(r[0],10)-1,parseInt(r[1],10));case"http://www.w3.org/2001/XMLSchema#gYear":return new Date(s.value+"-01-01");case"http://www.w3.org/2001/XMLSchema#gYearMonth":return new Date(s.value+"-01");default:return new Date(s.value)}}toRdf(s,{datatype:n,dataFactory:r}){if(n=n||r.namedNode(n3.TYPES[0]),!(s instanceof Date))return null;const a=s;let o;switch(n.value){case"http://www.w3.org/2001/XMLSchema#gDay":o=String(a.getUTCDate());break;case"http://www.w3.org/2001/XMLSchema#gMonthDay":o=a.getUTCMonth()+1+"-"+a.getUTCDate();break;case"http://www.w3.org/2001/XMLSchema#gYear":o=String(a.getUTCFullYear());break;case"http://www.w3.org/2001/XMLSchema#gYearMonth":o=a.getUTCFullYear()+"-"+(a.getUTCMonth()+1);break;case"http://www.w3.org/2001/XMLSchema#date":o=a.toISOString().replace(/T.*$/,"");break;default:o=a.toISOString()}return r.literal(o,n)}};return e.TYPES=["http://www.w3.org/2001/XMLSchema#dateTime","http://www.w3.org/2001/XMLSchema#date","http://www.w3.org/2001/XMLSchema#gDay","http://www.w3.org/2001/XMLSchema#gMonthDay","http://www.w3.org/2001/XMLSchema#gYear","http://www.w3.org/2001/XMLSchema#gYearMonth"],e.VALIDATORS={date:/^[0-9]+-[0-9][0-9]-[0-9][0-9]Z?$/,dateTime:/^[0-9]+-[0-9][0-9]-[0-9][0-9]T[0-9][0-9]:[0-9][0-9]:[0-9][0-9](\.[0-9][0-9][0-9])?((Z?)|([\+-][0-9][0-9]:[0-9][0-9]))$/,gDay:/^[0-9]+$/,gMonthDay:/^[0-9]+-[0-9][0-9]$/,gYear:/^[0-9]+$/,gYearMonth:/^[0-9]+-[0-9][0-9]$/},zc.TypeHandlerDate=e,zc}var Gc={},LI;function mG(){if(LI)return Gc;LI=1,Object.defineProperty(Gc,"__esModule",{value:!0}),Gc.TypeHandlerNumberDouble=void 0;const t=Ho();let e=class Aq{fromRdf(s,n){const r=parseFloat(s.value);return n&&isNaN(r)&&t.Translator.incorrectRdfDataType(s),r}toRdf(s,{datatype:n,dataFactory:r}){return n=n||r.namedNode(Aq.TYPES[0]),isNaN(s)?r.literal("NaN",n):isFinite(s)?s%1===0?null:r.literal(s.toExponential(15).replace(/(\d)0*e\+?/,"$1E"),n):r.literal(s>0?"INF":"-INF",n)}};return e.TYPES=["http://www.w3.org/2001/XMLSchema#double","http://www.w3.org/2001/XMLSchema#decimal","http://www.w3.org/2001/XMLSchema#float"],Gc.TypeHandlerNumberDouble=e,Gc}var Wc={},MI;function _G(){if(MI)return Wc;MI=1,Object.defineProperty(Wc,"__esModule",{value:!0}),Wc.TypeHandlerNumberInteger=void 0;const t=Ho();let e=class A0{fromRdf(s,n){const r=parseInt(s.value,10);return n&&(isNaN(r)||s.value.indexOf(".")>=0)&&t.Translator.incorrectRdfDataType(s),r}toRdf(s,{datatype:n,dataFactory:r}){return r.literal(String(s),n||(s<=A0.MAX_INT&&s>=A0.MIN_INT?r.namedNode(A0.TYPES[0]):r.namedNode(A0.TYPES[1])))}};return e.TYPES=["http://www.w3.org/2001/XMLSchema#integer","http://www.w3.org/2001/XMLSchema#long","http://www.w3.org/2001/XMLSchema#int","http://www.w3.org/2001/XMLSchema#byte","http://www.w3.org/2001/XMLSchema#short","http://www.w3.org/2001/XMLSchema#negativeInteger","http://www.w3.org/2001/XMLSchema#nonNegativeInteger","http://www.w3.org/2001/XMLSchema#nonPositiveInteger","http://www.w3.org/2001/XMLSchema#positiveInteger","http://www.w3.org/2001/XMLSchema#unsignedByte","http://www.w3.org/2001/XMLSchema#unsignedInt","http://www.w3.org/2001/XMLSchema#unsignedLong","http://www.w3.org/2001/XMLSchema#unsignedShort"],e.MAX_INT=2147483647,e.MIN_INT=-2147483648,Wc.TypeHandlerNumberInteger=e,Wc}var Jc={},FI;function vG(){if(FI)return Jc;FI=1,Object.defineProperty(Jc,"__esModule",{value:!0}),Jc.TypeHandlerString=void 0;let t=class{fromRdf(u){return u.value}toRdf(u,{datatype:s,dataFactory:n}){return n.literal(u,s)}};return t.TYPES=["http://www.w3.org/2001/XMLSchema#string","http://www.w3.org/2001/XMLSchema#normalizedString","http://www.w3.org/2001/XMLSchema#anyURI","http://www.w3.org/2001/XMLSchema#base64Binary","http://www.w3.org/2001/XMLSchema#language","http://www.w3.org/2001/XMLSchema#Name","http://www.w3.org/2001/XMLSchema#NCName","http://www.w3.org/2001/XMLSchema#NMTOKEN","http://www.w3.org/2001/XMLSchema#token","http://www.w3.org/2001/XMLSchema#hexBinary","http://www.w3.org/1999/02/22-rdf-syntax-ns#langString","http://www.w3.org/2001/XMLSchema#time","http://www.w3.org/2001/XMLSchema#duration"],Jc.TypeHandlerString=t,Jc}var qI;function BI(){return qI||(qI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(bG(),t),u(gG(),t),u(mG(),t),u(_G(),t),u(vG(),t)}(L_)),L_}var M_={},UI;function wG(){return UI||(UI=1,Object.defineProperty(M_,"__esModule",{value:!0})),M_}var HI;function SG(){return HI||(HI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(p,y,b,m){m===void 0&&(m=b);var g=Object.getOwnPropertyDescriptor(y,b);(!g||("get"in g?!y.__esModule:g.writable||g.configurable))&&(g={enumerable:!0,get:function(){return y[b]}}),Object.defineProperty(p,m,g)}:function(p,y,b,m){m===void 0&&(m=b),p[m]=y[b]}),u=I&&I.__exportStar||function(p,y){for(var b in p)b!=="default"&&!Object.prototype.hasOwnProperty.call(y,b)&&e(y,p,b)};Object.defineProperty(t,"__esModule",{value:!0}),t.getSupportedJavaScriptPrimitives=t.getSupportedRdfDatatypes=t.getTermRaw=t.toRdf=t.fromRdf=void 0;const s=Et(),n=BI(),r=Ho();u(BI(),t),u(wG(),t),u(Ho(),t);const a=new s.DataFactory,o=new r.Translator;o.registerHandler(new n.TypeHandlerString,n.TypeHandlerString.TYPES.map(p=>a.namedNode(p)),["string"]),o.registerHandler(new n.TypeHandlerBoolean,[n.TypeHandlerBoolean.TYPE].map(p=>a.namedNode(p)),["boolean"]),o.registerHandler(new n.TypeHandlerNumberDouble,n.TypeHandlerNumberDouble.TYPES.map(p=>a.namedNode(p)),["number"]),o.registerHandler(new n.TypeHandlerNumberInteger,n.TypeHandlerNumberInteger.TYPES.map(p=>a.namedNode(p)),["number"]),o.registerHandler(new n.TypeHandlerDate,n.TypeHandlerDate.TYPES.map(p=>a.namedNode(p)),["object"]);function l(p,y){return o.fromRdf(p,y)}t.fromRdf=l;function c(p,y){return y&&"namedNode"in y&&(y={dataFactory:y}),y=y||{},y&&!y.dataFactory&&(y.dataFactory=a),o.toRdf(p,y)}t.toRdf=c;function d(p,y){return p.termType==="Literal"?l(p,y):p.value}t.getTermRaw=d;function h(){return o.getSupportedRdfDatatypes()}t.getSupportedRdfDatatypes=h;function f(){return o.getSupportedJavaScriptPrimitives()}t.getSupportedJavaScriptPrimitives=f}(j_)),j_}var F_={},Xc={},q_,$I;function Eq(){if($I)return q_;$I=1;var{Buffer:t}=Wi(),e={},u=e.LEFT_BRACE=1,s=e.RIGHT_BRACE=2,n=e.LEFT_BRACKET=3,r=e.RIGHT_BRACKET=4,a=e.COLON=5,o=e.COMMA=6,l=e.TRUE=7,c=e.FALSE=8,d=e.NULL=9,h=e.STRING=10,f=e.NUMBER=11,p=e.START=17,y=e.STOP=18,b=e.TRUE1=33,m=e.TRUE2=34,g=e.TRUE3=35,v=e.FALSE1=49,_=e.FALSE2=50,w=e.FALSE3=51,S=e.FALSE4=52,A=e.NULL1=65,D=e.NULL2=66,L=e.NULL3=67,E=e.NUMBER1=81,O=e.NUMBER3=83,P=e.STRING1=97,j=e.STRING2=98,U=e.STRING3=99,M=e.STRING4=100,q=e.STRING5=101,Q=e.STRING6=102,Z=e.VALUE=113,K=e.KEY=114,fe=e.OBJECT=129,X=e.ARRAY=130,he="\\".charCodeAt(0),xe="/".charCodeAt(0),ie="\b".charCodeAt(0),ae="\f".charCodeAt(0),Oe=` -`.charCodeAt(0),Ne="\r".charCodeAt(0),ge=" ".charCodeAt(0),de=64*1024;function oe(R){return t.alloc?t.alloc(R):new t(R)}function $(){this.tState=p,this.value=void 0,this.string=void 0,this.stringBuffer=oe(de),this.stringBufferOffset=0,this.unicode=void 0,this.highSurrogate=void 0,this.key=void 0,this.mode=void 0,this.stack=[],this.state=Z,this.bytes_remaining=0,this.bytes_in_sequence=0,this.temp_buffs={2:oe(2),3:oe(3),4:oe(4)},this.offset=-1}$.toknam=function(R){for(var T=Object.keys(e),x=0,B=T.length;x=de&&(this.string+=this.stringBuffer.toString("utf8"),this.stringBufferOffset=0),this.stringBuffer[this.stringBufferOffset++]=R},N.appendStringBuf=function(R,T,x){var B=R.length;typeof T=="number"&&(typeof x=="number"?x<0?B=R.length-T+x:B=x-T:B=R.length-T),B<0&&(B=0),this.stringBufferOffset+B>de&&(this.string+=this.stringBuffer.toString("utf8",0,this.stringBufferOffset),this.stringBufferOffset=0),R.copy(this.stringBuffer,this.stringBufferOffset,T,x),this.stringBufferOffset+=B},N.write=function(R){typeof R=="string"&&(R=new t(R));for(var T,x=0,B=R.length;x=48&&T<64)this.string=String.fromCharCode(T),this.tState=O;else if(!(T===32||T===9||T===10||T===13))return this.charError(R,x)}else if(this.tState===P)if(T=R[x],this.bytes_remaining>0){for(var k=0;k=128){if(T<=193||T>244)return this.onError(new Error("Invalid UTF-8 character at position "+x+" in state "+$.toknam(this.tState)));if(T>=194&&T<=223&&(this.bytes_in_sequence=2),T>=224&&T<=239&&(this.bytes_in_sequence=3),T>=240&&T<=244&&(this.bytes_in_sequence=4),this.bytes_in_sequence+x>R.length){for(var V=0;V<=R.length-1-x;V++)this.temp_buffs[this.bytes_in_sequence][V]=R[x+V];this.bytes_remaining=x+this.bytes_in_sequence-R.length,x=R.length-1}else this.appendStringBuf(R,x,x+this.bytes_in_sequence),x=x+this.bytes_in_sequence-1}else if(T===34)this.tState=p,this.string+=this.stringBuffer.toString("utf8",0,this.stringBufferOffset),this.stringBufferOffset=0,this.onToken(h,this.string),this.offset+=t.byteLength(this.string,"utf8")+1,this.string=void 0;else if(T===92)this.tState=j;else if(T>=32)this.appendStringChar(T);else return this.charError(R,x);else if(this.tState===j)if(T=R[x],T===34)this.appendStringChar(T),this.tState=P;else if(T===92)this.appendStringChar(he),this.tState=P;else if(T===47)this.appendStringChar(xe),this.tState=P;else if(T===98)this.appendStringChar(ie),this.tState=P;else if(T===102)this.appendStringChar(ae),this.tState=P;else if(T===110)this.appendStringChar(Oe),this.tState=P;else if(T===114)this.appendStringChar(Ne),this.tState=P;else if(T===116)this.appendStringChar(ge),this.tState=P;else if(T===117)this.unicode="",this.tState=U;else return this.charError(R,x);else if(this.tState===U||this.tState===M||this.tState===q||this.tState===Q)if(T=R[x],T>=48&&T<64||T>64&&T<=70||T>96&&T<=102){if(this.unicode+=String.fromCharCode(T),this.tState++===Q){var J=parseInt(this.unicode,16);this.unicode=void 0,this.highSurrogate!==void 0&&J>=56320&&J<57343+1?(this.appendStringBuf(new t(String.fromCharCode(this.highSurrogate,J))),this.highSurrogate=void 0):this.highSurrogate===void 0&&J>=55296&&J<56319+1?this.highSurrogate=J:(this.highSurrogate!==void 0&&(this.appendStringBuf(new t(String.fromCharCode(this.highSurrogate))),this.highSurrogate=void 0),this.appendStringBuf(new t(String.fromCharCode(J)))),this.tState=P}}else return this.charError(R,x);else if(this.tState===E||this.tState===O)switch(T=R[x],T){case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:case 46:case 101:case 69:case 43:case 45:this.string+=String.fromCharCode(T),this.tState=O;break;default:this.tState=p;var z=this.numberReviver(this.string);if(z)return z;this.offset+=this.string.length-1,this.string=void 0,x--;break}else if(this.tState===b)if(R[x]===114)this.tState=m;else return this.charError(R,x);else if(this.tState===m)if(R[x]===117)this.tState=g;else return this.charError(R,x);else if(this.tState===g)if(R[x]===101)this.tState=p,this.onToken(l,!0),this.offset+=3;else return this.charError(R,x);else if(this.tState===v)if(R[x]===97)this.tState=_;else return this.charError(R,x);else if(this.tState===_)if(R[x]===108)this.tState=w;else return this.charError(R,x);else if(this.tState===w)if(R[x]===115)this.tState=S;else return this.charError(R,x);else if(this.tState===S)if(R[x]===101)this.tState=p,this.onToken(c,!1),this.offset+=4;else return this.charError(R,x);else if(this.tState===A)if(R[x]===117)this.tState=D;else return this.charError(R,x);else if(this.tState===D)if(R[x]===108)this.tState=L;else return this.charError(R,x);else if(this.tState===L)if(R[x]===108)this.tState=p,this.onToken(d,null),this.offset+=3;else return this.charError(R,x)},N.onToken=function(R,T){},N.parseError=function(R,T){this.tState=y,this.onError(new Error("Unexpected "+$.toknam(R)+(T?"("+JSON.stringify(T)+")":"")+" in state "+$.toknam(this.state)))},N.push=function(){this.stack.push({value:this.value,key:this.key,mode:this.mode})},N.pop=function(){var R=this.value,T=this.stack.pop();this.value=T.value,this.key=T.key,this.mode=T.mode,this.emit(R),this.mode||(this.state=Z)},N.emit=function(R){this.mode&&(this.state=o),this.onValue(R)},N.onValue=function(R){},N.onToken=function(R,T){if(this.state===Z)if(R===h||R===f||R===l||R===c||R===d)this.value&&(this.value[this.key]=T),this.emit(T);else if(R===u)this.push(),this.value?this.value=this.value[this.key]={}:this.value={},this.key=void 0,this.state=K,this.mode=fe;else if(R===n)this.push(),this.value?this.value=this.value[this.key]=[]:this.value=[],this.key=0,this.mode=X,this.state=Z;else if(R===s)if(this.mode===fe)this.pop();else return this.parseError(R,T);else if(R===r)if(this.mode===X)this.pop();else return this.parseError(R,T);else return this.parseError(R,T);else if(this.state===K)if(R===h)this.key=T,this.state=a;else if(R===s)this.pop();else return this.parseError(R,T);else if(this.state===a)if(R===a)this.state=Z;else return this.parseError(R,T);else if(this.state===o)if(R===o)this.mode===X?(this.key++,this.state=Z):this.mode===fe&&(this.state=K);else if(R===r&&this.mode===X||R===s&&this.mode===fe)this.pop();else return this.parseError(R,T);else return this.parseError(R,T)},N.numberReviver=function(R){var T=Number(R);if(isNaN(T))return this.charError(buffer,i);R.match(/[0-9]+/)==R&&T.toString()!=R?this.onToken(h,R):this.onToken(f,T)},$.C=e,q_=$,q_}var QI;function TG(){if(QI)return Xc;QI=1,Object.defineProperty(Xc,"__esModule",{value:!0}),Xc.SparqlJsonParser=void 0;const t=Et(),e=Wt(),u=Eq();let s=class{constructor(r){var a;r=r||{},this.dataFactory=r.dataFactory||new t.DataFactory,this.prefixVariableQuestionMark=!!r.prefixVariableQuestionMark,this.suppressMissingStreamResultsError=(a=r.suppressMissingStreamResultsError)!==null&&a!==void 0?a:!0}parseJsonResults(r){return r.results.bindings.map(a=>this.parseJsonBindings(a))}parseJsonResultsStream(r){const a=h=>d.emit("error",h);r.on("error",a);const o=new u;o.onError=a;let l=!1,c=!1;o.onValue=h=>{if(o.key==="vars"&&o.stack.length===2&&o.stack[1].key==="head")d.emit("variables",h.map(f=>this.dataFactory.variable(f))),l=!0;else if(o.key==="results"&&o.stack.length===1)c=!0;else if(typeof o.key=="number"&&o.stack.length===3&&o.stack[1].key==="results"&&o.stack[2].key==="bindings")try{d.push(this.parseJsonBindings(h))}catch(f){d.emit("error",f)}else o.key==="metadata"&&o.stack.length===1&&d.emit("metadata",h)};const d=r.on("end",h=>{!c&&!this.suppressMissingStreamResultsError?d.emit("error",new Error("No valid SPARQL query results were found.")):l||d.emit("variables",[])}).pipe(new e.Transform({objectMode:!0,transform(h,f,p){o.write(h),p()}}));return d}parseJsonBindings(r){const a={};for(const o in r){const l=r[o];a[this.prefixVariableQuestionMark?"?"+o:o]=this.parseJsonValue(l)}return a}parseJsonValue(r){let a;switch(r.type){case"bnode":a=this.dataFactory.blankNode(r.value);break;case"literal":r["xml:lang"]?a=this.dataFactory.literal(r.value,r["xml:lang"]):r.datatype?a=this.dataFactory.literal(r.value,this.dataFactory.namedNode(r.datatype)):a=this.dataFactory.literal(r.value);break;case"typed-literal":a=this.dataFactory.literal(r.value,this.dataFactory.namedNode(r.datatype));break;case"triple":const o=r.value;if(!o||!o.subject||!o.predicate||!o.object)throw new Error("Invalid quoted triple: "+JSON.stringify(r));a=this.dataFactory.quad(this.parseJsonValue(o.subject),this.parseJsonValue(o.predicate),this.parseJsonValue(o.object));break;default:a=this.dataFactory.namedNode(r.value);break}return a}parseJsonBoolean(r){if("boolean"in r)return r.boolean;throw new Error("No valid ASK response was found.")}parseJsonBooleanStream(r){return new Promise((a,o)=>{const l=new u;l.onError=o,l.onValue=c=>{l.key==="boolean"&&typeof c=="boolean"&&l.stack.length===1&&a(c)},r.on("error",o).on("data",c=>l.write(c)).on("end",()=>o(new Error("No valid ASK response was found.")))})}};return Xc.SparqlJsonParser=s,Xc}var VI;function Oq(){return VI||(VI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(TG(),t)}(F_)),F_}var kI;function AG(){if(kI)return Qc;kI=1,Object.defineProperty(Qc,"__esModule",{value:!0}),Qc.Converter=void 0;const t=SG(),e=Oq();let u=class fa{constructor(n){n=n||{delimiter:"_"},n.prefixVariableQuestionMark=!1,this.delimiter=n.delimiter||"_",this.parser=new e.SparqlJsonParser(n),this.materializeRdfJsTerms=n.materializeRdfJsTerms}static addValueToTree(n,r,a,o,l,c){const d=r[0],h=o?o+c+d:d,f=l.singularizeVariables[h];if(r.length===1)f?n[d]||(n[d]=a):(n[d]||(n[d]=[]),n[d].push(a));else{let p;f?(n[d]||(n[d]={}),p=n[d]):(n[d]||(n[d]=[{}]),p=n[d][0]),fa.addValueToTree(p,r.slice(1),a,h,l,c)}}static mergeTrees(n,r){if(typeof n!=typeof r)throw new Error(`Two incompatible tree nodes were found: ${typeof n} and ${typeof r}`);if(Array.isArray(n)!==Array.isArray(r))throw new Error(`Two incompatible tree nodes were found: Array?${Array.isArray(n)} and Array?${Array.isArray(r)}`);if(typeof n=="object"&&typeof r=="object"){if(n.termType&&r.termType)return n.equals(r)?{valid:!0,result:n}:{valid:!1,result:n};if(Array.isArray(n)&&Array.isArray(r)){if(n.length>0){const a=[];let o=!1;for(const l of n){const c=fa.mergeTrees(l,r[0]);c.valid?(o=!0,a.push(c.result)):a.push(l)}if(o)return{valid:!0,result:a}}return{valid:!0,result:n.concat(r)}}else{const a={};for(const o in r)a[o]=r[o];for(const o in n)if(a[o]){const l=fa.mergeTrees(n[o],a[o]);if(l.valid)a[o]=l.result;else return{valid:!1,result:n}}else a[o]=n[o];return{valid:!0,result:a}}}else throw new Error(`Unmergable tree types: ${typeof n} and ${typeof r}`)}static materializeTree(n){if(n.termType)return(0,t.getTermRaw)(n);if(Array.isArray(n))return n.map(fa.materializeTree);{const r={};for(const a in n)r[a]=fa.materializeTree(n[a]);return r}}sparqlJsonResultsToTree(n,r){return this.bindingsToTree(this.parser.parseJsonResults(n),r||{singularizeVariables:{}})}bindingsToTree(n,r){const a=r&&r.singularizeVariables[""];let o=a?{}:[];for(const l of n){const c=a?{}:[{}];for(const d in l){const h=d.split(this.delimiter),f=l[d];fa.addValueToTree(a?c:c[0],h,f,"",r,this.delimiter)}o=fa.mergeTrees(o,c).result}return this.materializeRdfJsTerms&&(o=fa.materializeTree(o)),o}};return Qc.Converter=u,Qc}var zI;function EG(){return zI||(zI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(AG(),t)}(C_)),C_}var GI;function WI(){if(GI)return $c;GI=1,Object.defineProperty($c,"__esModule",{value:!0}),$c.ActorQueryResultSerializeTree=void 0;const t=Gi(),e=Lt,u=ot,s=Wt(),n=EG();let r=class Rq extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(o){super(o)}static async bindingsStreamToGraphQl(o,l,c){const d=u.ActionContext.ensureActionContext(l),h=new n.Converter(c),f={singularizeVariables:d.get(e.KeysInitQuery.graphqlSingularizeVariables)??{}};return h.bindingsToTree(await o.map(p=>Object.fromEntries([...p].map(([y,b])=>[y.value,b]))).toArray(),f)}async testHandleChecked(o){if(o.type!=="bindings")throw new Error("This actor can only handle bindings streams.");return!0}async runHandle(o,l){const c=new s.Readable;return c._read=()=>{c._read=()=>{},Rq.bindingsStreamToGraphQl(o.bindingsStream,o.context,{materializeRdfJsTerms:!0}).then(d=>{c.push(JSON.stringify(d,null," ")),c.push(null)}).catch(d=>c.emit("error",d))},{data:c}}};return $c.ActorQueryResultSerializeTree=r,$c}var JI;function OG(){return JI||(JI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(r,a,o,l){l===void 0&&(l=o);var c=Object.getOwnPropertyDescriptor(a,o);(!c||("get"in c?!a.__esModule:c.writable||c.configurable))&&(c={enumerable:!0,get:function(){return a[o]}}),Object.defineProperty(r,l,c)}:function(r,a,o,l){l===void 0&&(l=o),r[l]=a[o]}),u=I&&I.__exportStar||function(r,a){for(var o in r)o!=="default"&&!Object.prototype.hasOwnProperty.call(a,o)&&e(a,r,o)};Object.defineProperty(t,"__esModule",{value:!0}),t.bindingsStreamToGraphQl=void 0;const s=WI(),{bindingsStreamToGraphQl:n}=s.ActorQueryResultSerializeTree;t.bindingsStreamToGraphQl=n,u(WI(),t)}(N_)),N_}var B_={},Kc={},XI;function RG(){if(XI)return Kc;XI=1,Object.defineProperty(Kc,"__esModule",{value:!0}),Kc.MediatorCombineUnion=void 0;const t=ot;let e=class extends t.Mediator{constructor(s){super(s),this.combiner=this.createCombiner()}async mediate(s){let n;try{n=this.publish(s)}catch{n=[]}if(this.filterErrors){const a=[];for(const o of n)try{await o.reply,a.push(o)}catch{}n=a}await Promise.all(n.map(({reply:a})=>a));const r=await Promise.all(n.map(a=>a.actor.runObservable(s)));return this.combiner(r)}mediateWith(){throw new Error("Method not supported.")}createCombiner(){return s=>{const n={};return n[this.field]={},[{}].concat(s.map(r=>r[this.field])).forEach(r=>{n[this.field]={...r,...n[this.field]}}),n}}};return Kc.MediatorCombineUnion=e,Kc}var KI;function Ra(){return KI||(KI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(RG(),t)}(B_)),B_}var U_={},Yc={},YI;function xG(){if(YI)return Yc;YI=1,Object.defineProperty(Yc,"__esModule",{value:!0}),Yc.MediatorNumber=void 0;const t=ot;let e=class extends t.Mediator{constructor(s){super(s),this.indexPicker=this.createIndexPicker()}createIndexPicker(){switch(this.type){case"min":return s=>s.reduce((n,r,a)=>{const o=this.getOrDefault(r[this.field],Number.POSITIVE_INFINITY);return o!==null&&(Number.isNaN(n[0])||n[0]>o)?[o,a]:n},[Number.NaN,-1])[1];case"max":return s=>s.reduce((n,r,a)=>{const o=this.getOrDefault(r[this.field],Number.NEGATIVE_INFINITY);return o!==null&&(Number.isNaN(n[0])||n[0]c);const a=[];if(this.ignoreErrors){const c={};c[this.field]=null,r=r.map(d=>d.catch(h=>(a.push(h),c)))}const o=await Promise.all(r),l=this.indexPicker(o);if(l<0)throw new Error(`All actors rejected their test in ${this.name} -${a.map(c=>c.message).join(` -`)}`);return n[l].actor}};return Yc.MediatorNumber=e,Yc}var ZI;function Zc(){return ZI||(ZI=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(xG(),t)}(U_)),U_}var H_={},el={},$_={},tl={},oa={},eP;function BT(){if(eP)return oa;eP=1,Object.defineProperty(oa,"__esModule",{value:!0}),oa.ActorDereferenceBase=oa.isHardError=oa.emptyReadable=void 0;const t=Lt,e=ot,u=Wt();function s(){const a=new u.Readable;return a.push(null),a}oa.emptyReadable=s;function n(a){return!a.get(t.KeysInitQuery.lenient)}oa.isHardError=n;let r=class extends e.Actor{constructor(o){super(o)}async dereferenceErrorHandler(o,l,c){if(n(o.context))throw l;return this.logWarn(o.context,l.message),{...c,data:s()}}};return oa.ActorDereferenceBase=r,oa}var tP;function IG(){if(tP)return tl;tP=1,Object.defineProperty(tl,"__esModule",{value:!0}),tl.ActorDereference=void 0;const t=BT();let e=class extends t.ActorDereferenceBase{constructor(s){super(s)}async handleDereferenceErrors(s,n,r,a=0){return this.dereferenceErrorHandler(s,n,{url:s.url,exists:!1,headers:r,requestTime:a})}};return tl.ActorDereference=e,tl}var ms={},rP;function PG(){if(rP)return ms;rP=1,Object.defineProperty(ms,"__esModule",{value:!0}),ms.ActorDereferenceParse=ms.getMediaTypeFromExtension=void 0;const t=Wt(),e=BT();function u(n,r){const a=n.lastIndexOf(".");return a>=0&&(r==null?void 0:r[n.slice(a+1)])||""}ms.getMediaTypeFromExtension=u;let s=class extends e.ActorDereferenceBase{constructor(r){super(r)}async test(r){return!0}handleDereferenceStreamErrors(r,a){return(0,e.isHardError)(r.context)||(a.on("error",o=>{this.logWarn(r.context,o.message,()=>({url:r.url})),a.push(null)}),a=a.pipe(new t.PassThrough({objectMode:!0}))),a}async run(r){var c,d;const{context:a}=r,o=await this.mediatorDereference.mediate({...r,mediaTypes:async()=>{var h,f;return(f=await((h=this.mediatorParseMediatypes)==null?void 0:h.mediate({context:a,mediaTypes:!0})))==null?void 0:f.mediaTypes}});let l;try{l=(await this.mediatorParse.mediate({context:a,handle:{context:a,...o,metadata:await this.getMetadata(o)},handleMediaType:o.mediaType||u(o.url,this.mediaMappings)||r.mediaType})).handle,l.data=this.handleDereferenceStreamErrors(r,l.data)}catch(h){await((d=(c=o.data).close)==null?void 0:d.call(c)),l=await this.dereferenceErrorHandler(r,h,{})}return{...o,...l}}};return ms.ActorDereferenceParse=s,ms}var nP;function UT(){return nP||(nP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(IG(),t),u(PG(),t),u(BT(),t)}($_)),$_}var iP;function DG(){if(iP)return el;iP=1,Object.defineProperty(el,"__esModule",{value:!0}),el.ActorDereferenceFallback=void 0;const t=UT();let e=class extends t.ActorDereference{constructor(s){super(s)}async test(s){return!0}async run(s){return this.handleDereferenceErrors(s,new Error(`Could not dereference '${s.url}'`))}};return el.ActorDereferenceFallback=e,el}var aP;function NG(){return aP||(aP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(DG(),t)}(H_)),H_}var Q_={},rl={},V_={},nl={},sP;function CG(){if(sP)return nl;sP=1,Object.defineProperty(nl,"__esModule",{value:!0}),nl.ActorRdfJoinEntriesSort=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return nl.ActorRdfJoinEntriesSort=e,nl}var oP;function jG(){return oP||(oP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(CG(),t)}(V_)),V_}var uP;function LG(){if(uP)return rl;uP=1,Object.defineProperty(rl,"__esModule",{value:!0}),rl.ActorRdfJoinEntriesSortCardinality=void 0;const t=jG();let e=class extends t.ActorRdfJoinEntriesSort{constructor(s){super(s)}async test(s){return!0}async run(s){return{entries:[...s.entries].sort((r,a)=>r.metadata.cardinality.value-a.metadata.cardinality.value)}}};return rl.ActorRdfJoinEntriesSortCardinality=e,rl}var cP;function MG(){return cP||(cP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(LG(),t)}(Q_)),Q_}var k_={},_s={},z_={},il={},lP;function FG(){if(lP)return il;lP=1,Object.defineProperty(il,"__esModule",{value:!0}),il.ActorRdfJoinSelectivity=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return il.ActorRdfJoinSelectivity=e,il}var dP;function qG(){return dP||(dP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(FG(),t)}(z_)),z_}var fP;function BG(){if(fP)return _s;fP=1,Object.defineProperty(_s,"__esModule",{value:!0}),_s.JoinTypes=_s.ActorRdfJoinSelectivityVariableCounting=void 0;const t=qG(),e=Ot();let u=class Ns extends t.ActorRdfJoinSelectivity{constructor(r){super(r)}async test(r){return{accuracy:.5}}static getPatternCost(r){let a=1;return r.subject.termType==="Variable"&&(a+=4),(r.predicate.termType==="Variable"||r.type===e.Algebra.types.PATH)&&(a+=1),r.object.termType==="Variable"&&(a+=2),r.graph.termType==="Variable"&&(a+=1),a/9}static getJoinTypes(r,a){const o=[];return r.subject.termType==="Variable"?(r.subject.equals(a.subject)&&o.push(s.unboundSS),a.type==="pattern"&&r.subject.equals(a.predicate)&&o.push(s.unboundSP),r.subject.equals(a.object)&&o.push(s.unboundSO),r.subject.equals(a.graph)&&o.push(s.unboundSG)):(r.subject.equals(a.subject)&&o.push(s.boundSS),a.type==="pattern"&&r.subject.equals(a.predicate)&&o.push(s.boundSP),r.subject.equals(a.object)&&o.push(s.boundSO),r.subject.equals(a.graph)&&o.push(s.boundSG)),r.type==="pattern"&&(r.predicate.termType==="Variable"?(r.predicate.equals(a.subject)&&o.push(s.unboundPS),a.type==="pattern"&&r.predicate.equals(a.predicate)&&o.push(s.unboundPP),r.predicate.equals(a.object)&&o.push(s.unboundPO),r.predicate.equals(a.graph)&&o.push(s.unboundPG)):(r.predicate.equals(a.subject)&&o.push(s.boundPS),a.type==="pattern"&&r.predicate.equals(a.predicate)&&o.push(s.boundPP),r.predicate.equals(a.object)&&o.push(s.boundPO),r.predicate.equals(a.graph)&&o.push(s.boundPG))),r.object.termType==="Variable"?(r.object.equals(a.subject)&&o.push(s.unboundOS),a.type==="pattern"&&r.object.equals(a.predicate)&&o.push(s.unboundOP),r.object.equals(a.object)&&o.push(s.unboundOO),r.object.equals(a.graph)&&o.push(s.unboundOG)):(r.object.equals(a.subject)&&o.push(s.boundOS),a.type==="pattern"&&r.object.equals(a.predicate)&&o.push(s.boundOP),r.object.equals(a.object)&&o.push(s.boundOO),r.object.equals(a.graph)&&o.push(s.boundOG)),r.graph.termType==="Variable"?(r.graph.equals(a.subject)&&o.push(s.unboundGS),a.type==="pattern"&&r.graph.equals(a.predicate)&&o.push(s.unboundGP),r.graph.equals(a.object)&&o.push(s.unboundGO),r.graph.equals(a.graph)&&o.push(s.unboundGG)):(r.graph.equals(a.subject)&&o.push(s.boundGS),a.type==="pattern"&&r.graph.equals(a.predicate)&&o.push(s.boundGP),r.graph.equals(a.object)&&o.push(s.boundGO),r.graph.equals(a.graph)&&o.push(s.boundGG)),o}static getOperationsPairwiseJoinCost(r,a){let o=Ns.MAX_PAIRWISE_COST;for(const l of Ns.getJoinTypes(r,a))switch(l){case s.boundSS:o-=2*2;break;case s.boundSP:o-=3*2;break;case s.boundSO:o-=1*2;break;case s.boundSG:o-=3*2;break;case s.boundPS:o-=3*2;break;case s.boundPP:return 1;case s.boundPO:o-=3*2;break;case s.boundPG:o-=3*2;break;case s.boundOS:o-=1*2;break;case s.boundOP:o-=3*2;break;case s.boundOO:o-=1*2;break;case s.boundOG:o-=3*2;break;case s.boundGS:o-=3*2;break;case s.boundGP:o-=3*2;break;case s.boundGO:o-=3*2;break;case s.boundGG:o-=3*2;break;case s.unboundSS:o-=2;break;case s.unboundSP:o-=3;break;case s.unboundSO:o-=1;break;case s.unboundSG:o-=3;break;case s.unboundPS:o-=3;break;case s.unboundPP:o-=3;break;case s.unboundPO:o-=3;break;case s.unboundPG:o-=3;break;case s.unboundOS:o-=1;break;case s.unboundOP:o-=3;break;case s.unboundOO:o-=1;break;case s.unboundOG:o-=3;break;case s.unboundGS:o-=3;break;case s.unboundGP:o-=3;break;case s.unboundGO:o-=3;break;case s.unboundGG:o-=3;break}return o/Ns.MAX_PAIRWISE_COST}static getOperationsJoinCost(r){const a=[];for(const c of r)e.Util.recurseOperation(c,{[e.Algebra.types.PATTERN](d){return a.push(d),!1},[e.Algebra.types.PATH](d){return a.push(d),!1}});let o=0,l=0;for(const c of a)for(const d of a)c!==d&&(o+=Ns.getOperationsPairwiseJoinCost(c,d),l++);return l===0?1:o/l*a.reduce((c,d)=>c*Ns.getPatternCost(d),1)}async run(r){return r.entries.length<=1?{selectivity:1}:{selectivity:Ns.getOperationsJoinCost(r.entries.map(a=>a.operation))}}};_s.ActorRdfJoinSelectivityVariableCounting=u,u.MAX_PAIRWISE_COST=41*2;var s;return function(n){n[n.boundSS=0]="boundSS",n[n.boundSP=1]="boundSP",n[n.boundSO=2]="boundSO",n[n.boundSG=3]="boundSG",n[n.boundPS=4]="boundPS",n[n.boundPP=5]="boundPP",n[n.boundPO=6]="boundPO",n[n.boundPG=7]="boundPG",n[n.boundOS=8]="boundOS",n[n.boundOP=9]="boundOP",n[n.boundOO=10]="boundOO",n[n.boundOG=11]="boundOG",n[n.boundGS=12]="boundGS",n[n.boundGP=13]="boundGP",n[n.boundGO=14]="boundGO",n[n.boundGG=15]="boundGG",n[n.unboundSS=16]="unboundSS",n[n.unboundSP=17]="unboundSP",n[n.unboundSO=18]="unboundSO",n[n.unboundSG=19]="unboundSG",n[n.unboundPS=20]="unboundPS",n[n.unboundPP=21]="unboundPP",n[n.unboundPO=22]="unboundPO",n[n.unboundPG=23]="unboundPG",n[n.unboundOS=24]="unboundOS",n[n.unboundOP=25]="unboundOP",n[n.unboundOO=26]="unboundOO",n[n.unboundOG=27]="unboundOG",n[n.unboundGS=28]="unboundGS",n[n.unboundGP=29]="unboundGP",n[n.unboundGO=30]="unboundGO",n[n.unboundGG=31]="unboundGG"}(s||(_s.JoinTypes=s={})),_s}var hP;function UG(){return hP||(hP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(BG(),t)}(k_)),k_}var G_={},al={},W_={},sl={},pP;function HG(){if(pP)return sl;pP=1,Object.defineProperty(sl,"__esModule",{value:!0}),sl.ActorRdfMetadata=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return sl.ActorRdfMetadata=e,sl}var yP;function xq(){return yP||(yP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(HG(),t)}(W_)),W_}var bP;function $G(){if(bP)return al;bP=1,Object.defineProperty(al,"__esModule",{value:!0}),al.ActorRdfMetadataPrimaryTopic=void 0;const t=xq(),e=Wt();let u=class extends t.ActorRdfMetadata{constructor(n){super(n)}async test(n){if(n.triples)throw new Error("This actor only supports non-triple quad streams.");return!0}async run(n){const r=new e.Readable({objectMode:!0}),a=new e.Readable({objectMode:!0}),o=()=>{r._read=a._read=()=>{},n.quads.on("error",h=>{r.emit("error",h),a.emit("error",h)});const l={};let c;const d={};n.quads.on("data",h=>{h.predicate.value==="http://rdfs.org/ns/void#subset"&&h.object.value===n.url?c=h.subject.value:h.predicate.value==="http://xmlns.com/foaf/0.1/primaryTopic"&&(d[h.object.value]=h.subject.value);let f=l[h.graph.value];f||(f=l[h.graph.value]=[]),f.push(h)}),n.quads.on("end",()=>{const h=c?d[c]:void 0;for(const f in l)if(f===h){for(const p of l[f])a.push(p);if(this.metadataToData)for(const p of l[f])r.push(p)}else{for(const p of l[f])r.push(p);if(!h&&this.dataToMetadataOnInvalidMetadataGraph)for(const p of l[f])a.push(p)}r.push(null),a.push(null)})};return r._read=a._read=()=>{o()},{data:r,metadata:a}}};return al.ActorRdfMetadataPrimaryTopic=u,al}var gP;function QG(){return gP||(gP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u($G(),t)}(G_)),G_}var J_={},ol={},mP;function VG(){if(mP)return ol;mP=1,Object.defineProperty(ol,"__esModule",{value:!0}),ol.ActorRdfMetadataAll=void 0;const t=xq(),e=Wt();let u=class extends t.ActorRdfMetadata{constructor(n){super(n)}async test(n){return!0}async run(n){const r=new e.Readable({objectMode:!0}),a=new e.Readable({objectMode:!0});n.quads.on("error",l=>{r.emit("error",l),a.emit("error",l)}),n.quads.on("end",()=>{r.push(null),a.push(null)});const o=r._read=a._read=l=>{for(;l>0;){const c=n.quads.read();if(c===null)return n.quads.once("readable",()=>o(l));l--,r.push(c),a.push(c)}};return{data:r,metadata:a}}};return ol.ActorRdfMetadataAll=u,ol}var _P;function kG(){return _P||(_P=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(VG(),t)}(J_)),J_}var X_={},ul={},K_={},cl={},vP;function zG(){if(vP)return cl;vP=1,Object.defineProperty(cl,"__esModule",{value:!0}),cl.ActorRdfMetadataAccumulate=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return cl.ActorRdfMetadataAccumulate=e,cl}var wP;function Hb(){return wP||(wP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(zG(),t)}(K_)),K_}var SP;function GG(){if(SP)return ul;SP=1,Object.defineProperty(ul,"__esModule",{value:!0}),ul.ActorRdfMetadataAccumulateCanContainUndefs=void 0;const t=Hb();let e=class extends t.ActorRdfMetadataAccumulate{constructor(s){super(s)}async test(s){return!0}async run(s){if(s.mode==="initialize")return{metadata:{canContainUndefs:!1}};let n=s.accumulatedMetadata.canContainUndefs;return s.appendingMetadata.canContainUndefs&&(n=!0),{metadata:{canContainUndefs:n}}}};return ul.ActorRdfMetadataAccumulateCanContainUndefs=e,ul}var TP;function WG(){return TP||(TP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(GG(),t)}(X_)),X_}var Y_={},ll={},AP;function JG(){if(AP)return ll;AP=1,Object.defineProperty(ll,"__esModule",{value:!0}),ll.ActorRdfMetadataAccumulateCardinality=void 0;const t=Hb();let e=class extends t.ActorRdfMetadataAccumulate{constructor(s){super(s)}async test(s){return!0}async run(s){if(s.mode==="initialize")return{metadata:{cardinality:{type:"exact",value:0}}};const n={...s.accumulatedMetadata.cardinality};if(n.dataset)if(s.appendingMetadata.cardinality.dataset){if(n.dataset!==s.appendingMetadata.cardinality.dataset&&s.appendingMetadata.subsetOf===n.dataset)return{metadata:{cardinality:s.appendingMetadata.cardinality}};if(n.dataset===s.appendingMetadata.cardinality.dataset)return{metadata:{cardinality:n}};delete n.dataset}else return{metadata:{cardinality:n}};return!s.appendingMetadata.cardinality||!Number.isFinite(s.appendingMetadata.cardinality.value)?(n.type="estimate",n.value=Number.POSITIVE_INFINITY):(s.appendingMetadata.cardinality.type==="estimate"&&(n.type="estimate"),n.value+=s.appendingMetadata.cardinality.value),{metadata:{cardinality:n}}}};return ll.ActorRdfMetadataAccumulateCardinality=e,ll}var EP;function XG(){return EP||(EP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(JG(),t)}(Y_)),Y_}var Z_={},dl={},OP;function KG(){if(OP)return dl;OP=1,Object.defineProperty(dl,"__esModule",{value:!0}),dl.ActorRdfMetadataAccumulatePageSize=void 0;const t=Hb();let e=class extends t.ActorRdfMetadataAccumulate{constructor(s){super(s)}async test(s){return!0}async run(s){return s.mode==="initialize"?{metadata:{}}:{metadata:{..."pageSize"in s.accumulatedMetadata||"pageSize"in s.appendingMetadata?{pageSize:(s.accumulatedMetadata.pageSize??0)+(s.appendingMetadata.pageSize??0)}:{}}}}};return dl.ActorRdfMetadataAccumulatePageSize=e,dl}var RP;function YG(){return RP||(RP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(KG(),t)}(Z_)),Z_}var ev={},fl={},xP;function ZG(){if(xP)return fl;xP=1,Object.defineProperty(fl,"__esModule",{value:!0}),fl.ActorRdfMetadataAccumulateRequestTime=void 0;const t=Hb();let e=class extends t.ActorRdfMetadataAccumulate{constructor(s){super(s)}async test(s){return!0}async run(s){return s.mode==="initialize"?{metadata:{}}:{metadata:{..."requestTime"in s.accumulatedMetadata||"requestTime"in s.appendingMetadata?{requestTime:(s.accumulatedMetadata.requestTime??0)+(s.appendingMetadata.requestTime??0)}:{}}}}};return fl.ActorRdfMetadataAccumulateRequestTime=e,fl}var IP;function eW(){return IP||(IP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(ZG(),t)}(ev)),ev}var tv={},hl={},rv={},pl={},PP;function tW(){if(PP)return pl;PP=1,Object.defineProperty(pl,"__esModule",{value:!0}),pl.ActorRdfMetadataExtract=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return pl.ActorRdfMetadataExtract=e,pl}var DP;function es(){return DP||(DP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(tW(),t)}(rv)),rv}var nv={exports:{}},NP;function rW(){return NP||(NP=1,function(t){(function(e){var u=function(){function y(b){this.options=b}return y.prototype.toString=function(){return JSON&&JSON.stringify?JSON.stringify(this.options):this.options},y}(),s=function(){function y(D){return Object.prototype.toString.apply(D)==="[object Array]"}function b(D){return Object.prototype.toString.apply(D)==="[object String]"}function m(D){return Object.prototype.toString.apply(D)==="[object Number]"}function g(D){return Object.prototype.toString.apply(D)==="[object Boolean]"}function v(D,L){var E="",O=!0,P;for(P=0;P="a"&&g<="z"||g>="A"&&g<="Z"}function b(g){return g>="0"&&g<="9"}function m(g){return b(g)||g>="a"&&g<="f"||g>="A"&&g<="F"}return{isAlpha:y,isDigit:b,isHexDigit:m}}(),r=function(){var y={encode:function(w){return unescape(encodeURIComponent(w))},numBytes:function(w){return w<=127?1:194<=w&&w<=223?2:224<=w&&w<=239?3:240<=w&&w<=244?4:0},isValidFollowingCharCode:function(w){return 128<=w&&w<=191}};function b(w){var S="",A=y.encode(w),D,L;for(L=0;L1||a.isReserved(w)||a.isUnreserved(w)?w:r.encodeCharacter(w)}function g(v){var _="",w,S="";for(w=0;w1?_+=S:_+=a.isReserved(S)||a.isUnreserved(S)?S:r.encodeCharacter(S);return _}return{encode:y,encodePassReserved:b,encodeLiteral:g,encodeLiteralCharacter:m}}(),l=function(){var y={};function b(m){y[m]={symbol:m,separator:m==="?"?"&":m===""||m==="+"||m==="#"?",":m,named:m===";"||m==="&"||m==="?",ifEmpty:m==="&"||m==="?"?"=":"",first:m==="+"?"":m,encode:m==="+"||m==="#"?o.encodePassReserved:o.encode,toString:function(){return this.symbol}}}return b(""),b("+"),b("#"),b("."),b("/"),b(";"),b("?"),b("&"),{valueOf:function(m){return y[m]?y[m]:"=,!@|".indexOf(m)>=0?null:y[""]}}}();function c(y){var b;if(y==null)return!1;if(s.isArray(y))return y.length>0;if(typeof y=="string"||typeof y=="number"||typeof y=="boolean")return!0;for(b in y)if(y.hasOwnProperty(b)&&c(y[b]))return!0;return!1}var d=function(){function y(b){this.literal=o.encodeLiteral(b)}return y.prototype.expand=function(){return this.literal},y.prototype.toString=y.prototype.expand,y}(),h=function(){function y(m){var g,v=[],_=null,w=null,S=null,A,D="";function L(){var O=m.substring(w,A);if(O.length===0)throw new u({expressionText:m,message:"a varname must be specified",position:A});_={varname:O,exploded:!1,maxLength:null},w=null}function E(){if(S===A)throw new u({expressionText:m,message:"after a ':' you have to specify the length",position:A});_.maxLength=parseInt(m.substring(S,A),10),S=null}for(g=function(O){var P=l.valueOf(O);if(P===null)throw new u({expressionText:m,message:"illegal use of reserved operator",position:A,operator:O});return P}(m.charAt(0)),A=g.symbol.length,w=A;A=4)throw new u({expressionText:m,message:"A :prefix must have max 4 digits",position:A});continue}E()}if(D===":"){if(_.maxLength!==null)throw new u({expressionText:m,message:"only one :maxLength is allowed per varspec",position:A});if(_.exploded)throw new u({expressionText:m,message:"an exploeded varspec MUST NOT be varspeced",position:A});S=A+1;continue}if(D==="*"){if(_===null)throw new u({expressionText:m,message:"exploded without varspec",position:A});if(_.exploded)throw new u({expressionText:m,message:"exploded twice",position:A});if(_.maxLength)throw new u({expressionText:m,message:"an explode (*) MUST NOT follow to a prefix",position:A});_.exploded=!0;continue}if(D===","){v.push(_),_=null,w=A+1;continue}throw new u({expressionText:m,message:"illegal character",character:D,position:A})}return w!==null&&L(),S!==null&&E(),v.push(_),new f(m,g,v)}function b(m){var g,v,_=[],w=null,S=0;for(g=0;g{const o=r[a]||r[`${a}Page`],l=o&&o[n];return[a,l&&l.length>0?[l[0]]:[]]}))}parseUriTemplateCached(n){const r=this.parsedUriTemplateCache[n];return r||(this.parsedUriTemplateCache[n]=(0,e.parse)(n))}getSearchForms(n){const r=n.search,a=[];if(r)for(const o in r)for(const l of r[o]){const c=(n.template||{})[l]||[];if(c.length!==1)throw new Error(`Expected 1 hydra:template for ${l}`);const d=c[0],h=this.parseUriTemplateCached(d),f=Object.fromEntries(((n.mapping||{})[l]||[]).map(y=>{const b=((n.variable||{})[y]||[])[0],m=((n.property||{})[y]||[])[0];if(!b)throw new Error(`Expected a hydra:variable for ${y}`);if(!m)throw new Error(`Expected a hydra:property for ${y}`);return[m,b]})),p=y=>h.expand(Object.fromEntries(Object.keys(y).map(b=>[f[b],y[b]])));a.push({dataset:o,template:d,mappings:f,getUri:p})}return{values:a}}getHydraProperties(n){return new Promise((r,a)=>{n.on("error",a);const o={};n.on("data",l=>{if(l.predicate.value.startsWith(F1.HYDRA)){const c=l.predicate.value.slice(F1.HYDRA.length),d=o[c]||(o[c]={});(d[l.subject.value]||(d[l.subject.value]=[])).push(l.object.value)}}),n.on("end",()=>r(o))})}async run(n){const r={},a=await this.getHydraProperties(n.metadata);return Object.assign(r,this.getLinks(n.url,a)),r.searchForms=this.getSearchForms(a),{metadata:r}}};return hl.ActorRdfMetadataExtractHydraControls=u,u.HYDRA="http://www.w3.org/ns/hydra/core#",u.LINK_TYPES=["first","next","previous","last"],hl}var jP;function iW(){return jP||(jP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(nW(),t)}(tv)),tv}var iv={},yl={},LP;function aW(){if(LP)return yl;LP=1,Object.defineProperty(yl,"__esModule",{value:!0}),yl.ActorRdfMetadataExtractHydraCount=void 0;const t=es();let e=class extends t.ActorRdfMetadataExtract{constructor(s){super(s)}async test(s){return!0}run(s){return new Promise((n,r)=>{s.metadata.on("error",r),s.metadata.on("data",a=>{this.predicates.includes(a.predicate.value)&&n({metadata:{cardinality:{type:"estimate",value:Number.parseInt(a.object.value,10),dataset:a.subject.value}}})}),s.metadata.on("end",()=>{n({metadata:{cardinality:{type:"estimate",value:0}}})})})}};return yl.ActorRdfMetadataExtractHydraCount=e,yl}var MP;function sW(){return MP||(MP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(aW(),t)}(iv)),iv}var av={},bl={},FP;function oW(){if(FP)return bl;FP=1,Object.defineProperty(bl,"__esModule",{value:!0}),bl.ActorRdfMetadataExtractHydraPagesize=void 0;const t=es();let e=class extends t.ActorRdfMetadataExtract{constructor(s){super(s)}async test(s){return!0}async run(s){return new Promise((n,r)=>{s.metadata.on("error",r),s.metadata.on("data",a=>{this.predicates.includes(a.predicate.value)&&n({metadata:{pageSize:Number.parseInt(a.object.value,10)}})}),s.metadata.on("end",()=>{n({metadata:{}})})})}};return bl.ActorRdfMetadataExtractHydraPagesize=e,bl}var qP;function uW(){return qP||(qP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(oW(),t)}(av)),av}var sv={},gl={},BP;function cW(){if(BP)return gl;BP=1,Object.defineProperty(gl,"__esModule",{value:!0}),gl.ActorRdfMetadataExtractRequestTime=void 0;const t=es();let e=class extends t.ActorRdfMetadataExtract{constructor(s){super(s)}async test(s){return!0}async run(s){return{metadata:{requestTime:s.requestTime}}}};return gl.ActorRdfMetadataExtractRequestTime=e,gl}var UP;function lW(){return UP||(UP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(cW(),t)}(sv)),sv}var ov={},ml={},HP;function dW(){if(HP)return ml;HP=1,Object.defineProperty(ml,"__esModule",{value:!0}),ml.ActorRdfMetadataExtractAllowHttpMethods=void 0;const t=es();let e=class extends t.ActorRdfMetadataExtract{constructor(s){super(s)}async test(s){return!0}async run(s){var r,a;const n={};return(r=s.headers)!=null&&r.get("allow")&&(n.allowHttpMethods=(a=s.headers.get("allow"))==null?void 0:a.split(/, */u)),{metadata:n}}};return ml.ActorRdfMetadataExtractAllowHttpMethods=e,ml}var $P;function fW(){return $P||($P=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(dW(),t)}(ov)),ov}var uv={},_l={},QP;function hW(){if(QP)return _l;QP=1,Object.defineProperty(_l,"__esModule",{value:!0}),_l.ActorRdfMetadataExtractPutAccepted=void 0;const t=es();let e=class extends t.ActorRdfMetadataExtract{constructor(s){super(s)}async test(s){return!0}async run(s){var r,a;const n={};return(r=s.headers)!=null&&r.get("accept-put")&&(n.putAccepted=(a=s.headers.get("accept-put"))==null?void 0:a.split(/, */u)),{metadata:n}}};return _l.ActorRdfMetadataExtractPutAccepted=e,_l}var VP;function pW(){return VP||(VP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(hW(),t)}(uv)),uv}var cv={},vl={},kP;function yW(){if(kP)return vl;kP=1,Object.defineProperty(vl,"__esModule",{value:!0}),vl.ActorRdfMetadataExtractPatchSparqlUpdate=void 0;const t=es();let e=class extends t.ActorRdfMetadataExtract{constructor(s){super(s)}async test(s){return!0}async run(s){var r,a,o,l;const n={};return(((a=(r=s.headers)==null?void 0:r.get("accept-patch"))==null?void 0:a.includes("application/sparql-update"))??((l=(o=s.headers)==null?void 0:o.get("ms-author-via"))==null?void 0:l.includes("SPARQL")))&&(n.patchSparqlUpdate=!0),{metadata:n}}};return vl.ActorRdfMetadataExtractPatchSparqlUpdate=e,vl}var zP;function bW(){return zP||(zP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(yW(),t)}(cv)),cv}var lv={},wl={},GP;function gW(){if(GP)return wl;GP=1,Object.defineProperty(wl,"__esModule",{value:!0}),wl.ActorRdfMetadataExtractSparqlService=void 0;const t=es(),e=Pi();let u=class extends t.ActorRdfMetadataExtract{constructor(n){super(n)}async test(n){return!0}async run(n){return new Promise((r,a)=>{n.metadata.on("error",a);const o={};n.metadata.on("data",l=>{l.predicate.value==="http://www.w3.org/ns/sparql-service-description#endpoint"&&(l.subject.termType==="BlankNode"||l.subject.value===n.url)?(o.sparqlService=l.object.termType==="Literal"?(0,e.resolve)(l.object.value,n.url):l.object.value,this.inferHttpsEndpoint&&n.url.startsWith("https")&&!o.sparqlService.startsWith("https")&&(o.sparqlService=o.sparqlService.replace("http:","https:"))):l.predicate.value==="http://www.w3.org/ns/sparql-service-description#defaultGraph"&&(o.defaultGraph=l.object.value)}),n.metadata.on("end",()=>{r({metadata:o})})})}};return wl.ActorRdfMetadataExtractSparqlService=u,wl}var WP;function mW(){return WP||(WP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(gW(),t)}(lv)),lv}var dv={},Sl={},fv={},Tl={},JP;function _W(){if(JP)return Tl;JP=1,Object.defineProperty(Tl,"__esModule",{value:!0}),Tl.ActorRdfParse=void 0;const t=nu();let e=class extends t.ActorAbstractMediaTyped{constructor(s){super(s)}};return Tl.ActorRdfParse=e,Tl}var Al={},XP;function vW(){if(XP)return Al;XP=1,Object.defineProperty(Al,"__esModule",{value:!0}),Al.ActorRdfParseFixedMediaTypes=void 0;const t=nu();let e=class extends t.ActorAbstractMediaTypedFixed{constructor(s){super(s)}async testHandleChecked(s){return!0}};return Al.ActorRdfParseFixedMediaTypes=e,Al}var KP;function au(){return KP||(KP=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(_W(),t),u(vW(),t)}(fv)),fv}var wW=Wi();/*! queue-microtask. MIT License. Feross Aboukhadijeh */let YP;var SW=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:I):t=>(YP||(YP=Promise.resolve())).then(t).catch(e=>setTimeout(()=>{throw e},0));const TW=Z$(SW),El="http://www.w3.org/1999/02/22-rdf-syntax-ns#",Ol="http://www.w3.org/2001/XMLSchema#",hv="http://www.w3.org/2000/10/swap/",cn={xsd:{decimal:`${Ol}decimal`,boolean:`${Ol}boolean`,double:`${Ol}double`,integer:`${Ol}integer`,string:`${Ol}string`},rdf:{type:`${El}type`,nil:`${El}nil`,first:`${El}first`,rest:`${El}rest`,langString:`${El}langString`},owl:{sameAs:"http://www.w3.org/2002/07/owl#sameAs"},r:{forSome:`${hv}reify#forSome`,forAll:`${hv}reify#forAll`},log:{implies:`${hv}log#implies`}},{xsd:c1}=cn,AW=/\\u([a-fA-F0-9]{4})|\\U([a-fA-F0-9]{8})|\\([^])/g,ZP={"\\":"\\","'":"'",'"':'"',n:` -`,r:"\r",t:" ",f:"\f",b:"\b",_:"_","~":"~",".":".","-":"-","!":"!",$:"$","&":"&","(":"(",")":")","*":"*","+":"+",",":",",";":";","=":"=","/":"/","?":"?","#":"#","@":"@","%":"%"},EW=/[\x00-\x20<>\\"\{\}\|\^\`]/,OW={_iri:!0,_unescapedIri:!0,_simpleQuotedString:!0,_langcode:!0,_blank:!0,_newline:!0,_comment:!0,_whitespace:!0,_endOfFile:!0},RW=/$0^/;class HT{constructor(e){if(this._iri=/^<((?:[^ <>{}\\]|\\[uU])+)>[ \t]*/,this._unescapedIri=/^<([^\x00-\x20<>\\"\{\}\|\^\`]*)>[ \t]*/,this._simpleQuotedString=/^"([^"\\\r\n]*)"(?=[^"])/,this._simpleApostropheString=/^'([^'\\\r\n]*)'(?=[^'])/,this._langcode=/^@([a-z]+(?:-[a-z0-9]+)*)(?=[^a-z0-9\-])/i,this._prefix=/^((?:[A-Za-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)?:(?=[#\s<])/,this._prefixed=/^((?:[A-Za-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)?:((?:(?:[0-:A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~])(?:(?:[\.\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~])*(?:[\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~]))?)?)(?:[ \t]+|(?=\.?[,;!\^\s#()\[\]\{\}"'<>]))/,this._variable=/^\?(?:(?:[A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:[\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)(?=[.,;!\^\s#()\[\]\{\}"'<>])/,this._blank=/^_:((?:[0-9A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)(?:[ \t]+|(?=\.?[,;:\s#()\[\]\{\}"'<>]))/,this._number=/^[\-+]?(?:(\d+\.\d*|\.?\d+)[eE][\-+]?|\d*(\.)?)\d+(?=\.?[,;:\s#()\[\]\{\}"'<>])/,this._boolean=/^(?:true|false)(?=[.,;\s#()\[\]\{\}"'<>])/,this._keyword=/^@[a-z]+(?=[\s#<:])/i,this._sparqlKeyword=/^(?:PREFIX|BASE|GRAPH)(?=[\s#<])/i,this._shortPredicates=/^a(?=[\s#()\[\]\{\}"'<>])/,this._newline=/^[ \t]*(?:#[^\n\r]*)?(?:\r\n|\n|\r)[ \t]*/,this._comment=/#([^\n\r]*)/,this._whitespace=/^[ \t]+/,this._endOfFile=/^(?:#[^\n\r]*)?$/,e=e||{},this._lineMode=!!e.lineMode){this._n3Mode=!1;for(const u in this)!(u in OW)&&this[u]instanceof RegExp&&(this[u]=RW)}else this._n3Mode=e.n3!==!1;this._comments=!!e.comments,this._literalClosingPos=0}_tokenizeToEnd(e,u){let s=this._input,n=s.length;for(;;){let o,l;for(;o=this._newline.exec(s);)this._comments&&(l=this._comment.exec(o[0]))&&r("comment",l[1],"",this._line,o[0].length),s=s.substr(o[0].length,s.length),n=s.length,this._line++;if(!o&&(o=this._whitespace.exec(s))&&(s=s.substr(o[0].length,s.length)),this._endOfFile.test(s))return u&&(this._comments&&(l=this._comment.exec(s))&&r("comment",l[1],"",this._line,s.length),s=null,r("eof","","",this._line,0)),this._input=s;const c=this._line,d=s[0];let h="",f="",p="",y=null,b=0,m=!1;switch(d){case"^":if(s.length<3)break;if(s[1]==="^"){if(this._previousMarker="^^",s=s.substr(2),s[0]!=="<"){m=!0;break}}else{this._n3Mode&&(b=1,h="^");break}case"<":if(y=this._unescapedIri.exec(s))h="IRI",f=y[1];else if(y=this._iri.exec(s)){if(f=this._unescape(y[1]),f===null||EW.test(f))return a(this);h="IRI"}else s.length>1&&s[1]==="<"?(h="<<",b=2):this._n3Mode&&s.length>1&&s[1]==="="&&(h="inverse",b=2,f=">");break;case">":s.length>1&&s[1]===">"&&(h=">>",b=2);break;case"_":((y=this._blank.exec(s))||u&&(y=this._blank.exec(`${s} `)))&&(h="blank",p="_",f=y[1]);break;case'"':if(y=this._simpleQuotedString.exec(s))f=y[1];else if({value:f,matchLength:b}=this._parseLiteral(s),f===null)return a(this);(y!==null||b!==0)&&(h="literal",this._literalClosingPos=0);break;case"'":if(!this._lineMode){if(y=this._simpleApostropheString.exec(s))f=y[1];else if({value:f,matchLength:b}=this._parseLiteral(s),f===null)return a(this);(y!==null||b!==0)&&(h="literal",this._literalClosingPos=0)}break;case"?":this._n3Mode&&(y=this._variable.exec(s))&&(h="var",f=y[0]);break;case"@":this._previousMarker==="literal"&&(y=this._langcode.exec(s))?(h="langcode",f=y[1]):(y=this._keyword.exec(s))&&(h=y[0]);break;case".":if(s.length===1?u:s[1]<"0"||s[1]>"9"){h=".",b=1;break}case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":case"+":case"-":(y=this._number.exec(s)||u&&(y=this._number.exec(`${s} `)))&&(h="literal",f=y[0],p=typeof y[1]=="string"?c1.double:typeof y[2]=="string"?c1.decimal:c1.integer);break;case"B":case"b":case"p":case"P":case"G":case"g":(y=this._sparqlKeyword.exec(s))?h=y[0].toUpperCase():m=!0;break;case"f":case"t":(y=this._boolean.exec(s))?(h="literal",f=y[0],p=c1.boolean):m=!0;break;case"a":(y=this._shortPredicates.exec(s))?(h="abbreviation",f="a"):m=!0;break;case"=":this._n3Mode&&s.length>1&&(h="abbreviation",s[1]!==">"?(b=1,f="="):(b=2,f=">"));break;case"!":if(!this._n3Mode)break;case",":case";":case"[":case"]":case"(":case")":case"}":this._lineMode||(b=1,h=d);break;case"{":!this._lineMode&&s.length>=2&&(s[1]==="|"?(h="{|",b=2):(h=d,b=1));break;case"|":s.length>=2&&s[1]==="}"&&(h="|}",b=2);break;default:m=!0}if(m&&((this._previousMarker==="@prefix"||this._previousMarker==="PREFIX")&&(y=this._prefix.exec(s))?(h="prefix",f=y[1]||""):((y=this._prefixed.exec(s))||u&&(y=this._prefixed.exec(`${s} `)))&&(h="prefixed",p=y[1]||"",f=this._unescape(y[2]))),this._previousMarker==="^^")switch(h){case"prefixed":h="type";break;case"IRI":h="typeIRI";break;default:h=""}if(!h)return u||!/^'''|^"""/.test(s)&&/\n|\r/.test(s)?a(this):this._input=s;const g=b||y[0].length,v=r(h,f,p,c,g);this.previousToken=v,this._previousMarker=h,s=s.substr(g,s.length)}function r(o,l,c,d,h){const f=s?n-s.length:n,p=f+h,y={type:o,value:l,prefix:c,line:d,start:f,end:p};return e(null,y),y}function a(o){e(o._syntaxError(/^\S*/.exec(s)[0]))}}_unescape(e){let u=!1;const s=e.replace(AW,(n,r,a,o)=>{if(typeof r=="string")return String.fromCharCode(Number.parseInt(r,16));if(typeof a=="string"){let l=Number.parseInt(a,16);return l<=65535?String.fromCharCode(Number.parseInt(a,16)):String.fromCharCode(55296+((l-=65536)>>10),56320+(l&1023))}return o in ZP?ZP[o]:(u=!0,"")});return u?null:s}_parseLiteral(e){if(e.length>=3){const u=e.match(/^(?:"""|"|'''|'|)/)[0],s=u.length;let n=Math.max(this._literalClosingPos,s);for(;(n=e.indexOf(u,n))>0;){let r=0;for(;e[n-r-1]==="\\";)r++;if(r%2===0){const a=e.substring(s,n),o=a.split(/\r\n|\r|\n/).length-1,l=n+s;if(s===1&&o!==0||s===3&&this._lineMode)break;return this._line+=o,{value:this._unescape(a),matchLength:l}}n++}this._literalClosingPos=e.length-s+1}return{value:"",matchLength:0}}_syntaxError(e){this._input=null;const u=new Error(`Unexpected "${e}" on line ${this._line}.`);return u.context={token:void 0,line:this._line,previousToken:this.previousToken},u}_readStartingBom(e){return e.startsWith("\uFEFF")?e.substr(1):e}tokenize(e,u){if(this._line=1,typeof e=="string")if(this._input=this._readStartingBom(e),typeof u=="function")TW(()=>this._tokenizeToEnd(u,!0));else{const s=[];let n;if(this._tokenizeToEnd((r,a)=>r?n=r:s.push(a),!0),n)throw n;return s}else this._pendingBuffer=null,typeof e.setEncoding=="function"&&e.setEncoding("utf8"),e.on("data",s=>{this._input!==null&&s.length!==0&&(this._pendingBuffer&&(s=wW.Buffer.concat([this._pendingBuffer,s]),this._pendingBuffer=null),s[s.length-1]&128?this._pendingBuffer=s:(typeof this._input>"u"?this._input=this._readStartingBom(typeof s=="string"?s:s.toString()):this._input+=s,this._tokenizeToEnd(u,!1)))}),e.on("end",()=>{typeof this._input=="string"&&this._tokenizeToEnd(u,!0)}),e.on("error",u)}}const{rdf:xW,xsd:Us}=cn;let Ry,IW=0;const i3={namedNode:PW,blankNode:DW,variable:CW,literal:NW,defaultGraph:jW,quad:eD,triple:eD},su=i3;let Ji=class Iq{constructor(e){this.id=e}get value(){return this.id}equals(e){return e instanceof Iq?this.id===e.id:!!e&&this.termType===e.termType&&this.value===e.value}hashCode(){return 0}toJSON(){return{termType:this.termType,value:this.value}}};class $b extends Ji{get termType(){return"NamedNode"}}class $a extends Ji{get termType(){return"Literal"}get value(){return this.id.substring(1,this.id.lastIndexOf('"'))}get language(){const e=this.id;let u=e.lastIndexOf('"')+1;return u0?"INF":"-INF")))),u===""||u===Us.string?new $a(`"${t}"`):new $a(`"${t}"^^${u}`)}function CW(t){return new QT(t)}function jW(){return Ry}function eD(t,e,u,s){return new K0(t,e,u,s)}let tD=0;class Qb{constructor(e){this._contextStack=[],this._graph=null,e=e||{},this._setBase(e.baseIRI),e.factory&&Pq(this,e.factory);const u=typeof e.format=="string"?e.format.match(/\w*$/)[0].toLowerCase():"",s=/turtle/.test(u),n=/trig/.test(u),r=/triple/.test(u),a=/quad/.test(u),o=this._n3Mode=/n3/.test(u),l=r||a;(this._supportsNamedGraphs=!(s||o))||(this._readPredicateOrNamedGraph=this._readPredicate),this._supportsQuads=!(s||n||r||o),this._supportsRDFStar=u===""||/star|\*$/.test(u),l&&(this._resolveRelativeIRI=c=>null),this._blankNodePrefix=typeof e.blankNodePrefix!="string"?"":e.blankNodePrefix.replace(/^(?!_:)/,"_:"),this._lexer=e.lexer||new HT({lineMode:l,n3:o}),this._explicitQuantifiers=!!e.explicitQuantifiers}static _resetBlankNodePrefix(){tD=0}_setBase(e){if(!e)this._base="",this._basePath="";else{const u=e.indexOf("#");u>=0&&(e=e.substr(0,u)),this._base=e,this._basePath=e.indexOf("/")<0?e:e.replace(/[^\/?]*(?:\?.*)?$/,""),e=e.match(/^(?:([a-z][a-z0-9+.-]*:))?(?:\/\/[^\/]*)?/i),this._baseRoot=e[0],this._baseScheme=e[1]}}_saveContext(e,u,s,n,r){const a=this._n3Mode;this._contextStack.push({type:e,subject:s,predicate:n,object:r,graph:u,inverse:a?this._inversePredicate:!1,blankPrefix:a?this._prefixes._:"",quantified:a?this._quantified:null}),a&&(this._inversePredicate=!1,this._prefixes._=this._graph?`${this._graph.value}.`:".",this._quantified=Object.create(this._quantified))}_restoreContext(e,u){const s=this._contextStack.pop();if(!s||s.type!==e)return this._error(`Unexpected ${u.type}`,u);this._subject=s.subject,this._predicate=s.predicate,this._object=s.object,this._graph=s.graph,this._n3Mode&&(this._inversePredicate=s.inverse,this._prefixes._=s.blankPrefix,this._quantified=s.quantified)}_readInTopContext(e){switch(e.type){case"eof":return this._graph!==null?this._error("Unclosed graph",e):(delete this._prefixes._,this._callback(null,null,this._prefixes));case"PREFIX":this._sparqlStyle=!0;case"@prefix":return this._readPrefix;case"BASE":this._sparqlStyle=!0;case"@base":return this._readBaseIRI;case"{":if(this._supportsNamedGraphs)return this._graph="",this._subject=null,this._readSubject;case"GRAPH":if(this._supportsNamedGraphs)return this._readNamedGraphLabel;default:return this._readSubject(e)}}_readEntity(e,u){let s;switch(e.type){case"IRI":case"typeIRI":const n=this._resolveIRI(e.value);if(n===null)return this._error("Invalid IRI",e);s=this._namedNode(n);break;case"type":case"prefixed":const r=this._prefixes[e.prefix];if(r===void 0)return this._error(`Undefined prefix "${e.prefix}:"`,e);s=this._namedNode(r+e.value);break;case"blank":s=this._blankNode(this._prefixes[e.prefix]+e.value);break;case"var":s=this._variable(e.value.substr(1));break;default:return this._error(`Expected entity but got ${e.type}`,e)}return!u&&this._n3Mode&&s.id in this._quantified&&(s=this._quantified[s.id]),s}_readSubject(e){switch(this._predicate=null,e.type){case"[":return this._saveContext("blank",this._graph,this._subject=this._blankNode(),null,null),this._readBlankNodeHead;case"(":return this._saveContext("list",this._graph,this.RDF_NIL,null,null),this._subject=null,this._readListItem;case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._graph=this._blankNode(),null,null),this._readSubject):this._error("Unexpected graph",e);case"}":return this._readPunctuation(e);case"@forSome":return this._n3Mode?(this._subject=null,this._predicate=this.N3_FORSOME,this._quantifier=this._blankNode,this._readQuantifierList):this._error('Unexpected "@forSome"',e);case"@forAll":return this._n3Mode?(this._subject=null,this._predicate=this.N3_FORALL,this._quantifier=this._variable,this._readQuantifierList):this._error('Unexpected "@forAll"',e);case"literal":if(!this._n3Mode)return this._error("Unexpected literal",e);if(e.prefix.length===0)return this._literalValue=e.value,this._completeSubjectLiteral;this._subject=this._literal(e.value,this._namedNode(e.prefix));break;case"<<":return this._supportsRDFStar?(this._saveContext("<<",this._graph,null,null,null),this._graph=null,this._readSubject):this._error("Unexpected RDF* syntax",e);default:if((this._subject=this._readEntity(e))===void 0)return;if(this._n3Mode)return this._getPathReader(this._readPredicateOrNamedGraph)}return this._readPredicateOrNamedGraph}_readPredicate(e){const u=e.type;switch(u){case"inverse":this._inversePredicate=!0;case"abbreviation":this._predicate=this.ABBREVIATIONS[e.value];break;case".":case"]":case"}":return this._predicate===null?this._error(`Unexpected ${u}`,e):(this._subject=null,u==="]"?this._readBlankNodeTail(e):this._readPunctuation(e));case";":return this._predicate!==null?this._readPredicate:this._error("Expected predicate but got ;",e);case"[":if(this._n3Mode)return this._saveContext("blank",this._graph,this._subject,this._subject=this._blankNode(),null),this._readBlankNodeHead;case"blank":if(!this._n3Mode)return this._error("Disallowed blank node as predicate",e);default:if((this._predicate=this._readEntity(e))===void 0)return}return this._readObject}_readObject(e){switch(e.type){case"literal":if(e.prefix.length===0)return this._literalValue=e.value,this._readDataTypeOrLang;this._object=this._literal(e.value,this._namedNode(e.prefix));break;case"[":return this._saveContext("blank",this._graph,this._subject,this._predicate,this._subject=this._blankNode()),this._readBlankNodeHead;case"(":return this._saveContext("list",this._graph,this._subject,this._predicate,this.RDF_NIL),this._subject=null,this._readListItem;case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._subject,this._predicate,this._graph=this._blankNode()),this._readSubject):this._error("Unexpected graph",e);case"<<":return this._supportsRDFStar?(this._saveContext("<<",this._graph,this._subject,this._predicate,null),this._graph=null,this._readSubject):this._error("Unexpected RDF* syntax",e);default:if((this._object=this._readEntity(e))===void 0)return;if(this._n3Mode)return this._getPathReader(this._getContextEndReader())}return this._getContextEndReader()}_readPredicateOrNamedGraph(e){return e.type==="{"?this._readGraph(e):this._readPredicate(e)}_readGraph(e){return e.type!=="{"?this._error(`Expected graph but got ${e.type}`,e):(this._graph=this._subject,this._subject=null,this._readSubject)}_readBlankNodeHead(e){return e.type==="]"?(this._subject=null,this._readBlankNodeTail(e)):(this._predicate=null,this._readPredicate(e))}_readBlankNodeTail(e){if(e.type!=="]")return this._readBlankNodePunctuation(e);this._subject!==null&&this._emit(this._subject,this._predicate,this._object,this._graph);const u=this._predicate===null;return this._restoreContext("blank",e),this._object!==null?this._getContextEndReader():this._predicate!==null?this._readObject:u?this._readPredicateOrNamedGraph:this._readPredicateAfterBlank}_readPredicateAfterBlank(e){switch(e.type){case".":case"}":return this._subject=null,this._readPunctuation(e);default:return this._readPredicate(e)}}_readListItem(e){let u=null,s=null,n=this._readListItem;const r=this._subject,a=this._contextStack,o=a[a.length-1];switch(e.type){case"[":this._saveContext("blank",this._graph,s=this._blankNode(),this.RDF_FIRST,this._subject=u=this._blankNode()),n=this._readBlankNodeHead;break;case"(":this._saveContext("list",this._graph,s=this._blankNode(),this.RDF_FIRST,this.RDF_NIL),this._subject=null;break;case")":if(this._restoreContext("list",e),a.length!==0&&a[a.length-1].type==="list"&&this._emit(this._subject,this._predicate,this._object,this._graph),this._predicate===null){if(n=this._readPredicate,this._subject===this.RDF_NIL)return n}else if(n=this._getContextEndReader(),this._object===this.RDF_NIL)return n;s=this.RDF_NIL;break;case"literal":e.prefix.length===0?(this._literalValue=e.value,n=this._readListItemDataTypeOrLang):(u=this._literal(e.value,this._namedNode(e.prefix)),n=this._getContextEndReader());break;case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._subject,this._predicate,this._graph=this._blankNode()),this._readSubject):this._error("Unexpected graph",e);default:if((u=this._readEntity(e))===void 0)return}if(s===null&&(this._subject=s=this._blankNode()),r===null?o.predicate===null?o.subject=s:o.object=s:this._emit(r,this.RDF_REST,s,this._graph),u!==null){if(this._n3Mode&&(e.type==="IRI"||e.type==="prefixed"))return this._saveContext("item",this._graph,s,this.RDF_FIRST,u),this._subject=u,this._predicate=null,this._getPathReader(this._readListItem);this._emit(s,this.RDF_FIRST,u,this._graph)}return n}_readDataTypeOrLang(e){return this._completeObjectLiteral(e,!1)}_readListItemDataTypeOrLang(e){return this._completeObjectLiteral(e,!0)}_completeLiteral(e){let u=this._literal(this._literalValue);switch(e.type){case"type":case"typeIRI":const s=this._readEntity(e);if(s===void 0)return;u=this._literal(this._literalValue,s),e=null;break;case"langcode":u=this._literal(this._literalValue,e.value),e=null;break}return{token:e,literal:u}}_completeSubjectLiteral(e){return this._subject=this._completeLiteral(e).literal,this._readPredicateOrNamedGraph}_completeObjectLiteral(e,u){const s=this._completeLiteral(e);if(s)return this._object=s.literal,u&&this._emit(this._subject,this.RDF_FIRST,this._object,this._graph),s.token===null?this._getContextEndReader():(this._readCallback=this._getContextEndReader(),this._readCallback(s.token))}_readFormulaTail(e){return e.type!=="}"?this._readPunctuation(e):(this._subject!==null&&this._emit(this._subject,this._predicate,this._object,this._graph),this._restoreContext("formula",e),this._object===null?this._readPredicate:this._getContextEndReader())}_readPunctuation(e){let u,s=this._graph;const n=this._subject,r=this._inversePredicate;switch(e.type){case"}":if(this._graph===null)return this._error("Unexpected graph closing",e);if(this._n3Mode)return this._readFormulaTail(e);this._graph=null;case".":this._subject=null,u=this._contextStack.length?this._readSubject:this._readInTopContext,r&&(this._inversePredicate=!1);break;case";":u=this._readPredicate;break;case",":u=this._readObject;break;case"{|":if(!this._supportsRDFStar)return this._error("Unexpected RDF* syntax",e);const a=this._predicate,o=this._object;this._subject=this._quad(n,a,o,this.DEFAULTGRAPH),u=this._readPredicate;break;case"|}":if(this._subject.termType!=="Quad")return this._error("Unexpected asserted triple closing",e);this._subject=null,u=this._readPunctuation;break;default:if(this._supportsQuads&&this._graph===null&&(s=this._readEntity(e))!==void 0){u=this._readQuadPunctuation;break}return this._error(`Expected punctuation to follow "${this._object.id}"`,e)}if(n!==null){const a=this._predicate,o=this._object;r?this._emit(o,a,n,s):this._emit(n,a,o,s)}return u}_readBlankNodePunctuation(e){let u;switch(e.type){case";":u=this._readPredicate;break;case",":u=this._readObject;break;default:return this._error(`Expected punctuation to follow "${this._object.id}"`,e)}return this._emit(this._subject,this._predicate,this._object,this._graph),u}_readQuadPunctuation(e){return e.type!=="."?this._error("Expected dot to follow quad",e):this._readInTopContext}_readPrefix(e){return e.type!=="prefix"?this._error("Expected prefix to follow @prefix",e):(this._prefix=e.value,this._readPrefixIRI)}_readPrefixIRI(e){if(e.type!=="IRI")return this._error(`Expected IRI to follow prefix "${this._prefix}:"`,e);const u=this._readEntity(e);return this._prefixes[this._prefix]=u.value,this._prefixCallback(this._prefix,u),this._readDeclarationPunctuation}_readBaseIRI(e){const u=e.type==="IRI"&&this._resolveIRI(e.value);return u?(this._setBase(u),this._readDeclarationPunctuation):this._error("Expected valid IRI to follow base declaration",e)}_readNamedGraphLabel(e){switch(e.type){case"IRI":case"blank":case"prefixed":return this._readSubject(e),this._readGraph;case"[":return this._readNamedGraphBlankLabel;default:return this._error("Invalid graph label",e)}}_readNamedGraphBlankLabel(e){return e.type!=="]"?this._error("Invalid graph label",e):(this._subject=this._blankNode(),this._readGraph)}_readDeclarationPunctuation(e){return this._sparqlStyle?(this._sparqlStyle=!1,this._readInTopContext(e)):e.type!=="."?this._error("Expected declaration to end with a dot",e):this._readInTopContext}_readQuantifierList(e){let u;switch(e.type){case"IRI":case"prefixed":if((u=this._readEntity(e,!0))!==void 0)break;default:return this._error(`Unexpected ${e.type}`,e)}return this._explicitQuantifiers?(this._subject===null?this._emit(this._graph||this.DEFAULTGRAPH,this._predicate,this._subject=this._blankNode(),this.QUANTIFIERS_GRAPH):this._emit(this._subject,this.RDF_REST,this._subject=this._blankNode(),this.QUANTIFIERS_GRAPH),this._emit(this._subject,this.RDF_FIRST,u,this.QUANTIFIERS_GRAPH)):this._quantified[u.id]=this._quantifier(this._blankNode().value),this._readQuantifierPunctuation}_readQuantifierPunctuation(e){return e.type===","?this._readQuantifierList:(this._explicitQuantifiers&&(this._emit(this._subject,this.RDF_REST,this.RDF_NIL,this.QUANTIFIERS_GRAPH),this._subject=null),this._readCallback=this._getContextEndReader(),this._readCallback(e))}_getPathReader(e){return this._afterPath=e,this._readPath}_readPath(e){switch(e.type){case"!":return this._readForwardPath;case"^":return this._readBackwardPath;default:const u=this._contextStack,s=u.length&&u[u.length-1];if(s&&s.type==="item"){const n=this._subject;this._restoreContext("item",e),this._emit(this._subject,this.RDF_FIRST,n,this._graph)}return this._afterPath(e)}}_readForwardPath(e){let u,s;const n=this._blankNode();if((s=this._readEntity(e))!==void 0)return this._predicate===null?(u=this._subject,this._subject=n):(u=this._object,this._object=n),this._emit(u,s,n,this._graph),this._readPath}_readBackwardPath(e){const u=this._blankNode();let s,n;if((s=this._readEntity(e))!==void 0)return this._predicate===null?(n=this._subject,this._subject=u):(n=this._object,this._object=u),this._emit(u,s,n,this._graph),this._readPath}_readRDFStarTailOrGraph(e){return e.type!==">>"?this._supportsQuads&&this._graph===null&&(this._graph=this._readEntity(e))!==void 0?this._readRDFStarTail:this._error(`Expected >> to follow "${this._object.id}"`,e):this._readRDFStarTail(e)}_readRDFStarTail(e){if(e.type!==">>")return this._error(`Expected >> but got ${e.type}`,e);const u=this._quad(this._subject,this._predicate,this._object,this._graph||this.DEFAULTGRAPH);return this._restoreContext("<<",e),this._subject===null?(this._subject=u,this._readPredicate):(this._object=u,this._getContextEndReader())}_getContextEndReader(){const e=this._contextStack;if(!e.length)return this._readPunctuation;switch(e[e.length-1].type){case"blank":return this._readBlankNodeTail;case"list":return this._readListItem;case"formula":return this._readFormulaTail;case"<<":return this._readRDFStarTailOrGraph}}_emit(e,u,s,n){this._callback(null,this._quad(e,u,s,n||this.DEFAULTGRAPH))}_error(e,u){const s=new Error(`${e} on line ${u.line}.`);s.context={token:u,line:u.line,previousToken:this._lexer.previousToken},this._callback(s),this._callback=pv}_resolveIRI(e){return/^[a-z][a-z0-9+.-]*:/i.test(e)?e:this._resolveRelativeIRI(e)}_resolveRelativeIRI(e){if(!e.length)return this._base;switch(e[0]){case"#":return this._base+e;case"?":return this._base.replace(/(?:\?.*)?$/,e);case"/":return(e[1]==="/"?this._baseScheme:this._baseRoot)+this._removeDotSegments(e);default:return/^[^/:]*:/.test(e)?null:this._removeDotSegments(this._basePath+e)}}_removeDotSegments(e){if(!/(^|\/)\.\.?($|[/#?])/.test(e))return e;const u=e.length;let s="",n=-1,r=-1,a=0,o="/";for(;n=r&&(s=s.substr(0,a)),o!=="/")return`${s}/${e.substr(n+1)}`;a=n+1}}}o=e[++n]}return s+e.substring(a)}parse(e,u,s){if(this._readCallback=this._readInTopContext,this._sparqlStyle=!1,this._prefixes=Object.create(null),this._prefixes._=this._blankNodePrefix?this._blankNodePrefix.substr(2):`b${tD++}_`,this._prefixCallback=s||pv,this._inversePredicate=!1,this._quantified=Object.create(null),!u){const n=[];let r;if(this._callback=(a,o)=>{a?r=a:o&&n.push(o)},this._lexer.tokenize(e).every(a=>this._readCallback=this._readCallback(a)),r)throw r;return n}this._callback=u,this._lexer.tokenize(e,(n,r)=>{n!==null?(this._callback(n),this._callback=pv):this._readCallback&&(this._readCallback=this._readCallback(r))})}}function pv(){}function Pq(t,e){const u=e.namedNode;t._namedNode=u,t._blankNode=e.blankNode,t._literal=e.literal,t._variable=e.variable,t._quad=e.quad,t.DEFAULTGRAPH=e.defaultGraph(),t.RDF_FIRST=u(cn.rdf.first),t.RDF_REST=u(cn.rdf.rest),t.RDF_NIL=u(cn.rdf.nil),t.N3_FORALL=u(cn.r.forAll),t.N3_FORSOME=u(cn.r.forSome),t.ABBREVIATIONS={a:u(cn.rdf.type),"=":u(cn.owl.sameAs),">":u(cn.log.implies)},t.QUANTIFIERS_GRAPH=u("urn:n3:quantifiers")}Pq(Qb.prototype,su);function LW(t){return!!t&&t.termType==="NamedNode"}function MW(t){return!!t&&t.termType==="BlankNode"}function FW(t){return!!t&&t.termType==="Literal"}function qW(t){return!!t&&t.termType==="Variable"}function Y0(t){return!!t&&t.termType==="DefaultGraph"}function BW(t){return Y0(t.graph)}function UW(t,e){return Dq({"":t.value||t},e)("")}function Dq(t,e){const u=Object.create(null);for(const n in t)s(n,t[n]);e=e||su;function s(n,r){if(typeof r=="string"){const a=Object.create(null);u[n]=o=>a[o]||(a[o]=e.namedNode(r+o))}else if(!(n in u))throw new Error(`Unknown prefix: ${n}`);return u[n]}return s}const Nq=Object.freeze(Object.defineProperty({__proto__:null,inDefaultGraph:BW,isBlankNode:MW,isDefaultGraph:Y0,isLiteral:FW,isNamedNode:LW,isVariable:qW,prefix:UW,prefixes:Dq},Symbol.toStringTag,{value:"Module"})),Rl=su.defaultGraph(),{rdf:HW,xsd:bo}=cn,rD=/["\\\t\n\r\b\f\u0000-\u0019\ud800-\udbff]/,nD=/["\\\t\n\r\b\f\u0000-\u0019]|[\ud800-\udbff][\udc00-\udfff]/g,$W={"\\":"\\\\",'"':'\\"'," ":"\\t","\n":"\\n","\r":"\\r","\b":"\\b","\f":"\\f"};class xl extends Ji{equals(e){return e===this}}class kT{constructor(e,u){if(this._prefixRegex=/$0^/,e&&typeof e.write!="function"&&(u=e,e=null),u=u||{},this._lists=u.lists,e)this._outputStream=e,this._endStream=u.end===void 0?!0:!!u.end;else{let s="";this._outputStream={write(n,r,a){s+=n,a&&a()},end:n=>{n&&n(null,s)}},this._endStream=!0}this._subject=null,/triple|quad/i.test(u.format)?(this._lineMode=!0,this._writeQuad=this._writeQuadLine):(this._lineMode=!1,this._graph=Rl,this._prefixIRIs=Object.create(null),u.prefixes&&this.addPrefixes(u.prefixes),u.baseIRI&&(this._baseMatcher=new RegExp(`^${aD(u.baseIRI)}${u.baseIRI.endsWith("/")?"":"[#?]"}`),this._baseLength=u.baseIRI.length))}get _inDefaultGraph(){return Rl.equals(this._graph)}_write(e,u){this._outputStream.write(e,"utf8",u)}_writeQuad(e,u,s,n,r){try{n.equals(this._graph)||(this._write((this._subject===null?"":this._inDefaultGraph?`. -`:` -} -`)+(Rl.equals(n)?"":`${this._encodeIriOrBlank(n)} { -`)),this._graph=n,this._subject=null),e.equals(this._subject)?u.equals(this._predicate)?this._write(`, ${this._encodeObject(s)}`,r):this._write(`; - ${this._encodePredicate(this._predicate=u)} ${this._encodeObject(s)}`,r):this._write(`${(this._subject===null?"":`. -`)+this._encodeSubject(this._subject=e)} ${this._encodePredicate(this._predicate=u)} ${this._encodeObject(s)}`,r)}catch(a){r&&r(a)}}_writeQuadLine(e,u,s,n,r){delete this._prefixMatch,this._write(this.quadToString(e,u,s,n),r)}quadToString(e,u,s,n){return`${this._encodeSubject(e)} ${this._encodeIriOrBlank(u)} ${this._encodeObject(s)}${n&&n.value?` ${this._encodeIriOrBlank(n)} . -`:` . -`}`}quadsToString(e){return e.map(u=>this.quadToString(u.subject,u.predicate,u.object,u.graph)).join("")}_encodeSubject(e){return e.termType==="Quad"?this._encodeQuad(e):this._encodeIriOrBlank(e)}_encodeIriOrBlank(e){if(e.termType!=="NamedNode")return this._lists&&e.value in this._lists&&(e=this.list(this._lists[e.value])),"id"in e?e.id:`_:${e.value}`;let u=e.value;this._baseMatcher&&this._baseMatcher.test(u)&&(u=u.substr(this._baseLength)),rD.test(u)&&(u=u.replace(nD,iD));const s=this._prefixRegex.exec(u);return s?s[1]?this._prefixIRIs[s[1]]+s[2]:u:`<${u}>`}_encodeLiteral(e){let u=e.value;if(rD.test(u)&&(u=u.replace(nD,iD)),e.language)return`"${u}"@${e.language}`;if(this._lineMode){if(e.datatype.value===bo.string)return`"${u}"`}else switch(e.datatype.value){case bo.string:return`"${u}"`;case bo.boolean:if(u==="true"||u==="false")return u;break;case bo.integer:if(/^[+-]?\d+$/.test(u))return u;break;case bo.decimal:if(/^[+-]?\d*\.\d+$/.test(u))return u;break;case bo.double:if(/^[+-]?(?:\d+\.\d*|\.?\d+)[eE][+-]?\d+$/.test(u))return u;break}return`"${u}"^^${this._encodeIriOrBlank(e.datatype)}`}_encodePredicate(e){return e.value===HW.type?"a":this._encodeIriOrBlank(e)}_encodeObject(e){switch(e.termType){case"Quad":return this._encodeQuad(e);case"Literal":return this._encodeLiteral(e);default:return this._encodeIriOrBlank(e)}}_encodeQuad({subject:e,predicate:u,object:s,graph:n}){return`<<${this._encodeSubject(e)} ${this._encodePredicate(u)} ${this._encodeObject(s)}${Y0(n)?"":` ${this._encodeIriOrBlank(n)}`}>>`}_blockedWrite(){throw new Error("Cannot write because the writer has been closed.")}addQuad(e,u,s,n,r){s===void 0?this._writeQuad(e.subject,e.predicate,e.object,e.graph,u):typeof n=="function"?this._writeQuad(e,u,s,Rl,n):this._writeQuad(e,u,s,n||Rl,r)}addQuads(e){for(let u=0;u. -`)}if(s){let n="",r="";for(const a in this._prefixIRIs)n+=n?`|${a}`:a,r+=(r?"|":"")+this._prefixIRIs[a];n=aD(n),this._prefixRegex=new RegExp(`^(?:${r})[^/]*$|^(${n})([_a-zA-Z][\\-_a-zA-Z0-9]*)$`)}this._write(s?` -`:"",u)}blank(e,u){let s=e,n,r;switch(e===void 0?s=[]:e.termType?s=[{predicate:e,object:u}]:"length"in e||(s=[e]),r=s.length){case 0:return new xl("[]");case 1:if(n=s[0],!(n.object instanceof xl))return new xl(`[ ${this._encodePredicate(n.predicate)} ${this._encodeObject(n.object)} ]`);default:let a="[";for(let o=0;o{u=null,e(s,n)});if(this._endStream)try{return this._outputStream.end(u)}catch{}u&&u()}}function iD(t){let e=$W[t];return e===void 0&&(t.length===1?(e=t.charCodeAt(0).toString(16),e="\\u0000".substr(0,6-e.length)+e):(e=((t.charCodeAt(0)-55296)*1024+t.charCodeAt(1)+9216).toString(16),e="\\U00000000".substr(0,10-e.length)+e)),e}function aD(t){return t.replace(/[\]\/\(\)\*\+\?\.\\\$]/g,"\\$&")}var Vb=Wt();class zT{constructor(e,u){this._size=0,this._graphs=Object.create(null),this._id=0,this._ids=Object.create(null),this._entities=Object.create(null),this._blankNodeIndex=0,!u&&e&&!e[0]&&(u=e,e=null),u=u||{},this._factory=u.factory||su,e&&this.addQuads(e)}_termFromId(e,u){if(e[0]==="."){const s=this._entities,n=e.split(".");return this._factory.quad(this._termFromId(s[n[1]]),this._termFromId(s[n[2]]),this._termFromId(s[n[3]]),n[4]&&this._termFromId(s[n[4]]))}return $s(e,u)}_termToNumericId(e){if(e.termType==="Quad"){const u=this._termToNumericId(e.subject),s=this._termToNumericId(e.predicate),n=this._termToNumericId(e.object);let r;return u&&s&&n&&(Y0(e.graph)||(r=this._termToNumericId(e.graph)))&&this._ids[r?`.${u}.${s}.${n}.${r}`:`.${u}.${s}.${n}`]}return this._ids[On(e)]}_termToNewNumericId(e){const u=e&&e.termType==="Quad"?`.${this._termToNewNumericId(e.subject)}.${this._termToNewNumericId(e.predicate)}.${this._termToNewNumericId(e.object)}${Y0(e.graph)?"":`.${this._termToNewNumericId(e.graph)}`}`:On(e);return this._ids[u]||(this._ids[this._entities[++this._id]=u]=this._id)}get size(){let e=this._size;if(e!==null)return e;e=0;const u=this._graphs;let s,n;for(const r in u)for(const a in s=u[r].subjects)for(const o in n=s[a])e+=Object.keys(n[o]).length;return this._size=e}_addToIndex(e,u,s,n){const r=e[u]||(e[u]={}),a=r[s]||(r[s]={}),o=n in a;return o||(a[n]=null),!o}_removeFromIndex(e,u,s,n){const r=e[u],a=r[s];delete a[n];for(const o in a)return;delete r[s];for(const o in r)return;delete e[u]}*_findInIndex(e,u,s,n,r,a,o,l){let c,d,h;const f=this._entities,p=this._termFromId(l,this._factory),y={subject:null,predicate:null,object:null};u&&((c=e,e={})[u]=c[u]);for(const b in e)if(d=e[b]){y[r]=this._termFromId(f[b],this._factory),s&&((c=d,d={})[s]=c[s]);for(const m in d)if(h=d[m]){y[a]=this._termFromId(f[m],this._factory);const g=n?n in h?[n]:[]:Object.keys(h);for(let v=0;v{s in u||(u[s]=!0,e(this._termFromId(this._entities[s],this._factory)))}}add(e){return this.addQuad(e),this}addQuad(e,u,s,n){u||(n=e.graph,s=e.object,u=e.predicate,e=e.subject),n=On(n);let r=this._graphs[n];r||(r=this._graphs[n]={subjects:{},predicates:{},objects:{}},Object.freeze(r)),e=this._termToNewNumericId(e),u=this._termToNewNumericId(u),s=this._termToNewNumericId(s);const a=this._addToIndex(r.subjects,e,u,s);return this._addToIndex(r.predicates,u,s,e),this._addToIndex(r.objects,s,e,u),this._size=null,a}addQuads(e){for(let u=0;u{this.addQuad(u)}),e}removeQuad(e,u,s,n){u||(n=e.graph,s=e.object,u=e.predicate,e=e.subject),n=On(n);const r=this._graphs;let a,o,l;if(!(e=e&&this._termToNumericId(e))||!(u=u&&this._termToNumericId(u))||!(s=s&&this._termToNumericId(s))||!(a=r[n])||!(o=a.subjects[e])||!(l=o[u])||!(s in l))return!1;this._removeFromIndex(a.subjects,e,u,s),this._removeFromIndex(a.predicates,u,s,e),this._removeFromIndex(a.objects,s,e,u),this._size!==null&&this._size--;for(e in a.subjects)return!0;return delete r[n],!0}removeQuads(e){for(let u=0;u{this.removeQuad(u)}),e}removeMatches(e,u,s,n){const r=new Vb.Readable({objectMode:!0});return r._read=()=>{for(const a of this.readQuads(e,u,s,n))r.push(a);r.push(null)},this.remove(r)}deleteGraph(e){return this.removeMatches(null,null,null,e)}getQuads(e,u,s,n){return[...this.readQuads(e,u,s,n)]}*readQuads(e,u,s,n){n=n&&On(n);const r=this._getGraphs(n);let a,o,l,c;if(!(e&&!(o=this._termToNumericId(e))||u&&!(l=this._termToNumericId(u))||s&&!(c=this._termToNumericId(s))))for(const d in r)(a=r[d])&&(o?c?yield*this._findInIndex(a.objects,c,o,l,"object","subject","predicate",d):yield*this._findInIndex(a.subjects,o,l,null,"subject","predicate","object",d):l?yield*this._findInIndex(a.predicates,l,c,null,"predicate","object","subject",d):c?yield*this._findInIndex(a.objects,c,null,null,"object","subject","predicate",d):yield*this._findInIndex(a.subjects,null,null,null,"subject","predicate","object",d))}match(e,u,s,n){return new GT(this,e,u,s,n)}countQuads(e,u,s,n){n=n&&On(n);const r=this._getGraphs(n);let a=0,o,l,c,d;if(e&&!(l=this._termToNumericId(e))||u&&!(c=this._termToNumericId(u))||s&&!(d=this._termToNumericId(s)))return 0;for(const h in r)(o=r[h])&&(e?s?a+=this._countInIndex(o.objects,d,l,c):a+=this._countInIndex(o.subjects,l,c,d):u?a+=this._countInIndex(o.predicates,c,d,l):a+=this._countInIndex(o.objects,d,l,c));return a}forEach(e,u,s,n,r){this.some(a=>(e(a),!1),u,s,n,r)}every(e,u,s,n,r){let a=!1;const o=!this.some(l=>(a=!0,!e(l)),u,s,n,r);return a&&o}some(e,u,s,n,r){for(const a of this.readQuads(u,s,n,r))if(e(a))return!0;return!1}getSubjects(e,u,s){const n=[];return this.forSubjects(r=>{n.push(r)},e,u,s),n}forSubjects(e,u,s,n){n=n&&On(n);const r=this._getGraphs(n);let a,o,l;if(e=this._uniqueEntities(e),!(u&&!(o=this._termToNumericId(u))||s&&!(l=this._termToNumericId(s))))for(n in r)(a=r[n])&&(o?l?this._loopBy2Keys(a.predicates,o,l,e):this._loopByKey1(a.subjects,o,e):l?this._loopByKey0(a.objects,l,e):this._loop(a.subjects,e))}getPredicates(e,u,s){const n=[];return this.forPredicates(r=>{n.push(r)},e,u,s),n}forPredicates(e,u,s,n){n=n&&On(n);const r=this._getGraphs(n);let a,o,l;if(e=this._uniqueEntities(e),!(u&&!(o=this._termToNumericId(u))||s&&!(l=this._termToNumericId(s))))for(n in r)(a=r[n])&&(o?l?this._loopBy2Keys(a.objects,l,o,e):this._loopByKey0(a.subjects,o,e):l?this._loopByKey1(a.predicates,l,e):this._loop(a.predicates,e))}getObjects(e,u,s){const n=[];return this.forObjects(r=>{n.push(r)},e,u,s),n}forObjects(e,u,s,n){n=n&&On(n);const r=this._getGraphs(n);let a,o,l;if(e=this._uniqueEntities(e),!(u&&!(o=this._termToNumericId(u))||s&&!(l=this._termToNumericId(s))))for(n in r)(a=r[n])&&(o?l?this._loopBy2Keys(a.subjects,o,l,e):this._loopByKey1(a.objects,o,e):l?this._loopByKey0(a.predicates,l,e):this._loop(a.objects,e))}getGraphs(e,u,s){const n=[];return this.forGraphs(r=>{n.push(r)},e,u,s),n}forGraphs(e,u,s,n){for(const r in this._graphs)this.some(a=>(e(a.graph),!0),u,s,n,r)}createBlankNode(e){let u,s;if(e)for(u=e=`_:${e}`,s=1;this._ids[u];)u=e+s++;else do u=`_:b${this._blankNodeIndex++}`;while(this._ids[u]);return this._ids[u]=++this._id,this._entities[this._id]=u,this._factory.blankNode(u.substr(2))}extractLists({remove:e=!1,ignoreErrors:u=!1}={}){const s={},n=u?()=>!0:(o,l)=>{throw new Error(`${o.value} ${l}`)},r=this.getQuads(null,cn.rdf.rest,cn.rdf.nil,null),a=e?[...r]:[];return r.forEach(o=>{const l=[];let c=!1,d,h;const f=o.graph;let p=o.subject;for(;p&&!c;){const y=this.getQuads(null,null,p,null),b=this.getQuads(p,null,null,null);let m,g=null,v=null,_=null;for(let w=0;w{switch(r){case"data":s=a;break;case"end":n=a;break}}},(r,a)=>{r&&this.emit("error",r)||a&&this.push(a)},(r,a)=>{this.emit("prefix",r,a)}),this._transform=(r,a,o)=>{s(r),o()},this._flush=r=>{n(),r()}}import(e){return e.on("data",u=>{this.write(u)}),e.on("end",()=>{this.end()}),e.on("error",u=>{this.emit("error",u)}),this}}class jq extends Vb.Transform{constructor(e){super({encoding:"utf8",writableObjectMode:!0});const u=this._writer=new kT({write:(s,n,r)=>{this.push(s),r&&r()},end:s=>{this.push(null),s&&s()}},e);this._transform=(s,n,r)=>{u.addQuad(s,r)},this._flush=s=>{u.end(s)}}import(e){return e.on("data",u=>{this.write(u)}),e.on("end",()=>{this.end()}),e.on("error",u=>{this.emit("error",u)}),e.on("prefix",(u,s)=>{this._writer.addPrefix(u,s)}),this}}const VW={Lexer:HT,Parser:Qb,Writer:kT,Store:zT,StreamParser:Cq,StreamWriter:jq,Util:Nq,DataFactory:su,Term:Ji,NamedNode:$b,Literal:$a,BlankNode:$T,Variable:QT,DefaultGraph:VT,Quad:K0,Triple:K0,termFromId:$s,termToId:On},kW=Object.freeze(Object.defineProperty({__proto__:null,BlankNode:$T,DataFactory:su,DefaultGraph:VT,Lexer:HT,Literal:$a,NamedNode:$b,Parser:Qb,Quad:K0,Store:zT,StreamParser:Cq,StreamWriter:jq,Term:Ji,Triple:K0,Util:Nq,Variable:QT,Writer:kT,default:VW,termFromId:$s,termToId:On},Symbol.toStringTag,{value:"Module"})),ts=Q3(kW);var sD;function zW(){if(sD)return Sl;sD=1,Object.defineProperty(Sl,"__esModule",{value:!0}),Sl.ActorRdfParseN3=void 0;const t=au(),e=ts;let u=class extends t.ActorRdfParseFixedMediaTypes{constructor(n){super(n)}async runHandle(n,r,a){var l;n.data.on("error",c=>o.emit("error",c));const o=n.data.pipe(new e.StreamParser({baseIRI:(l=n.metadata)==null?void 0:l.baseIRI,format:r.endsWith("n3")?r:`${r}*`}));return{data:o,metadata:{triples:r==="text/turtle"||r==="application/n-triples"||r==="text/n3"}}}};return Sl.ActorRdfParseN3=u,Sl}var oD;function GW(){return oD||(oD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(zW(),t)}(dv)),dv}var yv={},Il={},bv={},vs={},ws={},gv={},uD;function WW(){return uD||(uD=1,function(t){/** - * Character classes and associated utilities for the 5th edition of XML 1.0. - * - * @author Louis-Dominique Dubeau - * @license MIT - * @copyright Louis-Dominique Dubeau - */Object.defineProperty(t,"__esModule",{value:!0}),t.CHAR=` -\r -퟿-�𐀀-􏿿`,t.S=` \r -`,t.NAME_START_CHAR=":A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�𐀀-󯿿",t.NAME_CHAR="-"+t.NAME_START_CHAR+".0-9·̀-ͯ‿-⁀",t.CHAR_RE=new RegExp("^["+t.CHAR+"]$","u"),t.S_RE=new RegExp("^["+t.S+"]+$","u"),t.NAME_START_CHAR_RE=new RegExp("^["+t.NAME_START_CHAR+"]$","u"),t.NAME_CHAR_RE=new RegExp("^["+t.NAME_CHAR+"]$","u"),t.NAME_RE=new RegExp("^["+t.NAME_START_CHAR+"]["+t.NAME_CHAR+"]*$","u"),t.NMTOKEN_RE=new RegExp("^["+t.NAME_CHAR+"]+$","u");var e=9,u=10,s=13,n=32;t.S_LIST=[n,u,s,e];function r(c){return c>=n&&c<=55295||c===u||c===s||c===e||c>=57344&&c<=65533||c>=65536&&c<=1114111}t.isChar=r;function a(c){return c===n||c===u||c===s||c===e}t.isS=a;function o(c){return c>=65&&c<=90||c>=97&&c<=122||c===58||c===95||c===8204||c===8205||c>=192&&c<=214||c>=216&&c<=246||c>=248&&c<=767||c>=880&&c<=893||c>=895&&c<=8191||c>=8304&&c<=8591||c>=11264&&c<=12271||c>=12289&&c<=55295||c>=63744&&c<=64975||c>=65008&&c<=65533||c>=65536&&c<=983039}t.isNameStartChar=o;function l(c){return o(c)||c>=48&&c<=57||c===45||c===46||c===183||c>=768&&c<=879||c>=8255&&c<=8256}t.isNameChar=l}(gv)),gv}var mv={},cD;function JW(){return cD||(cD=1,function(t){/** - * Character classes and associated utilities for the 2nd edition of XML 1.1. - * - * @author Louis-Dominique Dubeau - * @license MIT - * @copyright Louis-Dominique Dubeau - */Object.defineProperty(t,"__esModule",{value:!0}),t.CHAR="-퟿-�𐀀-􏿿",t.RESTRICTED_CHAR="-\b\v\f--„†-Ÿ",t.S=` \r -`,t.NAME_START_CHAR=":A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�𐀀-󯿿",t.NAME_CHAR="-"+t.NAME_START_CHAR+".0-9·̀-ͯ‿-⁀",t.CHAR_RE=new RegExp("^["+t.CHAR+"]$","u"),t.RESTRICTED_CHAR_RE=new RegExp("^["+t.RESTRICTED_CHAR+"]$","u"),t.S_RE=new RegExp("^["+t.S+"]+$","u"),t.NAME_START_CHAR_RE=new RegExp("^["+t.NAME_START_CHAR+"]$","u"),t.NAME_CHAR_RE=new RegExp("^["+t.NAME_CHAR+"]$","u"),t.NAME_RE=new RegExp("^["+t.NAME_START_CHAR+"]["+t.NAME_CHAR+"]*$","u"),t.NMTOKEN_RE=new RegExp("^["+t.NAME_CHAR+"]+$","u");var e=9,u=10,s=13,n=32;t.S_LIST=[n,u,s,e];function r(h){return h>=1&&h<=55295||h>=57344&&h<=65533||h>=65536&&h<=1114111}t.isChar=r;function a(h){return h>=1&&h<=8||h===11||h===12||h>=14&&h<=31||h>=127&&h<=132||h>=134&&h<=159}t.isRestrictedChar=a;function o(h){return h===9||h===10||h===13||h>31&&h<127||h===133||h>159&&h<=55295||h>=57344&&h<=65533||h>=65536&&h<=1114111}t.isCharAndNotRestricted=o;function l(h){return h===n||h===u||h===s||h===e}t.isS=l;function c(h){return h>=65&&h<=90||h>=97&&h<=122||h===58||h===95||h===8204||h===8205||h>=192&&h<=214||h>=216&&h<=246||h>=248&&h<=767||h>=880&&h<=893||h>=895&&h<=8191||h>=8304&&h<=8591||h>=11264&&h<=12271||h>=12289&&h<=55295||h>=63744&&h<=64975||h>=65008&&h<=65533||h>=65536&&h<=983039}t.isNameStartChar=c;function d(h){return c(h)||h>=48&&h<=57||h===45||h===46||h===183||h>=768&&h<=879||h>=8255&&h<=8256}t.isNameChar=d}(mv)),mv}var _v={},lD;function XW(){return lD||(lD=1,function(t){/** - * Character class utilities for XML NS 1.0 edition 3. - * - * @author Louis-Dominique Dubeau - * @license MIT - * @copyright Louis-Dominique Dubeau - */Object.defineProperty(t,"__esModule",{value:!0}),t.NC_NAME_START_CHAR="A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�𐀀-󯿿",t.NC_NAME_CHAR="-"+t.NC_NAME_START_CHAR+".0-9·̀-ͯ‿-⁀",t.NC_NAME_START_CHAR_RE=new RegExp("^["+t.NC_NAME_START_CHAR+"]$","u"),t.NC_NAME_CHAR_RE=new RegExp("^["+t.NC_NAME_CHAR+"]$","u"),t.NC_NAME_RE=new RegExp("^["+t.NC_NAME_START_CHAR+"]["+t.NC_NAME_CHAR+"]*$","u");function e(s){return s>=65&&s<=90||s===95||s>=97&&s<=122||s>=192&&s<=214||s>=216&&s<=246||s>=248&&s<=767||s>=880&&s<=893||s>=895&&s<=8191||s>=8204&&s<=8205||s>=8304&&s<=8591||s>=11264&&s<=12271||s>=12289&&s<=55295||s>=63744&&s<=64975||s>=65008&&s<=65533||s>=65536&&s<=983039}t.isNCNameStartChar=e;function u(s){return e(s)||s===45||s===46||s>=48&&s<=57||s===183||s>=768&&s<=879||s>=8255&&s<=8256}t.isNCNameChar=u}(_v)),_v}var dD;function Lq(){if(dD)return ws;dD=1,Object.defineProperty(ws,"__esModule",{value:!0}),ws.SaxesParser=ws.EVENTS=void 0;const t=WW(),e=JW(),u=XW();var s=t.isS,n=t.isChar,r=t.isNameStartChar,a=t.isNameChar,o=t.S_LIST,l=t.NAME_RE,c=e.isChar,d=u.isNCNameStartChar,h=u.isNCNameChar,f=u.NC_NAME_RE;const p="http://www.w3.org/XML/1998/namespace",y="http://www.w3.org/2000/xmlns/",b={__proto__:null,xml:p,xmlns:y},m={__proto__:null,amp:"&",gt:">",lt:"<",quot:'"',apos:"'"},g=-1,v=-2,_=0,w=1,S=2,A=3,D=4,L=5,E=6,O=7,P=8,j=9,U=10,M=11,q=12,Q=13,Z=14,K=15,fe=16,X=17,he=18,xe=19,ie=20,ae=21,Oe=22,Ne=23,ge=24,de=25,oe=26,$=27,N=28,R=29,T=30,x=31,B=32,k=33,V=34,J=35,z=36,Y=37,te=38,ce=39,Ae=40,Ie=41,Ee=42,qe=43,G=44,F=9,H=10,re=13,be=32,Re=33,Ce=34,Qe=38,ke=39,me=45,Se=47,W=59,we=60,Te=61,Le=62,$e=63,We=91,tt=93,lt=133,ut=8232,le=Ke=>Ke===Ce||Ke===ke,C=[Ce,ke],ee=[...C,We,Le],pe=[...C,we,tt],De=[Te,$e,...o],Ue=[...o,Le,Qe,we];function Fe(Ke,ye,Pe){switch(ye){case"xml":Pe!==p&&Ke.fail(`xml prefix must be bound to ${p}.`);break;case"xmlns":Pe!==y&&Ke.fail(`xmlns prefix must be bound to ${y}.`);break}switch(Pe){case y:Ke.fail(ye===""?`the default namespace may not be set to ${Pe}.`:`may not assign a prefix (even "xmlns") to the URI ${y}.`);break;case p:switch(ye){case"xml":break;case"":Ke.fail(`the default namespace may not be set to ${Pe}.`);break;default:Ke.fail("may not assign the xml namespace to another prefix.")}break}}function Ye(Ke,ye){for(const Pe of Object.keys(ye))Fe(Ke,Pe,ye[Pe])}const Ve=Ke=>f.test(Ke),Je=Ke=>l.test(Ke),nt=0,yt=1,ft=2;ws.EVENTS=["xmldecl","text","processinginstruction","doctype","comment","opentagstart","attribute","opentag","closetag","cdata","error","end","ready"];const et={xmldecl:"xmldeclHandler",text:"textHandler",processinginstruction:"piHandler",doctype:"doctypeHandler",comment:"commentHandler",opentagstart:"openTagStartHandler",attribute:"attributeHandler",opentag:"openTagHandler",closetag:"closeTagHandler",cdata:"cdataHandler",error:"errorHandler",end:"endHandler",ready:"readyHandler"};class Ir{get closed(){return this._closed}constructor(ye){this.opt=ye??{},this.fragmentOpt=!!this.opt.fragment;const Pe=this.xmlnsOpt=!!this.opt.xmlns;if(this.trackPosition=this.opt.position!==!1,this.fileName=this.opt.fileName,Pe){this.nameStartCheck=d,this.nameCheck=h,this.isName=Ve,this.processAttribs=this.processAttribsNS,this.pushAttrib=this.pushAttribNS,this.ns=Object.assign({__proto__:null},b);const Me=this.opt.additionalNamespaces;Me!=null&&(Ye(this,Me),Object.assign(this.ns,Me))}else this.nameStartCheck=r,this.nameCheck=a,this.isName=Je,this.processAttribs=this.processAttribsPlain,this.pushAttrib=this.pushAttribPlain;this.stateTable=[this.sBegin,this.sBeginWhitespace,this.sDoctype,this.sDoctypeQuote,this.sDTD,this.sDTDQuoted,this.sDTDOpenWaka,this.sDTDOpenWakaBang,this.sDTDComment,this.sDTDCommentEnding,this.sDTDCommentEnded,this.sDTDPI,this.sDTDPIEnding,this.sText,this.sEntity,this.sOpenWaka,this.sOpenWakaBang,this.sComment,this.sCommentEnding,this.sCommentEnded,this.sCData,this.sCDataEnding,this.sCDataEnding2,this.sPIFirstChar,this.sPIRest,this.sPIBody,this.sPIEnding,this.sXMLDeclNameStart,this.sXMLDeclName,this.sXMLDeclEq,this.sXMLDeclValueStart,this.sXMLDeclValue,this.sXMLDeclSeparator,this.sXMLDeclEnding,this.sOpenTag,this.sOpenTagSlash,this.sAttrib,this.sAttribName,this.sAttribNameSawWhite,this.sAttribValue,this.sAttribValueQuoted,this.sAttribValueClosed,this.sAttribValueUnquoted,this.sCloseTag,this.sCloseTagSawWhite],this._init()}_init(){var ye;this.openWakaBang="",this.text="",this.name="",this.piTarget="",this.entity="",this.q=null,this.tags=[],this.tag=null,this.topNS=null,this.chunk="",this.chunkPosition=0,this.i=0,this.prevI=0,this.carriedFromPrevious=void 0,this.forbiddenState=nt,this.attribList=[];const{fragmentOpt:Pe}=this;this.state=Pe?Q:_,this.reportedTextBeforeRoot=this.reportedTextAfterRoot=this.closedRoot=this.sawRoot=Pe,this.xmlDeclPossible=!Pe,this.xmlDeclExpects=["version"],this.entityReturnState=void 0;let{defaultXMLVersion:Me}=this.opt;if(Me===void 0){if(this.opt.forceXMLVersion===!0)throw new Error("forceXMLVersion set but defaultXMLVersion is not set");Me="1.0"}this.setXMLVersion(Me),this.positionAtNewLine=0,this.doctype=!1,this._closed=!1,this.xmlDecl={version:void 0,encoding:void 0,standalone:void 0},this.line=1,this.column=0,this.ENTITIES=Object.create(m),(ye=this.readyHandler)===null||ye===void 0||ye.call(this)}get position(){return this.chunkPosition+this.i}get columnIndex(){return this.position-this.positionAtNewLine}on(ye,Pe){this[et[ye]]=Pe}off(ye){this[et[ye]]=void 0}makeError(ye){var Pe;let Me=(Pe=this.fileName)!==null&&Pe!==void 0?Pe:"";return this.trackPosition&&(Me.length>0&&(Me+=":"),Me+=`${this.line}:${this.column}`),Me.length>0&&(Me+=": "),new Error(Me+ye)}fail(ye){const Pe=this.makeError(ye),Me=this.errorHandler;if(Me===void 0)throw Pe;return Me(Pe),this}write(ye){if(this.closed)return this.fail("cannot write after close; assign an onready handler.");let Pe=!1;ye===null?(Pe=!0,ye=""):typeof ye=="object"&&(ye=ye.toString()),this.carriedFromPrevious!==void 0&&(ye=`${this.carriedFromPrevious}${ye}`,this.carriedFromPrevious=void 0);let Me=ye.length;const it=ye.charCodeAt(Me-1);!Pe&&(it===re||it>=55296&&it<=56319)&&(this.carriedFromPrevious=ye[Me-1],Me--,ye=ye.slice(0,Me));const{stateTable:at}=this;for(this.chunk=ye,this.i=0;this.i=ye.length)return g;const Me=ye.charCodeAt(Pe);if(this.column++,Me<55296){if(Me>=be||Me===F)return Me;switch(Me){case H:return this.line++,this.column=0,this.positionAtNewLine=this.position,H;case re:return ye.charCodeAt(Pe+1)===H&&(this.i=Pe+2),this.line++,this.column=0,this.positionAtNewLine=this.position,v;default:return this.fail("disallowed character."),Me}}if(Me>56319)return Me>=57344&&Me<=65533||this.fail("disallowed character."),Me;const it=65536+(Me-55296)*1024+(ye.charCodeAt(Pe+1)-56320);return this.i=Pe+2,it>1114111&&this.fail("disallowed character."),it}getCode11(){const{chunk:ye,i:Pe}=this;if(this.prevI=Pe,this.i=Pe+1,Pe>=ye.length)return g;const Me=ye.charCodeAt(Pe);if(this.column++,Me<55296){if(Me>31&&Me<127||Me>159&&Me!==ut||Me===F)return Me;switch(Me){case H:return this.line++,this.column=0,this.positionAtNewLine=this.position,H;case re:{const at=ye.charCodeAt(Pe+1);(at===H||at===lt)&&(this.i=Pe+2)}case lt:case ut:return this.line++,this.column=0,this.positionAtNewLine=this.position,v;default:return this.fail("disallowed character."),Me}}if(Me>56319)return Me>=57344&&Me<=65533||this.fail("disallowed character."),Me;const it=65536+(Me-55296)*1024+(ye.charCodeAt(Pe+1)-56320);return this.i=Pe+2,it>1114111&&this.fail("disallowed character."),it}getCodeNorm(){const ye=this.getCode();return ye===v?H:ye}unget(){this.i=this.prevI,this.column--}captureTo(ye){let{i:Pe}=this;const{chunk:Me}=this;for(;;){const it=this.getCode(),at=it===v,Tt=at?H:it;if(Tt===g||ye.includes(Tt))return this.text+=Me.slice(Pe,this.prevI),Tt;at&&(this.text+=`${Me.slice(Pe,this.prevI)} -`,Pe=this.i)}}captureToChar(ye){let{i:Pe}=this;const{chunk:Me}=this;for(;;){let it=this.getCode();switch(it){case v:this.text+=`${Me.slice(Pe,this.prevI)} -`,Pe=this.i,it=H;break;case g:return this.text+=Me.slice(Pe),!1}if(it===ye)return this.text+=Me.slice(Pe,this.prevI),!0}}captureNameChars(){const{chunk:ye,i:Pe}=this;for(;;){const Me=this.getCode();if(Me===g)return this.name+=ye.slice(Pe),g;if(!a(Me))return this.name+=ye.slice(Pe,this.prevI),Me===v?H:Me}}skipSpaces(){for(;;){const ye=this.getCodeNorm();if(ye===g||!s(ye))return ye}}setXMLVersion(ye){this.currentXMLVersion=ye,ye==="1.0"?(this.isChar=n,this.getCode=this.getCode10):(this.isChar=c,this.getCode=this.getCode11)}sBegin(){this.chunk.charCodeAt(0)===65279&&(this.i++,this.column++),this.state=w}sBeginWhitespace(){const ye=this.i,Pe=this.skipSpaces();switch(this.prevI!==ye&&(this.xmlDeclPossible=!1),Pe){case we:if(this.state=K,this.text.length!==0)throw new Error("no-empty text at start");break;case g:break;default:this.unget(),this.state=Q,this.xmlDeclPossible=!1}}sDoctype(){var ye;const Pe=this.captureTo(ee);switch(Pe){case Le:{(ye=this.doctypeHandler)===null||ye===void 0||ye.call(this,this.text),this.text="",this.state=Q,this.doctype=!0;break}case g:break;default:this.text+=String.fromCodePoint(Pe),Pe===We?this.state=D:le(Pe)&&(this.state=A,this.q=Pe)}}sDoctypeQuote(){const ye=this.q;this.captureToChar(ye)&&(this.text+=String.fromCodePoint(ye),this.q=null,this.state=S)}sDTD(){const ye=this.captureTo(pe);ye!==g&&(this.text+=String.fromCodePoint(ye),ye===tt?this.state=S:ye===we?this.state=E:le(ye)&&(this.state=L,this.q=ye))}sDTDQuoted(){const ye=this.q;this.captureToChar(ye)&&(this.text+=String.fromCodePoint(ye),this.state=D,this.q=null)}sDTDOpenWaka(){const ye=this.getCodeNorm();switch(this.text+=String.fromCodePoint(ye),ye){case Re:this.state=O,this.openWakaBang="";break;case $e:this.state=M;break;default:this.state=D}}sDTDOpenWakaBang(){const ye=String.fromCodePoint(this.getCodeNorm()),Pe=this.openWakaBang+=ye;this.text+=ye,Pe!=="-"&&(this.state=Pe==="--"?P:D,this.openWakaBang="")}sDTDComment(){this.captureToChar(me)&&(this.text+="-",this.state=j)}sDTDCommentEnding(){const ye=this.getCodeNorm();this.text+=String.fromCodePoint(ye),this.state=ye===me?U:P}sDTDCommentEnded(){const ye=this.getCodeNorm();this.text+=String.fromCodePoint(ye),ye===Le?this.state=D:(this.fail("malformed comment."),this.state=P)}sDTDPI(){this.captureToChar($e)&&(this.text+="?",this.state=q)}sDTDPIEnding(){const ye=this.getCodeNorm();this.text+=String.fromCodePoint(ye),ye===Le&&(this.state=D)}sText(){this.tags.length!==0?this.handleTextInRoot():this.handleTextOutsideRoot()}sEntity(){let{i:ye}=this;const{chunk:Pe}=this;e:for(;;)switch(this.getCode()){case v:this.entity+=`${Pe.slice(ye,this.prevI)} -`,ye=this.i;break;case W:{const{entityReturnState:Me}=this,it=this.entity+Pe.slice(ye,this.prevI);this.state=Me;let at;it===""?(this.fail("empty entity name."),at="&;"):(at=this.parseEntity(it),this.entity=""),(Me!==Q||this.textHandler!==void 0)&&(this.text+=at);break e}case g:this.entity+=Pe.slice(ye);break e}}sOpenWaka(){const ye=this.getCode();if(r(ye))this.state=V,this.unget(),this.xmlDeclPossible=!1;else switch(ye){case Se:this.state=qe,this.xmlDeclPossible=!1;break;case Re:this.state=fe,this.openWakaBang="",this.xmlDeclPossible=!1;break;case $e:this.state=Ne;break;default:this.fail("disallowed character in tag name"),this.state=Q,this.xmlDeclPossible=!1}}sOpenWakaBang(){switch(this.openWakaBang+=String.fromCodePoint(this.getCodeNorm()),this.openWakaBang){case"[CDATA[":!this.sawRoot&&!this.reportedTextBeforeRoot&&(this.fail("text data outside of root node."),this.reportedTextBeforeRoot=!0),this.closedRoot&&!this.reportedTextAfterRoot&&(this.fail("text data outside of root node."),this.reportedTextAfterRoot=!0),this.state=ie,this.openWakaBang="";break;case"--":this.state=X,this.openWakaBang="";break;case"DOCTYPE":this.state=S,(this.doctype||this.sawRoot)&&this.fail("inappropriately located doctype declaration."),this.openWakaBang="";break;default:this.openWakaBang.length>=7&&this.fail("incorrect syntax.")}}sComment(){this.captureToChar(me)&&(this.state=he)}sCommentEnding(){var ye;const Pe=this.getCodeNorm();Pe===me?(this.state=xe,(ye=this.commentHandler)===null||ye===void 0||ye.call(this,this.text),this.text=""):(this.text+=`-${String.fromCodePoint(Pe)}`,this.state=X)}sCommentEnded(){const ye=this.getCodeNorm();ye!==Le?(this.fail("malformed comment."),this.text+=`--${String.fromCodePoint(ye)}`,this.state=X):this.state=Q}sCData(){this.captureToChar(tt)&&(this.state=ae)}sCDataEnding(){const ye=this.getCodeNorm();ye===tt?this.state=Oe:(this.text+=`]${String.fromCodePoint(ye)}`,this.state=ie)}sCDataEnding2(){var ye;const Pe=this.getCodeNorm();switch(Pe){case Le:{(ye=this.cdataHandler)===null||ye===void 0||ye.call(this,this.text),this.text="",this.state=Q;break}case tt:this.text+="]";break;default:this.text+=`]]${String.fromCodePoint(Pe)}`,this.state=ie}}sPIFirstChar(){const ye=this.getCodeNorm();this.nameStartCheck(ye)?(this.piTarget+=String.fromCodePoint(ye),this.state=ge):ye===$e||s(ye)?(this.fail("processing instruction without a target."),this.state=ye===$e?oe:de):(this.fail("disallowed character in processing instruction name."),this.piTarget+=String.fromCodePoint(ye),this.state=ge)}sPIRest(){const{chunk:ye,i:Pe}=this;for(;;){const Me=this.getCodeNorm();if(Me===g){this.piTarget+=ye.slice(Pe);return}if(!this.nameCheck(Me)){this.piTarget+=ye.slice(Pe,this.prevI);const it=Me===$e;it||s(Me)?this.piTarget==="xml"?(this.xmlDeclPossible||this.fail("an XML declaration must be at the start of the document."),this.state=it?k:$):this.state=it?oe:de:(this.fail("disallowed character in processing instruction name."),this.piTarget+=String.fromCodePoint(Me));break}}}sPIBody(){if(this.text.length===0){const ye=this.getCodeNorm();ye===$e?this.state=oe:s(ye)||(this.text=String.fromCodePoint(ye))}else this.captureToChar($e)&&(this.state=oe)}sPIEnding(){var ye;const Pe=this.getCodeNorm();if(Pe===Le){const{piTarget:Me}=this;Me.toLowerCase()==="xml"&&this.fail("the XML declaration must appear at the start of the document."),(ye=this.piHandler)===null||ye===void 0||ye.call(this,{target:Me,body:this.text}),this.piTarget=this.text="",this.state=Q}else Pe===$e?this.text+="?":(this.text+=`?${String.fromCodePoint(Pe)}`,this.state=de);this.xmlDeclPossible=!1}sXMLDeclNameStart(){const ye=this.skipSpaces();if(ye===$e){this.state=k;return}ye!==g&&(this.state=N,this.name=String.fromCodePoint(ye))}sXMLDeclName(){const ye=this.captureTo(De);if(ye===$e){this.state=k,this.name+=this.text,this.text="",this.fail("XML declaration is incomplete.");return}if(s(ye)||ye===Te){if(this.name+=this.text,this.text="",!this.xmlDeclExpects.includes(this.name))switch(this.name.length){case 0:this.fail("did not expect any more name/value pairs.");break;case 1:this.fail(`expected the name ${this.xmlDeclExpects[0]}.`);break;default:this.fail(`expected one of ${this.xmlDeclExpects.join(", ")}`)}this.state=ye===Te?T:R}}sXMLDeclEq(){const ye=this.getCodeNorm();if(ye===$e){this.state=k,this.fail("XML declaration is incomplete.");return}s(ye)||(ye!==Te&&this.fail("value required."),this.state=T)}sXMLDeclValueStart(){const ye=this.getCodeNorm();if(ye===$e){this.state=k,this.fail("XML declaration is incomplete.");return}s(ye)||(le(ye)?this.q=ye:(this.fail("value must be quoted."),this.q=be),this.state=x)}sXMLDeclValue(){const ye=this.captureTo([this.q,$e]);if(ye===$e){this.state=k,this.text="",this.fail("XML declaration is incomplete.");return}if(ye===g)return;const Pe=this.text;switch(this.text="",this.name){case"version":{this.xmlDeclExpects=["encoding","standalone"];const Me=Pe;this.xmlDecl.version=Me,/^1\.[0-9]+$/.test(Me)?this.opt.forceXMLVersion||this.setXMLVersion(Me):this.fail("version number must match /^1\\.[0-9]+$/.");break}case"encoding":/^[A-Za-z][A-Za-z0-9._-]*$/.test(Pe)||this.fail("encoding value must match /^[A-Za-z0-9][A-Za-z0-9._-]*$/."),this.xmlDeclExpects=["standalone"],this.xmlDecl.encoding=Pe;break;case"standalone":Pe!=="yes"&&Pe!=="no"&&this.fail('standalone value must match "yes" or "no".'),this.xmlDeclExpects=[],this.xmlDecl.standalone=Pe;break}this.name="",this.state=B}sXMLDeclSeparator(){const ye=this.getCodeNorm();if(ye===$e){this.state=k;return}s(ye)||(this.fail("whitespace required."),this.unget()),this.state=$}sXMLDeclEnding(){var ye;this.getCodeNorm()===Le?(this.piTarget!=="xml"?this.fail("processing instructions are not allowed before root."):this.name!=="version"&&this.xmlDeclExpects.includes("version")&&this.fail("XML declaration must contain a version."),(ye=this.xmldeclHandler)===null||ye===void 0||ye.call(this,this.xmlDecl),this.name="",this.piTarget=this.text="",this.state=Q):this.fail("The character ? is disallowed anywhere in XML declarations."),this.xmlDeclPossible=!1}sOpenTag(){var ye;const Pe=this.captureNameChars();if(Pe===g)return;const Me=this.tag={name:this.name,attributes:Object.create(null)};switch(this.name="",this.xmlnsOpt&&(this.topNS=Me.ns=Object.create(null)),(ye=this.openTagStartHandler)===null||ye===void 0||ye.call(this,Me),this.sawRoot=!0,!this.fragmentOpt&&this.closedRoot&&this.fail("documents may contain only one root."),Pe){case Le:this.openTag();break;case Se:this.state=J;break;default:s(Pe)||this.fail("disallowed character in tag name."),this.state=z}}sOpenTagSlash(){this.getCode()===Le?this.openSelfClosingTag():(this.fail("forward-slash in opening tag not followed by >."),this.state=z)}sAttrib(){const ye=this.skipSpaces();ye!==g&&(r(ye)?(this.unget(),this.state=Y):ye===Le?this.openTag():ye===Se?this.state=J:this.fail("disallowed character in attribute name."))}sAttribName(){const ye=this.captureNameChars();ye===Te?this.state=ce:s(ye)?this.state=te:ye===Le?(this.fail("attribute without value."),this.pushAttrib(this.name,this.name),this.name=this.text="",this.openTag()):ye!==g&&this.fail("disallowed character in attribute name.")}sAttribNameSawWhite(){const ye=this.skipSpaces();switch(ye){case g:return;case Te:this.state=ce;break;default:this.fail("attribute without value."),this.text="",this.name="",ye===Le?this.openTag():r(ye)?(this.unget(),this.state=Y):(this.fail("disallowed character in attribute name."),this.state=z)}}sAttribValue(){const ye=this.getCodeNorm();le(ye)?(this.q=ye,this.state=Ae):s(ye)||(this.fail("unquoted attribute value."),this.state=Ee,this.unget())}sAttribValueQuoted(){const{q:ye,chunk:Pe}=this;let{i:Me}=this;for(;;)switch(this.getCode()){case ye:this.pushAttrib(this.name,this.text+Pe.slice(Me,this.prevI)),this.name=this.text="",this.q=null,this.state=Ie;return;case Qe:this.text+=Pe.slice(Me,this.prevI),this.state=Z,this.entityReturnState=Ae;return;case H:case v:case F:this.text+=`${Pe.slice(Me,this.prevI)} `,Me=this.i;break;case we:this.text+=Pe.slice(Me,this.prevI),this.fail("disallowed character.");return;case g:this.text+=Pe.slice(Me);return}}sAttribValueClosed(){const ye=this.getCodeNorm();s(ye)?this.state=z:ye===Le?this.openTag():ye===Se?this.state=J:r(ye)?(this.fail("no whitespace between attributes."),this.unget(),this.state=Y):this.fail("disallowed character in attribute name.")}sAttribValueUnquoted(){const ye=this.captureTo(Ue);switch(ye){case Qe:this.state=Z,this.entityReturnState=Ee;break;case we:this.fail("disallowed character.");break;case g:break;default:this.text.includes("]]>")&&this.fail('the string "]]>" is disallowed in char data.'),this.pushAttrib(this.name,this.text),this.name=this.text="",ye===Le?this.openTag():this.state=z}}sCloseTag(){const ye=this.captureNameChars();ye===Le?this.closeTag():s(ye)?this.state=G:ye!==g&&this.fail("disallowed character in closing tag.")}sCloseTagSawWhite(){switch(this.skipSpaces()){case Le:this.closeTag();break;case g:break;default:this.fail("disallowed character in closing tag.")}}handleTextInRoot(){let{i:ye,forbiddenState:Pe}=this;const{chunk:Me,textHandler:it}=this;e:for(;;)switch(this.getCode()){case we:{if(this.state=K,it!==void 0){const{text:at}=this,Tt=Me.slice(ye,this.prevI);at.length!==0?(it(at+Tt),this.text=""):Tt.length!==0&&it(Tt)}Pe=nt;break e}case Qe:this.state=Z,this.entityReturnState=Q,it!==void 0&&(this.text+=Me.slice(ye,this.prevI)),Pe=nt;break e;case tt:switch(Pe){case nt:Pe=yt;break;case yt:Pe=ft;break;case ft:break;default:throw new Error("impossible state")}break;case Le:Pe===ft&&this.fail('the string "]]>" is disallowed in char data.'),Pe=nt;break;case v:it!==void 0&&(this.text+=`${Me.slice(ye,this.prevI)} -`),ye=this.i,Pe=nt;break;case g:it!==void 0&&(this.text+=Me.slice(ye));break e;default:Pe=nt}this.forbiddenState=Pe}handleTextOutsideRoot(){let{i:ye}=this;const{chunk:Pe,textHandler:Me}=this;let it=!1;e:for(;;){const at=this.getCode();switch(at){case we:{if(this.state=K,Me!==void 0){const{text:Tt}=this,Vt=Pe.slice(ye,this.prevI);Tt.length!==0?(Me(Tt+Vt),this.text=""):Vt.length!==0&&Me(Vt)}break e}case Qe:this.state=Z,this.entityReturnState=Q,Me!==void 0&&(this.text+=Pe.slice(ye,this.prevI)),it=!0;break e;case v:Me!==void 0&&(this.text+=`${Pe.slice(ye,this.prevI)} -`),ye=this.i;break;case g:Me!==void 0&&(this.text+=Pe.slice(ye));break e;default:s(at)||(it=!0)}}it&&(!this.sawRoot&&!this.reportedTextBeforeRoot&&(this.fail("text data outside of root node."),this.reportedTextBeforeRoot=!0),this.closedRoot&&!this.reportedTextAfterRoot&&(this.fail("text data outside of root node."),this.reportedTextAfterRoot=!0))}pushAttribNS(ye,Pe){var Me;const{prefix:it,local:at}=this.qname(ye),Tt={name:ye,prefix:it,local:at,value:Pe};if(this.attribList.push(Tt),(Me=this.attributeHandler)===null||Me===void 0||Me.call(this,Tt),it==="xmlns"){const Vt=Pe.trim();this.currentXMLVersion==="1.0"&&Vt===""&&this.fail("invalid attempt to undefine prefix in XML 1.0"),this.topNS[at]=Vt,Fe(this,at,Vt)}else if(ye==="xmlns"){const Vt=Pe.trim();this.topNS[""]=Vt,Fe(this,"",Vt)}}pushAttribPlain(ye,Pe){var Me;const it={name:ye,value:Pe};this.attribList.push(it),(Me=this.attributeHandler)===null||Me===void 0||Me.call(this,it)}end(){var ye,Pe;this.sawRoot||this.fail("document must contain a root element.");const{tags:Me}=this;for(;Me.length>0;){const at=Me.pop();this.fail(`unclosed tag: ${at.name}`)}this.state!==_&&this.state!==Q&&this.fail("unexpected end.");const{text:it}=this;return it.length!==0&&((ye=this.textHandler)===null||ye===void 0||ye.call(this,it),this.text=""),this._closed=!0,(Pe=this.endHandler)===null||Pe===void 0||Pe.call(this),this._init(),this}resolve(ye){var Pe,Me;let it=this.topNS[ye];if(it!==void 0)return it;const{tags:at}=this;for(let Tt=at.length-1;Tt>=0;Tt--)if(it=at[Tt].ns[ye],it!==void 0)return it;return it=this.ns[ye],it!==void 0?it:(Me=(Pe=this.opt).resolvePrefix)===null||Me===void 0?void 0:Me.call(Pe,ye)}qname(ye){const Pe=ye.indexOf(":");if(Pe===-1)return{prefix:"",local:ye};const Me=ye.slice(Pe+1),it=ye.slice(0,Pe);return(it===""||Me===""||Me.includes(":"))&&this.fail(`malformed name: ${ye}.`),{prefix:it,local:Me}}processAttribsNS(){var ye;const{attribList:Pe}=this,Me=this.tag;{const{prefix:Tt,local:Vt}=this.qname(Me.name);Me.prefix=Tt,Me.local=Vt;const tr=Me.uri=(ye=this.resolve(Tt))!==null&&ye!==void 0?ye:"";Tt!==""&&(Tt==="xmlns"&&this.fail('tags may not have "xmlns" as prefix.'),tr===""&&(this.fail(`unbound namespace prefix: ${JSON.stringify(Tt)}.`),Me.uri=Tt))}if(Pe.length===0)return;const{attributes:it}=Me,at=new Set;for(const Tt of Pe){const{name:Vt,prefix:tr,local:di}=Tt;let yn,or;tr===""?(yn=Vt==="xmlns"?y:"",or=Vt):(yn=this.resolve(tr),yn===void 0&&(this.fail(`unbound namespace prefix: ${JSON.stringify(tr)}.`),yn=tr),or=`{${yn}}${di}`),at.has(or)&&this.fail(`duplicate attribute: ${or}.`),at.add(or),Tt.uri=yn,it[Vt]=Tt}this.attribList=[]}processAttribsPlain(){const{attribList:ye}=this,Pe=this.tag.attributes;for(const{name:Me,value:it}of ye)Pe[Me]!==void 0&&this.fail(`duplicate attribute: ${Me}.`),Pe[Me]=it;this.attribList=[]}openTag(){var ye;this.processAttribs();const{tags:Pe}=this,Me=this.tag;Me.isSelfClosing=!1,(ye=this.openTagHandler)===null||ye===void 0||ye.call(this,Me),Pe.push(Me),this.state=Q,this.name=""}openSelfClosingTag(){var ye,Pe,Me;this.processAttribs();const{tags:it}=this,at=this.tag;at.isSelfClosing=!0,(ye=this.openTagHandler)===null||ye===void 0||ye.call(this,at),(Pe=this.closeTagHandler)===null||Pe===void 0||Pe.call(this,at),(this.tag=(Me=it[it.length-1])!==null&&Me!==void 0?Me:null)===null&&(this.closedRoot=!0),this.state=Q,this.name=""}closeTag(){const{tags:ye,name:Pe}=this;if(this.state=Q,this.name="",Pe===""){this.fail("weird empty close tag."),this.text+="";return}const Me=this.closeTagHandler;let it=ye.length;for(;it-- >0;){const at=this.tag=ye.pop();if(this.topNS=at.ns,Me==null||Me(at),at.name===Pe)break;this.fail("unexpected close tag.")}it===0?this.closedRoot=!0:it<0&&(this.fail(`unmatched closing tag: ${Pe}.`),this.text+=``)}parseEntity(ye){if(ye[0]!=="#"){const Me=this.ENTITIES[ye];return Me!==void 0?Me:(this.fail(this.isName(ye)?"undefined entity.":"disallowed character in entity name."),`&${ye};`)}let Pe=NaN;return ye[1]==="x"&&/^#x[0-9a-f]+$/i.test(ye)?Pe=parseInt(ye.slice(2),16):/^#[0-9]+$/.test(ye)&&(Pe=parseInt(ye.slice(1),10)),this.isChar(Pe)?String.fromCodePoint(Pe):(this.fail("malformed character entity."),`&${ye};`)}}return ws.SaxesParser=Ir,ws}var Pl={},fD;function KW(){if(fD)return Pl;fD=1,Object.defineProperty(Pl,"__esModule",{value:!0}),Pl.ParseError=void 0;let t=class extends Error{constructor(u,s){const n=u.saxParser;super(u.trackPosition?`Line ${n.line} column ${n.column+1}: ${s}`:s)}};return Pl.ParseError=t,Pl}var vv={},wv={},hD;function YW(){return hD||(hD=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.validateIri=t.IriValidationStrategy=void 0;function e(){const o="[!$&'()*+,;=]",l="%[a-fA-F0-9]{2}",c="([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])",d=`${c}\\.${c}\\.${c}\\.${c}`,h="[a-fA-F0-9]{1,4}",f=`(${h}:${h}|${d})`,p=`((${h}:){6}${f}|::(${h}:){5}${f}|(${h})?::(${h}:){4}${f}|((${h}:){0,1}${h})?::(${h}:){3}${f}|((${h}:){0,2}${h})?::(${h}:){2}${f}|((${h}:){0,3}${h})?::${h}:${f}|((${h}:){0,4}${h})?::${f}|((${h}:){0,5}${h})?::${h}|((${h}:){0,6}${h})?::)`,y=`v[a-fA-F0-9]+\\.(${o}|${o}|":)+`,b=`\\[(${p}|${y})\\]`,m="[0-9]*",g="[a-zA-Z][a-zA-Z0-9+\\-.]*",_="[-󰀀-󿿽􀀀-􏿽]",A="[a-zA-Z0-9\\-._~ -퟿豈-﷏ﷰ-￯𐀀-🿽𠀀-𯿽𰀀-𿿽񀀀-񏿽񐀀-񟿽񠀀-񯿽񰀀-񿿽򀀀-򏿽򐀀-򟿽򠀀-򯿽򰀀-򿿽󀀀-󏿽󐀀-󟿽󡀀-󯿽]",D=`(${A}|${l}|${o}|[:@])*`,L=`(${D}|[\\/?])*`,E=`(${D}|${_}|[\\/?])*`,O=`(${D})+`,P=`(${D})*`,j="",U=`${O}(\\/${P})*`,M=`\\/(${O}(\\/${P})*)?`,q=`(\\/${P})*`,Q=`(${A}|${l}|${o})*`,Z=`(${b}|${d}|${Q})`,X=`(\\/\\/${`(${`(${A}|${l}|${o}|:)*`}@)?${Z}(:${m})?`}${q}|${M}|${U}|${j})`,he=`^${g}:${X}(\\?${E})?(#${L})?$`;return new RegExp(he,"u")}const u=e(),s=/^[A-Za-z][\d+-.A-Za-z]*:[^\u0000-\u0020"<>\\^`{|}]*$/u;var n;(function(a){a.Strict="strict",a.Pragmatic="pragmatic",a.None="none"})(n=t.IriValidationStrategy||(t.IriValidationStrategy={}));function r(a,o=n.Strict){switch(o){case n.Strict:return u.test(a)?void 0:new Error(`Invalid IRI according to RFC 3987: '${a}'`);case n.Pragmatic:return s.test(a)?void 0:new Error(`Invalid IRI according to RDF Turtle: '${a}'`);case n.None:return;default:return new Error(`Not supported validation strategy "${o}"`)}}t.validateIri=r}(wv)),wv}var pD;function ZW(){return pD||(pD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(YW(),t)}(vv)),vv}var yD;function eJ(){if(yD)return vs;yD=1,Object.defineProperty(vs,"__esModule",{value:!0}),vs.ParseType=vs.RdfXmlParser=void 0;const t=Pi(),e=Lq(),u=Wt(),s=KW(),n=Et(),r=ZW();let a=class Tr extends u.Transform{constructor(c){super({readableObjectMode:!0}),this.activeTagStack=[],this.nodeIds={},c&&(Object.assign(this,c),this.options=c),this.dataFactory||(this.dataFactory=new n.DataFactory),this.baseIRI||(this.baseIRI=""),this.defaultGraph||(this.defaultGraph=this.dataFactory.defaultGraph()),this.validateUri!==!1&&(this.validateUri=!0),this.iriValidationStrategy||(this.iriValidationStrategy=this.validateUri?r.IriValidationStrategy.Pragmatic:r.IriValidationStrategy.None),this.saxParser=new e.SaxesParser({xmlns:!0,position:this.trackPosition}),this.attachSaxListeners()}import(c){const d=new u.PassThrough({readableObjectMode:!0});c.on("error",f=>h.emit("error",f)),c.on("data",f=>d.push(f)),c.on("end",()=>d.push(null));const h=d.pipe(new Tr(this.options));return h}_transform(c,d,h){try{this.saxParser.write(c)}catch(f){return h(f)}h()}newParseError(c){return new s.ParseError(this,c)}valueToUri(c,d){return this.uriToNamedNode((0,t.resolve)(c,d.baseIRI))}uriToNamedNode(c){const d=(0,r.validateIri)(c,this.iriValidationStrategy);if(d instanceof Error)throw this.newParseError(d.message);return this.dataFactory.namedNode(c)}validateNcname(c){if(!Tr.NCNAME_MATCHER.test(c))throw this.newParseError(`Not a valid NCName: ${c}`)}attachSaxListeners(){this.saxParser.on("error",c=>this.emit("error",c)),this.saxParser.on("opentag",this.onTag.bind(this)),this.saxParser.on("text",this.onText.bind(this)),this.saxParser.on("cdata",this.onText.bind(this)),this.saxParser.on("closetag",this.onCloseTag.bind(this)),this.saxParser.on("doctype",this.onDoctype.bind(this))}onTag(c){const d=this.activeTagStack.length?this.activeTagStack[this.activeTagStack.length-1]:null;let h=o.RESOURCE;if(d&&(d.hadChildren=!0,h=d.childrenParseType),d&&d.childrenStringTags){const p=c.name;let y="";for(const v in c.attributes)y+=` ${v}="${c.attributes[v].value}"`;const m=`<${`${p}${y}`}>`;d.childrenStringTags.push(m);const g={childrenStringTags:d.childrenStringTags};g.childrenStringEmitClosingTag=``,this.activeTagStack.push(g);return}const f={};d?(f.language=d.language,f.baseIRI=d.baseIRI):f.baseIRI=this.baseIRI,this.activeTagStack.push(f),h===o.RESOURCE?this.onTagResource(c,f,d,!d):this.onTagProperty(c,f,d)}onTagResource(c,d,h,f){d.childrenParseType=o.PROPERTY;let p=!0;if(c.uri===Tr.RDF){if(!f&&Tr.FORBIDDEN_NODE_ELEMENTS.indexOf(c.local)>=0)throw this.newParseError(`Illegal node element name: ${c.local}`);switch(c.local){case"RDF":d.childrenParseType=o.RESOURCE;case"Description":p=!1}}const y=[],b=[];let m=null,g=!1,v=!1,_=null;for(const w in c.attributes){const S=c.attributes[w];if(h&&S.uri===Tr.RDF)switch(S.local){case"about":if(m)throw this.newParseError(`Only one of rdf:about, rdf:nodeID and rdf:ID can be present, while ${S.value} and ${m} where found.`);m=S.value;continue;case"ID":if(m)throw this.newParseError(`Only one of rdf:about, rdf:nodeID and rdf:ID can be present, while ${S.value} and ${m} where found.`);this.validateNcname(S.value),m="#"+S.value,g=!0;continue;case"nodeID":if(m)throw this.newParseError(`Only one of rdf:about, rdf:nodeID and rdf:ID can be present, while ${S.value} and ${m} where found.`);this.validateNcname(S.value),m=S.value,v=!0;continue;case"bagID":throw this.newParseError("rdf:bagID is not supported.");case"type":_=S.value;continue;case"aboutEach":throw this.newParseError("rdf:aboutEach is not supported.");case"aboutEachPrefix":throw this.newParseError("rdf:aboutEachPrefix is not supported.");case"li":throw this.newParseError("rdf:li on node elements are not supported.")}else if(S.uri===Tr.XML){if(S.local==="lang"){d.language=S.value===""?null:S.value.toLowerCase();continue}else if(S.local==="base"){d.baseIRI=(0,t.resolve)(S.value,d.baseIRI);continue}}S.prefix!=="xml"&&S.prefix!=="xmlns"&&(S.prefix!==""||S.local!=="xmlns")&&S.uri&&(y.push(this.uriToNamedNode(S.uri+S.local)),b.push(S.value))}if(m!==null&&(d.subject=v?this.dataFactory.blankNode(m):this.valueToUri(m,d),g&&this.claimNodeId(d.subject)),d.subject||(d.subject=this.dataFactory.blankNode()),p){const w=this.uriToNamedNode(c.uri+c.local);this.emitTriple(d.subject,this.dataFactory.namedNode(Tr.RDF+"type"),w,h?h.reifiedStatementId:null)}if(h){if(h.predicate)if(h.childrenCollectionSubject){const w=this.dataFactory.blankNode();this.emitTriple(h.childrenCollectionSubject,h.childrenCollectionPredicate,w,h.reifiedStatementId),this.emitTriple(w,this.dataFactory.namedNode(Tr.RDF+"first"),d.subject,d.reifiedStatementId),h.childrenCollectionSubject=w,h.childrenCollectionPredicate=this.dataFactory.namedNode(Tr.RDF+"rest")}else{this.emitTriple(h.subject,h.predicate,d.subject,h.reifiedStatementId);for(let w=0;w=0)throw this.newParseError(`Illegal property element name: ${c.local}`);d.predicateSubPredicates=[],d.predicateSubObjects=[];let f=!1,p=!1,y=null,b=!0;const m=[],g=[];for(const v in c.attributes){const _=c.attributes[v];if(_.uri===Tr.RDF)switch(_.local){case"resource":if(y)throw this.newParseError(`Found both rdf:resource (${_.value}) and rdf:nodeID (${y}).`);if(f)throw this.newParseError(`rdf:parseType is not allowed on property elements with rdf:resource (${_.value})`);d.hadChildren=!0,y=_.value,b=!1;continue;case"datatype":if(p)throw this.newParseError(`Found both non-rdf:* property attributes and rdf:datatype (${_.value}).`);if(f)throw this.newParseError(`rdf:parseType is not allowed on property elements with rdf:datatype (${_.value})`);d.datatype=this.valueToUri(_.value,d);continue;case"nodeID":if(p)throw this.newParseError(`Found both non-rdf:* property attributes and rdf:nodeID (${_.value}).`);if(d.hadChildren)throw this.newParseError(`Found both rdf:resource and rdf:nodeID (${_.value}).`);if(f)throw this.newParseError(`rdf:parseType is not allowed on property elements with rdf:nodeID (${_.value})`);this.validateNcname(_.value),d.hadChildren=!0,y=_.value,b=!0;continue;case"bagID":throw this.newParseError("rdf:bagID is not supported.");case"parseType":if(p)throw this.newParseError("rdf:parseType is not allowed when non-rdf:* property attributes are present");if(d.datatype)throw this.newParseError(`rdf:parseType is not allowed on property elements with rdf:datatype (${d.datatype.value})`);if(y)throw this.newParseError(`rdf:parseType is not allowed on property elements with rdf:nodeID or rdf:resource (${y})`);if(_.value==="Resource"){f=!0,d.childrenParseType=o.PROPERTY;const w=this.dataFactory.blankNode();this.emitTriple(d.subject,d.predicate,w,d.reifiedStatementId),d.subject=w,d.predicate=null}else _.value==="Collection"?(f=!0,d.hadChildren=!0,d.childrenCollectionSubject=d.subject,d.childrenCollectionPredicate=d.predicate,b=!1):_.value==="Literal"&&(f=!0,d.childrenTagsToString=!0,d.childrenStringTags=[]);continue;case"ID":this.validateNcname(_.value),d.reifiedStatementId=this.valueToUri("#"+_.value,d),this.claimNodeId(d.reifiedStatementId);continue}else if(_.uri===Tr.XML&&_.local==="lang"){d.language=_.value===""?null:_.value.toLowerCase();continue}if(_.prefix!=="xml"&&_.prefix!=="xmlns"&&(_.prefix!==""||_.local!=="xmlns")&&_.uri){if(f||d.datatype)throw this.newParseError(`Found illegal rdf:* properties on property element with attribute: ${_.value}`);d.hadChildren=!0,p=!0,m.push(this.uriToNamedNode(_.uri+_.local)),g.push(this.dataFactory.literal(_.value,d.datatype||d.language))}}if(y!==null){const v=d.subject;d.subject=b?this.dataFactory.blankNode(y):this.valueToUri(y,d),this.emitTriple(v,d.predicate,d.subject,d.reifiedStatementId);for(let _=0;_/g,(d,h,f)=>(this.saxParser.ENTITIES[h]=f,""))}};vs.RdfXmlParser=a,a.MIME_TYPE="application/rdf+xml",a.RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#",a.XML="http://www.w3.org/XML/1998/namespace",a.FORBIDDEN_NODE_ELEMENTS=["RDF","ID","about","bagID","parseType","resource","nodeID","li","aboutEach","aboutEachPrefix"],a.FORBIDDEN_PROPERTY_ELEMENTS=["Description","RDF","ID","about","bagID","parseType","resource","nodeID","aboutEach","aboutEachPrefix"],a.NCNAME_MATCHER=/^([A-Za-z\xC0-\xD6\xD8-\xF6\u{F8}-\u{2FF}\u{370}-\u{37D}\u{37F}-\u{1FFF}\u{200C}-\u{200D}\u{2070}-\u{218F}\u{2C00}-\u{2FEF}\u{3001}-\u{D7FF}\u{F900}-\u{FDCF}\u{FDF0}-\u{FFFD}\u{10000}-\u{EFFFF}_])([A-Za-z\xC0-\xD6\xD8-\xF6\u{F8}-\u{2FF}\u{370}-\u{37D}\u{37F}-\u{1FFF}\u{200C}-\u{200D}\u{2070}-\u{218F}\u{2C00}-\u{2FEF}\u{3001}-\u{D7FF}\u{F900}-\u{FDCF}\u{FDF0}-\u{FFFD}\u{10000}-\u{EFFFF}_\-.0-9#xB7\u{0300}-\u{036F}\u{203F}-\u{2040}])*$/u;var o;return function(l){l[l.RESOURCE=0]="RESOURCE",l[l.PROPERTY=1]="PROPERTY"}(o||(vs.ParseType=o={})),vs}var bD;function tJ(){return bD||(bD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(eJ(),t)}(bv)),bv}var gD;function rJ(){if(gD)return Il;gD=1,Object.defineProperty(Il,"__esModule",{value:!0}),Il.ActorRdfParseRdfXml=void 0;const t=au(),e=tJ();let u=class extends t.ActorRdfParseFixedMediaTypes{constructor(n){super(n)}async runHandle(n){var a;n.data.on("error",o=>r.emit("error",o));const r=n.data.pipe(new e.RdfXmlParser({baseIRI:(a=n.metadata)==null?void 0:a.baseIRI}));return{data:r,metadata:{triples:!0}}}};return Il.ActorRdfParseRdfXml=u,Il}var mD;function nJ(){return mD||(mD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(rJ(),t)}(yv)),yv}var Sv={},Dl={},Tv={},Av={},_D;function iJ(){return _D||(_D=1,Object.defineProperty(Av,"__esModule",{value:!0})),Av}var Ev={},vD;function aJ(){return vD||(vD=1,Object.defineProperty(Ev,"__esModule",{value:!0})),Ev}var Ov={},wD;function sJ(){return wD||(wD=1,Object.defineProperty(Ov,"__esModule",{value:!0})),Ov}var Nl={},Rv={},Cl={},xv={},Iv={},l1={},SD;function oJ(){return SD||(SD=1,Object.defineProperty(l1,"__esModule",{value:!0}),l1.default=new Uint16Array('ᵁ<Õıʊҝջאٵ۞ޢߖࠏ੊ઑඡ๭༉༦჊ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ὾⁠↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms„‹•˜¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲ΂ϏϢϸontourIntegraìȹoɴ͹\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՗՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲ׌y;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱cò׋؀JTabcdfgorstר׬ׯ׺؀ؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d׷׸䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇܎ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ޷޼߂ߐĀiyޱ޵rc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄΀HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶߻dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣ঳সে্਷ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗ࡜ࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४Ānrࢃ࢏gleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpw৔ਖਛgȀLRlr৞৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼੝੠੷੼અઋ઎p;椅y;䐜Ādl੥੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑ඗ඞcy;䐊cute;䅃ƀaey઴હાron;䅇dil;䅅;䐝ƀgswે૰଎ativeƀMTV૓૟૨ediumSpace;怋hiĀcn૦૘ë૙eryThiî૙tedĀGL૸ଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷ଺reak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪୼஡௫ఄ౞಄ದ೘ൡඅ櫬Āou୛୤ngruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊ஛ement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater΀;EFGLSTஶஷ஽௉௓௘௥扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲௽ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ೒拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨೹setĀ;E೰ೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂ෉෕ෛ෠෧෼ขภยา฿ไlig;䅒cute耻Ó䃓Āiy෎ීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲ෶cr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬื฼de耻Õ䃕es;樷ml耻Ö䃖erĀBP๋๠Āar๐๓r;怾acĀek๚๜;揞et;掴arenthesis;揜Ҁacfhilors๿ງຊຏຒດຝະ໼rtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ໠໤檻cedesȀ;EST່້໏໚扺qual;檯lantEqual;扼ilde;找me;怳Ādp໩໮uct;戏ortionĀ;aȥ໹l;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬؀BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁࿫࿳ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL࿜࿝࿡憒ar;懥eftArrow;懄eiling;按oǵ࿹\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»࿝pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄ቉ቕ቞ቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHc቎ቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗Āeiቻ኉Dzኀ\0ኇefore;戴a;䎘Ācn኎ኘkSpace;쀀  Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0᏿ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0጖y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻፿on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtè૙a;䎖r;愨pf;愤cr;쀀𝒵௡ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚΀;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒΀;Eaeiop዁ᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;e዁ᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;e዁ᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰ᜼ᝃᝈ᝸᝽០៦ᠹᡐᜍ᤽᥈ᥰot;櫭Ācrᛶ᜞kȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e᜚᜛戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;t፜᜷brk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓ᝛ᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯ᝱ᝳ;䎲;愶een;扬r;쀀𝔟g΀costuvwឍឝឳេ៕៛៞ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀako៭ᠦᠵĀcn៲ᠣkƀlst៺֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘᠝斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈؀DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬ᣿ᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教΀;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ᣷᣹᣻᣽;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ᤟;敛;敘;攘;攔΀;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģ᥂bar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;e᜚᜜lƀ;bhᥨᥩᥫ䁜;槅sub;柈Ŭᥴ᥾lĀ;e᥹᥺怢t»᥺pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭍᭒\0᯽\0ᰌƀcpr᦭ᦲ᧝ute;䄇̀;abcdsᦿᧀᧄ᧊᧕᧙戩nd;橄rcup;橉Āau᧏᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r΀;Ecefms᩟᩠ᩢᩫ᪤᪪᪮旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖᪚᪟»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇᫔᫺\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ᫙\0\0᫢aĀ;t᫞᫟䀬;䁀ƀ;fl᫨᫩᫫戁îᅠeĀmx᫱᫶ent»᫩eóɍǧ᫾\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯΀delprvw᭠᭬᭷ᮂᮬᯔ᯹arrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;p᭿ᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰸᰻᰿ᱝᱩᱵᲊᲞᲬᲷ᳻᳿ᴍᵻᶑᶫᶻ᷆᷍rò΁ar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂͸᳖᳜᳠mƀ;oș᳊᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄ὎὚ĀDoḆᴴoôᲉĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»Ṻƀaeiἒ἖Ἒls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙ῜ῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao‌⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧‪‬\0‮耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₟₥₰₴⃰⃵⃺⃿℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕ₝ute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽⃉ƀ;qsؾٌ⃄lanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqr׮ⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0↎proø₞r;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢␧␭␱␵␻ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀஀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼rò৆òΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonó྘quigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d྘➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ᠛旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐௏쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop඄⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roø඄urĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓΀;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨í஘istĀ;s஠டr;쀀𝔫ȀEest௅⩦⩹⩼ƀ;qs஼⩭௡ƀ;qs஼௅⩴lanô௢ií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚΀AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs఻⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs఻⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast୻⭕⭚⭟lleì୻l;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖ΀chimpqu⮽⯍⯙⬄୸⯤⯯Ȁ;cerല⯆ഷ⯉uå൅;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭å೸åഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñ೗Ā;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰⳴ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥ⵲ⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;c᪞ⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācr⵩⵭ir;榿;쀀𝔬ͯ⵹\0\0⵼\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕ⶘ⶥⶨrò᪀Āir⶝ⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔ⷗ǒr;榷rp;榹΀;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ⹞\0⹽\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ⹧⹲຅脀¶;l⹭⹮䂶leìЃɩ⹸\0\0⹻m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳⻴ᤈ⻹⻽⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp໬⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t໻⾴ï໻rel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⿚⋢⿟⿥⿫⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei⿾々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔઀ABHabcdefhilmnoprstux぀けさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤΀cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstw࿜ガクシスゼゾダッデナp;極Ā;f࿠ゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes㄂㄄;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ì࿲âヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘㇤㇮rrowĀ;t࿜ㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowó࿪arpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓rò࿪aòՑ;怏oustĀ;a㈞㈟掱che»㈟mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦΀Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼਴t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì⹯耻­䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;q኱ኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫ਩war;椪lig耻ß䃟௡㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rë๟ƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproø዁im»ኬsðኞĀas㚺㚮ð዁rn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈ΀adempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xô᝷headĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜΀eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roð໻tré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚΀cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜ៟tré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map(function(t){return t.charCodeAt(0)}))),l1}var d1={},TD;function uJ(){return TD||(TD=1,Object.defineProperty(d1,"__esModule",{value:!0}),d1.default=new Uint16Array("Ȁaglq \x1Bɭ\0\0p;䀦os;䀧t;䀾t;䀼uot;䀢".split("").map(function(t){return t.charCodeAt(0)}))),d1}var Pv={},AD;function ED(){return AD||(AD=1,function(t){var e;Object.defineProperty(t,"__esModule",{value:!0}),t.replaceCodePoint=t.fromCodePoint=void 0;var u=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]);t.fromCodePoint=(e=String.fromCodePoint)!==null&&e!==void 0?e:function(r){var a="";return r>65535&&(r-=65536,a+=String.fromCharCode(r>>>10&1023|55296),r=56320|r&1023),a+=String.fromCharCode(r),a};function s(r){var a;return r>=55296&&r<=57343||r>1114111?65533:(a=u.get(r))!==null&&a!==void 0?a:r}t.replaceCodePoint=s;function n(r){return(0,t.fromCodePoint)(s(r))}t.default=n}(Pv)),Pv}var OD;function Ga(){return OD||(OD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(P,j,U,M){M===void 0&&(M=U);var q=Object.getOwnPropertyDescriptor(j,U);(!q||("get"in q?!j.__esModule:q.writable||q.configurable))&&(q={enumerable:!0,get:function(){return j[U]}}),Object.defineProperty(P,M,q)}:function(P,j,U,M){M===void 0&&(M=U),P[M]=j[U]}),u=I&&I.__setModuleDefault||(Object.create?function(P,j){Object.defineProperty(P,"default",{enumerable:!0,value:j})}:function(P,j){P.default=j}),s=I&&I.__importStar||function(P){if(P&&P.__esModule)return P;var j={};if(P!=null)for(var U in P)U!=="default"&&Object.prototype.hasOwnProperty.call(P,U)&&e(j,P,U);return u(j,P),j},n=I&&I.__importDefault||function(P){return P&&P.__esModule?P:{default:P}};Object.defineProperty(t,"__esModule",{value:!0}),t.decodeXML=t.decodeHTMLStrict=t.decodeHTMLAttribute=t.decodeHTML=t.determineBranch=t.EntityDecoder=t.DecodingMode=t.BinTrieFlags=t.fromCodePoint=t.replaceCodePoint=t.decodeCodePoint=t.xmlDecodeTree=t.htmlDecodeTree=void 0;var r=n(oJ());t.htmlDecodeTree=r.default;var a=n(uJ());t.xmlDecodeTree=a.default;var o=s(ED());t.decodeCodePoint=o.default;var l=ED();Object.defineProperty(t,"replaceCodePoint",{enumerable:!0,get:function(){return l.replaceCodePoint}}),Object.defineProperty(t,"fromCodePoint",{enumerable:!0,get:function(){return l.fromCodePoint}});var c;(function(P){P[P.NUM=35]="NUM",P[P.SEMI=59]="SEMI",P[P.EQUALS=61]="EQUALS",P[P.ZERO=48]="ZERO",P[P.NINE=57]="NINE",P[P.LOWER_A=97]="LOWER_A",P[P.LOWER_F=102]="LOWER_F",P[P.LOWER_X=120]="LOWER_X",P[P.LOWER_Z=122]="LOWER_Z",P[P.UPPER_A=65]="UPPER_A",P[P.UPPER_F=70]="UPPER_F",P[P.UPPER_Z=90]="UPPER_Z"})(c||(c={}));var d=32,h;(function(P){P[P.VALUE_LENGTH=49152]="VALUE_LENGTH",P[P.BRANCH_LENGTH=16256]="BRANCH_LENGTH",P[P.JUMP_TABLE=127]="JUMP_TABLE"})(h=t.BinTrieFlags||(t.BinTrieFlags={}));function f(P){return P>=c.ZERO&&P<=c.NINE}function p(P){return P>=c.UPPER_A&&P<=c.UPPER_F||P>=c.LOWER_A&&P<=c.LOWER_F}function y(P){return P>=c.UPPER_A&&P<=c.UPPER_Z||P>=c.LOWER_A&&P<=c.LOWER_Z||f(P)}function b(P){return P===c.EQUALS||y(P)}var m;(function(P){P[P.EntityStart=0]="EntityStart",P[P.NumericStart=1]="NumericStart",P[P.NumericDecimal=2]="NumericDecimal",P[P.NumericHex=3]="NumericHex",P[P.NamedEntity=4]="NamedEntity"})(m||(m={}));var g;(function(P){P[P.Legacy=0]="Legacy",P[P.Strict=1]="Strict",P[P.Attribute=2]="Attribute"})(g=t.DecodingMode||(t.DecodingMode={}));var v=function(){function P(j,U,M){this.decodeTree=j,this.emitCodePoint=U,this.errors=M,this.state=m.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=g.Strict}return P.prototype.startEntity=function(j){this.decodeMode=j,this.state=m.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1},P.prototype.write=function(j,U){switch(this.state){case m.EntityStart:return j.charCodeAt(U)===c.NUM?(this.state=m.NumericStart,this.consumed+=1,this.stateNumericStart(j,U+1)):(this.state=m.NamedEntity,this.stateNamedEntity(j,U));case m.NumericStart:return this.stateNumericStart(j,U);case m.NumericDecimal:return this.stateNumericDecimal(j,U);case m.NumericHex:return this.stateNumericHex(j,U);case m.NamedEntity:return this.stateNamedEntity(j,U)}},P.prototype.stateNumericStart=function(j,U){return U>=j.length?-1:(j.charCodeAt(U)|d)===c.LOWER_X?(this.state=m.NumericHex,this.consumed+=1,this.stateNumericHex(j,U+1)):(this.state=m.NumericDecimal,this.stateNumericDecimal(j,U))},P.prototype.addToNumericResult=function(j,U,M,q){if(U!==M){var Q=M-U;this.result=this.result*Math.pow(q,Q)+parseInt(j.substr(U,Q),q),this.consumed+=Q}},P.prototype.stateNumericHex=function(j,U){for(var M=U;U>14;U>14,Q!==0){if(Z===c.SEMI)return this.emitNamedEntityData(this.treeIndex,Q,this.consumed+this.excess);this.decodeMode!==g.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1},P.prototype.emitNotTerminatedNamedEntity=function(){var j,U=this,M=U.result,q=U.decodeTree,Q=(q[M]&h.VALUE_LENGTH)>>14;return this.emitNamedEntityData(M,Q,this.consumed),(j=this.errors)===null||j===void 0||j.missingSemicolonAfterCharacterReference(),this.consumed},P.prototype.emitNamedEntityData=function(j,U,M){var q=this.decodeTree;return this.emitCodePoint(U===1?q[j]&~h.VALUE_LENGTH:q[j+1],M),U===3&&this.emitCodePoint(q[j+2],M),M},P.prototype.end=function(){var j;switch(this.state){case m.NamedEntity:return this.result!==0&&(this.decodeMode!==g.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case m.NumericDecimal:return this.emitNumericEntity(0,2);case m.NumericHex:return this.emitNumericEntity(0,3);case m.NumericStart:return(j=this.errors)===null||j===void 0||j.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case m.EntityStart:return 0}},P}();t.EntityDecoder=v;function _(P){var j="",U=new v(P,function(M){return j+=(0,o.fromCodePoint)(M)});return function(q,Q){for(var Z=0,K=0;(K=q.indexOf("&",K))>=0;){j+=q.slice(Z,K),U.startEntity(Q);var fe=U.write(q,K+1);if(fe<0){Z=K+U.end();break}Z=K+fe,K=fe===0?Z+1:Z}var X=j+q.slice(Z);return j="",X}}function w(P,j,U,M){var q=(j&h.BRANCH_LENGTH)>>7,Q=j&h.JUMP_TABLE;if(q===0)return Q!==0&&M===Q?U:-1;if(Q){var Z=M-Q;return Z<0||Z>=q?-1:P[U+Z]-1}for(var K=U,fe=K+q-1;K<=fe;){var X=K+fe>>>1,he=P[X];if(heM)fe=X-1;else return P[X+q]}return-1}t.determineBranch=w;var S=_(r.default),A=_(a.default);function D(P,j){return j===void 0&&(j=g.Legacy),S(P,j)}t.decodeHTML=D;function L(P){return S(P,g.Attribute)}t.decodeHTMLAttribute=L;function E(P){return S(P,g.Strict)}t.decodeHTMLStrict=E;function O(P){return A(P,g.Strict)}t.decodeXML=O}(Iv)),Iv}var RD;function Mq(){return RD||(RD=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.QuoteType=void 0;var e=Ga(),u;(function(f){f[f.Tab=9]="Tab",f[f.NewLine=10]="NewLine",f[f.FormFeed=12]="FormFeed",f[f.CarriageReturn=13]="CarriageReturn",f[f.Space=32]="Space",f[f.ExclamationMark=33]="ExclamationMark",f[f.Number=35]="Number",f[f.Amp=38]="Amp",f[f.SingleQuote=39]="SingleQuote",f[f.DoubleQuote=34]="DoubleQuote",f[f.Dash=45]="Dash",f[f.Slash=47]="Slash",f[f.Zero=48]="Zero",f[f.Nine=57]="Nine",f[f.Semi=59]="Semi",f[f.Lt=60]="Lt",f[f.Eq=61]="Eq",f[f.Gt=62]="Gt",f[f.Questionmark=63]="Questionmark",f[f.UpperA=65]="UpperA",f[f.LowerA=97]="LowerA",f[f.UpperF=70]="UpperF",f[f.LowerF=102]="LowerF",f[f.UpperZ=90]="UpperZ",f[f.LowerZ=122]="LowerZ",f[f.LowerX=120]="LowerX",f[f.OpeningSquareBracket=91]="OpeningSquareBracket"})(u||(u={}));var s;(function(f){f[f.Text=1]="Text",f[f.BeforeTagName=2]="BeforeTagName",f[f.InTagName=3]="InTagName",f[f.InSelfClosingTag=4]="InSelfClosingTag",f[f.BeforeClosingTagName=5]="BeforeClosingTagName",f[f.InClosingTagName=6]="InClosingTagName",f[f.AfterClosingTagName=7]="AfterClosingTagName",f[f.BeforeAttributeName=8]="BeforeAttributeName",f[f.InAttributeName=9]="InAttributeName",f[f.AfterAttributeName=10]="AfterAttributeName",f[f.BeforeAttributeValue=11]="BeforeAttributeValue",f[f.InAttributeValueDq=12]="InAttributeValueDq",f[f.InAttributeValueSq=13]="InAttributeValueSq",f[f.InAttributeValueNq=14]="InAttributeValueNq",f[f.BeforeDeclaration=15]="BeforeDeclaration",f[f.InDeclaration=16]="InDeclaration",f[f.InProcessingInstruction=17]="InProcessingInstruction",f[f.BeforeComment=18]="BeforeComment",f[f.CDATASequence=19]="CDATASequence",f[f.InSpecialComment=20]="InSpecialComment",f[f.InCommentLike=21]="InCommentLike",f[f.BeforeSpecialS=22]="BeforeSpecialS",f[f.SpecialStartSequence=23]="SpecialStartSequence",f[f.InSpecialTag=24]="InSpecialTag",f[f.BeforeEntity=25]="BeforeEntity",f[f.BeforeNumericEntity=26]="BeforeNumericEntity",f[f.InNamedEntity=27]="InNamedEntity",f[f.InNumericEntity=28]="InNumericEntity",f[f.InHexEntity=29]="InHexEntity"})(s||(s={}));function n(f){return f===u.Space||f===u.NewLine||f===u.Tab||f===u.FormFeed||f===u.CarriageReturn}function r(f){return f===u.Slash||f===u.Gt||n(f)}function a(f){return f>=u.Zero&&f<=u.Nine}function o(f){return f>=u.LowerA&&f<=u.LowerZ||f>=u.UpperA&&f<=u.UpperZ}function l(f){return f>=u.UpperA&&f<=u.UpperF||f>=u.LowerA&&f<=u.LowerF}var c;(function(f){f[f.NoValue=0]="NoValue",f[f.Unquoted=1]="Unquoted",f[f.Single=2]="Single",f[f.Double=3]="Double"})(c=t.QuoteType||(t.QuoteType={}));var d={Cdata:new Uint8Array([67,68,65,84,65,91]),CdataEnd:new Uint8Array([93,93,62]),CommentEnd:new Uint8Array([45,45,62]),ScriptEnd:new Uint8Array([60,47,115,99,114,105,112,116]),StyleEnd:new Uint8Array([60,47,115,116,121,108,101]),TitleEnd:new Uint8Array([60,47,116,105,116,108,101])},h=function(){function f(p,y){var b=p.xmlMode,m=b===void 0?!1:b,g=p.decodeEntities,v=g===void 0?!0:g;this.cbs=y,this.state=s.Text,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=s.Text,this.isSpecial=!1,this.running=!0,this.offset=0,this.currentSequence=void 0,this.sequenceIndex=0,this.trieIndex=0,this.trieCurrent=0,this.entityResult=0,this.entityExcess=0,this.xmlMode=m,this.decodeEntities=v,this.entityTrie=m?e.xmlDecodeTree:e.htmlDecodeTree}return f.prototype.reset=function(){this.state=s.Text,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=s.Text,this.currentSequence=void 0,this.running=!0,this.offset=0},f.prototype.write=function(p){this.offset+=this.buffer.length,this.buffer=p,this.parse()},f.prototype.end=function(){this.running&&this.finish()},f.prototype.pause=function(){this.running=!1},f.prototype.resume=function(){this.running=!0,this.indexthis.sectionStart&&this.cbs.ontext(this.sectionStart,this.index),this.state=s.BeforeTagName,this.sectionStart=this.index):this.decodeEntities&&p===u.Amp&&(this.state=s.BeforeEntity)},f.prototype.stateSpecialStartSequence=function(p){var y=this.sequenceIndex===this.currentSequence.length,b=y?r(p):(p|32)===this.currentSequence[this.sequenceIndex];if(!b)this.isSpecial=!1;else if(!y){this.sequenceIndex++;return}this.sequenceIndex=0,this.state=s.InTagName,this.stateInTagName(p)},f.prototype.stateInSpecialTag=function(p){if(this.sequenceIndex===this.currentSequence.length){if(p===u.Gt||n(p)){var y=this.index-this.currentSequence.length;if(this.sectionStart>14)-1;if(!this.allowLegacyEntity()&&p!==u.Semi)this.trieIndex+=b;else{var m=this.index-this.entityExcess+1;m>this.sectionStart&&this.emitPartial(this.sectionStart,m),this.entityResult=this.trieIndex,this.trieIndex+=b,this.entityExcess=0,this.sectionStart=this.index+1,b===0&&this.emitNamedEntity()}}},f.prototype.emitNamedEntity=function(){if(this.state=this.baseState,this.entityResult!==0){var p=(this.entityTrie[this.entityResult]&e.BinTrieFlags.VALUE_LENGTH)>>14;switch(p){case 1:{this.emitCodePoint(this.entityTrie[this.entityResult]&~e.BinTrieFlags.VALUE_LENGTH);break}case 2:{this.emitCodePoint(this.entityTrie[this.entityResult+1]);break}case 3:this.emitCodePoint(this.entityTrie[this.entityResult+1]),this.emitCodePoint(this.entityTrie[this.entityResult+2])}}},f.prototype.stateBeforeNumericEntity=function(p){(p|32)===u.LowerX?(this.entityExcess++,this.state=s.InHexEntity):(this.state=s.InNumericEntity,this.stateInNumericEntity(p))},f.prototype.emitNumericEntity=function(p){var y=this.index-this.entityExcess-1,b=y+2+ +(this.state===s.InHexEntity);b!==this.index&&(y>this.sectionStart&&this.emitPartial(this.sectionStart,y),this.sectionStart=this.index+Number(p),this.emitCodePoint((0,e.replaceCodePoint)(this.entityResult))),this.state=this.baseState},f.prototype.stateInNumericEntity=function(p){p===u.Semi?this.emitNumericEntity(!0):a(p)?(this.entityResult=this.entityResult*10+(p-u.Zero),this.entityExcess++):(this.allowLegacyEntity()?this.emitNumericEntity(!1):this.state=this.baseState,this.index--)},f.prototype.stateInHexEntity=function(p){p===u.Semi?this.emitNumericEntity(!0):a(p)?(this.entityResult=this.entityResult*16+(p-u.Zero),this.entityExcess++):l(p)?(this.entityResult=this.entityResult*16+((p|32)-u.LowerA+10),this.entityExcess++):(this.allowLegacyEntity()?this.emitNumericEntity(!1):this.state=this.baseState,this.index--)},f.prototype.allowLegacyEntity=function(){return!this.xmlMode&&(this.baseState===s.Text||this.baseState===s.InSpecialTag)},f.prototype.cleanup=function(){this.running&&this.sectionStart!==this.index&&(this.state===s.Text||this.state===s.InSpecialTag&&this.sequenceIndex===0?(this.cbs.ontext(this.sectionStart,this.index),this.sectionStart=this.index):(this.state===s.InAttributeValueDq||this.state===s.InAttributeValueSq||this.state===s.InAttributeValueNq)&&(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=this.index))},f.prototype.shouldContinue=function(){return this.index0&&A.has(this.stack[this.stack.length-1]);){var D=this.stack.pop();(_=(v=this.cbs).onclosetag)===null||_===void 0||_.call(v,D,!0)}this.isVoidElement(g)||(this.stack.push(g),f.has(g)?this.foreignContext.push(!0):p.has(g)&&this.foreignContext.push(!1)),(S=(w=this.cbs).onopentagname)===null||S===void 0||S.call(w,g),this.cbs.onopentag&&(this.attribs={})},m.prototype.endOpenTag=function(g){var v,_;this.startIndex=this.openTagStart,this.attribs&&((_=(v=this.cbs).onopentag)===null||_===void 0||_.call(v,this.tagname,this.attribs,g),this.attribs=null),this.cbs.onclosetag&&this.isVoidElement(this.tagname)&&this.cbs.onclosetag(this.tagname,!0),this.tagname=""},m.prototype.onopentagend=function(g){this.endIndex=g,this.endOpenTag(!1),this.startIndex=g+1},m.prototype.onclosetag=function(g,v){var _,w,S,A,D,L;this.endIndex=v;var E=this.getSlice(g,v);if(this.lowerCaseTagNames&&(E=E.toLowerCase()),(f.has(E)||p.has(E))&&this.foreignContext.pop(),this.isVoidElement(E))!this.options.xmlMode&&E==="br"&&((w=(_=this.cbs).onopentagname)===null||w===void 0||w.call(_,"br"),(A=(S=this.cbs).onopentag)===null||A===void 0||A.call(S,"br",{},!0),(L=(D=this.cbs).onclosetag)===null||L===void 0||L.call(D,"br",!1));else{var O=this.stack.lastIndexOf(E);if(O!==-1)if(this.cbs.onclosetag)for(var P=this.stack.length-O;P--;)this.cbs.onclosetag(this.stack.pop(),P!==0);else this.stack.length=O;else!this.options.xmlMode&&E==="p"&&(this.emitOpenTag("p"),this.closeCurrentTag(!0))}this.startIndex=v+1},m.prototype.onselfclosingtag=function(g){this.endIndex=g,this.options.xmlMode||this.options.recognizeSelfClosing||this.foreignContext[this.foreignContext.length-1]?(this.closeCurrentTag(!1),this.startIndex=g+1):this.onopentagend(g)},m.prototype.closeCurrentTag=function(g){var v,_,w=this.tagname;this.endOpenTag(g),this.stack[this.stack.length-1]===w&&((_=(v=this.cbs).onclosetag)===null||_===void 0||_.call(v,w,!g),this.stack.pop())},m.prototype.onattribname=function(g,v){this.startIndex=g;var _=this.getSlice(g,v);this.attribname=this.lowerCaseAttributeNames?_.toLowerCase():_},m.prototype.onattribdata=function(g,v){this.attribvalue+=this.getSlice(g,v)},m.prototype.onattribentity=function(g){this.attribvalue+=(0,n.fromCodePoint)(g)},m.prototype.onattribend=function(g,v){var _,w;this.endIndex=v,(w=(_=this.cbs).onattribute)===null||w===void 0||w.call(_,this.attribname,this.attribvalue,g===s.QuoteType.Double?'"':g===s.QuoteType.Single?"'":g===s.QuoteType.NoValue?void 0:null),this.attribs&&!Object.prototype.hasOwnProperty.call(this.attribs,this.attribname)&&(this.attribs[this.attribname]=this.attribvalue),this.attribvalue=""},m.prototype.getInstructionName=function(g){var v=g.search(y),_=v<0?g:g.substr(0,v);return this.lowerCaseTagNames&&(_=_.toLowerCase()),_},m.prototype.ondeclaration=function(g,v){this.endIndex=v;var _=this.getSlice(g,v);if(this.cbs.onprocessinginstruction){var w=this.getInstructionName(_);this.cbs.onprocessinginstruction("!".concat(w),"!".concat(_))}this.startIndex=v+1},m.prototype.onprocessinginstruction=function(g,v){this.endIndex=v;var _=this.getSlice(g,v);if(this.cbs.onprocessinginstruction){var w=this.getInstructionName(_);this.cbs.onprocessinginstruction("?".concat(w),"?".concat(_))}this.startIndex=v+1},m.prototype.oncomment=function(g,v,_){var w,S,A,D;this.endIndex=v,(S=(w=this.cbs).oncomment)===null||S===void 0||S.call(w,this.getSlice(g,v-_)),(D=(A=this.cbs).oncommentend)===null||D===void 0||D.call(A),this.startIndex=v+1},m.prototype.oncdata=function(g,v,_){var w,S,A,D,L,E,O,P,j,U;this.endIndex=v;var M=this.getSlice(g,v-_);this.options.xmlMode||this.options.recognizeCDATA?((S=(w=this.cbs).oncdatastart)===null||S===void 0||S.call(w),(D=(A=this.cbs).ontext)===null||D===void 0||D.call(A,M),(E=(L=this.cbs).oncdataend)===null||E===void 0||E.call(L)):((P=(O=this.cbs).oncomment)===null||P===void 0||P.call(O,"[CDATA[".concat(M,"]]")),(U=(j=this.cbs).oncommentend)===null||U===void 0||U.call(j)),this.startIndex=v+1},m.prototype.onend=function(){var g,v;if(this.cbs.onclosetag){this.endIndex=this.startIndex;for(var _=this.stack.length;_>0;this.cbs.onclosetag(this.stack[--_],!0));}(v=(g=this.cbs).onend)===null||v===void 0||v.call(g)},m.prototype.reset=function(){var g,v,_,w;(v=(g=this.cbs).onreset)===null||v===void 0||v.call(g),this.tokenizer.reset(),this.tagname="",this.attribname="",this.attribs=null,this.stack.length=0,this.startIndex=0,this.endIndex=0,(w=(_=this.cbs).onparserinit)===null||w===void 0||w.call(_,this),this.buffers.length=0,this.bufferOffset=0,this.writeIndex=0,this.ended=!1},m.prototype.parseComplete=function(g){this.reset(),this.end(g)},m.prototype.getSlice=function(g,v){for(;g-this.bufferOffset>=this.buffers[0].length;)this.shiftBuffer();for(var _=this.buffers[0].slice(g-this.bufferOffset,v-this.bufferOffset);v-this.bufferOffset>this.buffers[0].length;)this.shiftBuffer(),_+=this.buffers[0].slice(0,v-this.bufferOffset);return _},m.prototype.shiftBuffer=function(){this.bufferOffset+=this.buffers[0].length,this.writeIndex--,this.buffers.shift()},m.prototype.write=function(g){var v,_;if(this.ended){(_=(v=this.cbs).onerror)===null||_===void 0||_.call(v,new Error(".write() after done!"));return}this.buffers.push(g),this.tokenizer.running&&(this.tokenizer.write(g),this.writeIndex++)},m.prototype.end=function(g){var v,_;if(this.ended){(_=(v=this.cbs).onerror)===null||_===void 0||_.call(v,new Error(".end() after done!"));return}g&&this.write(g),this.ended=!0,this.tokenizer.end()},m.prototype.pause=function(){this.tokenizer.pause()},m.prototype.resume=function(){for(this.tokenizer.resume();this.tokenizer.running&&this.writeIndex0?this.children[this.children.length-1]:null},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"childNodes",{get:function(){return this.children},set:function(D){this.children=D},enumerable:!1,configurable:!0}),A}(s);Ft.NodeWithChildren=l;var c=function(S){t(A,S);function A(){var D=S!==null&&S.apply(this,arguments)||this;return D.type=u.ElementType.CDATA,D}return Object.defineProperty(A.prototype,"nodeType",{get:function(){return 4},enumerable:!1,configurable:!0}),A}(l);Ft.CDATA=c;var d=function(S){t(A,S);function A(){var D=S!==null&&S.apply(this,arguments)||this;return D.type=u.ElementType.Root,D}return Object.defineProperty(A.prototype,"nodeType",{get:function(){return 9},enumerable:!1,configurable:!0}),A}(l);Ft.Document=d;var h=function(S){t(A,S);function A(D,L,E,O){E===void 0&&(E=[]),O===void 0&&(O=D==="script"?u.ElementType.Script:D==="style"?u.ElementType.Style:u.ElementType.Tag);var P=S.call(this,E)||this;return P.name=D,P.attribs=L,P.type=O,P}return Object.defineProperty(A.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"tagName",{get:function(){return this.name},set:function(D){this.name=D},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"attributes",{get:function(){var D=this;return Object.keys(this.attribs).map(function(L){var E,O;return{name:L,value:D.attribs[L],namespace:(E=D["x-attribsNamespace"])===null||E===void 0?void 0:E[L],prefix:(O=D["x-attribsPrefix"])===null||O===void 0?void 0:O[L]}})},enumerable:!1,configurable:!0}),A}(l);Ft.Element=h;function f(S){return(0,u.isTag)(S)}Ft.isTag=f;function p(S){return S.type===u.ElementType.CDATA}Ft.isCDATA=p;function y(S){return S.type===u.ElementType.Text}Ft.isText=y;function b(S){return S.type===u.ElementType.Comment}Ft.isComment=b;function m(S){return S.type===u.ElementType.Directive}Ft.isDirective=m;function g(S){return S.type===u.ElementType.Root}Ft.isDocument=g;function v(S){return Object.prototype.hasOwnProperty.call(S,"children")}Ft.hasChildren=v;function _(S,A){A===void 0&&(A=!1);var D;if(y(S))D=new r(S.data);else if(b(S))D=new a(S.data);else if(f(S)){var L=A?w(S.children):[],E=new h(S.name,e({},S.attribs),L);L.forEach(function(U){return U.parent=E}),S.namespace!=null&&(E.namespace=S.namespace),S["x-attribsNamespace"]&&(E["x-attribsNamespace"]=e({},S["x-attribsNamespace"])),S["x-attribsPrefix"]&&(E["x-attribsPrefix"]=e({},S["x-attribsPrefix"])),D=E}else if(p(S)){var L=A?w(S.children):[],O=new c(L);L.forEach(function(M){return M.parent=O}),D=O}else if(g(S)){var L=A?w(S.children):[],P=new d(L);L.forEach(function(M){return M.parent=P}),S["x-mode"]&&(P["x-mode"]=S["x-mode"]),D=P}else if(m(S)){var j=new o(S.name,S.data);S["x-name"]!=null&&(j["x-name"]=S["x-name"],j["x-publicId"]=S["x-publicId"],j["x-systemId"]=S["x-systemId"]),D=j}else throw new Error("Not implemented yet: ".concat(S.type));return D.startIndex=S.startIndex,D.endIndex=S.endIndex,S.sourceCodeLocation!=null&&(D.sourceCodeLocation=S.sourceCodeLocation),D}Ft.cloneNode=_;function w(S){for(var A=S.map(function(L){return _(L,!0)}),D=1;D$\x80-\uFFFF]/g;var e=new Map([[34,"""],[38,"&"],[39,"'"],[60,"<"],[62,">"]]);t.getCodePoint=String.prototype.codePointAt!=null?function(n,r){return n.codePointAt(r)}:function(n,r){return(n.charCodeAt(r)&64512)===55296?(n.charCodeAt(r)-55296)*1024+n.charCodeAt(r+1)-56320+65536:n.charCodeAt(r)};function u(n){for(var r="",a=0,o;(o=t.xmlReplacer.exec(n))!==null;){var l=o.index,c=n.charCodeAt(l),d=e.get(c);d!==void 0?(r+=n.substring(a,l)+d,a=l+1):(r+="".concat(n.substring(a,l),"&#x").concat((0,t.getCodePoint)(n,l).toString(16),";"),a=t.xmlReplacer.lastIndex+=+((c&64512)===55296))}return r+n.substr(a)}t.encodeXML=u,t.escape=u;function s(n,r){return function(o){for(var l,c=0,d="";l=n.exec(o);)c!==l.index&&(d+=o.substring(c,l.index)),d+=r.get(l[0].charCodeAt(0)),c=l.index+1;return d+o.substring(c)}}t.escapeUTF8=s(/[&<>'"]/g,e),t.escapeAttribute=s(/["&\u00A0]/g,new Map([[34,"""],[38,"&"],[160," "]])),t.escapeText=s(/[&<>\u00A0]/g,new Map([[38,"&"],[60,"<"],[62,">"],[160," "]]))}(Lv)),Lv}var MD;function FD(){if(MD)return Ss;MD=1;var t=I&&I.__importDefault||function(o){return o&&o.__esModule?o:{default:o}};Object.defineProperty(Ss,"__esModule",{value:!0}),Ss.encodeNonAsciiHTML=Ss.encodeHTML=void 0;var e=t(cJ()),u=a3(),s=/[\t\n!-,./:-@[-`\f{-}$\x80-\uFFFF]/g;function n(o){return a(s,o)}Ss.encodeHTML=n;function r(o){return a(u.xmlReplacer,o)}Ss.encodeNonAsciiHTML=r;function a(o,l){for(var c="",d=0,h;(h=o.exec(l))!==null;){var f=h.index;c+=l.substring(d,f);var p=l.charCodeAt(f),y=e.default.get(p);if(typeof y=="object"){if(f+10&&(D+=h(w.children,S)),(S.xmlMode||!d.has(w.name))&&(D+=""))),D}function m(w){return"<".concat(w.data,">")}function g(w,S){var A,D=w.data||"";return((A=S.encodeEntities)!==null&&A!==void 0?A:S.decodeEntities)!==!1&&!(!S.xmlMode&&w.parent&&o.has(w.parent.name))&&(D=S.xmlMode||S.encodeEntities!=="utf8"?(0,r.encodeXML)(D):(0,r.escapeText)(D)),D}function v(w){return"")}function _(w){return"")}return go}var HD;function Fq(){if(HD)return zn;HD=1;var t=I&&I.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(zn,"__esModule",{value:!0}),zn.innerText=zn.textContent=zn.getText=zn.getInnerHTML=zn.getOuterHTML=void 0;var e=ui(),u=t(fJ()),s=Zs();function n(c,d){return(0,u.default)(c,d)}zn.getOuterHTML=n;function r(c,d){return(0,e.hasChildren)(c)?c.children.map(function(h){return n(h,d)}).join(""):""}zn.getInnerHTML=r;function a(c){return Array.isArray(c)?c.map(a).join(""):(0,e.isTag)(c)?c.name==="br"?` -`:a(c.children):(0,e.isCDATA)(c)?a(c.children):(0,e.isText)(c)?c.data:""}zn.getText=a;function o(c){return Array.isArray(c)?c.map(o).join(""):(0,e.hasChildren)(c)&&!(0,e.isComment)(c)?o(c.children):(0,e.isText)(c)?c.data:""}zn.textContent=o;function l(c){return Array.isArray(c)?c.map(l).join(""):(0,e.hasChildren)(c)&&(c.type===s.ElementType.Tag||(0,e.isCDATA)(c))?l(c.children):(0,e.isText)(c)?c.data:""}return zn.innerText=l,zn}var $r={},$D;function hJ(){if($D)return $r;$D=1,Object.defineProperty($r,"__esModule",{value:!0}),$r.prevElementSibling=$r.nextElementSibling=$r.getName=$r.hasAttrib=$r.getAttributeValue=$r.getSiblings=$r.getParent=$r.getChildren=void 0;var t=ui();function e(c){return(0,t.hasChildren)(c)?c.children:[]}$r.getChildren=e;function u(c){return c.parent||null}$r.getParent=u;function s(c){var d,h,f=u(c);if(f!=null)return e(f);for(var p=[c],y=c.prev,b=c.next;y!=null;)p.unshift(y),d=y,y=d.prev;for(;b!=null;)p.push(b),h=b,b=h.next;return p}$r.getSiblings=s;function n(c,d){var h;return(h=c.attribs)===null||h===void 0?void 0:h[d]}$r.getAttributeValue=n;function r(c,d){return c.attribs!=null&&Object.prototype.hasOwnProperty.call(c.attribs,d)&&c.attribs[d]!=null}$r.hasAttrib=r;function a(c){return c.name}$r.getName=a;function o(c){for(var d,h=c.next;h!==null&&!(0,t.isTag)(h);)d=h,h=d.next;return h}$r.nextElementSibling=o;function l(c){for(var d,h=c.prev;h!==null&&!(0,t.isTag)(h);)d=h,h=d.prev;return h}return $r.prevElementSibling=l,$r}var vn={},QD;function pJ(){if(QD)return vn;QD=1,Object.defineProperty(vn,"__esModule",{value:!0}),vn.prepend=vn.prependChild=vn.append=vn.appendChild=vn.replaceElement=vn.removeElement=void 0;function t(a){if(a.prev&&(a.prev.next=a.next),a.next&&(a.next.prev=a.prev),a.parent){var o=a.parent.children,l=o.lastIndexOf(a);l>=0&&o.splice(l,1)}a.next=null,a.prev=null,a.parent=null}vn.removeElement=t;function e(a,o){var l=o.prev=a.prev;l&&(l.next=o);var c=o.next=a.next;c&&(c.prev=o);var d=o.parent=a.parent;if(d){var h=d.children;h[h.lastIndexOf(a)]=o,a.parent=null}}vn.replaceElement=e;function u(a,o){if(t(o),o.next=null,o.parent=a,a.children.push(o)>1){var l=a.children[a.children.length-2];l.next=o,o.prev=l}else o.prev=null}vn.appendChild=u;function s(a,o){t(o);var l=a.parent,c=a.next;if(o.next=c,o.prev=a,a.next=o,o.parent=l,c){if(c.prev=o,l){var d=l.children;d.splice(d.lastIndexOf(c),0,o)}}else l&&l.children.push(o)}vn.append=s;function n(a,o){if(t(o),o.parent=a,o.prev=null,a.children.unshift(o)!==1){var l=a.children[1];l.prev=o,o.next=l}else o.next=null}vn.prependChild=n;function r(a,o){t(o);var l=a.parent;if(l){var c=l.children;c.splice(c.indexOf(a),0,o)}a.prev&&(a.prev.next=o),o.parent=l,o.prev=a.prev,o.next=a,a.prev=o}return vn.prepend=r,vn}var wn={},VD;function qq(){if(VD)return wn;VD=1,Object.defineProperty(wn,"__esModule",{value:!0}),wn.findAll=wn.existsOne=wn.findOne=wn.findOneChild=wn.find=wn.filter=void 0;var t=ui();function e(o,l,c,d){return c===void 0&&(c=!0),d===void 0&&(d=1/0),u(o,Array.isArray(l)?l:[l],c,d)}wn.filter=e;function u(o,l,c,d){for(var h=[],f=[l],p=[0];;){if(p[0]>=f[0].length){if(p.length===1)return h;f.shift(),p.shift();continue}var y=f[0][p[0]++];if(o(y)&&(h.push(y),--d<=0))return h;c&&(0,t.hasChildren)(y)&&y.children.length>0&&(p.unshift(0),f.unshift(y.children))}}wn.find=u;function s(o,l){return l.find(o)}wn.findOneChild=s;function n(o,l,c){c===void 0&&(c=!0);for(var d=null,h=0;h0&&(d=n(o,f.children,!0));else continue}return d}wn.findOne=n;function r(o,l){return l.some(function(c){return(0,t.isTag)(c)&&(o(c)||r(o,c.children))})}wn.existsOne=r;function a(o,l){for(var c=[],d=[l],h=[0];;){if(h[0]>=d[0].length){if(d.length===1)return c;d.shift(),h.shift();continue}var f=d[0][h[0]++];(0,t.isTag)(f)&&(o(f)&&c.push(f),f.children.length>0&&(h.unshift(0),d.unshift(f.children)))}}return wn.findAll=a,wn}var Gn={},kD;function Bq(){if(kD)return Gn;kD=1,Object.defineProperty(Gn,"__esModule",{value:!0}),Gn.getElementsByTagType=Gn.getElementsByTagName=Gn.getElementById=Gn.getElements=Gn.testElement=void 0;var t=ui(),e=qq(),u={tag_name:function(h){return typeof h=="function"?function(f){return(0,t.isTag)(f)&&h(f.name)}:h==="*"?t.isTag:function(f){return(0,t.isTag)(f)&&f.name===h}},tag_type:function(h){return typeof h=="function"?function(f){return h(f.type)}:function(f){return f.type===h}},tag_contains:function(h){return typeof h=="function"?function(f){return(0,t.isText)(f)&&h(f.data)}:function(f){return(0,t.isText)(f)&&f.data===h}}};function s(h,f){return typeof f=="function"?function(p){return(0,t.isTag)(p)&&f(p.attribs[h])}:function(p){return(0,t.isTag)(p)&&p.attribs[h]===f}}function n(h,f){return function(p){return h(p)||f(p)}}function r(h){var f=Object.keys(h).map(function(p){var y=h[p];return Object.prototype.hasOwnProperty.call(u,p)?u[p](y):s(p,y)});return f.length===0?null:f.reduce(n)}function a(h,f){var p=r(h);return p?p(f):!0}Gn.testElement=a;function o(h,f,p,y){y===void 0&&(y=1/0);var b=r(h);return b?(0,e.filter)(b,f,p,y):[]}Gn.getElements=o;function l(h,f,p){return p===void 0&&(p=!0),Array.isArray(f)||(f=[f]),(0,e.findOne)(s("id",h),f,p)}Gn.getElementById=l;function c(h,f,p,y){return p===void 0&&(p=!0),y===void 0&&(y=1/0),(0,e.filter)(u.tag_name(h),f,p,y)}Gn.getElementsByTagName=c;function d(h,f,p,y){return p===void 0&&(p=!0),y===void 0&&(y=1/0),(0,e.filter)(u.tag_type(h),f,p,y)}return Gn.getElementsByTagType=d,Gn}var Mv={},zD;function yJ(){return zD||(zD=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.uniqueSort=t.compareDocumentPosition=t.DocumentPosition=t.removeSubsets=void 0;var e=ui();function u(a){for(var o=a.length;--o>=0;){var l=a[o];if(o>0&&a.lastIndexOf(l,o-1)>=0){a.splice(o,1);continue}for(var c=l.parent;c;c=c.parent)if(a.includes(c)){a.splice(o,1);break}}return a}t.removeSubsets=u;var s;(function(a){a[a.DISCONNECTED=1]="DISCONNECTED",a[a.PRECEDING=2]="PRECEDING",a[a.FOLLOWING=4]="FOLLOWING",a[a.CONTAINS=8]="CONTAINS",a[a.CONTAINED_BY=16]="CONTAINED_BY"})(s=t.DocumentPosition||(t.DocumentPosition={}));function n(a,o){var l=[],c=[];if(a===o)return 0;for(var d=(0,e.hasChildren)(a)?a:a.parent;d;)l.unshift(d),d=d.parent;for(d=(0,e.hasChildren)(o)?o:o.parent;d;)c.unshift(d),d=d.parent;for(var h=Math.min(l.length,c.length),f=0;fy.indexOf(m)?p===o?s.FOLLOWING|s.CONTAINED_BY:s.FOLLOWING:p===a?s.PRECEDING|s.CONTAINS:s.PRECEDING}t.compareDocumentPosition=n;function r(a){return a=a.filter(function(o,l,c){return!c.includes(o,l+1)}),a.sort(function(o,l){var c=n(o,l);return c&s.PRECEDING?-1:c&s.FOLLOWING?1:0}),a}t.uniqueSort=r}(Mv)),Mv}var jl={},GD;function bJ(){if(GD)return jl;GD=1,Object.defineProperty(jl,"__esModule",{value:!0}),jl.getFeed=void 0;var t=Fq(),e=Bq();function u(f){var p=l(h,f);return p?p.name==="feed"?s(p):n(p):null}jl.getFeed=u;function s(f){var p,y=f.children,b={type:"atom",items:(0,e.getElementsByTagName)("entry",y).map(function(v){var _,w=v.children,S={media:o(w)};d(S,"id","id",w),d(S,"title","title",w);var A=(_=l("link",w))===null||_===void 0?void 0:_.attribs.href;A&&(S.link=A);var D=c("summary",w)||c("content",w);D&&(S.description=D);var L=c("updated",w);return L&&(S.pubDate=new Date(L)),S})};d(b,"id","id",y),d(b,"title","title",y);var m=(p=l("link",y))===null||p===void 0?void 0:p.attribs.href;m&&(b.link=m),d(b,"description","subtitle",y);var g=c("updated",y);return g&&(b.updated=new Date(g)),d(b,"author","email",y,!0),b}function n(f){var p,y,b=(y=(p=l("channel",f.children))===null||p===void 0?void 0:p.children)!==null&&y!==void 0?y:[],m={type:f.name.substr(0,3),id:"",items:(0,e.getElementsByTagName)("item",f.children).map(function(v){var _=v.children,w={media:o(_)};d(w,"id","guid",_),d(w,"title","title",_),d(w,"link","link",_),d(w,"description","description",_);var S=c("pubDate",_)||c("dc:date",_);return S&&(w.pubDate=new Date(S)),w})};d(m,"title","title",b),d(m,"link","link",b),d(m,"description","description",b);var g=c("lastBuildDate",b);return g&&(m.updated=new Date(g)),d(m,"author","managingEditor",b,!0),m}var r=["url","type","lang"],a=["fileSize","bitrate","framerate","samplingrate","channels","duration","height","width"];function o(f){return(0,e.getElementsByTagName)("media:content",f).map(function(p){for(var y=p.attribs,b={medium:y.medium,isDefault:!!y.isDefault},m=0,g=r;m0){const c=Object.assign(Object.assign({},a),l);if(r.prefix){let d;for(;d=s.PREFIX_REGEX.exec(r.prefix);)c[d[1]]=d[2]}return c}else return a}static expandPrefixedTerm(r,a){const o=r.indexOf(":");let l,c;if(o>=0&&(l=r.substr(0,o),c=r.substr(o+1)),l==="")return"http://www.w3.org/1999/xhtml/vocab#"+c;if(l){const d=a.prefixesAll[l];if(d)return d+c}if(r){const d=a.prefixesAll[r.toLocaleLowerCase()];if(d)return d}return r}static isValidIri(r){return s.IRI_REGEX.test(r)}static contentTypeToProfile(r){return e.RDFA_CONTENTTYPES[r]||""}getBaseIRI(r){let a=r;const o=a.indexOf("#");return o>=0&&(a=a.substr(0,o)),this.dataFactory.namedNode((0,t.resolve)(a,this.baseIRI.value))}getResourceOrBaseIri(r,a){return r===!0?this.getBaseIriTerm(a):r}getBaseIriTerm(r){return r.localBaseIRI||this.baseIRI}createVocabIris(r,a,o,l){return r.split(/\s+/).filter(c=>c&&(o||c.indexOf(":")>=0)).map(c=>this.createIri(c,a,!0,!0,l)).filter(c=>c!=null)}createLiteral(r,a){if(a.interpretObjectAsTime&&!a.datatype){for(const o of s.TIME_REGEXES)if(r.match(o.regex)){a.datatype=this.dataFactory.namedNode(s.XSD+o.type);break}}return this.dataFactory.literal(r,a.datatype||a.language)}createBlankNode(){return this.blankNodeFactory?this.blankNodeFactory():this.dataFactory.blankNode()}createIri(r,a,o,l,c){if(r=r||"",!l)return o||(r=(0,t.resolve)(r,this.getBaseIriTerm(a).value)),s.isValidIri(r)?this.dataFactory.namedNode(r):null;if(r.length>0&&r[0]==="["&&r[r.length-1]==="]"&&(r=r.substr(1,r.length-2),r.indexOf(":")<0))return null;if(r.startsWith("_:"))return c?this.dataFactory.blankNode(r.substr(2)||"b_identity"):null;if(o&&a.vocab&&r.indexOf(":")<0)return this.dataFactory.namedNode(a.vocab+r);let d=s.expandPrefixedTerm(r,a);return o?r!==d&&(d=(0,t.resolve)(d,this.baseIRIDocument.value)):d=(0,t.resolve)(d,this.getBaseIriTerm(a).value),s.isValidIri(d)?this.dataFactory.namedNode(d):null}}return Ll.Util=s,s.RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#",s.XSD="http://www.w3.org/2001/XMLSchema#",s.RDFA="http://www.w3.org/ns/rdfa#",s.PREFIX_REGEX=/\s*([^:\s]*)*:\s*([^\s]*)*\s*/g,s.TIME_REGEXES=[{regex:/^-?P([0-9]+Y)?([0-9]+M)?([0-9]+D)?(T([0-9]+H)?([0-9]+M)?([0-9]+(\.[0-9])?S)?)?$/,type:"duration"},{regex:/^[0-9]+-[0-9][0-9]-[0-9][0-9]T[0-9][0-9]:[0-9][0-9]:[0-9][0-9]((Z?)|([\+-][0-9][0-9]:[0-9][0-9]))$/,type:"dateTime"},{regex:/^[0-9]+-[0-9][0-9]-[0-9][0-9]Z?$/,type:"date"},{regex:/^[0-9][0-9]:[0-9][0-9]:[0-9][0-9]((Z?)|([\+-][0-9][0-9]:[0-9][0-9]))$/,type:"time"},{regex:/^[0-9]+-[0-9][0-9]$/,type:"gYearMonth"},{regex:/^[0-9]+$/,type:"gYear"}],s.IRI_REGEX=/^([A-Za-z][A-Za-z0-9+-.]*|_):[^ "<>{}|\\\[\]`]*$/,Ll}var YD;function vJ(){if(YD)return Nl;YD=1,Object.defineProperty(Nl,"__esModule",{value:!0}),Nl.RdfaParser=void 0;const t=gJ(),e=Wt(),u=mJ,s=_J,n=WT(),r=Uq();let a=class Hq extends e.Transform{constructor(l){super({readableObjectMode:!0}),this.activeTagStack=[],l=l||{},this.options=l,this.util=new r.Util(l.dataFactory,l.baseIRI),this.defaultGraph=l.defaultGraph||this.util.dataFactory.defaultGraph();const c=l.contentType?r.Util.contentTypeToProfile(l.contentType):l.profile||"";this.features=l.features||n.RDFA_FEATURES[c],this.htmlParseListener=l.htmlParseListener,this.rdfaPatterns=this.features.copyRdfaPatterns?{}:null,this.pendingRdfaPatternCopies=this.features.copyRdfaPatterns?{}:null,this.parser=this.initializeParser(c==="xml"),this.activeTagStack.push({incompleteTriples:[],inlist:!1,language:l.language,listMapping:{},listMappingLocal:{},name:"",prefixesAll:Object.assign(Object.assign({},s["@context"]),this.features.xhtmlInitialContext?u["@context"]:{}),prefixesCustom:{},skipElement:!1,vocab:l.vocab})}import(l){const c=new e.PassThrough({readableObjectMode:!0});l.on("error",h=>d.emit("error",h)),l.on("data",h=>c.push(h)),l.on("end",()=>c.push(null));const d=c.pipe(new Hq(this.options));return d}_transform(l,c,d){this.parser.write(l.toString()),d()}_flush(l){this.parser.end(),l()}onTagOpen(l,c){let d=this.activeTagStack.length-1;for(;d>0&&this.activeTagStack[d].skipElement;)d--;let h=this.activeTagStack[d];d!==this.activeTagStack.length-1&&(h=Object.assign(Object.assign({},h),{language:this.activeTagStack[this.activeTagStack.length-1].language,prefixesAll:this.activeTagStack[this.activeTagStack.length-1].prefixesAll,prefixesCustom:this.activeTagStack[this.activeTagStack.length-1].prefixesCustom,vocab:this.activeTagStack[this.activeTagStack.length-1].vocab}));const f={collectChildTags:h.collectChildTags,incompleteTriples:[],inlist:"inlist"in c,listMapping:[],listMappingLocal:h.listMapping,localBaseIRI:h.localBaseIRI,name:l,prefixesAll:null,prefixesCustom:null,skipElement:!1};if(this.activeTagStack.push(f),f.collectChildTags){for(const S of Object.keys(h.prefixesCustom).sort()){const A=h.prefixesCustom[S],D=S===""?"xmlns":"xmlns:"+S;D in c||(c[D]=A)}const w=Object.keys(c).map(S=>`${S}="${c[S]}"`).join(" ");if(f.text=[`<${l}${w?" "+w:""}>`],this.features.skipHandlingXmlLiteralChildren)return}let p=!0,y=!0;if(this.features.onlyAllowUriRelRevIfProperty&&("property"in c&&"rel"in c&&(p=!1,c.rel.indexOf(":")<0&&delete c.rel),"property"in c&&"rev"in c&&(y=!1,c.rev.indexOf(":")<0&&delete c.rev)),this.features.copyRdfaPatterns){if(h.collectedPatternTag){const w={attributes:c,children:[],name:l,referenced:!1,rootPattern:!1,text:[]};h.collectedPatternTag.children.push(w),f.collectedPatternTag=w;return}if(c.typeof==="rdfa:Pattern"){f.collectedPatternTag={attributes:c,children:[],name:l,parentTag:h,referenced:!1,rootPattern:!0,text:[]};return}if(c.property==="rdfa:copy"){const w=c.resource||c.href||c.src;this.rdfaPatterns[w]?this.emitPatternCopy(h,this.rdfaPatterns[w],w):(this.pendingRdfaPatternCopies[w]||(this.pendingRdfaPatternCopies[w]=[]),this.pendingRdfaPatternCopies[w].push(h));return}}this.features.baseTag&&l==="base"&&c.href&&(this.util.baseIRI=this.util.getBaseIRI(c.href)),this.features.xmlBase&&c["xml:base"]&&(f.localBaseIRI=this.util.getBaseIRI(c["xml:base"])),this.features.timeTag&&l==="time"&&!c.datatype&&(f.interpretObjectAsTime=!0);let b,m,g;if("vocab"in c?c.vocab?(f.vocab=c.vocab,this.emitTriple(this.util.getBaseIriTerm(f),this.util.dataFactory.namedNode(r.Util.RDFA+"usesVocabulary"),this.util.dataFactory.namedNode(f.vocab))):f.vocab=this.activeTagStack[0].vocab:f.vocab=h.vocab,f.prefixesCustom=r.Util.parsePrefixes(c,h.prefixesCustom,this.features.xmlnsPrefixMappings),f.prefixesAll=Object.keys(f.prefixesCustom).length>0?Object.assign(Object.assign({},h.prefixesAll),f.prefixesCustom):h.prefixesAll,this.features.roleAttribute&&c.role){const w=c.id?this.util.createIri("#"+c.id,f,!1,!1,!1):this.util.createBlankNode(),S=f.vocab;f.vocab="http://www.w3.org/1999/xhtml/vocab#";for(const A of this.util.createVocabIris(c.role,f,!0,!1))this.emitTriple(w,this.util.dataFactory.namedNode("http://www.w3.org/1999/xhtml/vocab#role"),A);f.vocab=S}"xml:lang"in c||this.features.langAttribute&&"lang"in c?f.language=c["xml:lang"]||c.lang:f.language=h.language;const v=this.activeTagStack.length===2;if(!("rel"in c)&&!("rev"in c)?"property"in c&&!("content"in c)&&!("datatype"in c)?("about"in c?(b=this.util.createIri(c.about,f,!1,!0,!0),f.explicitNewSubject=!!b):v?b=!0:h.object&&(b=h.object),"typeof"in c&&("about"in c&&(g=this.util.createIri(c.about,f,!1,!0,!0)),!g&&v&&(g=!0),!g&&"resource"in c&&(g=this.util.createIri(c.resource,f,!1,!0,!0)),!g&&("href"in c||"src"in c)&&(g=this.util.createIri(c.href||c.src,f,!1,!1,!0)),!g&&this.isInheritSubjectInHeadBody(l)&&(g=b),g||(g=this.util.createBlankNode()),m=g)):(("about"in c||"resource"in c)&&(b=this.util.createIri(c.about||c.resource,f,!1,!0,!0),f.explicitNewSubject=!!b),!b&&("href"in c||"src"in c)&&(b=this.util.createIri(c.href||c.src,f,!1,!1,!0),f.explicitNewSubject=!!b),b||(v?b=!0:this.isInheritSubjectInHeadBody(l)?b=h.object:"typeof"in c?(b=this.util.createBlankNode(),f.explicitNewSubject=!0):h.object&&(b=h.object,"property"in c||(f.skipElement=!0))),"typeof"in c&&(g=b)):("about"in c?(b=this.util.createIri(c.about,f,!1,!0,!0),f.explicitNewSubject=!!b,"typeof"in c&&(g=b)):v?b=!0:h.object&&(b=h.object),"resource"in c&&(m=this.util.createIri(c.resource,f,!1,!0,!0)),m||("href"in c||"src"in c?m=this.util.createIri(c.href||c.src,f,!1,!1,!0):"typeof"in c&&!("about"in c)&&!this.isInheritSubjectInHeadBody(l)&&(m=this.util.createBlankNode())),"typeof"in c&&!("about"in c)&&(this.isInheritSubjectInHeadBody(l)?g=b:g=m)),g)for(const w of this.util.createVocabIris(c.typeof,f,!0,!0))this.emitTriple(this.util.getResourceOrBaseIri(g,f),this.util.dataFactory.namedNode(r.Util.RDF+"type"),w);if(b&&(f.listMapping={}),m){if("rel"in c&&"inlist"in c)for(const w of this.util.createVocabIris(c.rel,f,p,!1))this.addListMapping(f,b,w,m);if(!("rel"in c&&"inlist"in c)){if("rel"in c)for(const w of this.util.createVocabIris(c.rel,f,p,!1))this.emitTriple(this.util.getResourceOrBaseIri(b,f),w,this.util.getResourceOrBaseIri(m,f));if("rev"in c)for(const w of this.util.createVocabIris(c.rev,f,y,!1))this.emitTriple(this.util.getResourceOrBaseIri(m,f),w,this.util.getResourceOrBaseIri(b,f))}}if(!m){if("rel"in c)if("inlist"in c)for(const w of this.util.createVocabIris(c.rel,f,p,!1))this.addListMapping(f,b,w,null),f.incompleteTriples.push({predicate:w,reverse:!1,list:!0});else for(const w of this.util.createVocabIris(c.rel,f,p,!1))f.incompleteTriples.push({predicate:w,reverse:!1});if("rev"in c)for(const w of this.util.createVocabIris(c.rev,f,y,!1))f.incompleteTriples.push({predicate:w,reverse:!0});f.incompleteTriples.length>0&&(m=this.util.createBlankNode())}if("property"in c){f.predicates=this.util.createVocabIris(c.property,f,!0,!1);let w;if("datatype"in c?(f.datatype=this.util.createIri(c.datatype,f,!0,!0,!1),f.datatype&&(f.datatype.value===r.Util.RDF+"XMLLiteral"||this.features.htmlDatatype&&f.datatype.value===r.Util.RDF+"HTML")&&(f.collectChildTags=!0)):(!("rev"in c)&&!("rel"in c)&&!("content"in c)&&("resource"in c&&(w=this.util.createIri(c.resource,f,!1,!0,!0)),!w&&"href"in c&&(w=this.util.createIri(c.href,f,!1,!1,!0)),!w&&"src"in c&&(w=this.util.createIri(c.src,f,!1,!1,!0))),"typeof"in c&&!("about"in c)&&(w=g)),"content"in c){const S=this.util.createLiteral(c.content,f);if("inlist"in c)for(const A of f.predicates)this.addListMapping(f,b,A,S);else{const A=this.util.getResourceOrBaseIri(b,f);for(const D of f.predicates)this.emitTriple(A,D,S)}f.predicates=null}else if(this.features.datetimeAttribute&&"datetime"in c){f.interpretObjectAsTime=!0;const S=this.util.createLiteral(c.datetime,f);if("inlist"in c)for(const A of f.predicates)this.addListMapping(f,b,A,S);else{const A=this.util.getResourceOrBaseIri(b,f);for(const D of f.predicates)this.emitTriple(A,D,S)}f.predicates=null}else if(w){const S=this.util.getResourceOrBaseIri(w,f);if("inlist"in c)for(const A of f.predicates)this.addListMapping(f,b,A,S);else{const A=this.util.getResourceOrBaseIri(b,f);for(const D of f.predicates)this.emitTriple(A,D,S)}f.predicates=null}}let _=!1;if(!f.skipElement&&b&&h.incompleteTriples.length>0){_=!0;const w=this.util.getResourceOrBaseIri(h.subject,f),S=this.util.getResourceOrBaseIri(b,f);for(const A of h.incompleteTriples)if(A.reverse)this.emitTriple(S,A.predicate,w);else if(A.list){let D=null;for(let L=this.activeTagStack.length-1;L>=0;L--)if(this.activeTagStack[L].inlist){D=this.activeTagStack[L];break}this.addListMapping(D,b,A.predicate,S)}else this.emitTriple(w,A.predicate,S)}!_&&h.incompleteTriples.length>0&&(f.incompleteTriples=f.incompleteTriples.concat(h.incompleteTriples)),f.subject=b||h.subject,f.object=m||b}onText(l){const c=this.activeTagStack[this.activeTagStack.length-1];if(this.features.copyRdfaPatterns&&c.collectedPatternTag){c.collectedPatternTag.text.push(l);return}c.text||(c.text=[]),c.text.push(l)}onTagClose(){const l=this.activeTagStack[this.activeTagStack.length-1],c=this.activeTagStack[this.activeTagStack.length-2];if(!(l.collectChildTags&&c.collectChildTags&&this.features.skipHandlingXmlLiteralChildren)){if(this.features.copyRdfaPatterns&&l.collectedPatternTag&&l.collectedPatternTag.rootPattern){const d=l.collectedPatternTag.attributes.resource;if(delete l.collectedPatternTag.attributes.resource,delete l.collectedPatternTag.attributes.typeof,this.rdfaPatterns[d]=l.collectedPatternTag,this.pendingRdfaPatternCopies[d]){for(const h of this.pendingRdfaPatternCopies[d])this.emitPatternCopy(h,l.collectedPatternTag,d);delete this.pendingRdfaPatternCopies[d]}this.activeTagStack.pop();return}if(l.predicates){const d=this.util.getResourceOrBaseIri(l.subject,l);let h=l.text||[];l.collectChildTags&&c.collectChildTags&&(h=h.slice(1));const f=this.util.createLiteral(h.join(""),l);if(l.inlist)for(const p of l.predicates)this.addListMapping(l,d,p,f);else for(const p of l.predicates)this.emitTriple(d,p,f);c.predicates||(l.text=null)}if(l.object&&Object.keys(l.listMapping).length>0){const d=this.util.getResourceOrBaseIri(l.object,l);for(const h in l.listMapping){const f=this.util.dataFactory.namedNode(h),p=l.listMapping[h];if(p.length>0){const y=p.map(()=>this.util.createBlankNode());for(let b=0;b`),l.text&&c&&(c.text?c.text=c.text.concat(l.text):c.text=l.text)}onEnd(){if(this.features.copyRdfaPatterns){this.features.copyRdfaPatterns=!1;for(const l in this.rdfaPatterns){const c=this.rdfaPatterns[l];c.referenced||(c.attributes.typeof="rdfa:Pattern",c.attributes.resource=l,this.emitPatternCopy(c.parentTag,c,l),c.referenced=!1,delete c.attributes.typeof,delete c.attributes.resource)}for(const l in this.pendingRdfaPatternCopies)for(const c of this.pendingRdfaPatternCopies[l])this.activeTagStack.push(c),this.onTagOpen("link",{property:"rdfa:copy",href:l}),this.onTagClose(),this.activeTagStack.pop();this.features.copyRdfaPatterns=!0}}isInheritSubjectInHeadBody(l){return this.features.inheritSubjectInHeadBody&&(l==="head"||l==="body")}addListMapping(l,c,d,h){if(l.explicitNewSubject){const f=this.util.createBlankNode();this.emitTriple(this.util.getResourceOrBaseIri(c,l),d,f),this.emitTriple(f,this.util.dataFactory.namedNode(r.Util.RDF+"first"),this.util.getResourceOrBaseIri(h,l)),this.emitTriple(f,this.util.dataFactory.namedNode(r.Util.RDF+"rest"),this.util.dataFactory.namedNode(r.Util.RDF+"nil"))}else{let f=l.listMappingLocal[d.value];f||(l.listMappingLocal[d.value]=f=[]),h&&f.push(h)}}emitTriple(l,c,d){l.termType==="NamedNode"&&l.value.indexOf(":")<0||c.termType==="NamedNode"&&c.value.indexOf(":")<0||d.termType==="NamedNode"&&d.value.indexOf(":")<0||this.push(this.util.dataFactory.quad(l,c,d,this.defaultGraph))}emitPatternCopy(l,c,d){if(this.activeTagStack.push(l),c.referenced=!0,!c.constructedBlankNodes)c.constructedBlankNodes=[],this.util.blankNodeFactory=()=>{const h=this.util.dataFactory.blankNode();return c.constructedBlankNodes.push(h),h};else{let h=0;this.util.blankNodeFactory=()=>c.constructedBlankNodes[h++]}this.emitPatternCopyAbsolute(c,!0,d),this.util.blankNodeFactory=null,this.activeTagStack.pop()}emitPatternCopyAbsolute(l,c,d){if(!(!c&&l.attributes.property==="rdfa:copy"&&l.attributes.href===d)){this.onTagOpen(l.name,l.attributes);for(const h of l.text)this.onText(h);for(const h of l.children)this.emitPatternCopyAbsolute(h,!1,d);this.onTagClose()}}initializeParser(l){return new t.Parser({onclosetag:()=>{try{this.onTagClose(),this.htmlParseListener&&this.htmlParseListener.onTagClose()}catch(c){this.emit("error",c)}},onend:()=>{try{this.onEnd(),this.htmlParseListener&&this.htmlParseListener.onEnd()}catch(c){this.emit("error",c)}},onopentag:(c,d)=>{try{this.onTagOpen(c,d),this.htmlParseListener&&this.htmlParseListener.onTagOpen(c,d)}catch(h){this.emit("error",h)}},ontext:c=>{try{this.onText(c),this.htmlParseListener&&this.htmlParseListener.onText(c)}catch(d){this.emit("error",d)}}},{decodeEntities:!0,recognizeSelfClosing:!0,xmlMode:l})}};return Nl.RdfaParser=a,Nl}var ZD;function $q(){return ZD||(ZD=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(iJ(),t),u(aJ(),t),u(sJ(),t),u(vJ(),t),u(WT(),t),u(Uq(),t)}(Tv)),Tv}var eN;function wJ(){if(eN)return Dl;eN=1,Object.defineProperty(Dl,"__esModule",{value:!0}),Dl.ActorRdfParseXmlRdfa=void 0;const t=au(),e=$q();let u=class extends t.ActorRdfParseFixedMediaTypes{constructor(n){super(n)}async runHandle(n,r,a){var c;const o=(n.headers&&n.headers.get("content-language"))??void 0;n.data.on("error",d=>l.emit("error",d));const l=n.data.pipe(new e.RdfaParser({baseIRI:(c=n.metadata)==null?void 0:c.baseIRI,profile:"xml",language:o}));return{data:l,metadata:{triples:!0}}}};return Dl.ActorRdfParseXmlRdfa=u,Dl}var tN;function SJ(){return tN||(tN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(wJ(),t)}(Sv)),Sv}var Fv={},Ml={},h1={},qv,rN;function TJ(){if(rN)return qv;rN=1;var t=function(){var e=function(Ye,Ve,Je,nt){for(Je=Je||{},nt=Ye.length;nt--;Je[Ye[nt]]=Ve);return Je},u=[7,12,13,14,15,16,20,25,115,130],s=[7,13,16,20,25,115,130],n=[7,13,16,115,130],r=[1,25],a=[1,29],o=[1,27],l=[1,28],c=[13,16,115,130],d=[13,16,28,38,40,42,44,46,48,53,56,61,67,85,87,92,93,95,96,102,110,111,115,119,120,126,128,129,130,131,132,133,134,135,136],h=[28,56],f=[1,42],p=[46,48,53,56],y=[1,54],b=[1,60],m=[1,56],g=[1,57],v=[1,58],_=[1,63],w=[1,64],S=[1,65],A=[1,66],D=[1,67],L=[1,68],E=[1,75],O=[28,46,48,53,56],P=[28,42,46,48,53,56],j=[13,16,28,38,40,42,44,46,48,53,56,92,115,119,120,130,131,132,133,134,135,136],U=[13,16,28,38,40,42,44,46,48,53,56,67,85,87,92,95,96,115,119,120,126,128,129,130,131,132,133,134,135,136],M=[13,16,38,40,44,92,115,119,120,130,131,132,133,134,135,136],q=[13,16,28,38,40,42,44,46,48,53,56,67,85,87,92,95,96,115,117,118,119,120,126,128,129,130,131,132,133,134,135,136],Q=[13,16,28,56,115,130],Z=[13,16,38,58,87,96,109,115,126,130],K=[1,116],fe=[1,112],X=[1,108],he=[1,114],xe=[1,111],ie=[7,13,16,20,25,44,48,53,56,67,85,87,95,96,115,128,129,130],ae=[48,53],Oe=[48,53,87,96,126],Ne=[13,16,44,48,53,56,85,87,95,96,115,128,129,130],ge=[1,126],de=[13,16,40,44,48,53,56,85,87,95,96,115,128,129,130],oe=[1,129],$=[48,53,67,87,96,126],N=[13,16,40,44,48,53,56,67,85,87,95,96,115,128,129,130],R=[1,133],T=[13,16,40,44,48,53,56,67,85,87,95,96,102,115,128,129,130],x=[13,16,40,44,48,53,56,67,85,87,93,95,96,102,110,111,115,128,129,130],B=[1,151],k=[1,153],V=[1,156],J=[1,157],z=[1,158],Y=[1,167],te=[1,175],ce=[13,16,44,48,53,56,67,85,87,95,96,115,128,129,130],Ae=[13,16,44,48,53,56,67,85,87,95,96,115,126,128,129,130],Ie=[13,16,46,92,115,119,120,130,131,132,133,134,135,136],Ee={trace:function(){},yy:{},symbols_:{error:2,shaclDoc:3,shaclDoc_repetition0:4,shaclDoc_repetition1:5,ttlSection:6,EOF:7,directive:8,baseDecl:9,importsDecl:10,prefixDecl:11,KW_BASE:12,IRIREF:13,KW_IMPORTS:14,KW_PREFIX:15,PNAME_NS:16,nodeShapeIri:17,iri:18,nodeShape:19,KW_SHAPE:20,nodeShape_option0:21,nodeShape_option1:22,nodeShapeBody:23,shapeClass:24,KW_SHAPE_CLASS:25,shapeClass_option0:26,turtleAnnotation:27,";":28,turtleAnnotation2:29,predicate:30,turtleAnnotation2_option0:31,objectList:32,object:33,objectList_repetition0:34,iriOrLiteral:35,blankNodeSection:36,list:37,"(":38,list_repetition0:39,")":40,objectTail:41,",":42,LB:43,"[":44,RB:45,"]":46,LP:47,"%":48,RP:49,pcSection:50,iriHead:51,ttlStatement:52,".":53,ttlSection_repetition0:54,startNodeShape:55,"{":56,endNodeShape:57,"}":58,nodeShapeBody_repetition0:59,targetClass:60,"->":61,targetClass_repetition_plus0:62,constraint:63,constraint_group0:64,constraint_option0:65,orNotComponent:66,"|":67,nodeNot:68,nodeOrEmit:69,nodeOr:70,nodeOr_repetition_plus0:71,nodeValue:72,negation:73,nodeValue_group0:74,"=":75,iriOrLiteralOrArray:76,propertyShape:77,path:78,propertyShape_repetition0:79,propertyOrComponent:80,propertyNot:81,propertyOr:82,propertyOr_repetition_plus0:83,propertyAtom:84,NODEKIND:85,shapeRef:86,PARAM:87,propertyCount:88,propertyMinCount:89,"..":90,propertyMaxCount:91,INTEGER:92,"*":93,shapeRef_group0:94,"@":95,"!":96,pathAlternative:97,additionalAlternative:98,pathSequence:99,pathAlternative_repetition_plus0:100,additionalSequence:101,"/":102,pathEltOrInverse:103,pathSequence_repetition_plus0:104,pathElt:105,pathPrimary:106,pathMod:107,pathInverse:108,"^":109,"?":110,"+":111,iriOrLiteralOrArray_repetition0:112,literal:113,iri_group0:114,a:115,string:116,LANGTAG:117,"^^":118,DECIMAL:119,DOUBLE:120,literal_group0:121,string_group0:122,string_group1:123,shaclDoc_repetition1_group0:124,constraint_group0_repetition_plus0:125,TARGET:126,propertyShape_repetition0_group0:127,ATPNAME_LN:128,ATPNAME_NS:129,PNAME_LN:130,KW_TRUE:131,KW_FALSE:132,STRING_LITERAL1:133,STRING_LITERAL2:134,STRING_LITERAL_LONG1:135,STRING_LITERAL_LONG2:136,$accept:0,$end:1},terminals_:{2:"error",7:"EOF",12:"KW_BASE",13:"IRIREF",14:"KW_IMPORTS",15:"KW_PREFIX",16:"PNAME_NS",20:"KW_SHAPE",25:"KW_SHAPE_CLASS",28:";",38:"(",40:")",42:",",44:"[",46:"]",48:"%",53:".",56:"{",58:"}",61:"->",67:"|",75:"=",85:"NODEKIND",87:"PARAM",90:"..",92:"INTEGER",93:"*",95:"@",96:"!",102:"/",109:"^",110:"?",111:"+",115:"a",117:"LANGTAG",118:"^^",119:"DECIMAL",120:"DOUBLE",126:"TARGET",128:"ATPNAME_LN",129:"ATPNAME_NS",130:"PNAME_LN",131:"KW_TRUE",132:"KW_FALSE",133:"STRING_LITERAL1",134:"STRING_LITERAL2",135:"STRING_LITERAL_LONG1",136:"STRING_LITERAL_LONG2"},productions_:[0,[3,4],[8,1],[8,1],[8,1],[9,2],[10,2],[11,3],[17,1],[19,5],[24,4],[27,2],[29,2],[30,2],[32,2],[33,1],[33,1],[33,1],[37,3],[41,2],[43,1],[45,1],[36,3],[47,1],[49,1],[50,3],[51,1],[52,3],[6,1],[55,1],[57,1],[23,3],[60,2],[63,3],[66,2],[69,1],[70,1],[70,2],[68,1],[68,2],[72,3],[77,2],[80,2],[82,1],[82,2],[81,1],[81,2],[84,1],[84,1],[84,1],[84,3],[84,1],[88,5],[89,1],[91,1],[91,1],[86,1],[86,2],[73,1],[78,1],[98,2],[97,1],[97,2],[101,2],[99,1],[99,2],[105,1],[105,2],[103,1],[103,2],[108,1],[107,1],[107,1],[107,1],[106,1],[106,3],[76,1],[76,3],[35,1],[35,1],[18,1],[18,1],[18,1],[113,1],[113,2],[113,3],[113,1],[113,1],[113,1],[113,1],[116,1],[116,1],[4,0],[4,2],[124,1],[124,1],[5,0],[5,2],[21,0],[21,1],[22,0],[22,1],[26,0],[26,1],[31,0],[31,1],[34,0],[34,2],[39,0],[39,2],[54,0],[54,2],[59,0],[59,2],[62,1],[62,2],[125,1],[125,2],[64,1],[64,1],[65,0],[65,1],[71,1],[71,2],[74,1],[74,1],[127,1],[127,1],[79,0],[79,2],[83,1],[83,2],[94,1],[94,1],[100,1],[100,2],[104,1],[104,2],[112,0],[112,2],[114,1],[114,1],[121,1],[121,1],[122,1],[122,1],[123,1],[123,1]],performAction:function(Ve,Je,nt,yt,ft,et,Ir){var Ke=et.length-1;switch(ft){case 1:this.$=C(Fe.factory.namedNode(Le("")),Fe.factory.namedNode(G),Fe.factory.namedNode(Se+"Ontology"));break;case 5:Fe.base=Fe.factory.namedNode(et[Ke].slice(1,-1)),Fe.n3Parser._setBase(Fe.base.value);break;case 6:this.$=C(Fe.base,Fe.factory.namedNode(Se+"imports"),Fe.factory.namedNode(et[Ke].slice(1,-1)));break;case 7:this.$=Fe.prefixes[et[Ke-1].substr(0,et[Ke-1].length-1)]=Le(et[Ke]);break;case 8:Fe.nodeShapeStack=!1,C(Fe.currentNodeShape=et[Ke],Fe.factory.namedNode(G),Fe.factory.namedNode(me+"NodeShape"));break;case 10:this.$=C(Fe.currentNodeShape,Fe.factory.namedNode(G),Fe.factory.namedNode(W+"Class"));break;case 11:this.$=De();break;case 13:this.$=et[Ke].forEach(Me=>C(Fe.currentNodeShape,et[Ke-1],Me));break;case 14:this.$=[et[Ke-1],...et[Ke]];break;case 18:this.$=Te(et[Ke-1],!0);break;case 19:case 34:case 42:case 60:case 63:this.$=et[Ke];break;case 20:Fe.tempCurrentNodeShape=Fe.currentNodeShape,this.$=Fe.currentNodeShape=lt();break;case 21:Fe.currentNodeShape=Fe.tempCurrentNodeShape;break;case 22:case 31:this.$=et[Ke-2];break;case 23:Fe.tempCurrentNodeShape=Fe.currentNodeShape,Fe.currentNodeShape=Fe.currentPropertyNode;break;case 24:Fe.currentNodeShape=Fe.tempCurrentNodeShape;break;case 26:Fe.currentNodeShape=et[Ke];break;case 29:Fe.nodeShapeStack?(Fe.nodeShapeStack.push(Fe.currentNodeShape),C(Fe.currentPropertyNode,Fe.factory.namedNode(me+"node"),Fe.currentNodeShape=lt())):Fe.nodeShapeStack=[],this.$=Fe.currentNodeShape;break;case 30:Fe.nodeShapeStack.length>0&&(Fe.currentNodeShape=Fe.nodeShapeStack.pop());break;case 32:this.$=et[Ke].forEach(Me=>{C(Fe.currentNodeShape,Fe.factory.namedNode(me+"targetClass"),Me)});break;case 35:this.$=C(Fe.currentNodeShape,Fe.factory.namedNode(me+et[Ke][0]),et[Ke][1]);break;case 36:break;case 37:const ye=Te([et[Ke-1],...et[Ke]].map(Me=>{const it=lt();return C(it,Fe.factory.namedNode(me+Me[0]),Me[1]),it}));this.$=["or",ye];break;case 39:case 46:this.$=pe("not",...et[Ke]);break;case 40:case 50:this.$=[et[Ke-2],et[Ke]];break;case 43:this.$=et[Ke]&&ee(...et[Ke]);break;case 44:this.$=ee("or",Te([et[Ke-1],...et[Ke]].map(Me=>{const it=lt();return C(it,Fe.factory.namedNode(me+Me[0]),Me[1]),it})));break;case 47:this.$=[we[et[Ke].value]?"datatype":"class",et[Ke]];break;case 48:this.$=["nodeKind",Fe.factory.namedNode(me+et[Ke])];break;case 49:this.$=["node",Fe.factory.namedNode(et[Ke])];break;case 51:this.$=void 0;break;case 53:this.$=et[Ke]>0&&ee("minCount",We(et[Ke],Re));break;case 54:this.$=ee("maxCount",We(et[Ke],Re));break;case 56:this.$=$e(et[Ke].slice(1));break;case 57:this.$=Le(et[Ke]);break;case 59:C(Fe.currentNodeShape,Fe.factory.namedNode(me+"property"),Fe.currentPropertyNode=lt()),ee("path",et[Ke]);break;case 62:const Pe=lt();C(Pe,Fe.factory.namedNode(me+"alternativePath"),Te([et[Ke-1],...et[Ke]])),this.$=Pe;break;case 65:this.$=Te([et[Ke-1],...et[Ke]]);break;case 67:C(this.$=lt(),Fe.factory.namedNode(me+et[Ke]),et[Ke-1]);break;case 69:C(this.$=lt(),Fe.factory.namedNode(me+"inversePath"),et[Ke]);break;case 71:this.$="zeroOrOnePath";break;case 72:this.$="zeroOrMorePath";break;case 73:this.$="oneOrMorePath";break;case 75:this.$=et[Ke-1];break;case 77:this.$=Te(et[Ke-1]);break;case 80:this.$=Fe.factory.namedNode(Le(et[Ke]));break;case 81:this.$=Fe.factory.namedNode($e(et[Ke]));break;case 82:this.$=De(Fe.factory.namedNode(G));break;case 83:this.$=We(et[Ke]);break;case 84:this.$=tt(et[Ke-1],lowercase(et[Ke].substr(1)));break;case 85:this.$=We(et[Ke-2],et[Ke]);break;case 86:this.$=We(et[Ke],Re);break;case 87:this.$=We(et[Ke],Ce);break;case 88:this.$=We(et[Ke].toLowerCase(),Qe);break;case 89:this.$=We(et[Ke].toLowerCase(),ke);break;case 90:this.$=le(et[Ke],1);break;case 91:this.$=le(et[Ke],3);break;case 92:case 96:case 106:case 108:case 110:case 112:case 128:case 138:this.$=[];break;case 93:case 97:case 107:case 109:case 111:case 113:case 115:case 117:case 123:case 129:case 131:case 135:case 137:case 139:et[Ke-1].push(et[Ke]);break;case 114:case 116:case 122:case 130:case 134:case 136:this.$=[et[Ke]];break}},table:[e(u,[2,92],{3:1,4:2}),{1:[3]},e(s,[2,96],{5:3,8:4,9:5,10:6,11:7,12:[1,8],14:[1,9],15:[1,10]}),e(n,[2,110],{6:11,124:12,54:13,19:14,24:15,20:[1,16],25:[1,17]}),e(u,[2,93]),e(u,[2,2]),e(u,[2,3]),e(u,[2,4]),{13:[1,18]},{13:[1,19]},{16:[1,20]},{7:[1,21]},e(s,[2,97]),{7:[2,28],13:r,16:a,18:24,51:23,52:22,114:26,115:o,130:l},e(s,[2,94]),e(s,[2,95]),{13:r,16:a,17:30,18:31,114:26,115:o,130:l},{13:r,16:a,17:32,18:31,114:26,115:o,130:l},e(u,[2,5]),e(u,[2,6]),{13:[1,33]},{1:[2,1]},e(n,[2,111]),{13:r,16:a,18:36,29:34,30:35,114:26,115:o,130:l},e(c,[2,26]),e(d,[2,80]),e(d,[2,81]),e(d,[2,82]),e(d,[2,140]),e(d,[2,141]),e(h,[2,98],{21:37,60:38,61:[1,39]}),e([28,56,61],[2,8]),{26:40,27:41,28:f,56:[2,102]},e(u,[2,7]),{53:[1,43]},e(p,[2,104],{31:44,27:45,28:f}),{13:r,16:a,18:51,32:46,33:47,35:48,36:49,37:50,38:y,43:53,44:b,92:m,113:52,114:26,115:o,116:55,119:g,120:v,121:59,122:61,123:62,130:l,131:_,132:w,133:S,134:A,135:D,136:L},{22:69,27:70,28:f,56:[2,100]},e(h,[2,99]),{13:r,16:a,18:72,62:71,114:26,115:o,130:l},{23:73,55:74,56:E},{56:[2,103]},{13:r,16:a,18:36,29:76,30:35,114:26,115:o,130:l},e(n,[2,27]),e(p,[2,12]),e(p,[2,105]),e(O,[2,13]),e(P,[2,106],{34:77}),e(j,[2,15]),e(j,[2,16]),e(j,[2,17]),e(U,[2,78]),e(U,[2,79]),{13:r,16:a,18:36,29:78,30:35,114:26,115:o,130:l},e(M,[2,108],{39:79}),e(U,[2,83],{117:[1,80],118:[1,81]}),e(U,[2,86]),e(U,[2,87]),e(U,[2,88]),e(U,[2,89]),e(c,[2,20]),e(q,[2,90]),e(q,[2,91]),e(U,[2,142]),e(U,[2,143]),e(q,[2,144]),e(q,[2,145]),e(q,[2,146]),e(q,[2,147]),{23:82,55:74,56:E},{56:[2,101]},e(h,[2,32],{114:26,18:83,13:r,16:a,115:o,130:l}),e(Q,[2,114]),e(s,[2,10]),e(Z,[2,112],{59:84}),e(Z,[2,29]),e(p,[2,11]),e(O,[2,14],{41:85,42:[1,86]}),{45:87,46:[1,88]},{13:r,16:a,18:51,33:90,35:48,36:49,37:50,38:y,40:[1,89],43:53,44:b,92:m,113:52,114:26,115:o,116:55,119:g,120:v,121:59,122:61,123:62,130:l,131:_,132:w,133:S,134:A,135:D,136:L},e(U,[2,84]),{13:r,16:a,18:91,114:26,115:o,130:l},e(s,[2,9]),e(Q,[2,115]),{13:r,16:a,18:115,38:K,57:92,58:[1,94],63:93,64:95,68:102,69:98,70:100,72:104,73:105,74:107,77:97,78:99,87:fe,96:X,97:101,99:103,103:106,105:109,106:113,108:110,109:he,114:26,115:o,125:96,126:xe,130:l},e(P,[2,107]),{13:r,16:a,18:51,33:117,35:48,36:49,37:50,38:y,43:53,44:b,92:m,113:52,114:26,115:o,116:55,119:g,120:v,121:59,122:61,123:62,130:l,131:_,132:w,133:S,134:A,135:D,136:L},e(j,[2,22]),e(j,[2,21]),e(j,[2,18]),e(M,[2,109]),e(U,[2,85]),e(ie,[2,31]),e(Z,[2,113]),e(ie,[2,30]),{47:120,48:[1,121],50:119,53:[2,120],65:118},e(ae,[2,118],{70:100,68:102,72:104,73:105,74:107,69:122,87:fe,96:X,126:xe}),e(ae,[2,119]),e(Oe,[2,116]),e(Ne,[2,128],{79:123}),e(Oe,[2,35]),e(Ne,[2,59]),e(Oe,[2,36],{71:124,66:125,67:ge}),e(de,[2,61],{100:127,98:128,67:oe}),e($,[2,38]),{72:130,74:107,87:fe,126:xe},e(N,[2,64],{104:131,101:132,102:R}),{75:[1,134]},e([13,16,56,85,87,95,115,126,128,129,130],[2,58]),e(T,[2,68]),{13:r,16:a,18:115,38:K,105:135,106:113,114:26,115:o,130:l},{75:[2,124]},{75:[2,125]},e(T,[2,66],{107:136,93:[1,138],110:[1,137],111:[1,139]}),e([13,16,38,115,130],[2,70]),e(x,[2,74]),{13:r,16:a,18:115,38:K,97:140,99:103,103:106,105:109,106:113,108:110,109:he,114:26,115:o,130:l},e(P,[2,19]),{53:[1,141]},{53:[2,121]},{13:r,16:a,18:36,29:142,30:35,114:26,115:o,130:l},e(c,[2,23]),e(Oe,[2,117]),e(ae,[2,41],{114:26,55:74,127:143,88:144,82:145,81:147,84:148,73:149,18:150,86:152,23:154,94:155,13:r,16:a,44:[1,146],56:E,85:B,87:k,95:V,96:X,115:o,128:J,129:z,130:l}),e(Oe,[2,37],{66:159,67:ge}),e($,[2,122]),{68:160,72:104,73:105,74:107,87:fe,96:X,126:xe},e(de,[2,62],{98:161,67:oe}),e(N,[2,134]),{13:r,16:a,18:115,38:K,99:162,103:106,105:109,106:113,108:110,109:he,114:26,115:o,130:l},e($,[2,39]),e(N,[2,65],{101:163,102:R}),e(T,[2,136]),{13:r,16:a,18:115,38:K,103:164,105:109,106:113,108:110,109:he,114:26,115:o,130:l},{13:r,16:a,18:51,35:166,44:Y,76:165,92:m,113:52,114:26,115:o,116:55,119:g,120:v,121:59,122:61,123:62,130:l,131:_,132:w,133:S,134:A,135:D,136:L},e(T,[2,69]),e(T,[2,67]),e(T,[2,71]),e(T,[2,72]),e(T,[2,73]),{40:[1,168]},e(Z,[2,33]),{48:[1,170],49:169},e(Ne,[2,129]),e(Ne,[2,126]),e(Ne,[2,127]),{89:171,92:[1,172]},e(Ne,[2,43],{83:173,80:174,67:te}),e(ce,[2,45]),{13:r,16:a,18:150,23:154,55:74,56:E,84:176,85:B,86:152,87:k,94:155,95:V,114:26,115:o,128:J,129:z,130:l},e(ce,[2,47]),e(ce,[2,48]),e(ce,[2,49]),{75:[1,177]},e(ce,[2,51]),e(ce,[2,56]),{13:[1,178]},e(ce,[2,132]),e(ce,[2,133]),e($,[2,123]),e($,[2,34]),e(N,[2,135]),e(N,[2,60]),e(T,[2,137]),e(T,[2,63]),e($,[2,40]),e(Ae,[2,76]),e(Ie,[2,138],{112:179}),e(x,[2,75]),{53:[2,25]},{53:[2,24]},{90:[1,180]},{90:[2,53]},e(Ne,[2,44],{80:181,67:te}),e(ce,[2,130]),{13:r,16:a,18:150,23:154,55:74,56:E,73:149,81:182,84:148,85:B,86:152,87:k,94:155,95:V,96:X,114:26,115:o,128:J,129:z,130:l},e(ce,[2,46]),{13:r,16:a,18:51,35:166,44:Y,76:183,92:m,113:52,114:26,115:o,116:55,119:g,120:v,121:59,122:61,123:62,130:l,131:_,132:w,133:S,134:A,135:D,136:L},e(ce,[2,57]),{13:r,16:a,18:51,35:185,46:[1,184],92:m,113:52,114:26,115:o,116:55,119:g,120:v,121:59,122:61,123:62,130:l,131:_,132:w,133:S,134:A,135:D,136:L},{91:186,92:[1,187],93:[1,188]},e(ce,[2,131]),e(ce,[2,42]),e(ce,[2,50]),e(Ae,[2,77]),e(Ie,[2,139]),{46:[1,189]},{46:[2,54]},{46:[2,55]},e(Ne,[2,52])],defaultActions:{21:[2,1],41:[2,103],70:[2,101],111:[2,124],112:[2,125],119:[2,121],169:[2,25],170:[2,24],172:[2,53],187:[2,54],188:[2,55]},parseError:function(Ve,Je){if(Je.recoverable)this.trace(Ve);else{var nt=new Error(Ve);throw nt.hash=Je,nt}},parse:function(Ve){var Je=this,nt=[0],yt=[null],ft=[],et=this.table,Ir="",Ke=0,ye=0,Pe=2,Me=1,it=ft.slice.call(arguments,1),at=Object.create(this.lexer),Tt={yy:{}};for(var Vt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,Vt)&&(Tt.yy[Vt]=this.yy[Vt]);at.setInput(Ve,Tt.yy),Tt.yy.lexer=at,Tt.yy.parser=this,typeof at.yylloc>"u"&&(at.yylloc={});var tr=at.yylloc;ft.push(tr);var di=at.options&&at.options.ranges;typeof Tt.yy.parseError=="function"?this.parseError=Tt.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var yn=function(){var Xr;return Xr=at.lex()||Me,typeof Xr!="number"&&(Xr=Je.symbols_[Xr]||Xr),Xr},or,Mn,Hr,Hn,Pr={},fi,Mr,Ni,Zi;;){if(Mn=nt[nt.length-1],this.defaultActions[Mn]?Hr=this.defaultActions[Mn]:((or===null||typeof or>"u")&&(or=yn()),Hr=et[Mn]&&et[Mn][or]),typeof Hr>"u"||!Hr.length||!Hr[0]){var bn="";Zi=[];for(fi in et[Mn])this.terminals_[fi]&&fi>Pe&&Zi.push("'"+this.terminals_[fi]+"'");at.showPosition?bn="Parse error on line "+(Ke+1)+`: -`+at.showPosition()+` -Expecting `+Zi.join(", ")+", got '"+(this.terminals_[or]||or)+"'":bn="Parse error on line "+(Ke+1)+": Unexpected "+(or==Me?"end of input":"'"+(this.terminals_[or]||or)+"'"),this.parseError(bn,{text:at.match,token:this.terminals_[or]||or,line:at.yylineno,loc:tr,expected:Zi})}if(Hr[0]instanceof Array&&Hr.length>1)throw new Error("Parse Error: multiple actions possible at state: "+Mn+", token: "+or);switch(Hr[0]){case 1:nt.push(or),yt.push(at.yytext),ft.push(at.yylloc),nt.push(Hr[1]),or=null,ye=at.yyleng,Ir=at.yytext,Ke=at.yylineno,tr=at.yylloc;break;case 2:if(Mr=this.productions_[Hr[1]][1],Pr.$=yt[yt.length-Mr],Pr._$={first_line:ft[ft.length-(Mr||1)].first_line,last_line:ft[ft.length-1].last_line,first_column:ft[ft.length-(Mr||1)].first_column,last_column:ft[ft.length-1].last_column},di&&(Pr._$.range=[ft[ft.length-(Mr||1)].range[0],ft[ft.length-1].range[1]]),Hn=this.performAction.apply(Pr,[Ir,ye,Ke,Tt.yy,Hr[1],yt,ft].concat(it)),typeof Hn<"u")return Hn;Mr&&(nt=nt.slice(0,-1*Mr*2),yt=yt.slice(0,-1*Mr),ft=ft.slice(0,-1*Mr)),nt.push(this.productions_[Hr[1]][0]),yt.push(Pr.$),ft.push(Pr._$),Ni=et[nt[nt.length-2]][nt[nt.length-1]],nt.push(Ni);break;case 3:return!0}}return!0}};const qe="http://www.w3.org/1999/02/22-rdf-syntax-ns#",G=qe+"type",F=qe+"first",H=qe+"rest",re=qe+"nil",be="http://www.w3.org/2001/XMLSchema#",Re=be+"integer",Ce=be+"decimal",Qe=be+"double",ke=be+"boolean",me="http://www.w3.org/ns/shacl#",Se="http://www.w3.org/2002/07/owl#",W="http://www.w3.org/2000/01/rdf-schema#",we={[Re]:!0,[Ce]:!0,[be+"float"]:!0,[Qe]:!0,[be+"string"]:!0,[ke]:!0,[be+"dateTime"]:!0,[be+"nonPositiveInteger"]:!0,[be+"negativeInteger"]:!0,[be+"long"]:!0,[be+"int"]:!0,[be+"short"]:!0,[be+"byte"]:!0,[be+"nonNegativeInteger"]:!0,[be+"unsignedLong"]:!0,[be+"unsignedShort"]:!0,[be+"unsignedByte"]:!0,[be+"positiveInteger"]:!0,[qe+"langString"]:!0};function Te(Ye,Ve=!1){let Je=0,nt=Ye.length;if(Ve&&nt===0)return Fe.factory.namedNode(re);const yt=head=lt();return nt===0&&C(head,Fe.factory.namedNode(H),Fe.factory.namedNode(re)),Ye.forEach(ft=>{if(ft===void 0)throw new Error("b");C(head,Fe.factory.namedNode(F),ft),C(head,Fe.factory.namedNode(H),head=++Je20?"...":"")+Ve.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var Ve=this.match;return Ve.length<20&&(Ve+=this._input.substr(0,20-Ve.length)),(Ve.substr(0,20)+(Ve.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var Ve=this.pastInput(),Je=new Array(Ve.length+1).join("-");return Ve+this.upcomingInput()+` -`+Je+"^"},test_match:function(Ve,Je){var nt,yt,ft;if(this.options.backtrack_lexer&&(ft={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(ft.yylloc.range=this.yylloc.range.slice(0))),yt=Ve[0].match(/(?:\r\n?|\n).*/g),yt&&(this.yylineno+=yt.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:yt?yt[yt.length-1].length-yt[yt.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+Ve[0].length},this.yytext+=Ve[0],this.match+=Ve[0],this.matches=Ve,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(Ve[0].length),this.matched+=Ve[0],nt=this.performAction.call(this,this.yy,this,Je,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),nt)return nt;if(this._backtrack){for(var et in ft)this[et]=ft[et];return!1}return!1},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var Ve,Je,nt,yt;this._more||(this.yytext="",this.match="");for(var ft=this._currentRules(),et=0;etJe[0].length)){if(Je=nt,yt=et,this.options.backtrack_lexer){if(Ve=this.test_match(nt,ft[et]),Ve!==!1)return Ve;if(this._backtrack){Je=!1;continue}else return!1}else if(!this.options.flex)break}return Je?(Ve=this.test_match(Je,ft[yt]),Ve!==!1?Ve:!1):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text. -`+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var Je=this.next();return Je||this.lex()},begin:function(Je){this.conditionStack.push(Je)},popState:function(){var Je=this.conditionStack.length-1;return Je>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(Je){return Je=this.conditionStack.length-1-Math.abs(Je||0),Je>=0?this.conditionStack[Je]:"INITIAL"},pushState:function(Je){this.begin(Je)},stateStackSize:function(){return this.conditionStack.length},options:{flex:!0,"case-insensitive":!0},performAction:function(Je,nt,yt,ft){switch(yt){case 0:break;case 1:return 12;case 2:return 14;case 3:return 15;case 4:return 25;case 5:return 20;case 6:return 131;case 7:return 132;case 8:return 85;case 9:return 126;case 10:return 87;case 11:return"PASS";case 12:return"COMMENT";case 13:return 13;case 14:return 16;case 15:return 130;case 16:return 129;case 17:return 128;case 18:return 117;case 19:return 92;case 20:return 119;case 21:return 120;case 22:return"EXPONENT";case 23:return 133;case 24:return 134;case 25:return 135;case 26:return 136;case 27:return 61;case 28:return 90;case 29:return 58;case 30:return 56;case 31:return 38;case 32:return 40;case 33:return 44;case 34:return 46;case 35:return 110;case 36:return 93;case 37:return 111;case 38:return 67;case 39:return 118;case 40:return 53;case 41:return 96;case 42:return 102;case 43:return 75;case 44:return 95;case 45:return 109;case 46:return 28;case 47:return 42;case 48:return 48;case 49:return 115;case 50:return 7;case 51:console.log(nt.yytext);break}},rules:[/^(?:\s+|#[^\n\r]*)/i,/^(?:BASE)/i,/^(?:IMPORTS)/i,/^(?:PREFIX)/i,/^(?:shapeClass)/i,/^(?:shape)/i,/^(?:true)/i,/^(?:false)/i,/^(?:(BlankNode|IRI|Literal|BlankNodeOrIRI|BlankNodeOrLiteral|IRIOrLiteral\b))/i,/^(?:(targetNode|targetObjectsOf|targetSubjectsOf\b))/i,/^(?:(deactivated|severity|message|class|datatype|nodeKind|minExclusive|minInclusive|maxExclusive|maxInclusive|minLength|maxLength|pattern|flags|languageIn|uniqueLang|equals|disjoint|lessThan|lessThanOrEquals|qualifiedValueShape|qualifiedMinCount|qualifiedMaxCount|qualifiedValueShapesDisjoint|closed|ignoredProperties|hasValue|in))/i,/^(?:([ \t\r\n]+))/i,/^(?:(#[\r\n]*))/i,/^(?:(<([^=<>\"\{\}\|\^`\\\u0000-\u0020]|(\\u([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])|\\U([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])))*>))/i,/^(?:((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])((((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|\.)*((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040]))?)?:))/i,/^(?:(((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])((((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|\.)*((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040]))?)?:)(((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|:|[0-9]|((%([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%))))((((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|\.|:|((%([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%))))*(((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|:|((%([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%)))))?)))/i,/^(?:(@(([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])((((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|\.)*((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040]))?)?:))/i,/^(?:(@((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])((((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|\.)*((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040]))?)?:)(((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|:|[0-9]|((%([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%))))((((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|\.|:|((%([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%))))*(((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD])|_\b)|-|[0-9]|[\u00B7]|[\u0300-\u036F]|[\u203F-\u2040])|:|((%([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%)))))?)))/i,/^(?:(@[a-zA-Z]+(-[a-zA-Z0-9]+)*))/i,/^(?:([+-]?[0-9]+))/i,/^(?:([+-]?[0-9]*\.[0-9]+))/i,/^(?:([+-]?([0-9]+\.[0-9]*([eE][+-]?[0-9]+)|\.?[0-9]+([eE][+-]?[0-9]+))))/i,/^(?:([eE][+-]?[0-9]+))/i,/^(?:('(?:(?:[^\u0027\u005C\u000A\u000D])|(\\[tbnrf\\\"\']))*'))/i,/^(?:("(?:(?:[^\u0022\u005C\u000A\u000D])|(\\[tbnrf\\\"\']))*"))/i,/^(?:('''(?:(?:'|'')?(?:[^'\\]|(\\[tbnrf\\\"\'])))*'''))/i,/^(?:("""(?:(?:"|"")?(?:[^\"\\]|(\\[tbnrf\\\"\'])))*"""))/i,/^(?:->)/i,/^(?:\.\.)/i,/^(?:\})/i,/^(?:\{)/i,/^(?:\()/i,/^(?:\))/i,/^(?:\[)/i,/^(?:\])/i,/^(?:\?)/i,/^(?:\*)/i,/^(?:\+)/i,/^(?:\|)/i,/^(?:\^\^)/i,/^(?:\.)/i,/^(?:!)/i,/^(?:\/)/i,/^(?:=)/i,/^(?:@)/i,/^(?:\^)/i,/^(?:;)/i,/^(?:,)/i,/^(?:%)/i,/^(?:a)/i,/^(?:$)/i,/^(?:.)/i],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51],inclusive:!0}}};return Ye}();Ee.lexer=Ue;function Fe(){this.yy={}}return Fe.prototype=Ee,Ee.Parser=Fe,new Fe}();return qv=t,qv}var nN;function AJ(){if(nN)return h1;nN=1;const t=TJ().Parser,e=ts;class u{constructor(){}parse(n,{extendedSyntax:r,baseIRI:a}={}){this._parser=new t,this._parser.Parser.factory=e.DataFactory,this._parser.Parser.base=e.DataFactory.namedNode(a||"urn:x-base:default"),this._parser.Parser.extended=r===!0,this._parser.Parser.prefixes={rdf:"http://www.w3.org/1999/02/22-rdf-syntax-ns#",rdfs:"http://www.w3.org/2000/01/rdf-schema#",sh:"http://www.w3.org/ns/shacl#",xsd:"http://www.w3.org/2001/XMLSchema#"},this._parser.Parser.currentNodeShape=void 0,this._parser.Parser.currentPropertyNode=void 0,this._parser.Parser.nodeShapeStack=[],this._parser.Parser.tempCurrentNodeShape=void 0,this._parser.Parser.n3Parser=new e.Parser({baseIRI:a||"urn:x-base:default"});const o=[];return this._parser.Parser.onQuad=l=>{o.push(l)},this._parser.parse(n),o.prefixes=this._parser.Parser.prefixes,o}}return h1.Parser=u,h1.parse=function(n,r){return new u().parse(n,r)},h1}var Bv={exports:{}},iN;function EJ(){return iN||(iN=1,function(t){(function(){var e;typeof window=="object"&&window?e=window:e=I,t.exports?t.exports=e.Promise?e.Promise:r:e.Promise||(e.Promise=r);var u=e.setImmediate||function(f){setTimeout(f,1)};function s(f,p){return function(){f.apply(p,arguments)}}var n=Array.isArray||function(f){return Object.prototype.toString.call(f)==="[object Array]"};function r(f){if(typeof this!="object")throw new TypeError("Promises must be constructed via new");if(typeof f!="function")throw new TypeError("not a function");this._state=null,this._value=null,this._deferreds=[],h(f,s(o,this),s(l,this))}function a(f){var p=this;if(this._state===null){this._deferreds.push(f);return}u(function(){var y=p._state?f.onFulfilled:f.onRejected;if(y===null){(p._state?f.resolve:f.reject)(p._value);return}var b;try{b=y(p._value)}catch(m){f.reject(m);return}f.resolve(b)})}function o(f){try{if(f===this)throw new TypeError("A promise cannot be resolved with itself.");if(f&&(typeof f=="object"||typeof f=="function")){var p=f.then;if(typeof p=="function"){h(s(p,f),s(o,this),s(l,this));return}}this._state=!0,this._value=f,c.call(this)}catch(y){l.call(this,y)}}function l(f){this._state=!1,this._value=f,c.call(this)}function c(){for(var f=0,p=this._deferreds.length;f(this.prefixes=n.prefixes,n)))}read(){if(this.prefixes){for(const s of Object.entries(this.prefixes))this.emit("prefix",...s);delete this.prefixes}return super.read()}};return Fl.PrefixWrappingIterator=e,Fl}var oN;function RJ(){if(oN)return Ml;oN=1,Object.defineProperty(Ml,"__esModule",{value:!0}),Ml.ActorRdfParseShaclc=void 0;const t=au(),e=Wt(),u=AJ(),s=eo(),n=OJ();let r=class extends t.ActorRdfParseFixedMediaTypes{constructor(o){super(o)}async runHandle(o,l,c){const d=new n.PrefixWrappingIterator(s(o.data).then(f=>{var p;return(0,u.parse)(f,{extendedSyntax:l==="text/shaclc-ext",baseIRI:(p=o.metadata)==null?void 0:p.baseIRI})})),h=new e.Readable({objectMode:!0});return d.on("prefix",(...f)=>h.emit("prefix",...f)),{data:h.wrap(d),metadata:{triples:!0}}}};return Ml.ActorRdfParseShaclc=r,Ml}var uN;function xJ(){return uN||(uN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(RJ(),t)}(Fv)),Fv}var Hv={},ql={},$v={},Bl={},mo={},cN;function Qq(){if(cN)return mo;cN=1,Object.defineProperty(mo,"__esModule",{value:!0}),mo.QuoteType=void 0;var t=Ga(),e;(function(c){c[c.Tab=9]="Tab",c[c.NewLine=10]="NewLine",c[c.FormFeed=12]="FormFeed",c[c.CarriageReturn=13]="CarriageReturn",c[c.Space=32]="Space",c[c.ExclamationMark=33]="ExclamationMark",c[c.Number=35]="Number",c[c.Amp=38]="Amp",c[c.SingleQuote=39]="SingleQuote",c[c.DoubleQuote=34]="DoubleQuote",c[c.Dash=45]="Dash",c[c.Slash=47]="Slash",c[c.Zero=48]="Zero",c[c.Nine=57]="Nine",c[c.Semi=59]="Semi",c[c.Lt=60]="Lt",c[c.Eq=61]="Eq",c[c.Gt=62]="Gt",c[c.Questionmark=63]="Questionmark",c[c.UpperA=65]="UpperA",c[c.LowerA=97]="LowerA",c[c.UpperF=70]="UpperF",c[c.LowerF=102]="LowerF",c[c.UpperZ=90]="UpperZ",c[c.LowerZ=122]="LowerZ",c[c.LowerX=120]="LowerX",c[c.OpeningSquareBracket=91]="OpeningSquareBracket"})(e||(e={}));var u;(function(c){c[c.Text=1]="Text",c[c.BeforeTagName=2]="BeforeTagName",c[c.InTagName=3]="InTagName",c[c.InSelfClosingTag=4]="InSelfClosingTag",c[c.BeforeClosingTagName=5]="BeforeClosingTagName",c[c.InClosingTagName=6]="InClosingTagName",c[c.AfterClosingTagName=7]="AfterClosingTagName",c[c.BeforeAttributeName=8]="BeforeAttributeName",c[c.InAttributeName=9]="InAttributeName",c[c.AfterAttributeName=10]="AfterAttributeName",c[c.BeforeAttributeValue=11]="BeforeAttributeValue",c[c.InAttributeValueDq=12]="InAttributeValueDq",c[c.InAttributeValueSq=13]="InAttributeValueSq",c[c.InAttributeValueNq=14]="InAttributeValueNq",c[c.BeforeDeclaration=15]="BeforeDeclaration",c[c.InDeclaration=16]="InDeclaration",c[c.InProcessingInstruction=17]="InProcessingInstruction",c[c.BeforeComment=18]="BeforeComment",c[c.CDATASequence=19]="CDATASequence",c[c.InSpecialComment=20]="InSpecialComment",c[c.InCommentLike=21]="InCommentLike",c[c.BeforeSpecialS=22]="BeforeSpecialS",c[c.BeforeSpecialT=23]="BeforeSpecialT",c[c.SpecialStartSequence=24]="SpecialStartSequence",c[c.InSpecialTag=25]="InSpecialTag",c[c.InEntity=26]="InEntity"})(u||(u={}));function s(c){return c===e.Space||c===e.NewLine||c===e.Tab||c===e.FormFeed||c===e.CarriageReturn}function n(c){return c===e.Slash||c===e.Gt||s(c)}function r(c){return c>=e.LowerA&&c<=e.LowerZ||c>=e.UpperA&&c<=e.UpperZ}var a;(function(c){c[c.NoValue=0]="NoValue",c[c.Unquoted=1]="Unquoted",c[c.Single=2]="Single",c[c.Double=3]="Double"})(a||(mo.QuoteType=a={}));var o={Cdata:new Uint8Array([67,68,65,84,65,91]),CdataEnd:new Uint8Array([93,93,62]),CommentEnd:new Uint8Array([45,45,62]),ScriptEnd:new Uint8Array([60,47,115,99,114,105,112,116]),StyleEnd:new Uint8Array([60,47,115,116,121,108,101]),TitleEnd:new Uint8Array([60,47,116,105,116,108,101]),TextareaEnd:new Uint8Array([60,47,116,101,120,116,97,114,101,97])},l=function(){function c(d,h){var f=d.xmlMode,p=f===void 0?!1:f,y=d.decodeEntities,b=y===void 0?!0:y,m=this;this.cbs=h,this.state=u.Text,this.buffer="",this.sectionStart=0,this.index=0,this.entityStart=0,this.baseState=u.Text,this.isSpecial=!1,this.running=!0,this.offset=0,this.currentSequence=void 0,this.sequenceIndex=0,this.xmlMode=p,this.decodeEntities=b,this.entityDecoder=new t.EntityDecoder(p?t.xmlDecodeTree:t.htmlDecodeTree,function(g,v){return m.emitCodePoint(g,v)})}return c.prototype.reset=function(){this.state=u.Text,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=u.Text,this.currentSequence=void 0,this.running=!0,this.offset=0},c.prototype.write=function(d){this.offset+=this.buffer.length,this.buffer=d,this.parse()},c.prototype.end=function(){this.running&&this.finish()},c.prototype.pause=function(){this.running=!1},c.prototype.resume=function(){this.running=!0,this.indexthis.sectionStart&&this.cbs.ontext(this.sectionStart,this.index),this.state=u.BeforeTagName,this.sectionStart=this.index):this.decodeEntities&&d===e.Amp&&this.startEntity()},c.prototype.stateSpecialStartSequence=function(d){var h=this.sequenceIndex===this.currentSequence.length,f=h?n(d):(d|32)===this.currentSequence[this.sequenceIndex];if(!f)this.isSpecial=!1;else if(!h){this.sequenceIndex++;return}this.sequenceIndex=0,this.state=u.InTagName,this.stateInTagName(d)},c.prototype.stateInSpecialTag=function(d){if(this.sequenceIndex===this.currentSequence.length){if(d===e.Gt||s(d)){var h=this.index-this.currentSequence.length;if(this.sectionStart=0?(this.state=this.baseState,d===0&&(this.index=this.entityStart)):this.index=this.offset+this.buffer.length-1},c.prototype.cleanup=function(){this.running&&this.sectionStart!==this.index&&(this.state===u.Text||this.state===u.InSpecialTag&&this.sequenceIndex===0?(this.cbs.ontext(this.sectionStart,this.index),this.sectionStart=this.index):(this.state===u.InAttributeValueDq||this.state===u.InAttributeValueSq||this.state===u.InAttributeValueNq)&&(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=this.index))},c.prototype.shouldContinue=function(){return this.index=d||(this.state===u.InCommentLike?this.currentSequence===o.CdataEnd?this.cbs.oncdata(this.sectionStart,d,0):this.cbs.oncomment(this.sectionStart,d,0):this.state===u.InTagName||this.state===u.BeforeAttributeName||this.state===u.BeforeAttributeValue||this.state===u.AfterAttributeName||this.state===u.InAttributeName||this.state===u.InAttributeValueSq||this.state===u.InAttributeValueDq||this.state===u.InAttributeValueNq||this.state===u.InClosingTagName||this.cbs.ontext(this.sectionStart,d))},c.prototype.emitCodePoint=function(d,h){this.baseState!==u.Text&&this.baseState!==u.InSpecialTag?(this.sectionStart0&&A.has(this.stack[0]);){var D=this.stack.shift();(_=(v=this.cbs).onclosetag)===null||_===void 0||_.call(v,D,!0)}this.isVoidElement(g)||(this.stack.unshift(g),this.htmlMode&&(f.has(g)?this.foreignContext.unshift(!0):p.has(g)&&this.foreignContext.unshift(!1))),(S=(w=this.cbs).onopentagname)===null||S===void 0||S.call(w,g),this.cbs.onopentag&&(this.attribs={})},m.prototype.endOpenTag=function(g){var v,_;this.startIndex=this.openTagStart,this.attribs&&((_=(v=this.cbs).onopentag)===null||_===void 0||_.call(v,this.tagname,this.attribs,g),this.attribs=null),this.cbs.onclosetag&&this.isVoidElement(this.tagname)&&this.cbs.onclosetag(this.tagname,!0),this.tagname=""},m.prototype.onopentagend=function(g){this.endIndex=g,this.endOpenTag(!1),this.startIndex=g+1},m.prototype.onclosetag=function(g,v){var _,w,S,A,D,L,E,O;this.endIndex=v;var P=this.getSlice(g,v);if(this.lowerCaseTagNames&&(P=P.toLowerCase()),this.htmlMode&&(f.has(P)||p.has(P))&&this.foreignContext.shift(),this.isVoidElement(P))this.htmlMode&&P==="br"&&((A=(S=this.cbs).onopentagname)===null||A===void 0||A.call(S,"br"),(L=(D=this.cbs).onopentag)===null||L===void 0||L.call(D,"br",{},!0),(O=(E=this.cbs).onclosetag)===null||O===void 0||O.call(E,"br",!1));else{var j=this.stack.indexOf(P);if(j!==-1)for(var U=0;U<=j;U++){var M=this.stack.shift();(w=(_=this.cbs).onclosetag)===null||w===void 0||w.call(_,M,U!==j)}else this.htmlMode&&P==="p"&&(this.emitOpenTag("p"),this.closeCurrentTag(!0))}this.startIndex=v+1},m.prototype.onselfclosingtag=function(g){this.endIndex=g,this.recognizeSelfClosing||this.foreignContext[0]?(this.closeCurrentTag(!1),this.startIndex=g+1):this.onopentagend(g)},m.prototype.closeCurrentTag=function(g){var v,_,w=this.tagname;this.endOpenTag(g),this.stack[0]===w&&((_=(v=this.cbs).onclosetag)===null||_===void 0||_.call(v,w,!g),this.stack.shift())},m.prototype.onattribname=function(g,v){this.startIndex=g;var _=this.getSlice(g,v);this.attribname=this.lowerCaseAttributeNames?_.toLowerCase():_},m.prototype.onattribdata=function(g,v){this.attribvalue+=this.getSlice(g,v)},m.prototype.onattribentity=function(g){this.attribvalue+=(0,n.fromCodePoint)(g)},m.prototype.onattribend=function(g,v){var _,w;this.endIndex=v,(w=(_=this.cbs).onattribute)===null||w===void 0||w.call(_,this.attribname,this.attribvalue,g===s.QuoteType.Double?'"':g===s.QuoteType.Single?"'":g===s.QuoteType.NoValue?void 0:null),this.attribs&&!Object.prototype.hasOwnProperty.call(this.attribs,this.attribname)&&(this.attribs[this.attribname]=this.attribvalue),this.attribvalue=""},m.prototype.getInstructionName=function(g){var v=g.search(y),_=v<0?g:g.substr(0,v);return this.lowerCaseTagNames&&(_=_.toLowerCase()),_},m.prototype.ondeclaration=function(g,v){this.endIndex=v;var _=this.getSlice(g,v);if(this.cbs.onprocessinginstruction){var w=this.getInstructionName(_);this.cbs.onprocessinginstruction("!".concat(w),"!".concat(_))}this.startIndex=v+1},m.prototype.onprocessinginstruction=function(g,v){this.endIndex=v;var _=this.getSlice(g,v);if(this.cbs.onprocessinginstruction){var w=this.getInstructionName(_);this.cbs.onprocessinginstruction("?".concat(w),"?".concat(_))}this.startIndex=v+1},m.prototype.oncomment=function(g,v,_){var w,S,A,D;this.endIndex=v,(S=(w=this.cbs).oncomment)===null||S===void 0||S.call(w,this.getSlice(g,v-_)),(D=(A=this.cbs).oncommentend)===null||D===void 0||D.call(A),this.startIndex=v+1},m.prototype.oncdata=function(g,v,_){var w,S,A,D,L,E,O,P,j,U;this.endIndex=v;var M=this.getSlice(g,v-_);!this.htmlMode||this.options.recognizeCDATA?((S=(w=this.cbs).oncdatastart)===null||S===void 0||S.call(w),(D=(A=this.cbs).ontext)===null||D===void 0||D.call(A,M),(E=(L=this.cbs).oncdataend)===null||E===void 0||E.call(L)):((P=(O=this.cbs).oncomment)===null||P===void 0||P.call(O,"[CDATA[".concat(M,"]]")),(U=(j=this.cbs).oncommentend)===null||U===void 0||U.call(j)),this.startIndex=v+1},m.prototype.onend=function(){var g,v;if(this.cbs.onclosetag){this.endIndex=this.startIndex;for(var _=0;_=this.buffers[0].length;)this.shiftBuffer();for(var _=this.buffers[0].slice(g-this.bufferOffset,v-this.bufferOffset);v-this.bufferOffset>this.buffers[0].length;)this.shiftBuffer(),_+=this.buffers[0].slice(0,v-this.bufferOffset);return _},m.prototype.shiftBuffer=function(){this.bufferOffset+=this.buffers[0].length,this.writeIndex--,this.buffers.shift()},m.prototype.write=function(g){var v,_;if(this.ended){(_=(v=this.cbs).onerror)===null||_===void 0||_.call(v,new Error(".write() after done!"));return}this.buffers.push(g),this.tokenizer.running&&(this.tokenizer.write(g),this.writeIndex++)},m.prototype.end=function(g){var v,_;if(this.ended){(_=(v=this.cbs).onerror)===null||_===void 0||_.call(v,new Error(".end() after done!"));return}g&&this.write(g),this.ended=!0,this.tokenizer.end()},m.prototype.pause=function(){this.tokenizer.pause()},m.prototype.resume=function(){for(this.tokenizer.resume();this.tokenizer.running&&this.writeIndex{};let c=0,d=1;function h(b){l.emit("error",b)}function f(){--d===0&&l.push(null)}const p={baseIRI:((y=r.metadata)==null?void 0:y.baseIRI)??"",context:o,emit:b=>{c--,l.push(b)},end:f,error:h,headers:r.headers};try{const b=await Promise.all(this.busRdfParseHtml.publish(p));d+=b.length;const m=[];for(const _ of b){const{htmlParseListener:w}=await _.actor.run(p);m.push(w)}const g=new e.Parser({onclosetag(){try{for(const _ of m)_.onTagClose()}catch(_){h(_)}},onend(){try{for(const _ of m)_.onEnd()}catch(_){h(_)}f()},onopentag(_,w){try{for(const S of m)S.onTagOpen(_,w)}catch(S){h(S)}},ontext(_){try{for(const w of m)w.onText(_)}catch(w){h(w)}}},{decodeEntities:!0,recognizeSelfClosing:!0,xmlMode:!1}),v=l._read=_=>{for(c=Math.max(_,c);c>0;){const w=r.data.read();if(w===null){r.data.once("readable",()=>v(0));return}g.write(w.toString())}};r.data.on("error",h).on("end",()=>g.end())}catch(b){setTimeout(()=>{l.emit("error",b)})}return{data:l}}}return ql.ActorRdfParseHtml=s,ql}var pN;function DJ(){return pN||(pN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(PJ(),t)}(Hv)),Hv}var Qv={},Ul={},Vv={},Hl={},yN;function NJ(){if(yN)return Hl;yN=1,Object.defineProperty(Hl,"__esModule",{value:!0}),Hl.ActorRdfParseHtml=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return Hl.ActorRdfParseHtml=e,Hl}var bN;function JT(){return bN||(bN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(NJ(),t)}(Vv)),Vv}var kv={},zv={},gN;function CJ(){return gN||(gN=1,Object.defineProperty(zv,"__esModule",{value:!0})),zv}var $l={},mN;function Vq(){if(mN)return $l;mN=1,Object.defineProperty($l,"__esModule",{value:!0}),$l.ItemPropertyHandlerContent=void 0;let t=class{canHandle(u,s){return"content"in s}getObject(u,s,n){return s.createLiteral(u.content,n)}};return $l.ItemPropertyHandlerContent=t,$l}var Ql={},Vl={},_N;function kb(){if(_N)return Vl;_N=1,Object.defineProperty(Vl,"__esModule",{value:!0}),Vl.Util=void 0;const t=Et(),e=Pi();class u{constructor(n,r){this.dataFactory=n||new t.DataFactory,this.baseIRI=r||""}static isValidIri(n){return u.IRI_REGEX.test(n)}createVocabIris(n,r,a){return n.split(/\s+/u).filter(o=>!!o).map(o=>{if(!u.isValidIri(o)){if(!a)return;o=`${r.vocab||`${this.baseIRI}#`}${o}`}return this.dataFactory.namedNode(o)}).filter(o=>!!o)}getVocabularyExpansionType(n,r,a){const o=n.split(/\s+/u);if(o.includes("subPropertyOf")||o.includes("equivalentProperty"))return[this.dataFactory.namedNode(`${u.RDF}type`)];if(r.vocab&&r.vocab in a&&a[r.vocab].properties){let l=[];for(const[c,d]of Object.entries(a[r.vocab].properties))o.includes(c)&&(l=[...Object.values(d).map(h=>this.dataFactory.namedNode(h))]);return l}return[]}createSubject(n){if(!u.isValidIri(n))try{n=(0,e.resolve)(n,this.baseIRI)}catch{return}return this.dataFactory.namedNode(n)}createLiteral(n,r){return this.dataFactory.literal(n,r.language)}deriveVocab(n,r){let a;for(const o in r)if(n.startsWith(o)){a=o,a.endsWith("/")||(a+="#");break}if(!a){const o=n.indexOf("#");o>0?a=n.slice(0,o+1):a=(0,e.resolve)(".",n)}return a}}return Vl.Util=u,u.RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#",u.XSD="http://www.w3.org/2001/XMLSchema#",u.RDFA="http://www.w3.org/ns/rdfa#",u.IRI_REGEX=/^([A-Za-z][\d+-.A-Za-z]*|_):[^ "<>[\\\]`{|}]*$/u,Vl}var vN;function kq(){if(vN)return Ql;vN=1,Object.defineProperty(Ql,"__esModule",{value:!0}),Ql.ItemPropertyHandlerNumber=void 0;const t=kb();let e=class{constructor(s,n){this.tagName=s,this.attributeName=n}canHandle(s,n){return this.tagName===s&&this.attributeName in n}getObject(s,n,r){const a=s[this.attributeName];let o;return!Number.isNaN(Number.parseInt(a,10))&&!a.includes(".")?o=`${t.Util.XSD}integer`:Number.isNaN(Number.parseFloat(a))||(o=`${t.Util.XSD}double`),n.dataFactory.literal(a,o&&n.dataFactory.namedNode(o))}};return Ql.ItemPropertyHandlerNumber=e,Ql}var kl={},wN;function Gq(){if(wN)return kl;wN=1,Object.defineProperty(kl,"__esModule",{value:!0}),kl.ItemPropertyHandlerTime=void 0;const t=kb();let e=class zq{canHandle(s,n){return s==="time"&&"datetime"in n}getObject(s,n,r){const a=s.datetime;let o;for(const l of zq.TIME_REGEXES)if(l.regex.test(a)){o=n.dataFactory.namedNode(t.Util.XSD+l.type);break}return n.dataFactory.literal(a,o)}};return kl.ItemPropertyHandlerTime=e,e.TIME_REGEXES=[{regex:/^-?P(\d+Y)?(\d+M)?(\d+D)?(T(\d+H)?(\d+M)?(\d+(\.\d)?S)?)?$/u,type:"duration"},{regex:/^\d+-\d\d-\d\dT\d\d:\d\d:\d\d((Z?)|([+-]\d\d:\d\d))$/u,type:"dateTime"},{regex:/^\d+-\d\d-\d\dZ?$/u,type:"date"},{regex:/^\d\d:\d\d:\d\d((Z?)|([+-]\d\d:\d\d))$/u,type:"time"},{regex:/^\d+-\d\d$/u,type:"gYearMonth"},{regex:/^\d+$/u,type:"gYear"}],kl}var zl={},SN;function Wq(){if(SN)return zl;SN=1,Object.defineProperty(zl,"__esModule",{value:!0}),zl.ItemPropertyHandlerUrl=void 0;const t=Pi();let e=class{constructor(s,n){this.tagName=s,this.attributeName=n}canHandle(s,n){return this.tagName===s&&this.attributeName in n}getObject(s,n,r){return n.dataFactory.namedNode((0,t.resolve)(s[this.attributeName],n.baseIRI))}};return zl.ItemPropertyHandlerUrl=e,zl}var Gv={},TN;function jJ(){return TN||(TN=1,Object.defineProperty(Gv,"__esModule",{value:!0})),Gv}var Wv={},AN;function LJ(){return AN||(AN=1,Object.defineProperty(Wv,"__esModule",{value:!0})),Wv}var Jv={},EN;function MJ(){return EN||(EN=1,Object.defineProperty(Jv,"__esModule",{value:!0})),Jv}var Gl={},Xv={},Wl={},Kv={},ON;function Jq(){return ON||(ON=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.QuoteType=void 0;var e=Ga(),u;(function(f){f[f.Tab=9]="Tab",f[f.NewLine=10]="NewLine",f[f.FormFeed=12]="FormFeed",f[f.CarriageReturn=13]="CarriageReturn",f[f.Space=32]="Space",f[f.ExclamationMark=33]="ExclamationMark",f[f.Number=35]="Number",f[f.Amp=38]="Amp",f[f.SingleQuote=39]="SingleQuote",f[f.DoubleQuote=34]="DoubleQuote",f[f.Dash=45]="Dash",f[f.Slash=47]="Slash",f[f.Zero=48]="Zero",f[f.Nine=57]="Nine",f[f.Semi=59]="Semi",f[f.Lt=60]="Lt",f[f.Eq=61]="Eq",f[f.Gt=62]="Gt",f[f.Questionmark=63]="Questionmark",f[f.UpperA=65]="UpperA",f[f.LowerA=97]="LowerA",f[f.UpperF=70]="UpperF",f[f.LowerF=102]="LowerF",f[f.UpperZ=90]="UpperZ",f[f.LowerZ=122]="LowerZ",f[f.LowerX=120]="LowerX",f[f.OpeningSquareBracket=91]="OpeningSquareBracket"})(u||(u={}));var s;(function(f){f[f.Text=1]="Text",f[f.BeforeTagName=2]="BeforeTagName",f[f.InTagName=3]="InTagName",f[f.InSelfClosingTag=4]="InSelfClosingTag",f[f.BeforeClosingTagName=5]="BeforeClosingTagName",f[f.InClosingTagName=6]="InClosingTagName",f[f.AfterClosingTagName=7]="AfterClosingTagName",f[f.BeforeAttributeName=8]="BeforeAttributeName",f[f.InAttributeName=9]="InAttributeName",f[f.AfterAttributeName=10]="AfterAttributeName",f[f.BeforeAttributeValue=11]="BeforeAttributeValue",f[f.InAttributeValueDq=12]="InAttributeValueDq",f[f.InAttributeValueSq=13]="InAttributeValueSq",f[f.InAttributeValueNq=14]="InAttributeValueNq",f[f.BeforeDeclaration=15]="BeforeDeclaration",f[f.InDeclaration=16]="InDeclaration",f[f.InProcessingInstruction=17]="InProcessingInstruction",f[f.BeforeComment=18]="BeforeComment",f[f.CDATASequence=19]="CDATASequence",f[f.InSpecialComment=20]="InSpecialComment",f[f.InCommentLike=21]="InCommentLike",f[f.BeforeSpecialS=22]="BeforeSpecialS",f[f.SpecialStartSequence=23]="SpecialStartSequence",f[f.InSpecialTag=24]="InSpecialTag",f[f.BeforeEntity=25]="BeforeEntity",f[f.BeforeNumericEntity=26]="BeforeNumericEntity",f[f.InNamedEntity=27]="InNamedEntity",f[f.InNumericEntity=28]="InNumericEntity",f[f.InHexEntity=29]="InHexEntity"})(s||(s={}));function n(f){return f===u.Space||f===u.NewLine||f===u.Tab||f===u.FormFeed||f===u.CarriageReturn}function r(f){return f===u.Slash||f===u.Gt||n(f)}function a(f){return f>=u.Zero&&f<=u.Nine}function o(f){return f>=u.LowerA&&f<=u.LowerZ||f>=u.UpperA&&f<=u.UpperZ}function l(f){return f>=u.UpperA&&f<=u.UpperF||f>=u.LowerA&&f<=u.LowerF}var c;(function(f){f[f.NoValue=0]="NoValue",f[f.Unquoted=1]="Unquoted",f[f.Single=2]="Single",f[f.Double=3]="Double"})(c=t.QuoteType||(t.QuoteType={}));var d={Cdata:new Uint8Array([67,68,65,84,65,91]),CdataEnd:new Uint8Array([93,93,62]),CommentEnd:new Uint8Array([45,45,62]),ScriptEnd:new Uint8Array([60,47,115,99,114,105,112,116]),StyleEnd:new Uint8Array([60,47,115,116,121,108,101]),TitleEnd:new Uint8Array([60,47,116,105,116,108,101])},h=function(){function f(p,y){var b=p.xmlMode,m=b===void 0?!1:b,g=p.decodeEntities,v=g===void 0?!0:g;this.cbs=y,this.state=s.Text,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=s.Text,this.isSpecial=!1,this.running=!0,this.offset=0,this.currentSequence=void 0,this.sequenceIndex=0,this.trieIndex=0,this.trieCurrent=0,this.entityResult=0,this.entityExcess=0,this.xmlMode=m,this.decodeEntities=v,this.entityTrie=m?e.xmlDecodeTree:e.htmlDecodeTree}return f.prototype.reset=function(){this.state=s.Text,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=s.Text,this.currentSequence=void 0,this.running=!0,this.offset=0},f.prototype.write=function(p){this.offset+=this.buffer.length,this.buffer=p,this.parse()},f.prototype.end=function(){this.running&&this.finish()},f.prototype.pause=function(){this.running=!1},f.prototype.resume=function(){this.running=!0,this.indexthis.sectionStart&&this.cbs.ontext(this.sectionStart,this.index),this.state=s.BeforeTagName,this.sectionStart=this.index):this.decodeEntities&&p===u.Amp&&(this.state=s.BeforeEntity)},f.prototype.stateSpecialStartSequence=function(p){var y=this.sequenceIndex===this.currentSequence.length,b=y?r(p):(p|32)===this.currentSequence[this.sequenceIndex];if(!b)this.isSpecial=!1;else if(!y){this.sequenceIndex++;return}this.sequenceIndex=0,this.state=s.InTagName,this.stateInTagName(p)},f.prototype.stateInSpecialTag=function(p){if(this.sequenceIndex===this.currentSequence.length){if(p===u.Gt||n(p)){var y=this.index-this.currentSequence.length;if(this.sectionStart>14)-1;if(!this.allowLegacyEntity()&&p!==u.Semi)this.trieIndex+=b;else{var m=this.index-this.entityExcess+1;m>this.sectionStart&&this.emitPartial(this.sectionStart,m),this.entityResult=this.trieIndex,this.trieIndex+=b,this.entityExcess=0,this.sectionStart=this.index+1,b===0&&this.emitNamedEntity()}}},f.prototype.emitNamedEntity=function(){if(this.state=this.baseState,this.entityResult!==0){var p=(this.entityTrie[this.entityResult]&e.BinTrieFlags.VALUE_LENGTH)>>14;switch(p){case 1:{this.emitCodePoint(this.entityTrie[this.entityResult]&~e.BinTrieFlags.VALUE_LENGTH);break}case 2:{this.emitCodePoint(this.entityTrie[this.entityResult+1]);break}case 3:this.emitCodePoint(this.entityTrie[this.entityResult+1]),this.emitCodePoint(this.entityTrie[this.entityResult+2])}}},f.prototype.stateBeforeNumericEntity=function(p){(p|32)===u.LowerX?(this.entityExcess++,this.state=s.InHexEntity):(this.state=s.InNumericEntity,this.stateInNumericEntity(p))},f.prototype.emitNumericEntity=function(p){var y=this.index-this.entityExcess-1,b=y+2+ +(this.state===s.InHexEntity);b!==this.index&&(y>this.sectionStart&&this.emitPartial(this.sectionStart,y),this.sectionStart=this.index+Number(p),this.emitCodePoint((0,e.replaceCodePoint)(this.entityResult))),this.state=this.baseState},f.prototype.stateInNumericEntity=function(p){p===u.Semi?this.emitNumericEntity(!0):a(p)?(this.entityResult=this.entityResult*10+(p-u.Zero),this.entityExcess++):(this.allowLegacyEntity()?this.emitNumericEntity(!1):this.state=this.baseState,this.index--)},f.prototype.stateInHexEntity=function(p){p===u.Semi?this.emitNumericEntity(!0):a(p)?(this.entityResult=this.entityResult*16+(p-u.Zero),this.entityExcess++):l(p)?(this.entityResult=this.entityResult*16+((p|32)-u.LowerA+10),this.entityExcess++):(this.allowLegacyEntity()?this.emitNumericEntity(!1):this.state=this.baseState,this.index--)},f.prototype.allowLegacyEntity=function(){return!this.xmlMode&&(this.baseState===s.Text||this.baseState===s.InSpecialTag)},f.prototype.cleanup=function(){this.running&&this.sectionStart!==this.index&&(this.state===s.Text||this.state===s.InSpecialTag&&this.sequenceIndex===0?(this.cbs.ontext(this.sectionStart,this.index),this.sectionStart=this.index):(this.state===s.InAttributeValueDq||this.state===s.InAttributeValueSq||this.state===s.InAttributeValueNq)&&(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=this.index))},f.prototype.shouldContinue=function(){return this.index0&&A.has(this.stack[this.stack.length-1]);){var D=this.stack.pop();(_=(v=this.cbs).onclosetag)===null||_===void 0||_.call(v,D,!0)}this.isVoidElement(g)||(this.stack.push(g),f.has(g)?this.foreignContext.push(!0):p.has(g)&&this.foreignContext.push(!1)),(S=(w=this.cbs).onopentagname)===null||S===void 0||S.call(w,g),this.cbs.onopentag&&(this.attribs={})},m.prototype.endOpenTag=function(g){var v,_;this.startIndex=this.openTagStart,this.attribs&&((_=(v=this.cbs).onopentag)===null||_===void 0||_.call(v,this.tagname,this.attribs,g),this.attribs=null),this.cbs.onclosetag&&this.isVoidElement(this.tagname)&&this.cbs.onclosetag(this.tagname,!0),this.tagname=""},m.prototype.onopentagend=function(g){this.endIndex=g,this.endOpenTag(!1),this.startIndex=g+1},m.prototype.onclosetag=function(g,v){var _,w,S,A,D,L;this.endIndex=v;var E=this.getSlice(g,v);if(this.lowerCaseTagNames&&(E=E.toLowerCase()),(f.has(E)||p.has(E))&&this.foreignContext.pop(),this.isVoidElement(E))!this.options.xmlMode&&E==="br"&&((w=(_=this.cbs).onopentagname)===null||w===void 0||w.call(_,"br"),(A=(S=this.cbs).onopentag)===null||A===void 0||A.call(S,"br",{},!0),(L=(D=this.cbs).onclosetag)===null||L===void 0||L.call(D,"br",!1));else{var O=this.stack.lastIndexOf(E);if(O!==-1)if(this.cbs.onclosetag)for(var P=this.stack.length-O;P--;)this.cbs.onclosetag(this.stack.pop(),P!==0);else this.stack.length=O;else!this.options.xmlMode&&E==="p"&&(this.emitOpenTag("p"),this.closeCurrentTag(!0))}this.startIndex=v+1},m.prototype.onselfclosingtag=function(g){this.endIndex=g,this.options.xmlMode||this.options.recognizeSelfClosing||this.foreignContext[this.foreignContext.length-1]?(this.closeCurrentTag(!1),this.startIndex=g+1):this.onopentagend(g)},m.prototype.closeCurrentTag=function(g){var v,_,w=this.tagname;this.endOpenTag(g),this.stack[this.stack.length-1]===w&&((_=(v=this.cbs).onclosetag)===null||_===void 0||_.call(v,w,!g),this.stack.pop())},m.prototype.onattribname=function(g,v){this.startIndex=g;var _=this.getSlice(g,v);this.attribname=this.lowerCaseAttributeNames?_.toLowerCase():_},m.prototype.onattribdata=function(g,v){this.attribvalue+=this.getSlice(g,v)},m.prototype.onattribentity=function(g){this.attribvalue+=(0,n.fromCodePoint)(g)},m.prototype.onattribend=function(g,v){var _,w;this.endIndex=v,(w=(_=this.cbs).onattribute)===null||w===void 0||w.call(_,this.attribname,this.attribvalue,g===s.QuoteType.Double?'"':g===s.QuoteType.Single?"'":g===s.QuoteType.NoValue?void 0:null),this.attribs&&!Object.prototype.hasOwnProperty.call(this.attribs,this.attribname)&&(this.attribs[this.attribname]=this.attribvalue),this.attribvalue=""},m.prototype.getInstructionName=function(g){var v=g.search(y),_=v<0?g:g.substr(0,v);return this.lowerCaseTagNames&&(_=_.toLowerCase()),_},m.prototype.ondeclaration=function(g,v){this.endIndex=v;var _=this.getSlice(g,v);if(this.cbs.onprocessinginstruction){var w=this.getInstructionName(_);this.cbs.onprocessinginstruction("!".concat(w),"!".concat(_))}this.startIndex=v+1},m.prototype.onprocessinginstruction=function(g,v){this.endIndex=v;var _=this.getSlice(g,v);if(this.cbs.onprocessinginstruction){var w=this.getInstructionName(_);this.cbs.onprocessinginstruction("?".concat(w),"?".concat(_))}this.startIndex=v+1},m.prototype.oncomment=function(g,v,_){var w,S,A,D;this.endIndex=v,(S=(w=this.cbs).oncomment)===null||S===void 0||S.call(w,this.getSlice(g,v-_)),(D=(A=this.cbs).oncommentend)===null||D===void 0||D.call(A),this.startIndex=v+1},m.prototype.oncdata=function(g,v,_){var w,S,A,D,L,E,O,P,j,U;this.endIndex=v;var M=this.getSlice(g,v-_);this.options.xmlMode||this.options.recognizeCDATA?((S=(w=this.cbs).oncdatastart)===null||S===void 0||S.call(w),(D=(A=this.cbs).ontext)===null||D===void 0||D.call(A,M),(E=(L=this.cbs).oncdataend)===null||E===void 0||E.call(L)):((P=(O=this.cbs).oncomment)===null||P===void 0||P.call(O,"[CDATA[".concat(M,"]]")),(U=(j=this.cbs).oncommentend)===null||U===void 0||U.call(j)),this.startIndex=v+1},m.prototype.onend=function(){var g,v;if(this.cbs.onclosetag){this.endIndex=this.startIndex;for(var _=this.stack.length;_>0;this.cbs.onclosetag(this.stack[--_],!0));}(v=(g=this.cbs).onend)===null||v===void 0||v.call(g)},m.prototype.reset=function(){var g,v,_,w;(v=(g=this.cbs).onreset)===null||v===void 0||v.call(g),this.tokenizer.reset(),this.tagname="",this.attribname="",this.attribs=null,this.stack.length=0,this.startIndex=0,this.endIndex=0,(w=(_=this.cbs).onparserinit)===null||w===void 0||w.call(_,this),this.buffers.length=0,this.bufferOffset=0,this.writeIndex=0,this.ended=!1},m.prototype.parseComplete=function(g){this.reset(),this.end(g)},m.prototype.getSlice=function(g,v){for(;g-this.bufferOffset>=this.buffers[0].length;)this.shiftBuffer();for(var _=this.buffers[0].slice(g-this.bufferOffset,v-this.bufferOffset);v-this.bufferOffset>this.buffers[0].length;)this.shiftBuffer(),_+=this.buffers[0].slice(0,v-this.bufferOffset);return _},m.prototype.shiftBuffer=function(){this.bufferOffset+=this.buffers[0].length,this.writeIndex--,this.buffers.shift()},m.prototype.write=function(g){var v,_;if(this.ended){(_=(v=this.cbs).onerror)===null||_===void 0||_.call(v,new Error(".write() after done!"));return}this.buffers.push(g),this.tokenizer.running&&(this.tokenizer.write(g),this.writeIndex++)},m.prototype.end=function(g){var v,_;if(this.ended){(_=(v=this.cbs).onerror)===null||_===void 0||_.call(v,new Error(".end() after done!"));return}g&&this.write(g),this.ended=!0,this.tokenizer.end()},m.prototype.pause=function(){this.tokenizer.pause()},m.prototype.resume=function(){for(this.tokenizer.resume();this.tokenizer.running&&this.writeIndexf.emit("error",p)),d.on("data",p=>h.push(p)),d.on("end",()=>h.push(null));const f=h.pipe(new s3(this.options));return f}_transform(d,h,f){this.parser.write(d.toString()),f()}_flush(d){this.parser.end(),d()}getItemScope(d){let h=this.itemScopeStack.length-(d?2:1);for(;h>0&&!this.itemScopeStack[h];)h--;return this.itemScopeStack[h]}getDepth(){return this.itemScopeStack.length}onTagOpen(d,h){if(!this.isEmittingReferences){if("id"in h){const p=h.id;this.pendingItemRefsRangeCollecting[p]={events:[],counter:0,ids:[]}}for(const p of Object.values(this.pendingItemRefsRangeCollecting))p.counter++,p.events.push({type:"open",name:d,attributes:h})}this.textBufferStack.push(void 0);let f;if("itemscope"in h){let p;if(this.emittingReferencesItemScopeIdGenerator)p=this.emittingReferencesItemScopeIdGenerator();else{p="itemid"in h&&this.util.createSubject(h.itemid)||this.util.dataFactory.blankNode();for(const b of Object.values(this.pendingItemRefsRangeCollecting))b.ids.push(p)}f={subject:p},this.isEmittingReferences&&(f.blockEmission=!0);const y=this.getItemScope();y&&y.vocab&&(f.vocab=y.vocab),this.itemScopeStack.push(f)}else f=this.getItemScope(),this.itemScopeStack.push(void 0);if(f){if("itemtype"in h)for(const p of this.util.createVocabIris(h.itemtype,f,!1))f.vocab||(f.vocab=this.util.deriveVocab(p.value,this.vocabRegistry)),f.blockEmission||this.emitTriple(f.subject,this.util.dataFactory.namedNode(`${a.Util.RDF}type`),p);if("lang"in h&&(f.language=h.lang),"xml:lang"in h&&(f.language=h["xml:lang"]),"itemscope"in h&&!this.isEmittingReferences&&"itemref"in h)for(const p of h.itemref.split(/\s+/u))p in this.pendingItemRefsDomain||(this.pendingItemRefsDomain[p]=[]),this.pendingItemRefsDomain[p].push(f),this.tryToEmitReferences(p,f)}"itemprop"in h&&this.handleItemProperties(h.itemprop,!1,f,d,h),"itemprop-reverse"in h&&this.handleItemProperties(h["itemprop-reverse"],!0,f,d,h)}onText(d){if(!this.isEmittingReferences)for(const h of Object.values(this.pendingItemRefsRangeCollecting))h.events.push({type:"text",data:d});for(const h of this.textBufferStack)h&&h.push(d)}onTagClose(){if(!this.isEmittingReferences)for(const[h,f]of Object.entries(this.pendingItemRefsRangeCollecting))f.counter--,f.events.push({type:"close"}),f.counter===0&&(this.pendingItemRefsRangeFinalized[h]=f,delete this.pendingItemRefsRangeCollecting[h],this.tryToEmitReferences(h));const d=this.getItemScope(!0);if(d){const h=this.getDepth();if(d.predicates&&h in d.predicates)for(const[f,p]of Object.entries(d.predicates[h])){const y=this.util.createLiteral(this.textBufferStack[h].join(""),d);this.emitPredicateTriples(d,p,y,f==="reverse"),delete d.predicates[h][f]}}this.itemScopeStack.pop(),this.textBufferStack.pop()}onEnd(){}initializeParser(d){return new t.Parser({onclosetag:()=>{try{this.onTagClose(),this.htmlParseListener&&this.htmlParseListener.onTagClose()}catch(h){this.emit("error",h)}},onend:()=>{try{this.onEnd(),this.htmlParseListener&&this.htmlParseListener.onEnd()}catch(h){this.emit("error",h)}},onopentag:(h,f)=>{try{this.onTagOpen(h,f),this.htmlParseListener&&this.htmlParseListener.onTagOpen(h,f)}catch(p){this.emit("error",p)}},ontext:h=>{try{this.onText(h),this.htmlParseListener&&this.htmlParseListener.onText(h)}catch(f){this.emit("error",f)}}},{decodeEntities:!0,recognizeSelfClosing:!0,xmlMode:d})}handleItemProperties(d,h,f,p,y){const b=this.getItemScope(!0);if(b){const m=this.getDepth(),g=this.util.createVocabIris(d,b,!0);b.predicates||(b.predicates={}),b.predicates[m]||(b.predicates[m]={});const v=h?"reverse":"forward";b.predicates[m][v]=g;for(const _ of this.util.getVocabularyExpansionType(d,b,this.vocabRegistry))g.push(_);if(f&&"itemscope"in y)this.emitPredicateTriples(b,g,f.subject,h),delete b.predicates[m][v];else for(const _ of s3.ITEM_PROPERTY_HANDLERS)if(_.canHandle(p,y)){const w=_.getObject(y,this.util,b);this.emitPredicateTriples(b,g,w,h),delete b.predicates[m][v]}b.predicates[m][v]&&(this.textBufferStack[m]=[])}}emitPredicateTriples(d,h,f,p){if(!d.blockEmission)for(const y of h)p?f.termType!=="Literal"&&this.emitTriple(f,y,d.subject):this.emitTriple(d.subject,y,f)}emitTriple(d,h,f){this.push(this.util.dataFactory.quad(d,h,f,this.defaultGraph))}tryToEmitReferences(d,h){const f=this.pendingItemRefsRangeFinalized[d];if(f){let p;if(h){p=[h];const y=this.pendingItemRefsDomain[d].indexOf(h);this.pendingItemRefsDomain[d].splice(y,1)}else p=this.pendingItemRefsDomain[d],delete this.pendingItemRefsDomain[d];if(p){const y=this.itemScopeStack,b=this.textBufferStack;this.isEmittingReferences=!0;for(const m of p){this.itemScopeStack=[m],this.textBufferStack=[void 0];const g=[...f.ids];this.emittingReferencesItemScopeIdGenerator=()=>g.shift();for(const v of f.events)switch(v.type){case"open":this.onTagOpen(v.name,v.attributes);break;case"text":this.onText(v.data);break;case"close":this.onTagClose();break}}this.emittingReferencesItemScopeIdGenerator=void 0,this.itemScopeStack=y,this.textBufferStack=b,this.isEmittingReferences=!1}}}};return Gl.MicrodataRdfParser=l,l.ITEM_PROPERTY_HANDLERS=[new u.ItemPropertyHandlerContent,new r.ItemPropertyHandlerUrl("a","href"),new r.ItemPropertyHandlerUrl("area","href"),new r.ItemPropertyHandlerUrl("audio","src"),new r.ItemPropertyHandlerUrl("embed","src"),new r.ItemPropertyHandlerUrl("iframe","src"),new r.ItemPropertyHandlerUrl("img","src"),new r.ItemPropertyHandlerUrl("link","href"),new r.ItemPropertyHandlerUrl("object","data"),new r.ItemPropertyHandlerUrl("source","src"),new r.ItemPropertyHandlerUrl("track","src"),new r.ItemPropertyHandlerUrl("video","src"),new s.ItemPropertyHandlerNumber("data","value"),new s.ItemPropertyHandlerNumber("meter","value"),new n.ItemPropertyHandlerTime],Gl}var DN;function UJ(){return DN||(DN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(CJ(),t),u(Vq(),t),u(kq(),t),u(Gq(),t),u(Wq(),t),u(jJ(),t),u(LJ(),t),u(MJ(),t),u(BJ(),t),u(kb(),t)}(kv)),kv}var NN;function HJ(){if(NN)return Ul;NN=1,Object.defineProperty(Ul,"__esModule",{value:!0}),Ul.ActorRdfParseHtmlMicrodata=void 0;const t=JT(),e=UJ();let u=class extends t.ActorRdfParseHtml{constructor(n){super(n)}async test(n){return!0}async run(n){const r=n.headers?n.headers.get("content-type"):null,a=r==null?void 0:r.includes("xml"),o=new e.MicrodataRdfParser({baseIRI:n.baseIRI,xmlMode:a});o.on("error",n.error),o.on("data",n.emit);const l=o.onEnd;return o.onEnd=()=>{l.call(o),n.end()},{htmlParseListener:o}}};return Ul.ActorRdfParseHtmlMicrodata=u,Ul}var CN;function $J(){return CN||(CN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(HJ(),t)}(Qv)),Qv}var Yv={},Jl={},jN;function QJ(){if(jN)return Jl;jN=1,Object.defineProperty(Jl,"__esModule",{value:!0}),Jl.ActorRdfParseHtmlRdfa=void 0;const t=JT(),e=$q();let u=class extends t.ActorRdfParseHtml{constructor(n){super(n)}async test(n){return!0}async run(n){const r=n.headers?n.headers.get("content-type"):null,a=(n.headers&&n.headers.get("content-language"))??void 0,o=r&&r.includes("xml")?"xhtml":"html",l=new e.RdfaParser({baseIRI:n.baseIRI,profile:o,language:a});l.on("error",n.error),l.on("data",n.emit);const c=l.onEnd;return l.onEnd=()=>{c.call(l),n.end()},{htmlParseListener:l}}};return Jl.ActorRdfParseHtmlRdfa=u,Jl}var LN;function VJ(){return LN||(LN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(QJ(),t)}(Yv)),Yv}var Zv={},Xl={},e2={},Kl={},MN;function kJ(){if(MN)return Kl;MN=1,Object.defineProperty(Kl,"__esModule",{value:!0}),Kl.ActorRdfResolveHypermediaLinksQueue=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return Kl.ActorRdfResolveHypermediaLinksQueue=e,Kl}var t2={},FN;function zJ(){return FN||(FN=1,Object.defineProperty(t2,"__esModule",{value:!0})),t2}var Yl={},qN;function GJ(){if(qN)return Yl;qN=1,Object.defineProperty(Yl,"__esModule",{value:!0}),Yl.LinkQueueWrapper=void 0;let t=class{constructor(u){this.linkQueue=u}push(u,s){return this.linkQueue.push(u,s)}getSize(){return this.linkQueue.getSize()}isEmpty(){return this.linkQueue.isEmpty()}pop(){return this.linkQueue.pop()}peek(){return this.linkQueue.peek()}};return Yl.LinkQueueWrapper=t,Yl}var BN;function WJ(){return BN||(BN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(kJ(),t),u(zJ(),t),u(GJ(),t)}(e2)),e2}var Zl={},UN;function Xq(){if(UN)return Zl;UN=1,Object.defineProperty(Zl,"__esModule",{value:!0}),Zl.LinkQueueFifo=void 0;let t=class{constructor(){this.links=[]}push(u){return this.links.push(u),!0}getSize(){return this.links.length}isEmpty(){return this.links.length===0}pop(){return this.links.shift()}peek(){return this.links[0]}};return Zl.LinkQueueFifo=t,Zl}var HN;function JJ(){if(HN)return Xl;HN=1,Object.defineProperty(Xl,"__esModule",{value:!0}),Xl.ActorRdfResolveHypermediaLinksQueueFifo=void 0;const t=WJ(),e=Xq();let u=class extends t.ActorRdfResolveHypermediaLinksQueue{constructor(n){super(n)}async test(n){return!0}async run(n){return{linkQueue:new e.LinkQueueFifo}}};return Xl.ActorRdfResolveHypermediaLinksQueueFifo=u,Xl}var $N;function XJ(){return $N||($N=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(JJ(),t),u(Xq(),t)}(Zv)),Zv}var r2={},ed={},n2={},td={},QN;function KJ(){if(QN)return td;QN=1,Object.defineProperty(td,"__esModule",{value:!0}),td.ActorRdfResolveHypermediaLinks=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return td.ActorRdfResolveHypermediaLinks=e,td}var VN;function YJ(){return VN||(VN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(KJ(),t)}(n2)),n2}var kN;function ZJ(){if(kN)return ed;kN=1,Object.defineProperty(ed,"__esModule",{value:!0}),ed.ActorRdfResolveHypermediaLinksNext=void 0;const t=YJ();let e=class extends t.ActorRdfResolveHypermediaLinks{constructor(s){super(s)}async test(s){if(!s.metadata.next||s.metadata.next.length===0)throw new Error(`Actor ${this.name} requires a 'next' metadata entry.`);return!0}async run(s){return{links:s.metadata.next.map(n=>({url:n}))}}};return ed.ActorRdfResolveHypermediaLinksNext=e,ed}var zN;function eX(){return zN||(zN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(ZJ(),t)}(r2)),r2}var i2={},rd={},a2={},nd={},GN;function tX(){if(GN)return nd;GN=1,Object.defineProperty(nd,"__esModule",{value:!0}),nd.ActorRdfSerialize=void 0;const t=nu();let e=class extends t.ActorAbstractMediaTyped{constructor(s){super(s)}};return nd.ActorRdfSerialize=e,nd}var id={},WN;function rX(){if(WN)return id;WN=1,Object.defineProperty(id,"__esModule",{value:!0}),id.ActorRdfSerializeFixedMediaTypes=void 0;const t=nu();let e=class extends t.ActorAbstractMediaTypedFixed{constructor(s){super(s)}async testHandleChecked(){return!0}};return id.ActorRdfSerializeFixedMediaTypes=e,id}var JN;function XT(){return JN||(JN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(tX(),t),u(rX(),t)}(a2)),a2}var XN;function nX(){if(XN)return rd;XN=1,Object.defineProperty(rd,"__esModule",{value:!0}),rd.ActorRdfSerializeN3=void 0;const t=XT(),e=ts;let u=class extends t.ActorRdfSerializeFixedMediaTypes{constructor(n){super(n)}async runHandle(n,r){const a=new e.StreamWriter({format:r});let o;return"pipe"in n.quadStream?(n.quadStream.on("error",l=>a.emit("error",l)),o=n.quadStream.pipe(a)):o=a.import(n.quadStream),{data:o,triples:r==="text/turtle"||r==="application/n-triples"||r==="text/n3"}}};return rd.ActorRdfSerializeN3=u,rd}var KN;function iX(){return KN||(KN=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(nX(),t)}(i2)),i2}var s2={},ad={},o2={},sd={},od={},YN;function aX(){if(YN)return od;YN=1,Object.defineProperty(od,"__esModule",{value:!0}),od.SeparatorType=void 0;let t=class{constructor(u){this.label=u}};return od.SeparatorType=t,t.COMMA=new t(","),t.OBJECT_START=new t("{"),t.OBJECT_END=new t("}"),t.OBJECT_END_COMMA=new t("},"),t.ARRAY_START=new t("["),t.ARRAY_END=new t("]"),t.ARRAY_END_COMMA=new t("],"),t.GRAPH_FIELD_NONCOMPACT=new t('"@graph": ['),t.GRAPH_FIELD_COMPACT=new t('"@graph":['),t.CONTEXT_FIELD=new t('"@context":'),od}var ud={},ZN;function Kq(){if(ZN)return ud;ZN=1,Object.defineProperty(ud,"__esModule",{value:!0}),ud.Util=void 0;const t=Jr();class e{static termToValue(s,n,r={compactIds:!1,useNativeTypes:!1}){switch(s.termType){case"NamedNode":const a=n.compactIri(s.value,r.vocab);return r.compactIds?a:{"@id":a};case"DefaultGraph":return r.compactIds?s.value:{"@id":s.value};case"BlankNode":const o=`_:${s.value}`;return r.compactIds?o:{"@id":o};case"Literal":if(s.datatype.value===e.RDF_JSON){let d;try{d=JSON.parse(s.value)}catch(h){throw new t.ErrorCoded("Invalid JSON literal: "+h.message,t.ERROR_CODES.INVALID_JSON_LITERAL)}return{"@value":d,"@type":"@json"}}if(r.rdfDirection==="i18n-datatype"&&s.datatype.value.startsWith(e.I18N)){const[d,h]=s.datatype.value.substr(e.I18N.length,s.datatype.value.length).split("_");return Object.assign(Object.assign({"@value":s.value},d?{"@language":d}:{}),h?{"@direction":h}:{})}const l=s.datatype.value===e.XSD_STRING,c={"@value":!l&&r.useNativeTypes?e.stringToNativeType(s.value,s.datatype.value):s.value};return s.language?Object.assign(Object.assign({},c),{"@language":s.language}):!l&&typeof c["@value"]=="string"?Object.assign(Object.assign({},c),{"@type":s.datatype.value}):c}}static stringToNativeType(s,n){if(n.startsWith(e.XSD))switch(n.substr(e.XSD.length)){case"boolean":if(s==="true")return!0;if(s==="false")return!1;throw new Error(`Invalid xsd:boolean value '${s}'`);case"integer":case"number":case"int":case"byte":case"long":const a=parseInt(s,10);if(isNaN(a))throw new Error(`Invalid xsd:integer value '${s}'`);return a;case"float":case"double":const o=parseFloat(s);if(isNaN(o))throw new Error(`Invalid xsd:float value '${s}'`);return o}return s}}return ud.Util=e,e.XSD="http://www.w3.org/2001/XMLSchema#",e.XSD_STRING=e.XSD+"string",e.RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#",e.RDF_TYPE=e.RDF+"type",e.RDF_JSON=e.RDF+"JSON",e.I18N="https://www.w3.org/ns/i18n#",ud}var e4;function sX(){if(e4)return sd;e4=1,Object.defineProperty(sd,"__esModule",{value:!0}),sd.JsonLdSerializer=void 0;const t=Jr(),e=aX(),u=Kq(),s=Wt();let n=class Yq extends s.Transform{constructor(a={}){super({objectMode:!0}),this.indentation=0,this.options=a,this.options.baseIRI&&!this.options.context&&(this.options.context={"@base":this.options.baseIRI}),this.options.context?(this.originalContext=this.options.context,this.context=new t.ContextParser().parse(this.options.context,{baseIRI:this.options.baseIRI})):this.context=Promise.resolve(new t.JsonLdContextNormalized({}))}import(a){const o=new s.PassThrough({objectMode:!0});a.on("error",c=>l.emit("error",c)),a.on("data",c=>o.push(c)),a.on("end",()=>o.push(null));const l=o.pipe(new Yq(this.options));return l}_transform(a,o,l){this.context.then(c=>{this.transformQuad(a,c),l()}).catch(l)}async list(a){const o=await this.context;return{"@list":a.map(l=>u.Util.termToValue(l,o,this.options))}}_flush(a){return this.opened||this.pushDocumentStart(),this.lastPredicate&&this.endPredicate(),this.lastSubject&&this.endSubject(),this.lastGraph&&this.lastGraph.termType!=="DefaultGraph"&&this.endGraph(),this.endDocument(),a(null,null)}transformQuad(a,o){this.opened||this.pushDocumentStart();const l=this.lastGraph&&this.lastGraph.termType!=="DefaultGraph"&&this.lastGraph.equals(a.subject);if(!l&&(!this.lastGraph||!a.graph.equals(this.lastGraph))){let c=a.graph.termType!=="DefaultGraph"&&this.lastSubject&&this.lastSubject.equals(a.graph);this.lastGraph&&(this.lastGraph.termType!=="DefaultGraph"?(this.endPredicate(),this.endSubject(),this.endGraph(!0),c=!1):c?(this.endPredicate(!0),this.lastSubject=null):(this.endPredicate(),this.endSubject(!0))),a.graph.termType!=="DefaultGraph"&&(c||this.pushId(a.graph,!0,o),this.pushSeparator(this.options.space?e.SeparatorType.GRAPH_FIELD_NONCOMPACT:e.SeparatorType.GRAPH_FIELD_COMPACT),this.indentation++),this.lastGraph=a.graph}(!this.lastSubject||!a.subject.equals(this.lastSubject))&&(l?(this.endPredicate(),this.endSubject(),this.indentation--,this.pushSeparator(e.SeparatorType.ARRAY_END_COMMA),this.lastGraph=a.graph):(this.lastSubject&&(this.endPredicate(),this.endSubject(!0)),this.pushId(a.subject,!0,o)),this.lastSubject=a.subject),(!this.lastPredicate||!a.predicate.equals(this.lastPredicate))&&(this.lastPredicate&&this.endPredicate(!0),this.pushPredicate(a.predicate,o)),this.pushObject(a.object,o)}pushDocumentStart(){this.opened=!0,this.originalContext&&!this.options.excludeContext?(this.pushSeparator(e.SeparatorType.OBJECT_START),this.indentation++,this.pushSeparator(e.SeparatorType.CONTEXT_FIELD),this.pushIndented(JSON.stringify(this.originalContext,null,this.options.space)+","),this.pushSeparator(this.options.space?e.SeparatorType.GRAPH_FIELD_NONCOMPACT:e.SeparatorType.GRAPH_FIELD_COMPACT),this.indentation++):(this.pushSeparator(e.SeparatorType.ARRAY_START),this.indentation++)}pushId(a,o,l){if(a.termType==="Quad")this.pushNestedQuad(a,!0,l);else{const c=a.termType==="BlankNode"?"_:"+a.value:l.compactIri(a.value,!1);o?this.pushSeparator(e.SeparatorType.OBJECT_START):(this.push(e.SeparatorType.OBJECT_START.label),this.options.space&&this.push(` -`)),this.indentation++,this.pushIndented(this.options.space?`"@id": "${c}",`:`"@id":"${c}",`)}}pushPredicate(a,o){let l=a.value;!this.options.useRdfType&&l===u.Util.RDF_TYPE&&(l="@type",this.objectOptions=Object.assign(Object.assign({},this.options),{compactIds:!0,vocab:!0}));const c=o.compactIri(l,!0);this.pushIndented(this.options.space?`"${c}": [`:`"${c}":[`),this.indentation++,this.lastPredicate=a}pushObject(a,o){if(this.hadObjectForPredicate?this.pushSeparator(e.SeparatorType.COMMA):this.hadObjectForPredicate=!0,a.termType==="Quad"){const c=this.lastSubject,d=this.lastPredicate;this.hadObjectForPredicate=!1,this.pushNestedQuad(a,!1,o),this.endSubject(!1),this.hadObjectForPredicate=!0,this.lastPredicate=d,this.lastSubject=c;return}let l;try{a["@list"]?l=a:l=u.Util.termToValue(a,o,this.objectOptions||this.options)}catch(c){return this.emit("error",c)}this.pushIndented(JSON.stringify(l,null,this.options.space))}pushNestedQuad(a,o,l){this.pushSeparator(e.SeparatorType.OBJECT_START),this.indentation++,this.pushIndented(this.options.space?'"@id": ':'"@id":',!1),a.graph.termType!=="DefaultGraph"&&this.emit("error",new Error(`Found a nested quad with the non-default graph: ${a.graph.value}`)),this.pushId(a.subject,!1,l),this.pushPredicate(a.predicate,l),this.pushObject(a.object,l),this.endPredicate(!1),this.endSubject(o)}endDocument(){this.opened=!1,this.originalContext&&!this.options.excludeContext?(this.indentation--,this.pushSeparator(e.SeparatorType.ARRAY_END),this.indentation--,this.pushSeparator(e.SeparatorType.OBJECT_END)):(this.indentation--,this.pushSeparator(e.SeparatorType.ARRAY_END))}endPredicate(a){this.indentation--,this.pushSeparator(a?e.SeparatorType.ARRAY_END_COMMA:e.SeparatorType.ARRAY_END),this.hadObjectForPredicate=!1,this.objectOptions=null,this.lastPredicate=null}endSubject(a){this.indentation--,this.pushSeparator(a?e.SeparatorType.OBJECT_END_COMMA:e.SeparatorType.OBJECT_END),this.lastSubject=null}endGraph(a){this.indentation--,this.pushSeparator(e.SeparatorType.ARRAY_END),this.indentation--,this.pushSeparator(a?e.SeparatorType.OBJECT_END_COMMA:e.SeparatorType.OBJECT_END),this.lastGraph=null}pushSeparator(a){this.pushIndented(a.label)}pushIndented(a,o=!0){const l=this.getIndentPrefix(),c=a.split(` -`).map(d=>l+d).join(` -`);this.push(c),this.options.space&&o&&this.push(` -`)}getIndentPrefix(){return this.options.space?this.options.space.repeat(this.indentation):""}};return sd.JsonLdSerializer=n,sd}var t4;function oX(){return t4||(t4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r),Object.defineProperty(s,a,{enumerable:!0,get:function(){return n[r]}})}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(sX(),t),u(Kq(),t)}(o2)),o2}var r4;function uX(){if(r4)return ad;r4=1,Object.defineProperty(ad,"__esModule",{value:!0}),ad.ActorRdfSerializeJsonLd=void 0;const t=XT(),e=oX();let u=class extends t.ActorRdfSerializeFixedMediaTypes{constructor(n){super(n)}async runHandle(n,r,a){const o=new e.JsonLdSerializer({space:" ".repeat(this.jsonStringifyIndentSpaces)});let l;return"pipe"in n.quadStream?(n.quadStream.on("error",c=>o.emit("error",c)),l=n.quadStream.pipe(o)):l=o.import(n.quadStream),{data:l}}};return ad.ActorRdfSerializeJsonLd=u,ad}var n4;function cX(){return n4||(n4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(uX(),t)}(s2)),s2}var u2={},cd={},p1={},i4;function lX(){if(i4)return p1;i4=1,Object.defineProperty(p1,"__esModule",{value:!0});function t(u,s){return new Promise((n,r)=>{u.on("end",()=>n(s)),u.on("error",r)})}function e(u){const s=[];return t(u.on("data",n=>s.push(n)),s)}return p1.default=e,p1}var ld={},y1={},c2={},dd={},a4;function dX(){if(a4)return dd;a4=1,Object.defineProperty(dd,"__esModule",{value:!0}),dd.fragment=void 0;function t(s){let n=s;(n.endsWith("/")||n.endsWith("#"))&&(n=n.slice(0,n.length-1));const r=[];n.lastIndexOf("/")>0&&r.push(n.lastIndexOf("/")),n.lastIndexOf("#")>0&&r.push(n.lastIndexOf("#"));const a=Math.max(...r);return n.slice(a+1)}function e(s){var n;const r=(n=s.split(/[^a-z0-9]+/ig).filter(a=>a!=="").map(a=>a[0].toUpperCase()+a.slice(1)).join("").match(/[a-z][a-z0-9]+/ig))===null||n===void 0?void 0:n[0];return typeof r>"u"?void 0:r[0].toLowerCase()+r.slice(1)}function u(s){let n=t(s);return n=n?e(n):void 0,n||"v"}return dd.fragment=u,dd}var l2={},fd={},Es={},b1={exports:{}},s4;function fX(){return s4||(s4=1,function(t,e){var u=typeof self<"u"?self:I,s=function(){function r(){this.fetch=!1,this.DOMException=u.DOMException}return r.prototype=u,new r}();(function(r){(function(a){var o={searchParams:"URLSearchParams"in r,iterable:"Symbol"in r&&"iterator"in Symbol,blob:"FileReader"in r&&"Blob"in r&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in r,arrayBuffer:"ArrayBuffer"in r};function l(M){return M&&DataView.prototype.isPrototypeOf(M)}if(o.arrayBuffer)var c=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],d=ArrayBuffer.isView||function(M){return M&&c.indexOf(Object.prototype.toString.call(M))>-1};function h(M){if(typeof M!="string"&&(M=String(M)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(M))throw new TypeError("Invalid character in header field name");return M.toLowerCase()}function f(M){return typeof M!="string"&&(M=String(M)),M}function p(M){var q={next:function(){var Q=M.shift();return{done:Q===void 0,value:Q}}};return o.iterable&&(q[Symbol.iterator]=function(){return q}),q}function y(M){this.map={},M instanceof y?M.forEach(function(q,Q){this.append(Q,q)},this):Array.isArray(M)?M.forEach(function(q){this.append(q[0],q[1])},this):M&&Object.getOwnPropertyNames(M).forEach(function(q){this.append(q,M[q])},this)}y.prototype.append=function(M,q){M=h(M),q=f(q);var Q=this.map[M];this.map[M]=Q?Q+", "+q:q},y.prototype.delete=function(M){delete this.map[h(M)]},y.prototype.get=function(M){return M=h(M),this.has(M)?this.map[M]:null},y.prototype.has=function(M){return this.map.hasOwnProperty(h(M))},y.prototype.set=function(M,q){this.map[h(M)]=f(q)},y.prototype.forEach=function(M,q){for(var Q in this.map)this.map.hasOwnProperty(Q)&&M.call(q,this.map[Q],Q,this)},y.prototype.keys=function(){var M=[];return this.forEach(function(q,Q){M.push(Q)}),p(M)},y.prototype.values=function(){var M=[];return this.forEach(function(q){M.push(q)}),p(M)},y.prototype.entries=function(){var M=[];return this.forEach(function(q,Q){M.push([Q,q])}),p(M)},o.iterable&&(y.prototype[Symbol.iterator]=y.prototype.entries);function b(M){if(M.bodyUsed)return Promise.reject(new TypeError("Already read"));M.bodyUsed=!0}function m(M){return new Promise(function(q,Q){M.onload=function(){q(M.result)},M.onerror=function(){Q(M.error)}})}function g(M){var q=new FileReader,Q=m(q);return q.readAsArrayBuffer(M),Q}function v(M){var q=new FileReader,Q=m(q);return q.readAsText(M),Q}function _(M){for(var q=new Uint8Array(M),Q=new Array(q.length),Z=0;Z-1?q:M}function L(M,q){q=q||{};var Q=q.body;if(M instanceof L){if(M.bodyUsed)throw new TypeError("Already read");this.url=M.url,this.credentials=M.credentials,q.headers||(this.headers=new y(M.headers)),this.method=M.method,this.mode=M.mode,this.signal=M.signal,!Q&&M._bodyInit!=null&&(Q=M._bodyInit,M.bodyUsed=!0)}else this.url=String(M);if(this.credentials=q.credentials||this.credentials||"same-origin",(q.headers||!this.headers)&&(this.headers=new y(q.headers)),this.method=D(q.method||this.method||"GET"),this.mode=q.mode||this.mode||null,this.signal=q.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&Q)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(Q)}L.prototype.clone=function(){return new L(this,{body:this._bodyInit})};function E(M){var q=new FormData;return M.trim().split("&").forEach(function(Q){if(Q){var Z=Q.split("="),K=Z.shift().replace(/\+/g," "),fe=Z.join("=").replace(/\+/g," ");q.append(decodeURIComponent(K),decodeURIComponent(fe))}}),q}function O(M){var q=new y,Q=M.replace(/\r?\n[\t ]+/g," ");return Q.split(/\r?\n/).forEach(function(Z){var K=Z.split(":"),fe=K.shift().trim();if(fe){var X=K.join(":").trim();q.append(fe,X)}}),q}S.call(L.prototype);function P(M,q){q||(q={}),this.type="default",this.status=q.status===void 0?200:q.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in q?q.statusText:"OK",this.headers=new y(q.headers),this.url=q.url||"",this._initBody(M)}S.call(P.prototype),P.prototype.clone=function(){return new P(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new y(this.headers),url:this.url})},P.error=function(){var M=new P(null,{status:0,statusText:""});return M.type="error",M};var j=[301,302,303,307,308];P.redirect=function(M,q){if(j.indexOf(q)===-1)throw new RangeError("Invalid status code");return new P(null,{status:q,headers:{location:M}})},a.DOMException=r.DOMException;try{new a.DOMException}catch{a.DOMException=function(q,Q){this.message=q,this.name=Q;var Z=Error(q);this.stack=Z.stack},a.DOMException.prototype=Object.create(Error.prototype),a.DOMException.prototype.constructor=a.DOMException}function U(M,q){return new Promise(function(Q,Z){var K=new L(M,q);if(K.signal&&K.signal.aborted)return Z(new a.DOMException("Aborted","AbortError"));var fe=new XMLHttpRequest;function X(){fe.abort()}fe.onload=function(){var he={status:fe.status,statusText:fe.statusText,headers:O(fe.getAllResponseHeaders()||"")};he.url="responseURL"in fe?fe.responseURL:he.headers.get("X-Request-URL");var xe="response"in fe?fe.response:fe.responseText;Q(new P(xe,he))},fe.onerror=function(){Z(new TypeError("Network request failed"))},fe.ontimeout=function(){Z(new TypeError("Network request failed"))},fe.onabort=function(){Z(new a.DOMException("Aborted","AbortError"))},fe.open(K.method,K.url,!0),K.credentials==="include"?fe.withCredentials=!0:K.credentials==="omit"&&(fe.withCredentials=!1),"responseType"in fe&&o.blob&&(fe.responseType="blob"),K.headers.forEach(function(he,xe){fe.setRequestHeader(xe,he)}),K.signal&&(K.signal.addEventListener("abort",X),fe.onreadystatechange=function(){fe.readyState===4&&K.signal.removeEventListener("abort",X)}),fe.send(typeof K._bodyInit>"u"?null:K._bodyInit)})}return U.polyfill=!0,r.fetch||(r.fetch=U,r.Headers=y,r.Request=L,r.Response=P),a.Headers=y,a.Request=L,a.Response=P,a.fetch=U,Object.defineProperty(a,"__esModule",{value:!0}),a})({})})(s),s.fetch.ponyfill=!0,delete s.fetch.polyfill;var n=s;e=n.fetch,e.default=n.fetch,e.fetch=n.fetch,e.Headers=n.Headers,e.Request=n.Request,e.Response=n.Response,t.exports=e}(b1,b1.exports)),b1.exports}var o4;function KT(){if(o4)return Es;o4=1;var t=I&&I.__awaiter||function(n,r,a,o){function l(c){return c instanceof a?c:new a(function(d){d(c)})}return new(a||(a=Promise))(function(c,d){function h(y){try{p(o.next(y))}catch(b){d(b)}}function f(y){try{p(o.throw(y))}catch(b){d(b)}}function p(y){y.done?c(y.value):l(y.value).then(h,f)}p((o=o.apply(n,r||[])).next())})};Object.defineProperty(Es,"__esModule",{value:!0}),Es.fetchContext=Es.fetchJson=void 0;const e=fX();function u(n,r){var a;return t(this,void 0,void 0,function*(){return(yield((a=r==null?void 0:r.fetch)!==null&&a!==void 0?a:e.fetch)(n)).json()})}Es.fetchJson=u;function s(n,r){return t(this,void 0,void 0,function*(){return(yield u(n,r))["@context"]})}return Es.fetchContext=s,Es}var u4;function hX(){if(u4)return fd;u4=1;var t=I&&I.__awaiter||function(s,n,r,a){function o(l){return l instanceof r?l:new r(function(c){c(l)})}return new(r||(r=Promise))(function(l,c){function d(p){try{f(a.next(p))}catch(y){c(y)}}function h(p){try{f(a.throw(p))}catch(y){c(y)}}function f(p){p.done?l(p.value):o(p.value).then(d,h)}f((a=a.apply(s,n||[])).next())})};Object.defineProperty(fd,"__esModule",{value:!0}),fd.lookupUri=void 0;const e=KT();function u(s,n){return t(this,void 0,void 0,function*(){const r=(yield(0,e.fetchContext)(`https://prefix.cc/${s}.file.jsonld`,n))[s];if(typeof r!="string")throw new Error(`Expected uri to be a string, received: ${r} of type ${typeof r}`);return r})}return fd.lookupUri=u,fd}var hd={},c4;function pX(){if(c4)return hd;c4=1;var t=I&&I.__awaiter||function(s,n,r,a){function o(l){return l instanceof r?l:new r(function(c){c(l)})}return new(r||(r=Promise))(function(l,c){function d(p){try{f(a.next(p))}catch(y){c(y)}}function h(p){try{f(a.throw(p))}catch(y){c(y)}}function f(p){p.done?l(p.value):o(p.value).then(d,h)}f((a=a.apply(s,n||[])).next())})};Object.defineProperty(hd,"__esModule",{value:!0}),hd.lookupPrefix=void 0;const e=KT();function u(s,n){return t(this,void 0,void 0,function*(){const r=new URL("https://prefix.cc/reverse");r.searchParams.append("uri",s),r.searchParams.append("format","jsonld");const a=Object.keys(yield(0,e.fetchContext)(r,n));if(a.length===0)throw new Error("No prefixes returned");return a[0]})}return hd.lookupPrefix=u,hd}var pd={},l4;function yX(){if(l4)return pd;l4=1;var t=I&&I.__awaiter||function(s,n,r,a){function o(l){return l instanceof r?l:new r(function(c){c(l)})}return new(r||(r=Promise))(function(l,c){function d(p){try{f(a.next(p))}catch(y){c(y)}}function h(p){try{f(a.throw(p))}catch(y){c(y)}}function f(p){p.done?l(p.value):o(p.value).then(d,h)}f((a=a.apply(s,n||[])).next())})};Object.defineProperty(pd,"__esModule",{value:!0}),pd.lookupAllPrefixes=void 0;const e=KT();function u(s){return t(this,void 0,void 0,function*(){return(0,e.fetchContext)("https://prefix.cc/context",s)})}return pd.lookupAllPrefixes=u,pd}var d4;function f4(){return d4||(d4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(hX(),t),u(pX(),t),u(yX(),t)}(l2)),l2}var h4;function bX(){return h4||(h4=1,function(t){var e=I&&I.__awaiter||function(o,l,c,d){function h(f){return f instanceof c?f:new c(function(p){p(f)})}return new(c||(c=Promise))(function(f,p){function y(g){try{m(d.next(g))}catch(v){p(v)}}function b(g){try{m(d.throw(g))}catch(v){p(v)}}function m(g){g.done?f(g.value):h(g.value).then(y,b)}m((d=d.apply(o,l||[])).next())})};Object.defineProperty(t,"__esModule",{value:!0}),t.lookupAllPrefixes=t.prefixToUri=t.uriToPrefix=void 0;const u=dX(),s=f4();function n(o,l){return e(this,void 0,void 0,function*(){let c;try{c=yield(0,s.lookupPrefix)(o,l)}catch{l!=null&&l.mintOnUnknown&&(c=(0,u.fragment)(o).slice(0,4))}if(typeof c<"u"&&typeof(l==null?void 0:l.existingPrefixes)=="object"&&c in l.existingPrefixes){let d=0;for(;`${c}${d}`in l.existingPrefixes;)d+=1;c=`${c}${d}`}return c})}t.uriToPrefix=n;function r(o,l){return e(this,void 0,void 0,function*(){try{return yield(0,s.lookupUri)(o,l)}catch{return}})}t.prefixToUri=r;var a=f4();Object.defineProperty(t,"lookupAllPrefixes",{enumerable:!0,get:function(){return a.lookupAllPrefixes}})}(c2)),c2}var yd={},p4;function gX(){if(p4)return yd;p4=1,Object.defineProperty(yd,"__esModule",{value:!0}),yd.getShaclName=void 0;function t(e){if(e.termType!=="NamedNode"||!e.value.startsWith("http://www.w3.org/ns/shacl#"))throw new Error(`Term ${e.value} is not part of the SHACL namespace`);return e.value.slice(27)}return yd.getShaclName=t,yd}var g1={},y4;function mX(){return y4||(y4=1,Object.defineProperty(g1,"__esModule",{value:!0}),g1.default={deactivated:!0,severity:!0,message:!0,class:!0,datatype:!0,nodeKind:!0,minExclusive:!0,minInclusive:!0,maxExclusive:!0,maxInclusive:!0,minLength:!0,maxLength:!0,pattern:!0,flags:!0,languageIn:!0,uniqueLang:!0,equals:!0,disjoint:!0,lessThan:!0,lessThanOrEquals:!0,qualifiedValueShape:!0,qualifiedMinCount:!0,qualifiedMaxCount:!0,qualifiedValueShapesDisjoint:!0,closed:!0,ignoredProperties:!0,hasValue:!0,in:!0,node:!0}),g1}var m1={},b4;function _X(){return b4||(b4=1,Object.defineProperty(m1,"__esModule",{value:!0}),m1.default={owl:"http://www.w3.org/2002/07/owl#",rdf:"http://www.w3.org/1999/02/22-rdf-syntax-ns#",rdfs:"http://www.w3.org/2000/01/rdf-schema#",sh:"http://www.w3.org/ns/shacl#",xsd:"http://www.w3.org/2001/XMLSchema#"}),m1}var _1={},g4;function vX(){return g4||(g4=1,Object.defineProperty(_1,"__esModule",{value:!0}),_1.default={targetNode:!0,targetObjectsOf:!0,targetSubjectsOf:!0,deactivated:!0,severity:!0,message:!0,class:!0,datatype:!0,nodeKind:!0,minExclusive:!0,minInclusive:!0,maxExclusive:!0,maxInclusive:!0,minLength:!0,maxLength:!0,pattern:!0,flags:!0,languageIn:!0,equals:!0,disjoint:!0,closed:!0,ignoredProperties:!0,hasValue:!0,in:!0}),_1}var m4;function wX(){if(m4)return y1;m4=1;var t=I&&I.__awaiter||function(p,y,b,m){function g(v){return v instanceof b?v:new b(function(_){_(v)})}return new(b||(b=Promise))(function(v,_){function w(D){try{A(m.next(D))}catch(L){_(L)}}function S(D){try{A(m.throw(D))}catch(L){_(L)}}function A(D){D.done?v(D.value):g(D.value).then(w,S)}A((m=m.apply(p,y||[])).next())})},e=I&&I.__importDefault||function(p){return p&&p.__esModule?p:{default:p}};Object.defineProperty(y1,"__esModule",{value:!0});const u=ts,s=bX(),n=Oy(),r=gX(),a=e(mX()),o=e(_X()),l=e(vX());function c(p){var y;return(y=/^[^]*[#/]/.exec(p))===null||y===void 0?void 0:y[0]}const d={"http://www.w3.org/1999/02/22-rdf-syntax-ns#":"rdf","http://www.w3.org/2000/01/rdf-schema#":"rdfs","http://www.w3.org/ns/shacl#":"sh","http://www.w3.org/2001/XMLSchema#":"xsd"},h={rdf:"http://www.w3.org/1999/02/22-rdf-syntax-ns#",rdfs:"http://www.w3.org/2000/01/rdf-schema#",sh:"http://www.w3.org/ns/shacl#",xsd:"http://www.w3.org/2001/XMLSchema#"};class f{constructor(y,b,m={},g=void 0,v=!0,_=!1,w,S=!1){this.store=y,this.base=g,this.errorOnExtraQuads=v,this.mintUnspecifiedPrefixes=_,this.fetch=w,this.extendedSyntax=S,this.prefixes={},this.prefixRev={};for(const A of Object.keys(m)){const D=m[A],L=typeof D=="string"?D:D.value;!(L in d)&&!(A in h)&&(this.prefixRev[L]=A,this.prefixes[A]=L)}this.writer=b}write(){return t(this,void 0,void 0,function*(){const y=this.store.getQuads(null,"http://www.w3.org/1999/02/22-rdf-syntax-ns#type","http://www.w3.org/2002/07/owl#Ontology",null);if(y.length===1&&y[0].subject.termType==="NamedNode"){const m=y[0].subject;this.store.removeQuads(y),m.equals(new u.NamedNode("urn:x-base:default"))||this.writer.add(`BASE ${(0,n.termToString)(m)}`),yield this.writeImports(m)}else throw new Error("Base expected");if(this.mintUnspecifiedPrefixes){const m=new Set;for(const v of[...this.store.getSubjects(null,null,null),...this.store.getPredicates(null,null,null),...this.store.getObjects(null,null,null)])if(v.termType==="NamedNode"){const _=c(v.value);_&&!(_ in this.prefixRev)&&!(_ in d)&&m.add(_)}const g=Object.assign(Object.assign({},this.prefixes),h);yield Promise.all([...m].map(v=>(0,s.uriToPrefix)(v,{fetch:this.fetch,mintOnUnknown:!0,existingPrefixes:g}).then(_=>{this.prefixes[_]=v,g[_]=v,this.prefixRev[v]=_})))}const b=new Set([...this.store.getSubjects(null,null,null),...this.store.getPredicates(null,null,null),...this.store.getObjects(null,null,null)].filter(m=>m.termType==="NamedNode").map(m=>c(m.value)).filter(m=>typeof m=="string"));for(const m in this.prefixRev)b.has(m)||(delete this.prefixes[this.prefixRev[m]],delete this.prefixRev[m]);if(yield this.writePrefixes(),this.prefixes=Object.assign(Object.assign({},this.prefixes),h),this.prefixRev=Object.assign(Object.assign({},this.prefixRev),d),this.writer.newLine(),yield this.writeShapes(),this.extendedSyntax){const m=this.store.getSubjects(null,null,null);m.length>0&&this.writer.newLine(1);for(const g of m)this.writer.add(yield this.termToString(g,!0,!0)),this.writer.add(" "),this.writer.indent(),yield this.writeTurtlePredicates(g),this.writer.deindent();m.length>0&&(this.writer.add(" ."),this.writer.newLine())}if(this.errorOnExtraQuads&&this.store.size>0)throw new Error(`Dataset contains quads that cannot be written in SHACLC [ -${new u.Writer({prefixes:this.prefixes}).quadsToString(this.store.getQuads(null,null,null,null))}]`);this.writer.end()})}writeImports(y){return t(this,void 0,void 0,function*(){const b=this.store.getObjectsOnce(y,new u.NamedNode("http://www.w3.org/2002/07/owl#imports"),null);if(b.length>0)for(const m of b)this.writer.add(`IMPORTS <${m.value}>`,!0)})}writePrefixes(){return t(this,void 0,void 0,function*(){const y=Object.keys(this.prefixes).filter(b=>!(b in o.default)).sort();if(y.length>0)for(const b of y)this.writer.add(`PREFIX ${b}: <${this.prefixes[b]}>`,!0)})}termToString(y,b=!1,m=!1){return t(this,void 0,void 0,function*(){try{if(b)throw new Error("Shacl name disabled");return(0,r.getShaclName)(y)}catch{}if(y.termType==="NamedNode"){const g=c(y.value);return g&&g in this.prefixRev&&g in this.prefixRev?`${this.prefixRev[g]}:${y.value.slice(g.length)}`:(0,n.termToString)(y)}if(y.termType==="Literal")return y.datatypeString==="http://www.w3.org/2001/XMLSchema#integer"||y.datatypeString==="http://www.w3.org/2001/XMLSchema#boolean"?y.value:(0,n.termToString)(y);throw y.termType==="BlankNode"&&m&&(0,n.termToString)(y),new Error(`Invalid term type for extra statement ${y.value} (${y.termType})`)})}writeShapes(){return t(this,void 0,void 0,function*(){for(const y of this.store.getSubjectsOnce(new u.NamedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),new u.NamedNode("http://www.w3.org/ns/shacl#NodeShape"),null)){this.store.getQuadsOnce(y,new u.NamedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),new u.NamedNode("http://www.w3.org/2000/01/rdf-schema#Class"),null).length>0?this.writer.add("shapeClass "):this.writer.add("shape "),this.writer.add(yield this.termToString(y)),this.writer.add(" ");const b=this.store.getObjectsOnce(y,new u.NamedNode("http://www.w3.org/ns/shacl#targetClass"),null);if(b.length>0){this.writer.add("-> ");for(const g of b)g.termType==="NamedNode"?this.writer.add(yield this.termToString(g)):(this.writer.add("!"),this.writer.add(yield this.termToString(this.singleObject(g,new u.NamedNode("http://www.w3.org/ns/shacl#not"),!0)))),this.writer.add(" ")}const m=this.store.getPredicates(y,null,null).filter(g=>[new u.NamedNode("http://www.w3.org/ns/shacl#targetClass"),new u.NamedNode("http://www.w3.org/ns/shacl#property"),new u.NamedNode("http://www.w3.org/ns/shacl#or"),...Object.keys(l.default).map(v=>new u.NamedNode("http://www.w3.org/ns/shacl#"+v))].every(v=>!g.equals(v)));m.length>0&&(this.writer.add(";"),this.writer.indent(),this.writer.newLine(1)),this.extendedSyntax&&(yield this.writeGivenTurtlePredicates(y,m)),m.length>0&&(this.writer.add(" "),this.writer.deindent()),yield this.writeShapeBody(y,!1)}})}getSingleProperty(y,b){let m=[y];try{let g=(0,r.getShaclName)(y.predicate),v="pred";if(g==="not"){const _=this.store.getQuadsOnce(y.object,null,null,null);if(m=m.concat(_),_.length!==1)throw new Error("Can only handle having one predicate of 'not'");[y]=_,g=(0,r.getShaclName)(y.predicate),v="not"}if(!(g in b))throw new Error(`${g} is not allowed`);return{name:g,type:v,object:y.object}}catch{this.store.addQuads(m)}}singleLayerPropertiesList(y,b){const m=[];for(const g of this.store.getQuadsOnce(y,null,null,null)){const v=this.getSingleProperty(g,b);v&&m.push(v)}return m}expectOneProperty(y,b){const m=this.store.getQuadsOnce(y,null,null,null);if(m.length===1){const g=this.getSingleProperty(m[0],b);if(g)return g}this.store.addQuads(m)}orProperties(y,b){const m=[];for(const g of this.store.getQuadsOnce(y,new u.NamedNode("http://www.w3.org/ns/shacl#or"),null,null)){const v=[];for(const _ of this.getList(g.object)){const w=this.expectOneProperty(_,b);if(!w)throw this.store.addQuad(g),new Error("Each entry of the 'or' statement must declare exactly one property");v.push(w)}m.push(v)}return m}getList(y){let b=y;const m=[];for(;!b.equals(new u.NamedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#nil"));)m.push(this.singleObject(b,new u.NamedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#first"),!0)),b=this.singleObject(b,new u.NamedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#rest"),!0);return m}writeIriLiteralOrArray(y){return t(this,void 0,void 0,function*(){if(y.termType==="BlankNode"){this.writer.add("[");let b=!0;for(const m of this.getList(y))b?b=!1:this.writer.add(" "),this.writer.add(yield this.termToString(m));this.writer.add("]")}else this.writer.add(yield this.termToString(y))})}singleObject(y,b,m){var g;return(g=this.singleQuad(y,b,m))===null||g===void 0?void 0:g.object}singleQuad(y,b,m=!1){const g=this.store.getQuadsOnce(y,b,null,null);if(m&&g.length!==1)throw this.store.addQuads(g),new Error(`The subject and predicate ${y==null?void 0:y.value} ${b==null?void 0:b.value} must have exactly one object. Instead has ${g.length}`);if(g.length>1)throw this.store.addQuads(g),new Error(`The subject and predicate ${y==null?void 0:y.value} ${b==null?void 0:b.value} can have at most one object. Instead has ${g.length}`);return g.length===1?g[0]:void 0}writeAssigment({name:y,type:b,object:m}){return t(this,void 0,void 0,function*(){b==="not"&&this.writer.add("!"),this.writer.add(y),this.writer.add("="),yield this.writeIriLiteralOrArray(m)})}writeAtom({name:y,type:b,object:m}){return t(this,void 0,void 0,function*(){switch(b==="not"&&this.writer.add("!"),y){case"node":{if(m.termType==="NamedNode")this.writer.add(`@${yield this.termToString(m)}`);else if(m.termType==="BlankNode")yield this.writeShapeBody(m);else throw new Error("Invalid nested shape, must be blank node or IRI");return}case"nodeKind":{this.writer.add((0,r.getShaclName)(m));return}case"class":{this.writer.add(yield this.termToString(m));return}case"datatype":{this.writer.add(yield this.termToString(m));return}default:this.writer.add(y),this.writer.add("="),yield this.writeIriLiteralOrArray(m)}})}writeAssigments(y,b=" ",m=!0,g){return t(this,void 0,void 0,function*(){for(const v of y)m?m=!1:this.writer.add(b),g?yield this.writeAtom(v):yield this.writeAssigment(v)})}writeParams(y,b=!0,m,g=!1,v=!1){return t(this,void 0,void 0,function*(){const _=this.orProperties(y,m),w=this.singleLayerPropertiesList(y,m);v&&(_.length>0||w.length>0)&&this.writer.newLine(1);for(const S of _)b?b=!1:this.writer.add(" "),yield this.writeAssigments(S,"|",!0,g);yield this.writeAssigments(w," ",b,g),v&&(_.length>0||w.length>0)&&this.writer.add(" .")})}writeShapeBody(y,b=!0){return t(this,void 0,void 0,function*(){this.writer.add("{").indent();const m=this.store.getObjectsOnce(y,new u.NamedNode("http://www.w3.org/ns/shacl#property"),null);yield this.writeParams(y,!0,l.default,!1,!0);for(const g of m)this.writer.newLine(1),yield this.writeProperty(g);this.writer.deindent().newLine(1),b?this.writer.add("} ."):this.writer.add("}").newLine(1)})}writeProperty(y){return t(this,void 0,void 0,function*(){yield this.writePath(this.singleObject(y,new u.NamedNode("http://www.w3.org/ns/shacl#path"),!0));const b=this.singleObject(y,new u.NamedNode("http://www.w3.org/ns/shacl#minCount")),m=this.singleObject(y,new u.NamedNode("http://www.w3.org/ns/shacl#maxCount")),g=this.singleObject(y,new u.NamedNode("http://www.w3.org/ns/shacl#nodeKind")),v=this.singleObject(y,new u.NamedNode("http://www.w3.org/ns/shacl#class")),_=this.singleObject(y,new u.NamedNode("http://www.w3.org/ns/shacl#datatype")),w=this.store.getObjectsOnce(y,new u.NamedNode("http://www.w3.org/ns/shacl#node"),null);if(g&&(this.writer.add(" "),this.writer.add((0,r.getShaclName)(g))),v&&(this.writer.add(" "),this.writer.add(yield this.termToString(v))),_&&(this.writer.add(" "),this.writer.add(yield this.termToString(_))),b!==void 0||m!==void 0){if(this.writer.add(" ["),b){if(b.termType!=="Literal"||b.datatypeString!=="http://www.w3.org/2001/XMLSchema#integer")throw new Error("Invalid min value, must me an integer literal");this.writer.add(b.value)}else this.writer.add("0");if(this.writer.add(".."),m){if(m.termType!=="Literal"||m.datatypeString!=="http://www.w3.org/2001/XMLSchema#integer")throw new Error("Invalid max value, must me an integer literal");this.store.removeMatches(y,new u.NamedNode("http://www.w3.org/ns/shacl#maxCount"),void 0,void 0),this.writer.add(m.value)}else this.writer.add("*");this.writer.add("]")}yield this.writeParams(y,!1,a.default,!0);const S=[];for(const A of w)if(A.termType==="NamedNode")this.writer.add(" "),this.writer.add(`@${yield this.termToString(A)}`);else if(A.termType==="BlankNode")S.push(A);else throw new Error("Invalid nested shape, must be blank node or IRI");for(const A of S)this.writer.add(" "),yield this.writeShapeBody(A);this.extendedSyntax&&this.store.getQuads(y,null,null,null).length>0&&(this.writer.add(" %"),this.writer.indent(),this.writer.newLine(1),yield this.writeTurtlePredicates(y),this.writer.deindent(),this.writer.newLine(1),this.writer.add("%")),S.length===0&&this.writer.add(" .")})}writeTurtlePredicates(y){return t(this,void 0,void 0,function*(){return this.writeGivenTurtlePredicates(y,this.store.getPredicates(y,null,null))})}writeGivenTurtlePredicates(y,b){return t(this,void 0,void 0,function*(){let m=!1;if(b.some(g=>g.equals(u.DataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type")))){const g=this.store.getObjectsOnce(y,u.DataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),null);g.length>0&&(m=!0,this.writer.add("a "),yield this.writeTurtleObjects(g))}for(const g of b)g.equals(u.DataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"))||(m?(this.writer.add(" ;"),this.writer.newLine(1)):m=!0,this.writer.add(yield this.termToString(g,!0)),this.writer.add(" "),yield this.writeTurtleObjects(this.store.getObjectsOnce(y,g,null)))})}writeTurtleObjects(y){return t(this,void 0,void 0,function*(){const b=[],m=[];for(const v of y)v.termType==="BlankNode"&&[...this.store.match(null,null,v),...this.store.match(null,v,null)].length===0?b.push(v):m.push(v);this.writer.add((yield Promise.all(m.map(v=>this.termToString(v,!0,!0)))).join(", "));let g=m.length>0;if(b.length>0)for(const v of b)g?this.writer.add(", "):g=!0,(yield this.writeList(v))||(this.writer.add("["),this.writer.indent(),this.writer.newLine(1),yield this.writeTurtlePredicates(v),this.writer.deindent(),this.writer.newLine(1),this.writer.add("]"))})}writeList(y){return t(this,void 0,void 0,function*(){let b=y;const m=[],g=[];for(;!b.equals(u.DataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#nil"));){const _=this.store.getQuadsOnce(b,u.DataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#first"),null,null),w=this.store.getQuadsOnce(b,u.DataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#rest"),null,null);if(g.push(..._,...w),_.length!==1||w.length!==1||this.store.getQuads(b,null,null,null).length!==0)return this.store.addQuads(g),!1;m.push(_[0].object),b=w[0].object}let v=!1;this.writer.add("(");for(const _ of m)v?this.writer.add(" "):v=!0,yield this.writeTurtleObjects([_]);return this.writer.add(")"),!0})}writePath(y,b=!1){return t(this,void 0,void 0,function*(){if(y.termType==="NamedNode")this.writer.add(yield this.termToString(y));else if(y.termType==="BlankNode"){const m=this.store.getQuadsOnce(y,null,null,null);if(m.length===1){const{predicate:g,object:v}=m[0];switch(g.value){case"http://www.w3.org/ns/shacl#inversePath":this.writer.add("^"),yield this.writePath(v,!0);return;case"http://www.w3.org/ns/shacl#alternativePath":{const _=this.getList(v);if(_.length===0)throw new Error("Invalid Alternative Path - no options");if(_.length===1)yield this.writePath(_[0]);else{b&&this.writer.add("(");let w=!0;for(const S of _)w?w=!1:this.writer.add("|"),yield this.writePath(S,!0);b&&this.writer.add(")")}return}case"http://www.w3.org/ns/shacl#zeroOrMorePath":yield this.writePath(v,!0),this.writer.add("*");return;case"http://www.w3.org/ns/shacl#oneOrMorePath":yield this.writePath(v,!0),this.writer.add("+");return;case"http://www.w3.org/ns/shacl#zeroOrOnePath":yield this.writePath(v,!0),this.writer.add("?");return;default:throw new Error(`Invalid path type ${y.value}`)}}else{this.store.addQuads(m);const g=this.getList(y);if(g.length===0)throw new Error("Invalid Path");{b&&this.writer.add("(");let v=!0;for(const _ of g)v?v=!1:this.writer.add("/"),yield this.writePath(_,!0);b&&this.writer.add(")")}}}else throw new Error("Path should be named node or blank node")})}}return y1.default=f,y1}var v1={},_4;function SX(){if(_4)return v1;_4=1,Object.defineProperty(v1,"__esModule",{value:!0});class t{constructor(u){this.indents=0,this.write=u.write,this.end=u.end}indent(){return this.indents+=1,this}deindent(){if(this.indents<1)throw new Error(`Trying to deindent when indent is only ${this.indents}`);return this.indents-=1,this}add(u,s=!1){return this.write(s?` -${" ".repeat(this.indents)}${u}`:u,"utf-8"),this}newLine(u=2){return this.write(` -`.repeat(u)+" ".repeat(this.indents),"utf-8"),this}}return v1.default=t,v1}var w1={},v4;function TX(){if(v4)return w1;v4=1,Object.defineProperty(w1,"__esModule",{value:!0});const t=ts;class e extends t.Store{getQuadsOnce(s,n,r,a){const o=this.getQuads(s,n,r,a);return this.removeQuads(o),o}getSubjectsOnce(s,n,r){return this.getQuadsOnce(null,s,n,r).map(a=>a.subject)}getObjectsOnce(s,n,r){return this.getQuadsOnce(s,n,null,r).map(a=>a.object)}}return w1.default=e,w1}var w4;function AX(){if(w4)return ld;w4=1;var t=I&&I.__awaiter||function(o,l,c,d){function h(f){return f instanceof c?f:new c(function(p){p(f)})}return new(c||(c=Promise))(function(f,p){function y(g){try{m(d.next(g))}catch(v){p(v)}}function b(g){try{m(d.throw(g))}catch(v){p(v)}}function m(g){g.done?f(g.value):h(g.value).then(y,b)}m((d=d.apply(o,l||[])).next())})},e=I&&I.__importDefault||function(o){return o&&o.__esModule?o:{default:o}};Object.defineProperty(ld,"__esModule",{value:!0}),ld.write=void 0;const u=ts,s=e(wX()),n=e(SX()),r=e(TX());function a(o,l){return t(this,void 0,void 0,function*(){return new Promise((c,d)=>t(this,void 0,void 0,function*(){try{let h="";const f=new r.default(o),p=f.getGraphs(null,null,null);if(p.length>1)throw new Error("More than one graph found - can serialize in the default graph");if(p.length===1&&!p[0].equals(u.DataFactory.defaultGraph()))throw new Error(`Expected all triples to be in the default graph, instead triples were in ${p[0].value}`);const y=new n.default({write:m=>{h+=m},end:()=>{let m=f.getQuads(null,null,null,null);m.length===0&&(m=void 0),c({text:h,extraQuads:m})}});yield new s.default(f,y,l==null?void 0:l.prefixes,void 0,(l==null?void 0:l.errorOnUnused)!==!1,l==null?void 0:l.mintPrefixes,l==null?void 0:l.fetch,l==null?void 0:l.extendedSyntax).write()}catch(h){d(h)}}))})}return ld.write=a,ld}var S4;function EX(){if(S4)return cd;S4=1,Object.defineProperty(cd,"__esModule",{value:!0}),cd.ActorRdfSerializeShaclc=void 0;const t=XT(),e=lX(),u=Wt(),s=AX();let n=class extends t.ActorRdfSerializeFixedMediaTypes{constructor(a){super(a)}async runHandle(a,o){const l=new u.Readable;l._read=()=>{};try{const c={};a.quadStream.on("prefix",(h,f)=>{c[h]=f});const{text:d}=await(0,s.write)(await(0,e.default)(a.quadStream),{errorOnUnused:!0,extendedSyntax:o==="text/shaclc-ext",prefixes:c});l.push(d),l.push(null)}catch(c){l._read=()=>{l.emit("error",c)}}return{data:l,triples:!0}}};return cd.ActorRdfSerializeShaclc=n,cd}var T4;function OX(){return T4||(T4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(EX(),t)}(u2)),u2}var d2={},bd={},f2={},gd={},A4;function Zq(){if(A4)return gd;A4=1,Object.defineProperty(gd,"__esModule",{value:!0}),gd.ActorRdfUpdateQuads=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return gd.ActorRdfUpdateQuads=e,gd}var ua={},E4;function RX(){if(E4)return ua;E4=1,Object.defineProperty(ua,"__esModule",{value:!0}),ua.ActorRdfUpdateQuadsDestination=ua.deskolemize=ua.deskolemizeStream=void 0;const t=QF(),e=Lt,u=Zq();function s(a,o){return a==null?void 0:a.map(l=>(0,t.deskolemizeQuad)(l,o))}ua.deskolemizeStream=s;function n(a){var c;const o=a.context.get(e.KeysRdfUpdateQuads.destination),l=(c=a.context.get(e.KeysQuerySourceIdentify.sourceIds))==null?void 0:c.get(o);return l?{...a,quadStreamInsert:s(a.quadStreamInsert,l),quadStreamDelete:s(a.quadStreamDelete,l)}:a}ua.deskolemize=n;let r=class extends u.ActorRdfUpdateQuads{async test(o){return!0}async run(o){const l=await this.getDestination(o.context);return await this.getOutput(l,n(o))}async getOutput(o,l){return{execute:async()=>{await(l.quadStreamDelete?o.delete(l.quadStreamDelete):Promise.resolve()),await(l.deleteGraphs?o.deleteGraphs(l.deleteGraphs.graphs,l.deleteGraphs.requireExistence,l.deleteGraphs.dropGraphs):Promise.resolve()),await(l.createGraphs?o.createGraphs(l.createGraphs.graphs,l.createGraphs.requireNonExistence):Promise.resolve()),await(l.quadStreamInsert?o.insert(l.quadStreamInsert):Promise.resolve())}}}};return ua.ActorRdfUpdateQuadsDestination=r,ua}var h2={},O4;function xX(){return O4||(O4=1,Object.defineProperty(h2,"__esModule",{value:!0})),h2}var Sn={},R4;function IX(){if(R4)return Sn;R4=1,Object.defineProperty(Sn,"__esModule",{value:!0}),Sn.getContextDestinationUrl=Sn.getContextDestination=Sn.getDataDestinationContext=Sn.getDataDestinationValue=Sn.getDataDestinationType=Sn.isDataDestinationRawType=void 0;const t=Lt;function e(o){return typeof o=="string"||"remove"in o}Sn.isDataDestinationRawType=e;function u(o){return typeof o=="string"?"":"remove"in o?"rdfjsStore":o.type}Sn.getDataDestinationType=u;function s(o){return e(o)?o:o.value}Sn.getDataDestinationValue=s;function n(o,l){return typeof o=="string"||"remove"in o||!o.context?l:l.merge(o.context)}Sn.getDataDestinationContext=n;function r(o){return o.get(t.KeysRdfUpdateQuads.destination)}Sn.getContextDestination=r;function a(o){if(o){let l=s(o);if(typeof l=="string"){const c=l.indexOf("#");return c>=0&&(l=l.slice(0,c)),l}}}return Sn.getContextDestinationUrl=a,Sn}var x4;function YT(){return x4||(x4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Zq(),t),u(RX(),t),u(xX(),t),u(IX(),t)}(f2)),f2}var md={},_d={},I4;function PX(){if(I4)return _d;I4=1,Object.defineProperty(_d,"__esModule",{value:!0}),_d.promisifyEventEmitter=void 0;function t(e,u){return new Promise((s,n)=>{e.on("end",()=>s(u)),e.on("error",n)})}return _d.promisifyEventEmitter=t,_d}var P4;function DX(){if(P4)return md;P4=1,Object.defineProperty(md,"__esModule",{value:!0}),md.RdfJsQuadDestination=void 0;const t=PX(),e=Et(),u=er(),s=new e.DataFactory;let n=class{constructor(a){this.store=a}delete(a){return(0,t.promisifyEventEmitter)(this.store.remove(a))}insert(a){return(0,t.promisifyEventEmitter)(this.store.import(a))}async deleteGraphs(a,o,l){switch(a){case"ALL":await(0,t.promisifyEventEmitter)(this.store.deleteGraph(s.defaultGraph()));case"NAMED":const c=this.store.match(),d={};c.on("data",h=>{h.graph.termType!=="DefaultGraph"&&(d[(0,u.termToString)(h.graph)]=!0)}),await(0,t.promisifyEventEmitter)(c),await Promise.all(Object.keys(d).map(h=>(0,t.promisifyEventEmitter)(this.store.deleteGraph((0,u.stringToTerm)(h)))));break;default:for(const h of Array.isArray(a)?a:[a])await(0,t.promisifyEventEmitter)(this.store.deleteGraph(h))}}async createGraphs(a,o){if(o)for(const l of a){const c=this.store.match(void 0,void 0,void 0,l);await new Promise((d,h)=>{c.once("data",()=>{h(new Error(`Unable to create graph ${l.value} as it already exists`))}),c.on("end",d),c.on("error",h)})}}};return md.RdfJsQuadDestination=n,md}var D4;function NX(){if(D4)return bd;D4=1,Object.defineProperty(bd,"__esModule",{value:!0}),bd.ActorRdfUpdateQuadsRdfJsStore=void 0;const t=YT(),e=DX();let u=class extends t.ActorRdfUpdateQuadsDestination{constructor(n){super(n)}async test(n){const r=(0,t.getContextDestination)(n.context);if(!r||typeof r=="string"||!("remove"in r)&&"value"in r&&!r.value.remove)throw new Error(`${this.name} received an invalid rdfjsStore.`);return!0}async getDestination(n){const r=(0,t.getContextDestination)(n);return new e.RdfJsQuadDestination("remove"in r?r:r.value)}};return bd.ActorRdfUpdateQuadsRdfJsStore=u,bd}var N4;function CX(){return N4||(N4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(NX(),t)}(d2)),d2}var p2={},vd={},y2={},wd={},b2={},Os={},C4;function jX(){if(C4)return Os;C4=1,Object.defineProperty(Os,"__esModule",{value:!0}),Os.readableFromWeb=Os.ReadableFromWeb=void 0;const t=Wt();let e=class extends t.Readable{constructor(n,r){super(r),this.reader=n.getReader(),this.readerClosed=!1,this.reader.closed.then(()=>{this.readerClosed=!0}).catch(a=>{this.readerClosed=!0,this.destroy(a)})}_read(){this.reader.read().then(n=>this.push(n.done?null:n.value)).catch(n=>this.destroy(n))}destroy(n){return this.readerClosed||this.reader.cancel(n).then().catch(()=>{}),super.destroy(n)}};Os.ReadableFromWeb=e;function u(s,n){return new e(s,n)}return Os.readableFromWeb=u,Os}var j4;function LX(){return j4||(j4=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.readableFromWeb=void 0;var e=jX();Object.defineProperty(t,"readableFromWeb",{enumerable:!0,get:function(){return e.readableFromWeb}})}(b2)),b2}function S1(t){throw new Error('Could not dynamically require "'+t+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var g2={exports:{}},L4;function MX(){return L4||(L4=1,function(t,e){(function(u){t.exports=u()})(function(){return function u(s,n,r){function a(c,d){if(!n[c]){if(!s[c]){var h=typeof S1=="function"&&S1;if(!d&&h)return h(c,!0);if(o)return o(c,!0);var f=new Error("Cannot find module '"+c+"'");throw f.code="MODULE_NOT_FOUND",f}var p=n[c]={exports:{}};s[c][0].call(p.exports,function(y){var b=s[c][1][y];return a(b||y)},p,p.exports,u,s,n,r)}return n[c].exports}for(var o=typeof S1=="function"&&S1,l=0;l=0;he--)if(xe[he]!==ie[he])return!1;for(he=xe.length-1;he>=0;he--)if(X=xe[he],!m(M[X],q[X],Q,Z))return!1;return!0}function _(M,q,Q){m(M,q,!0)&&y(M,q,Q,"notDeepStrictEqual",_)}function w(M,q){if(!M||!q)return!1;if(Object.prototype.toString.call(q)=="[object RegExp]")return q.test(M);try{if(M instanceof q)return!0}catch{}return!Error.isPrototypeOf(q)&&q.call({},M)===!0}function S(M){var q;try{M()}catch(Q){q=Q}return q}function A(M,q,Q,Z){var K;if(typeof q!="function")throw new TypeError('"block" argument must be a function');typeof Q=="string"&&(Z=Q,Q=null),K=S(q),Z=(Q&&Q.name?" ("+Q.name+").":".")+(Z?" "+Z:"."),M&&!K&&y(K,Q,"Missing expected exception"+Z);var fe=typeof Z=="string",X=!M&&D.isError(K),he=!M&&K&&!Q;if((X&&fe&&w(K,Q)||he)&&y(K,Q,"Got unwanted exception"+Z),M&&K&&Q&&!w(K,Q)||!M&&K)throw K}var D=u("util/"),L=Object.prototype.hasOwnProperty,E=Array.prototype.slice,O=(function(){}).name==="foo",P=s.exports=b,j=/\s*function\s+([^\(\s]*)\s*/;P.AssertionError=function(q){this.name="AssertionError",this.actual=q.actual,this.expected=q.expected,this.operator=q.operator,q.message?(this.message=q.message,this.generatedMessage=!1):(this.message=p(this),this.generatedMessage=!0);var Q=q.stackStartFunction||y;if(Error.captureStackTrace)Error.captureStackTrace(this,Q);else{var Z=new Error;if(Z.stack){var K=Z.stack,fe=d(Q),X=K.indexOf(` -`+fe);if(X>=0){var he=K.indexOf(` -`,X+1);K=K.substring(he+1)}this.stack=K}}},D.inherits(P.AssertionError,Error),P.fail=y,P.ok=b,P.equal=function(q,Q,Z){q!=Q&&y(q,Q,Z,"==",P.equal)},P.notEqual=function(q,Q,Z){q==Q&&y(q,Q,Z,"!=",P.notEqual)},P.deepEqual=function(q,Q,Z){m(q,Q,!1)||y(q,Q,Z,"deepEqual",P.deepEqual)},P.deepStrictEqual=function(q,Q,Z){m(q,Q,!0)||y(q,Q,Z,"deepStrictEqual",P.deepStrictEqual)},P.notDeepEqual=function(q,Q,Z){m(q,Q,!1)&&y(q,Q,Z,"notDeepEqual",P.notDeepEqual)},P.notDeepStrictEqual=_,P.strictEqual=function(q,Q,Z){q!==Q&&y(q,Q,Z,"===",P.strictEqual)},P.notStrictEqual=function(q,Q,Z){q===Q&&y(q,Q,Z,"!==",P.notStrictEqual)},P.throws=function(M,q,Q){A(!0,M,q,Q)},P.doesNotThrow=function(M,q,Q){A(!1,M,q,Q)},P.ifError=function(M){if(M)throw M};var U=Object.keys||function(M){var q=[];for(var Q in M)L.call(M,Q)&&q.push(Q);return q}}).call(this,typeof I<"u"?I:typeof self<"u"?self:typeof window<"u"?window:{})},{"util/":7}],3:[function(u,s,n){},{}],4:[function(u,s,n){function r(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function o(w){if(p===setTimeout)return setTimeout(w,0);if((p===r||!p)&&setTimeout)return p=setTimeout,setTimeout(w,0);try{return p(w,0)}catch{try{return p.call(null,w,0)}catch{return p.call(this,w,0)}}}function l(w){if(y===clearTimeout)return clearTimeout(w);if((y===a||!y)&&clearTimeout)return y=clearTimeout,clearTimeout(w);try{return y(w)}catch{try{return y.call(null,w)}catch{return y.call(this,w)}}}function c(){v&&m&&(v=!1,m.length?g=m.concat(g):_=-1,g.length&&d())}function d(){if(!v){var w=o(c);v=!0;for(var S=g.length;S;){for(m=g,g=[];++_1)for(var A=1;A=3&&(Oe.depth=arguments[2]),arguments.length>=4&&(Oe.colors=arguments[3]),v(ae)?Oe.showHidden=ae:ae&&n._extend(Oe,ae),L(Oe.showHidden)&&(Oe.showHidden=!1),L(Oe.depth)&&(Oe.depth=2),L(Oe.colors)&&(Oe.colors=!1),L(Oe.customInspect)&&(Oe.customInspect=!0),Oe.colors&&(Oe.stylize=l),h(Oe,ie,Oe.depth)}function l(ie,ae){var Oe=o.styles[ae];return Oe?"\x1B["+o.colors[Oe][0]+"m"+ie+"\x1B["+o.colors[Oe][1]+"m":ie}function c(ie,ae){return ie}function d(ie){var ae={};return ie.forEach(function(Oe,Ne){ae[Oe]=!0}),ae}function h(ie,ae,Oe){if(ie.customInspect&&ae&&U(ae.inspect)&&ae.inspect!==n.inspect&&(!ae.constructor||ae.constructor.prototype!==ae)){var Ne=ae.inspect(Oe,ie);return A(Ne)||(Ne=h(ie,Ne,Oe)),Ne}var ge=f(ie,ae);if(ge)return ge;var de=Object.keys(ae),oe=d(de);if(ie.showHidden&&(de=Object.getOwnPropertyNames(ae)),j(ae)&&(de.indexOf("message")>=0||de.indexOf("description")>=0))return p(ae);if(de.length===0){if(U(ae)){var $=ae.name?": "+ae.name:"";return ie.stylize("[Function"+$+"]","special")}if(E(ae))return ie.stylize(RegExp.prototype.toString.call(ae),"regexp");if(P(ae))return ie.stylize(Date.prototype.toString.call(ae),"date");if(j(ae))return p(ae)}var N="",R=!1,T=["{","}"];if(g(ae)&&(R=!0,T=["[","]"]),U(ae)&&(N=" [Function"+(ae.name?": "+ae.name:"")+"]"),E(ae)&&(N=" "+RegExp.prototype.toString.call(ae)),P(ae)&&(N=" "+Date.prototype.toUTCString.call(ae)),j(ae)&&(N=" "+p(ae)),de.length===0&&(!R||ae.length==0))return T[0]+N+T[1];if(Oe<0)return E(ae)?ie.stylize(RegExp.prototype.toString.call(ae),"regexp"):ie.stylize("[Object]","special");ie.seen.push(ae);var x;return x=R?y(ie,ae,Oe,oe,de):de.map(function(B){return b(ie,ae,Oe,oe,B,R)}),ie.seen.pop(),m(x,N,T)}function f(ie,ae){if(L(ae))return ie.stylize("undefined","undefined");if(A(ae)){var Oe="'"+JSON.stringify(ae).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return ie.stylize(Oe,"string")}return S(ae)?ie.stylize(""+ae,"number"):v(ae)?ie.stylize(""+ae,"boolean"):_(ae)?ie.stylize("null","null"):void 0}function p(ie){return"["+Error.prototype.toString.call(ie)+"]"}function y(ie,ae,Oe,Ne,ge){for(var de=[],oe=0,$=ae.length;oe<$;++oe)K(ae,String(oe))?de.push(b(ie,ae,Oe,Ne,String(oe),!0)):de.push("");return ge.forEach(function(N){N.match(/^\d+$/)||de.push(b(ie,ae,Oe,Ne,N,!0))}),de}function b(ie,ae,Oe,Ne,ge,de){var oe,$,N;if((N=Object.getOwnPropertyDescriptor(ae,ge)||{value:ae[ge]}).get?$=N.set?ie.stylize("[Getter/Setter]","special"):ie.stylize("[Getter]","special"):N.set&&($=ie.stylize("[Setter]","special")),K(Ne,ge)||(oe="["+ge+"]"),$||(ie.seen.indexOf(N.value)<0?($=_(Oe)?h(ie,N.value,null):h(ie,N.value,Oe-1)).indexOf(` -`)>-1&&($=de?$.split(` -`).map(function(R){return" "+R}).join(` -`).substr(2):` -`+$.split(` -`).map(function(R){return" "+R}).join(` -`)):$=ie.stylize("[Circular]","special")),L(oe)){if(de&&ge.match(/^\d+$/))return $;(oe=JSON.stringify(""+ge)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(oe=oe.substr(1,oe.length-2),oe=ie.stylize(oe,"name")):(oe=oe.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),oe=ie.stylize(oe,"string"))}return oe+": "+$}function m(ie,ae,Oe){var Ne=0;return ie.reduce(function(ge,de){return Ne++,de.indexOf(` -`)>=0&&Ne++,ge+de.replace(/\u001b\[\d\d?m/g,"").length+1},0)>60?Oe[0]+(ae===""?"":ae+` - `)+" "+ie.join(`, - `)+" "+Oe[1]:Oe[0]+ae+" "+ie.join(", ")+" "+Oe[1]}function g(ie){return Array.isArray(ie)}function v(ie){return typeof ie=="boolean"}function _(ie){return ie===null}function w(ie){return ie==null}function S(ie){return typeof ie=="number"}function A(ie){return typeof ie=="string"}function D(ie){return typeof ie=="symbol"}function L(ie){return ie===void 0}function E(ie){return O(ie)&&q(ie)==="[object RegExp]"}function O(ie){return typeof ie=="object"&&ie!==null}function P(ie){return O(ie)&&q(ie)==="[object Date]"}function j(ie){return O(ie)&&(q(ie)==="[object Error]"||ie instanceof Error)}function U(ie){return typeof ie=="function"}function M(ie){return ie===null||typeof ie=="boolean"||typeof ie=="number"||typeof ie=="string"||typeof ie=="symbol"||ie===void 0}function q(ie){return Object.prototype.toString.call(ie)}function Q(ie){return ie<10?"0"+ie.toString(10):ie.toString(10)}function Z(){var ie=new Date,ae=[Q(ie.getHours()),Q(ie.getMinutes()),Q(ie.getSeconds())].join(":");return[ie.getDate(),xe[ie.getMonth()],ae].join(" ")}function K(ie,ae){return Object.prototype.hasOwnProperty.call(ie,ae)}var fe=/%[sdj%]/g;n.format=function(ie){if(!A(ie)){for(var ae=[],Oe=0;Oe=ge)return N;switch(N){case"%s":return String(Ne[Oe++]);case"%d":return Number(Ne[Oe++]);case"%j":try{return JSON.stringify(Ne[Oe++])}catch{return"[Circular]"}default:return N}}),oe=Ne[Oe];Oe3&&arguments[3]!==void 0?arguments[3]:1,st=arguments.length>4&&arguments[4]!==void 0?arguments[4]:function(){return 1},ht=Object.create(Ni.prototype);return d(ht),ge(ht,Object.create(Xr.prototype),ue,ve,je,Xe,st),ht}function c(ue,ve,je){var Xe=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,st=arguments.length>4&&arguments[4]!==void 0?arguments[4]:void 0,ht=Object.create(Ni.prototype);return d(ht),Ce(ht,Object.create(Zn.prototype),ue,ve,je,Xe,st),ht}function d(ue){ue._state="readable",ue._reader=void 0,ue._storedError=void 0,ue._disturbed=!1}function h(ue){return!!Ke(ue)&&!!Object.prototype.hasOwnProperty.call(ue,"_readableStreamController")}function f(ue){return ue._disturbed}function p(ue){return ue._reader!==void 0}function y(ue,ve){function je(){return Q(st).then(function(Fr){var gn=Fr.value;if(Fr.done===!0&&ht===!1&&(St===!1&&X(vr._readableStreamController),Ht===!1&&X(zt._readableStreamController),ht=!0),ht!==!0){var $n=gn,Qn=gn;St===!1&&he(vr._readableStreamController,$n),Ht===!1&&he(zt._readableStreamController,Qn)}})}function Xe(){}var st=o(ue),ht=!1,St=!1,Ht=!1,Xt=void 0,lr=void 0,vr=void 0,zt=void 0,Fn=void 0,ei=new Promise(function(Fr){Fn=Fr});return vr=l(Xe,je,function(gn){if(St=!0,Xt=gn,Ht===!0){var $n=Ir([Xt,lr]),Qn=g(ue,$n);Fn(Qn)}return ei}),zt=l(Xe,je,function(gn){if(Ht=!0,lr=gn,St===!0){var $n=Ir([Xt,lr]),Qn=g(ue,$n);Fn(Qn)}return ei}),st._closedPromise.catch(function(Fr){ht!==!0&&(ie(vr._readableStreamController,Fr),ie(zt._readableStreamController,Fr),ht=!0)}),[vr,zt]}function b(ue){return new Promise(function(ve,je){var Xe={_resolve:ve,_reject:je};ue._reader._readIntoRequests.push(Xe)})}function m(ue){return new Promise(function(ve,je){var Xe={_resolve:ve,_reject:je};ue._reader._readRequests.push(Xe)})}function g(ue,ve){return ue._disturbed=!0,ue._state==="closed"?Promise.resolve(void 0):ue._state==="errored"?Promise.reject(ue._storedError):(v(ue),ue._readableStreamController[fi](ve).then(function(){}))}function v(ue){ue._state="closed";var ve=ue._reader;if(ve!==void 0){if(P(ve)===!0){var je=!0,Xe=!1,st=void 0;try{for(var ht,St=ve._readRequests[Symbol.iterator]();!(je=(ht=St.next()).done);je=!0)(0,ht.value._resolve)(Ye(void 0,!0))}catch(Ht){Xe=!0,st=Ht}finally{try{!je&&St.return&&St.return()}finally{if(Xe)throw st}}ve._readRequests=[]}tt(ve)}}function _(ue,ve){ue._state="errored",ue._storedError=ve;var je=ue._reader;if(je!==void 0){if(P(je)===!0){var Xe=!0,st=!1,ht=void 0;try{for(var St,Ht=je._readRequests[Symbol.iterator]();!(Xe=(St=Ht.next()).done);Xe=!0)St.value._reject(ve)}catch(ei){st=!0,ht=ei}finally{try{!Xe&&Ht.return&&Ht.return()}finally{if(st)throw ht}}je._readRequests=[]}else{var Xt=!0,lr=!1,vr=void 0;try{for(var zt,Fn=je._readIntoRequests[Symbol.iterator]();!(Xt=(zt=Fn.next()).done);Xt=!0)zt.value._reject(ve)}catch(ei){lr=!0,vr=ei}finally{try{!Xt&&Fn.return&&Fn.return()}finally{if(lr)throw vr}}je._readIntoRequests=[]}$e(je,ve),je._closedPromise.catch(function(){})}}function w(ue,ve,je){ue._reader._readIntoRequests.shift()._resolve(Ye(ve,je))}function S(ue,ve,je){ue._reader._readRequests.shift()._resolve(Ye(ve,je))}function A(ue){return ue._reader._readIntoRequests.length}function D(ue){return ue._reader._readRequests.length}function L(ue){var ve=ue._reader;return ve!==void 0&&O(ve)!==!1}function E(ue){var ve=ue._reader;return ve!==void 0&&P(ve)!==!1}function O(ue){return!!Ke(ue)&&!!Object.prototype.hasOwnProperty.call(ue,"_readIntoRequests")}function P(ue){return!!Ke(ue)&&!!Object.prototype.hasOwnProperty.call(ue,"_readRequests")}function j(ue,ve){ue._ownerReadableStream=ve,ve._reader=ue,ve._state==="readable"?we(ue):ve._state==="closed"?Le(ue):(Te(ue,ve._storedError),ue._closedPromise.catch(function(){}))}function U(ue,ve){return g(ue._ownerReadableStream,ve)}function M(ue){ue._ownerReadableStream._state==="readable"?$e(ue,new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")):We(ue,new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")),ue._closedPromise.catch(function(){}),ue._ownerReadableStream._reader=void 0,ue._ownerReadableStream=void 0}function q(ue,ve){var je=ue._ownerReadableStream;return je._disturbed=!0,je._state==="errored"?Promise.reject(je._storedError):te(je._readableStreamController,ve)}function Q(ue){var ve=ue._ownerReadableStream;return ve._disturbed=!0,ve._state==="closed"?Promise.resolve(Ye(void 0,!0)):ve._state==="errored"?Promise.reject(ve._storedError):ve._readableStreamController[Mr]()}function Z(ue){return!!Ke(ue)&&!!Object.prototype.hasOwnProperty.call(ue,"_controlledReadableStream")}function K(ue){fe(ue)!==!1&&(ue._pulling!==!0?(ue._pulling=!0,ue._pullAlgorithm().then(function(){if(ue._pulling=!1,ue._pullAgain===!0)return ue._pullAgain=!1,K(ue)},function(ve){ie(ue,ve)}).catch(Pe)):ue._pullAgain=!0)}function fe(ue){var ve=ue._controlledReadableStream;return Ne(ue)!==!1&&ue._started!==!1&&(p(ve)===!0&&D(ve)>0||ae(ue)>0)}function X(ue){var ve=ue._controlledReadableStream;ue._closeRequested=!0,ue._queue.length===0&&v(ve)}function he(ue,ve){var je=ue._controlledReadableStream;if(p(je)===!0&&D(je)>0)S(je,ve,!1);else{var Xe=void 0;try{Xe=ue._strategySizeAlgorithm(ve)}catch(st){throw ie(ue,st),st}try{at(ue,ve,Xe)}catch(st){throw ie(ue,st),st}}K(ue)}function xe(ue,ve){var je=ue._controlledReadableStream;Tt(ue),_(je,ve)}function ie(ue,ve){ue._controlledReadableStream._state==="readable"&&xe(ue,ve)}function ae(ue){var ve=ue._controlledReadableStream._state;return ve==="errored"?null:ve==="closed"?0:ue._strategyHWM-ue._queueTotalSize}function Oe(ue){return fe(ue)!==!0}function Ne(ue){var ve=ue._controlledReadableStream._state;return ue._closeRequested===!1&&ve==="readable"}function ge(ue,ve,je,Xe,st,ht,St){ve._controlledReadableStream=ue,ve._queue=void 0,ve._queueTotalSize=void 0,Tt(ve),ve._started=!1,ve._closeRequested=!1,ve._pullAgain=!1,ve._pulling=!1,ve._strategySizeAlgorithm=St,ve._strategyHWM=ht,ve._pullAlgorithm=Xe,ve._cancelAlgorithm=st,ue._readableStreamController=ve;var Ht=je();Promise.resolve(Ht).then(function(){ve._started=!0,K(ve)},function(Xt){ie(ve,Xt)}).catch(Pe)}function de(ue,ve,je,Xe){var st=Object.create(Xr.prototype),ht=Fe(ve,"pull",0,[st]),St=Fe(ve,"cancel",1,[]);ge(ue,st,function(){return Je(ve,"start",[st])},ht,St,je,Xe)}function oe(ue){return!!Ke(ue)&&!!Object.prototype.hasOwnProperty.call(ue,"_controlledReadableByteStream")}function $(ue){return!!Ke(ue)&&!!Object.prototype.hasOwnProperty.call(ue,"_associatedReadableByteStreamController")}function N(ue){qe(ue)!==!1&&(ue._pulling!==!0?(ue._pulling=!0,ue._pullAlgorithm().then(function(){ue._pulling=!1,ue._pullAgain===!0&&(ue._pullAgain=!1,N(ue))},function(ve){ue._controlledReadableByteStream._state==="readable"&&H(ue,ve)}).catch(Pe)):ue._pullAgain=!0)}function R(ue){z(ue),ue._pendingPullIntos=[]}function T(ue,ve){var je=!1;ue._state==="closed"&&(je=!0);var Xe=x(ve);ve.readerType==="default"?S(ue,Xe,je):w(ue,Xe,je)}function x(ue){var ve=ue.bytesFilled,je=ue.elementSize;return new ue.ctor(ue.buffer,ue.byteOffset,ve/je)}function B(ue,ve,je,Xe){ue._queue.push({buffer:ve,byteOffset:je,byteLength:Xe}),ue._queueTotalSize+=Xe}function k(ue,ve){var je=ve.elementSize,Xe=ve.bytesFilled-ve.bytesFilled%je,st=Math.min(ue._queueTotalSize,ve.byteLength-ve.bytesFilled),ht=ve.bytesFilled+st,St=ht-ht%je,Ht=st,Xt=!1;St>Xe&&(Ht=St-ve.bytesFilled,Xt=!0);for(var lr=ue._queue;Ht>0;){var vr=lr[0],zt=Math.min(Ht,vr.byteLength),Fn=ve.byteOffset+ve.bytesFilled;Ue(ve.buffer,Fn,vr.buffer,vr.byteOffset,zt),vr.byteLength===zt?lr.shift():(vr.byteOffset+=zt,vr.byteLength-=zt),ue._queueTotalSize-=zt,V(ue,zt,ve),Ht-=zt}return Xt}function V(ue,ve,je){z(ue),je.bytesFilled+=ve}function J(ue){ue._queueTotalSize===0&&ue._closeRequested===!0?v(ue._controlledReadableByteStream):N(ue)}function z(ue){ue._byobRequest!==void 0&&(ue._byobRequest._associatedReadableByteStreamController=void 0,ue._byobRequest._view=void 0,ue._byobRequest=void 0)}function Y(ue){for(;ue._pendingPullIntos.length>0;){if(ue._queueTotalSize===0)return;var ve=ue._pendingPullIntos[0];k(ue,ve)===!0&&(Ee(ue),T(ue._controlledReadableByteStream,ve))}}function te(ue,ve){var je=ue._controlledReadableByteStream,Xe=1;ve.constructor!==DataView&&(Xe=ve.constructor.BYTES_PER_ELEMENT);var st=ve.constructor,ht={buffer:yt(ve.buffer),byteOffset:ve.byteOffset,byteLength:ve.byteLength,bytesFilled:0,elementSize:Xe,ctor:st,readerType:"byob"};if(ue._pendingPullIntos.length>0)return ue._pendingPullIntos.push(ht),b(je);if(je._state==="closed"){var St=new ve.constructor(ht.buffer,ht.byteOffset,0);return Promise.resolve(Ye(St,!0))}if(ue._queueTotalSize>0){if(k(ue,ht)===!0){var Ht=x(ht);return J(ue),Promise.resolve(Ye(Ht,!1))}if(ue._closeRequested===!0){var Xt=new TypeError("Insufficient bytes to fill elements in the given buffer");return H(ue,Xt),Promise.reject(Xt)}}ue._pendingPullIntos.push(ht);var lr=b(je);return N(ue),lr}function ce(ue,ve){ve.buffer=yt(ve.buffer);var je=ue._controlledReadableByteStream;if(L(je)===!0)for(;A(je)>0;)T(je,Ee(ue))}function Ae(ue,ve,je){if(je.bytesFilled+ve>je.byteLength)throw new RangeError("bytesWritten out of range");if(V(ue,ve,je),!(je.bytesFilled0){var st=je.byteOffset+je.bytesFilled,ht=je.buffer.slice(st-Xe,st);B(ue,ht,0,ht.byteLength)}je.buffer=yt(je.buffer),je.bytesFilled-=Xe,T(ue._controlledReadableByteStream,je),Y(ue)}}function Ie(ue,ve){var je=ue._pendingPullIntos[0];if(ue._controlledReadableByteStream._state==="closed"){if(ve!==0)throw new TypeError("bytesWritten must be 0 when calling respond() on a closed stream");ce(ue,je)}else Ae(ue,ve,je)}function Ee(ue){var ve=ue._pendingPullIntos.shift();return z(ue),ve}function qe(ue){var ve=ue._controlledReadableByteStream;return ve._state==="readable"&&ue._closeRequested!==!0&&ue._started!==!1&&(E(ve)===!0&&D(ve)>0||L(ve)===!0&&A(ve)>0||re(ue)>0)}function G(ue){var ve=ue._controlledReadableByteStream;if(ue._queueTotalSize>0)ue._closeRequested=!0;else{if(ue._pendingPullIntos.length>0&&ue._pendingPullIntos[0].bytesFilled>0){var je=new TypeError("Insufficient bytes to fill elements in the given buffer");throw H(ue,je),je}v(ve)}}function F(ue,ve){var je=ue._controlledReadableByteStream,Xe=ve.buffer,st=ve.byteOffset,ht=ve.byteLength,St=yt(Xe);E(je)===!0?D(je)===0?B(ue,St,st,ht):S(je,new Uint8Array(St,st,ht),!1):L(je)===!0?(B(ue,St,st,ht),Y(ue)):B(ue,St,st,ht)}function H(ue,ve){var je=ue._controlledReadableByteStream;R(ue),Tt(ue),_(je,ve)}function re(ue){var ve=ue._controlledReadableByteStream._state;return ve==="errored"?null:ve==="closed"?0:ue._strategyHWM-ue._queueTotalSize}function be(ue,ve){if(ve=Number(ve),Ve(ve)===!1)throw new RangeError("bytesWritten must be a finite");Ie(ue,ve)}function Re(ue,ve){var je=ue._pendingPullIntos[0];if(je.byteOffset+je.bytesFilled!==ve.byteOffset)throw new RangeError("The region specified by view does not match byobRequest");if(je.byteLength!==ve.byteLength)throw new RangeError("The buffer of view has different capacity than byobRequest");je.buffer=ve.buffer,Ie(ue,ve.byteLength)}function Ce(ue,ve,je,Xe,st,ht,St){ve._controlledReadableByteStream=ue,ve._pullAgain=!1,ve._pulling=!1,R(ve),ve._queue=ve._queueTotalSize=void 0,Tt(ve),ve._closeRequested=!1,ve._started=!1,ve._strategyHWM=ft(ht),ve._pullAlgorithm=Xe,ve._cancelAlgorithm=st,ve._autoAllocateChunkSize=St,ve._pendingPullIntos=[],ue._readableStreamController=ve;var Ht=je();Promise.resolve(Ht).then(function(){ve._started=!0,N(ve)},function(Xt){ue._state==="readable"&&H(ve,Xt)}).catch(Pe)}function Qe(ue,ve,je){var Xe=Object.create(Zn.prototype),st=Fe(ve,"pull",0,[Xe]),ht=Fe(ve,"cancel",1,[]),St=ve.autoAllocateChunkSize;if(St!==void 0&&(Number.isInteger(St)===!1||St<=0))throw new RangeError("autoAllocateChunkSize must be a positive integer");Ce(ue,Xe,function(){return Je(ve,"start",[Xe])},st,ht,je,St)}function ke(ue,ve,je){ue._associatedReadableByteStreamController=ve,ue._view=je}function me(ue){return new TypeError("ReadableStream.prototype."+ue+" can only be used on a ReadableStream")}function Se(ue){return new TypeError("Cannot "+ue+" a stream using a released reader")}function W(ue){return new TypeError("ReadableStreamDefaultReader.prototype."+ue+" can only be used on a ReadableStreamDefaultReader")}function we(ue){ue._closedPromise=new Promise(function(ve,je){ue._closedPromise_resolve=ve,ue._closedPromise_reject=je})}function Te(ue,ve){ue._closedPromise=Promise.reject(ve),ue._closedPromise_resolve=void 0,ue._closedPromise_reject=void 0}function Le(ue){ue._closedPromise=Promise.resolve(void 0),ue._closedPromise_resolve=void 0,ue._closedPromise_reject=void 0}function $e(ue,ve){ue._closedPromise_reject(ve),ue._closedPromise_resolve=void 0,ue._closedPromise_reject=void 0}function We(ue,ve){ue._closedPromise=Promise.reject(ve)}function tt(ue){ue._closedPromise_resolve(void 0),ue._closedPromise_resolve=void 0,ue._closedPromise_reject=void 0}function lt(ue){return new TypeError("ReadableStreamBYOBReader.prototype."+ue+" can only be used on a ReadableStreamBYOBReader")}function ut(ue){return new TypeError("ReadableStreamDefaultController.prototype."+ue+" can only be used on a ReadableStreamDefaultController")}function le(ue){return new TypeError("ReadableStreamBYOBRequest.prototype."+ue+" can only be used on a ReadableStreamBYOBRequest")}function C(ue){return new TypeError("ReadableByteStreamController.prototype."+ue+" can only be used on a ReadableByteStreamController")}function ee(ue){try{Promise.prototype.then.call(ue,void 0,function(){})}catch{}}var pe=function(){function ue(ve,je){for(var Xe=0;Xe0&&arguments[0]!==void 0?arguments[0]:{},je=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Xe=je.size,st=je.highWaterMark;r(this,ue),d(this);var ht=ve.type;if(String(ht)==="bytes"){if(st===void 0&&(st=0),st=ft(st),Xe!==void 0)throw new RangeError("The strategy for a byte stream cannot have a size function");Qe(this,ve,st)}else{if(ht!==void 0)throw new RangeError("Invalid type is specified");st===void 0&&(st=1),de(this,ve,st=ft(st),et(Xe))}}return pe(ue,[{key:"cancel",value:function(je){return h(this)===!1?Promise.reject(me("cancel")):p(this)===!0?Promise.reject(new TypeError("Cannot cancel a stream that already has a reader")):g(this,je)}},{key:"getReader",value:function(){var je=(arguments.length>0&&arguments[0]!==void 0?arguments[0]:{}).mode;if(h(this)===!1)throw me("getReader");if(je===void 0)return o(this);if((je=String(je))==="byob")return a(this);throw new RangeError("Invalid mode is specified")}},{key:"pipeThrough",value:function(je,Xe){var st=je.writable,ht=je.readable;if(st===void 0||ht===void 0)throw new TypeError("readable and writable arguments must be defined");return ee(this.pipeTo(st,Xe)),ht}},{key:"pipeTo",value:function(je){var Xe=this,st=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},ht=st.preventClose,St=st.preventAbort,Ht=st.preventCancel;if(h(this)===!1)return Promise.reject(me("pipeTo"));if(di(je)===!1)return Promise.reject(new TypeError("ReadableStream.prototype.pipeTo's first argument must be a WritableStream"));if(ht=!!ht,St=!!St,Ht=!!Ht,p(this)===!0)return Promise.reject(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked ReadableStream"));if(yn(je)===!0)return Promise.reject(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked WritableStream"));var Xt=o(this),lr=tr(je),vr=!1,zt=Promise.resolve();return new Promise(function(Fn,ei){function Fr(){return vr===!0?Promise.resolve():lr._readyPromise.then(function(){return Q(Xt).then(function(Kt){var zr=Kt.value;Kt.done!==!0&&(zt=Hn(lr,zr).catch(function(){}))})}).then(Fr)}function gn(){var Kt=zt;return zt.then(function(){return Kt!==zt?gn():void 0})}function $n(Kt,zr,ri){Kt._state==="errored"?ri(Kt._storedError):zr.catch(ri).catch(Pe)}function Qn(Kt,zr,ri){function Aa(){Kt().then(function(){return ea(zr,ri)},function(Iy){return ea(!0,Iy)}).catch(Pe)}vr!==!0&&(vr=!0,je._state==="writable"&&Pr(je)===!1?gn().then(Aa):Aa())}function ti(Kt,zr){vr!==!0&&(vr=!0,je._state==="writable"&&Pr(je)===!1?gn().then(function(){return ea(Kt,zr)}).catch(Pe):ea(Kt,zr))}function ea(Kt,zr){Hr(lr),M(Xt),Kt?ei(zr):Fn(void 0)}if($n(Xe,Xt._closedPromise,function(Kt){St===!1?Qn(function(){return or(je,Kt)},!0,Kt):ti(!0,Kt)}),$n(je,lr._closedPromise,function(Kt){Ht===!1?Qn(function(){return g(Xe,Kt)},!0,Kt):ti(!0,Kt)}),function(zr,ri,Aa){zr._state==="closed"?Aa():ri.then(Aa).catch(Pe)}(Xe,Xt._closedPromise,function(){ht===!1?Qn(function(){return Mn(lr)}):ti()}),Pr(je)===!0||je._state==="closed"){var no=new TypeError("the destination writable stream closed before all data could be piped to it");Ht===!1?Qn(function(){return g(Xe,no)},!0,no):ti(!0,no)}Fr().catch(function(Kt){zt=Promise.resolve(),Pe(Kt)})})}},{key:"tee",value:function(){if(h(this)===!1)throw me("tee");var je=y(this);return Ir(je)}},{key:"locked",get:function(){if(h(this)===!1)throw me("locked");return p(this)}}]),ue}();s.exports={CreateReadableByteStream:c,CreateReadableStream:l,ReadableStream:Ni,IsReadableStreamDisturbed:f,ReadableStreamDefaultControllerClose:X,ReadableStreamDefaultControllerEnqueue:he,ReadableStreamDefaultControllerError:xe,ReadableStreamDefaultControllerGetDesiredSize:ae,ReadableStreamDefaultControllerHasBackpressure:Oe,ReadableStreamDefaultControllerCanCloseOrEnqueue:Ne};var Zi=function(){function ue(ve){if(r(this,ue),h(ve)===!1)throw new TypeError("ReadableStreamDefaultReader can only be constructed with a ReadableStream instance");if(p(ve)===!0)throw new TypeError("This stream has already been locked for exclusive reading by another reader");j(this,ve),this._readRequests=[]}return pe(ue,[{key:"cancel",value:function(je){return P(this)===!1?Promise.reject(W("cancel")):this._ownerReadableStream===void 0?Promise.reject(Se("cancel")):U(this,je)}},{key:"read",value:function(){return P(this)===!1?Promise.reject(W("read")):this._ownerReadableStream===void 0?Promise.reject(Se("read from")):Q(this)}},{key:"releaseLock",value:function(){if(P(this)===!1)throw W("releaseLock");if(this._ownerReadableStream!==void 0){if(this._readRequests.length>0)throw new TypeError("Tried to release a reader lock when that reader has pending read() calls un-settled");M(this)}}},{key:"closed",get:function(){return P(this)===!1?Promise.reject(W("closed")):this._closedPromise}}]),ue}(),bn=function(){function ue(ve){if(r(this,ue),!h(ve))throw new TypeError("ReadableStreamBYOBReader can only be constructed with a ReadableStream instance given a byte source");if(oe(ve._readableStreamController)===!1)throw new TypeError("Cannot construct a ReadableStreamBYOBReader for a stream not constructed with a byte source");if(p(ve))throw new TypeError("This stream has already been locked for exclusive reading by another reader");j(this,ve),this._readIntoRequests=[]}return pe(ue,[{key:"cancel",value:function(je){return O(this)?this._ownerReadableStream===void 0?Promise.reject(Se("cancel")):U(this,je):Promise.reject(lt("cancel"))}},{key:"read",value:function(je){return O(this)?this._ownerReadableStream===void 0?Promise.reject(Se("read from")):ArrayBuffer.isView(je)?nt(je.buffer)===!0?Promise.reject(new TypeError("Cannot read into a view onto a detached ArrayBuffer")):je.byteLength===0?Promise.reject(new TypeError("view must have non-zero byteLength")):q(this,je):Promise.reject(new TypeError("view must be an array buffer view")):Promise.reject(lt("read"))}},{key:"releaseLock",value:function(){if(!O(this))throw lt("releaseLock");if(this._ownerReadableStream!==void 0){if(this._readIntoRequests.length>0)throw new TypeError("Tried to release a reader lock when that reader has pending read() calls un-settled");M(this)}}},{key:"closed",get:function(){return O(this)?this._closedPromise:Promise.reject(lt("closed"))}}]),ue}(),Xr=function(){function ue(){throw r(this,ue),new TypeError}return pe(ue,[{key:"close",value:function(){if(Z(this)===!1)throw ut("close");if(Ne(this)===!1)throw new TypeError("The stream is not in a state that permits close");X(this)}},{key:"enqueue",value:function(je){if(Z(this)===!1)throw ut("enqueue");if(Ne(this)===!1)throw new TypeError("The stream is not in a state that permits enqueue");return he(this,je)}},{key:"error",value:function(je){if(Z(this)===!1)throw ut("error");var Xe=this._controlledReadableStream;if(Xe._state!=="readable")throw new TypeError("The stream is "+Xe._state+" and so cannot be errored");xe(this,je)}},{key:fi,value:function(je){return Tt(this),this._cancelAlgorithm(je)}},{key:Mr,value:function(){var je=this._controlledReadableStream;if(this._queue.length>0){var Xe=it(this);return this._closeRequested===!0&&this._queue.length===0?v(je):K(this),Promise.resolve(Ye(Xe,!1))}var st=m(je);return K(this),st}},{key:"desiredSize",get:function(){if(Z(this)===!1)throw ut("desiredSize");return ae(this)}}]),ue}(),os=function(){function ue(){throw r(this,ue),new TypeError("ReadableStreamBYOBRequest cannot be used directly")}return pe(ue,[{key:"respond",value:function(je){if($(this)===!1)throw le("respond");if(this._associatedReadableByteStreamController===void 0)throw new TypeError("This BYOB request has been invalidated");if(nt(this._view.buffer)===!0)throw new TypeError("The BYOB request's buffer has been detached and so cannot be used as a response");be(this._associatedReadableByteStreamController,je)}},{key:"respondWithNewView",value:function(je){if($(this)===!1)throw le("respond");if(this._associatedReadableByteStreamController===void 0)throw new TypeError("This BYOB request has been invalidated");if(!ArrayBuffer.isView(je))throw new TypeError("You can only respond with array buffer views");if(nt(je.buffer)===!0)throw new TypeError("The supplied view's buffer has been detached and so cannot be used as a response");Re(this._associatedReadableByteStreamController,je)}},{key:"view",get:function(){if($(this)===!1)throw le("view");return this._view}}]),ue}(),Zn=function(){function ue(){throw r(this,ue),new TypeError("ReadableByteStreamController constructor cannot be used directly")}return pe(ue,[{key:"close",value:function(){if(oe(this)===!1)throw C("close");if(this._closeRequested===!0)throw new TypeError("The stream has already been closed; do not close it again!");var je=this._controlledReadableByteStream._state;if(je!=="readable")throw new TypeError("The stream (in "+je+" state) is not in the readable state and cannot be closed");G(this)}},{key:"enqueue",value:function(je){if(oe(this)===!1)throw C("enqueue");if(this._closeRequested===!0)throw new TypeError("stream is closed or draining");var Xe=this._controlledReadableByteStream._state;if(Xe!=="readable")throw new TypeError("The stream (in "+Xe+" state) is not in the readable state and cannot be enqueued to");if(!ArrayBuffer.isView(je))throw new TypeError("You can only enqueue array buffer views when using a ReadableByteStreamController");if(nt(je.buffer)===!0)throw new TypeError("Cannot enqueue a view onto a detached ArrayBuffer");F(this,je)}},{key:"error",value:function(je){if(oe(this)===!1)throw C("error");var Xe=this._controlledReadableByteStream;if(Xe._state!=="readable")throw new TypeError("The stream is "+Xe._state+" and so cannot be errored");H(this,je)}},{key:fi,value:function(je){return this._pendingPullIntos.length>0&&(this._pendingPullIntos[0].bytesFilled=0),Tt(this),this._cancelAlgorithm(je)}},{key:Mr,value:function(){var je=this._controlledReadableByteStream;if(this._queueTotalSize>0){var Xe=this._queue.shift();this._queueTotalSize-=Xe.byteLength,J(this);var st=void 0;try{st=new Uint8Array(Xe.buffer,Xe.byteOffset,Xe.byteLength)}catch(lr){return Promise.reject(lr)}return Promise.resolve(Ye(st,!1))}var ht=this._autoAllocateChunkSize;if(ht!==void 0){var St=void 0;try{St=new ArrayBuffer(ht)}catch(lr){return Promise.reject(lr)}var Ht={buffer:St,byteOffset:0,byteLength:ht,bytesFilled:0,elementSize:1,ctor:Uint8Array,readerType:"default"};this._pendingPullIntos.push(Ht)}var Xt=m(je);return N(this),Xt}},{key:"byobRequest",get:function(){if(oe(this)===!1)throw C("byobRequest");if(this._byobRequest===void 0&&this._pendingPullIntos.length>0){var je=this._pendingPullIntos[0],Xe=new Uint8Array(je.buffer,je.byteOffset+je.bytesFilled,je.byteLength-je.bytesFilled),st=Object.create(os.prototype);ke(st,this,Xe),this._byobRequest=st}return this._byobRequest}},{key:"desiredSize",get:function(){if(oe(this)===!1)throw C("desiredSize");return re(this)}}]),ue}()},{"./helpers.js":10,"./queue-with-sizes.js":11,"./utils.js":14,"./writable-stream.js":15,"better-assert":16}],13:[function(u,s,n){function r($,N){if(!($ instanceof N))throw new TypeError("Cannot call a class as a function")}function a($,N,R){var T=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1,x=arguments.length>4&&arguments[4]!==void 0?arguments[4]:function(){return 1},B=arguments.length>5&&arguments[5]!==void 0?arguments[5]:0,k=arguments.length>6&&arguments[6]!==void 0?arguments[6]:function(){return 1},V=Object.create(de.prototype),J=void 0;o(V,new Promise(function(Y){J=Y}),T,x,B,k),p(V,Object.create(oe.prototype),N,R);var z=$();return J(z),V}function o($,N,R,T,x,B){function k(){return N}$._writable=Ne(k,function(J){return v($,J)},function(){return w($)},function(){return _($)},R,T),$._readable=K(k,function(){return S($)},function(J){return d($,J),Promise.resolve()},x,B),$._backpressure=void 0,$._backpressureChangePromise=void 0,$._backpressureChangePromise_resolve=void 0,h($,!0),$._transformStreamController=void 0}function l($){return!!M($)&&!!Object.prototype.hasOwnProperty.call($,"_transformStreamController")}function c($,N){E("TransformStreamError()"),$._readable._state==="readable"&&he($._readable._readableStreamController,N),d($,N)}function d($,N){ge($._writable._writableStreamController,N),$._backpressure===!0&&h($,!1)}function h($,N){E("TransformStreamSetBackpressure() [backpressure = "+N+"]"),$._backpressureChangePromise!==void 0&&$._backpressureChangePromise_resolve(),$._backpressureChangePromise=new Promise(function(R){$._backpressureChangePromise_resolve=R}),$._backpressure=N}function f($){return!!M($)&&!!Object.prototype.hasOwnProperty.call($,"_controlledTransformStream")}function p($,N,R,T){N._controlledTransformStream=$,$._transformStreamController=N,N._transformAlgorithm=R,N._flushAlgorithm=T}function y($,N){var R=Object.create(oe.prototype),T=function(V){try{return b(R,V),Promise.resolve()}catch(J){return Promise.reject(J)}},x=N.transform;if(x!==void 0){if(typeof x!="function")throw new TypeError("transform is not a method");T=function(V){return U(x,N,[V,R]).catch(function(J){throw c($,J),J})}}var B=j(N,"flush",0,[R]);p($,R,T,B)}function b($,N){E("TransformStreamDefaultControllerEnqueue()");var R=$._controlledTransformStream,T=R._readable._readableStreamController;if(ae(T)===!1)throw new TypeError("Readable side is not in a state that permits enqueue");try{X(T,N)}catch(x){throw d(R,x),R._readable._storedError}ie(T)!==R._backpressure&&h(R,!0)}function m($,N){c($._controlledTransformStream,N)}function g($){E("TransformStreamDefaultControllerTerminate()");var N=$._controlledTransformStream,R=N._readable._readableStreamController;ae(R)===!0&&fe(R),d(N,new TypeError("TransformStream terminated"))}function v($,N){E("TransformStreamDefaultSinkWriteAlgorithm()");var R=$._transformStreamController;return $._backpressure===!0?$._backpressureChangePromise.then(function(){var T=$._writable;if(T._state==="erroring")throw T._storedError;return R._transformAlgorithm(N)}):R._transformAlgorithm(N)}function _($){return c($,new TypeError("Writable side aborted")),Promise.resolve()}function w($){E("TransformStreamDefaultSinkCloseAlgorithm()");var N=$._readable;return $._transformStreamController._flushAlgorithm().then(function(){if(N._state==="errored")throw N._storedError;var R=N._readableStreamController;ae(R)===!0&&fe(R)}).catch(function(R){throw c($,R),N._storedError})}function S($){return E("TransformStreamDefaultSourcePullAlgorithm()"),h($,!1),$._backpressureChangePromise}function A($){return new TypeError("TransformStreamDefaultController.prototype."+$+" can only be used on a TransformStreamDefaultController")}function D($){return new TypeError("TransformStream.prototype."+$+" can only be used on a TransformStream")}var L=function(){function $(N,R){for(var T=0;T0&&arguments[0]!==void 0?arguments[0]:{},R=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},T=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(r(this,$),N.readableType!==void 0)throw new RangeError("Invalid readable type specified");if(N.writableType!==void 0)throw new RangeError("Invalid writable type specified");var x=R.size,B=Q(x),k=R.highWaterMark;k===void 0&&(k=1),k=q(k);var V=T.size,J=Q(V),z=T.highWaterMark;z===void 0&&(z=0),z=q(z);var Y=void 0;o(this,new Promise(function(ce){Y=ce}),k,B,z,J),y(this,N);var te=P(N,"start",[this._transformStreamController]);Y(te)}return L($,[{key:"readable",get:function(){if(l(this)===!1)throw D("readable");return this._readable}},{key:"writable",get:function(){if(l(this)===!1)throw D("writable");return this._writable}}]),$}(),oe=function(){function $(){throw r(this,$),new TypeError("TransformStreamDefaultController instances cannot be created directly")}return L($,[{key:"enqueue",value:function(R){if(f(this)===!1)throw A("enqueue");b(this,R)}},{key:"error",value:function(R){if(f(this)===!1)throw A("error");m(this,R)}},{key:"terminate",value:function(){if(f(this)===!1)throw A("terminate");g(this)}},{key:"desiredSize",get:function(){if(f(this)===!1)throw A("desiredSize");var R=this._controlledTransformStream._readable._readableStreamController;return xe(R)}}]),$}();s.exports={CreateTransformStream:a,TransformStream:de}},{"./helpers.js":10,"./readable-stream.js":12,"./writable-stream.js":15,"better-assert":16,debug:18}],14:[function(u,s,n){var r=u("better-assert");n.rethrowAssertionErrorRejection=function(a){a&&a.constructor===r.AssertionError&&setTimeout(function(){throw a},0)}},{"better-assert":16}],15:[function(u,s,n){function r(C,ee){if(!(C instanceof ee))throw new TypeError("Cannot call a class as a function")}function a(C){return new ut(C)}function o(C,ee,pe,De){var Ue=arguments.length>4&&arguments[4]!==void 0?arguments[4]:1,Fe=arguments.length>5&&arguments[5]!==void 0?arguments[5]:function(){return 1},Ye=Object.create(lt.prototype);return l(Ye),X(Ye,Object.create(le.prototype),C,ee,pe,De,Ue,Fe),Ye}function l(C){C._state="writable",C._storedError=void 0,C._writer=void 0,C._writableStreamController=void 0,C._writeRequests=[],C._inFlightWriteRequest=void 0,C._closeRequest=void 0,C._inFlightCloseRequest=void 0,C._pendingAbortRequest=void 0,C._backpressure=!1}function c(C){return!!ke(C)&&!!Object.prototype.hasOwnProperty.call(C,"_writableStreamController")}function d(C){return C._writer!==void 0}function h(C,ee){var pe=C._state;if(pe==="closed")return Promise.resolve(void 0);if(pe==="errored")return Promise.reject(C._storedError);var De=new TypeError("Requested to abort");if(C._pendingAbortRequest!==void 0)return Promise.reject(De);var Ue=!1;pe==="erroring"&&(Ue=!0,ee=void 0);var Fe=new Promise(function(Ye,Ve){C._pendingAbortRequest={_resolve:Ye,_reject:Ve,_reason:ee,_wasAlreadyErroring:Ue}});return Ue===!1&&y(C,De),Fe}function f(C){return new Promise(function(ee,pe){var De={_resolve:ee,_reject:pe};C._writeRequests.push(De)})}function p(C,ee){H("WritableStreamDealWithRejection(stream, %o)",ee),C._state!=="writable"?b(C):y(C,ee)}function y(C,ee){H("WritableStreamStartErroring(stream, %o)",ee);var pe=C._writableStreamController;C._state="erroring",C._storedError=ee;var De=C._writer;De!==void 0&&q(De,ee),S(C)===!1&&pe._started===!0&&b(C)}function b(C){H("WritableStreamFinishErroring()"),C._state="errored",C._writableStreamController[tt]();var ee=C._storedError,pe=!0,De=!1,Ue=void 0;try{for(var Fe,Ye=C._writeRequests[Symbol.iterator]();!(pe=(Fe=Ye.next()).done);pe=!0)Fe.value._reject(ee)}catch(Je){De=!0,Ue=Je}finally{try{!pe&&Ye.return&&Ye.return()}finally{if(De)throw Ue}}if(C._writeRequests=[],C._pendingAbortRequest!==void 0){var Ve=C._pendingAbortRequest;if(C._pendingAbortRequest=void 0,Ve._wasAlreadyErroring===!0)return Ve._reject(ee),void L(C);C._writableStreamController[We](Ve._reason).then(function(){Ve._resolve(),L(C)},function(Je){Ve._reject(Je),L(C)})}else L(C)}function m(C){C._inFlightWriteRequest._resolve(void 0),C._inFlightWriteRequest=void 0}function g(C,ee){C._inFlightWriteRequest._reject(ee),C._inFlightWriteRequest=void 0,p(C,ee)}function v(C){C._inFlightCloseRequest._resolve(void 0),C._inFlightCloseRequest=void 0,C._state==="erroring"&&(C._storedError=void 0,C._pendingAbortRequest!==void 0&&(C._pendingAbortRequest._resolve(),C._pendingAbortRequest=void 0)),C._state="closed";var ee=C._writer;ee!==void 0&&Y(ee)}function _(C,ee){C._inFlightCloseRequest._reject(ee),C._inFlightCloseRequest=void 0,C._pendingAbortRequest!==void 0&&(C._pendingAbortRequest._reject(ee),C._pendingAbortRequest=void 0),p(C,ee)}function w(C){return C._closeRequest!==void 0||C._inFlightCloseRequest!==void 0}function S(C){return C._inFlightWriteRequest===void 0&&C._inFlightCloseRequest===void 0?(H("WritableStreamHasOperationMarkedInFlight() is false"),!1):(H("WritableStreamHasOperationMarkedInFlight() is true"),!0)}function A(C){C._inFlightCloseRequest=C._closeRequest,C._closeRequest=void 0}function D(C){C._inFlightWriteRequest=C._writeRequests.shift()}function L(C){H("WritableStreamRejectCloseAndClosedPromiseIfNeeded()"),C._closeRequest!==void 0&&(C._closeRequest._reject(C._storedError),C._closeRequest=void 0);var ee=C._writer;ee!==void 0&&(J(ee,C._storedError),ee._closedPromise.catch(function(){}))}function E(C,ee){var pe=C._writer;pe!==void 0&&ee!==C._backpressure&&(ee===!0?Ee(pe):G(pe)),C._backpressure=ee}function O(C){return!!ke(C)&&!!Object.prototype.hasOwnProperty.call(C,"_ownerWritableStream")}function P(C,ee){return h(C._ownerWritableStream,ee)}function j(C){var ee=C._ownerWritableStream,pe=ee._state;if(pe==="closed"||pe==="errored")return Promise.reject(new TypeError("The stream (in "+pe+" state) is not in the writable state and cannot be closed"));var De=new Promise(function(Ue,Fe){var Ye={_resolve:Ue,_reject:Fe};ee._closeRequest=Ye});return ee._backpressure===!0&&pe==="writable"&&G(C),xe(ee._writableStreamController),De}function U(C){var ee=C._ownerWritableStream,pe=ee._state;return w(ee)===!0||pe==="closed"?Promise.resolve():pe==="errored"?Promise.reject(ee._storedError):j(C)}function M(C,ee){C._closedPromiseState==="pending"?J(C,ee):z(C,ee),C._closedPromise.catch(function(){})}function q(C,ee){H("WritableStreamDefaultWriterEnsureReadyPromiseRejected(writer, %o)",ee),C._readyPromiseState==="pending"?Ie(C,ee):qe(C,ee),C._readyPromise.catch(function(){})}function Q(C){var ee=C._ownerWritableStream,pe=ee._state;return pe==="errored"||pe==="erroring"?null:pe==="closed"?0:ae(ee._writableStreamController)}function Z(C){var ee=C._ownerWritableStream,pe=new TypeError("Writer was released and can no longer be used to monitor the stream's closedness");q(C,pe),M(C,pe),ee._writer=void 0,C._ownerWritableStream=void 0}function K(C,ee){var pe=C._ownerWritableStream,De=pe._writableStreamController,Ue=ie(De,ee);if(pe!==C._ownerWritableStream)return Promise.reject(x("write to"));var Fe=pe._state;if(Fe==="errored")return Promise.reject(pe._storedError);if(w(pe)===!0||Fe==="closed")return Promise.reject(new TypeError("The stream is closing or closed and cannot be written to"));if(Fe==="erroring")return Promise.reject(pe._storedError);var Ye=f(pe);return Oe(De,ee,Ue),Ye}function fe(C){return!!ke(C)&&!!Object.prototype.hasOwnProperty.call(C,"_controlledWritableStream")}function X(C,ee,pe,De,Ue,Fe,Ye,Ve){ee._controlledWritableStream=C,C._writableStreamController=ee,ee._queue=void 0,ee._queueTotalSize=void 0,$e(ee),ee._started=!1,ee._strategySizeAlgorithm=Ve,ee._strategyHWM=Ye,ee._writeAlgorithm=De,ee._closeAlgorithm=Ue,ee._abortAlgorithm=Fe;var Je=$(ee);E(C,Je);var nt=pe();Promise.resolve(nt).then(function(){ee._started=!0,Ne(ee)},function(yt){ee._started=!0,p(C,yt)}).catch(Se)}function he(C,ee,pe,De){var Ue=Object.create(le.prototype),Fe=be(ee,"write",1,[Ue]),Ye=be(ee,"close",0,[]),Ve=be(ee,"abort",1,[]);X(C,Ue,function(){return Re(ee,"start",[Ue])},Fe,Ye,Ve,pe,De)}function xe(C){Te(C,"close",0),Ne(C)}function ie(C,ee){try{return C._strategySizeAlgorithm(ee)}catch(pe){return ge(C,pe),1}}function ae(C){return C._strategyHWM-C._queueTotalSize}function Oe(C,ee,pe){var De={chunk:ee};try{Te(C,De,pe)}catch(Fe){return void ge(C,Fe)}var Ue=C._controlledWritableStream;w(Ue)===!1&&Ue._state==="writable"&&E(Ue,$(C)),Ne(C)}function Ne(C){H("WritableStreamDefaultControllerAdvanceQueueIfNeeded()");var ee=C._controlledWritableStream;if(C._started!==!1&&ee._inFlightWriteRequest===void 0){var pe=ee._state;if(pe!=="closed"&&pe!=="errored")if(pe!=="erroring"){if(C._queue.length!==0){var De=Le(C);De==="close"?de(C):oe(C,De.chunk)}}else b(ee)}}function ge(C,ee){C._controlledWritableStream._state==="writable"&&N(C,ee)}function de(C){var ee=C._controlledWritableStream;A(ee),we(C),C._closeAlgorithm().then(function(){v(ee)},function(pe){_(ee,pe)}).catch(Se)}function oe(C,ee){var pe=C._controlledWritableStream;D(pe),C._writeAlgorithm(ee).then(function(){m(pe);var De=pe._state;if(we(C),w(pe)===!1&&De==="writable"){var Ue=$(C);E(pe,Ue)}Ne(C)},function(De){g(pe,De)}).catch(Se)}function $(C){return ae(C)<=0}function N(C,ee){y(C._controlledWritableStream,ee)}function R(C){return new TypeError("WritableStream.prototype."+C+" can only be used on a WritableStream")}function T(C){return new TypeError("WritableStreamDefaultWriter.prototype."+C+" can only be used on a WritableStreamDefaultWriter")}function x(C){return new TypeError("Cannot "+C+" a stream using a released writer")}function B(C){C._closedPromise=new Promise(function(ee,pe){C._closedPromise_resolve=ee,C._closedPromise_reject=pe,C._closedPromiseState="pending"})}function k(C,ee){C._closedPromise=Promise.reject(ee),C._closedPromise_resolve=void 0,C._closedPromise_reject=void 0,C._closedPromiseState="rejected"}function V(C){C._closedPromise=Promise.resolve(void 0),C._closedPromise_resolve=void 0,C._closedPromise_reject=void 0,C._closedPromiseState="resolved"}function J(C,ee){C._closedPromise_reject(ee),C._closedPromise_resolve=void 0,C._closedPromise_reject=void 0,C._closedPromiseState="rejected"}function z(C,ee){C._closedPromise=Promise.reject(ee),C._closedPromiseState="rejected"}function Y(C){C._closedPromise_resolve(void 0),C._closedPromise_resolve=void 0,C._closedPromise_reject=void 0,C._closedPromiseState="resolved"}function te(C){H("defaultWriterReadyPromiseInitialize()"),C._readyPromise=new Promise(function(ee,pe){C._readyPromise_resolve=ee,C._readyPromise_reject=pe}),C._readyPromiseState="pending"}function ce(C,ee){H("defaultWriterReadyPromiseInitializeAsRejected(writer, %o)",ee),C._readyPromise=Promise.reject(ee),C._readyPromise_resolve=void 0,C._readyPromise_reject=void 0,C._readyPromiseState="rejected"}function Ae(C){H("defaultWriterReadyPromiseInitializeAsResolved()"),C._readyPromise=Promise.resolve(void 0),C._readyPromise_resolve=void 0,C._readyPromise_reject=void 0,C._readyPromiseState="fulfilled"}function Ie(C,ee){H("defaultWriterReadyPromiseReject(writer, %o)",ee),C._readyPromise_reject(ee),C._readyPromise_resolve=void 0,C._readyPromise_reject=void 0,C._readyPromiseState="rejected"}function Ee(C){H("defaultWriterReadyPromiseReset()"),C._readyPromise=new Promise(function(ee,pe){C._readyPromise_resolve=ee,C._readyPromise_reject=pe}),C._readyPromiseState="pending"}function qe(C,ee){H("defaultWriterReadyPromiseResetToRejected(writer, %o)",ee),C._readyPromise=Promise.reject(ee),C._readyPromiseState="rejected"}function G(C){H("defaultWriterReadyPromiseResolve()"),C._readyPromise_resolve(void 0),C._readyPromise_resolve=void 0,C._readyPromise_reject=void 0,C._readyPromiseState="fulfilled"}var F=function(){function C(ee,pe){for(var De=0;De0&&arguments[0]!==void 0?arguments[0]:{},pe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},De=pe.size,Ue=pe.highWaterMark,Fe=Ue===void 0?1:Ue;if(r(this,C),l(this),ee.type!==void 0)throw new RangeError("Invalid type is specified");var Ye=Qe(De);he(this,ee,Fe=Ce(Fe),Ye)}return F(C,[{key:"abort",value:function(pe){return c(this)===!1?Promise.reject(R("abort")):d(this)===!0?Promise.reject(new TypeError("Cannot abort a stream that already has a writer")):h(this,pe)}},{key:"getWriter",value:function(){if(c(this)===!1)throw R("getWriter");return a(this)}},{key:"locked",get:function(){if(c(this)===!1)throw R("locked");return d(this)}}]),C}();s.exports={AcquireWritableStreamDefaultWriter:a,CreateWritableStream:o,IsWritableStream:c,IsWritableStreamLocked:d,WritableStream:lt,WritableStreamAbort:h,WritableStreamDefaultControllerErrorIfNeeded:ge,WritableStreamDefaultWriterCloseWithErrorPropagation:U,WritableStreamDefaultWriterRelease:Z,WritableStreamDefaultWriterWrite:K,WritableStreamCloseQueuedOrInFlight:w};var ut=function(){function C(ee){if(r(this,C),c(ee)===!1)throw new TypeError("WritableStreamDefaultWriter can only be constructed with a WritableStream instance");if(d(ee)===!0)throw new TypeError("This stream has already been locked for exclusive writing by another writer");this._ownerWritableStream=ee,ee._writer=this;var pe=ee._state;if(pe==="writable")w(ee)===!1&&ee._backpressure===!0?te(this):Ae(this),B(this);else if(pe==="erroring")ce(this,ee._storedError),this._readyPromise.catch(function(){}),B(this);else if(pe==="closed")Ae(this),V(this);else{var De=ee._storedError;ce(this,De),this._readyPromise.catch(function(){}),k(this,De),this._closedPromise.catch(function(){})}}return F(C,[{key:"abort",value:function(pe){return O(this)===!1?Promise.reject(T("abort")):this._ownerWritableStream===void 0?Promise.reject(x("abort")):P(this,pe)}},{key:"close",value:function(){if(O(this)===!1)return Promise.reject(T("close"));var pe=this._ownerWritableStream;return pe===void 0?Promise.reject(x("close")):w(pe)===!0?Promise.reject(new TypeError("cannot close an already-closing stream")):j(this)}},{key:"releaseLock",value:function(){if(O(this)===!1)throw T("releaseLock");this._ownerWritableStream!==void 0&&Z(this)}},{key:"write",value:function(pe){return O(this)===!1?Promise.reject(T("write")):this._ownerWritableStream===void 0?Promise.reject(x("write to")):K(this,pe)}},{key:"closed",get:function(){return O(this)===!1?Promise.reject(T("closed")):this._closedPromise}},{key:"desiredSize",get:function(){if(O(this)===!1)throw T("desiredSize");if(this._ownerWritableStream===void 0)throw x("desiredSize");return Q(this)}},{key:"ready",get:function(){return O(this)===!1?Promise.reject(T("ready")):this._readyPromise}}]),C}(),le=function(){function C(){throw r(this,C),new TypeError("WritableStreamDefaultController cannot be constructed explicitly")}return F(C,[{key:"error",value:function(pe){if(fe(this)===!1)throw new TypeError("WritableStreamDefaultController.prototype.error can only be used on a WritableStreamDefaultController");this._controlledWritableStream._state==="writable"&&N(this,pe)}},{key:We,value:function(pe){return this._abortAlgorithm(pe)}},{key:tt,value:function(){$e(this)}}]),C}()},{"./helpers.js":10,"./queue-with-sizes.js":11,"./utils.js":14,"better-assert":16,debug:18}],16:[function(u,s,n){(function(r){function a(d){if(!d){var h=l(),f=h[1],p=f.getFileName(),y=f.getLineNumber(),b=(b=c.readFileSync(p,"utf8")).split(` -`)[y-1].match(/assert\((.*)\)/)[1];throw new o({message:b,stackStartFunction:h[0].getFunction()})}}var o=u("assert").AssertionError,l=u("callsite"),c=u("fs");s.exports={}.NO_ASSERT?function(){}:a}).call(this,u("_process"))},{_process:4,assert:2,callsite:17,fs:3}],17:[function(u,s,n){s.exports=function(){var r=Error.prepareStackTrace;Error.prepareStackTrace=function(l,c){return c};var a=new Error;Error.captureStackTrace(a,arguments.callee);var o=a.stack;return Error.prepareStackTrace=r,o}},{}],18:[function(u,s,n){(function(r){function a(){return!(typeof window>"u"||!window.process||window.process.type!=="renderer")||(typeof navigator>"u"||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&(typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function o(f){var p=this.useColors;if(f[0]=(p?"%c":"")+this.namespace+(p?" %c":" ")+f[0]+(p?"%c ":" ")+"+"+n.humanize(this.diff),p){var y="color: "+this.color;f.splice(1,0,y,"color: inherit");var b=0,m=0;f[0].replace(/%[a-zA-Z%]/g,function(g){g!=="%%"&&(b++,g==="%c"&&(m=b))}),f.splice(m,0,y)}}function l(){return typeof console=="object"&&console.log&&Function.prototype.apply.call(console.log,console,arguments)}function c(f){try{f==null?n.storage.removeItem("debug"):n.storage.debug=f}catch{}}function d(){var f;try{f=n.storage.debug}catch{}return!f&&typeof r<"u"&&"env"in r&&(f={}.DEBUG),f}function h(){try{return window.localStorage}catch{}}n=s.exports=u("./debug"),n.log=l,n.formatArgs=o,n.save=c,n.load=d,n.useColors=a,n.storage=typeof chrome<"u"&&chrome.storage!==void 0?chrome.storage.local:h(),n.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],n.formatters.j=function(f){try{return JSON.stringify(f)}catch(p){return"[UnexpectedJSONParseError]: "+p.message}},n.enable(d())}).call(this,u("_process"))},{"./debug":19,_process:4}],19:[function(u,s,n){function r(f){var p,y=0;for(p in f)y=(y<<5)-y+f.charCodeAt(p),y|=0;return n.colors[Math.abs(y)%n.colors.length]}function a(f){function p(){if(p.enabled){var b=p,m=+new Date,g=m-(y||m);b.diff=g,b.prev=y,b.curr=m,y=m;for(var v=new Array(arguments.length),_=0;_100)){var b=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(y);if(b){var m=parseFloat(b[1]);switch((b[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return m*p;case"days":case"day":case"d":return m*f;case"hours":case"hour":case"hrs":case"hr":case"h":return m*h;case"minutes":case"minute":case"mins":case"min":case"m":return m*d;case"seconds":case"second":case"secs":case"sec":case"s":return m*c;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return m;default:return}}}}function a(y){return y>=f?Math.round(y/f)+"d":y>=h?Math.round(y/h)+"h":y>=d?Math.round(y/d)+"m":y>=c?Math.round(y/c)+"s":y+"ms"}function o(y){return l(y,f,"day")||l(y,h,"hour")||l(y,d,"minute")||l(y,c,"second")||y+" ms"}function l(y,b,m){if(!(y0)return r(y);if(m==="number"&&isNaN(y)===!1)return b.long?o(y):a(y);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(y))}},{}]},{},[1])(1)})}(g2)),g2.exports}var m2,M4;function e7(){if(M4)return m2;M4=1;const t=e=>e!==null&&typeof e=="object"&&typeof e.pipe=="function";return t.writable=e=>t(e)&&e.writable!==!1&&typeof e._write=="function"&&typeof e._writableState=="object",t.readable=e=>t(e)&&e.readable!==!1&&typeof e._read=="function"&&typeof e._readableState=="object",t.duplex=e=>t.writable(e)&&t.readable(e),t.transform=e=>t.duplex(e)&&typeof e._transform=="function",m2=t,m2}var _2={exports:{}},F4;function FX(){return F4||(F4=1,function(t){t.exports=e,t.exports.WEBSTREAM_SUPPORT=typeof ReadableStream<"u";function e(u){if(!t.exports.WEBSTREAM_SUPPORT)throw new Error("No web ReadableStream support");var s=!1,n={};function r(l){n.data=d,n.end=d,n.end=h,n.close=h,n.error=h;for(var c in n)u.on(c,n[c]);u.pause();function d(f){s||(l.enqueue(f),u.pause())}function h(f){if(!s){s=!0;for(var p in n)u.removeListener(p,n[p]);f?l.error(f):l.close()}}}function a(){s||u.resume()}function o(){s=!0;for(var l in n)u.removeListener(l,n[l]);u.push(null),u.pause(),u.destroy?u.destroy():u.close&&u.close()}return new ReadableStream({start:r,pull:a,cancel:o})}}(_2)),_2.exports}var q4;function t7(){if(q4)return wd;q4=1,Object.defineProperty(wd,"__esModule",{value:!0}),wd.ActorHttp=void 0;const t=ot,e=LX();globalThis.ReadableStream||(globalThis.ReadableStream=MX().ReadableStream);const u=e7(),s=FX();let n=class extends t.Actor{constructor(a){super(a)}static toNodeReadable(a){return u(a)||a===null?a:(0,e.readableFromWeb)(a)}static toWebReadableStream(a){return s(a)}static headersToHash(a){const o={};return a.forEach((l,c)=>{o[c]=l}),o}};return wd.ActorHttp=n,wd}var Sd={},B4;function qX(){if(B4)return Sd;B4=1,Object.defineProperty(Sd,"__esModule",{value:!0}),Sd.validateAndCloseHttpResponse=void 0;const t=eo(),e=t7();async function u(s,n){var r;if(n.status>=400){let a="empty response";if(n.body){const o=e.ActorHttp.toNodeReadable(n.body);a=await t(o)}throw new Error(`Could not update ${s} (HTTP status ${n.status}): -${a}`)}await((r=n.body)==null?void 0:r.cancel())}return Sd.validateAndCloseHttpResponse=u,Sd}var U4;function rs(){return U4||(U4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(t7(),t),u(qX(),t)}(y2)),y2}var H4={},$4;function r7(){return $4||($4=1,function(t){(function(e){var u=typeof globalThis<"u"&&globalThis||typeof t<"u"&&t||typeof u<"u"&&u,s={searchParams:"URLSearchParams"in u,iterable:"Symbol"in u&&"iterator"in Symbol,blob:"FileReader"in u&&"Blob"in u&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in u,arrayBuffer:"ArrayBuffer"in u};function n(O){return O&&DataView.prototype.isPrototypeOf(O)}if(s.arrayBuffer)var r=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],a=ArrayBuffer.isView||function(O){return O&&r.indexOf(Object.prototype.toString.call(O))>-1};function o(O){if(typeof O!="string"&&(O=String(O)),/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(O)||O==="")throw new TypeError('Invalid character in header field name: "'+O+'"');return O.toLowerCase()}function l(O){return typeof O!="string"&&(O=String(O)),O}function c(O){var P={next:function(){var j=O.shift();return{done:j===void 0,value:j}}};return s.iterable&&(P[Symbol.iterator]=function(){return P}),P}function d(O){this.map={},O instanceof d?O.forEach(function(P,j){this.append(j,P)},this):Array.isArray(O)?O.forEach(function(P){this.append(P[0],P[1])},this):O&&Object.getOwnPropertyNames(O).forEach(function(P){this.append(P,O[P])},this)}d.prototype.append=function(O,P){O=o(O),P=l(P);var j=this.map[O];this.map[O]=j?j+", "+P:P},d.prototype.delete=function(O){delete this.map[o(O)]},d.prototype.get=function(O){return O=o(O),this.has(O)?this.map[O]:null},d.prototype.has=function(O){return this.map.hasOwnProperty(o(O))},d.prototype.set=function(O,P){this.map[o(O)]=l(P)},d.prototype.forEach=function(O,P){for(var j in this.map)this.map.hasOwnProperty(j)&&O.call(P,this.map[j],j,this)},d.prototype.keys=function(){var O=[];return this.forEach(function(P,j){O.push(j)}),c(O)},d.prototype.values=function(){var O=[];return this.forEach(function(P){O.push(P)}),c(O)},d.prototype.entries=function(){var O=[];return this.forEach(function(P,j){O.push([j,P])}),c(O)},s.iterable&&(d.prototype[Symbol.iterator]=d.prototype.entries);function h(O){if(O.bodyUsed)return Promise.reject(new TypeError("Already read"));O.bodyUsed=!0}function f(O){return new Promise(function(P,j){O.onload=function(){P(O.result)},O.onerror=function(){j(O.error)}})}function p(O){var P=new FileReader,j=f(P);return P.readAsArrayBuffer(O),j}function y(O){var P=new FileReader,j=f(P);return P.readAsText(O),j}function b(O){for(var P=new Uint8Array(O),j=new Array(P.length),U=0;U-1?P:O}function w(O,P){if(!(this instanceof w))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');P=P||{};var j=P.body;if(O instanceof w){if(O.bodyUsed)throw new TypeError("Already read");this.url=O.url,this.credentials=O.credentials,P.headers||(this.headers=new d(O.headers)),this.method=O.method,this.mode=O.mode,this.signal=O.signal,!j&&O._bodyInit!=null&&(j=O._bodyInit,O.bodyUsed=!0)}else this.url=String(O);if(this.credentials=P.credentials||this.credentials||"same-origin",(P.headers||!this.headers)&&(this.headers=new d(P.headers)),this.method=_(P.method||this.method||"GET"),this.mode=P.mode||this.mode||null,this.signal=P.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&j)throw new TypeError("Body not allowed for GET or HEAD requests");if(this._initBody(j),(this.method==="GET"||this.method==="HEAD")&&(P.cache==="no-store"||P.cache==="no-cache")){var U=/([?&])_=[^&]*/;if(U.test(this.url))this.url=this.url.replace(U,"$1_="+new Date().getTime());else{var M=/\?/;this.url+=(M.test(this.url)?"&":"?")+"_="+new Date().getTime()}}}w.prototype.clone=function(){return new w(this,{body:this._bodyInit})};function S(O){var P=new FormData;return O.trim().split("&").forEach(function(j){if(j){var U=j.split("="),M=U.shift().replace(/\+/g," "),q=U.join("=").replace(/\+/g," ");P.append(decodeURIComponent(M),decodeURIComponent(q))}}),P}function A(O){var P=new d,j=O.replace(/\r?\n[\t ]+/g," ");return j.split("\r").map(function(U){return U.indexOf(` -`)===0?U.substr(1,U.length):U}).forEach(function(U){var M=U.split(":"),q=M.shift().trim();if(q){var Q=M.join(":").trim();P.append(q,Q)}}),P}g.call(w.prototype);function D(O,P){if(!(this instanceof D))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');P||(P={}),this.type="default",this.status=P.status===void 0?200:P.status,this.ok=this.status>=200&&this.status<300,this.statusText=P.statusText===void 0?"":""+P.statusText,this.headers=new d(P.headers),this.url=P.url||"",this._initBody(O)}g.call(D.prototype),D.prototype.clone=function(){return new D(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new d(this.headers),url:this.url})},D.error=function(){var O=new D(null,{status:0,statusText:""});return O.type="error",O};var L=[301,302,303,307,308];D.redirect=function(O,P){if(L.indexOf(P)===-1)throw new RangeError("Invalid status code");return new D(null,{status:P,headers:{location:O}})},e.DOMException=u.DOMException;try{new e.DOMException}catch{e.DOMException=function(P,j){this.message=P,this.name=j;var U=Error(P);this.stack=U.stack},e.DOMException.prototype=Object.create(Error.prototype),e.DOMException.prototype.constructor=e.DOMException}function E(O,P){return new Promise(function(j,U){var M=new w(O,P);if(M.signal&&M.signal.aborted)return U(new e.DOMException("Aborted","AbortError"));var q=new XMLHttpRequest;function Q(){q.abort()}q.onload=function(){var K={status:q.status,statusText:q.statusText,headers:A(q.getAllResponseHeaders()||"")};K.url="responseURL"in q?q.responseURL:K.headers.get("X-Request-URL");var fe="response"in q?q.response:q.responseText;setTimeout(function(){j(new D(fe,K))},0)},q.onerror=function(){setTimeout(function(){U(new TypeError("Network request failed"))},0)},q.ontimeout=function(){setTimeout(function(){U(new TypeError("Network request failed"))},0)},q.onabort=function(){setTimeout(function(){U(new e.DOMException("Aborted","AbortError"))},0)};function Z(K){try{return K===""&&u.location.href?u.location.href:K}catch{return K}}q.open(M.method,Z(M.url),!0),M.credentials==="include"?q.withCredentials=!0:M.credentials==="omit"&&(q.withCredentials=!1),"responseType"in q&&(s.blob?q.responseType="blob":s.arrayBuffer&&M.headers.get("Content-Type")&&M.headers.get("Content-Type").indexOf("application/octet-stream")!==-1&&(q.responseType="arraybuffer")),P&&typeof P.headers=="object"&&!(P.headers instanceof d)?Object.getOwnPropertyNames(P.headers).forEach(function(K){q.setRequestHeader(K,l(P.headers[K]))}):M.headers.forEach(function(K,fe){q.setRequestHeader(fe,K)}),M.signal&&(M.signal.addEventListener("abort",Q),q.onreadystatechange=function(){q.readyState===4&&M.signal.removeEventListener("abort",Q)}),q.send(typeof M._bodyInit>"u"?null:M._bodyInit)})}return E.polyfill=!0,u.fetch||(u.fetch=E,u.Headers=d,u.Request=w,u.Response=D),e.Headers=d,e.Request=w,e.Response=D,e.fetch=E,e})({})}(typeof self<"u"?self:I)),H4}var Td={},Q4;function BX(){if(Q4)return Td;Q4=1,Object.defineProperty(Td,"__esModule",{value:!0}),Td.FetchInitPreprocessor=void 0;const t=rs();class e{async handle(s){if(s.headers){const n=new Headers(s.headers);n.has("user-agent")&&n.delete("user-agent"),s.headers=n}if(s!=null&&s.headers&&"append"in s.headers&&(s.headers=t.ActorHttp.headersToHash(s.headers)),s.body&&typeof s.body!="string"&&"getReader"in s.body){const n=s.body.getReader(),r=[];for(;;){const{done:a,value:o}=await n.read();if(a)break;r.push(o)}s.body=r.join("")}return{keepalive:!s.body,...s}}async createAbortController(){return new AbortController}}return Td.FetchInitPreprocessor=e,Td}var V4;function UX(){if(V4)return vd;V4=1,Object.defineProperty(vd,"__esModule",{value:!0}),vd.ActorHttpFetch=void 0;const t=rs(),e=Lt;r7();const u=BX();let s=class o3 extends t.ActorHttp{constructor(r){super(r),this.userAgent=o3.createUserAgent(),this.fetchInitPreprocessor=new u.FetchInitPreprocessor(r.agentOptions)}static createUserAgent(){return`Comunica/actor-http-fetch (${typeof globalThis.navigator>"u"?`Node.js ${process.version}; ${process.platform}`:`Browser-${globalThis.navigator.userAgent}`})`}async test(r){return{time:Number.POSITIVE_INFINITY}}static async getResponse(r,a,o,l,c,d){var p;let h,f=l+1;for(;f-- >0;)try{const y=await r(a,o);if(d&&y.status>=500&&y.status<600)throw new Error(`Server replied with response code ${y.status}: ${y.statusText}`);return y}catch(y){if(h=y,(p=o.signal)!=null&&p.aborted)throw y;f>0&&await new Promise((b,m)=>{var g;setTimeout(b,c),(g=o.signal)==null||g.addEventListener("abort",()=>{m(new Error("Fetch aborted by timeout."))})})}throw l>0?new Error(`Number of fetch retries (${l}) exceeded. Last error: ${String(h)}`):h}async run(r){var f,p,y,b,m,g,v,_;const a=((f=r.init)==null?void 0:f.headers)??{};r.init=r.init??{},r.init.headers=new Headers(a),r.init.headers.has("user-agent")||r.init.headers.append("user-agent",this.userAgent);const o=r.context.get(e.KeysHttp.auth);o&&r.init.headers.append("Authorization",`Basic ${Buffer.from(o).toString("base64")}`),this.logInfo(r.context,`Requesting ${typeof r.input=="string"?r.input:r.input.url}`,()=>({headers:t.ActorHttp.headersToHash(new Headers(r.init.headers)),method:r.init.method??"GET"})),(p=r.init)!=null&&p.headers&&"append"in r.init.headers&&r.context.has(e.KeysHttp.fetch)&&(r.init.headers=t.ActorHttp.headersToHash(r.init.headers));let l={...r.init};r.context.get(e.KeysHttp.includeCredentials)&&(l.credentials="include");const c=(y=r.context)==null?void 0:y.get(e.KeysHttp.httpTimeout);let d,h;if(c!==void 0){const w=await this.fetchInitPreprocessor.createAbortController();l.signal=w.signal,h=()=>w.abort(),d=setTimeout(()=>h(),c)}try{l=await this.fetchInitPreprocessor.handle(l);const w=((b=r.context)==null?void 0:b.get(e.KeysHttp.httpRetryCount))??0,S=((m=r.context)==null?void 0:m.get(e.KeysHttp.httpRetryDelay))??0,A=((g=r.context)==null?void 0:g.get(e.KeysHttp.httpRetryOnServerError))??!1,D=(v=r.context)==null?void 0:v.get(e.KeysHttp.fetch),L=await o3.getResponse(D??fetch,r.input,l,w,S,A);return d!==void 0&&((((_=r.context)==null?void 0:_.get(e.KeysHttp.httpBodyTimeout))||!1)&&L.body?(h=()=>{var O;return(O=L.body)==null?void 0:O.cancel(new Error(`HTTP timeout when reading the body of ${L.url}. -This error can be disabled by modifying the 'httpBodyTimeout' and/or 'httpTimeout' options.`))},L.body.on("close",()=>{clearTimeout(d)})):clearTimeout(d)),L.body&&!L.body.cancel&&(L.body.cancel=async E=>{L.body.destroy(E),d!==void 0&&clearTimeout(d)}),L}catch(w){throw d!==void 0&&clearTimeout(d),w}}};return vd.ActorHttpFetch=s,vd}var k4;function HX(){return k4||(k4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(UX(),t)}(p2)),p2}var v2={},Ad={},z4;function $X(){if(z4)return Ad;z4=1,Object.defineProperty(Ad,"__esModule",{value:!0}),Ad.ActorQueryOperationSource=void 0;const t=wt(),e=Lt,u=jn(),s=Ot();let n=class extends t.ActorQueryOperation{constructor(a){super(a)}async test(a){if(!t.ActorQueryOperation.getOperationSource(a.operation))throw new Error(`Actor ${this.name} requires an operation with source annotation.`);return{httpRequests:1}}async run(a){const o=a.context.get(e.KeysInitQuery.physicalQueryPlanLogger);o&&(o.logOperation(a.operation.type,void 0,a.operation,a.context.get(e.KeysInitQuery.physicalQueryPlanNode),this.name,{}),a.context=a.context.set(e.KeysInitQuery.physicalQueryPlanNode,a.operation));const l=t.ActorQueryOperation.getOperationSource(a.operation),c=l.context?a.context.merge(l.context):a.context;let d=!1;if(s.Util.recurseOperation(a.operation,{construct(){return d=!0,!1}}),d){const p=l.source.queryQuads(a.operation,c),y=(0,u.getMetadataQuads)(p);return{type:"quads",quadStream:p,metadata:y}}switch(a.operation.type){case s.Algebra.types.ASK:return{type:"boolean",execute:()=>l.source.queryBoolean(a.operation,c)};case s.Algebra.types.COMPOSITE_UPDATE:case s.Algebra.types.DELETE_INSERT:case s.Algebra.types.LOAD:case s.Algebra.types.CLEAR:case s.Algebra.types.CREATE:case s.Algebra.types.DROP:case s.Algebra.types.ADD:case s.Algebra.types.MOVE:case s.Algebra.types.COPY:return{type:"void",execute:()=>l.source.queryVoid(a.operation,c)}}const h=l.source.queryBindings(a.operation,c),f=(0,u.getMetadataBindings)(h);return{type:"bindings",bindingsStream:h,metadata:f}}};return Ad.ActorQueryOperationSource=n,Ad}var G4;function QX(){return G4||(G4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u($X(),t)}(v2)),v2}var w2={},Ed={},W4;function VX(){if(W4)return Ed;W4=1,Object.defineProperty(Ed,"__esModule",{value:!0}),Ed.MediatorJoinCoefficientsFixed=void 0;const t=Lt,e=ot;let u=class extends e.Mediator{constructor(n){super(n)}async mediateWith(n,r){var b;const a=[],o=r.map(({reply:m})=>m).map(m=>m.catch(g=>{a.push(g)})),l=await Promise.all(o);let c=l.map(m=>{if(m)return m.iterations*this.cpuWeight+m.persistedItems*this.memoryWeight+m.blockingItems*this.timeWeight+m.requestTime*this.ioWeight});const d=Math.max(...c.filter(m=>m!==void 0)),h=n.context.get(t.KeysQueryOperation.limitIndicator);h&&(c=c.map((m,g)=>m!==void 0&&l[g].persistedItems>0&&l[g].iterations>h?m+d:m));let f=-1,p=Number.POSITIVE_INFINITY;for(const[m,g]of c.entries())g!==void 0&&(f===-1||gm.message).join(` -`)}`);const y=r[f].actor;return y.includeInLogs&&((b=e.Actor.getContextLogger(n.context))==null||b.debug(`Determined physical join operator '${y.logicalType}-${y.physicalName}'`,{entries:n.entries.length,variables:await Promise.all(n.entries.map(async m=>(await m.output.metadata()).variables.map(g=>g.value))),costs:Object.fromEntries(c.map((m,g)=>[`${r[g].actor.logicalType}-${r[g].actor.physicalName}`,m]).filter(m=>m[1]!==void 0)),coefficients:Object.fromEntries(l.map((m,g)=>[`${r[g].actor.logicalType}-${r[g].actor.physicalName}`,m]).filter(m=>m[1]!==void 0))})),y}};return Ed.MediatorJoinCoefficientsFixed=u,Ed}var J4;function kX(){return J4||(J4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(VX(),t)}(w2)),w2}var S2={},Od={},X4;function n7(){if(X4)return Od;X4=1,Object.defineProperty(Od,"__esModule",{value:!0}),Od.ActorHttpInvalidate=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return Od.ActorHttpInvalidate=e,Od}var Rd={},K4;function zX(){if(K4)return Rd;K4=1,Object.defineProperty(Rd,"__esModule",{value:!0}),Rd.ActorHttpInvalidateListenable=void 0;const t=n7();let e=class extends t.ActorHttpInvalidate{constructor(s){super(s),this.invalidateListeners=[],this.invalidateListeners=[]}addInvalidateListener(s){this.invalidateListeners.push(s)}async test(s){return!0}async run(s){for(const n of this.invalidateListeners)n(s);return{}}};return Rd.ActorHttpInvalidateListenable=e,Rd}var Y4;function T1(){return Y4||(Y4=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(n7(),t),u(zX(),t)}(S2)),S2}var T2={},xd={},Z4;function GX(){if(Z4)return xd;Z4=1,Object.defineProperty(xd,"__esModule",{value:!0}),xd.MediatorAll=void 0;const t=ot;let e=class extends t.Mediator{constructor(s){super(s)}async mediate(s){const n=[];let r;try{r=this.publish(s)}catch{r=[]}for(const o of r)try{await o.reply,n.push(o.actor)}catch{}return(await Promise.all(n.map(o=>o.runObservable(s))))[0]}async mediateWith(){throw new Error("Unsupported operation: MediatorAll#mediateWith")}};return xd.MediatorAll=e,xd}var e6;function WX(){return e6||(e6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(GX(),t)}(T2)),T2}var A2={},Id={},E2={},Pd={},Dd={},t6;function JX(){if(t6)return Dd;t6=1,Object.defineProperty(Dd,"__esModule",{value:!0}),Dd.instrumentIterator=void 0;function t(u){const s={count:0,timeSelf:0,timeLife:0};return e(u,s,!0),new Promise(n=>{u.on("end",()=>{n(s)})})}Dd.instrumentIterator=t;function e(u,s,n){if(!("_profileInstrumented"in u)){if(u._profileInstrumented=!0,"_read"in u){const r=u._read;u._read=(a,o)=>{const l=performance.now();r.call(u,a,()=>{s.timeSelf+=performance.now()-l,o()})}}if("read"in u){const r=u.read;u.read=()=>{const a=performance.now(),o=r.call(u);return n&&o&&s.count++,s.timeSelf+=performance.now()-a,o}}if(n){const r=performance.now();u.on("end",()=>{s.timeLife=performance.now()-r})}"_source"in u&&e(u._source,s,!1)}}return Dd}var r6;function XX(){if(r6)return Pd;r6=1,Object.defineProperty(Pd,"__esModule",{value:!0}),Pd.ActorRdfJoin=void 0;const t=Lt,e=ot,u=jn(),s=Et(),n=er(),r=JX(),a=new s.DataFactory;let o=class Cs extends e.Actor{constructor(c,d){super(c),this.includeInLogs=!0,this.logicalType=d.logicalType,this.physicalName=d.physicalName,this.limitEntries=d.limitEntries??Number.POSITIVE_INFINITY,this.limitEntriesMin=d.limitEntriesMin??!1,this.canHandleUndefs=d.canHandleUndefs??!1,this.isLeaf=d.isLeaf??!0}static hash(c,d){return d.map(h=>{const f=c.get(h);return f?f.value:""}).join("")}static hashNonClashing(c,d){return d.map(h=>{const f=c.get(h);return f?(0,n.termToString)(f):""}).join("")}static overlappingVariables(c){const d=c.map(f=>f.variables);let h=d[0];for(const f of d.slice(1))h=h.filter(p=>f.some(y=>y.value===p.value));return h}static joinVariables(c){return[...new Set(c.flatMap(d=>d.variables.map(h=>h.value)))].map(d=>a.variable(d))}static joinBindings(...c){if(c.length===0)return null;if(c.length===1)return c[0];let d=c[0];for(const h of c.slice(1)){const f=d.merge(h);if(!f)return null;d=f}return d}static getCardinality(c){return c.cardinality}static async getMetadatas(c){return await Promise.all(c.map(d=>d.output.metadata()))}static async getEntriesWithMetadatas(c){const d=await Cs.getMetadatas(c);return c.map((h,f)=>({...h,metadata:d[f]}))}static getRequestInitialTimes(c){return c.map(d=>d.pageSize?0:d.requestTime??0)}static getRequestItemTimes(c){return c.map(d=>d.pageSize?(d.requestTime??0)/d.pageSize:0)}constructState(c){const d=new u.MetadataValidationState,h=()=>d.invalidate();for(const f of c)f.state.addInvalidateListener(h);return d}async constructResultMetadata(c,d,h,f={}){let p;return f.cardinality?p=f.cardinality:(p=d.reduce((y,b)=>{const m=Cs.getCardinality(b);return{type:m.type==="estimate"?"estimate":y.type,value:y.value*m.value}},{type:"exact",value:1}),p.value*=(await this.mediatorJoinSelectivity.mediate({entries:c,context:h})).selectivity),{state:this.constructState(d),...f,cardinality:{type:p.type,value:p.value},canContainUndefs:f.canContainUndefs??d.some(y=>y.canContainUndefs),variables:Cs.joinVariables(d)}}static async sortJoinEntries(c,d,h){if(d.some(m=>m.metadata.canContainUndefs))return d;const p={};for(const m of d)for(const g of m.metadata.variables){let v=p[g.value];v||(v=0),p[g.value]=++v}const y=[];for(const[m,g]of Object.entries(p))g>=2&&y.push(m);if(y.length===0)throw new Error("Bind join can only join entries with at least one common variable");const b=[];for(const m of d){let g=!1;for(const v of m.metadata.variables)if(y.includes(v.value)){g=!0;break}g||b.push(m)}return(await c.mediate({entries:d,context:h})).entries.sort((m,g)=>{const v=b.includes(m),_=b.includes(g);return v===_?0:v?1:-1})}async test(c){if(c.type!==this.logicalType)throw new Error(`${this.name} can only handle logical joins of type '${this.logicalType}', while '${c.type}' was given.`);if(c.entries.length<=1)throw new Error(`${this.name} requires at least two join entries.`);if(this.limitEntriesMin?c.entries.lengththis.limitEntries)throw new Error(`${this.name} requires ${this.limitEntries} join entries at ${this.limitEntriesMin?"least":"most"}. The input contained ${c.entries.length}.`);for(const h of c.entries)if(h.output.type!=="bindings")throw new Error(`Invalid type of a join entry: Expected 'bindings' but got '${h.output.type}'`);const d=await Cs.getMetadatas(c.entries);if(!this.canHandleUndefs){for(const h of d)if(h.canContainUndefs)throw new Error(`Actor ${this.name} can not join streams containing undefs`)}return await this.getJoinCoefficients(c,d)}async run(c){let d;c.context.has(t.KeysInitQuery.physicalQueryPlanLogger)&&(d=c.context.get(t.KeysInitQuery.physicalQueryPlanNode),c.context=c.context.set(t.KeysInitQuery.physicalQueryPlanNode,c));const h=c.context.get(t.KeysInitQuery.physicalQueryPlanLogger);let f;this.includeInLogs&&h&&(f={},h.stashChildren(d,m=>m.logicalOperator.startsWith("join")),h.logOperation(`join-${this.logicalType}`,this.physicalName,c,d,this.name,f));const{result:p,physicalPlanMetadata:y}=await this.getOutput(c),b=await Cs.getMetadatas(c.entries);if(f){(0,r.instrumentIterator)(p.bindingsStream).then(g=>{h.appendMetadata(c,{cardinalityReal:g.count,timeSelf:g.timeSelf,timeLife:g.timeLife})}),Object.assign(f,y);const m=b.map(Cs.getCardinality);if(f.cardinalities=m,f.joinCoefficients=await this.getJoinCoefficients(c,b),this.isLeaf)for(let g=0;g=this.blockSize&&r(this.consumeChunkAsIterator()),n()}_flush(s){this.chunk.length>0&&this._push(this.consumeChunkAsIterator()),super._flush(s)}};return Nd.ChunkedIterator=e,Nd}var i6;function Ln(){return i6||(i6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(XX(),t),u(KX(),t)}(E2)),E2}var a6;function YX(){if(a6)return Id;a6=1,Object.defineProperty(Id,"__esModule",{value:!0}),Id.ActorRdfJoinSingle=void 0;const t=Ln();let e=class extends t.ActorRdfJoin{constructor(s){super(s,{logicalType:"inner",physicalName:"single",limitEntries:1}),this.includeInLogs=!1}async test(s){if(s.entries.length!==1)throw new Error(`Actor ${this.name} can only join a single entry`);return await this.getJoinCoefficients()}async getOutput(s){return{result:s.entries[0].output}}async getJoinCoefficients(){return{iterations:0,persistedItems:0,blockingItems:0,requestTime:0}}};return Id.ActorRdfJoinSingle=e,Id}var s6;function ZX(){return s6||(s6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(YX(),t)}(A2)),A2}var O2={},Cd={},o6;function eK(){if(o6)return Cd;o6=1,Object.defineProperty(Cd,"__esModule",{value:!0}),Cd.ActorRdfJoinMultiEmpty=void 0;const t=Ln(),e=jn(),u=Nt();let s=class extends t.ActorRdfJoin{constructor(r){super(r,{logicalType:"inner",physicalName:"multi-empty",canHandleUndefs:!0})}async test(r){if((await t.ActorRdfJoin.getMetadatas(r.entries)).every(a=>t.ActorRdfJoin.getCardinality(a).value>0))throw new Error(`Actor ${this.name} can only join entries where at least one is empty`);return super.test(r)}async getOutput(r){for(const a of r.entries)a.output.bindingsStream.close();return{result:{bindingsStream:new u.ArrayIterator([],{autoStart:!1}),metadata:async()=>({state:new e.MetadataValidationState,cardinality:{type:"exact",value:0},canContainUndefs:!1,variables:t.ActorRdfJoin.joinVariables(await t.ActorRdfJoin.getMetadatas(r.entries))}),type:"bindings"}}}async getJoinCoefficients(r,a){return{iterations:0,persistedItems:0,blockingItems:0,requestTime:0}}};return Cd.ActorRdfJoinMultiEmpty=s,Cd}var u6;function tK(){return u6||(u6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(eK(),t)}(O2)),O2}var R2={},jd={},c6;function rK(){if(c6)return jd;c6=1,Object.defineProperty(jd,"__esModule",{value:!0}),jd.ActorRdfJoinMultiBindSource=void 0;const t=wt(),e=Ln(),u=Nt(),s=Ot(),n=new s.Factory;let r=class extends e.ActorRdfJoin{constructor(o){super(o,{logicalType:"inner",physicalName:"bind-source",canHandleUndefs:!0})}async getOutput(o){const l=await e.ActorRdfJoin.getEntriesWithMetadatas(o.entries),c=await this.sortJoinEntries(l,o.context);this.logDebug(o.context,"First entry for Bind Join Source: ",()=>({entry:c[0].operation,metadata:c[0].metadata}));for(const[g,v]of c.entries())g!==0&&v.output.bindingsStream.close();const d=c[0].output,h=c[0].metadata,f=[...c];f.splice(0,1);const p=t.ActorQueryOperation.getOperationSource(f[0].operation),y=this.createOperationFromEntries(f),b=new e.ChunkedIterator(d.bindingsStream,this.blockSize,{autoStart:!1});return{result:{type:"bindings",bindingsStream:new u.UnionIterator(b.map(g=>p.source.queryBindings(y,p.context?o.context.merge(p.context):o.context,{joinBindings:{bindings:g,metadata:h}}))),metadata:()=>this.constructResultMetadata(c,c.map(g=>g.metadata),o.context)},physicalPlanMetadata:{bindIndex:l.indexOf(c[0])}}}async sortJoinEntries(o,l){return o=await e.ActorRdfJoin.sortJoinEntries(this.mediatorJoinEntriesSort,o,l),o=o.sort((c,d)=>c.operationModified&&!d.operationModified?-1:0),o}async getJoinCoefficients(o,l){const c=await this.sortJoinEntries(o.entries.map((_,w)=>({..._,metadata:l[w]})),o.context);l=c.map(_=>_.metadata);const d=e.ActorRdfJoin.getRequestInitialTimes(l),h=e.ActorRdfJoin.getRequestItemTimes(l),f=[...c];[...d],[...h],f.splice(0,1);const p=f.map(_=>t.ActorQueryOperation.getOperationSource(_.operation));if(p.some(_=>!_))throw new Error(`Actor ${this.name} can not bind on remaining operations without source annotation`);if(p.some(_=>_!==p[0]))throw new Error(`Actor ${this.name} can not bind on remaining operations with non-equal source annotation`);const y=p[0],b=this.createOperationFromEntries(f),m=await y.source.getSelectorShape(o.context);if(!t.ActorQueryOperation.doesShapeAcceptOperation(m,b,{joinBindings:!0}))throw new Error(`Actor ${this.name} detected a source that can not handle passing down join bindings`);const g=await Promise.all(f.map(async _=>(await this.mediatorJoinSelectivity.mediate({entries:[c[0],_],context:o.context})).selectivity*this.selectivityModifier)),v=f.map((_,w)=>_.metadata.cardinality.value*g[w]).reduce((_,w)=>_+w,0);return{iterations:1,persistedItems:l[0].cardinality.value,blockingItems:l[0].cardinality.value,requestTime:d[0]+l[0].cardinality.value*h[0]+d[1]+v*h[1]}}createOperationFromEntries(o){return o.length===1?o[0].operation:n.createJoin(o.map(l=>l.operation),!0)}};return jd.ActorRdfJoinMultiBindSource=r,jd}var l6;function nK(){return l6||(l6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(rK(),t)}(R2)),R2}var x2={},Ld={},I2,d6;function iK(){if(d6)return I2;d6=1;let t=Nt(),e=t.MultiTransformIterator,u=t.SimpleTransformIterator;class s extends e{constructor(r,a,o,l){super(r,l),this.funRight=a,this.funJoin=o}_createTransformer(r){return new u(this.funRight(r),{transform:(a,o,l)=>{let c=this.funJoin(r,a);c!==null&&l(c),o()}})}}return I2=s,I2}var P2,f6;function aK(){if(f6)return P2;f6=1;let t=Nt().AsyncIterator;class e extends t{constructor(s,n,r,a){super(),this.addedDataListener=!1,this.left=s,this.right=n,this.funHash=r,this.funJoin=a,this.leftMap=new Map,this.match=null,this.matches=[],this.matchIdx=0,this.left.on("error",l=>this.destroy(l)),this.right.on("error",l=>this.destroy(l)),this.readable=!1,this.left.on("end",o.bind(this));function o(){this.readable=!0,this.right.on("readable",()=>this.readable=!0),this.right.on("end",()=>{this.hasResults()||this._end()})}this.on("newListener",l=>{l==="data"&&this._addDataListenerIfNeeded()}),this.left.readable&&this._addDataListenerIfNeeded(),this.left.on("readable",()=>this._addDataListenerIfNeeded())}hasResults(){return!this.right.ended||this.matchIdxthis.right.close())}_end(){super._end(),u(()=>this.right.destroy())}_createTransformer(r){return new e(this.right.clone(),{transform:(a,o,l)=>{let c=this.funJoin(r,a);c!==null&&l(c),o()}})}}return D2=s,D2}var N2,p6;function oK(){if(p6)return N2;p6=1;let t=Nt().AsyncIterator;class e extends t{constructor(s,n,r,a){super(),this.left=s,this.right=n,this.funHash=r,this.funJoin=a,this.usedLeft=!1,this.leftMap=new Map,this.rightMap=new Map,this.on("end",()=>this._cleanup()),this.match=null,this.matches=[],this.matchIdx=0,(this.left.readable||this.right.readable)&&(this.readable=!0),this.left.on("error",o=>this.destroy(o)),this.right.on("error",o=>this.destroy(o)),this.left.on("readable",()=>this.readable=!0),this.right.on("readable",()=>this.readable=!0),this.left.on("end",()=>{this.hasResults()||this._end()}),this.right.on("end",()=>{this.hasResults()||this._end()})}hasResults(){return!this.left.ended||!this.right.ended||!!this.matches&&this.matchIdxthis.emit("readable")),n.on("end",()=>this._removeStream(n));this.streams.length===0&&this.close(),this.idx=this.streams.length-1}_removeStream(s){let n=this.streams.indexOf(s);n<0||(this.streams.splice(n,1),this.idx>=this.streams.length&&--this.idx,this.streams.length===0&&this._end())}close(){super.close();for(let s of this.streams)s.close()}read(){for(let s=0;st.ActorRdfJoin.hash(l,a),t.ActorRdfJoin.joinBindings),metadata:async()=>await this.constructResultMetadata(n.entries,r,n.context)}}}async getJoinCoefficients(n,r){const a=t.ActorRdfJoin.getRequestInitialTimes(r),o=t.ActorRdfJoin.getRequestItemTimes(r);return{iterations:r[0].cardinality.value+r[1].cardinality.value,persistedItems:r[0].cardinality.value,blockingItems:r[0].cardinality.value,requestTime:a[0]+r[0].cardinality.value*o[0]+a[1]+r[1].cardinality.value*o[1]}}};return Ld.ActorRdfJoinHash=u,Ld}var m6;function lK(){return m6||(m6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(cK(),t)}(x2)),x2}var L2={},Md={},_6;function dK(){if(_6)return Md;_6=1,Object.defineProperty(Md,"__esModule",{value:!0}),Md.ActorRdfJoinSymmetricHash=void 0;const t=Ln(),e=zb();let u=class i7 extends t.ActorRdfJoin{constructor(n){super(n,{logicalType:"inner",physicalName:"symmetric-hash",limitEntries:2})}async getOutput(n){const r=await t.ActorRdfJoin.getMetadatas(n.entries),a=t.ActorRdfJoin.overlappingVariables(r);return{result:{type:"bindings",bindingsStream:new e.SymmetricHashJoin(n.entries[0].output.bindingsStream,n.entries[1].output.bindingsStream,l=>i7.hash(l,a),t.ActorRdfJoin.joinBindings),metadata:async()=>await this.constructResultMetadata(n.entries,r,n.context)}}}async getJoinCoefficients(n,r){const a=t.ActorRdfJoin.getRequestInitialTimes(r),o=t.ActorRdfJoin.getRequestItemTimes(r);return{iterations:r[0].cardinality.value+r[1].cardinality.value,persistedItems:r[0].cardinality.value+r[1].cardinality.value,blockingItems:0,requestTime:a[0]+r[0].cardinality.value*o[0]+a[1]+r[1].cardinality.value*o[1]}}};return Md.ActorRdfJoinSymmetricHash=u,Md}var v6;function fK(){return v6||(v6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(dK(),t)}(L2)),L2}var M2={},Fd={},w6;function hK(){if(w6)return Fd;w6=1,Object.defineProperty(Fd,"__esModule",{value:!0}),Fd.ActorRdfJoinNestedLoop=void 0;const t=Ln(),e=zb();let u=class extends t.ActorRdfJoin{constructor(n){super(n,{logicalType:"inner",physicalName:"nested-loop",limitEntries:2,canHandleUndefs:!0})}async getOutput(n){return{result:{type:"bindings",bindingsStream:new e.NestedLoopJoin(n.entries[0].output.bindingsStream,n.entries[1].output.bindingsStream,t.ActorRdfJoin.joinBindings,{autoStart:!1}),metadata:async()=>await this.constructResultMetadata(n.entries,await t.ActorRdfJoin.getMetadatas(n.entries),n.context)}}}async getJoinCoefficients(n,r){const a=t.ActorRdfJoin.getRequestInitialTimes(r),o=t.ActorRdfJoin.getRequestItemTimes(r);return{iterations:r[0].cardinality.value*r[1].cardinality.value,persistedItems:0,blockingItems:0,requestTime:a[0]+r[0].cardinality.value*o[0]+a[1]+r[1].cardinality.value*o[1]}}};return Fd.ActorRdfJoinNestedLoop=u,Fd}var S6;function pK(){return S6||(S6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(hK(),t)}(M2)),M2}var F2={},qd={},T6;function yK(){if(T6)return qd;T6=1,Object.defineProperty(qd,"__esModule",{value:!0}),qd.ActorRdfJoinMinusHash=void 0;const t=wt(),e=Ln();let u=class extends e.ActorRdfJoin{constructor(n){super(n,{logicalType:"minus",physicalName:"hash",limitEntries:2})}async getOutput(n){const r=n.entries[1].output,a=n.entries[0].output,o=await e.ActorRdfJoin.getMetadatas(n.entries),l=e.ActorRdfJoin.overlappingVariables(o);if(l.length>0){const c={},d=new t.ClosableTransformIterator(async()=>(await new Promise(h=>{r.bindingsStream.on("data",f=>{c[e.ActorRdfJoin.hashNonClashing(f,l)]=!0}),r.bindingsStream.on("end",h),r.bindingsStream.on("error",f=>{d.emit("error",f)})}),a.bindingsStream.filter(h=>!c[e.ActorRdfJoin.hashNonClashing(h,l)])),{autoStart:!1,onClose(){r.bindingsStream.destroy(),a.bindingsStream.destroy()}});return{result:{type:"bindings",bindingsStream:d,metadata:a.metadata}}}return r.bindingsStream.destroy(),{result:a}}async getJoinCoefficients(n,r){const a=e.ActorRdfJoin.getRequestInitialTimes(r),o=e.ActorRdfJoin.getRequestItemTimes(r);return{iterations:r[0].cardinality.value+r[1].cardinality.value,persistedItems:r[0].cardinality.value,blockingItems:r[0].cardinality.value,requestTime:a[0]+r[0].cardinality.value*o[0]+a[1]+r[1].cardinality.value*o[1]}}};return qd.ActorRdfJoinMinusHash=u,qd}var A6;function bK(){return A6||(A6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(yK(),t)}(F2)),F2}var q2={},Bd={},Ud={},E6;function gK(){if(E6)return Ud;E6=1,Object.defineProperty(Ud,"__esModule",{value:!0}),Ud.BindingsIndex=void 0;const t=er();let e=class u3{constructor(s){this.data={},this.keys=s}static hashTerm(s){return s&&s.termType!=="Variable"?(0,t.termToString)(s):""}add(s){if(this.isBindingsValid(s)){let n=this.data;for(const r of this.keys){const a=u3.hashTerm(s.get(r));let o=n[a];o||(o=n[a]={}),n=o}}}contains(s){return this.isBindingsValid(s)?this.containsRecursive(s,this.keys,[this.data]):!1}isBindingsValid(s){let n=!1;for(const r of this.keys)if(s.get(r)){n=!0;break}return n}containsRecursive(s,n,r){if(n.length===0)return!0;let a;[a,...n]=n;for(const o of r){const l=u3.hashTerm(s.get(a));if(l){const c=[o[l],o[""]].filter(Boolean);if(c.length===0)continue;if(this.containsRecursive(s,n,c))return!0}else{let c=Object.keys(o).map(d=>o[d]);if(c.length===0&&(c=[{}]),this.containsRecursive(s,n,c))return!0}}return!1}};return Ud.BindingsIndex=e,Ud}var O6;function mK(){if(O6)return Bd;O6=1,Object.defineProperty(Bd,"__esModule",{value:!0}),Bd.ActorRdfJoinMinusHashUndef=void 0;const t=wt(),e=Ln(),u=gK();let s=class extends e.ActorRdfJoin{constructor(r){super(r,{logicalType:"minus",physicalName:"hash-undef",limitEntries:2,canHandleUndefs:!0})}async getOutput(r){const a=r.entries[1].output,o=r.entries[0].output,l=await e.ActorRdfJoin.getMetadatas(r.entries),c=e.ActorRdfJoin.overlappingVariables(l);if(c.length>0){const d=new u.BindingsIndex(c),h=new t.ClosableTransformIterator(async()=>(await new Promise(f=>{a.bindingsStream.on("data",p=>d.add(p)),a.bindingsStream.on("end",f),a.bindingsStream.on("error",p=>{h.emit("error",p)})}),o.bindingsStream.filter(f=>!d.contains(f))),{autoStart:!1,onClose(){a.bindingsStream.destroy(),o.bindingsStream.destroy()}});return{result:{type:"bindings",bindingsStream:h,async metadata(){const f=await o.metadata(),p=await o.metadata();return{...p,canContainUndefs:f.canContainUndefs||p.canContainUndefs}}}}}return a.bindingsStream.destroy(),{result:o}}async getJoinCoefficients(r,a){const o=e.ActorRdfJoin.getRequestInitialTimes(a),l=e.ActorRdfJoin.getRequestItemTimes(a);return{iterations:(a[0].cardinality.value+a[1].cardinality.value)*1.01,persistedItems:a[0].cardinality.value,blockingItems:a[0].cardinality.value,requestTime:o[0]+a[0].cardinality.value*l[0]+o[1]+a[1].cardinality.value*l[1]}}};return Bd.ActorRdfJoinMinusHashUndef=s,Bd}var R6;function _K(){return R6||(R6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(mK(),t)}(q2)),q2}var B2={},Hd={},$d={},x6;function vK(){if(x6)return $d;x6=1,Object.defineProperty($d,"__esModule",{value:!0}),$d.BindingsIndexDef=void 0;let t=class{constructor(u,s){this.keys=u,this.hashFn=s,this.index={}}put(u,s){return this.index[this.hashFn(u,this.keys)]=s}get(u){const s=this.getFirst(u);return s?[s]:[]}getFirst(u){return this.index[this.hashFn(u,this.keys)]}values(){return Object.values(this.index)}};return $d.BindingsIndexDef=t,$d}var Qd={},I6;function wK(){if(I6)return Qd;I6=1,Object.defineProperty(Qd,"__esModule",{value:!0}),Qd.BindingsIndexUndef=void 0;let t=class{constructor(u,s){this.data={},this.keys=u,this.hashFn=s}put(u,s){if(this.isBindingsValid(u)){let n=this.data;for(let r=0;rd&&d.termType!=="Variable"?(0,s.termToString)(d):""):new n.BindingsIndexDef(c,e.ActorRdfJoin.hashNonClashing)}async getOutput(l){const c=l.entries[1].output,d=l.entries[0].output,h=await e.ActorRdfJoin.getMetadatas(l.entries),f=e.ActorRdfJoin.overlappingVariables(h);let p;return this.blocking?p=new t.ClosableTransformIterator(async()=>{const y=c3.constructIndex(this.canHandleUndefs,f);return await new Promise(b=>{c.bindingsStream.on("data",m=>{(y.getFirst(m)??y.put(m,[])).push(m)}),c.bindingsStream.on("end",b),c.bindingsStream.on("error",m=>{p.emit("error",m)})}),new u.MultiTransformIterator(d.bindingsStream,{multiTransform:b=>new u.ArrayIterator(y.get(b).flat().map(m=>e.ActorRdfJoin.joinBindings(b,m)).filter(m=>m!==null),{autoStart:!1}),optional:!0,autoStart:!1})},{autoStart:!1,onClose(){c.bindingsStream.destroy(),d.bindingsStream.destroy()}}):p=new t.ClosableTransformIterator(async()=>{const y=c3.constructIndex(this.canHandleUndefs,f);let b=!0;return c.bindingsStream.on("data",m=>{(y.getFirst(m)??y.put(m,new u.BufferedIterator({autoStart:!1})))._push(m)}),c.bindingsStream.on("end",()=>{for(const m of y.values())m.close();b=!1}),c.bindingsStream.on("error",m=>{p.emit("error",m)}),new u.MultiTransformIterator(d.bindingsStream,{multiTransform:m=>{let g=y.get(m);return g.length===0&&(b?g=[y.put(m,new u.BufferedIterator({autoStart:!1}))]:g=[]),new u.UnionIterator(g.map(_=>_.clone()),{autoStart:!1}).map(_=>e.ActorRdfJoin.joinBindings(m,_))},optional:!0,autoStart:!1})},{autoStart:!1,onClose(){c.bindingsStream.destroy(),d.bindingsStream.destroy()}}),{result:{type:"bindings",bindingsStream:p,metadata:async()=>await this.constructResultMetadata(l.entries,await e.ActorRdfJoin.getMetadatas(l.entries),l.context,{canContainUndefs:!0})}}}async getJoinCoefficients(l,c){if(e.ActorRdfJoin.overlappingVariables(c).length===0)throw new Error(`Actor ${this.name} only join entries with at least one common variable`);const d=e.ActorRdfJoin.getRequestInitialTimes(c),h=e.ActorRdfJoin.getRequestItemTimes(c);let f=c[0].cardinality.value+c[1].cardinality.value;return this.canHandleUndefs||(f*=.8),this.blocking&&(f*=.9),{iterations:f,persistedItems:c[0].cardinality.value,blockingItems:this.blocking?c[0].cardinality.value:0,requestTime:d[0]+c[0].cardinality.value*h[0]+d[1]+c[1].cardinality.value*h[1]}}};return Hd.ActorRdfJoinOptionalHash=a,Hd}var D6;function A1(){return D6||(D6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(SK(),t)}(B2)),B2}var U2={},Vd={},N6;function TK(){if(N6)return Vd;N6=1,Object.defineProperty(Vd,"__esModule",{value:!0}),Vd.ActorRdfJoinOptionalNestedLoop=void 0;const t=Ln(),e=zb();let u=class extends t.ActorRdfJoin{constructor(n){super(n,{logicalType:"optional",physicalName:"nested-loop",limitEntries:2,canHandleUndefs:!0})}async getOutput(n){return{result:{type:"bindings",bindingsStream:new e.NestedLoopJoin(n.entries[0].output.bindingsStream,n.entries[1].output.bindingsStream,t.ActorRdfJoin.joinBindings,{optional:!0,autoStart:!1}),metadata:async()=>await this.constructResultMetadata(n.entries,await t.ActorRdfJoin.getMetadatas(n.entries),n.context,{canContainUndefs:!0})}}}async getJoinCoefficients(n,r){const a=t.ActorRdfJoin.getRequestInitialTimes(r),o=t.ActorRdfJoin.getRequestItemTimes(r);return{iterations:r[0].cardinality.value*r[1].cardinality.value,persistedItems:0,blockingItems:0,requestTime:a[0]+r[0].cardinality.value*o[0]+a[1]+r[1].cardinality.value*o[1]}}};return Vd.ActorRdfJoinOptionalNestedLoop=u,Vd}var C6;function AK(){return C6||(C6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(TK(),t)}(U2)),U2}var H2={},kd={},$2={},zd={},j6;function EK(){if(j6)return zd;j6=1,Object.defineProperty(zd,"__esModule",{value:!0}),zd.ActorDereferenceRdf=void 0;const t=UT();let e=class extends t.ActorDereferenceParse{constructor(s){super(s)}};return zd.ActorDereferenceRdf=e,zd}var L6;function OK(){return L6||(L6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(EK(),t)}($2)),$2}var M6;function RK(){if(M6)return kd;M6=1,Object.defineProperty(kd,"__esModule",{value:!0}),kd.ActorDereferenceRdfParse=void 0;const t=OK();let e=class extends t.ActorDereferenceRdf{constructor(s){super(s)}async getMetadata(s){return{baseIRI:s.url}}};return kd.ActorDereferenceRdfParse=e,kd}var F6;function xK(){return F6||(F6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(RK(),t)}(H2)),H2}var Q2={},Gd={},Wd={},q6;function IK(){if(q6)return Wd;q6=1,Object.defineProperty(Wd,"__esModule",{value:!0}),Wd.HtmlScriptListener=void 0;const t=Lt,e=Wt(),u=Pi();let s=class E0{constructor(r,a,o,l,c,d,h,f){this.textChunksJsonLd=[],this.endBarrier=1,this.passedScripts=0,this.isFinalJsonLdProcessing=!1,this.mediatorRdfParseHandle=r,this.cbQuad=a,this.cbError=o,this.cbEnd=l,this.supportedTypes=c,this.context=d.set(t.KeysRdfParseHtmlScript.processingHtmlScript,!0),this.baseIRI=h,this.headers=f,this.onlyFirstScript=d.get(t.KeysRdfParseHtmlScript.extractAllScripts)===!1;const p=this.baseIRI.indexOf("#");this.targetScriptId=p>0?this.baseIRI.slice(p+1,this.baseIRI.length):null}static newErrorCoded(r,a){const o=new Error(r);return o.code=a,o}onEnd(){--this.endBarrier===0&&(this.textChunksJsonLd.length>0?(this.handleMediaType="application/ld+json",this.textChunks=this.textChunksJsonLd,this.textChunks.push("]"),this.textChunksJsonLd=[],this.isFinalJsonLdProcessing=!0,this.endBarrier++,this.onTagClose()):(this.passedScripts===0&&this.targetScriptId&&this.cbError(E0.newErrorCoded(`Failed to find targeted script id "${this.targetScriptId}"`,"loading document failed")),this.cbEnd()),this.isFinalJsonLdProcessing=!1)}onTagClose(){if(this.handleMediaType)if(this.requiresCustomJsonLdHandling(this.handleMediaType)&&!this.isFinalJsonLdProcessing)this.handleMediaType=void 0,this.textChunks=void 0,this.onEnd();else{const r=new e.Readable({objectMode:!0});r._read=()=>{};const a=this.textChunks,o={context:this.context,handle:{metadata:{baseIRI:this.baseIRI},data:r,headers:this.headers,context:this.context},handleMediaType:this.handleMediaType};this.mediatorRdfParseHandle.mediate(o).then(({handle:l})=>{l.data.on("error",c=>this.cbError(E0.newErrorCoded(c.message,"invalid script element"))).on("data",this.cbQuad).on("end",()=>this.onEnd());for(const c of a)r.push(c);r.push(null)}).catch(l=>{this.targetScriptId?this.cbError(E0.newErrorCoded(l.message,"loading document failed")):this.onEnd()}),this.handleMediaType=void 0,this.textChunks=void 0}}onTagOpen(r,a){r==="base"&&a.href&&(this.baseIRI=(0,u.resolve)(a.href,this.baseIRI)),r==="script"&&(!this.targetScriptId||a.id===this.targetScriptId)?this.supportedTypes[a.type]?this.onlyFirstScript&&this.passedScripts>0?this.handleMediaType=void 0:(this.passedScripts++,this.handleMediaType=a.type,this.endBarrier++,this.requiresCustomJsonLdHandling(this.handleMediaType)?(this.textChunks=this.textChunksJsonLd,this.textChunks.push(this.textChunks.length===0?"[":",")):this.textChunks=[]):this.targetScriptId&&this.cbError(E0.newErrorCoded(`Targeted script "${this.targetScriptId}" does not have a supported type`,"loading document failed")):this.handleMediaType=void 0}onText(r){this.handleMediaType&&this.textChunks.push(r)}requiresCustomJsonLdHandling(r){return!this.onlyFirstScript&&!this.targetScriptId&&r==="application/ld+json"}};return Wd.HtmlScriptListener=s,Wd}var B6;function PK(){if(B6)return Gd;B6=1,Object.defineProperty(Gd,"__esModule",{value:!0}),Gd.ActorRdfParseHtmlScript=void 0;const t=JT(),e=IK();let u=class extends t.ActorRdfParseHtml{constructor(n){super(n)}async test(n){return!0}async run(n){const r=(await this.mediatorRdfParseMediatypes.mediate({context:n.context,mediaTypes:!0})).mediaTypes;return{htmlParseListener:new e.HtmlScriptListener(this.mediatorRdfParseHandle,n.emit,n.error,n.end,r,n.context,n.baseIRI,n.headers)}}};return Gd.ActorRdfParseHtmlScript=u,Gd}var U6;function DK(){return U6||(U6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(PK(),t)}(Q2)),Q2}var V2={},Jd={},H6;function NK(){if(H6)return Jd;H6=1,Object.defineProperty(Jd,"__esModule",{value:!0}),Jd.ActorQueryResultSerializeRdf=void 0;const t=Gi();let e=class extends t.ActorQueryResultSerialize{constructor(s){super(s)}async testHandle(s,n,r){if(s.type!=="quads")throw new Error(`Actor ${this.name} can only handle quad streams`);const{mediaTypes:a}=await this.mediatorMediaTypeCombiner.mediate({context:r,mediaTypes:!0});if(!(n in a))throw new Error(`Actor ${this.name} can not handle media type ${n}. All available types: ${Object.keys(a)}`);return!0}async runHandle(s,n,r){return(await this.mediatorRdfSerialize.mediate({context:r,handle:{context:r,quadStream:s.quadStream},handleMediaType:n})).handle}async testMediaType(s){return!0}async getMediaTypes(s){return(await this.mediatorMediaTypeCombiner.mediate({context:s,mediaTypes:!0})).mediaTypes}async testMediaTypeFormats(s){return!0}async getMediaTypeFormats(s){return(await this.mediatorMediaTypeFormatCombiner.mediate({context:s,mediaTypeFormats:!0})).mediaTypeFormats}};return Jd.ActorQueryResultSerializeRdf=e,Jd}var $6;function CK(){return $6||($6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(NK(),t)}(V2)),V2}var k2={},Xd={},Q6;function jK(){if(Q6)return Xd;Q6=1,Object.defineProperty(Xd,"__esModule",{value:!0}),Xd.ActorHttpWayback=void 0;const t=rs(),e=Lt,u=eo();r7();const s="http://wayback.archive-it.org/";function n(o){const l=new Request(o.input,o.init);return{input:new Request(new URL(`/${l.url}`,s),l)}}function r(o){const l=o.get(e.KeysHttpProxy.httpProxyHandler);return l?c=>l.getProxy(n(c)):c=>Promise.resolve(n(c))}let a=class extends t.ActorHttp{constructor(l){super(l)}async test(l){return!0}async run(l){let c=await this.mediatorHttp.mediate(l);if(c.status===404&&l.context.get(e.KeysHttpWayback.recoverBrokenLinks)){let d=await this.mediatorHttp.mediate({...l,context:l.context.set(e.KeysHttpWayback.recoverBrokenLinks,!1).set(e.KeysHttpProxy.httpProxyHandler,{getProxy:r(l.context)})});d.status===200&&([c,d]=[d,c]);const{body:h}=d;h&&("cancel"in h&&typeof h.cancel=="function"?await h.cancel():"destroy"in h&&typeof h.destroy=="function"?h.destroy():await u(t.ActorHttp.toNodeReadable(h)))}return c}};return Xd.ActorHttpWayback=a,Xd}var V6;function LK(){return V6||(V6=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(jK(),t)}(k2)),k2}var z2={},Kd={},G2={},Yd={},Zd={},ef={},tf={},rf={},k6;function MK(){if(k6)return rf;k6=1,Object.defineProperty(rf,"__esModule",{value:!0}),rf.ContainerHandlerIdentifier=void 0;let t=class{canCombineWithGraph(){return!0}async handle(u,s,n,r,a,o){let l;if(s.emittedStack[o+1]&&s.idStack[o+1])l=s.idStack[o+1][0];else{const h=await n.getContainerKey(r[o],r,o)!==null?await n.resourceToTerm(await s.getContext(r),r[o]):n.dataFactory.blankNode();if(!h){s.emittedStack[o]=!1;return}l=h,s.idStack[o+1]=[l]}let c=s.idStack[o];c||(c=s.idStack[o]=[]),c.some(d=>d.equals(l))||c.push(l),await s.handlePendingContainerFlushBuffers()||(s.emittedStack[o]=!1)}};return rf.ContainerHandlerIdentifier=t,rf}var nf={},af={},z6;function Gb(){if(z6)return af;z6=1,Object.defineProperty(af,"__esModule",{value:!0}),af.EntryHandlerPredicate=void 0;const t=Jr(),e=to();let u=class a7{static async handlePredicateObject(n,r,a,o,l,c,d,h,f){const p=await r.getPropertiesDepth(a,o),y=await r.getDepthOffsetGraph(o,a),b=o-y,m=n.idStack[p];if(m&&!f)for(const g of m)if(y>=0){const _=n.idStack[b-1];if(_)for(const w of _)r.emitQuadChecked(o,g,l,c,w,d,h);else d?(r.validateReverseSubject(c),n.getUnidentifiedGraphBufferSafe(b-1).push({subject:c,predicate:l,object:g,isEmbedded:h})):n.getUnidentifiedGraphBufferSafe(b-1).push({subject:g,predicate:l,object:c,isEmbedded:h})}else{const _=await r.getGraphContainerValue(a,p);r.emitQuadChecked(o,g,l,c,_,d,h)}else if(d&&r.validateReverseSubject(c),f){if(n.rdfstar){n.idStack[o]&&n.emitError(new t.ErrorCoded(`Found an illegal @id inside an annotation: ${n.idStack[o][0].value}`,t.ERROR_CODES.INVALID_ANNOTATION));for(let _=0;_=0;_--){const w=g[_];w.depth>p&&(v.nestedAnnotations.push(w),g.splice(_,1))}}}else n.getUnidentifiedValueBufferSafe(p).push({predicate:l,object:c,reverse:d,isEmbedded:h})}isPropertyHandler(){return!0}isStackProcessor(){return!0}async validate(n,r,a,o,l){const c=a[o];if(c){const d=await n.getContext(a);if(!n.jsonLiteralStack[o]&&await r.predicateToTerm(d,a[o]))return e.Util.getContextValueType(d,c)==="@json"&&(n.jsonLiteralStack[o+1]=!0),!0}return!1}async test(n,r,a,o,l){return o[l]}async handle(n,r,a,o,l,c,d){const h=o[c],f=await n.getContext(o),p=await r.predicateToTerm(f,a);if(p){const y=await r.valueToTerm(f,a,l,c,o);if(y.length)for(let b of y){let m=await r.unaliasKeywordParent(o,c);const g=e.Util.isPropertyReverse(f,h,m);let v=0;for(;m==="@reverse"||typeof m=="number";)typeof m=="number"?v++:c--,m=await r.unaliasKeywordParent(o,c-v);const _=e.Util.isPropertyInEmbeddedNode(m);r.validateReverseInEmbeddedNode(a,g,_);const w=e.Util.isPropertyInAnnotationObject(m);if(l){const S="@list"in e.Util.getContextValueContainer(f,a);if(S||l["@list"]){if((S&&!Array.isArray(l)&&!l["@list"]||l["@list"]&&!Array.isArray(l["@list"]))&&b!==r.rdfNil){const A=r.dataFactory.blankNode();n.emitQuad(c,r.dataFactory.quad(A,r.rdfRest,r.rdfNil,r.getDefaultGraph())),n.emitQuad(c,r.dataFactory.quad(A,r.rdfFirst,b,r.getDefaultGraph())),b=A}if(g&&!n.allowSubjectList)throw new t.ErrorCoded(`Found illegal list value in subject position at ${a}`,t.ERROR_CODES.INVALID_REVERSE_PROPERTY_VALUE)}}await a7.handlePredicateObject(n,r,o,c,p,b,g,_,w)}}}};return af.EntryHandlerPredicate=u,af}var G6;function FK(){if(G6)return nf;G6=1,Object.defineProperty(nf,"__esModule",{value:!0}),nf.ContainerHandlerIndex=void 0;const t=Jr(),e=Gb(),u=to();let s=class{canCombineWithGraph(){return!0}async handle(r,a,o,l,c,d){if(!Array.isArray(c)){const h="@graph"in r,f=await a.getContext(l),p=l[d-1],y=u.Util.getContextValueIndex(f,p);if(y){if(t.Util.isPotentialKeyword(y))throw new t.ErrorCoded(`Keywords can not be used as @index value, got: ${y}`,t.ERROR_CODES.INVALID_TERM_DEFINITION);if(typeof y!="string")throw new t.ErrorCoded(`@index values must be strings, got: ${y}`,t.ERROR_CODES.INVALID_TERM_DEFINITION);if(typeof c!="object"){if(u.Util.getContextValueType(f,p)!=="@id")throw new t.ErrorCoded(`Property-based index containers require nodes as values or strings with @type: @id, but got: ${c}`,t.ERROR_CODES.INVALID_VALUE_OBJECT);const g=o.resourceToTerm(f,c);g&&(a.idStack[d+1]=[g])}const m=o.createVocabOrBaseTerm(f,y);if(m){const g=await o.valueToTerm(f,y,await o.getContainerKey(l[d],l,d),d,l);if(h){const v=await o.getGraphContainerValue(l,d+1);for(const _ of g)a.emitQuad(d,o.dataFactory.quad(v,m,_,o.getDefaultGraph()))}else for(const v of g)await e.EntryHandlerPredicate.handlePredicateObject(a,o,l,d+1,m,v,!1,!1,!1)}}const b=h?2:1;await a.newOnValueJob(l.slice(0,l.length-b),c,d-b,!0),await a.handlePendingContainerFlushBuffers()}a.emittedStack[d]=!1}};return nf.ContainerHandlerIndex=s,nf}var sf={},W6;function qK(){if(W6)return sf;W6=1,Object.defineProperty(sf,"__esModule",{value:!0}),sf.ContainerHandlerLanguage=void 0;const t=Jr();let e=class{canCombineWithGraph(){return!1}async handle(s,n,r,a,o,l){const c=await r.getContainerKey(a[l],a,l);if(Array.isArray(o))o=o.map(d=>({"@value":d,"@language":c}));else{if(typeof o!="string")throw new t.ErrorCoded(`Got invalid language map value, got '${JSON.stringify(o)}', but expected string`,t.ERROR_CODES.INVALID_LANGUAGE_MAP_VALUE);o={"@value":o,"@language":c}}await n.newOnValueJob(a.slice(0,a.length-1),o,l-1,!0),n.emittedStack[l]=!1}};return sf.ContainerHandlerLanguage=e,sf}var of={},J6;function BK(){if(J6)return of;J6=1,Object.defineProperty(of,"__esModule",{value:!0}),of.ContainerHandlerType=void 0;const t=Gb(),e=to();let u=class{canCombineWithGraph(){return!1}async handle(n,r,a,o,l,c){if(!Array.isArray(l)){if(typeof l=="string"){const f=await r.getContext(o),y=e.Util.getContextValueType(f,o[c-1])==="@vocab"?await a.createVocabOrBaseTerm(f,l):await a.resourceToTerm(f,l);if(y){const b={"@id":y.termType==="NamedNode"?y.value:l};await r.newOnValueJob(o.slice(0,o.length-1),b,c-1,!0),r.idStack[c+1]=[y]}}else{const f=!!r.idStack[c+1];f||delete r.idStack[c],await r.newOnValueJob(o.slice(0,o.length-1),l,c-1,!0),f||(r.idStack[c+1]=r.idStack[c])}const d=await a.getContainerKey(o[c],o,c),h=d!==null?a.createVocabOrBaseTerm(await r.getContext(o),d):null;h&&await t.EntryHandlerPredicate.handlePredicateObject(r,a,o,c+1,a.rdfType,h,!1,!1,!1),await r.handlePendingContainerFlushBuffers()}r.emittedStack[c]=!1}};return of.ContainerHandlerType=u,of}var X6;function s7(){if(X6)return tf;X6=1,Object.defineProperty(tf,"__esModule",{value:!0}),tf.EntryHandlerContainer=void 0;const t=MK(),e=FK(),u=qK(),s=BK(),n=to();let r=class Pa{static isSimpleGraphContainer(o){return"@graph"in o&&("@set"in o&&Object.keys(o).length===2||Object.keys(o).length===1)}static isComplexGraphContainer(o){return"@graph"in o&&("@set"in o&&Object.keys(o).length>2||!("@set"in o)&&Object.keys(o).length>1)}static getContainerGraphIndex(o,l,c){let d=Pa.isSimpleGraphContainer(o),h="";for(let f=l;f=0;p--)if(typeof l[p]!="number"){const y=n.Util.getContextValue(f,"@container",l[p],!1);if(y&&Pa.isSimpleGraphContainer(y))return{containers:y,depth:p+1,fallback:!1};const b=n.Util.getContextValue(f,"@container",l[p-1],!1);if(b){const m="@graph"in b;for(const g in Pa.CONTAINER_HANDLERS)if(b[g])return m?Pa.CONTAINER_HANDLERS[g].canCombineWithGraph()?{containers:b,depth:p,fallback:!1}:d:h?d:{containers:b,depth:p,fallback:!1};return d}else{if(h)return d;h=!0}}return d}static async isBufferableContainerHandler(o,l,c){const d=await Pa.getContainerHandler(o,l,c);return!d.fallback&&!("@graph"in d.containers)}isPropertyHandler(){return!1}isStackProcessor(){return!0}async validate(o,l,c,d,h){return!!await this.test(o,l,null,c,d)}async test(o,l,c,d,h){const f=n.Util.getContextValueContainer(await o.getContext(d,2),d[h-1]);for(const p in Pa.CONTAINER_HANDLERS)if(f[p])return{containers:f,handler:Pa.CONTAINER_HANDLERS[p]};return null}async handle(o,l,c,d,h,f,p){return p.handler.handle(p.containers,o,l,d,h,f)}};return r.CONTAINER_HANDLERS={"@id":new t.ContainerHandlerIdentifier,"@index":new e.ContainerHandlerIndex,"@language":new u.ContainerHandlerLanguage,"@type":new s.ContainerHandlerType},tf.EntryHandlerContainer=r,tf}var W2,K6;function UK(){return K6||(K6=1,W2=function t(e){return e===null||typeof e!="object"||e.toJSON!=null?JSON.stringify(e):Array.isArray(e)?"["+e.reduce((u,s,n)=>{const r=n===0?"":",",a=s===void 0||typeof s=="symbol"?null:s;return u+r+t(a)},"")+"]":"{"+Object.keys(e).sort().reduce((u,s,n)=>{if(e[s]===void 0||typeof e[s]=="symbol")return u;const r=u.length===0?"":",";return u+r+t(s)+":"+t(e[s])},"")+"}"}),W2}var Y6;function to(){if(Y6)return ef;Y6=1,Object.defineProperty(ef,"__esModule",{value:!0}),ef.Util=void 0;const t=Jr(),e=Et(),u=s7(),s=UK();let n=class Yt{constructor(a){this.parsingContext=a.parsingContext,this.dataFactory=a.dataFactory||new e.DataFactory,this.rdfFirst=this.dataFactory.namedNode(Yt.RDF+"first"),this.rdfRest=this.dataFactory.namedNode(Yt.RDF+"rest"),this.rdfNil=this.dataFactory.namedNode(Yt.RDF+"nil"),this.rdfType=this.dataFactory.namedNode(Yt.RDF+"type"),this.rdfJson=this.dataFactory.namedNode(Yt.RDF+"JSON")}static getContextValue(a,o,l,c){const d=a.getContextRaw()[l];if(!d)return c;const h=d[o];return h===void 0?c:h}static getContextValueContainer(a,o){return Yt.getContextValue(a,"@container",o,{"@set":!0})}static getContextValueType(a,o){const l=Yt.getContextValue(a,"@type",o,null);return l==="@none"?null:l}static getContextValueLanguage(a,o){return Yt.getContextValue(a,"@language",o,a.getContextRaw()["@language"]||null)}static getContextValueDirection(a,o){return Yt.getContextValue(a,"@direction",o,a.getContextRaw()["@direction"]||null)}static isContextValueReverse(a,o){return!!Yt.getContextValue(a,"@reverse",o,null)}static getContextValueIndex(a,o){return Yt.getContextValue(a,"@index",o,a.getContextRaw()["@index"]||null)}static isPropertyReverse(a,o,l){return l==="@reverse"!==Yt.isContextValueReverse(a,o)}static isPropertyInEmbeddedNode(a){return a==="@id"}static isPropertyInAnnotationObject(a){return a==="@annotation"}static isValidIri(a){return a!==null&&t.Util.isValidIri(a)}static isPrefixArray(a,o){if(a.length>o.length)return!1;for(let l=0;l1)throw new t.ErrorCoded(`Found illegal neighbouring entries next to @set for key: '${o}'`,t.ERROR_CODES.INVALID_SET_OR_LIST_OBJECT);return[]}else if("@list"in l){if(Object.keys(l).length>1)throw new t.ErrorCoded(`Found illegal neighbouring entries next to @list for key: '${o}'`,t.ERROR_CODES.INVALID_SET_OR_LIST_OBJECT);const f=l["@list"];return Array.isArray(f)?f.length===0?[this.rdfNil]:this.parsingContext.idStack[c+1]||[]:await this.valueToTerm(await this.parsingContext.getContext(d),o,f,c-1,d.slice(0,-1))}else{if("@reverse"in l&&typeof l["@reverse"]=="boolean")return[];if("@graph"in Yt.getContextValueContainer(await this.parsingContext.getContext(d),o)){const f=this.parsingContext.graphContainerTermStack[c+1];return f?Object.values(f):[this.dataFactory.blankNode()]}else if("@id"in l){if(Object.keys(l).length>1&&(a=await this.parsingContext.getContext(d,0)),"@context"in l&&(a=await this.parsingContext.parseContext(l["@context"],a.getContextRaw())),l["@type"]==="@vocab")return this.nullableTermToArray(this.createVocabOrBaseTerm(a,l["@id"]));{const f=l["@id"];let p;if(typeof f=="object")if(this.parsingContext.rdfstar)p=this.parsingContext.idStack[c+1][0];else throw new t.ErrorCoded(`Found illegal @id '${l}'`,t.ERROR_CODES.INVALID_ID_VALUE);else p=this.resourceToTerm(a,f);return this.nullableTermToArray(p)}}else return this.parsingContext.emittedStack[c+1]||l&&typeof l=="object"&&Object.keys(l).length===0?this.parsingContext.idStack[c+1]||(this.parsingContext.idStack[c+1]=[this.dataFactory.blankNode()]):[]}case"string":return this.nullableTermToArray(this.stringValueToTerm(c,await this.getContextSelfOrPropertyScoped(a,o),o,l,null));case"boolean":return this.nullableTermToArray(this.stringValueToTerm(c,await this.getContextSelfOrPropertyScoped(a,o),o,(!!l).toString(),this.dataFactory.namedNode(Yt.XSD_BOOLEAN)));case"number":return this.nullableTermToArray(this.stringValueToTerm(c,await this.getContextSelfOrPropertyScoped(a,o),o,l,this.dataFactory.namedNode(l%1===0&&l<1e21?Yt.XSD_INTEGER:Yt.XSD_DOUBLE)));default:return this.parsingContext.emitError(new Error(`Could not determine the RDF type of a ${h}`)),[]}}async getContextSelfOrPropertyScoped(a,o){const l=a.getContextRaw()[o];return l&&typeof l=="object"&&"@context"in l&&(a=await this.parsingContext.parseContext(l,a.getContextRaw(),!0)),a}nullableTermToArray(a){return a?[a]:[]}predicateToTerm(a,o){const l=a.expandTerm(o,!0,this.parsingContext.getExpandOptions());if(!l)return null;if(l[0]==="_"&&l[1]===":")return this.parsingContext.produceGeneralizedRdf?this.dataFactory.blankNode(l.substr(2)):null;if(Yt.isValidIri(l))return this.dataFactory.namedNode(l);if(l&&this.parsingContext.strictValues)this.parsingContext.emitError(new t.ErrorCoded(`Invalid predicate IRI: ${l}`,t.ERROR_CODES.INVALID_IRI_MAPPING));else return null;return null}resourceToTerm(a,o){if(o.startsWith("_:"))return this.dataFactory.blankNode(o.substr(2));const l=a.expandTerm(o,!1,this.parsingContext.getExpandOptions());if(!Yt.isValidIri(l))if(l&&this.parsingContext.strictValues)this.parsingContext.emitError(new Error(`Invalid resource IRI: ${l}`));else return null;return this.dataFactory.namedNode(l)}createVocabOrBaseTerm(a,o){if(o.startsWith("_:"))return this.dataFactory.blankNode(o.substr(2));const l=this.parsingContext.getExpandOptions();let c=a.expandTerm(o,!0,l);if(c===o&&(c=a.expandTerm(o,!1,l)),!Yt.isValidIri(c))if(c&&this.parsingContext.strictValues&&!c.startsWith("@"))this.parsingContext.emitError(new Error(`Invalid term IRI: ${c}`));else return null;return this.dataFactory.namedNode(c)}intToString(a,o){return typeof a=="number"?Number.isFinite(a)?a%1===0&&(!o||o.value!==Yt.XSD_DOUBLE)?Number(a).toString():a.toExponential(15).replace(/(\d)0*e\+?/,"$1E"):a>0?"INF":"-INF":a}stringValueToTerm(a,o,l,c,d){const h=Yt.getContextValueType(o,l);if(h)if(h==="@id"){if(!d)return this.resourceToTerm(o,this.intToString(c,d))}else if(h==="@vocab"){if(!d)return this.createVocabOrBaseTerm(o,this.intToString(c,d))}else d=this.dataFactory.namedNode(h);if(!d){const f=Yt.getContextValueLanguage(o,l),p=Yt.getContextValueDirection(o,l);return p&&this.parsingContext.rdfDirection?this.createLanguageDirectionLiteral(a,this.intToString(c,d),f,p):this.dataFactory.literal(this.intToString(c,d),f)}return this.dataFactory.literal(this.intToString(c,d),d)}createLanguageDirectionLiteral(a,o,l,c){if(this.parsingContext.rdfDirection==="i18n-datatype")return l||(l=""),this.dataFactory.literal(o,this.dataFactory.namedNode(`https://www.w3.org/ns/i18n#${l}_${c}`));{const d=this.dataFactory.blankNode(),h=this.getDefaultGraph();return this.parsingContext.emitQuad(a,this.dataFactory.quad(d,this.dataFactory.namedNode(Yt.RDF+"value"),this.dataFactory.literal(o),h)),l&&this.parsingContext.emitQuad(a,this.dataFactory.quad(d,this.dataFactory.namedNode(Yt.RDF+"language"),this.dataFactory.literal(l),h)),this.parsingContext.emitQuad(a,this.dataFactory.quad(d,this.dataFactory.namedNode(Yt.RDF+"direction"),this.dataFactory.literal(c),h)),d}}valueToJsonString(a){return s(a)}async unaliasKeyword(a,o,l,c,d){if(Number.isInteger(a))return a;if(!c){const h=this.parsingContext.unaliasedKeywordCacheStack[l];if(h)return h}if(!t.Util.isPotentialKeyword(a)){d=d||await this.parsingContext.getContext(o);let h=d.getContextRaw()[a];h&&typeof h=="object"&&(h=h["@id"]),t.Util.isValidKeyword(h)&&(a=h)}return c?a:this.parsingContext.unaliasedKeywordCacheStack[l]=a}async unaliasKeywordParent(a,o){return await this.unaliasKeyword(o>0&&a[o-1],a,o-1)}async unaliasKeywords(a,o,l,c){const d={};for(const h in a)d[await this.unaliasKeyword(h,o,l+1,!0,c)]=a[h];return d}async isLiteral(a,o){for(let l=o;l>=0;l--){if(await this.unaliasKeyword(a[l],a,l)==="@annotation")return!1;if(this.parsingContext.literalStack[l]||this.parsingContext.jsonLiteralStack[l])return!0}return!1}async getDepthOffsetGraph(a,o){for(let l=a-1;l>0;l--)if(await this.unaliasKeyword(o[l],o,l)==="@graph"){const c=(await u.EntryHandlerContainer.getContainerHandler(this.parsingContext,o,l)).containers;return u.EntryHandlerContainer.isComplexGraphContainer(c)?-1:a-l-1}return-1}validateReverseSubject(a){if(a.termType==="Literal")throw new t.ErrorCoded(`Found illegal literal in subject position: ${a.value}`,t.ERROR_CODES.INVALID_REVERSE_PROPERTY_VALUE)}getDefaultGraph(){return this.parsingContext.defaultGraph||this.dataFactory.defaultGraph()}async getGraphContainerValue(a,o){let l=this.getDefaultGraph();const{containers:c,depth:d}=await u.EntryHandlerContainer.getContainerHandler(this.parsingContext,a,o);if("@graph"in c){const h=u.EntryHandlerContainer.getContainerGraphIndex(c,d,a),f=this.parsingContext.graphContainerTermStack[d];if(l=f?f[h]:null,!l){let p=null;if("@id"in c){const y=await this.getContainerKey(a[d],a,d);y!==null&&(p=await this.resourceToTerm(await this.parsingContext.getContext(a),y))}p||(p=this.dataFactory.blankNode()),this.parsingContext.graphContainerTermStack[d]||(this.parsingContext.graphContainerTermStack[d]={}),l=this.parsingContext.graphContainerTermStack[d][h]=p}}return l}async getPropertiesDepth(a,o){let l=o;for(let c=o-1;c>0;c--)if(typeof a[c]!="number"){const d=await this.unaliasKeyword(a[c],a,c);if(d==="@reverse")return c;if(d==="@nest")l=c;else return l}return l}async getContainerKey(a,o,l){const c=await this.unaliasKeyword(a,o,l);return c==="@none"?null:c}validateReverseInEmbeddedNode(a,o,l){if(l&&o&&!this.parsingContext.rdfstarReverseInEmbedded)throw new t.ErrorCoded(`Illegal reverse property in embedded node in ${a}`,t.ERROR_CODES.INVALID_EMBEDDED_NODE)}emitQuadChecked(a,o,l,c,d,h,f){let p;if(h?(this.validateReverseSubject(c),p=this.dataFactory.quad(c,l,o,d)):p=this.dataFactory.quad(o,l,c,d),f){if(p.graph.termType!=="DefaultGraph"&&(p=this.dataFactory.quad(p.subject,p.predicate,p.object)),this.parsingContext.idStack[a-1])throw new t.ErrorCoded("Illegal multiple properties in an embedded node",t.ERROR_CODES.INVALID_EMBEDDED_NODE);this.parsingContext.idStack[a-1]=[p]}else this.parsingContext.emitQuad(a,p);const y=this.parsingContext.annotationsBuffer[a];if(y){for(const b of y)this.emitAnnotation(a,p,b);delete this.parsingContext.annotationsBuffer[a]}}emitAnnotation(a,o,l){let c;l.reverse?(this.validateReverseSubject(l.object),c=this.dataFactory.quad(l.object,l.predicate,o)):c=this.dataFactory.quad(o,l.predicate,l.object),this.parsingContext.emitQuad(a,c);for(const d of l.nestedAnnotations)this.emitAnnotation(a,c,d)}};return n.XSD="http://www.w3.org/2001/XMLSchema#",n.XSD_BOOLEAN=n.XSD+"boolean",n.XSD_INTEGER=n.XSD+"integer",n.XSD_DOUBLE=n.XSD+"double",n.RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#",ef.Util=n,ef}var Z6;function HK(){if(Z6)return Zd;Z6=1,Object.defineProperty(Zd,"__esModule",{value:!0}),Zd.EntryHandlerArrayValue=void 0;const t=to(),e=Jr();let u=class{isPropertyHandler(){return!1}isStackProcessor(){return!0}async validate(n,r,a,o,l){return this.test(n,r,null,a,o)}async test(n,r,a,o,l){return typeof o[l]=="number"}async handle(n,r,a,o,l,c){let d=await r.unaliasKeywordParent(o,c);if(d==="@list"){let h=null,f=0;for(let p=c-2;p>0;p--){const y=o[p];if(typeof y=="string"||typeof y=="number"){f=p,h=y;break}}if(h!==null){const p=await r.valueToTerm(await n.getContext(o),h,l,c,o);for(const y of p)await this.handleListElement(n,r,y,l,c,o.slice(0,f),f);p.length===0&&await this.handleListElement(n,r,null,l,c,o.slice(0,f),f)}}else if(d==="@set")await n.newOnValueJob(o.slice(0,-2),l,c-2,!1);else if(d!==void 0&&d!=="@type"){for(let f=c-1;f>0;f--)if(typeof o[f]!="number"){d=await r.unaliasKeyword(o[f],o,f);break}const h=await n.getContext(o.slice(0,-1));if("@list"in t.Util.getContextValueContainer(h,d)){n.emittedStack[c+1]=!0;const f=await r.valueToTerm(await n.getContext(o),d,l,c,o);for(const p of f)await this.handleListElement(n,r,p,l,c,o.slice(0,-1),c-1);f.length===0&&await this.handleListElement(n,r,null,l,c,o.slice(0,-1),c-1)}else n.shiftStack(c,1),await n.newOnValueJob(o.slice(0,-1),l,c-1,!1),n.contextTree.removeContext(o.slice(0,-1))}}async handleListElement(n,r,a,o,l,c,d){let h=n.listPointerStack[l];if(o!==null&&(await r.unaliasKeywords(o,c,l))["@value"]!==null){if(!h||!h.value){const f=r.dataFactory.blankNode();h={value:f,listRootDepth:d,listId:f}}else{const f=r.dataFactory.blankNode();n.emitQuad(l,r.dataFactory.quad(h.value,r.rdfRest,f,r.getDefaultGraph())),h.value=f}a&&n.emitQuad(l,r.dataFactory.quad(h.value,r.rdfFirst,a,r.getDefaultGraph()))}else h||(h={listRootDepth:d,listId:r.rdfNil});n.listPointerStack[l]=h,n.rdfstar&&n.annotationsBuffer[l]&&n.emitError(new e.ErrorCoded("Found an illegal annotation inside a list",e.ERROR_CODES.INVALID_ANNOTATION))}};return Zd.EntryHandlerArrayValue=u,Zd}var uf={},eC;function $K(){if(eC)return uf;eC=1,Object.defineProperty(uf,"__esModule",{value:!0}),uf.EntryHandlerInvalidFallback=void 0;let t=class{isPropertyHandler(){return!1}isStackProcessor(){return!0}async validate(u,s,n,r,a){return!1}async test(u,s,n,r,a){return!0}async handle(u,s,n,r,a,o){u.emittedStack[o]=!1}};return uf.EntryHandlerInvalidFallback=t,uf}var cf={},lf={},tC;function ns(){if(tC)return lf;tC=1,Object.defineProperty(lf,"__esModule",{value:!0}),lf.EntryHandlerKeyword=void 0;let t=class{constructor(u){this.keyword=u}isPropertyHandler(){return!1}isStackProcessor(){return!0}async validate(u,s,n,r,a){return!1}async test(u,s,n,r,a){return n===this.keyword}};return lf.EntryHandlerKeyword=t,lf}var rC;function QK(){if(rC)return cf;rC=1,Object.defineProperty(cf,"__esModule",{value:!0}),cf.EntryHandlerKeywordContext=void 0;const t=Jr(),e=ns();let u=class extends e.EntryHandlerKeyword{constructor(){super("@context")}isStackProcessor(){return!1}async handle(n,r,a,o,l,c){n.streamingProfile&&(n.processingStack[c]||n.processingType[c]||n.idStack[c]!==void 0)&&n.emitError(new t.ErrorCoded("Found an out-of-order context, while streaming is enabled.(disable `streamingProfile`)",t.ERROR_CODES.INVALID_STREAMING_KEY_ORDER));const d=n.getContext(o),h=n.parseContext(l,(await d).getContextRaw());n.contextTree.setContext(o.slice(0,-1),h),n.emitContext(l),await n.validateContext(await h)}};return cf.EntryHandlerKeywordContext=u,cf}var df={},nC;function VK(){if(nC)return df;nC=1,Object.defineProperty(df,"__esModule",{value:!0}),df.EntryHandlerKeywordGraph=void 0;const t=ns();let e=class extends t.EntryHandlerKeyword{constructor(){super("@graph")}async handle(s,n,r,a,o,l){s.graphStack[l+1]=!0}};return df.EntryHandlerKeywordGraph=e,df}var ff={},iC;function kK(){if(iC)return ff;iC=1,Object.defineProperty(ff,"__esModule",{value:!0}),ff.EntryHandlerKeywordId=void 0;const t=Jr(),e=ns();let u=class extends e.EntryHandlerKeyword{constructor(){super("@id")}isStackProcessor(){return!1}async handle(n,r,a,o,l,c){if(typeof l!="string"){if(n.rdfstar&&typeof l=="object"){const h=Object.keys(l);h.length===1&&h[0]==="@id"&&n.emitError(new t.ErrorCoded(`Invalid embedded node without property with @id ${l["@id"]}`,t.ERROR_CODES.INVALID_EMBEDDED_NODE))}else n.emitError(new t.ErrorCoded(`Found illegal @id '${l}'`,t.ERROR_CODES.INVALID_ID_VALUE));return}const d=await r.getPropertiesDepth(o,c);if(n.idStack[d]!==void 0&&(n.idStack[d][0].listHead?n.emitError(new t.ErrorCoded(`Found illegal neighbouring entries next to @list for key: '${o[c-1]}'`,t.ERROR_CODES.INVALID_SET_OR_LIST_OBJECT)):n.emitError(new t.ErrorCoded(`Found duplicate @ids '${n.idStack[d][0].value}' and '${l}'`,t.ERROR_CODES.COLLIDING_KEYWORDS))),n.rdfstar&&n.annotationsBuffer[c])for(const h of n.annotationsBuffer[c])h.depth===c&&n.emitError(new t.ErrorCoded(`Found an illegal @id inside an annotation: ${l}`,t.ERROR_CODES.INVALID_ANNOTATION));n.idStack[d]=r.nullableTermToArray(await r.resourceToTerm(await n.getContext(o),l))}};return ff.EntryHandlerKeywordId=u,ff}var hf={},aC;function zK(){if(aC)return hf;aC=1,Object.defineProperty(hf,"__esModule",{value:!0}),hf.EntryHandlerKeywordIncluded=void 0;const t=Jr(),e=ns();let u=class extends e.EntryHandlerKeyword{constructor(){super("@included")}async handle(n,r,a,o,l,c){typeof l!="object"&&n.emitError(new t.ErrorCoded(`Found illegal @included '${l}'`,t.ERROR_CODES.INVALID_INCLUDED_VALUE));const d=await r.unaliasKeywords(l,o,c,await n.getContext(o));"@value"in d&&n.emitError(new t.ErrorCoded(`Found an illegal @included @value node '${JSON.stringify(l)}'`,t.ERROR_CODES.INVALID_INCLUDED_VALUE)),"@list"in d&&n.emitError(new t.ErrorCoded(`Found an illegal @included @list node '${JSON.stringify(l)}'`,t.ERROR_CODES.INVALID_INCLUDED_VALUE)),n.emittedStack[c]=!1}};return hf.EntryHandlerKeywordIncluded=u,hf}var pf={},sC;function GK(){if(sC)return pf;sC=1,Object.defineProperty(pf,"__esModule",{value:!0}),pf.EntryHandlerKeywordNest=void 0;const t=Jr(),e=ns();let u=class extends e.EntryHandlerKeyword{constructor(){super("@nest")}async handle(n,r,a,o,l,c){typeof l!="object"&&n.emitError(new t.ErrorCoded(`Found invalid @nest entry for '${a}': '${l}'`,t.ERROR_CODES.INVALID_NEST_VALUE)),"@value"in await r.unaliasKeywords(l,o,c,await n.getContext(o))&&n.emitError(new t.ErrorCoded(`Found an invalid @value node for '${a}'`,t.ERROR_CODES.INVALID_NEST_VALUE)),n.emittedStack[c]=!1}};return pf.EntryHandlerKeywordNest=u,pf}var yf={},oC;function WK(){if(oC)return yf;oC=1,Object.defineProperty(yf,"__esModule",{value:!0}),yf.EntryHandlerKeywordType=void 0;const t=Jr(),e=to(),u=Gb(),s=ns();let n=class extends s.EntryHandlerKeyword{constructor(){super("@type")}isStackProcessor(){return!1}async handle(a,o,l,c,d,h){const f=c[h],p=await a.getContext(c),y=o.rdfType,b=await o.unaliasKeywordParent(c,h),m=e.Util.isPropertyReverse(p,f,b),g=e.Util.isPropertyInEmbeddedNode(b);o.validateReverseInEmbeddedNode(l,m,g);const v=e.Util.isPropertyInAnnotationObject(b),_=Array.isArray(d)?d:[d];for(const A of _){typeof A!="string"&&a.emitError(new t.ErrorCoded(`Found illegal @type '${A}'`,t.ERROR_CODES.INVALID_TYPE_VALUE));const D=o.createVocabOrBaseTerm(p,A);D&&await u.EntryHandlerPredicate.handlePredicateObject(a,o,c,h,y,D,m,g,v)}let w=Promise.resolve(p),S=!1;for(const A of _.sort()){const D=e.Util.getContextValue(p,"@context",A,null);D&&(S=!0,w=w.then(L=>a.parseContext(D,L.getContextRaw())))}a.streamingProfile&&(S||!a.streamingProfileAllowOutOfOrderPlainType)&&(a.processingStack[h]||a.idStack[h])&&a.emitError(new t.ErrorCoded("Found an out-of-order type-scoped context, while streaming is enabled.(disable `streamingProfile`)",t.ERROR_CODES.INVALID_STREAMING_KEY_ORDER)),S&&(w=w.then(A=>A.getContextRaw()["@propagate"]!==!0?new t.JsonLdContextNormalized(Object.assign(Object.assign({},A.getContextRaw()),{"@propagate":!1,"@__propagateFallback":p.getContextRaw()})):A),a.contextTree.setContext(c.slice(0,c.length-1),w)),a.processingType[h]=!0}};return yf.EntryHandlerKeywordType=n,yf}var bf={},uC;function JK(){if(uC)return bf;uC=1,Object.defineProperty(bf,"__esModule",{value:!0}),bf.EntryHandlerKeywordUnknownFallback=void 0;const t=Jr();let e=class o7{isPropertyHandler(){return!1}isStackProcessor(){return!0}async validate(s,n,r,a,o){const l=await n.unaliasKeyword(r[a],r,a);return t.Util.isPotentialKeyword(l)?!(!o&&l==="@list"):!1}async test(s,n,r,a,o){return t.Util.isPotentialKeyword(r)}async handle(s,n,r,a,o,l){const c=o7.VALID_KEYWORDS_TYPES[r];c!==void 0?c&&typeof o!==c.type&&s.emitError(new t.ErrorCoded(`Invalid value type for '${r}' with value '${o}'`,c.errorCode)):s.strictValues&&s.emitError(new Error(`Unknown keyword '${r}' with value '${o}'`)),s.emittedStack[l]=!1}};return e.VALID_KEYWORDS_TYPES={"@index":{type:"string",errorCode:t.ERROR_CODES.INVALID_INDEX_VALUE},"@list":null,"@reverse":{type:"object",errorCode:t.ERROR_CODES.INVALID_REVERSE_VALUE},"@set":null,"@value":null},bf.EntryHandlerKeywordUnknownFallback=e,bf}var gf={},cC;function XK(){if(cC)return gf;cC=1,Object.defineProperty(gf,"__esModule",{value:!0}),gf.EntryHandlerKeywordValue=void 0;const t=ns();let e=class extends t.EntryHandlerKeyword{constructor(){super("@value")}async validate(s,n,r,a,o){const l=r[a];return l&&!s.literalStack[a]&&await this.test(s,n,l,r,a)&&(s.literalStack[a]=!0),super.validate(s,n,r,a,o)}async test(s,n,r,a,o){return await n.unaliasKeyword(a[o],a.slice(0,a.length-1),o-1,!0)==="@value"}async handle(s,n,r,a,o,l){s.literalStack[l]=!0,delete s.unidentifiedValuesBuffer[l],delete s.unidentifiedGraphsBuffer[l],s.emittedStack[l]=!1}};return gf.EntryHandlerKeywordValue=e,gf}var mf={},_f={},lC;function KK(){if(lC)return _f;lC=1,Object.defineProperty(_f,"__esModule",{value:!0}),_f.ContextTree=void 0;let t=class u7{constructor(){this.subTrees={}}getContext(u){if(u.length>0){const[s,...n]=u,r=this.subTrees[s];if(r){const a=r.getContext(n);if(a)return a.then(({context:o,depth:l})=>({context:o,depth:l+1}))}}return this.context?this.context.then(s=>({context:s,depth:0})):null}setContext(u,s){if(u.length===0)this.context=s;else{const[n,...r]=u;let a=this.subTrees[n];a||(a=this.subTrees[n]=new u7),a.setContext(r,s)}}removeContext(u){this.setContext(u,null)}};return _f.ContextTree=t,_f}var dC;function YK(){if(dC)return mf;dC=1,Object.defineProperty(mf,"__esModule",{value:!0}),mf.ParsingContext=void 0;const t=Jr(),e=Ay(),u=KK(),s=l7();let n=class c7{constructor(a){this.contextParser=new t.ContextParser({documentLoader:a.documentLoader,skipValidation:a.skipContextValidation}),this.streamingProfile=!!a.streamingProfile,this.baseIRI=a.baseIRI,this.produceGeneralizedRdf=!!a.produceGeneralizedRdf,this.allowSubjectList=!!a.allowSubjectList,this.processingMode=a.processingMode||s.JsonLdParser.DEFAULT_PROCESSING_MODE,this.strictValues=!!a.strictValues,this.validateValueIndexes=!!a.validateValueIndexes,this.defaultGraph=a.defaultGraph,this.rdfDirection=a.rdfDirection,this.normalizeLanguageTags=a.normalizeLanguageTags,this.streamingProfileAllowOutOfOrderPlainType=a.streamingProfileAllowOutOfOrderPlainType,this.rdfstar=a.rdfstar!==!1,this.rdfstarReverseInEmbedded=a.rdfstarReverseInEmbedded,this.topLevelProperties=!1,this.activeProcessingMode=parseFloat(this.processingMode),this.processingStack=[],this.processingType=[],this.emittedStack=[],this.idStack=[],this.graphStack=[],this.graphContainerTermStack=[],this.listPointerStack=[],this.contextTree=new u.ContextTree,this.literalStack=[],this.validationStack=[],this.unaliasedKeywordCacheStack=[],this.jsonLiteralStack=[],this.unidentifiedValuesBuffer=[],this.unidentifiedGraphsBuffer=[],this.annotationsBuffer=[],this.pendingContainerFlushBuffers=[],this.parser=a.parser,a.context?(this.rootContext=this.parseContext(a.context),this.rootContext.then(o=>this.validateContext(o))):this.rootContext=Promise.resolve(new t.JsonLdContextNormalized(this.baseIRI?{"@base":this.baseIRI,"@__baseDocument":!0}:{}))}async parseContext(a,o,l){return this.contextParser.parse(a,{baseIRI:this.baseIRI,ignoreProtection:l,normalizeLanguageTags:this.normalizeLanguageTags,parentContext:o,processingMode:this.activeProcessingMode})}validateContext(a){const o=a.getContextRaw()["@version"];if(o){if(this.activeProcessingMode&&o>this.activeProcessingMode)throw new e.ErrorCoded(`Unsupported JSON-LD version '${o}' under active processing mode ${this.activeProcessingMode}.`,e.ERROR_CODES.PROCESSING_MODE_CONFLICT);if(this.activeProcessingMode&&o0&&l.context.getContextRaw()["@propagate"]===!1&&l.depth!==o&&!c);return l.depth===0&&l.context.getContextRaw()["@propagate"]===!1&&l.depth!==o&&(l.context=new t.JsonLdContextNormalized({})),l}async newOnValueJob(a,o,l,c){await this.parser.newOnValueJob(a,o,l,c)}async handlePendingContainerFlushBuffers(){if(this.pendingContainerFlushBuffers.length>0){for(const a of this.pendingContainerFlushBuffers)await this.parser.flushBuffer(a.depth,a.keys),this.parser.flushStacks(a.depth);return this.pendingContainerFlushBuffers.splice(0,this.pendingContainerFlushBuffers.length),!0}else return!1}emitQuad(a,o){a===1&&(this.topLevelProperties=!0),this.parser.push(o)}emitError(a){this.parser.emit("error",a)}emitContext(a){this.parser.emit("context",a)}getUnidentifiedValueBufferSafe(a){let o=this.unidentifiedValuesBuffer[a];return o||(o=[],this.unidentifiedValuesBuffer[a]=o),o}getUnidentifiedGraphBufferSafe(a){let o=this.unidentifiedGraphsBuffer[a];return o||(o=[],this.unidentifiedGraphsBuffer[a]=o),o}getAnnotationsBufferSafe(a){let o=this.annotationsBuffer[a];return o||(o=[],this.annotationsBuffer[a]=o),o}getExpandOptions(){return c7.EXPAND_OPTIONS[this.activeProcessingMode]}shiftStack(a,o){const l=this.idStack[a+o];if(l&&(this.idStack[a]=l,this.emittedStack[a]=!0,delete this.idStack[a+o]),this.pendingContainerFlushBuffers.length)for(const c of this.pendingContainerFlushBuffers)c.depth>=a+o&&(c.depth-=o,c.keys.splice(a,o));this.unidentifiedValuesBuffer[a+o]&&(this.unidentifiedValuesBuffer[a]=this.unidentifiedValuesBuffer[a+o],delete this.unidentifiedValuesBuffer[a+o]),this.annotationsBuffer[a+o-1]&&(this.annotationsBuffer[a-1]||(this.annotationsBuffer[a-1]=[]),this.annotationsBuffer[a-1]=[...this.annotationsBuffer[a-1],...this.annotationsBuffer[a+o-1]],delete this.annotationsBuffer[a+o-1])}};return n.EXPAND_OPTIONS={1:{allowPrefixForcing:!1,allowPrefixNonGenDelims:!1,allowVocabRelativeToBase:!1},1.1:{allowPrefixForcing:!0,allowPrefixNonGenDelims:!1,allowVocabRelativeToBase:!0}},mf.ParsingContext=n,mf}var vf={},fC;function ZK(){if(fC)return vf;fC=1,Object.defineProperty(vf,"__esModule",{value:!0}),vf.EntryHandlerKeywordAnnotation=void 0;const t=ns(),e=Jr();let u=class extends t.EntryHandlerKeyword{constructor(){super("@annotation")}async handle(n,r,a,o,l,c){(typeof l=="string"||typeof l=="object"&&l["@value"])&&n.emitError(new e.ErrorCoded(`Found illegal annotation value: ${JSON.stringify(l)}`,e.ERROR_CODES.INVALID_ANNOTATION))}};return vf.EntryHandlerKeywordAnnotation=u,vf}var hC;function l7(){if(hC)return Yd;hC=1,Object.defineProperty(Yd,"__esModule",{value:!0}),Yd.JsonLdParser=void 0;const t=Eq(),e=Jr(),u=Wt(),s=HK(),n=s7(),r=$K(),a=Gb(),o=QK(),l=VK(),c=kK(),d=zK(),h=GK(),f=WK(),p=JK(),y=XK(),b=YK(),m=to(),g=lq(),v=ZK();let _=class wo extends u.Transform{constructor(S){super({readableObjectMode:!0}),S=S||{},this.options=S,this.parsingContext=new b.ParsingContext(Object.assign({parser:this},S)),this.util=new m.Util({dataFactory:S.dataFactory,parsingContext:this.parsingContext}),this.jsonParser=new t,this.contextJobs=[],this.typeJobs=[],this.contextAwaitingJobs=[],this.lastDepth=0,this.lastKeys=[],this.lastOnValueJob=Promise.resolve(),this.attachJsonParserListeners(),this.on("end",()=>{typeof this.jsonParser.mode<"u"&&this.emit("error",new Error("Unclosed document"))})}static fromHttpResponse(S,A,D,L){let E,O=["application/activity+json"];if(L&&L.wellKnownMediaTypes&&(O=L.wellKnownMediaTypes),A!=="application/ld+json"&&!O.includes(A)){if(A!=="application/json"&&!A.endsWith("+json"))throw new e.ErrorCoded(`Unsupported JSON-LD media type ${A}`,e.ERROR_CODES.LOADING_DOCUMENT_FAILED);if(D&&D.has("Link")&&D.forEach((j,U)=>{if(U==="link"){const M=(0,g.parse)(j);for(const q of M.get("rel","http://www.w3.org/ns/json-ld#context")){if(E)throw new e.ErrorCoded("Multiple JSON-LD context link headers were found on "+S,e.ERROR_CODES.MULTIPLE_CONTEXT_LINK_HEADERS);E=q.uri}}}),!E&&!(L!=null&&L.ignoreMissingContextLinkHeader))throw new e.ErrorCoded(`Missing context link header for media type ${A} on ${S}`,e.ERROR_CODES.LOADING_DOCUMENT_FAILED)}let P;if(D&&D.has("Content-Type")){const j=D.get("Content-Type"),U=/; *profile=([^"]*)/.exec(j);U&&U[1]==="http://www.w3.org/ns/json-ld#streaming"&&(P=!0)}return new wo(Object.assign({baseIRI:S,context:E,streamingProfile:P},L||{}))}import(S){if("pipe"in S){S.on("error",D=>A.emit("error",D));const A=S.pipe(new wo(this.options));return A}else{const A=new u.PassThrough({readableObjectMode:!0});S.on("error",L=>D.emit("error",L)),S.on("data",L=>A.push(L)),S.on("end",()=>A.push(null));const D=A.pipe(new wo(this.options));return D}}_transform(S,A,D){this.jsonParser.write(S),this.lastOnValueJob.then(()=>D(),L=>D(L))}async newOnValueJob(S,A,D,L){let E=!0;if(L&&D1&&(U=this.parsingContext.validationStack[this.parsingContext.validationStack.length-1].property);for(let M=Math.max(1,this.parsingContext.validationStack.length-1);M=0?this.parsingContext.idStack[S-U-1]:[await this.util.getGraphContainerValue(A,S)];if(M)for(const q of M){this.parsingContext.emittedStack[S]=!0;for(const Q of E)this.util.emitQuadChecked(S,j,Q.predicate,Q.object,q,Q.reverse,Q.isEmbedded)}else{const q=this.parsingContext.getUnidentifiedGraphBufferSafe(S-await this.util.getDepthOffsetGraph(S,A)-1);for(const Q of E)Q.reverse?q.push({object:j,predicate:Q.predicate,subject:Q.object,isEmbedded:Q.isEmbedded}):q.push({object:Q.object,predicate:Q.predicate,subject:j,isEmbedded:Q.isEmbedded})}}this.parsingContext.unidentifiedValuesBuffer.splice(S,1),this.parsingContext.literalStack.splice(S,1),this.parsingContext.jsonLiteralStack.splice(S,1)}const O=this.parsingContext.unidentifiedGraphsBuffer[S];if(O){for(const j of D){const U=S===1&&j.termType==="BlankNode"&&!this.parsingContext.topLevelProperties?this.util.getDefaultGraph():j;this.parsingContext.emittedStack[S]=!0;for(const M of O)this.parsingContext.emitQuad(S,this.util.dataFactory.quad(M.subject,M.predicate,M.object,U))}this.parsingContext.unidentifiedGraphsBuffer.splice(S,1)}const P=this.parsingContext.annotationsBuffer[S];if(P){P.length>0&&S===1&&this.parsingContext.emitError(new e.ErrorCoded("Annotations can not be made on top-level nodes",e.ERROR_CODES.INVALID_ANNOTATION));const j=this.parsingContext.getAnnotationsBufferSafe(S-1);for(const U of P)j.push(U);delete this.parsingContext.annotationsBuffer[S]}}async validateKey(S,A,D){for(const L of wo.ENTRY_HANDLERS)if(await L.validate(this.parsingContext,this.util,S,A,D))return{valid:!0,property:D||L.isPropertyHandler()};return{valid:!1,property:!1}}attachJsonParserListeners(){this.jsonParser.onValue=S=>{const A=this.jsonParser.stack.length,D=new Array(A+1).fill(0).map((L,E)=>E===A?this.jsonParser.key:this.jsonParser.stack[E].key);if(!this.isParsingContextInner(A)){const L=()=>this.newOnValueJob(D,S,A,!0);if(!this.parsingContext.streamingProfile&&!this.parsingContext.contextTree.getContext(D.slice(0,-1)))if(D[A]==="@context"){let E=this.contextJobs[A];E||(E=this.contextJobs[A]=[]),E.push(L)}else this.contextAwaitingJobs.push({job:L,keys:D,depth:A});else this.lastOnValueJob=this.lastOnValueJob.then(L);!this.parsingContext.streamingProfile&&A===0&&(this.lastOnValueJob=this.lastOnValueJob.then(()=>this.executeBufferedJobs()))}},this.jsonParser.onError=S=>{this.emit("error",S)}}isParsingContextInner(S){for(let A=S;A>0;A--)if(this.jsonParser.stack[A-1].key==="@context")return!0;return!1}async executeBufferedJobs(){for(const A of this.contextJobs)if(A)for(const D of A)await D();this.parsingContext.unaliasedKeywordCacheStack.splice(0);const S=[];for(const A of this.contextAwaitingJobs)await this.util.unaliasKeyword(A.keys[A.depth],A.keys,A.depth,!0)==="@type"||typeof A.keys[A.depth]=="number"&&await this.util.unaliasKeyword(A.keys[A.depth-1],A.keys,A.depth-1,!0)==="@type"?this.typeJobs.push({job:A.job,keys:A.keys.slice(0,A.keys.length-1)}):S.push(A);for(const A of S){if(this.typeJobs.length>0){const D=[],L=[];for(let P=0;PP.keys.length-j.keys.length);for(const P of E)await P.job();const O=L.sort().reverse();for(const P of O)this.typeJobs.splice(P,1)}await A.job()}}};return _.DEFAULT_PROCESSING_MODE="1.1",_.ENTRY_HANDLERS=[new s.EntryHandlerArrayValue,new o.EntryHandlerKeywordContext,new c.EntryHandlerKeywordId,new d.EntryHandlerKeywordIncluded,new l.EntryHandlerKeywordGraph,new h.EntryHandlerKeywordNest,new f.EntryHandlerKeywordType,new y.EntryHandlerKeywordValue,new v.EntryHandlerKeywordAnnotation,new n.EntryHandlerContainer,new p.EntryHandlerKeywordUnknownFallback,new a.EntryHandlerPredicate,new r.EntryHandlerInvalidFallback],Yd.JsonLdParser=_,Yd}var pC;function eY(){return pC||(pC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(l7(),t)}(G2)),G2}var wf={},yC;function f7(){if(yC)return wf;yC=1,Object.defineProperty(wf,"__esModule",{value:!0}),wf.DocumentLoaderMediated=void 0;const t=rs(),e=Jr(),u=eo();let s=class d7 extends e.FetchDocumentLoader{constructor(r,a){super(d7.createFetcher(r,a)),this.mediatorHttp=r,this.context=a}static createFetcher(r,a){return async(o,l)=>{const c=await r.mediate({input:o,init:l,context:a});return c.json=async()=>JSON.parse(await u(t.ActorHttp.toNodeReadable(c.body))),c}}};return wf.DocumentLoaderMediated=s,wf}var bC;function tY(){if(bC)return Kd;bC=1,Object.defineProperty(Kd,"__esModule",{value:!0}),Kd.ActorRdfParseJsonLd=void 0;const t=au(),e=Lt,u=eY(),s=f7();let n=class extends t.ActorRdfParseFixedMediaTypes{constructor(a){super(a)}async testHandle(a,o,l){if(l.has(e.KeysRdfParseHtmlScript.processingHtmlScript)&&o!=="application/ld+json")throw new Error("JSON-LD in script tags can only have media type 'application/ld+json'");if(!o||!(o in this.mediaTypePriorities||o.endsWith("+json")))throw new Error(`Unrecognized media type: ${o}`);return await this.testHandleChecked(a)}async runHandle(a,o,l){var h;return{data:u.JsonLdParser.fromHttpResponse(((h=a.metadata)==null?void 0:h.baseIRI)??"",o,a.headers,{documentLoader:l.get(e.KeysRdfParseJsonLd.documentLoader)??new s.DocumentLoaderMediated(this.mediatorHttp,l),strictValues:l.get(e.KeysRdfParseJsonLd.strictValues),...l.get(e.KeysRdfParseJsonLd.parserOptions)}).import(a.data)}}};return Kd.ActorRdfParseJsonLd=n,Kd}var gC;function rY(){return gC||(gC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(tY(),t),u(f7(),t)}(z2)),z2}var J2={},Sf={},X2={},Tf={},mC;function nY(){if(mC)return Tf;mC=1,Object.defineProperty(Tf,"__esModule",{value:!0}),Tf.ActorRdfUpdateHypermedia=void 0;const t=ot;let e=class extends t.Actor{constructor(s,n){super(s),this.destinationType=n}async test(s){if(s.forceDestinationType&&this.destinationType!==s.forceDestinationType)throw new Error(`Actor ${this.name} is not able to handle destination type ${s.forceDestinationType}.`);return this.testMetadata(s)}};return Tf.ActorRdfUpdateHypermedia=e,Tf}var _C;function ZT(){return _C||(_C=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(nY(),t)}(X2)),X2}var Af={},E1={exports:{}},vC;function eA(){return vC||(vC=1,function(t,e){var u=typeof globalThis<"u"&&globalThis||typeof self<"u"&&self||typeof I<"u"&&I,s=function(){function r(){this.fetch=!1,this.DOMException=u.DOMException}return r.prototype=u,new r}();(function(r){(function(a){var o=typeof r<"u"&&r||typeof self<"u"&&self||typeof o<"u"&&o,l={searchParams:"URLSearchParams"in o,iterable:"Symbol"in o&&"iterator"in Symbol,blob:"FileReader"in o&&"Blob"in o&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in o,arrayBuffer:"ArrayBuffer"in o};function c(q){return q&&DataView.prototype.isPrototypeOf(q)}if(l.arrayBuffer)var d=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],h=ArrayBuffer.isView||function(q){return q&&d.indexOf(Object.prototype.toString.call(q))>-1};function f(q){if(typeof q!="string"&&(q=String(q)),/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(q)||q==="")throw new TypeError('Invalid character in header field name: "'+q+'"');return q.toLowerCase()}function p(q){return typeof q!="string"&&(q=String(q)),q}function y(q){var Q={next:function(){var Z=q.shift();return{done:Z===void 0,value:Z}}};return l.iterable&&(Q[Symbol.iterator]=function(){return Q}),Q}function b(q){this.map={},q instanceof b?q.forEach(function(Q,Z){this.append(Z,Q)},this):Array.isArray(q)?q.forEach(function(Q){this.append(Q[0],Q[1])},this):q&&Object.getOwnPropertyNames(q).forEach(function(Q){this.append(Q,q[Q])},this)}b.prototype.append=function(q,Q){q=f(q),Q=p(Q);var Z=this.map[q];this.map[q]=Z?Z+", "+Q:Q},b.prototype.delete=function(q){delete this.map[f(q)]},b.prototype.get=function(q){return q=f(q),this.has(q)?this.map[q]:null},b.prototype.has=function(q){return this.map.hasOwnProperty(f(q))},b.prototype.set=function(q,Q){this.map[f(q)]=p(Q)},b.prototype.forEach=function(q,Q){for(var Z in this.map)this.map.hasOwnProperty(Z)&&q.call(Q,this.map[Z],Z,this)},b.prototype.keys=function(){var q=[];return this.forEach(function(Q,Z){q.push(Z)}),y(q)},b.prototype.values=function(){var q=[];return this.forEach(function(Q){q.push(Q)}),y(q)},b.prototype.entries=function(){var q=[];return this.forEach(function(Q,Z){q.push([Z,Q])}),y(q)},l.iterable&&(b.prototype[Symbol.iterator]=b.prototype.entries);function m(q){if(q.bodyUsed)return Promise.reject(new TypeError("Already read"));q.bodyUsed=!0}function g(q){return new Promise(function(Q,Z){q.onload=function(){Q(q.result)},q.onerror=function(){Z(q.error)}})}function v(q){var Q=new FileReader,Z=g(Q);return Q.readAsArrayBuffer(q),Z}function _(q){var Q=new FileReader,Z=g(Q);return Q.readAsText(q),Z}function w(q){for(var Q=new Uint8Array(q),Z=new Array(Q.length),K=0;K-1?Q:q}function E(q,Q){if(!(this instanceof E))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');Q=Q||{};var Z=Q.body;if(q instanceof E){if(q.bodyUsed)throw new TypeError("Already read");this.url=q.url,this.credentials=q.credentials,Q.headers||(this.headers=new b(q.headers)),this.method=q.method,this.mode=q.mode,this.signal=q.signal,!Z&&q._bodyInit!=null&&(Z=q._bodyInit,q.bodyUsed=!0)}else this.url=String(q);if(this.credentials=Q.credentials||this.credentials||"same-origin",(Q.headers||!this.headers)&&(this.headers=new b(Q.headers)),this.method=L(Q.method||this.method||"GET"),this.mode=Q.mode||this.mode||null,this.signal=Q.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&Z)throw new TypeError("Body not allowed for GET or HEAD requests");if(this._initBody(Z),(this.method==="GET"||this.method==="HEAD")&&(Q.cache==="no-store"||Q.cache==="no-cache")){var K=/([?&])_=[^&]*/;if(K.test(this.url))this.url=this.url.replace(K,"$1_="+new Date().getTime());else{var fe=/\?/;this.url+=(fe.test(this.url)?"&":"?")+"_="+new Date().getTime()}}}E.prototype.clone=function(){return new E(this,{body:this._bodyInit})};function O(q){var Q=new FormData;return q.trim().split("&").forEach(function(Z){if(Z){var K=Z.split("="),fe=K.shift().replace(/\+/g," "),X=K.join("=").replace(/\+/g," ");Q.append(decodeURIComponent(fe),decodeURIComponent(X))}}),Q}function P(q){var Q=new b,Z=q.replace(/\r?\n[\t ]+/g," ");return Z.split("\r").map(function(K){return K.indexOf(` -`)===0?K.substr(1,K.length):K}).forEach(function(K){var fe=K.split(":"),X=fe.shift().trim();if(X){var he=fe.join(":").trim();Q.append(X,he)}}),Q}A.call(E.prototype);function j(q,Q){if(!(this instanceof j))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');Q||(Q={}),this.type="default",this.status=Q.status===void 0?200:Q.status,this.ok=this.status>=200&&this.status<300,this.statusText=Q.statusText===void 0?"":""+Q.statusText,this.headers=new b(Q.headers),this.url=Q.url||"",this._initBody(q)}A.call(j.prototype),j.prototype.clone=function(){return new j(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new b(this.headers),url:this.url})},j.error=function(){var q=new j(null,{status:0,statusText:""});return q.type="error",q};var U=[301,302,303,307,308];j.redirect=function(q,Q){if(U.indexOf(Q)===-1)throw new RangeError("Invalid status code");return new j(null,{status:Q,headers:{location:q}})},a.DOMException=o.DOMException;try{new a.DOMException}catch{a.DOMException=function(Q,Z){this.message=Q,this.name=Z;var K=Error(Q);this.stack=K.stack},a.DOMException.prototype=Object.create(Error.prototype),a.DOMException.prototype.constructor=a.DOMException}function M(q,Q){return new Promise(function(Z,K){var fe=new E(q,Q);if(fe.signal&&fe.signal.aborted)return K(new a.DOMException("Aborted","AbortError"));var X=new XMLHttpRequest;function he(){X.abort()}X.onload=function(){var ie={status:X.status,statusText:X.statusText,headers:P(X.getAllResponseHeaders()||"")};ie.url="responseURL"in X?X.responseURL:ie.headers.get("X-Request-URL");var ae="response"in X?X.response:X.responseText;setTimeout(function(){Z(new j(ae,ie))},0)},X.onerror=function(){setTimeout(function(){K(new TypeError("Network request failed"))},0)},X.ontimeout=function(){setTimeout(function(){K(new TypeError("Network request failed"))},0)},X.onabort=function(){setTimeout(function(){K(new a.DOMException("Aborted","AbortError"))},0)};function xe(ie){try{return ie===""&&o.location.href?o.location.href:ie}catch{return ie}}X.open(fe.method,xe(fe.url),!0),fe.credentials==="include"?X.withCredentials=!0:fe.credentials==="omit"&&(X.withCredentials=!1),"responseType"in X&&(l.blob?X.responseType="blob":l.arrayBuffer&&fe.headers.get("Content-Type")&&fe.headers.get("Content-Type").indexOf("application/octet-stream")!==-1&&(X.responseType="arraybuffer")),Q&&typeof Q.headers=="object"&&!(Q.headers instanceof b)?Object.getOwnPropertyNames(Q.headers).forEach(function(ie){X.setRequestHeader(ie,p(Q.headers[ie]))}):fe.headers.forEach(function(ie,ae){X.setRequestHeader(ae,ie)}),fe.signal&&(fe.signal.addEventListener("abort",he),X.onreadystatechange=function(){X.readyState===4&&fe.signal.removeEventListener("abort",he)}),X.send(typeof fe._bodyInit>"u"?null:fe._bodyInit)})}return M.polyfill=!0,o.fetch||(o.fetch=M,o.Headers=b,o.Request=E,o.Response=j),a.Headers=b,a.Request=E,a.Response=j,a.fetch=M,a})({})})(s),s.fetch.ponyfill=!0,delete s.fetch.polyfill;var n=u.fetch?u:s;e=n.fetch,e.default=n.fetch,e.fetch=n.fetch,e.Headers=n.Headers,e.Request=n.Request,e.Response=n.Response,t.exports=e}(E1,E1.exports)),E1.exports}var wC;function h7(){if(wC)return Af;wC=1,Object.defineProperty(Af,"__esModule",{value:!0}),Af.QuadDestinationPatchSparqlUpdate=void 0;const t=rs(),e=eA(),u=Oy(),s=Wt();let n=class{constructor(a,o,l){this.url=a,this.context=o,this.mediatorHttp=l}insert(a){return this.wrapSparqlUpdateRequest("INSERT",a)}async delete(a){return this.wrapSparqlUpdateRequest("DELETE",a)}async wrapSparqlUpdateRequest(a,o){const l=o.map(f=>{let p=`${(0,u.termToString)(f.subject)} ${(0,u.termToString)(f.predicate)} ${(0,u.termToString)(f.object)} .`;return f.graph.termType==="DefaultGraph"?p=` ${p} -`:p=` GRAPH ${(0,u.termToString)(f.graph)} { ${p} } -`,p}).prepend([`${a} DATA { -`]).append(["}"]),c=new s.Readable;c.wrap(l);const d=new e.Headers({"content-type":"application/sparql-update"}),h=await this.mediatorHttp.mediate({context:this.context,init:{headers:d,method:"PATCH",body:t.ActorHttp.toWebReadableStream(c)},input:this.url});await(0,t.validateAndCloseHttpResponse)(this.url,h)}async deleteGraphs(a,o,l){throw new Error("Patch-based SPARQL Update destinations don't support named graphs")}async createGraphs(a,o){throw new Error("Patch-based SPARQL Update destinations don't support named graphs")}};return Af.QuadDestinationPatchSparqlUpdate=n,Af}var SC;function iY(){if(SC)return Sf;SC=1,Object.defineProperty(Sf,"__esModule",{value:!0}),Sf.ActorRdfUpdateHypermediaPatchSparqlUpdate=void 0;const t=ZT(),e=h7();let u=class extends t.ActorRdfUpdateHypermedia{constructor(n){super(n,"patchSparqlUpdate")}async testMetadata(n){if(!n.forceDestinationType&&!n.metadata.patchSparqlUpdate)throw new Error(`Actor ${this.name} could not detect a destination with 'application/sparql-update' as 'Accept-Patch' header.`);if(!n.forceDestinationType&&!n.exists)throw new Error(`Actor ${this.name} can only patch a destination that already exists.`);return!0}async run(n){return this.logInfo(n.context,`Identified as patchSparqlUpdate destination: ${n.url}`),{destination:new e.QuadDestinationPatchSparqlUpdate(n.url,n.context,this.mediatorHttp)}}};return Sf.ActorRdfUpdateHypermediaPatchSparqlUpdate=u,Sf}var TC;function aY(){return TC||(TC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(iY(),t),u(h7(),t)}(J2)),J2}var K2={},Ef={},Of={},AC;function p7(){if(AC)return Of;AC=1,Object.defineProperty(Of,"__esModule",{value:!0}),Of.QuadDestinationPutLdp=void 0;const t=rs(),e=eA();let u=class{constructor(n,r,a,o,l,c){this.url=n,this.context=r,this.mediaTypes=a,this.mediatorHttp=o,this.mediatorRdfSerializeMediatypes=l,this.mediatorRdfSerialize=c}insert(n){return this.wrapRdfUpdateRequest("INSERT",n)}async delete(n){throw new Error("Put-based LDP destinations don't support deletions")}async wrapRdfUpdateRequest(n,r){const{mediaTypes:a}=await this.mediatorRdfSerializeMediatypes.mediate({context:this.context,mediaTypes:!0}),o=this.mediaTypes.filter(f=>f in a),l=o.length>0?o[0]:Object.keys(a).sort((f,p)=>a[p]-a[f])[0],{handle:{data:c}}=await this.mediatorRdfSerialize.mediate({context:this.context,handle:{quadStream:r,context:this.context},handleMediaType:l}),d=new e.Headers({"content-type":l}),h=await this.mediatorHttp.mediate({context:this.context,init:{headers:d,method:"PUT",body:t.ActorHttp.toWebReadableStream(c)},input:this.url});await(0,t.validateAndCloseHttpResponse)(this.url,h)}async deleteGraphs(n,r,a){throw new Error("Put-based LDP destinations don't support named graphs")}async createGraphs(n,r){throw new Error("Put-based LDP destinations don't support named graphs")}};return Of.QuadDestinationPutLdp=u,Of}var EC;function sY(){if(EC)return Ef;EC=1,Object.defineProperty(Ef,"__esModule",{value:!0}),Ef.ActorRdfUpdateHypermediaPutLdp=void 0;const t=ZT(),e=p7();let u=class extends t.ActorRdfUpdateHypermedia{constructor(n){super(n,"putLdp")}async testMetadata(n){if(!n.forceDestinationType){if(!n.metadata.allowHttpMethods||!n.metadata.allowHttpMethods.includes("PUT"))throw new Error(`Actor ${this.name} could not detect a destination with 'Allow: PUT' header.`);if(n.exists)throw new Error(`Actor ${this.name} can only put on a destination that does not already exists.`)}return!0}async run(n){return this.logInfo(n.context,`Identified as putLdp destination: ${n.url}`),{destination:new e.QuadDestinationPutLdp(n.url,n.context,n.metadata.putAccepted||[],this.mediatorHttp,this.mediatorRdfSerializeMediatypes,this.mediatorRdfSerialize)}}};return Ef.ActorRdfUpdateHypermediaPutLdp=u,Ef}var OC;function oY(){return OC||(OC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(sY(),t),u(p7(),t)}(K2)),K2}var Y2={},Rf={},xf={},Z2={},If={},RC={},xC;function uY(){return xC||(xC=1,function(){(function(t){(function(e){var u={searchParams:"URLSearchParams"in t,iterable:"Symbol"in t&&"iterator"in Symbol,blob:"FileReader"in t&&"Blob"in t&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in t,arrayBuffer:"ArrayBuffer"in t};function s(E){return E&&DataView.prototype.isPrototypeOf(E)}if(u.arrayBuffer)var n=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],r=ArrayBuffer.isView||function(E){return E&&n.indexOf(Object.prototype.toString.call(E))>-1};function a(E){if(typeof E!="string"&&(E=String(E)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(E))throw new TypeError("Invalid character in header field name");return E.toLowerCase()}function o(E){return typeof E!="string"&&(E=String(E)),E}function l(E){var O={next:function(){var P=E.shift();return{done:P===void 0,value:P}}};return u.iterable&&(O[Symbol.iterator]=function(){return O}),O}function c(E){this.map={},E instanceof c?E.forEach(function(O,P){this.append(P,O)},this):Array.isArray(E)?E.forEach(function(O){this.append(O[0],O[1])},this):E&&Object.getOwnPropertyNames(E).forEach(function(O){this.append(O,E[O])},this)}c.prototype.append=function(E,O){E=a(E),O=o(O);var P=this.map[E];this.map[E]=P?P+", "+O:O},c.prototype.delete=function(E){delete this.map[a(E)]},c.prototype.get=function(E){return E=a(E),this.has(E)?this.map[E]:null},c.prototype.has=function(E){return this.map.hasOwnProperty(a(E))},c.prototype.set=function(E,O){this.map[a(E)]=o(O)},c.prototype.forEach=function(E,O){for(var P in this.map)this.map.hasOwnProperty(P)&&E.call(O,this.map[P],P,this)},c.prototype.keys=function(){var E=[];return this.forEach(function(O,P){E.push(P)}),l(E)},c.prototype.values=function(){var E=[];return this.forEach(function(O){E.push(O)}),l(E)},c.prototype.entries=function(){var E=[];return this.forEach(function(O,P){E.push([P,O])}),l(E)},u.iterable&&(c.prototype[Symbol.iterator]=c.prototype.entries);function d(E){if(E.bodyUsed)return Promise.reject(new TypeError("Already read"));E.bodyUsed=!0}function h(E){return new Promise(function(O,P){E.onload=function(){O(E.result)},E.onerror=function(){P(E.error)}})}function f(E){var O=new FileReader,P=h(O);return O.readAsArrayBuffer(E),P}function p(E){var O=new FileReader,P=h(O);return O.readAsText(E),P}function y(E){for(var O=new Uint8Array(E),P=new Array(O.length),j=0;j-1?O:E}function _(E,O){O=O||{};var P=O.body;if(E instanceof _){if(E.bodyUsed)throw new TypeError("Already read");this.url=E.url,this.credentials=E.credentials,O.headers||(this.headers=new c(E.headers)),this.method=E.method,this.mode=E.mode,this.signal=E.signal,!P&&E._bodyInit!=null&&(P=E._bodyInit,E.bodyUsed=!0)}else this.url=String(E);if(this.credentials=O.credentials||this.credentials||"same-origin",(O.headers||!this.headers)&&(this.headers=new c(O.headers)),this.method=v(O.method||this.method||"GET"),this.mode=O.mode||this.mode||null,this.signal=O.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&P)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(P)}_.prototype.clone=function(){return new _(this,{body:this._bodyInit})};function w(E){var O=new FormData;return E.trim().split("&").forEach(function(P){if(P){var j=P.split("="),U=j.shift().replace(/\+/g," "),M=j.join("=").replace(/\+/g," ");O.append(decodeURIComponent(U),decodeURIComponent(M))}}),O}function S(E){var O=new c,P=E.replace(/\r?\n[\t ]+/g," ");return P.split(/\r?\n/).forEach(function(j){var U=j.split(":"),M=U.shift().trim();if(M){var q=U.join(":").trim();O.append(M,q)}}),O}m.call(_.prototype);function A(E,O){O||(O={}),this.type="default",this.status=O.status===void 0?200:O.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in O?O.statusText:"OK",this.headers=new c(O.headers),this.url=O.url||"",this._initBody(E)}m.call(A.prototype),A.prototype.clone=function(){return new A(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new c(this.headers),url:this.url})},A.error=function(){var E=new A(null,{status:0,statusText:""});return E.type="error",E};var D=[301,302,303,307,308];A.redirect=function(E,O){if(D.indexOf(O)===-1)throw new RangeError("Invalid status code");return new A(null,{status:O,headers:{location:E}})},e.DOMException=t.DOMException;try{new e.DOMException}catch{e.DOMException=function(O,P){this.message=O,this.name=P;var j=Error(O);this.stack=j.stack},e.DOMException.prototype=Object.create(Error.prototype),e.DOMException.prototype.constructor=e.DOMException}function L(E,O){return new Promise(function(P,j){var U=new _(E,O);if(U.signal&&U.signal.aborted)return j(new e.DOMException("Aborted","AbortError"));var M=new XMLHttpRequest;function q(){M.abort()}M.onload=function(){var Q={status:M.status,statusText:M.statusText,headers:S(M.getAllResponseHeaders()||"")};Q.url="responseURL"in M?M.responseURL:Q.headers.get("X-Request-URL");var Z="response"in M?M.response:M.responseText;P(new A(Z,Q))},M.onerror=function(){j(new TypeError("Network request failed"))},M.ontimeout=function(){j(new TypeError("Network request failed"))},M.onabort=function(){j(new e.DOMException("Aborted","AbortError"))},M.open(U.method,U.url,!0),U.credentials==="include"?M.withCredentials=!0:U.credentials==="omit"&&(M.withCredentials=!1),"responseType"in M&&u.blob&&(M.responseType="blob"),U.headers.forEach(function(Q,Z){M.setRequestHeader(Z,Q)}),U.signal&&(U.signal.addEventListener("abort",q),M.onreadystatechange=function(){M.readyState===4&&U.signal.removeEventListener("abort",q)}),M.send(typeof U._bodyInit>"u"?null:U._bodyInit)})}return L.polyfill=!0,t.fetch||(t.fetch=L,t.Headers=c,t.Request=_,t.Response=A),e.Headers=c,e.Request=_,e.Response=A,e.fetch=L,Object.defineProperty(e,"__esModule",{value:!0}),e})({})})(typeof self<"u"?self:I)}()),RC}var ew={},Pf={},IC;function cY(){if(IC)return Pf;IC=1,Object.defineProperty(Pf,"__esModule",{value:!0}),Pf.SparqlXmlParser=void 0;const t=Et(),e=Lq(),u=Wt();let s=class{constructor(r){r=r||{},this.dataFactory=r.dataFactory||new t.DataFactory,this.prefixVariableQuestionMark=!!r.prefixVariableQuestionMark}parseXmlResultsStream(r){const a=_=>v.emit("error",_);r.on("error",a);const o=new e.SaxesParser,l=[];let c=!1,d=!1;const h=[];let f={},p="",y="",b,m="",g=[];o.on("error",a),o.on("opentag",_=>{_.name==="variable"&&this.stackEquals(l,["sparql","head"])?h.push(this.dataFactory.variable(_.attributes.name)):_.name==="results"&&this.stackEquals(l,["sparql"])?d=!0:_.name==="result"&&this.stackEquals(l,["sparql","results"])?f={}:_.name==="binding"&&this.stackEquals(l,["sparql","results","result"])?(p=_.attributes.name||"",y="",b="",m="",g=[]):_.name==="triple"&&this.stackBeginsWith(l,["sparql","results","result"])?g.push({components:{}}):l[l.length-1]==="triple"&&this.stackBeginsWith(l,["sparql","results","result","binding"])?(y="",b="",m="",["subject","predicate","object"].includes(_.name)?g[g.length-1].currentComponent=_.name:a(new Error(`Illegal quoted triple component '${_.name}' found on line ${o.line+1}`))):this.stackBeginsWith(l,["sparql","results","result","binding"])&&(y=_.name,"xml:lang"in _.attributes?b=_.attributes["xml:lang"]:"datatype"in _.attributes?b=this.dataFactory.namedNode(_.attributes.datatype):b=void 0),l.push(_.name)}),o.on("closetag",_=>{if(this.stackEquals(l,["sparql","head"])&&(v.emit("variables",h),c=!0),this.stackEquals(l,["sparql","results","result"])&&v.push(f),this.stackBeginsWith(l,["sparql","results","result","binding"])){let w;if(!p&&y)a(new Error(`Terms should have a name on line ${o.line+1}`));else if(y==="uri")w=this.dataFactory.namedNode(m);else if(y==="bnode")w=this.dataFactory.blankNode(m);else if(y==="literal")w=this.dataFactory.literal(m,b);else if(l[l.length-1]==="triple"){const S=g.pop();S&&S.components.subject&&S.components.predicate&&S.components.object?w=this.dataFactory.quad(S.components.subject,S.components.predicate,S.components.object):a(new Error(`Incomplete quoted triple on line ${o.line+1}`))}else y&&a(new Error(`Invalid term type '${y}' on line ${o.line+1}`));if(w)if(g.length>0){const S=g[g.length-1];S.components[S.currentComponent]&&a(new Error(`The ${S.currentComponent} in a quoted triple on line ${o.line+1} was already defined before`)),S.components[S.currentComponent]=w}else{const S=this.prefixVariableQuestionMark?"?"+p:p;f[S]=w}y=void 0}l.pop()}),o.on("text",_=>{this.stackBeginsWith(l,["sparql","results","result","binding"])&&l[l.length-1]===y&&(m=_)});const v=r.on("end",_=>{d?c||v.emit("variables",[]):v.emit("error",new Error("No valid SPARQL query results were found."))}).pipe(new u.Transform({objectMode:!0,transform(_,w,S){o.write(_),S()}}));return v}parseXmlBooleanStream(r){return new Promise((a,o)=>{const l=new e.SaxesParser,c=[];l.on("error",o),l.on("opentag",d=>{c.push(d.name)}),l.on("closetag",d=>{c.pop()}),l.on("text",d=>{this.stackEquals(c,["sparql","boolean"])&&a(d==="true")}),r.on("error",o).on("data",d=>l.write(d)).on("end",()=>o(new Error("No valid ASK response was found.")))})}stackEquals(r,a){return r.length===a.length&&r.every((o,l)=>a[l]===o)}stackBeginsWith(r,a){return r.length>=a.length&&a.every((o,l)=>r[l]===o)}};return Pf.SparqlXmlParser=s,Pf}var PC;function lY(){return PC||(PC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(cY(),t)}(ew)),ew}var Df={},DC;function dY(){if(DC)return Df;DC=1,Object.defineProperty(Df,"__esModule",{value:!0}),Df.ReadableWebToNodeStream=void 0;const t=Wt();class e extends t.Readable{constructor(s){super(),this.bytesRead=0,this.released=!1,this.reader=s.getReader()}async _read(){if(this.released){this.push(null);return}this.pendingRead=this.reader.read();const s=await this.pendingRead;delete this.pendingRead,s.done||this.released?this.push(null):(this.bytesRead+=s.value.length,this.push(s.value))}async waitForReadToComplete(){this.pendingRead&&await this.pendingRead}async close(){await this.syncAndRelease()}async syncAndRelease(){this.released=!0,await this.waitForReadToComplete(),await this.reader.releaseLock()}}return Df.ReadableWebToNodeStream=e,Df}var NC;function fY(){if(NC)return If;NC=1,Object.defineProperty(If,"__esModule",{value:!0}),If.SparqlEndpointFetcher=void 0,uY();const t=my(),e=Oq(),u=lY(),s=eo(),n=dY(),r=ts,a=e7();let o=class js{constructor(c){c=c||{},this.method=c.method||"POST",this.additionalUrlParams=c.additionalUrlParams||new URLSearchParams,this.defaultHeaders=c.defaultHeaders||new Headers,this.fetchCb=c.fetch,this.sparqlJsonParser=new e.SparqlJsonParser(c),this.sparqlXmlParser=new u.SparqlXmlParser(c),this.sparqlParsers={[js.CONTENTTYPE_SPARQL_JSON]:{parseBooleanStream:d=>this.sparqlJsonParser.parseJsonBooleanStream(d),parseResultsStream:d=>this.sparqlJsonParser.parseJsonResultsStream(d)},[js.CONTENTTYPE_SPARQL_XML]:{parseBooleanStream:d=>this.sparqlXmlParser.parseXmlBooleanStream(d),parseResultsStream:d=>this.sparqlXmlParser.parseXmlResultsStream(d)}},this.timeout=c.timeout}getQueryType(c){const d=new t.Parser({sparqlStar:!0}).parse(c);return d.type==="query"?d.queryType==="DESCRIBE"?"CONSTRUCT":d.queryType:"UNKNOWN"}getUpdateTypes(c){const d=new t.Parser({sparqlStar:!0}).parse(c);if(d.type==="update"){const h={};for(const f of d.updates)"type"in f?h[f.type]=!0:h[f.updateType]=!0;return h}else return"UNKNOWN"}async fetchBindings(c,d){const[h,f]=await this.fetchRawStream(c,d,js.CONTENTTYPE_SPARQL),p=this.sparqlParsers[h];if(!p)throw new Error("Unknown SPARQL results content type: "+h);return p.parseResultsStream(f)}async fetchAsk(c,d){const[h,f]=await this.fetchRawStream(c,d,js.CONTENTTYPE_SPARQL),p=this.sparqlParsers[h];if(!p)throw new Error("Unknown SPARQL results content type: "+h);return p.parseBooleanStream(f)}async fetchTriples(c,d){return(await this.fetchRawStream(c,d,js.CONTENTTYPE_TURTLE))[1].pipe(new r.StreamParser({format:js.CONTENTTYPE_TURTLE}))}async fetchUpdate(c,d){const h=globalThis.AbortController||await Promise.resolve().then(()=>Uo()),f=new h,p={};this.defaultHeaders.forEach((b,m)=>{p[m]=b});const y={method:"POST",headers:Object.assign(Object.assign({},p),{"content-type":"application/sparql-update"}),body:d,signal:f.signal};await this.handleFetchCall(c,y,{ignoreBody:!0}),f.abort()}async fetchRawStream(c,d,h){let f=this.method==="POST"?c:c+"?query="+encodeURIComponent(d);const p=new Headers(this.defaultHeaders);let y;return p.append("Accept",h),this.method==="POST"?(p.append("Content-Type","application/x-www-form-urlencoded"),y=new URLSearchParams,y.set("query",d),this.additionalUrlParams.forEach((b,m)=>{y.set(m,b)}),p.append("Content-Length",y.toString().length.toString())):this.additionalUrlParams.toString()!==""&&(f+=`&${this.additionalUrlParams.toString()}`),this.handleFetchCall(f,{headers:p,method:this.method,body:y})}async handleFetchCall(c,d,h={}){let f;if(this.timeout){const m=new AbortController;d.signal=m.signal,f=setTimeout(()=>m.abort(),this.timeout)}const p=await(this.fetchCb||fetch)(c,d);clearTimeout(f);let y;h.ignoreBody||(y=a(p.body)?p.body:new n.ReadableWebToNodeStream(p.body));let b=p.headers.get("Content-Type")||"";if(b.indexOf(";")>0&&(b=b.substr(0,b.indexOf(";"))),!p.ok){const m=/^[^?]*/u.exec(c)[0];let g="empty response";throw y&&(g=await s(y)),new Error(`Invalid SPARQL endpoint response from ${m} (HTTP status ${p.status}): -${g}`)}return[b,y]}};return o.CONTENTTYPE_SPARQL_JSON="application/sparql-results+json",o.CONTENTTYPE_SPARQL_XML="application/sparql-results+xml",o.CONTENTTYPE_SPARQL=`${o.CONTENTTYPE_SPARQL_JSON};q=1.0,${o.CONTENTTYPE_SPARQL_XML};q=0.7`,o.CONTENTTYPE_TURTLE="text/turtle",If.SparqlEndpointFetcher=o,If}var CC;function y7(){return CC||(CC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(fY(),t)}(Z2)),Z2}var jC;function b7(){if(jC)return xf;jC=1,Object.defineProperty(xf,"__esModule",{value:!0}),xf.QuadDestinationSparql=void 0;const t=y7(),e=Oy(),u=eo();let s=class{constructor(r,a,o){this.url=r,this.context=a,this.mediatorHttp=o,this.endpointFetcher=new t.SparqlEndpointFetcher({fetch:(l,c)=>this.mediatorHttp.mediate({input:l,init:c,context:this.context}),prefixVariableQuestionMark:!0})}insert(r){return this.wrapSparqlUpdateRequest("INSERT",r)}async delete(r){return this.wrapSparqlUpdateRequest("DELETE",r)}async wrapSparqlUpdateRequest(r,a){const o=a.map(c=>{let d=`${(0,e.termToString)(c.subject)} ${(0,e.termToString)(c.predicate)} ${(0,e.termToString)(c.object)} .`;return c.graph.termType==="DefaultGraph"?d=` ${d} -`:d=` GRAPH ${(0,e.termToString)(c.graph)} { ${d} } -`,d}).prepend([`${r} DATA { -`]).append(["}"]),l=await u(o);await this.endpointFetcher.fetchUpdate(this.url,l)}async deleteGraphs(r,a,o){const l=Array.isArray(r)?r:[r],c=[];for(const d of l){let h;typeof d=="string"?h=d:d.termType==="DefaultGraph"?h="DEFAULT":h=`GRAPH <${d.value}>`,c.push(`${o?"DROP":"CLEAR"} ${a?"":"SILENT "}${h}`)}await this.endpointFetcher.fetchUpdate(this.url,c.join("; "))}async createGraphs(r,a){const o=[];for(const l of r)o.push(`CREATE${a?"":" SILENT"} GRAPH <${l.value}>`);await this.endpointFetcher.fetchUpdate(this.url,o.join("; "))}};return xf.QuadDestinationSparql=s,xf}var LC;function hY(){if(LC)return Rf;LC=1,Object.defineProperty(Rf,"__esModule",{value:!0}),Rf.ActorRdfUpdateHypermediaSparql=void 0;const t=ZT(),e=b7();let u=class extends t.ActorRdfUpdateHypermedia{constructor(n){super(n,"sparql")}async testMetadata(n){if(!n.forceDestinationType&&!n.metadata.sparqlService&&!(this.checkUrlSuffixSparql&&n.url.endsWith("/sparql"))&&!(this.checkUrlSuffixUpdate&&n.url.endsWith("/update")))throw new Error(`Actor ${this.name} could not detect a SPARQL service description or URL ending on /sparql or /update.`);return!0}async run(n){return this.logInfo(n.context,`Identified as sparql destination: ${n.url}`),{destination:new e.QuadDestinationSparql(n.metadata.sparqlService||n.url,n.context,this.mediatorHttp)}}};return Rf.ActorRdfUpdateHypermediaSparql=u,Rf}var MC;function pY(){return MC||(MC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(hY(),t),u(b7(),t)}(Y2)),Y2}var tw={},Nf={},FC;function yY(){if(FC)return Nf;FC=1,Object.defineProperty(Nf,"__esModule",{value:!0}),Nf.ActorQueryOperationAsk=void 0;const t=wt();let e=class extends t.ActorQueryOperationTypedMediated{constructor(s){super(s,"ask")}async testOperation(s,n){return!0}async runOperation(s,n){const r=await this.mediatorQueryOperation.mediate({operation:s.input,context:n}),{bindingsStream:a}=t.ActorQueryOperation.getSafeBindings(r);return{type:"boolean",execute:async()=>(await a.take(1).toArray()).length===1}}};return Nf.ActorQueryOperationAsk=e,Nf}var qC;function bY(){return qC||(qC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(yY(),t)}(tw)),tw}var rw={},Cf={},BC;function gY(){if(BC)return Cf;BC=1,Object.defineProperty(Cf,"__esModule",{value:!0}),Cf.ActorQueryOperationBgpJoin=void 0;const t=wt(),e=Ot();let u=class g7 extends t.ActorQueryOperationTypedMediated{constructor(n){super(n,"bgp")}async testOperation(n,r){return!0}async runOperation(n,r){return this.mediatorQueryOperation.mediate({operation:g7.FACTORY.createJoin(n.patterns),context:r})}};return Cf.ActorQueryOperationBgpJoin=u,u.FACTORY=new e.Factory,Cf}var UC;function mY(){return UC||(UC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(gY(),t)}(rw)),rw}var nw={},jf={},HC;function _Y(){if(HC)return jf;HC=1,Object.defineProperty(jf,"__esModule",{value:!0}),jf.ActorQueryOperationDistinctHash=void 0;const t=wt();let e=class extends t.ActorQueryOperationTypedMediated{constructor(s){super(s,"distinct")}async testOperation(s,n){return!0}async runOperation(s,n){const r=t.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:s.input,context:n}));return{type:"bindings",bindingsStream:r.bindingsStream.filter(await this.newHashFilter(n)),metadata:r.metadata}}async newHashFilter(s){const{hashFunction:n}=await this.mediatorHashBindings.mediate({allowHashCollisions:!0,context:s}),r={};return a=>{const o=n(a);return!(o in r)&&(r[o]=!0)}}};return jf.ActorQueryOperationDistinctHash=e,jf}var $C;function vY(){return $C||($C=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(_Y(),t)}(nw)),nw}var iw={},Lf={},Mf={},QC;function m7(){if(QC)return Mf;QC=1,Object.defineProperty(Mf,"__esModule",{value:!0}),Mf.BindingsToQuadsIterator=void 0;const t=Nt(),e=Et(),u=un(),s=new e.DataFactory;let n=class O0 extends t.MultiTransformIterator{constructor(a,o){super(o,{autoStart:!1}),this.template=a,this.blankNodeCounter=0}static bindTerm(a,o){return o.termType==="Variable"?a.get(o):o}static bindQuad(a,o){try{return(0,u.mapTermsNested)(o,l=>{const c=O0.bindTerm(a,l);if(!c)throw new Error("Unbound term");return c})}catch{}}static localizeBlankNode(a,o){return o.termType==="BlankNode"?s.blankNode(`${o.value}${a}`):o}static localizeQuad(a,o){return(0,u.mapTermsNested)(o,l=>O0.localizeBlankNode(a,l))}bindTemplate(a,o,l){return o.map(O0.localizeQuad.bind(null,l)).map(d=>O0.bindQuad.bind(null,a)(d)).filter(Boolean)}_createTransformer(a){return new t.ArrayIterator(this.bindTemplate(a,this.template,this.blankNodeCounter++),{autoStart:!1})}};return Mf.BindingsToQuadsIterator=n,Mf}var VC;function wY(){if(VC)return Lf;VC=1,Object.defineProperty(Lf,"__esModule",{value:!0}),Lf.ActorQueryOperationConstruct=void 0;const t=wt(),e=un(),u=Ot(),s=m7();let n=class _7 extends t.ActorQueryOperationTypedMediated{constructor(a){super(a,"construct")}static getVariables(a){return(0,e.uniqTerms)([].concat.apply([],a.map(o=>(0,e.getVariables)((0,e.getTermsNested)(o)))))}async testOperation(a,o){return!0}async runOperation(a,o){const l=_7.getVariables(a.template),c={type:u.Algebra.types.PROJECT,input:a.input,variables:l},d=t.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:c,context:o})),h=new s.BindingsToQuadsIterator(a.template,d.bindingsStream);return{metadata:()=>d.metadata().then(p=>({...p,order:void 0,cardinality:{type:p.cardinality.type,value:p.cardinality.value*a.template.length},canContainUndefs:!1,availableOrders:void 0})),quadStream:h,type:"quads"}}};return Lf.ActorQueryOperationConstruct=n,Lf}var kC;function v7(){return kC||(kC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(wY(),t),u(m7(),t)}(iw)),iw}var aw={},Ff={},zC;function SY(){if(zC)return Ff;zC=1,Object.defineProperty(Ff,"__esModule",{value:!0}),Ff.ActorQueryOperationFromQuad=void 0;const t=wt(),e=Ot();let u=class hr extends t.ActorQueryOperationTypedMediated{constructor(n){super(n,"from")}static copyOperation(n,r){const a={};for(const o of Object.keys(n))Array.isArray(n[o])&&o!=="template"?o==="variables"?a[o]=n[o]:a[o]=n[o].map(r):hr.ALGEBRA_TYPES.includes(n[o].type)?a[o]=r(n[o]):a[o]=n[o];return a}static applyOperationDefaultGraph(n,r){if(n.type==="bgp"&&n.patterns.length>0||n.type==="path"||n.type==="pattern"){if(n.type==="bgp")return hr.joinOperations(n.patterns.map(o=>{if(o.graph.termType!=="DefaultGraph")return hr.FACTORY.createBgp([o]);const l=r.map(c=>hr.FACTORY.createBgp([Object.assign(hr.FACTORY.createPattern(o.subject,o.predicate,o.object,c),{metadata:o.metadata})]));return hr.unionOperations(l)}));if(n.graph.termType!=="DefaultGraph")return n;const a=r.map(o=>n.type==="path"?hr.FACTORY.createPath(n.subject,n.predicate,n.object,o):Object.assign(hr.FACTORY.createPattern(n.subject,n.predicate,n.object,o),{metadata:n.metadata}));return hr.unionOperations(a)}return hr.copyOperation(n,a=>this.applyOperationDefaultGraph(a,r))}static applyOperationNamedGraph(n,r,a){if(n.type==="bgp"&&n.patterns.length>0||n.type==="path"||n.type==="pattern"){const o=n.type==="bgp"?n.patterns[0].graph:n.graph;if(o.termType==="DefaultGraph")return{type:e.Algebra.types.BGP,patterns:[]};if(o.termType==="Variable"){if(r.length===1){const c=r[0],d={};d[`?${o.value}`]=c;const h=hr.FACTORY.createValues([o],[d]);let f;return n.type==="bgp"?f=hr.FACTORY.createBgp(n.patterns.map(p=>hr.FACTORY.createPattern(p.subject,p.predicate,p.object,c))):n.type==="path"?f=hr.FACTORY.createPath(n.subject,n.predicate,n.object,c):f=hr.FACTORY.createPattern(n.subject,n.predicate,n.object,c),hr.FACTORY.createJoin([h,f])}return hr.unionOperations(r.map(c=>hr.applyOperationNamedGraph(n,[c],a)))}return[...r,...a].some(c=>c.equals(o))?n:{type:e.Algebra.types.BGP,patterns:[]}}return hr.copyOperation(n,o=>this.applyOperationNamedGraph(o,r,a))}static joinOperations(n){if(n.length===1)return n[0];if(n.length>1)return hr.FACTORY.createJoin(n);throw new Error("A join can only be applied on at least one operation")}static unionOperations(n){if(n.length===1)return n[0];if(n.length>1)return hr.FACTORY.createUnion(n);throw new Error("A union can only be applied on at least one operation")}static createOperation(n){let r=n.input;return n.default.length>0&&(r=hr.applyOperationDefaultGraph(r,n.default)),(n.named.length>0||n.default.length>0)&&(r=hr.applyOperationNamedGraph(r,n.named,n.default)),r}async testOperation(n,r){return!0}async runOperation(n,r){const a=hr.createOperation(n);return this.mediatorQueryOperation.mediate({operation:a,context:r})}};return Ff.ActorQueryOperationFromQuad=u,u.FACTORY=new e.Factory,u.ALGEBRA_TYPES=Object.keys(e.Algebra.types).map(s=>e.Algebra.types[s]),Ff}var GC;function TY(){return GC||(GC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(SY(),t)}(aw)),aw}var sw={},qf={},WC;function AY(){if(WC)return qf;WC=1,Object.defineProperty(qf,"__esModule",{value:!0}),qf.ActorQueryOperationProject=void 0;const t=wt(),e=ET(),u=Et(),s=new u.DataFactory;let n=class extends t.ActorQueryOperationTypedMediated{constructor(a){super(a,"project")}async testOperation(a,o){return!0}async runOperation(a,o){const l=t.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:a.input,context:o})),c=await l.metadata(),d=a.variables,h=c.variables.filter(b=>!d.some(m=>b.value===m.value)),f=d.filter(b=>!c.variables.some(m=>b.value===m.value));if(f.length>0)throw new Error(`Variables '${f.map(b=>`?${b.value}`)}' are used in the projection result, but are not assigned.`);let p=h.length===0?l.bindingsStream:l.bindingsStream.map(b=>{for(const m of h)b=b.delete(m);return b}),y=0;return p=p.map(b=>{y++;const m=new Map;return b.map(g=>{if(g instanceof e.BlankNodeBindingsScoped){let v=m.get(g.value);return v||(v=s.blankNode(`${g.value}${y}`),m.set(g.value,v)),v}return g})}),{type:"bindings",bindingsStream:p,metadata:async()=>({...c,variables:d})}}};return qf.ActorQueryOperationProject=n,qf}var JC;function EY(){return JC||(JC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(AY(),t)}(sw)),sw}var ow={},Bf={},Uf={},XC;function is(){var f,p,b,m,g,v,_,w,S,A,D,L,E,O,P,j,U,M,q,Q,Z,K,fe,X,he,xe,l3,ae,Oe,Ne,ge,de,w7,$,N,R,T,Da,B,Na,V,d3,z,Y,q1,ce,B1,Ie,pr,qe,f3,F,R0,re,Ca,Re,h3;if(XC)return Uf;XC=1,Object.defineProperty(Uf,"__esModule",{value:!0}),Uf.LRUCache=void 0;const t=typeof performance=="object"&&performance&&typeof performance.now=="function"?performance:Date,e=new Set,u=typeof process=="object"&&process?process:{},s=(ke,me,Se,W)=>{typeof u.emitWarning=="function"?u.emitWarning(ke,me,Se,W):console.error(`[${Se}] ${me}: ${ke}`)};let n=globalThis.AbortController,r=globalThis.AbortSignal;if(typeof n>"u"){r=class{constructor(){wr(this,"onabort");wr(this,"_onabort",[]);wr(this,"reason");wr(this,"aborted",!1)}addEventListener(W,we){this._onabort.push(we)}},n=class{constructor(){wr(this,"signal",new r);me()}abort(W){var we,Te;if(!this.signal.aborted){this.signal.reason=W,this.signal.aborted=!0;for(const Le of this.signal._onabort)Le(W);(Te=(we=this.signal).onabort)==null||Te.call(we,W)}}};let ke=((f=u.env)==null?void 0:f.LRU_CACHE_IGNORE_AC_WARNING)!=="1";const me=()=>{ke&&(ke=!1,s("AbortController is not defined. If using lru-cache in node 14, load an AbortController polyfill from the `node-abort-controller` package. A minimal polyfill is provided for use by LRUCache.fetch(), but it should not be relied upon in other contexts (eg, passing it to other APIs that use AbortController/AbortSignal might have undesirable effects). You may disable this with LRU_CACHE_IGNORE_AC_WARNING=1 in the env.","NO_ABORT_CONTROLLER","ENOTSUP",me))}}const a=ke=>!e.has(ke),o=ke=>ke&&ke===Math.floor(ke)&&ke>0&&isFinite(ke),l=ke=>o(ke)?ke<=Math.pow(2,8)?Uint8Array:ke<=Math.pow(2,16)?Uint16Array:ke<=Math.pow(2,32)?Uint32Array:ke<=Number.MAX_SAFE_INTEGER?c:null:null;class c extends Array{constructor(me){super(me),this.fill(0)}}const y=class y{constructor(me,Se){wr(this,"heap");wr(this,"length");if(!_e(y,p))throw new TypeError("instantiate Stack using Stack.create(n)");this.heap=new Se(me),this.length=0}static create(me){const Se=l(me);if(!Se)return[];_t(y,p,!0);const W=new y(me,Se);return _t(y,p,!1),W}push(me){this.heap[this.length++]=me}pop(){return this.heap[--this.length]}};p=new WeakMap,xt(y,p,!1);let d=y;const Qe=class Qe{constructor(me){xt(this,xe);xt(this,de);xt(this,T);xt(this,B);xt(this,V);xt(this,Y);xt(this,ce);xt(this,Ie);xt(this,qe);xt(this,F);xt(this,re);xt(this,Re);xt(this,b,void 0);xt(this,m,void 0);xt(this,g,void 0);xt(this,v,void 0);xt(this,_,void 0);xt(this,w,void 0);wr(this,"ttl");wr(this,"ttlResolution");wr(this,"ttlAutopurge");wr(this,"updateAgeOnGet");wr(this,"updateAgeOnHas");wr(this,"allowStale");wr(this,"noDisposeOnSet");wr(this,"noUpdateTTL");wr(this,"maxEntrySize");wr(this,"sizeCalculation");wr(this,"noDeleteOnFetchRejection");wr(this,"noDeleteOnStaleGet");wr(this,"allowStaleOnFetchAbort");wr(this,"allowStaleOnFetchRejection");wr(this,"ignoreFetchAbort");xt(this,S,void 0);xt(this,A,void 0);xt(this,D,void 0);xt(this,L,void 0);xt(this,E,void 0);xt(this,O,void 0);xt(this,P,void 0);xt(this,j,void 0);xt(this,U,void 0);xt(this,M,void 0);xt(this,q,void 0);xt(this,Q,void 0);xt(this,Z,void 0);xt(this,K,void 0);xt(this,fe,void 0);xt(this,X,void 0);xt(this,he,void 0);xt(this,ae,()=>{});xt(this,Oe,()=>{});xt(this,Ne,()=>{});xt(this,ge,()=>!1);xt(this,$,me=>{});xt(this,N,(me,Se,W)=>{});xt(this,R,(me,Se,W,we)=>{if(W||we)throw new TypeError("cannot set size without setting maxSize or maxEntrySize on cache");return 0});wr(this,z,"LRUCache");const{max:Se=0,ttl:W,ttlResolution:we=1,ttlAutopurge:Te,updateAgeOnGet:Le,updateAgeOnHas:$e,allowStale:We,dispose:tt,disposeAfter:lt,noDisposeOnSet:ut,noUpdateTTL:le,maxSize:C=0,maxEntrySize:ee=0,sizeCalculation:pe,fetchMethod:De,memoMethod:Ue,noDeleteOnFetchRejection:Fe,noDeleteOnStaleGet:Ye,allowStaleOnFetchRejection:Ve,allowStaleOnFetchAbort:Je,ignoreFetchAbort:nt}=me;if(Se!==0&&!o(Se))throw new TypeError("max option must be a nonnegative integer");const yt=Se?l(Se):Array;if(!yt)throw new Error("invalid max value: "+Se);if(_t(this,b,Se),_t(this,m,C),this.maxEntrySize=ee||_e(this,m),this.sizeCalculation=pe,this.sizeCalculation){if(!_e(this,m)&&!this.maxEntrySize)throw new TypeError("cannot set sizeCalculation without setting maxSize or maxEntrySize");if(typeof this.sizeCalculation!="function")throw new TypeError("sizeCalculation set to non-function")}if(Ue!==void 0&&typeof Ue!="function")throw new TypeError("memoMethod must be a function if defined");if(_t(this,w,Ue),De!==void 0&&typeof De!="function")throw new TypeError("fetchMethod must be a function if specified");if(_t(this,_,De),_t(this,X,!!De),_t(this,D,new Map),_t(this,L,new Array(Se).fill(void 0)),_t(this,E,new Array(Se).fill(void 0)),_t(this,O,new yt(Se)),_t(this,P,new yt(Se)),_t(this,j,0),_t(this,U,0),_t(this,M,d.create(Se)),_t(this,S,0),_t(this,A,0),typeof tt=="function"&&_t(this,g,tt),typeof lt=="function"?(_t(this,v,lt),_t(this,q,[])):(_t(this,v,void 0),_t(this,q,void 0)),_t(this,fe,!!_e(this,g)),_t(this,he,!!_e(this,v)),this.noDisposeOnSet=!!ut,this.noUpdateTTL=!!le,this.noDeleteOnFetchRejection=!!Fe,this.allowStaleOnFetchRejection=!!Ve,this.allowStaleOnFetchAbort=!!Je,this.ignoreFetchAbort=!!nt,this.maxEntrySize!==0){if(_e(this,m)!==0&&!o(_e(this,m)))throw new TypeError("maxSize must be a positive integer if specified");if(!o(this.maxEntrySize))throw new TypeError("maxEntrySize must be a positive integer if specified");ct(this,de,w7).call(this)}if(this.allowStale=!!We,this.noDeleteOnStaleGet=!!Ye,this.updateAgeOnGet=!!Le,this.updateAgeOnHas=!!$e,this.ttlResolution=o(we)||we===0?we:1,this.ttlAutopurge=!!Te,this.ttl=W||0,this.ttl){if(!o(this.ttl))throw new TypeError("ttl must be a positive integer if specified");ct(this,xe,l3).call(this)}if(_e(this,b)===0&&this.ttl===0&&_e(this,m)===0)throw new TypeError("At least one of max, maxSize, or ttl is required");if(!this.ttlAutopurge&&!_e(this,b)&&!_e(this,m)){const ft="LRU_CACHE_UNBOUNDED";a(ft)&&(e.add(ft),s("TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.","UnboundedCacheWarning",ft,Qe))}}static unsafeExposeInternals(me){return{starts:_e(me,Z),ttls:_e(me,K),sizes:_e(me,Q),keyMap:_e(me,D),keyList:_e(me,L),valList:_e(me,E),next:_e(me,O),prev:_e(me,P),get head(){return _e(me,j)},get tail(){return _e(me,U)},free:_e(me,M),isBackgroundFetch:Se=>{var W;return ct(W=me,Ie,pr).call(W,Se)},backgroundFetch:(Se,W,we,Te)=>{var Le;return ct(Le=me,ce,B1).call(Le,Se,W,we,Te)},moveToTail:Se=>{var W;return ct(W=me,F,R0).call(W,Se)},indexes:Se=>{var W;return ct(W=me,T,Da).call(W,Se)},rindexes:Se=>{var W;return ct(W=me,B,Na).call(W,Se)},isStale:Se=>{var W;return _e(W=me,ge).call(W,Se)}}}get max(){return _e(this,b)}get maxSize(){return _e(this,m)}get calculatedSize(){return _e(this,A)}get size(){return _e(this,S)}get fetchMethod(){return _e(this,_)}get memoMethod(){return _e(this,w)}get dispose(){return _e(this,g)}get disposeAfter(){return _e(this,v)}getRemainingTTL(me){return _e(this,D).has(me)?1/0:0}*entries(){for(const me of ct(this,T,Da).call(this))_e(this,E)[me]!==void 0&&_e(this,L)[me]!==void 0&&!ct(this,Ie,pr).call(this,_e(this,E)[me])&&(yield[_e(this,L)[me],_e(this,E)[me]])}*rentries(){for(const me of ct(this,B,Na).call(this))_e(this,E)[me]!==void 0&&_e(this,L)[me]!==void 0&&!ct(this,Ie,pr).call(this,_e(this,E)[me])&&(yield[_e(this,L)[me],_e(this,E)[me]])}*keys(){for(const me of ct(this,T,Da).call(this)){const Se=_e(this,L)[me];Se!==void 0&&!ct(this,Ie,pr).call(this,_e(this,E)[me])&&(yield Se)}}*rkeys(){for(const me of ct(this,B,Na).call(this)){const Se=_e(this,L)[me];Se!==void 0&&!ct(this,Ie,pr).call(this,_e(this,E)[me])&&(yield Se)}}*values(){for(const me of ct(this,T,Da).call(this))_e(this,E)[me]!==void 0&&!ct(this,Ie,pr).call(this,_e(this,E)[me])&&(yield _e(this,E)[me])}*rvalues(){for(const me of ct(this,B,Na).call(this))_e(this,E)[me]!==void 0&&!ct(this,Ie,pr).call(this,_e(this,E)[me])&&(yield _e(this,E)[me])}[Symbol.iterator](){return this.entries()}find(me,Se={}){for(const W of ct(this,T,Da).call(this)){const we=_e(this,E)[W],Te=ct(this,Ie,pr).call(this,we)?we.__staleWhileFetching:we;if(Te!==void 0&&me(Te,_e(this,L)[W],this))return this.get(_e(this,L)[W],Se)}}forEach(me,Se=this){for(const W of ct(this,T,Da).call(this)){const we=_e(this,E)[W],Te=ct(this,Ie,pr).call(this,we)?we.__staleWhileFetching:we;Te!==void 0&&me.call(Se,Te,_e(this,L)[W],this)}}rforEach(me,Se=this){for(const W of ct(this,B,Na).call(this)){const we=_e(this,E)[W],Te=ct(this,Ie,pr).call(this,we)?we.__staleWhileFetching:we;Te!==void 0&&me.call(Se,Te,_e(this,L)[W],this)}}purgeStale(){let me=!1;for(const Se of ct(this,B,Na).call(this,{allowStale:!0}))_e(this,ge).call(this,Se)&&(ct(this,re,Ca).call(this,_e(this,L)[Se],"expire"),me=!0);return me}info(me){const Se=_e(this,D).get(me);if(Se===void 0)return;const W=_e(this,E)[Se],we=ct(this,Ie,pr).call(this,W)?W.__staleWhileFetching:W;if(we===void 0)return;const Te={value:we};if(_e(this,K)&&_e(this,Z)){const Le=_e(this,K)[Se],$e=_e(this,Z)[Se];if(Le&&$e){const We=Le-(t.now()-$e);Te.ttl=We,Te.start=Date.now()}}return _e(this,Q)&&(Te.size=_e(this,Q)[Se]),Te}dump(){const me=[];for(const Se of ct(this,T,Da).call(this,{allowStale:!0})){const W=_e(this,L)[Se],we=_e(this,E)[Se],Te=ct(this,Ie,pr).call(this,we)?we.__staleWhileFetching:we;if(Te===void 0||W===void 0)continue;const Le={value:Te};if(_e(this,K)&&_e(this,Z)){Le.ttl=_e(this,K)[Se];const $e=t.now()-_e(this,Z)[Se];Le.start=Math.floor(Date.now()-$e)}_e(this,Q)&&(Le.size=_e(this,Q)[Se]),me.unshift([W,Le])}return me}load(me){this.clear();for(const[Se,W]of me){if(W.start){const we=Date.now()-W.start;W.start=t.now()-we}this.set(Se,W.value,W)}}set(me,Se,W={}){var le,C,ee,pe,De;if(Se===void 0)return this.delete(me),this;const{ttl:we=this.ttl,start:Te,noDisposeOnSet:Le=this.noDisposeOnSet,sizeCalculation:$e=this.sizeCalculation,status:We}=W;let{noUpdateTTL:tt=this.noUpdateTTL}=W;const lt=_e(this,R).call(this,me,Se,W.size||0,$e);if(this.maxEntrySize&<>this.maxEntrySize)return We&&(We.set="miss",We.maxEntrySizeExceeded=!0),ct(this,re,Ca).call(this,me,"set"),this;let ut=_e(this,S)===0?void 0:_e(this,D).get(me);if(ut===void 0)ut=_e(this,S)===0?_e(this,U):_e(this,M).length!==0?_e(this,M).pop():_e(this,S)===_e(this,b)?ct(this,Y,q1).call(this,!1):_e(this,S),_e(this,L)[ut]=me,_e(this,E)[ut]=Se,_e(this,D).set(me,ut),_e(this,O)[_e(this,U)]=ut,_e(this,P)[ut]=_e(this,U),_t(this,U,ut),$y(this,S)._++,_e(this,N).call(this,ut,lt,We),We&&(We.set="add"),tt=!1;else{ct(this,F,R0).call(this,ut);const Ue=_e(this,E)[ut];if(Se!==Ue){if(_e(this,X)&&ct(this,Ie,pr).call(this,Ue)){Ue.__abortController.abort(new Error("replaced"));const{__staleWhileFetching:Fe}=Ue;Fe!==void 0&&!Le&&(_e(this,fe)&&((le=_e(this,g))==null||le.call(this,Fe,me,"set")),_e(this,he)&&((C=_e(this,q))==null||C.push([Fe,me,"set"])))}else Le||(_e(this,fe)&&((ee=_e(this,g))==null||ee.call(this,Ue,me,"set")),_e(this,he)&&((pe=_e(this,q))==null||pe.push([Ue,me,"set"])));if(_e(this,$).call(this,ut),_e(this,N).call(this,ut,lt,We),_e(this,E)[ut]=Se,We){We.set="replace";const Fe=Ue&&ct(this,Ie,pr).call(this,Ue)?Ue.__staleWhileFetching:Ue;Fe!==void 0&&(We.oldValue=Fe)}}else We&&(We.set="update")}if(we!==0&&!_e(this,K)&&ct(this,xe,l3).call(this),_e(this,K)&&(tt||_e(this,Ne).call(this,ut,we,Te),We&&_e(this,Oe).call(this,We,ut)),!Le&&_e(this,he)&&_e(this,q)){const Ue=_e(this,q);let Fe;for(;Fe=Ue==null?void 0:Ue.shift();)(De=_e(this,v))==null||De.call(this,...Fe)}return this}pop(){var me;try{for(;_e(this,S);){const Se=_e(this,E)[_e(this,j)];if(ct(this,Y,q1).call(this,!0),ct(this,Ie,pr).call(this,Se)){if(Se.__staleWhileFetching)return Se.__staleWhileFetching}else if(Se!==void 0)return Se}}finally{if(_e(this,he)&&_e(this,q)){const Se=_e(this,q);let W;for(;W=Se==null?void 0:Se.shift();)(me=_e(this,v))==null||me.call(this,...W)}}}has(me,Se={}){const{updateAgeOnHas:W=this.updateAgeOnHas,status:we}=Se,Te=_e(this,D).get(me);if(Te!==void 0){const Le=_e(this,E)[Te];if(ct(this,Ie,pr).call(this,Le)&&Le.__staleWhileFetching===void 0)return!1;if(_e(this,ge).call(this,Te))we&&(we.has="stale",_e(this,Oe).call(this,we,Te));else return W&&_e(this,ae).call(this,Te),we&&(we.has="hit",_e(this,Oe).call(this,we,Te)),!0}else we&&(we.has="miss");return!1}peek(me,Se={}){const{allowStale:W=this.allowStale}=Se,we=_e(this,D).get(me);if(we===void 0||!W&&_e(this,ge).call(this,we))return;const Te=_e(this,E)[we];return ct(this,Ie,pr).call(this,Te)?Te.__staleWhileFetching:Te}async fetch(me,Se={}){const{allowStale:W=this.allowStale,updateAgeOnGet:we=this.updateAgeOnGet,noDeleteOnStaleGet:Te=this.noDeleteOnStaleGet,ttl:Le=this.ttl,noDisposeOnSet:$e=this.noDisposeOnSet,size:We=0,sizeCalculation:tt=this.sizeCalculation,noUpdateTTL:lt=this.noUpdateTTL,noDeleteOnFetchRejection:ut=this.noDeleteOnFetchRejection,allowStaleOnFetchRejection:le=this.allowStaleOnFetchRejection,ignoreFetchAbort:C=this.ignoreFetchAbort,allowStaleOnFetchAbort:ee=this.allowStaleOnFetchAbort,context:pe,forceRefresh:De=!1,status:Ue,signal:Fe}=Se;if(!_e(this,X))return Ue&&(Ue.fetch="get"),this.get(me,{allowStale:W,updateAgeOnGet:we,noDeleteOnStaleGet:Te,status:Ue});const Ye={allowStale:W,updateAgeOnGet:we,noDeleteOnStaleGet:Te,ttl:Le,noDisposeOnSet:$e,size:We,sizeCalculation:tt,noUpdateTTL:lt,noDeleteOnFetchRejection:ut,allowStaleOnFetchRejection:le,allowStaleOnFetchAbort:ee,ignoreFetchAbort:C,status:Ue,signal:Fe};let Ve=_e(this,D).get(me);if(Ve===void 0){Ue&&(Ue.fetch="miss");const Je=ct(this,ce,B1).call(this,me,Ve,Ye,pe);return Je.__returned=Je}else{const Je=_e(this,E)[Ve];if(ct(this,Ie,pr).call(this,Je)){const Ir=W&&Je.__staleWhileFetching!==void 0;return Ue&&(Ue.fetch="inflight",Ir&&(Ue.returnedStale=!0)),Ir?Je.__staleWhileFetching:Je.__returned=Je}const nt=_e(this,ge).call(this,Ve);if(!De&&!nt)return Ue&&(Ue.fetch="hit"),ct(this,F,R0).call(this,Ve),we&&_e(this,ae).call(this,Ve),Ue&&_e(this,Oe).call(this,Ue,Ve),Je;const yt=ct(this,ce,B1).call(this,me,Ve,Ye,pe),et=yt.__staleWhileFetching!==void 0&&W;return Ue&&(Ue.fetch=nt?"stale":"refresh",et&&nt&&(Ue.returnedStale=!0)),et?yt.__staleWhileFetching:yt.__returned=yt}}async forceFetch(me,Se={}){const W=await this.fetch(me,Se);if(W===void 0)throw new Error("fetch() returned undefined");return W}memo(me,Se={}){const W=_e(this,w);if(!W)throw new Error("no memoMethod provided to constructor");const{context:we,forceRefresh:Te,...Le}=Se,$e=this.get(me,Le);if(!Te&&$e!==void 0)return $e;const We=W(me,$e,{options:Le,context:we});return this.set(me,We,Le),We}get(me,Se={}){const{allowStale:W=this.allowStale,updateAgeOnGet:we=this.updateAgeOnGet,noDeleteOnStaleGet:Te=this.noDeleteOnStaleGet,status:Le}=Se,$e=_e(this,D).get(me);if($e!==void 0){const We=_e(this,E)[$e],tt=ct(this,Ie,pr).call(this,We);return Le&&_e(this,Oe).call(this,Le,$e),_e(this,ge).call(this,$e)?(Le&&(Le.get="stale"),tt?(Le&&W&&We.__staleWhileFetching!==void 0&&(Le.returnedStale=!0),W?We.__staleWhileFetching:void 0):(Te||ct(this,re,Ca).call(this,me,"expire"),Le&&W&&(Le.returnedStale=!0),W?We:void 0)):(Le&&(Le.get="hit"),tt?We.__staleWhileFetching:(ct(this,F,R0).call(this,$e),we&&_e(this,ae).call(this,$e),We))}else Le&&(Le.get="miss")}delete(me){return ct(this,re,Ca).call(this,me,"delete")}clear(){return ct(this,Re,h3).call(this,"delete")}};z=Symbol.toStringTag,b=new WeakMap,m=new WeakMap,g=new WeakMap,v=new WeakMap,_=new WeakMap,w=new WeakMap,S=new WeakMap,A=new WeakMap,D=new WeakMap,L=new WeakMap,E=new WeakMap,O=new WeakMap,P=new WeakMap,j=new WeakMap,U=new WeakMap,M=new WeakMap,q=new WeakMap,Q=new WeakMap,Z=new WeakMap,K=new WeakMap,fe=new WeakMap,X=new WeakMap,he=new WeakMap,xe=new WeakSet,l3=function(){const me=new c(_e(this,b)),Se=new c(_e(this,b));_t(this,K,me),_t(this,Z,Se),_t(this,Ne,(Te,Le,$e=t.now())=>{if(Se[Te]=Le!==0?$e:0,me[Te]=Le,Le!==0&&this.ttlAutopurge){const We=setTimeout(()=>{_e(this,ge).call(this,Te)&&ct(this,re,Ca).call(this,_e(this,L)[Te],"expire")},Le+1);We.unref&&We.unref()}}),_t(this,ae,Te=>{Se[Te]=me[Te]!==0?t.now():0}),_t(this,Oe,(Te,Le)=>{if(me[Le]){const $e=me[Le],We=Se[Le];if(!$e||!We)return;Te.ttl=$e,Te.start=We,Te.now=W||we();const tt=Te.now-We;Te.remainingTTL=$e-tt}});let W=0;const we=()=>{const Te=t.now();if(this.ttlResolution>0){W=Te;const Le=setTimeout(()=>W=0,this.ttlResolution);Le.unref&&Le.unref()}return Te};this.getRemainingTTL=Te=>{const Le=_e(this,D).get(Te);if(Le===void 0)return 0;const $e=me[Le],We=Se[Le];if(!$e||!We)return 1/0;const tt=(W||we())-We;return $e-tt},_t(this,ge,Te=>{const Le=Se[Te],$e=me[Te];return!!$e&&!!Le&&(W||we())-Le>$e})},ae=new WeakMap,Oe=new WeakMap,Ne=new WeakMap,ge=new WeakMap,de=new WeakSet,w7=function(){const me=new c(_e(this,b));_t(this,A,0),_t(this,Q,me),_t(this,$,Se=>{_t(this,A,_e(this,A)-me[Se]),me[Se]=0}),_t(this,R,(Se,W,we,Te)=>{if(ct(this,Ie,pr).call(this,W))return 0;if(!o(we))if(Te){if(typeof Te!="function")throw new TypeError("sizeCalculation must be a function");if(we=Te(W,Se),!o(we))throw new TypeError("sizeCalculation return invalid (expect positive integer)")}else throw new TypeError("invalid size value (must be positive integer). When maxSize or maxEntrySize is used, sizeCalculation or size must be set.");return we}),_t(this,N,(Se,W,we)=>{if(me[Se]=W,_e(this,m)){const Te=_e(this,m)-me[Se];for(;_e(this,A)>Te;)ct(this,Y,q1).call(this,!0)}_t(this,A,_e(this,A)+me[Se]),we&&(we.entrySize=W,we.totalCalculatedSize=_e(this,A))})},$=new WeakMap,N=new WeakMap,R=new WeakMap,T=new WeakSet,Da=function*({allowStale:me=this.allowStale}={}){if(_e(this,S))for(let Se=_e(this,U);!(!ct(this,V,d3).call(this,Se)||((me||!_e(this,ge).call(this,Se))&&(yield Se),Se===_e(this,j)));)Se=_e(this,P)[Se]},B=new WeakSet,Na=function*({allowStale:me=this.allowStale}={}){if(_e(this,S))for(let Se=_e(this,j);!(!ct(this,V,d3).call(this,Se)||((me||!_e(this,ge).call(this,Se))&&(yield Se),Se===_e(this,U)));)Se=_e(this,O)[Se]},V=new WeakSet,d3=function(me){return me!==void 0&&_e(this,D).get(_e(this,L)[me])===me},Y=new WeakSet,q1=function(me){var Te,Le;const Se=_e(this,j),W=_e(this,L)[Se],we=_e(this,E)[Se];return _e(this,X)&&ct(this,Ie,pr).call(this,we)?we.__abortController.abort(new Error("evicted")):(_e(this,fe)||_e(this,he))&&(_e(this,fe)&&((Te=_e(this,g))==null||Te.call(this,we,W,"evict")),_e(this,he)&&((Le=_e(this,q))==null||Le.push([we,W,"evict"]))),_e(this,$).call(this,Se),me&&(_e(this,L)[Se]=void 0,_e(this,E)[Se]=void 0,_e(this,M).push(Se)),_e(this,S)===1?(_t(this,j,_t(this,U,0)),_e(this,M).length=0):_t(this,j,_e(this,O)[Se]),_e(this,D).delete(W),$y(this,S)._--,Se},ce=new WeakSet,B1=function(me,Se,W,we){const Te=Se===void 0?void 0:_e(this,E)[Se];if(ct(this,Ie,pr).call(this,Te))return Te;const Le=new n,{signal:$e}=W;$e==null||$e.addEventListener("abort",()=>Le.abort($e.reason),{signal:Le.signal});const We={signal:Le.signal,options:W,context:we},tt=(pe,De=!1)=>{const{aborted:Ue}=Le.signal,Fe=W.ignoreFetchAbort&&pe!==void 0;if(W.status&&(Ue&&!De?(W.status.fetchAborted=!0,W.status.fetchError=Le.signal.reason,Fe&&(W.status.fetchAbortIgnored=!0)):W.status.fetchResolved=!0),Ue&&!Fe&&!De)return ut(Le.signal.reason);const Ye=C;return _e(this,E)[Se]===C&&(pe===void 0?Ye.__staleWhileFetching?_e(this,E)[Se]=Ye.__staleWhileFetching:ct(this,re,Ca).call(this,me,"fetch"):(W.status&&(W.status.fetchUpdated=!0),this.set(me,pe,We.options))),pe},lt=pe=>(W.status&&(W.status.fetchRejected=!0,W.status.fetchError=pe),ut(pe)),ut=pe=>{const{aborted:De}=Le.signal,Ue=De&&W.allowStaleOnFetchAbort,Fe=Ue||W.allowStaleOnFetchRejection,Ye=Fe||W.noDeleteOnFetchRejection,Ve=C;if(_e(this,E)[Se]===C&&(!Ye||Ve.__staleWhileFetching===void 0?ct(this,re,Ca).call(this,me,"fetch"):Ue||(_e(this,E)[Se]=Ve.__staleWhileFetching)),Fe)return W.status&&Ve.__staleWhileFetching!==void 0&&(W.status.returnedStale=!0),Ve.__staleWhileFetching;if(Ve.__returned===Ve)throw pe},le=(pe,De)=>{var Fe;const Ue=(Fe=_e(this,_))==null?void 0:Fe.call(this,me,Te,We);Ue&&Ue instanceof Promise&&Ue.then(Ye=>pe(Ye===void 0?void 0:Ye),De),Le.signal.addEventListener("abort",()=>{(!W.ignoreFetchAbort||W.allowStaleOnFetchAbort)&&(pe(void 0),W.allowStaleOnFetchAbort&&(pe=Ye=>tt(Ye,!0)))})};W.status&&(W.status.fetchDispatched=!0);const C=new Promise(le).then(tt,lt),ee=Object.assign(C,{__abortController:Le,__staleWhileFetching:Te,__returned:void 0});return Se===void 0?(this.set(me,ee,{...We.options,status:void 0}),Se=_e(this,D).get(me)):_e(this,E)[Se]=ee,ee},Ie=new WeakSet,pr=function(me){if(!_e(this,X))return!1;const Se=me;return!!Se&&Se instanceof Promise&&Se.hasOwnProperty("__staleWhileFetching")&&Se.__abortController instanceof n},qe=new WeakSet,f3=function(me,Se){_e(this,P)[Se]=me,_e(this,O)[me]=Se},F=new WeakSet,R0=function(me){me!==_e(this,U)&&(me===_e(this,j)?_t(this,j,_e(this,O)[me]):ct(this,qe,f3).call(this,_e(this,P)[me],_e(this,O)[me]),ct(this,qe,f3).call(this,_e(this,U),me),_t(this,U,me))},re=new WeakSet,Ca=function(me,Se){var we,Te,Le,$e;let W=!1;if(_e(this,S)!==0){const We=_e(this,D).get(me);if(We!==void 0)if(W=!0,_e(this,S)===1)ct(this,Re,h3).call(this,Se);else{_e(this,$).call(this,We);const tt=_e(this,E)[We];if(ct(this,Ie,pr).call(this,tt)?tt.__abortController.abort(new Error("deleted")):(_e(this,fe)||_e(this,he))&&(_e(this,fe)&&((we=_e(this,g))==null||we.call(this,tt,me,Se)),_e(this,he)&&((Te=_e(this,q))==null||Te.push([tt,me,Se]))),_e(this,D).delete(me),_e(this,L)[We]=void 0,_e(this,E)[We]=void 0,We===_e(this,U))_t(this,U,_e(this,P)[We]);else if(We===_e(this,j))_t(this,j,_e(this,O)[We]);else{const lt=_e(this,P)[We];_e(this,O)[lt]=_e(this,O)[We];const ut=_e(this,O)[We];_e(this,P)[ut]=_e(this,P)[We]}$y(this,S)._--,_e(this,M).push(We)}}if(_e(this,he)&&((Le=_e(this,q))!=null&&Le.length)){const We=_e(this,q);let tt;for(;tt=We==null?void 0:We.shift();)($e=_e(this,v))==null||$e.call(this,...tt)}return W},Re=new WeakSet,h3=function(me){var Se,W,we;for(const Te of ct(this,B,Na).call(this,{allowStale:!0})){const Le=_e(this,E)[Te];if(ct(this,Ie,pr).call(this,Le))Le.__abortController.abort(new Error("deleted"));else{const $e=_e(this,L)[Te];_e(this,fe)&&((Se=_e(this,g))==null||Se.call(this,Le,$e,me)),_e(this,he)&&((W=_e(this,q))==null||W.push([Le,$e,me]))}}if(_e(this,D).clear(),_e(this,E).fill(void 0),_e(this,L).fill(void 0),_e(this,K)&&_e(this,Z)&&(_e(this,K).fill(0),_e(this,Z).fill(0)),_e(this,Q)&&_e(this,Q).fill(0),_t(this,j,0),_t(this,U,0),_e(this,M).length=0,_t(this,A,0),_t(this,S,0),_e(this,he)&&_e(this,q)){const Te=_e(this,q);let Le;for(;Le=Te==null?void 0:Te.shift();)(we=_e(this,v))==null||we.call(this,...Le)}};let h=Qe;return Uf.LRUCache=h,Uf}var KC;function OY(){if(KC)return Bf;KC=1,Object.defineProperty(Bf,"__esModule",{value:!0}),Bf.ActorQueryOperationReducedHash=void 0;const t=wt(),e=is();let u=class extends t.ActorQueryOperationTypedMediated{constructor(n){super(n,"reduced")}async testOperation(n,r){return!0}async runOperation(n,r){const a=t.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:n.input,context:r}));return{type:"bindings",bindingsStream:a.bindingsStream.filter(await this.newHashFilter(r)),metadata:a.metadata}}async newHashFilter(n){const{hashFunction:r}=await this.mediatorHashBindings.mediate({allowHashCollisions:!0,context:n}),a=new e.LRUCache({max:this.cacheSize});return o=>{const l=r(o);return a.has(l)?!1:(a.set(l,!0),!0)}}};return Bf.ActorQueryOperationReducedHash=u,Bf}var YC;function RY(){return YC||(YC=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(OY(),t)}(ow)),ow}var uw={},Hf={},ZC;function xY(){if(ZC)return Hf;ZC=1,Object.defineProperty(Hf,"__esModule",{value:!0}),Hf.ActorQueryOperationSlice=void 0;const t=wt(),e=Lt;let u=class extends t.ActorQueryOperationTypedMediated{constructor(n){super(n,"slice")}async testOperation(n,r){return!0}async runOperation(n,r){n.length&&(r=r.set(e.KeysQueryOperation.limitIndicator,n.length));const a=await this.mediatorQueryOperation.mediate({operation:n.input,context:r});if(a.type==="bindings")return{type:"bindings",bindingsStream:this.sliceStream(a.bindingsStream,n),metadata:this.sliceMetadata(a,n)};if(a.type==="quads")return{type:"quads",quadStream:this.sliceStream(a.quadStream,n),metadata:this.sliceMetadata(a,n)};throw new Error(`Invalid query output type: Expected 'bindings' or 'quads' but got '${a.type}'`)}sliceStream(n,r){const a=!!r.length||r.length===0,{start:o}=r,l=a?r.start+r.length-1:Number.POSITIVE_INFINITY;return n.transform({offset:o,limit:Math.max(l-o+1,0),autoStart:!1})}sliceMetadata(n,r){const a=!!r.length||r.length===0;return()=>n.metadata().then(o=>{const l={...o.cardinality};return Number.isFinite(l.value)&&(l.value=Math.max(0,l.value-r.start),a&&(l.value=Math.min(l.value,r.length))),{...o,cardinality:l}})}};return Hf.ActorQueryOperationSlice=u,Hf}var e8;function IY(){return e8||(e8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(xY(),t)}(uw)),uw}var cw={},$f={},t8;function PY(){if(t8)return $f;t8=1,Object.defineProperty($f,"__esModule",{value:!0}),$f.ActorQueryOperationUnion=void 0;const t=wt(),e=jn(),u=Nt(),s=un();let n=class U1 extends t.ActorQueryOperationTypedMediated{constructor(a){super(a,"union")}static unionVariables(a){return(0,s.uniqTerms)(a.flat())}static async unionMetadata(a,o,l,c){let d=(await c.mediate({mode:"initialize",context:l})).metadata;for(const f of a)d={...f,...(await c.mediate({mode:"append",accumulatedMetadata:d,appendingMetadata:f,context:l})).metadata};d.state=new e.MetadataValidationState;const h=()=>d.state.invalidate();for(const f of a)f.state.addInvalidateListener(h);return o&&(d.variables=U1.unionVariables(a.map(f=>f.variables))),d}async testOperation(a,o){return!0}async runOperation(a,o){const l=await Promise.all(a.input.map(d=>this.mediatorQueryOperation.mediate({operation:d,context:o})));let c;for(const d of l)if(c===void 0)c=d.type;else if(c!==d.type)throw new Error(`Unable to union ${c} and ${d.type}`);if(c==="bindings"||a.input.length===0){const d=l.map(t.ActorQueryOperation.getSafeBindings);return{type:"bindings",bindingsStream:new u.UnionIterator(d.map(p=>p.bindingsStream),{autoStart:!1}),metadata:()=>Promise.all(d.map(p=>p.metadata())).then(p=>U1.unionMetadata(p,!0,o,this.mediatorRdfMetadataAccumulate))}}if(c==="quads"){const d=l.map(t.ActorQueryOperation.getSafeQuads);return{type:"quads",quadStream:new u.UnionIterator(d.map(p=>p.quadStream),{autoStart:!1}),metadata:()=>Promise.all(d.map(p=>p.metadata())).then(p=>U1.unionMetadata(p,!1,o,this.mediatorRdfMetadataAccumulate))}}throw new Error(`Unable to union ${c}`)}};return $f.ActorQueryOperationUnion=n,$f}var r8;function S7(){return r8||(r8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(PY(),t)}(cw)),cw}var lw={},Qf={},dw={},Vf={},kf={},n8;function T7(){if(n8)return kf;n8=1,Object.defineProperty(kf,"__esModule",{value:!0}),kf.PathVariableObjectIterator=void 0;const t=wt(),e=Nt(),u=Et(),s=er(),n=Ot(),r=new u.DataFactory,a=new n.Factory;let o=class extends e.BufferedIterator{constructor(c,d,h,f,p,y,b=16){super({autoStart:!0}),this.subject=c,this.predicate=d,this.graph=h,this.context=f,this.mediatorQueryOperation=p,this.maxRunningOperations=b,this.termHashes=new Map,this.runningOperations=[],this.pendingOperations=[],this._push(this.subject,y)}_end(c){for(const d of this.runningOperations)d.destroy();super._end(c)}_push(c,d=!0){let h;if(d&&(h=(0,s.termToString)(c),this.termHashes.has(h)))return;const f=r.variable("b");this.pendingOperations.push({variable:f,operation:a.createPath(c,this.predicate,f,this.graph)}),h&&(this.termHashes.set(h,c),super._push(c))}_read(c,d){const h=this;(async function(){for(;h.runningOperations.lengthh.destroy(g)),m.on("readable",()=>{h.readable=!0,h._fillBufferAsync()}),m.on("end",()=>{h.runningOperations.splice(h.runningOperations.indexOf(m),1),h.readable=!0,h._fillBufferAsync()})),h.setProperty("metadata",b.metadata)}let f=0,p;for(;f!==(f=c);)for(let y=0;y0;y++)(p=h.runningOperations[y].read())!==null&&(c--,h._push(p));h.runningOperations.length===0&&h.pendingOperations.length===0&&h.close()})().then(()=>{d()},f=>this.destroy(f))}};return kf.PathVariableObjectIterator=o,kf}var i8;function DY(){if(i8)return Vf;i8=1,Object.defineProperty(Vf,"__esModule",{value:!0}),Vf.ActorAbstractPath=void 0;const t=wt(),e=Lt,u=Nt(),s=Et(),n=er(),r=Ot(),a=T7(),o=new s.DataFactory;let l=class ha extends t.ActorQueryOperationTypedMediated{constructor(d,h){super(d,"path"),this.predicateType=h}async testOperation(d,h){if(d.predicate.type!==this.predicateType)throw new Error(`This Actor only supports ${this.predicateType} Path operations.`);return!0}generateVariable(d,h){return h?d&&(d.subject.value===h||d.object.value===h)?this.generateVariable(d,`${h}b`):o.variable(h):this.generateVariable(d,"b")}async isPathArbitraryLengthDistinct(d,h){return d.get(e.KeysQueryOperation.isPathArbitraryLengthDistinctKey)?(d=d.set(e.KeysQueryOperation.isPathArbitraryLengthDistinctKey,!1),{context:d,operation:void 0}):(d=d.set(e.KeysQueryOperation.isPathArbitraryLengthDistinctKey,!0),{context:d,operation:t.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:ha.FACTORY.createDistinct(h),context:d}))})}async predicateStarGraphVariable(d,h,f,p,y,b){const m=this.getPathSources(f),g=this.generateVariable(ha.FACTORY.createPath(d,f,h,p)),v=ha.FACTORY.createUnion([this.assignPatternSources(ha.FACTORY.createPattern(d,g,h,p),m),this.assignPatternSources(ha.FACTORY.createPattern(h,g,d,p),m)]),_=t.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({context:y,operation:v})),w=new Set;return{bindingsStream:new u.MultiTransformIterator(_.bindingsStream,{multiTransform:A=>{const D=A.get(p);return w.has(D.value)?new u.EmptyIterator:(w.add(D.value),new u.TransformIterator(async()=>{const L=new u.BufferedIterator;return await this.getObjectsPredicateStar(d,f,D,y,{},L,{count:0}),L.transform({transform(E,O,P){P(b.bindings([[h,E],[p,D]])),O()}})},{maxBufferSize:128}))},autoStart:!1}),metadata:_.metadata}}async getObjectsPredicateStarEval(d,h,f,p,y,b,m){if(p.termType==="Variable")return this.predicateStarGraphVariable(d,f,h,p,y,m);const g=new a.PathVariableObjectIterator(d,h,p,y,this.mediatorQueryOperation,b);return{bindingsStream:g.transform({autoStart:!1,transform(_,w,S){S(m.bindings([[f,_]])),w()}}),async metadata(){const _=await new Promise(w=>{g.getProperty("metadata",S=>w(S()))});return _.cardinality.value++,_}}}async getObjectsPredicateStar(d,h,f,p,y,b,m){const g=(0,n.termToString)(d);if(y[g])return;b._push(d),y[g]=d,m.count++;const v=this.generateVariable(),_=ha.FACTORY.createPath(d,h,v,f),w=t.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:_,context:p}));return w.bindingsStream.on("data",async S=>{const A=S.get(v);await this.getObjectsPredicateStar(A,h,f,p,y,b,m)}),w.bindingsStream.on("end",()=>{--m.count===0&&b.close()}),w.metadata}async getSubjectAndObjectBindingsPredicateStar(d,h,f,p,y,b,m,g,v,_,w,S){const A=(0,n.termToString)(p)+(0,n.termToString)(b);if(v[A])return;if(w.count++,v[A]=!0,_._push(S.bindings([[d,f],[h,p]])),A in g){const L=await g[A];for(const E of L)await this.getSubjectAndObjectBindingsPredicateStar(d,h,f,E,y,b,m,g,v,_,w,S);--w.count===0&&_.close();return}const D=new Promise(async(L,E)=>{const O=[],P=this.generateVariable(),j=ha.FACTORY.createPath(p,y,P,b),U=t.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:j,context:m}));U.bindingsStream.on("data",async M=>{const q=M.get(P);O.push(q),await this.getSubjectAndObjectBindingsPredicateStar(d,h,f,q,y,b,m,g,v,_,w,S)}),U.bindingsStream.on("error",E),U.bindingsStream.on("end",()=>{--w.count===0&&_.close(),L(O)})});g[A]=D}getPathSources(d){switch(d.type){case r.Algebra.types.ALT:case r.Algebra.types.SEQ:return d.input.flatMap(h=>this.getPathSources(h));case r.Algebra.types.INV:case r.Algebra.types.ONE_OR_MORE_PATH:case r.Algebra.types.ZERO_OR_MORE_PATH:case r.Algebra.types.ZERO_OR_ONE_PATH:return this.getPathSources(d.path);case r.Algebra.types.LINK:case r.Algebra.types.NPS:{const h=t.ActorQueryOperation.getOperationSource(d);if(!h)throw new Error("Could not find a required source on a link path operation");return[h]}}}assignPatternSources(d,h){if(h.length===0)throw new Error("Attempted to assign zero sources to a pattern during property path handling");return h.length===1?t.ActorQueryOperation.assignOperationSource(d,h[0]):ha.FACTORY.createUnion(h.map(f=>t.ActorQueryOperation.assignOperationSource(d,f)),!0)}};return Vf.ActorAbstractPath=l,l.FACTORY=new r.Factory,Vf}var a8;function as(){return a8||(a8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(DY(),t),u(T7(),t)}(dw)),dw}var s8;function NY(){if(s8)return Qf;s8=1,Object.defineProperty(Qf,"__esModule",{value:!0}),Qf.ActorQueryOperationPathAlt=void 0;const t=as(),e=S7(),u=wt(),s=Nt(),n=Ot();let r=class extends t.ActorAbstractPath{constructor(o){super(o,n.Algebra.types.ALT)}async runOperation(o,l){const c=o.predicate,d=(await Promise.all(c.input.map(p=>this.mediatorQueryOperation.mediate({context:l,operation:t.ActorAbstractPath.FACTORY.createPath(o.subject,p,o.object,o.graph)})))).map(u.ActorQueryOperation.getSafeBindings);return{type:"bindings",bindingsStream:new s.UnionIterator(d.map(p=>p.bindingsStream),{autoStart:!1}),metadata:()=>Promise.all(d.map(p=>p.metadata())).then(p=>e.ActorQueryOperationUnion.unionMetadata(p,!0,l,this.mediatorRdfMetadataAccumulate))}}};return Qf.ActorQueryOperationPathAlt=r,Qf}var o8;function CY(){return o8||(o8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(NY(),t)}(lw)),lw}var fw={},zf={},u8;function jY(){if(u8)return zf;u8=1,Object.defineProperty(zf,"__esModule",{value:!0}),zf.ActorQueryOperationPathInv=void 0;const t=as(),e=Ot();let u=class extends t.ActorAbstractPath{constructor(n){super(n,e.Algebra.types.INV)}async runOperation(n,r){const a=n.predicate,o=t.ActorAbstractPath.FACTORY.createPath(n.object,a.path,n.subject,n.graph);return this.mediatorQueryOperation.mediate({operation:o,context:r})}};return zf.ActorQueryOperationPathInv=u,zf}var c8;function LY(){return c8||(c8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(jY(),t)}(fw)),fw}var hw={},Gf={},l8;function MY(){if(l8)return Gf;l8=1,Object.defineProperty(Gf,"__esModule",{value:!0}),Gf.ActorQueryOperationPathLink=void 0;const t=as(),e=Ot();let u=class extends t.ActorAbstractPath{constructor(n){super(n,e.Algebra.types.LINK)}async runOperation(n,r){const a=n.predicate,o=Object.assign(t.ActorAbstractPath.FACTORY.createPattern(n.subject,a.iri,n.object,n.graph),{metadata:a.metadata});return this.mediatorQueryOperation.mediate({operation:o,context:r})}};return Gf.ActorQueryOperationPathLink=u,Gf}var d8;function FY(){return d8||(d8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(MY(),t)}(hw)),hw}var pw={},Wf={},f8;function qY(){if(f8)return Wf;f8=1,Object.defineProperty(Wf,"__esModule",{value:!0}),Wf.ActorQueryOperationPathNps=void 0;const t=as(),e=wt(),u=Ot();let s=class extends t.ActorAbstractPath{constructor(r){super(r,u.Algebra.types.NPS)}async runOperation(r,a){const o=r.predicate,l=this.generateVariable(r),c=Object.assign(t.ActorAbstractPath.FACTORY.createPattern(r.subject,l,r.object,r.graph),{metadata:o.metadata}),d=e.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:c,context:a}));return{type:"bindings",bindingsStream:d.bindingsStream.map(f=>o.iris.some(p=>p.equals(f.get(l)))?null:f.delete(l)),metadata:d.metadata}}};return Wf.ActorQueryOperationPathNps=s,Wf}var h8;function BY(){return h8||(h8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(qY(),t)}(pw)),pw}var yw={},Jf={},p8;function UY(){if(p8)return Jf;p8=1,Object.defineProperty(Jf,"__esModule",{value:!0}),Jf.ActorQueryOperationClear=void 0;const t=wt(),e=Et(),u=new e.DataFactory;let s=class extends t.ActorQueryOperationTypedMediated{constructor(r){super(r,"clear")}async testOperation(r,a){return t.ActorQueryOperation.throwOnReadOnly(a),!0}async runOperation(r,a){let o;r.source==="DEFAULT"?o=u.defaultGraph():typeof r.source=="string"?o=r.source:o=[r.source];const{execute:l}=await this.mediatorUpdateQuads.mediate({deleteGraphs:{graphs:o,requireExistence:!r.silent,dropGraphs:!1},context:a});return{type:"void",execute:l}}};return Jf.ActorQueryOperationClear=s,Jf}var y8;function HY(){return y8||(y8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(UY(),t)}(yw)),yw}var bw={},Xf={},b8;function $Y(){if(b8)return Xf;b8=1,Object.defineProperty(Xf,"__esModule",{value:!0}),Xf.ActorQueryOperationUpdateCompositeUpdate=void 0;const t=wt();let e=class extends t.ActorQueryOperationTypedMediated{constructor(s){super(s,"compositeupdate")}async testOperation(s,n){return t.ActorQueryOperation.throwOnReadOnly(n),!0}async runOperation(s,n){return{type:"void",execute:()=>(async()=>{for(const a of s.updates)await t.ActorQueryOperation.getSafeVoid(await this.mediatorQueryOperation.mediate({operation:a,context:n})).execute()})()}}};return Xf.ActorQueryOperationUpdateCompositeUpdate=e,Xf}var g8;function QY(){return g8||(g8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u($Y(),t)}(bw)),bw}var gw={},Kf={},m8;function VY(){if(m8)return Kf;m8=1,Object.defineProperty(Kf,"__esModule",{value:!0}),Kf.ActorQueryOperationCreate=void 0;const t=wt();let e=class extends t.ActorQueryOperationTypedMediated{constructor(s){super(s,"create")}async testOperation(s,n){return t.ActorQueryOperation.throwOnReadOnly(n),!0}async runOperation(s,n){const{execute:r}=await this.mediatorUpdateQuads.mediate({createGraphs:{graphs:[s.source],requireNonExistence:!s.silent},context:n});return{type:"void",execute:r}}};return Kf.ActorQueryOperationCreate=e,Kf}var _8;function kY(){return _8||(_8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(VY(),t)}(gw)),gw}var mw={},Yf={},v8;function zY(){if(v8)return Yf;v8=1,Object.defineProperty(Yf,"__esModule",{value:!0}),Yf.ActorQueryOperationDrop=void 0;const t=wt(),e=Et(),u=new e.DataFactory;let s=class extends t.ActorQueryOperationTypedMediated{constructor(r){super(r,"drop")}async testOperation(r,a){return t.ActorQueryOperation.throwOnReadOnly(a),!0}async runOperation(r,a){let o;r.source==="DEFAULT"?o=u.defaultGraph():typeof r.source=="string"?o=r.source:o=[r.source];const{execute:l}=await this.mediatorUpdateQuads.mediate({deleteGraphs:{graphs:o,requireExistence:!r.silent,dropGraphs:!0},context:a});return{type:"void",execute:l}}};return Yf.ActorQueryOperationDrop=s,Yf}var w8;function GY(){return w8||(w8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(zY(),t)}(mw)),mw}var _w={},Zf={},S8;function WY(){if(S8)return Zf;S8=1,Object.defineProperty(Zf,"__esModule",{value:!0}),Zf.ActorQueryOperationLoad=void 0;const t=wt(),e=Lt,u=Et(),s=Ot(),n=new u.DataFactory;let r=class A7 extends t.ActorQueryOperationTypedMediated{constructor(o){super(o,"load"),this.factory=new s.Factory}async testOperation(o,l){return t.ActorQueryOperation.throwOnReadOnly(l),!0}async runOperation(o,l){let c=l;o.silent&&(c=c.set(e.KeysInitQuery.lenient,!0));const{querySource:d}=await this.mediatorQuerySourceIdentify.mediate({querySourceUnidentified:{value:o.source.value},context:c});let f=A7.getSafeQuads(await this.mediatorQueryOperation.mediate({operation:this.factory.createConstruct(t.ActorQueryOperation.assignOperationSource(this.factory.createPattern(n.variable("s"),n.variable("p"),n.variable("o")),d),[this.factory.createPattern(n.variable("s"),n.variable("p"),n.variable("o"))]),context:c})).quadStream;o.destination&&(f=f.map(y=>n.quad(y.subject,y.predicate,y.object,o.destination)));const{execute:p}=await this.mediatorUpdateQuads.mediate({quadStreamInsert:f,context:l});return{type:"void",execute:p}}};return Zf.ActorQueryOperationLoad=r,Zf}var T8;function JY(){return T8||(T8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(WY(),t)}(_w)),_w}var vw={},eh={},A8;function XY(){if(A8)return eh;A8=1,Object.defineProperty(eh,"__esModule",{value:!0}),eh.ActorQueryOperationJoin=void 0;const t=wt();let e=class extends t.ActorQueryOperationTypedMediated{constructor(s){super(s,"join")}async testOperation(s,n){return!0}async runOperation(s,n){const r=(await Promise.all(s.input.map(async a=>({output:await this.mediatorQueryOperation.mediate({operation:a,context:n}),operation:a})))).map(({output:a,operation:o})=>({output:t.ActorQueryOperation.getSafeBindings(a),operation:o}));return this.mediatorJoin.mediate({type:"inner",entries:r,context:n})}};return eh.ActorQueryOperationJoin=e,eh}var E8;function KY(){return E8||(E8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(XY(),t)}(vw)),vw}var ww={},th={},O8;function YY(){if(O8)return th;O8=1,Object.defineProperty(th,"__esModule",{value:!0}),th.ActorQueryOperationMinus=void 0;const t=wt();let e=class extends t.ActorQueryOperationTypedMediated{constructor(s){super(s,"minus")}async testOperation(s,n){return!0}async runOperation(s,n){const r=(await Promise.all(s.input.map(async a=>({output:await this.mediatorQueryOperation.mediate({operation:a,context:n}),operation:a})))).map(({output:a,operation:o})=>({output:t.ActorQueryOperation.getSafeBindings(a),operation:o}));return this.mediatorJoin.mediate({type:"minus",entries:r,context:n})}};return th.ActorQueryOperationMinus=e,th}var R8;function ZY(){return R8||(R8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(YY(),t)}(ww)),ww}var Sw={},rh={},x8;function eZ(){if(x8)return rh;x8=1,Object.defineProperty(rh,"__esModule",{value:!0}),rh.ActorQueryOperationPathSeq=void 0;const t=as(),e=wt(),u=Ot();let s=class extends t.ActorAbstractPath{constructor(r){super(r,u.Algebra.types.SEQ)}async runOperation(r,a){const o=r.predicate;let l=r.subject;const c=[],d=await Promise.all(o.input.map((p,y)=>{const b=y===o.input.length-1?r.object:this.generateVariable(r,`b${y}`),m=t.ActorAbstractPath.FACTORY.createPath(l,p,b,r.graph),g=this.mediatorQueryOperation.mediate({context:a,operation:m});return l=b,y({output:e.ActorQueryOperation.getSafeBindings(await p),operation:y}))),h=e.ActorQueryOperation.getSafeBindings(await this.mediatorJoin.mediate({type:"inner",entries:d,context:a}));return{type:"bindings",bindingsStream:h.bindingsStream.transform({transform(p,y,b){for(const m of c)p=p.delete(m);b(p),y()}}),async metadata(){const p=await h.metadata(),y=p.variables.filter(b=>!c.some(m=>m.value===b.value));return{...p,variables:y}}}}};return rh.ActorQueryOperationPathSeq=s,rh}var I8;function tZ(){return I8||(I8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(eZ(),t)}(Sw)),Sw}var Tw={},nh={},P8;function rZ(){if(P8)return nh;P8=1,Object.defineProperty(nh,"__esModule",{value:!0}),nh.ActorRdfJoinMultiSmallest=void 0;const t=wt(),e=Ln(),u=Ot();let s=class E7 extends e.ActorRdfJoin{constructor(r){super(r,{logicalType:"inner",physicalName:"multi-smallest",limitEntries:3,limitEntriesMin:!0,canHandleUndefs:!0,isLeaf:!1})}async sortJoinEntries(r,a){return(await this.mediatorJoinEntriesSort.mediate({entries:r,context:a})).entries}async getOutput(r){const a=await this.sortJoinEntries(await e.ActorRdfJoin.getEntriesWithMetadatas([...r.entries]),r.context),o=a[0],l=a[1];a.splice(0,2);const c={output:t.ActorQueryOperation.getSafeBindings(await this.mediatorJoin.mediate({type:r.type,entries:[o,l],context:r.context})),operation:E7.FACTORY.createJoin([o.operation,l.operation],!1)};return a.push(c),{result:await this.mediatorJoin.mediate({type:r.type,entries:a,context:r.context})}}async getJoinCoefficients(r,a){a=[...a],a=(await this.sortJoinEntries(r.entries.map((d,h)=>({...d,metadata:a[h]})),r.context)).map(d=>d.metadata);const l=e.ActorRdfJoin.getRequestInitialTimes(a),c=e.ActorRdfJoin.getRequestItemTimes(a);return{iterations:a[0].cardinality.value*a[1].cardinality.value*a.slice(2).reduce((d,h)=>d*h.cardinality.value,1),persistedItems:0,blockingItems:0,requestTime:l[0]+a[0].cardinality.value*c[0]+l[1]+a[1].cardinality.value*c[1]+a.slice(2).reduce((d,h,f)=>d+l.slice(2)[f]+h.cardinality.value*c.slice(2)[f],0)}}};return nh.ActorRdfJoinMultiSmallest=s,s.FACTORY=new u.Factory,nh}var D8;function nZ(){return D8||(D8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(rZ(),t)}(Tw)),Tw}var Aw={},ih={},Ew={},ah={},sh={},N8;function O7(){if(N8)return sh;N8=1,Object.defineProperty(sh,"__esModule",{value:!0}),sh.bindingsToString=void 0;const t=er();function e(u){const s={};for(const n of u.keys())s[n.value]=(0,t.termToString)(u.get(n));return JSON.stringify(s,null," ")}return sh.bindingsToString=e,sh}var C8;function R7(){if(C8)return ah;C8=1,Object.defineProperty(ah,"__esModule",{value:!0}),ah.Bindings=void 0;const t=ot,e=AT,u=O7();let s=class ni{constructor(r,a,o){this.type="bindings",this.dataFactory=r,this.entries=a,this.contextHolder=o}has(r){return this.entries.has(typeof r=="string"?r:r.value)}get(r){return this.entries.get(typeof r=="string"?r:r.value)}set(r,a){return new ni(this.dataFactory,this.entries.set(typeof r=="string"?r:r.value,a),this.contextHolder)}delete(r){return new ni(this.dataFactory,this.entries.delete(typeof r=="string"?r:r.value),this.contextHolder)}keys(){return this.mapIterable(this.iteratorToIterable(this.entries.keys()),r=>this.dataFactory.variable(r))}values(){return this.iteratorToIterable(this.entries.values())}forEach(r){for(const[a,o]of this.entries.entries())r(o,this.dataFactory.variable(a))}get size(){return this.entries.size}[Symbol.iterator](){return this.mapIterable(this.iteratorToIterable(this.entries.entries()),([r,a])=>[this.dataFactory.variable(r),a])[Symbol.iterator]()}equals(r){var a;if(!r)return!1;if(this===r)return!0;if(this.size!==r.size)return!1;for(const o of this.keys())if(!((a=this.get(o))!=null&&a.equals(r.get(o))))return!1;return!0}filter(r){return new ni(this.dataFactory,(0,e.Map)(this.entries.filter((a,o)=>r(a,this.dataFactory.variable(o)))),this.contextHolder)}map(r){return new ni(this.dataFactory,(0,e.Map)(this.entries.map((a,o)=>r(a,this.dataFactory.variable(o)))),this.contextHolder)}merge(r){const a=new Set([...this.iteratorToIterable(this.entries.keys()),...[...r.keys()].map(l=>l.value)]),o=[];for(const l of a){const c=this.entries.get(l),d=r.get(this.dataFactory.variable(l));if(c&&d&&!c.equals(d))return;const h=c||d;o.push([l,h])}return this.createBindingsWithContexts(o,r)}mergeWith(r,a){const o=new Set([...this.iteratorToIterable(this.entries.keys()),...[...a.keys()].map(c=>c.value)]),l=[];for(const c of o){const d=this.dataFactory.variable(c),h=this.entries.get(c),f=a.get(d);let p;h&&f&&!h.equals(f)?p=r(h,f,d):p=h||f,l.push([c,p])}return this.createBindingsWithContexts(l,a)}createBindingsWithContexts(r,a){if(this.contextHolder&&this.contextHolder.context){let o=this.contextHolder.context;return"contextHolder"in a&&a.contextHolder&&a.contextHolder.context&&(o=ni.mergeContext(this.contextHolder.contextMergeHandlers,o,a.contextHolder.context)),new ni(this.dataFactory,(0,e.Map)(r),{contextMergeHandlers:this.contextHolder.contextMergeHandlers,context:o})}return new ni(this.dataFactory,(0,e.Map)(r),a.contextHolder)}static mergeContext(r,a,o){const l=[...a.keys(),...o.keys()],c={},d={},h=new Set(o.keys().map(p=>p.name)),f=a.keys().filter(p=>h.has(p.name));for(const p of l){if(d[p.name]===1)continue;d[p.name]=1;const y=f.some(b=>b.name===p.name);if(r[p.name]&&y){c[p.name]=r[p.name].run(a.get(p),o.get(p));continue}if(!(!r[p.name]&&y)){if(!a.get(p)){c[p.name]=o.get(p);continue}o.get(p)||(c[p.name]=a.get(p))}}return new t.ActionContext(c)}setContextEntry(r,a){return this.setContextEntryRaw(r,a)}setContextEntryRaw(r,a){var o;return this.contextHolder&&this.contextHolder.context?new ni(this.dataFactory,this.entries,{contextMergeHandlers:this.contextHolder.contextMergeHandlers,context:this.contextHolder.context.set(r,a)}):new ni(this.dataFactory,this.entries,{contextMergeHandlers:((o=this.contextHolder)==null?void 0:o.contextMergeHandlers)??{},context:new t.ActionContext().set(r,a)})}deleteContextEntry(r){return this.deleteContextEntryRaw(r)}deleteContextEntryRaw(r){var a;return this.contextHolder?new ni(this.dataFactory,this.entries,{contextMergeHandlers:this.contextHolder.contextMergeHandlers,context:(a=this.contextHolder.context)==null?void 0:a.delete(r)}):new ni(this.dataFactory,this.entries)}getContext(){var r;return(r=this.contextHolder)==null?void 0:r.context}getContextEntry(r){var a;return(a=this.getContext())==null?void 0:a.get(r)}toString(){return(0,u.bindingsToString)(this)}*mapIterable(r,a){for(const o of r)yield a(o)}iteratorToIterable(r){return{[Symbol.iterator]:()=>r}}};return ah.Bindings=s,ah}var oh={},j8;function iZ(){if(j8)return oh;j8=1,Object.defineProperty(oh,"__esModule",{value:!0}),oh.BindingsFactory=void 0;const t=AT,e=Et(),u=R7();let s=class x7{constructor(r=new e.DataFactory,a){this.dataFactory=r,this.contextMergeHandlers=a}static async create(r,a){return new x7(new e.DataFactory,(await r.mediate({context:a})).mergeHandlers)}bindings(r=[]){return new u.Bindings(this.dataFactory,(0,t.Map)(r.map(([a,o])=>[a.value,o])),this.contextMergeHandlers?{contextMergeHandlers:this.contextMergeHandlers}:void 0)}fromBindings(r){return this.bindings([...r])}fromRecord(r){return this.bindings(Object.entries(r).map(([a,o])=>[this.dataFactory.variable(a),o]))}};return oh.BindingsFactory=s,oh}var L8;function xr(){return L8||(L8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(R7(),t),u(iZ(),t),u(O7(),t)}(Ew)),Ew}var M8;function aZ(){if(M8)return ih;M8=1,Object.defineProperty(ih,"__esModule",{value:!0}),ih.ActorRdfJoinMultiSmallestFilterBindings=void 0;const t=xr(),e=wt(),u=Ln(),s=Lt,n=Nt(),r=Ot();let a=class I7 extends u.ActorRdfJoin{constructor(l){super(l,{logicalType:"inner",physicalName:"multi-smallest-filter-bindings",limitEntries:2,limitEntriesMin:!0,isLeaf:!1})}async sortJoinEntries(l,c){let{entries:d}=await this.mediatorJoinEntriesSort.mediate({entries:l,context:c});d=d.sort((m,g)=>m.operationModified&&!g.operationModified?-1:0);const h=d.splice(0,1)[0];let f,p=-1,y=0;for(const[m,g]of d.entries()){const v=h.metadata.variables.filter(_=>g.metadata.variables.some(w=>_.equals(w))).length;(!f||v>y||v===y&&(g.metadata.variables.lengthh.metadata.variables.some(L=>D.equals(L))),b={},m=p.clone().map(D=>D.filter((L,E)=>y.some(O=>O.equals(E)))).filter(D=>{const L=(0,t.bindingsToString)(D);return!(L in b)&&(b[L]=!0)}),g=new u.ChunkedIterator(m,this.blockSize,{autoStart:!1}),v=e.ActorQueryOperation.getOperationSource(h.operation),w={output:{type:"bindings",bindingsStream:new n.UnionIterator(g.map(D=>v.source.queryBindings(h.operation,v.context?l.context.merge(v.context):l.context,{filterBindings:{bindings:D,metadata:d.metadata}}))),metadata:h.output.metadata},operation:h.operation,operationModified:!0};h.output.bindingsStream.destroy();const S={output:e.ActorQueryOperation.getSafeBindings(await this.mediatorJoin.mediate({type:l.type,entries:[d,w],context:l.context.set(s.KeysRdfJoin.lastPhysicalJoin,this.physicalName)})),operation:I7.FACTORY.createJoin([d.operation,w.operation],!1),operationModified:!0},A=f;return A.unshift(S),{result:await this.mediatorJoin.mediate({type:l.type,entries:A,context:l.context}),physicalPlanMetadata:{firstIndex:c.indexOf(d),secondIndex:c.indexOf(h)}}}async getJoinCoefficients(l,c){if(l.context.get(s.KeysRdfJoin.lastPhysicalJoin)===this.physicalName)throw new Error(`Actor ${this.name} can not be called recursively`);c=[...c];const{first:d,second:h,remaining:f}=await this.sortJoinEntries(l.entries.map((w,S)=>({...w,metadata:c[S]})),l.context),p=e.ActorQueryOperation.getOperationSource(h.operation);if(!p)throw new Error(`Actor ${this.name} can only process if entries[1] has a source`);const y=h.operation,b=await p.source.getSelectorShape(l.context);if(!e.ActorQueryOperation.doesShapeAcceptOperation(b,y,{filterBindings:!0}))throw new Error(`Actor ${this.name} can only process if entries[1] accept filterBindings`);c=[d.metadata,h.metadata,...f.map(w=>w.metadata)];const m=u.ActorRdfJoin.getRequestInitialTimes(c),g=u.ActorRdfJoin.getRequestItemTimes(c),{selectivity:v}=await this.mediatorJoinSelectivity.mediate({entries:[d,h],context:l.context}),_=f.reduce((w,S)=>w*S.metadata.cardinality.value*this.selectivityModifier,1);return{iterations:v*this.selectivityModifier*h.metadata.cardinality.value*_,persistedItems:d.metadata.cardinality.value,blockingItems:d.metadata.cardinality.value,requestTime:m[0]+c[0].cardinality.value*g[0]+m[1]+_*g[1]}}};return ih.ActorRdfJoinMultiSmallestFilterBindings=a,a.FACTORY=new r.Factory,ih}var F8;function sZ(){return F8||(F8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(aZ(),t)}(Aw)),Aw}var Ow={},uh={},q8;function oZ(){if(q8)return uh;q8=1,Object.defineProperty(uh,"__esModule",{value:!0}),uh.ActorOptimizeQueryOperationFilterPushdown=void 0;const t=Ii(),e=un(),u=Ot();let s=class extends t.ActorOptimizeQueryOperation{constructor(r){super(r)}async test(r){return!0}async run(r){const a=this;return{operation:u.Util.mapOperation(r.operation,{filter(l,c){const d=a.getExpressionVariables(l.expression);return{recurse:!0,result:a.filterPushdown(l.expression,d,l.input,c,r.context)}}}),context:r.context}}getExpressionVariables(r){switch(r.expressionType){case u.Algebra.expressionTypes.AGGREGATE:case u.Algebra.expressionTypes.WILDCARD:throw new Error(`Getting expression variables is not supported for ${r.expressionType}`);case u.Algebra.expressionTypes.EXISTENCE:return u.Util.inScopeVariables(r.input);case u.Algebra.expressionTypes.NAMED:return[];case u.Algebra.expressionTypes.OPERATOR:return(0,e.uniqTerms)(r.args.flatMap(a=>this.getExpressionVariables(a)));case u.Algebra.expressionTypes.TERM:return r.term.termType==="Variable"?[r.term]:[]}}getOverlappingOperations(r,a){const o=[],l=[],c=[];for(const d of r.input){const h=u.Util.inScopeVariables(d);this.variablesSubSetOf(a,h)?o.push(d):this.variablesIntersect(a,h)?l.push(d):c.push(d)}return{fullyOverlapping:o,partiallyOverlapping:l,notOverlapping:c}}filterPushdown(r,a,o,l,c){switch(o.type){case u.Algebra.types.EXTEND:return this.variablesIntersect([o.variable],a)?l.createFilter(o,r):l.createExtend(this.filterPushdown(r,a,o.input,l,c),o.variable,o.expression);case u.Algebra.types.FILTER:return l.createFilter(this.filterPushdown(r,a,o.input,l,c),o.expression);case u.Algebra.types.JOIN:{if(o.input.length===0)return l.createFilter(o,r);const{fullyOverlapping:d,partiallyOverlapping:h,notOverlapping:f}=this.getOverlappingOperations(o,a),p=[];return this.logDebug(c,`Push down filter across join entries with ${d.length} fully overlapping, ${h.length} partially overlapping, and ${f.length} not overlapping`),d.length>0&&p.push(l.createJoin(d.map(y=>this.filterPushdown(r,a,y,l,c)))),h.length>0&&p.push(l.createFilter(l.createJoin(h,!1),r)),f.length>0&&p.push(...f),p.length===1?p[0]:l.createJoin(p)}case u.Algebra.types.NOP:return o;case u.Algebra.types.PROJECT:return this.variablesIntersect(o.variables,a)?l.createProject(this.filterPushdown(r,a,o.input,l,c),o.variables):o;case u.Algebra.types.UNION:{const{fullyOverlapping:d,partiallyOverlapping:h,notOverlapping:f}=this.getOverlappingOperations(o,a),p=[];return this.logDebug(c,`Push down filter across union entries with ${d.length} fully overlapping, ${h.length} partially overlapping, and ${f.length} not overlapping`),d.length>0&&p.push(l.createUnion(d.map(y=>this.filterPushdown(r,a,y,l,c)))),h.length>0&&p.push(l.createFilter(l.createUnion(h,!1),r)),f.length>0&&p.push(...f),p.length===1?p[0]:l.createUnion(p)}case u.Algebra.types.VALUES:return this.variablesIntersect(o.variables,a)?l.createFilter(o,r):o;case u.Algebra.types.LEFT_JOIN:case u.Algebra.types.MINUS:case u.Algebra.types.ALT:case u.Algebra.types.ASK:case u.Algebra.types.BGP:case u.Algebra.types.CONSTRUCT:case u.Algebra.types.DESCRIBE:case u.Algebra.types.DISTINCT:case u.Algebra.types.EXPRESSION:case u.Algebra.types.FROM:case u.Algebra.types.GRAPH:case u.Algebra.types.GROUP:case u.Algebra.types.INV:case u.Algebra.types.LINK:case u.Algebra.types.NPS:case u.Algebra.types.ONE_OR_MORE_PATH:case u.Algebra.types.ORDER_BY:case u.Algebra.types.PATTERN:case u.Algebra.types.REDUCED:case u.Algebra.types.SEQ:case u.Algebra.types.SERVICE:case u.Algebra.types.SLICE:case u.Algebra.types.PATH:case u.Algebra.types.ZERO_OR_MORE_PATH:case u.Algebra.types.ZERO_OR_ONE_PATH:case u.Algebra.types.COMPOSITE_UPDATE:case u.Algebra.types.DELETE_INSERT:case u.Algebra.types.LOAD:case u.Algebra.types.CLEAR:case u.Algebra.types.CREATE:case u.Algebra.types.DROP:case u.Algebra.types.ADD:case u.Algebra.types.MOVE:case u.Algebra.types.COPY:return l.createFilter(o,r)}}variablesIntersect(r,a){return r.some(o=>a.some(l=>o.equals(l)))}variablesSubSetOf(r,a){return r.length<=a.length&&r.every(o=>a.some(l=>o.equals(l)))}};return uh.ActorOptimizeQueryOperationFilterPushdown=s,uh}var B8;function uZ(){return B8||(B8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(oZ(),t)}(Ow)),Ow}var Rw={},ch={},Rs={},U8;function P7(){if(U8)return Rs;U8=1,Object.defineProperty(Rs,"__esModule",{value:!0}),Rs.ActorDereferenceHttpBase=Rs.mediaTypesToAcceptString=void 0;const t=UT(),e=rs(),u=eA(),s=Pi(),n=eo(),r=/^[^ ;]*/u;function a(l,c){const d="*/*;q=0.1",h=[],f=Object.entries(l).map(([y,b])=>({mediaType:y,priority:b})).sort((y,b)=>b.priority===y.priority?y.mediaType.localeCompare(b.mediaType):b.priority-y.priority);let p=f.length-1;for(const{mediaType:y,priority:b}of f){const m=y+(b===1?"":`;q=${b.toFixed(3).replace(/0*$/u,"")}`);if(p+m.length>c){for(;p+d.length>c;){const g=h.pop()??"";p-=g.length+1}h.push(d);break}h.push(m),p+=m.length}return h.length===0?"*/*":h.join(",")}Rs.mediaTypesToAcceptString=a;let o=class extends t.ActorDereference{constructor(c){super(c)}async test({url:c}){if(!/^https?:/u.test(c))throw new Error(`Cannot retrieve ${c} because it is not an HTTP(S) URL.`);return!0}async run(c){var g,v;let d=!0;const h=new u.Headers(c.headers);h.append("Accept",a(await((g=c.mediaTypes)==null?void 0:g.call(c))??{},this.getMaxAcceptHeaderLength()));let f;const p=Date.now();try{f=await this.mediatorHttp.mediate({context:c.context,init:{headers:h,method:c.method},input:c.url})}catch(_){return this.handleDereferenceErrors(c,_)}const y=(0,s.resolve)(f.url,c.url),b=Date.now()-p;if(f.status!==200){d=!1;const _=f.body?await n(e.ActorHttp.toNodeReadable(f.body)):"empty response";if(!c.acceptErrors){const w=new Error(`Could not retrieve ${c.url} (HTTP status ${f.status}): -${_}`);return this.handleDereferenceErrors(c,w,f.headers,b)}}const m=(v=r.exec(f.headers.get("content-type")??""))==null?void 0:v[0];return{url:y,data:d?e.ActorHttp.toNodeReadable(f.body):(0,t.emptyReadable)(),exists:d,requestTime:b,headers:f.headers,mediaType:m==="text/plain"?void 0:m}}};return Rs.ActorDereferenceHttpBase=o,Rs}var H8;function cZ(){if(H8)return ch;H8=1,Object.defineProperty(ch,"__esModule",{value:!0}),ch.ActorDereferenceHttp=void 0;const t=P7();class e extends t.ActorDereferenceHttpBase{getMaxAcceptHeaderLength(){return this.maxAcceptHeaderLengthBrowser}}return ch.ActorDereferenceHttp=e,ch}var $8;function lZ(){return $8||($8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(cZ(),t),u(P7(),t)}(Rw)),Rw}var xw={},lh={},Q8;function dZ(){if(Q8)return lh;Q8=1,Object.defineProperty(lh,"__esModule",{value:!0}),lh.ActorHttpProxy=void 0;const t=rs(),e=Lt;let u=class extends t.ActorHttp{constructor(n){super(n)}async test(n){const r=n.context.get(e.KeysHttpProxy.httpProxyHandler);if(!r)throw new Error(`Actor ${this.name} could not find a proxy handler in the context.`);if(!await r.getProxy(n))throw new Error(`Actor ${this.name} could not determine a proxy for the given request.`);return{time:Number.POSITIVE_INFINITY}}async run(n){const r=typeof n.input=="string"?n.input:n.input.url,a=n.context.get(e.KeysHttpProxy.httpProxyHandler),o=await this.mediatorHttp.mediate({...await a.getProxy(n),context:n.context.delete(e.KeysHttpProxy.httpProxyHandler)});return Object.defineProperty(o,"url",{configurable:!0,enumerable:!0,get:()=>o.headers.get("x-final-url")??r}),o}};return lh.ActorHttpProxy=u,lh}var dh={},V8;function fZ(){if(V8)return dh;V8=1,Object.defineProperty(dh,"__esModule",{value:!0}),dh.ProxyHandlerStatic=void 0;let t=class{constructor(u){this.prefixUrl=u}async getProxy(u){return{init:u.init,input:this.modifyInput(u.input)}}modifyInput(u){return typeof u=="string"?this.prefixUrl+u:new Request(this.prefixUrl+u.url,u)}};return dh.ProxyHandlerStatic=t,dh}var k8;function hZ(){return k8||(k8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(dZ(),t),u(fZ(),t)}(xw)),xw}var Iw={},fh={},z8;function pZ(){if(z8)return fh;z8=1,Object.defineProperty(fh,"__esModule",{value:!0}),fh.ActorContextPreprocessQuerySourceIdentify=void 0;const t=Sy(),e=Lt,u=ot,s=is();let n=class extends t.ActorContextPreprocess{constructor(a){super(a),this.cache=this.cacheSize?new s.LRUCache({max:this.cacheSize}):void 0;const o=this.cache;o&&this.httpInvalidator.addInvalidateListener(({url:l})=>l?o.delete(l):o.clear())}async test(a){return!0}async run(a){let o=a.context;if(o.has(e.KeysInitQuery.querySourcesUnidentified)){const l=a.context.get(e.KeysInitQuery.querySourcesUnidentified),c=await Promise.all(l.map(h=>this.expandSource(h))),d=await Promise.all(c.map(async h=>this.identifySource(h,a.context)));o=a.context.delete(e.KeysInitQuery.querySourcesUnidentified).set(e.KeysQueryOperation.querySources,d)}return{context:o}}async expandSource(a){return typeof a=="string"||"match"in a?{value:a}:{...a,context:(await this.mediatorContextPreprocess.mediate({context:u.ActionContext.ensureActionContext(a.context??{})})).context}}identifySource(a,o){let l;return typeof a.value=="string"&&this.cache&&(l=this.cache.get(a.value)),l||(l=this.mediatorQuerySourceIdentify.mediate({querySourceUnidentified:a,context:o}).then(({querySource:c})=>c),typeof a.value=="string"&&this.cache&&this.cache.set(a.value,l)),l}};return fh.ActorContextPreprocessQuerySourceIdentify=n,fh}var G8;function yZ(){return G8||(G8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(pZ(),t)}(Iw)),Iw}var Pw={},hh={},W8;function bZ(){if(W8)return hh;W8=1,Object.defineProperty(hh,"__esModule",{value:!0}),hh.ActorRdfUpdateQuadsHypermedia=void 0;const t=YT(),e=is();let u=class extends t.ActorRdfUpdateQuadsDestination{constructor(n){super(n),this.cache=this.cacheSize?new e.LRUCache({max:this.cacheSize}):void 0;const r=this.cache;r&&this.httpInvalidator.addInvalidateListener(({url:a})=>a?r.delete(a):r.clear())}async test(n){if(!(0,t.getContextDestinationUrl)((0,t.getContextDestination)(n.context)))throw new Error(`Actor ${this.name} can only update quads against a single destination URL.`);return!0}getDestination(n){const r=(0,t.getContextDestination)(n);let a=(0,t.getContextDestinationUrl)(r);if(this.cache&&this.cache.has(a))return this.cache.get(a);const o=(async()=>{var h;let l,c;try{const f=await this.mediatorDereferenceRdf.mediate({context:n,url:a,acceptErrors:!0});c=f.exists,a=f.url;const p=await this.mediatorMetadata.mediate({context:n,url:a,quads:f.data,triples:(h=f.metadata)==null?void 0:h.triples});l=(await this.mediatorMetadataExtract.mediate({context:n,url:a,metadata:p.metadata,headers:f.headers,requestTime:f.requestTime})).metadata}catch{l={},c=!1}const{destination:d}=await this.mediatorRdfUpdateHypermedia.mediate({context:n,url:a,metadata:l,exists:c,forceDestinationType:(0,t.getDataDestinationType)(r)});return d})();return this.cache&&this.cache.set(a,o),o}};return hh.ActorRdfUpdateQuadsHypermedia=u,hh}var J8;function gZ(){return J8||(J8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(bZ(),t)}(Pw)),Pw}var Dw={},ph={},X8;function mZ(){if(X8)return ph;X8=1,Object.defineProperty(ph,"__esModule",{value:!0}),ph.ActionObserverHttp=void 0;const t=ot;class e extends t.ActionObserver{constructor(s){super(s),this.requests=0,this.bus.subscribeObserver(this),this.httpInvalidator.addInvalidateListener(()=>{this.requests=0})}onRun(s,n,r){this.requests++}}return ph.ActionObserverHttp=e,ph}var yh={},K8;function _Z(){if(K8)return yh;K8=1,Object.defineProperty(yh,"__esModule",{value:!0}),yh.ActorQueryResultSerializeSparqlJson=void 0;const t=Gi(),e=Nt(),u=Wt();let s=class x0 extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(r){super(r)}static bindingToJsonBindings(r){if(r.termType==="Literal"){const a=r,o={value:a.value,type:"literal"},{language:l,datatype:c}=a;return l?o["xml:lang"]=l:c&&c.value!=="http://www.w3.org/2001/XMLSchema#string"&&(o.datatype=c.value),o}return r.termType==="BlankNode"?{value:r.value,type:"bnode"}:r.termType==="Quad"?{value:{subject:x0.bindingToJsonBindings(r.subject),predicate:x0.bindingToJsonBindings(r.predicate),object:x0.bindingToJsonBindings(r.object)},type:"triple"}:{value:r.value,type:"uri"}}async testHandleChecked(r,a){if(!["bindings","boolean"].includes(r.type))throw new Error("This actor can only handle bindings streams or booleans.");return!0}async runHandle(r,a,o){const l=new u.Readable,c={};if(r.type==="bindings"){const d=await r.metadata();d.variables.length>0&&(c.vars=d.variables.map(h=>h.value))}if(l.push(`{"head": ${JSON.stringify(c)}, -`),r.type==="bindings"){const d=r.bindingsStream;l.push(`"results": { "bindings": [ -`);let h=!0;function*f(p){yield p()}l.wrap((0,e.wrap)(d).map(p=>{const y=`${h?"":`, -`}${JSON.stringify(Object.fromEntries([...p].map(([b,m])=>[b.value,x0.bindingToJsonBindings(m)])))}`;return h=!1,y}).append((0,e.wrap)(f(()=>` -]}${this.emitMetadata?`, -"metadata": { "httpRequests": ${this.httpObserver.requests} }`:""}} -`))))}else l.wrap((0,e.wrap)(r.execute().then(d=>[`"boolean":${d} -} -`])));return{data:l}}};return yh.ActorQueryResultSerializeSparqlJson=s,yh}var Y8;function Z8(){return Y8||(Y8=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(mZ(),t),u(_Z(),t)}(Dw)),Dw}var Nw={},bh={},e5;function vZ(){if(e5)return bh;e5=1,Object.defineProperty(bh,"__esModule",{value:!0}),bh.ActionObserverHttp=void 0;const t=ot;let e=class extends t.ActionObserver{constructor(s){super(s),this.requests=0,this.bus.subscribeObserver(this),this.httpInvalidator.addInvalidateListener(()=>{this.requests=0})}onRun(s,n,r){this.requests++}};return bh.ActionObserverHttp=e,bh}var gh={},t5;function wZ(){if(t5)return gh;t5=1,Object.defineProperty(gh,"__esModule",{value:!0}),gh.ActorQueryResultSerializeStats=void 0;const t=Gi(),e=Nt(),u=Wt(),s=Sa();let n=class extends t.ActorQueryResultSerializeFixedMediaTypes{constructor(a){super(a)}async testHandleChecked(a,o){if(!["bindings","quads"].includes(a.type))throw new Error("This actor can only handle bindings streams or quad streams.");return!0}pushHeader(a){const o=["Result","Delay (ms)","HTTP requests"].join(",");a.push(`${o} -`)}createStat(a,o){return`${[o,this.delay(a),this.httpObserver.requests].join(",")} -`}createFooter(a){return`${["TOTAL",this.delay(a),this.httpObserver.requests].join(",")} -`}async runHandle(a,o,l){const c=new u.Readable,d=a.type==="bindings"?a.bindingsStream:a.quadStream,h=this.now();let f=1;function*p(b){yield b()}const y=(0,e.wrap)(d).map(()=>this.createStat(h,f++)).append((0,e.wrap)(p(()=>this.createFooter(h))));return this.pushHeader(c),c.wrap(y),{data:c}}now(){if(typeof performance>"u"){const a=s.hrtime();return a[0]*1e3+a[1]/1e6}return performance.now()}delay(a){return this.now()-a}};return gh.ActorQueryResultSerializeStats=n,gh}var r5;function n5(){return r5||(r5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(vZ(),t),u(wZ(),t)}(Nw)),Nw}var Cw={},mh={},jw={},_h={},i5;function SZ(){if(i5)return _h;i5=1,Object.defineProperty(_h,"__esModule",{value:!0}),_h.ActorQuerySourceIdentifyHypermedia=void 0;const t=ot;class e extends t.Actor{constructor(s,n){super(s),this.sourceType=n}async test(s){if(s.forceSourceType&&this.sourceType!==s.forceSourceType)throw new Error(`Actor ${this.name} is not able to handle source type ${s.forceSourceType}.`);return this.testMetadata(s)}}return _h.ActorQuerySourceIdentifyHypermedia=e,_h}var a5;function tA(){return a5||(a5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(SZ(),t)}(jw)),jw}var vh={},Lw={},wh={},s5;function TZ(){if(s5)return wh;s5=1,Object.defineProperty(wh,"__esModule",{value:!0}),wh.ActorQuerySourceIdentify=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return wh.ActorQuerySourceIdentify=e,wh}var Qr={},o5;function AZ(){if(o5)return Qr;o5=1,Object.defineProperty(Qr,"__esModule",{value:!0}),Qr.filterMatchingQuotedQuads=Qr.quadsOrderToBindingsOrder=Qr.quadsMetadataToBindingsMetadata=Qr.setMetadata=Qr.getDuplicateElementLinks=Qr.getVariables=Qr.isTermVariable=Qr.quadsToBindings=void 0;const t=wt(),e=jn(),u=Et(),s=er(),n=un(),r=CF(),a=new u.DataFactory;function o(b,m,g,v){const _=c(m),w=m.graph.termType==="Variable"&&!v,S=d(m),A=(0,n.reduceTermsNested)(m,(L,E,O)=>(E.termType==="Variable"&&(L[O.join("_")]=E.value),L),{}),D=new t.ClosableTransformIterator(async()=>{let L=b;return w&&(L=L.filter(E=>E.graph.termType!=="DefaultGraph")),S&&(L=L.filter(E=>{for(const O in S){const P=O.split("_"),j=(0,n.getValueNestedPath)(E,P);for(const U of S[O])if(!j.equals((0,n.getValueNestedPath)(E,U)))return!1}return!0})),L.map(E=>g.bindings(Object.keys(A).map(O=>{const P=O.split("_"),j=A[O],U=(0,n.getValueNestedPath)(E,P);return[a.variable(j),U]})))},{autoStart:!1,onClose:()=>b.destroy()});return h(D,b,A,_,w||!!S),D}Qr.quadsToBindings=o;function l(b){return b.termType==="Variable"}Qr.isTermVariable=l;function c(b){return(0,n.uniqTerms)((0,n.getTermsNested)(b).filter(l))}Qr.getVariables=c;function d(b){const m={};let g=!1;if((0,n.forEachTermsNested)(b,(_,w)=>{if(_.termType==="Variable"){const S=(0,s.termToString)(_),A=(m[S]||(m[S]=[])).push(w);g=g||A>1}}),!g)return;const v={};for(const _ in m){const w=m[_],S=w.slice(1);S.length>0&&(v[w[0].join("_")]=S)}return v}Qr.getDuplicateElementLinks=d;function h(b,m,g,v,_){const w=A=>{"canContainUndefs"in A||(A.canContainUndefs=!1),_&&(A.cardinality.type="estimate"),b.setProperty("metadata",f((0,e.validateMetadataQuads)(A),g,v)),A.state&&A.state.addInvalidateListener(()=>{h(b,m,g,v,_)})},S=m.getProperty("metadata");S?w(S):m.getProperty("metadata",w)}Qr.setMetadata=h;function f(b,m,g){return{...b,canContainUndefs:!1,order:b.order?p(b.order,m):void 0,availableOrders:b.availableOrders?b.availableOrders.map(v=>({cost:v.cost,terms:p(v.terms,m)})):void 0,variables:g}}Qr.quadsMetadataToBindingsMetadata=f;function p(b,m){const g={};return b.map(v=>{const _=m[v.term];if(_&&!g[_])return g[_]=!0,{term:a.variable(_),direction:v.direction}}).filter(Boolean)}Qr.quadsOrderToBindingsOrder=p;function y(b,m){return(0,n.someTerms)(b,g=>g.termType==="Quad")&&(m=m.filter(g=>(0,r.matchPatternMappings)(g,b))),m}return Qr.filterMatchingQuotedQuads=y,Qr}var u5;function xy(){return u5||(u5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(TZ(),t),u(AZ(),t)}(Lw)),Lw}var c5;function D7(){if(c5)return vh;c5=1,Object.defineProperty(vh,"__esModule",{value:!0}),vh.QuerySourceQpf=void 0;const t=xy(),e=Lt,u=Nt(),s=Et(),n=er(),r=Oy(),a=un(),o=Ot(),l=new o.Factory,c=new s.DataFactory;let d=class p3{constructor(p,y,b,m,g,v,_,w,S,A,D,L){this.referenceValue=S,this.mediatorMetadata=p,this.mediatorMetadataExtract=y,this.mediatorDereferenceRdf=b,this.bindingsFactory=m,this.subjectUri=g,this.predicateUri=v,this.objectUri=_,this.graphUri=w,this.url=S,this.bindingsRestricted=D,this.cachedQuads={};const E=this.getSearchForm(A);if(!E)throw new Error("Illegal state: found no TPF/QPF search form anymore in metadata.");if(this.searchForm=E,this.defaultGraph=A.defaultGraph?c.namedNode(A.defaultGraph):void 0,L){let O=(0,u.wrap)(L);this.defaultGraph&&(O=this.reverseMapQuadsToDefaultGraph(O)),O.setProperty("metadata",A),this.cacheQuads(O,c.variable(""),c.variable(""),c.variable(""),c.variable(""))}}async getSelectorShape(){return this.bindingsRestricted?p3.SELECTOR_SHAPE_BR:p3.SELECTOR_SHAPE}queryBindings(p,y,b){if(p.type!=="pattern")throw new Error(`Attempted to pass non-pattern operation '${p.type}' to QuerySourceQpf`);const m=!!y.get(e.KeysQueryOperation.unionDefaultGraph);let g=this.match(p.subject,p.predicate,p.object,p.graph,m,y,b);return g=(0,t.filterMatchingQuotedQuads)(p,g),(0,t.quadsToBindings)(g,p,this.bindingsFactory,m)}getSearchForm(p){if(!p.searchForms||!p.searchForms.values)return;const{searchForms:y}=p;for(const b of y.values)if(this.graphUri&&this.subjectUri in b.mappings&&this.predicateUri in b.mappings&&this.objectUri in b.mappings&&this.graphUri in b.mappings&&Object.keys(b.mappings).length===4||this.subjectUri in b.mappings&&this.predicateUri in b.mappings&&this.objectUri in b.mappings&&Object.keys(b.mappings).length===3)return b}createFragmentUri(p,y,b,m,g){const v={},_=[{uri:this.subjectUri,term:y},{uri:this.predicateUri,term:b},{uri:this.objectUri,term:m},{uri:this.graphUri,term:g}];for(const w of _)w.uri&&(this.bindingsRestricted||w.term.termType!=="Variable"&&(w.term.termType!=="Quad"||(0,a.everyTermsNested)(w.term,S=>S.termType!=="Variable")))&&(v[w.uri]=(0,n.termToString)(w.term));return p.getUri(v)}match(p,y,b,m,g,v,_){let w=!1;if(m.termType==="DefaultGraph")if(this.defaultGraph)w=!0,m=this.defaultGraph;else if(Object.keys(this.searchForm.mappings).length===4&&!this.defaultGraph)if(g)m=c.variable("g");else{const L=new u.ArrayIterator([],{autoStart:!1});return L.setProperty("metadata",{requestTime:0,cardinality:{type:"exact",value:0},first:null,next:null,last:null,canContainUndefs:!1}),L}else Object.keys(this.searchForm.mappings).length===3&&(m=c.variable("g"));if(!(_!=null&&_.filterBindings)){const L=this.getCachedQuads(p,y,b,m);if(L)return L}const S=this;let A;const D=async function(){var j;let L=S.createFragmentUri(S.searchForm,p,y,b,m);_!=null&&_.filterBindings&&(L=await S.getBindingsRestrictedLink(p,y,b,m,L,_.filterBindings));const E=await S.mediatorDereferenceRdf.mediate({context:v,url:L});L=E.url;const O=await S.mediatorMetadata.mediate({context:v,url:L,quads:E.data,triples:(j=E.metadata)==null?void 0:j.triples}),{metadata:P}=await S.mediatorMetadataExtract.mediate({context:v,url:L,metadata:O.metadata,requestTime:E.requestTime});return A.setProperty("metadata",{...P,canContainUndefs:!1,subsetOf:S.url}),O.data}();return A=new u.TransformIterator(async()=>{const L=await D,E=c.defaultGraph();let O=(0,u.wrap)(L).transform({filter(P){return(0,a.matchPattern)(P,p,y,b,m)?!0:w&&(0,a.matchPattern)(P,p,y,b,E)}});return(w||m.termType==="Variable")&&(O=this.reverseMapQuadsToDefaultGraph(O)),O},{autoStart:!1}),_!=null&&_.filterBindings?A:(this.cacheQuads(A,p,y,b,m),this.getCachedQuads(p,y,b,m))}async getBindingsRestrictedLink(p,y,b,m,g,v){const _=[];for(const S of await v.bindings.toArray()){const A=["("];for(const D of v.metadata.variables){const L=S.get(D);A.push(L?(0,r.termToString)(L):"UNDEF"),A.push(" ")}A.push(")"),_.push(A.join(""))}_.length===0&&_.push("()");const w=encodeURIComponent(`(${v.metadata.variables.map(S=>`?${S.value}`).join(" ")}) { ${_.join(" ")} }`);return`${g}&values=${w}`}reverseMapQuadsToDefaultGraph(p){const y=c.defaultGraph();return p.map(b=>(0,a.mapTerms)(b,(m,g)=>g==="graph"&&m.equals(this.defaultGraph)?y:m))}getPatternId(p,y,b,m){return JSON.stringify({s:p.termType==="Variable"?"":h(p),p:y.termType==="Variable"?"":h(y),o:b.termType==="Variable"?"":h(b),g:m.termType==="Variable"?"":h(m)})}cacheQuads(p,y,b,m,g){const v=this.getPatternId(y,b,m,g);this.cachedQuads[v]=p.clone()}getCachedQuads(p,y,b,m){const g=this.getPatternId(p,y,b,m),v=this.cachedQuads[g];if(v)return v.clone()}queryQuads(p,y){throw new Error("queryQuads is not implemented in QuerySourceQpf")}queryBoolean(p,y){throw new Error("queryBoolean is not implemented in QuerySourceQpf")}queryVoid(p,y){throw new Error("queryVoid is not implemented in QuerySourceQpf")}};vh.QuerySourceQpf=d,d.SELECTOR_SHAPE={type:"operation",operation:{operationType:"pattern",pattern:l.createPattern(c.variable("s"),c.variable("p"),c.variable("o"),c.variable("g"))},variablesOptional:[c.variable("s"),c.variable("p"),c.variable("o"),c.variable("g")]},d.SELECTOR_SHAPE_BR={type:"operation",operation:{operationType:"pattern",pattern:l.createPattern(c.variable("s"),c.variable("p"),c.variable("o"),c.variable("g"))},variablesOptional:[c.variable("s"),c.variable("p"),c.variable("o"),c.variable("g")],filterBindings:!0};function h(f){return f.termType==="DefaultGraph"?"|":(0,n.termToString)(f)}return vh}var l5;function EZ(){if(l5)return mh;l5=1,Object.defineProperty(mh,"__esModule",{value:!0}),mh.ActorQuerySourceIdentifyHypermediaQpf=void 0;const t=xr(),e=tA(),u=D7();let s=class extends e.ActorQuerySourceIdentifyHypermedia{constructor(r){super(r,"qpf")}async test(r){if(r.forceSourceType&&r.forceSourceType!=="qpf"&&r.forceSourceType!=="brtpf")throw new Error(`Actor ${this.name} is not able to handle source type ${r.forceSourceType}.`);return this.testMetadata(r)}async testMetadata(r){const{searchForm:a}=await this.createSource(r.url,r.metadata,r.context,r.forceSourceType==="brtpf");if(r.handledDatasets&&r.handledDatasets[a.dataset])throw new Error(`Actor ${this.name} can only be applied for the first page of a QPF dataset.`);return{filterFactor:1}}async run(r){this.logInfo(r.context,`Identified as qpf source: ${r.url}`);const a=await this.createSource(r.url,r.metadata,r.context,r.forceSourceType==="brtpf",r.quads);return{source:a,dataset:a.searchForm.dataset}}async createSource(r,a,o,l,c){return new u.QuerySourceQpf(this.mediatorMetadata,this.mediatorMetadataExtract,this.mediatorDereferenceRdf,await t.BindingsFactory.create(this.mediatorMergeBindingsContext,o),this.subjectUri,this.predicateUri,this.objectUri,this.graphUri,r,a,l,c)}};return mh.ActorQuerySourceIdentifyHypermediaQpf=s,mh}var d5;function OZ(){return d5||(d5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(EZ(),t),u(D7(),t)}(Cw)),Cw}var Mw={},Sh={},Th={},f5;function N7(){if(f5)return Th;f5=1,Object.defineProperty(Th,"__esModule",{value:!0}),Th.QuerySourceSparql=void 0;const t=Lt,e=Nt(),u=y7(),s=is(),n=Et(),r=Ot(),a=new r.Factory,o=new n.DataFactory,l=o.variable("count"),c={type:"estimate",value:Number.POSITIVE_INFINITY};let d=class ii{constructor(f,p,y,b,m,g,v,_){this.referenceValue=f,this.url=f,this.context=p,this.mediatorHttp=y,this.bindMethod=b,this.bindingsFactory=m,this.endpointFetcher=new u.SparqlEndpointFetcher({method:g?"GET":"POST",fetch:(w,S)=>this.mediatorHttp.mediate({input:w,init:S,context:this.lastSourceContext}),prefixVariableQuestionMark:!0}),this.cache=v>0?new s.LRUCache({max:v}):void 0,this.countTimeout=_}async getSelectorShape(){return ii.SELECTOR_SHAPE}queryBindings(f,p,y){let b;y!=null&&y.joinBindings?b=ii.addBindingsToOperation(this.bindMethod,f,y.joinBindings):b=Promise.resolve(f);const m=new e.TransformIterator(async()=>{const g=await b,v=r.Util.inScopeVariables(g),_=p.get(t.KeysInitQuery.queryString),w=!(y!=null&&y.joinBindings)&&_?_:ii.operationToSelectQuery(g,v),S=ii.operationCanContainUndefs(g);return this.queryBindingsRemote(this.url,w,v,p,S)},{autoStart:!1});return this.attachMetadata(m,p,b),m}queryQuads(f,p){this.lastSourceContext=this.context.merge(p);const y=this.endpointFetcher.fetchTriples(this.url,p.get(t.KeysInitQuery.queryString)??ii.operationToQuery(f));this.lastSourceContext=void 0;const b=(0,e.wrap)(y,{autoStart:!1,maxBufferSize:Number.POSITIVE_INFINITY});return this.attachMetadata(b,p,Promise.resolve(f.input)),b}queryBoolean(f,p){this.lastSourceContext=this.context.merge(p);const y=this.endpointFetcher.fetchAsk(this.url,p.get(t.KeysInitQuery.queryString)??ii.operationToQuery(f));return this.lastSourceContext=void 0,y}queryVoid(f,p){this.lastSourceContext=this.context.merge(p);const y=this.endpointFetcher.fetchUpdate(this.url,p.get(t.KeysInitQuery.queryString)??ii.operationToQuery(f));return this.lastSourceContext=void 0,y}attachMetadata(f,p,y){let b=[],m=!1;new Promise(async(g,v)=>{var w;let _;try{const S=await y;b=r.Util.inScopeVariables(S),_=ii.operationToCountQuery(S),m=ii.operationCanContainUndefs(S);const A=(w=this.cache)==null?void 0:w.get(_);if(A!==void 0)return g(A);const D=setTimeout(()=>g(c),this.countTimeout),L=await this.queryBindingsRemote(this.url,_,[l],p,!1);L.on("data",E=>{var j;clearTimeout(D);const O=E.get(l),P={type:"estimate",value:Number.POSITIVE_INFINITY};if(O){const U=Number.parseInt(O.value,10);Number.isNaN(U)||(P.type="exact",P.value=U,(j=this.cache)==null||j.set(_,P))}return g(P)}),L.on("error",()=>{clearTimeout(D),g(c)}),L.on("end",()=>{clearTimeout(D),g(c)})}catch(S){return v(S)}}).then(g=>f.setProperty("metadata",{cardinality:g,canContainUndefs:m,variables:b})).catch(()=>f.setProperty("metadata",{cardinality:c,canContainUndefs:m,variables:b}))}static async addBindingsToOperation(f,p,y){const b=await y.bindings.toArray();switch(f){case"values":return a.createJoin([a.createValues(y.metadata.variables,b.map(m=>Object.fromEntries([...m].map(([g,v])=>[`?${g.value}`,v])))),p],!1);case"union":throw new Error('Not implemented yet: "union" case');case"filter":throw new Error('Not implemented yet: "filter" case')}}static operationToSelectQuery(f,p){return ii.operationToQuery(a.createProject(f,p))}static operationToCountQuery(f){return ii.operationToQuery(a.createProject(a.createExtend(a.createGroup(f,[],[a.createBoundAggregate(o.variable("var0"),"count",a.createWildcardExpression(),!1)]),o.variable("count"),a.createTermExpression(o.variable("var0"))),[o.variable("count")]))}static operationToQuery(f){return(0,r.toSparql)(f,{sparqlStar:!0})}static operationCanContainUndefs(f){let p=!1;return r.Util.recurseOperation(f,{leftjoin(){return p=!0,!1},values(y){return p=y.bindings.some(b=>y.variables.some(m=>!(`?${m.value}`in b))),!1}}),p}async queryBindingsRemote(f,p,y,b,m){this.lastSourceContext=this.context.merge(b);const g=await this.endpointFetcher.fetchBindings(f,p);this.lastSourceContext=void 0;const v=(0,e.wrap)(g,{autoStart:!1,maxBufferSize:Number.POSITIVE_INFINITY}).map(_=>this.bindingsFactory.bindings(y.map(w=>{const S=_[`?${w.value}`];return!m&&!S&&v.emit("error",new Error(`The endpoint ${f} failed to provide a binding for ${w.value}.`)),[w,S]})));return v}toString(){return`QuerySourceSparql(${this.url})`}};return Th.QuerySourceSparql=d,d.SELECTOR_SHAPE={type:"disjunction",children:[{type:"operation",operation:{operationType:"type",type:r.Algebra.types.PROJECT},joinBindings:!0},{type:"operation",operation:{operationType:"type",type:r.Algebra.types.CONSTRUCT}},{type:"operation",operation:{operationType:"type",type:r.Algebra.types.DESCRIBE}},{type:"operation",operation:{operationType:"type",type:r.Algebra.types.ASK}},{type:"operation",operation:{operationType:"type",type:r.Algebra.types.COMPOSITE_UPDATE}}]},Th}var h5;function RZ(){if(h5)return Sh;h5=1,Object.defineProperty(Sh,"__esModule",{value:!0}),Sh.ActorQuerySourceIdentifyHypermediaSparql=void 0;const t=xr(),e=tA(),u=N7();let s=class extends e.ActorQuerySourceIdentifyHypermedia{constructor(r){super(r,"sparql")}async testMetadata(r){if(!r.forceSourceType&&!r.metadata.sparqlService&&!(this.checkUrlSuffix&&r.url.endsWith("/sparql")))throw new Error(`Actor ${this.name} could not detect a SPARQL service description or URL ending on /sparql.`);return{filterFactor:1}}async run(r){return this.logInfo(r.context,`Identified ${r.url} as sparql source with service URL: ${r.metadata.sparqlService||r.url}`),{source:new u.QuerySourceSparql(r.forceSourceType?r.url:r.metadata.sparqlService||r.url,r.context,this.mediatorHttp,this.bindMethod,await t.BindingsFactory.create(this.mediatorMergeBindingsContext,r.context),this.forceHttpGet,this.cacheSize,this.countTimeout)}}};return Sh.ActorQuerySourceIdentifyHypermediaSparql=s,Sh}var p5;function xZ(){return p5||(p5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(RZ(),t),u(N7(),t)}(Mw)),Mw}var Fw={},Ah={},qw={},Eh={},Oh={},y5;function C7(){if(y5)return Oh;y5=1,Object.defineProperty(Oh,"__esModule",{value:!0}),Oh.QuerySourceRdfJs=void 0;const t=xy(),e=Lt,u=jn(),s=Nt(),n=Et(),r=un(),a=Ot(),o=new a.Factory,l=new n.DataFactory;let c=class An{constructor(h,f){this.source=h,this.referenceValue=h,this.bindingsFactory=f}static nullifyVariables(h,f){return!h||h.termType==="Variable"||!f&&h.termType==="Quad"&&(0,r.someTermsNested)(h,p=>p.termType==="Variable")?void 0:h}static hasDuplicateVariables(h){const f=(0,r.filterTermsNested)(h,p=>p.termType==="Variable");return f.length>1&&(0,r.uniqTerms)(f).lengthb.destroy(g)),(0,t.quadsToBindings)(b,h,this.bindingsFactory,!!f.get(e.KeysQueryOperation.unionDefaultGraph))}async setMetadata(h,f){var m;const p=!!((m=this.source.features)!=null&&m.quotedTripleFiltering);let y;if(this.source.countQuads)y=await this.source.countQuads(An.nullifyVariables(f.subject,p),An.nullifyVariables(f.predicate,p),An.nullifyVariables(f.object,p),An.nullifyVariables(f.graph,p));else{let g=0;y=await new Promise((v,_)=>{const w=this.source.match(An.nullifyVariables(f.subject,p),An.nullifyVariables(f.predicate,p),An.nullifyVariables(f.object,p),An.nullifyVariables(f.graph,p));w.on("error",_),w.on("end",()=>v(g)),w.on("data",()=>g++)})}const b=!p&&(0,r.someTerms)(f,g=>g.termType==="Quad")||An.hasDuplicateVariables(f);h.setProperty("metadata",{state:new u.MetadataValidationState,cardinality:{type:b?"estimate":"exact",value:y},canContainUndefs:!1})}queryQuads(h,f){throw new Error("queryQuads is not implemented in QuerySourceQpf")}queryBoolean(h,f){throw new Error("queryBoolean is not implemented in QuerySourceQpf")}queryVoid(h,f){throw new Error("queryVoid is not implemented in QuerySourceQpf")}toString(){return`QuerySourceRdfJs(${this.source.constructor.name})`}};return Oh.QuerySourceRdfJs=c,c.SELECTOR_SHAPE={type:"operation",operation:{operationType:"pattern",pattern:o.createPattern(l.variable("s"),l.variable("p"),l.variable("o"))},variablesOptional:[l.variable("s"),l.variable("p"),l.variable("o")]},Oh}var b5;function IZ(){if(b5)return Eh;b5=1,Object.defineProperty(Eh,"__esModule",{value:!0}),Eh.ActorQuerySourceIdentifyRdfJs=void 0;const t=xr(),e=xy(),u=ot,s=C7();let n=class extends e.ActorQuerySourceIdentify{constructor(a){super(a)}async test(a){const o=a.querySourceUnidentified;if(o.type!==void 0&&o.type!=="rdfjs")throw new Error(`${this.name} requires a single query source with rdfjs type to be present in the context.`);if(typeof o.value=="string"||!("match"in o.value))throw new Error(`${this.name} received an invalid rdfjs query source.`);return!0}async run(a){return{querySource:{source:new s.QuerySourceRdfJs(a.querySourceUnidentified.value,await t.BindingsFactory.create(this.mediatorMergeBindingsContext,a.context)),context:a.querySourceUnidentified.context??new u.ActionContext}}}};return Eh.ActorQuerySourceIdentifyRdfJs=n,Eh}var Bw={},g5;function PZ(){return g5||(g5=1,Object.defineProperty(Bw,"__esModule",{value:!0})),Bw}var m5;function rA(){return m5||(m5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(IZ(),t),u(PZ(),t),u(C7(),t)}(qw)),qw}var Rh={},Uw={},xh={},Ih={},Ph={},_5;function j7(){if(_5)return Ph;_5=1,Object.defineProperty(Ph,"__esModule",{value:!0}),Ph.TermDictionaryNumberRecordFullTerms=void 0;const t=Et(),e=er();let u=class{constructor(n=new t.DataFactory){this.lastId=0,this.dictionary={},this.reverseDictionary={},this.features={quotedTriples:!1},this.dataFactory=n}encode(n){const r=(0,e.termToString)(n);let a=this.dictionary[r];return a===void 0&&(a=this.lastId++,this.dictionary[r]=a,this.reverseDictionary[a]=n),a}encodeOptional(n){const r=(0,e.termToString)(n);return this.dictionary[r]}decode(n){const r=this.reverseDictionary[n];if(r===void 0)throw new Error(`The value ${n} is not present in this dictionary`);return r}*encodings(){for(const n of Object.keys(this.reverseDictionary))yield Number.parseInt(n,10)}findQuotedTriples(n){throw new Error("findQuotedTriples is not supported")}findQuotedTriplesEncoded(n){throw new Error("findQuotedTriplesEncoded is not supported")}};return Ph.TermDictionaryNumberRecordFullTerms=u,Ph}var Dh={},Nh={},Hw={},v5;function Xi(){return v5||(v5=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.arePatternsQuoted=t.quadHasVariables=t.quadToPattern=t.encodeOptionalTerms=t.orderQuadComponents=t.getComponentOrderScore=t.getBestIndex=t.QUAD_TERM_NAMES_INVERSE=void 0;const e=un();t.QUAD_TERM_NAMES_INVERSE=Object.fromEntries(e.QUAD_TERM_NAMES.map((c,d)=>[c,d]));function u(c,d){if(c.length===1||d.every(p=>p!==void 0))return 0;const h=[];for(let p=0;p({score:s(p,h),index:y})).sort((p,y)=>y.score-p.score)[0].index}t.getBestIndex=u;function s(c,d){return c.map((h,f)=>d.includes(h)?c.length-f:0).reduce((h,f)=>h+f,0)}t.getComponentOrderScore=s;function n(c,d){return c.map(h=>{const f=t.QUAD_TERM_NAMES_INVERSE[h];return d[f]})}t.orderQuadComponents=n;function r(c,d){const h=c.map(f=>{if(f){if(f.termType==="Quad"&&o(f))return;const p=d.encodeOptional(f);return p===void 0?"none":p}return f});if(!h.includes("none"))return h}t.encodeOptionalTerms=r;function a(c,d,h,f,p){let y=!1;return[[c||void 0,d||void 0,h||void 0,f||void 0].map(m=>{if(m){if(m.termType==="Variable")return;if(m.termType==="Quad"){if(p)return m;y=!0;return}}return m}),y]}t.quadToPattern=a;function o(c){for(const d of e.QUAD_TERM_NAMES){const h=c[d];if(h.termType==="Variable"||h.termType==="Quad"&&o(h))return!0}return!1}t.quadHasVariables=o;function l(c){return c.map(d=>(d==null?void 0:d.termType)==="Quad"&&o(d))}t.arePatternsQuoted=l}(Hw)),Hw}var w5;function nA(){if(w5)return Nh;w5=1,Object.defineProperty(Nh,"__esModule",{value:!0}),Nh.RdfStoreIndexNestedMap=void 0;const t=Xi();let e=class{constructor(s){this.features={quotedTripleFiltering:!1},this.dictionary=s.dictionary,this.nestedMap=new Map}set(s,n){const r=this.nestedMap;let a=r.get(s[0]);a||(a=new Map,r.set(s[0],a));let o=a.get(s[1]);o||(o=new Map,a.set(s[1],o));let l=o.get(s[2]);l||(l=new Map,o.set(s[2],l));const c=l.has(s[3]);return c||l.set(s[3],n),!c}remove(s){const n=this.nestedMap,r=n.get(s[0]);if(!r)return!1;const a=r.get(s[1]);if(!a)return!1;const o=a.get(s[2]);if(!o)return!1;const l=o.delete(s[3]);return l&&o.size===0&&(a.delete(s[2]),a.size===0&&(r.delete(s[1]),r.size===0&&n.delete(s[0]))),l}get(s){const n=(0,t.encodeOptionalTerms)(s,this.dictionary);if(!(!n||n.includes(void 0)))return this.getEncoded(n)}getEncoded(s){const n=this.nestedMap.get(s[0]);if(!n)return;const r=n.get(s[1]);if(!r)return;const a=r.get(s[2]);if(a)return a.get(s[3])}*find(s){const n=(0,t.encodeOptionalTerms)(s,this.dictionary);if(!n)return;const[r,a,o,l]=n,[c,d,h,f]=s;let p,y,b,m,g,v,_;const w=this.nestedMap,S=r!==void 0?w.has(r)?[r]:[]:w.keys();for(const A of S){g=w.get(A),p=c||this.dictionary.decode(A);const D=a!==void 0?g.has(a)?[a]:[]:g.keys();for(const L of D){v=g.get(L),y=d||this.dictionary.decode(L);const E=o!==void 0?v.has(o)?[o]:[]:v.keys();for(const O of E){_=v.get(O),b=h||this.dictionary.decode(O);const P=l!==void 0?_.has(l)?[l]:[]:_.keys();for(const j of P)m=f||this.dictionary.decode(j),yield[p,y,b,m]}}}}*findEncoded(s,n){const[r,a,o,l]=s;let c,d,h;const f=this.nestedMap,p=r!==void 0?f.has(r)?[r]:[]:f.keys();for(const y of p){c=f.get(y);const b=a!==void 0?c.has(a)?[a]:[]:c.keys();for(const m of b){d=c.get(m);const g=o!==void 0?d.has(o)?[o]:[]:d.keys();for(const v of g){h=d.get(v);const _=l!==void 0?h.has(l)?[l]:[]:h.keys();for(const w of _)yield[y,m,v,w]}}}}count(s){let n=0;const r=(0,t.encodeOptionalTerms)(s,this.dictionary);if(!r)return 0;const a=r[0],o=r[1],l=r[2],c=r[3];let d,h,f;const p=this.nestedMap,y=a!==void 0?p.has(a)?[a]:[]:p.keys();for(const b of y){d=p.get(b);const m=o!==void 0?d.has(o)?[o]:[]:d.keys();for(const g of m){h=d.get(g);const v=l!==void 0?h.has(l)?[l]:[]:h.keys();for(const _ of v)f=h.get(_),c!==void 0?f.has(c)&&n++:n+=f.size}}return n}};return Nh.RdfStoreIndexNestedMap=e,Nh}var S5;function L7(){if(S5)return Dh;S5=1,Object.defineProperty(Dh,"__esModule",{value:!0}),Dh.TermDictionaryQuotedIndexed=void 0;const t=Et(),e=nA(),u=Xi();let s=class pa{constructor(r,a=new t.DataFactory){this.quotedTriplesDictionary=[],this.features={quotedTriples:!0},this.plainTermDictionary=r;const o={indexCombinations:[],indexConstructor:void 0,dictionary:this,dataFactory:a};this.quotedTriplesReverseDictionaries=[new e.RdfStoreIndexNestedMap(o),new e.RdfStoreIndexNestedMap(o),new e.RdfStoreIndexNestedMap(o)],this.dataFactory=a}encode(r){return r.termType==="Quad"?this.encodeQuotedTriple(r,!1):this.plainTermDictionary.encode(r)}encodeQuotedTriple(r,a){if(r.graph.termType!=="DefaultGraph")throw new Error("Encoding of quoted quads outside of the default graph is not allowed");const o=(0,u.encodeOptionalTerms)([r.subject,r.predicate,r.object,r.graph],this),l=o&&o.every(f=>f!==void 0)?this.quotedTriplesReverseDictionaries[0].getEncoded(o):void 0;if(l!==void 0||a)return l===void 0?void 0:pa.BITMASK|l;const c=[this.encode(r.subject),this.encode(r.predicate),this.encode(r.object)],d=this.quotedTriplesDictionary.length+1;this.quotedTriplesDictionary.push(c);const h=this.encode(this.dataFactory.defaultGraph());return this.quotedTriplesReverseDictionaries[0].set([c[0],c[1],c[2],h],d),this.quotedTriplesReverseDictionaries[1].set([c[1],c[2],c[0],h],d),this.quotedTriplesReverseDictionaries[2].set([c[2],c[0],c[1],h],d),pa.BITMASK|d}encodeOptional(r){return r.termType==="Quad"?this.encodeQuotedTriple(r,!0):this.plainTermDictionary.encodeOptional(r)}decode(r){if(pa.BITMASK&r){const a=(~pa.BITMASK&r)-1;if(a>=this.quotedTriplesDictionary.length)throw new Error(`The value ${r} is not present in the quoted triples range of the dictionary`);const o=this.quotedTriplesDictionary[a];return this.dataFactory.quad(this.decode(o[0]),this.decode(o[1]),this.decode(o[2]))}return this.plainTermDictionary.decode(r)}*encodings(){for(const r of this.plainTermDictionary.encodings())yield r;for(const r of this.quotedTriplesDictionary.keys())yield pa.BITMASK|1+r}*findQuotedTriples(r){for(const a of this.findQuotedTriplesEncoded(r))yield this.decode(a)}*findQuotedTriplesEncoded(r){const[a,o]=(0,u.quadToPattern)(r.subject,r.predicate,r.object,r.graph,!0);for(const l of this.patternToIterable(a[0]))for(const c of this.patternToIterable(a[1]))for(const d of this.patternToIterable(a[2]))for(const h of this.patternToIterable(a[3]))if(l&&c||!c&&!d){const f=[l,c,d,h];for(const p of this.quotedTriplesReverseDictionaries[0].findEncoded(f,a))yield pa.BITMASK|this.quotedTriplesReverseDictionaries[0].getEncoded(p)}else if(!l&&c){const f=[c,d,l,h];for(const p of this.quotedTriplesReverseDictionaries[1].findEncoded(f,a))yield pa.BITMASK|this.quotedTriplesReverseDictionaries[1].getEncoded(p)}else{const f=[d,l,c,h];for(const p of this.quotedTriplesReverseDictionaries[2].findEncoded(f,a))yield pa.BITMASK|this.quotedTriplesReverseDictionaries[2].getEncoded(p)}}*patternToIterable(r){if((r==null?void 0:r.termType)==="Quad"){yield*this.findQuotedTriplesEncoded(r);return}if(r===void 0){yield void 0;return}const a=this.encodeOptional(r);a!==void 0&&(yield a)}};return s.BITMASK=1<<31,Dh.TermDictionaryQuotedIndexed=s,Dh}var Ch={},T5;function M7(){if(T5)return Ch;T5=1,Object.defineProperty(Ch,"__esModule",{value:!0}),Ch.RdfStoreIndexNestedMapQuoted=void 0;const t=Xi(),e=nA();let u=class extends e.RdfStoreIndexNestedMap{constructor(n){super(n),this.features={quotedTripleFiltering:!0}}*getQuotedPatternKeys(n,r){for(const a of this.dictionary.findQuotedTriplesEncoded(r))n.has(a)&&(yield a)}*find(n){const r=(0,t.encodeOptionalTerms)(n,this.dictionary);if(!r)return;const[a,o,l,c]=r,[d,h,f,p]=n,[y,b,m,g]=(0,t.arePatternsQuoted)(n);let v,_,w,S,A,D,L;const E=this.nestedMap,O=d!==void 0?y?this.getQuotedPatternKeys(E,d):E.has(a)?[a]:[]:E.keys();for(const P of O){A=E.get(P),v=!y&&d?d:this.dictionary.decode(P);const j=h!==void 0?b?this.getQuotedPatternKeys(A,h):A.has(o)?[o]:[]:A.keys();for(const U of j){D=A.get(U),_=!b&&h?h:this.dictionary.decode(U);const M=f!==void 0?m?this.getQuotedPatternKeys(D,f):D.has(l)?[l]:[]:D.keys();for(const q of M){L=D.get(q),w=!m&&f?f:this.dictionary.decode(q);const Q=p!==void 0?g?this.getQuotedPatternKeys(L,p):L.has(c)?[c]:[]:L.keys();for(const Z of Q)S=!g&&p?p:this.dictionary.decode(Z),yield[v,_,w,S]}}}}*findEncoded(n,r){const[a,o,l,c]=n,[d,h,f,p]=r,[y,b,m,g]=(0,t.arePatternsQuoted)(r);let v,_,w;const S=this.nestedMap,A=d!==void 0?y?this.getQuotedPatternKeys(S,d):S.has(a)?[a]:[]:S.keys();for(const D of A){v=S.get(D);const L=h!==void 0?b?this.getQuotedPatternKeys(v,h):v.has(o)?[o]:[]:v.keys();for(const E of L){_=v.get(E);const O=f!==void 0?m?this.getQuotedPatternKeys(_,f):_.has(l)?[l]:[]:_.keys();for(const P of O){w=_.get(P);const j=p!==void 0?g?this.getQuotedPatternKeys(w,p):w.has(c)?[c]:[]:w.keys();for(const U of j)yield[Number.parseInt(D,10),Number.parseInt(E,10),Number.parseInt(P,10),Number.parseInt(U,10)]}}}}count(n){let r=0;const a=(0,t.encodeOptionalTerms)(n,this.dictionary);if(!a)return 0;const[o,l,c,d]=a,[h,f,p,y]=n,[b,m,g,v]=(0,t.arePatternsQuoted)(n);let _,w,S;const A=this.nestedMap,D=h!==void 0?b?this.getQuotedPatternKeys(A,h):A.has(o)?[o]:[]:A.keys();for(const L of D){_=A.get(L);const E=f!==void 0?m?this.getQuotedPatternKeys(_,f):_.has(l)?[l]:[]:_.keys();for(const O of E){w=_.get(O);const P=p!==void 0?g?this.getQuotedPatternKeys(w,p):w.has(c)?[c]:[]:w.keys();for(const j of P)S=w.get(j),y!==void 0?v?r+=[...this.getQuotedPatternKeys(S,y)].length:S.has(d)&&r++:r+=S.size}}return r}};return Ch.RdfStoreIndexNestedMapQuoted=u,Ch}var A5;function F7(){if(A5)return Ih;A5=1,Object.defineProperty(Ih,"__esModule",{value:!0}),Ih.RdfStore=void 0;const t=Nt(),e=Et(),u=un(),s=B7(),n=j7(),r=L7(),a=M7(),o=Xi();let l=class I0{constructor(d){this.features={quotedTripleFiltering:!0},this._size=0,this.options=d,this.dataFactory=d.dataFactory,this.dictionary=d.dictionary,this.indexesWrapped=I0.constructIndexesWrapped(d),this.indexesWrappedComponentOrders=this.indexesWrapped.map(h=>h.componentOrder)}static createDefault(){return new I0({indexCombinations:I0.DEFAULT_INDEX_COMBINATIONS,indexConstructor:d=>new a.RdfStoreIndexNestedMapQuoted(d),dictionary:new r.TermDictionaryQuotedIndexed(new n.TermDictionaryNumberRecordFullTerms),dataFactory:new e.DataFactory})}static constructIndexesWrapped(d){const h=[];if(d.indexCombinations.length===0)throw new Error("At least one index combination is required");for(const f of d.indexCombinations){if(!I0.isCombinationValid(f))throw new Error(`Invalid index combination: ${f}`);h.push({index:d.indexConstructor(d),componentOrder:f,componentOrderInverse:Object.fromEntries(f.map((p,y)=>[p,y]))})}return h}static isCombinationValid(d){for(const h of u.QUAD_TERM_NAMES)if(!d.includes(h))return!1;return d.length===4}get size(){return this._size}addQuad(d){const h=[this.dictionary.encode(d.subject),this.dictionary.encode(d.predicate),this.dictionary.encode(d.object),this.dictionary.encode(d.graph)];let f=!1;for(const p of this.indexesWrapped)f=p.index.set((0,o.orderQuadComponents)(p.componentOrder,h),!0);return f?(this._size++,!0):!1}removeQuad(d){const h=[this.dictionary.encodeOptional(d.subject),this.dictionary.encodeOptional(d.predicate),this.dictionary.encodeOptional(d.object),this.dictionary.encodeOptional(d.graph)];if(h.includes(void 0))return!1;let f=!1;for(const p of this.indexesWrapped)if(f=p.index.remove((0,o.orderQuadComponents)(p.componentOrder,h)),!f)break;return f?(this._size--,!0):!1}remove(d){return d.on("data",h=>this.removeQuad(h)),d}removeMatches(d,h,f,p){return this.remove(this.match(d,h,f,p))}deleteGraph(d){return typeof d=="string"&&(d=this.dataFactory.namedNode(d)),this.removeMatches(void 0,void 0,void 0,d)}import(d){return d.on("data",h=>this.addQuad(h)),d}*readQuads(d,h,f,p){const y=!!this.dictionary.features.quotedTriples&&Object.values(this.indexesWrapped).every(_=>_.index.features.quotedTripleFiltering),[b,m]=(0,o.quadToPattern)(d,h,f,p,y),g=this.indexesWrapped[(0,o.getBestIndex)(this.indexesWrappedComponentOrders,b)],v=(0,o.orderQuadComponents)(g.componentOrder,b);for(const _ of g.index.find(v)){const w=this.dataFactory.quad(_[g.componentOrderInverse.subject],_[g.componentOrderInverse.predicate],_[g.componentOrderInverse.object],_[g.componentOrderInverse.graph]);m?(0,u.matchPattern)(w,d,h,f,p)&&(yield w):yield w}}getQuads(d,h,f,p){return[...this.readQuads(d,h,f,p)]}match(d,h,f,p){return(0,t.wrap)(this.readQuads(d,h,f,p))}countQuads(d,h,f,p){const y=!!this.dictionary.features.quotedTriples&&Object.values(this.indexesWrapped).every(v=>v.index.features.quotedTripleFiltering),[b]=(0,o.quadToPattern)(d,h,f,p,y);if(b.every(v=>v===void 0))return this.size;const m=this.indexesWrapped[(0,o.getBestIndex)(this.indexesWrappedComponentOrders,b)],g=(0,o.orderQuadComponents)(m.componentOrder,b);return m.index.count(g)}asDataset(){return new s.DatasetCoreWrapper(this)}};return l.DEFAULT_INDEX_COMBINATIONS=[["graph","subject","predicate","object"],["graph","predicate","object","subject"],["graph","object","subject","predicate"]],Ih.RdfStore=l,Ih}var E5;function B7(){if(E5)return xh;E5=1,Object.defineProperty(xh,"__esModule",{value:!0}),xh.DatasetCoreWrapper=void 0;const t=F7();let e=class q7{constructor(s){this.store=s}get size(){return this.store.size}add(s){return this.store.addQuad(s),this}delete(s){return this.store.removeQuad(s),this}has(s){for(const n of this.store.readQuads(s.subject,s.predicate,s.object,s.graph))return!0;return!1}match(s,n,r,a){const o=new t.RdfStore(this.store.options);for(const l of this.store.readQuads(s,n,r,a))o.addQuad(l);return new q7(o)}[Symbol.iterator](){return this.store.readQuads()}};return xh.DatasetCoreWrapper=e,xh}var $w={},O5;function DZ(){return O5||(O5=1,Object.defineProperty($w,"__esModule",{value:!0})),$w}var jh={},R5;function NZ(){if(R5)return jh;R5=1,Object.defineProperty(jh,"__esModule",{value:!0}),jh.TermDictionaryNumberMap=void 0;const t=Et(),e=er();let u=class{constructor(n=new t.DataFactory){this.lastId=0,this.dictionary=new Map,this.reverseDictionary=new Map,this.features={quotedTriples:!1},this.dataFactory=n}encode(n){const r=(0,e.termToString)(n);let a=this.dictionary.get(r);return a===void 0&&(a=this.lastId++,this.dictionary.set(r,a),this.reverseDictionary.set(a,r)),a}encodeOptional(n){const r=(0,e.termToString)(n);return this.dictionary.get(r)}decode(n){const r=this.reverseDictionary.get(n);if(r===void 0)throw new Error(`The value ${n} is not present in this dictionary`);return(0,e.stringToTerm)(r,this.dataFactory)}encodings(){return this.reverseDictionary.keys()}findQuotedTriples(n){throw new Error("findQuotedTriples is not supported")}findQuotedTriplesEncoded(n){throw new Error("findQuotedTriplesEncoded is not supported")}};return jh.TermDictionaryNumberMap=u,jh}var Lh={},x5;function CZ(){if(x5)return Lh;x5=1,Object.defineProperty(Lh,"__esModule",{value:!0}),Lh.TermDictionaryNumberRecord=void 0;const t=Et(),e=er();let u=class{constructor(n=new t.DataFactory){this.lastId=0,this.dictionary={},this.reverseDictionary={},this.features={quotedTriples:!1},this.dataFactory=n}encode(n){const r=(0,e.termToString)(n);let a=this.dictionary[r];return a===void 0&&(a=this.lastId++,this.dictionary[r]=a,this.reverseDictionary[a]=r),a}encodeOptional(n){const r=(0,e.termToString)(n);return this.dictionary[r]}decode(n){const r=this.reverseDictionary[n];if(r===void 0)throw new Error(`The value ${n} is not present in this dictionary`);return(0,e.stringToTerm)(r,this.dataFactory)}*encodings(){for(const n of Object.keys(this.reverseDictionary))yield Number.parseInt(n,10)}findQuotedTriples(n){throw new Error("findQuotedTriples is not supported")}findQuotedTriplesEncoded(n){throw new Error("findQuotedTriplesEncoded is not supported")}};return Lh.TermDictionaryNumberRecord=u,Lh}var Mh={},I5;function jZ(){if(I5)return Mh;I5=1,Object.defineProperty(Mh,"__esModule",{value:!0}),Mh.TermDictionaryQuoted=void 0;const t=Et(),e=un();let u=class Ls{constructor(n,r,a=new t.DataFactory){this.features={quotedTriples:!0},this.plainTermDictionary=n,this.quotedTriplesDictionary=r,this.dataFactory=a}encode(n){return n.termType==="Quad"?Ls.BITMASK|1+this.quotedTriplesDictionary.encode(n):this.plainTermDictionary.encode(n)}encodeOptional(n){if(n.termType==="Quad"){const r=this.quotedTriplesDictionary.encodeOptional(n);return r===void 0?r:Ls.BITMASK|1+r}return this.plainTermDictionary.encodeOptional(n)}decode(n){if(Ls.BITMASK&n){const r=(~Ls.BITMASK&n)-1;return this.quotedTriplesDictionary.decode(r)}return this.plainTermDictionary.decode(n)}*encodings(){for(const n of this.plainTermDictionary.encodings())yield n;for(const n of this.quotedTriplesDictionary.encodings())yield Ls.BITMASK|1+n}*findQuotedTriples(n){for(const r of this.findQuotedTriplesEncoded(n))yield this.decode(r)}*findQuotedTriplesEncoded(n){for(let r of this.quotedTriplesDictionary.encodings()){r=Ls.BITMASK|1+r;const a=this.decode(r);(0,e.matchPattern)(a,n.subject,n.predicate,n.object,n.graph)&&(yield r)}}};return u.BITMASK=1<<31,Mh.TermDictionaryQuoted=u,Mh}var Fh={},P5;function LZ(){if(P5)return Fh;P5=1,Object.defineProperty(Fh,"__esModule",{value:!0}),Fh.TermDictionaryQuotedReferential=void 0;const t=Et(),e=un(),u=Xi();let s=class ya{constructor(r,a=new t.DataFactory){this.quotedTriplesDictionary=[],this.quotedTriplesReverseDictionary={},this.features={quotedTriples:!0},this.plainTermDictionary=r,this.dataFactory=a}encode(r){return r.termType==="Quad"?this.encodeQuotedTriple(r,!1):this.plainTermDictionary.encode(r)}encodeQuotedTriple(r,a){var o;if(r.graph.termType!=="DefaultGraph")throw new Error("Encoding of quoted quads outside of the default graph is not allowed");const l=(o=(0,u.encodeOptionalTerms)([r.subject,r.predicate,r.object,void 0],this))===null||o===void 0?void 0:o.slice(0,3),c=l&&l.every(f=>f!==void 0)?this.quotedTriplesReverseDictionary[l.join(ya.SEPARATOR)]:void 0;if(c!==void 0||a)return c===void 0?void 0:ya.BITMASK|c;const d=[this.encode(r.subject),this.encode(r.predicate),this.encode(r.object)],h=this.quotedTriplesDictionary.length+1;return this.quotedTriplesDictionary.push(d),this.quotedTriplesReverseDictionary[d.join(ya.SEPARATOR)]=h,ya.BITMASK|h}encodeOptional(r){return r.termType==="Quad"?this.encodeQuotedTriple(r,!0):this.plainTermDictionary.encodeOptional(r)}decode(r){if(ya.BITMASK&r){const a=(~ya.BITMASK&r)-1;if(a>=this.quotedTriplesDictionary.length)throw new Error(`The value ${r} is not present in the quoted triples range of the dictionary`);const o=this.quotedTriplesDictionary[a];return this.dataFactory.quad(this.decode(o[0]),this.decode(o[1]),this.decode(o[2]))}return this.plainTermDictionary.decode(r)}*encodings(){for(const r of this.plainTermDictionary.encodings())yield r;for(const r of this.quotedTriplesDictionary.keys())yield ya.BITMASK|1+r}*findQuotedTriples(r){for(const a of this.findQuotedTriplesEncoded(r))yield this.decode(a)}*findQuotedTriplesEncoded(r){for(let a of this.quotedTriplesDictionary.keys()){a=ya.BITMASK|1+a;const o=this.decode(a);(0,e.matchPattern)(o,r.subject,r.predicate,r.object,r.graph)&&(yield a)}}};return s.BITMASK=1<<31,s.SEPARATOR="_",Fh.TermDictionaryQuotedReferential=s,Fh}var qh={},D5;function MZ(){if(D5)return qh;D5=1,Object.defineProperty(qh,"__esModule",{value:!0}),qh.TermDictionarySymbol=void 0;const t=Et(),e=er();let u=class{constructor(n=new t.DataFactory){this.features={quotedTriples:!1},this.dataFactory=n}encode(n){return Symbol.for(`rdf::${(0,e.termToString)(n)}`)}encodeOptional(n){return this.encode(n)}decode(n){const r=Symbol.keyFor(n);if(r===void 0)throw new Error(`The value ${String(n)} is not present in this dictionary`);return(0,e.stringToTerm)(r.slice(5),this.dataFactory)}encodings(){throw new Error("encodings is not supported")}findQuotedTriples(n){throw new Error("findQuotedTriples is not supported")}findQuotedTriplesEncoded(n){throw new Error("findQuotedTriplesEncoded is not supported")}};return qh.TermDictionarySymbol=u,qh}var Qw={},N5;function FZ(){return N5||(N5=1,Object.defineProperty(Qw,"__esModule",{value:!0})),Qw}var Bh={},C5;function U7(){if(C5)return Bh;C5=1,Object.defineProperty(Bh,"__esModule",{value:!0}),Bh.RdfStoreIndexNestedMapRecursive=void 0;const t=Xi();let e=class{constructor(s){this.features={quotedTripleFiltering:!1},this.dictionary=s.dictionary,this.nestedMap=new Map}set(s,n){let r=this.nestedMap,a=!1;for(const[o,l]of s.entries()){const c=r;let d=c.get(l);d?o===s.length-1&&(a=!0):(d=o===s.length-1?n:new Map,c.set(l,d)),r=d}return!a}remove(s){const n=this.nestedMap,r=n.get(s[0]);if(!r)return!1;const a=r.get(s[1]);if(!a)return!1;const o=a.get(s[2]);if(!o)return!1;const l=o.delete(s[3]);return l&&o.size===0&&(a.delete(s[2]),a.size===0&&(r.delete(s[1]),r.size===0&&n.delete(s[0]))),l}get(s){const n=(0,t.encodeOptionalTerms)(s,this.dictionary);if(!(!n||n.includes(void 0)))return this.getEncoded(n)}getEncoded(s){const n=this.nestedMap.get(s[0]);if(!n)return;const r=n.get(s[1]);if(!r)return;const a=r.get(s[2]);if(a)return a.get(s[3])}*find(s){const n=(0,t.encodeOptionalTerms)(s,this.dictionary);if(n)for(const r of this.findEncoded(n,s))yield[n[0]!==void 0?s[0]:this.dictionary.decode(r[0]),n[1]!==void 0?s[1]:this.dictionary.decode(r[1]),n[2]!==void 0?s[2]:this.dictionary.decode(r[2]),n[3]!==void 0?s[3]:this.dictionary.decode(r[3])]}*findEncoded(s,n){return yield*this.findEncodedInner(0,s,n,this.nestedMap,[])}*findEncodedInner(s,n,r,a,o){if(s===n.length)yield[...o];else{const l=n[s];if(r[s]){const d=l;if(d!==void 0){const h=a.get(d);h&&(o[s]=l,yield*this.findEncodedInner(s+1,n,r,h,o))}}else for(const[d,h]of a.entries())o[s]=d,yield*this.findEncodedInner(s+1,n,r,h,o)}}count(s){return this.countInner(0,s,this.nestedMap)}countInner(s,n,r){const a=n[s];let o=0;if(a){const l=this.dictionary.encodeOptional(a);if(l!==void 0){if(s===n.length-1)return r.has(l)?1:0;const c=r.get(l);c&&(o+=this.countInner(s+1,n,c))}}else{if(s===n.length-1)return r.size;for(const l of r.values())o+=this.countInner(s+1,n,l)}return o}};return Bh.RdfStoreIndexNestedMapRecursive=e,Bh}var Uh={},j5;function qZ(){if(j5)return Uh;j5=1,Object.defineProperty(Uh,"__esModule",{value:!0}),Uh.RdfStoreIndexNestedMapRecursiveQuoted=void 0;const t=Xi(),e=U7();let u=class extends e.RdfStoreIndexNestedMapRecursive{constructor(n){super(n),this.features={quotedTripleFiltering:!0}}*findEncoded(n,r){return yield*this.findEncodedInnerQuoted(0,n,r,(0,t.arePatternsQuoted)(r),this.nestedMap,[])}*findEncodedInnerQuoted(n,r,a,o,l,c){if(n===r.length)yield[...c];else{const d=r[n],h=a[n];if(h)if(o[n]){const f=this.dictionary.findQuotedTriplesEncoded(h);for(const p of f){const y=l.get(p);y&&(c[n]=p,yield*this.findEncodedInnerQuoted(n+1,r,a,o,y,c))}}else{const f=d;if(f!==void 0){const p=l.get(f);p&&(c[n]=d,yield*this.findEncodedInnerQuoted(n+1,r,a,o,p,c))}}else for(const[f,p]of l.entries())c[n]=f,yield*this.findEncodedInnerQuoted(n+1,r,a,o,p,c)}}countInner(n,r,a){const o=r[n];let l=0;if(o)if(o.termType==="Quad"&&(0,t.quadHasVariables)(o)){const c=this.dictionary.findQuotedTriplesEncoded(o);for(const d of c)if(n===r.length-1)a.has(d)&&l++;else{const h=a.get(d);h&&(l+=this.countInner(n+1,r,h))}}else{const c=this.dictionary.encodeOptional(o);if(c!==void 0){if(n===r.length-1)return a.has(c)?1:0;const d=a.get(c);d&&(l+=this.countInner(n+1,r,d))}}else{if(n===r.length-1)return a.size;for(const c of a.values())l+=this.countInner(n+1,r,c)}return l}};return Uh.RdfStoreIndexNestedMapRecursiveQuoted=u,Uh}var Hh={},L5;function H7(){if(L5)return Hh;L5=1,Object.defineProperty(Hh,"__esModule",{value:!0}),Hh.RdfStoreIndexNestedRecord=void 0;const t=Xi();let e=class{constructor(s){this.features={quotedTripleFiltering:!1},this.dictionary=s.dictionary,this.nestedRecords={}}set(s,n){const r=this.nestedRecords,a=r[s[0]]||(r[s[0]]={}),o=a[s[1]]||(a[s[1]]={}),l=o[s[2]]||(o[s[2]]={});return l[s[3]]?!1:(l[s[3]]=n,!0)}remove(s){const n=this.nestedRecords,r=n[s[0]];if(!r)return!1;const a=r[s[1]];if(!a)return!1;const o=a[s[2]];return!o||!o[s[3]]?!1:(delete o[s[3]],Object.keys(o).length===0&&(delete a[s[2]],Object.keys(a).length===0&&(delete r[s[1]],Object.keys(r).length===0&&delete n[s[0]])),!0)}get(s){const n=(0,t.encodeOptionalTerms)(s,this.dictionary);if(!(!n||n.includes(void 0)))return this.getEncoded(n)}getEncoded(s){var n,r,a;return(a=(r=(n=this.nestedRecords[s[0]])===null||n===void 0?void 0:n[s[1]])===null||r===void 0?void 0:r[s[2]])===null||a===void 0?void 0:a[s[3]]}*find(s){const n=(0,t.encodeOptionalTerms)(s,this.dictionary);if(!n)return;const[r,a,o,l]=n,[c,d,h,f]=s;let p,y,b,m,g,v,_;const w=this.nestedRecords,S=r!==void 0?r in w?[r]:[]:Object.keys(w);for(const A of S){g=w[A],p=c||this.dictionary.decode(Number.parseInt(A,10));const D=a!==void 0?a in g?[a]:[]:Object.keys(g);for(const L of D){v=g[L],y=d||this.dictionary.decode(Number.parseInt(L,10));const E=o!==void 0?o in v?[o]:[]:Object.keys(v);for(const O of E){_=v[O],b=h||this.dictionary.decode(Number.parseInt(O,10));const P=l!==void 0?l in _?[l]:[]:Object.keys(_);for(const j of P)m=f||this.dictionary.decode(Number.parseInt(j,10)),yield[p,y,b,m]}}}}*findEncoded(s,n){const[r,a,o,l]=s;let c,d,h;const f=this.nestedRecords,p=r!==void 0?r in f?[r]:[]:Object.keys(f);for(const y of p){c=f[y];const b=a!==void 0?a in c?[a]:[]:Object.keys(c);for(const m of b){d=c[m];const g=o!==void 0?o in d?[o]:[]:Object.keys(d);for(const v of g){h=d[v];const _=l!==void 0?l in h?[l]:[]:Object.keys(h);for(const w of _)yield[Number.parseInt(y,10),Number.parseInt(m,10),Number.parseInt(v,10),Number.parseInt(w,10)]}}}}count(s){let n=0;const r=(0,t.encodeOptionalTerms)(s,this.dictionary);if(!r)return 0;const a=r[0],o=r[1],l=r[2],c=r[3];let d,h,f;const p=this.nestedRecords,y=a!==void 0?a in p?[a]:[]:Object.keys(p);for(const b of y){d=p[b];const m=o!==void 0?o in d?[o]:[]:Object.keys(d);for(const g of m){h=d[g];const v=l!==void 0?l in h?[l]:[]:Object.keys(h);for(const _ of v)f=h[_],c!==void 0?c in f&&n++:n+=Object.keys(f).length}}return n}};return Hh.RdfStoreIndexNestedRecord=e,Hh}var $h={},M5;function BZ(){if(M5)return $h;M5=1,Object.defineProperty($h,"__esModule",{value:!0}),$h.RdfStoreIndexNestedRecordQuoted=void 0;const t=Xi(),e=H7();let u=class extends e.RdfStoreIndexNestedRecord{constructor(n){super(n),this.features={quotedTripleFiltering:!0}}*getQuotedPatternKeys(n,r){for(const a of this.dictionary.findQuotedTriplesEncoded(r))a in n&&(yield a)}*find(n){const r=(0,t.encodeOptionalTerms)(n,this.dictionary);if(!r)return;const[a,o,l,c]=r,[d,h,f,p]=n,[y,b,m,g]=(0,t.arePatternsQuoted)(n);let v,_,w,S,A,D,L;const E=this.nestedRecords,O=d!==void 0?y?this.getQuotedPatternKeys(E,d):a in E?[a]:[]:Object.keys(E);for(const P of O){A=E[P],v=!y&&d?d:this.dictionary.decode(Number.parseInt(P,10));const j=h!==void 0?b?this.getQuotedPatternKeys(A,h):o in A?[o]:[]:Object.keys(A);for(const U of j){D=A[U],_=!b&&h?h:this.dictionary.decode(Number.parseInt(U,10));const M=f!==void 0?m?this.getQuotedPatternKeys(D,f):l in D?[l]:[]:Object.keys(D);for(const q of M){L=D[q],w=!m&&f?f:this.dictionary.decode(Number.parseInt(q,10));const Q=p!==void 0?g?this.getQuotedPatternKeys(L,p):c in L?[c]:[]:Object.keys(L);for(const Z of Q)S=!g&&p?p:this.dictionary.decode(Number.parseInt(Z,10)),yield[v,_,w,S]}}}}*findEncoded(n,r){const[a,o,l,c]=n,[d,h,f,p]=r,[y,b,m,g]=(0,t.arePatternsQuoted)(r);let v,_,w;const S=this.nestedRecords,A=d!==void 0?y?this.getQuotedPatternKeys(S,d):a in S?[a]:[]:Object.keys(S);for(const D of A){v=S[D];const L=h!==void 0?b?this.getQuotedPatternKeys(v,h):o in v?[o]:[]:Object.keys(v);for(const E of L){_=v[E];const O=f!==void 0?m?this.getQuotedPatternKeys(_,f):l in _?[l]:[]:Object.keys(_);for(const P of O){w=_[P];const j=p!==void 0?g?this.getQuotedPatternKeys(w,p):c in w?[c]:[]:Object.keys(w);for(const U of j)yield[Number.parseInt(D,10),Number.parseInt(E,10),Number.parseInt(P,10),Number.parseInt(U,10)]}}}}count(n){let r=0;const a=(0,t.encodeOptionalTerms)(n,this.dictionary);if(!a)return 0;const[o,l,c,d]=a,[h,f,p,y]=n,[b,m,g,v]=(0,t.arePatternsQuoted)(n);let _,w,S;const A=this.nestedRecords,D=h!==void 0?b?this.getQuotedPatternKeys(A,h):o in A?[o]:[]:Object.keys(A);for(const L of D){_=A[L];const E=f!==void 0?m?this.getQuotedPatternKeys(_,f):l in _?[l]:[]:Object.keys(_);for(const O of E){w=_[O];const P=p!==void 0?g?this.getQuotedPatternKeys(w,p):c in w?[c]:[]:Object.keys(w);for(const j of P)S=w[j],y!==void 0?v?r+=[...this.getQuotedPatternKeys(S,y)].length:d in S&&r++:r+=Object.keys(S).length}}return r}};return $h.RdfStoreIndexNestedRecordQuoted=u,$h}var Vw={},F5;function UZ(){return F5||(F5=1,Object.defineProperty(Vw,"__esModule",{value:!0})),Vw}var kw={},q5;function HZ(){return q5||(q5=1,Object.defineProperty(kw,"__esModule",{value:!0})),kw}var B5;function $Z(){return B5||(B5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(B7(),t),u(DZ(),t),u(NZ(),t),u(CZ(),t),u(j7(),t),u(jZ(),t),u(L7(),t),u(LZ(),t),u(MZ(),t),u(FZ(),t),u(nA(),t),u(M7(),t),u(U7(),t),u(qZ(),t),u(H7(),t),u(BZ(),t),u(UZ(),t),u(Xi(),t),u(HZ(),t),u(F7(),t)}(Uw)),Uw}var U5;function $7(){if(U5)return Rh;U5=1,Object.defineProperty(Rh,"__esModule",{value:!0}),Rh.storeStream=void 0;const t=$Z();function e(u){const s=t.RdfStore.createDefault();return new Promise((n,r)=>s.import(u).on("error",r).once("end",()=>n(s)))}return Rh.storeStream=e,Rh}var H5;function QZ(){if(H5)return Ah;H5=1,Object.defineProperty(Ah,"__esModule",{value:!0}),Ah.ActorQuerySourceIdentifyHypermediaNone=void 0;const t=rA(),e=xr(),u=tA(),s=$7();let n=class extends u.ActorQuerySourceIdentifyHypermedia{constructor(a){super(a,"file")}async testMetadata(a){return{filterFactor:0}}async run(a){this.logInfo(a.context,`Identified as file source: ${a.url}`);const o=new t.QuerySourceRdfJs(await(0,s.storeStream)(a.quads),await e.BindingsFactory.create(this.mediatorMergeBindingsContext,a.context));return o.toString=()=>`QuerySourceRdfJs(${a.url})`,o.referenceValue=a.url,{source:o}}};return Ah.ActorQuerySourceIdentifyHypermediaNone=n,Ah}var $5;function VZ(){return $5||($5=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(QZ(),t)}(Fw)),Fw}var zw={},Qh={},Gw={},Vh={},kh={},Ww={},xs={},Q5;function Ki(){if(Q5)return xs;Q5=1,Object.defineProperty(xs,"__esModule",{value:!0}),xs.asTermType=xs.ExpressionType=void 0;var t;(function(u){u.Aggregate="aggregate",u.Existence="existence",u.Named="named",u.Operator="operator",u.SpecialOperator="specialOperator",u.Term="term",u.Variable="variable",u.AsyncExtension="asyncExtension",u.SyncExtension="syncExtension"})(t||(xs.ExpressionType=t={}));function e(u){if(u==="namedNode"||u==="literal"||u==="blankNode"||u==="quad")return u}return xs.asTermType=e,xs}var zh={},V5;function kZ(){if(V5)return zh;V5=1,Object.defineProperty(zh,"__esModule",{value:!0}),zh.Variable=void 0;const t=Ki();let e=class{constructor(s){this.expressionType=t.ExpressionType.Variable,this.name=s}};return zh.Variable=e,zh}var At={},Gh={},Jw={},k5;function Cn(){return k5||(k5=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.NamedOperators=t.SetFunctions=t.SetFunction=t.Operators=t.SpecialOperators=t.RegularOperators=t.SpecialOperator=t.RegularOperator=t.TypeURL=t.TypeAlias=void 0;var e;(function(a){a.SPARQL_NUMERIC="SPARQL_NUMERIC",a.SPARQL_STRINGLY="SPARQL_STRINGLY"})(e||(t.TypeAlias=e={}));var u;(function(a){a.XSD_ANY_URI="http://www.w3.org/2001/XMLSchema#anyURI",a.XSD_STRING="http://www.w3.org/2001/XMLSchema#string",a.RDF_LANG_STRING="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString",a.XSD_BOOLEAN="http://www.w3.org/2001/XMLSchema#boolean",a.XSD_DATE_TIME="http://www.w3.org/2001/XMLSchema#dateTime",a.XSD_DATE_TIME_STAMP="http://www.w3.org/2001/XMLSchema#dateTimeStamp",a.XSD_DATE="http://www.w3.org/2001/XMLSchema#date",a.XSD_G_MONTH="http://www.w3.org/2001/XMLSchema#gMonth",a.XSD_G_MONTHDAY="http://www.w3.org/2001/XMLSchema#gMonthDay",a.XSD_G_YEAR="http://www.w3.org/2001/XMLSchema#gYear",a.XSD_G_YEAR_MONTH="http://www.w3.org/2001/XMLSchema#gYearMonth",a.XSD_TIME="http://www.w3.org/2001/XMLSchema#time",a.XSD_G_DAY="http://www.w3.org/2001/XMLSchema#gDay",a.XSD_DECIMAL="http://www.w3.org/2001/XMLSchema#decimal",a.XSD_FLOAT="http://www.w3.org/2001/XMLSchema#float",a.XSD_DOUBLE="http://www.w3.org/2001/XMLSchema#double",a.XSD_INTEGER="http://www.w3.org/2001/XMLSchema#integer",a.XSD_NON_POSITIVE_INTEGER="http://www.w3.org/2001/XMLSchema#nonPositiveInteger",a.XSD_NEGATIVE_INTEGER="http://www.w3.org/2001/XMLSchema#negativeInteger",a.XSD_LONG="http://www.w3.org/2001/XMLSchema#long",a.XSD_INT="http://www.w3.org/2001/XMLSchema#int",a.XSD_SHORT="http://www.w3.org/2001/XMLSchema#short",a.XSD_BYTE="http://www.w3.org/2001/XMLSchema#byte",a.XSD_NON_NEGATIVE_INTEGER="http://www.w3.org/2001/XMLSchema#nonNegativeInteger",a.XSD_POSITIVE_INTEGER="http://www.w3.org/2001/XMLSchema#positiveInteger",a.XSD_UNSIGNED_LONG="http://www.w3.org/2001/XMLSchema#unsignedLong",a.XSD_UNSIGNED_INT="http://www.w3.org/2001/XMLSchema#unsignedInt",a.XSD_UNSIGNED_SHORT="http://www.w3.org/2001/XMLSchema#unsignedShort",a.XSD_UNSIGNED_BYTE="http://www.w3.org/2001/XMLSchema#unsignedByte",a.XSD_NORMALIZED_STRING="http://www.w3.org/2001/XMLSchema#normalizedString",a.XSD_TOKEN="http://www.w3.org/2001/XMLSchema#token",a.XSD_LANGUAGE="http://www.w3.org/2001/XMLSchema#language",a.XSD_NM_TOKEN="http://www.w3.org/2001/XMLSchema#NMTOKEN",a.XSD_NAME="http://www.w3.org/2001/XMLSchema#name",a.XSD_NC_NAME="http://www.w3.org/2001/XMLSchema#NCName",a.XSD_ENTITY="http://www.w3.org/2001/XMLSchema#ENTITY",a.XSD_ID="http://www.w3.org/2001/XMLSchema#ID",a.XSD_ID_REF="http://www.w3.org/2001/XMLSchema#IDREF",a.XSD_DURATION="http://www.w3.org/2001/XMLSchema#duration",a.XSD_YEAR_MONTH_DURATION="http://www.w3.org/2001/XMLSchema#yearMonthDuration",a.XSD_DAY_TIME_DURATION="http://www.w3.org/2001/XMLSchema#dayTimeDuration"})(u||(t.TypeURL=u={}));var s;(function(a){a.NOT="!",a.UMINUS="uminus",a.UPLUS="uplus",a.EQUAL="=",a.NOT_EQUAL="!=",a.LT="<",a.GT=">",a.LTE="<=",a.GTE=">=",a.MULTIPLICATION="*",a.DIVISION="/",a.ADDITION="+",a.SUBTRACTION="-",a.IS_IRI="isiri",a.IS_URI="isuri",a.IS_BLANK="isblank",a.IS_LITERAL="isliteral",a.IS_NUMERIC="isnumeric",a.STR="str",a.LANG="lang",a.DATATYPE="datatype",a.IRI="iri",a.URI="uri",a.STRDT="strdt",a.STRLANG="strlang",a.UUID="uuid",a.STRUUID="struuid",a.STRLEN="strlen",a.SUBSTR="substr",a.UCASE="ucase",a.LCASE="lcase",a.STRSTARTS="strstarts",a.STRENDS="strends",a.CONTAINS="contains",a.STRBEFORE="strbefore",a.STRAFTER="strafter",a.ENCODE_FOR_URI="encode_for_uri",a.LANG_MATCHES="langmatches",a.REGEX="regex",a.REPLACE="replace",a.ABS="abs",a.ROUND="round",a.CEIL="ceil",a.FLOOR="floor",a.RAND="rand",a.NOW="now",a.YEAR="year",a.MONTH="month",a.DAY="day",a.HOURS="hours",a.MINUTES="minutes",a.SECONDS="seconds",a.TIMEZONE="timezone",a.TZ="tz",a.MD5="md5",a.SHA1="sha1",a.SHA256="sha256",a.SHA384="sha384",a.SHA512="sha512",a.TRIPLE="triple",a.SUBJECT="subject",a.PREDICATE="predicate",a.OBJECT="object",a.IS_TRIPLE="istriple"})(s||(t.RegularOperator=s={}));var n;(function(a){a.BOUND="bound",a.IF="if",a.COALESCE="coalesce",a.LOGICAL_OR="||",a.LOGICAL_AND="&&",a.SAME_TERM="sameterm",a.IN="in",a.NOT_IN="notin",a.CONCAT="concat",a.BNODE="bnode"})(n||(t.SpecialOperator=n={})),t.RegularOperators=new Set(Object.values(s)),t.SpecialOperators=new Set(Object.values(n)),t.Operators=new Set([...t.RegularOperators,...t.SpecialOperators]);var r;(function(a){a.COUNT="count",a.SUM="sum",a.MIN="min",a.MAX="max",a.AVG="avg",a.GROUP_CONCAT="group_concat",a.SAMPLE="sample"})(r||(t.SetFunction=r={})),t.SetFunctions=new Set(Object.values(r)),t.NamedOperators=new Set([u.XSD_STRING,u.XSD_FLOAT,u.XSD_DOUBLE,u.XSD_DECIMAL,u.XSD_INTEGER,u.XSD_DATE_TIME,u.XSD_DATE,u.XSD_BOOLEAN,u.XSD_TIME,u.XSD_DURATION,u.XSD_DAY_TIME_DURATION,u.XSD_YEAR_MONTH_DURATION])}(Jw)),Jw}var gt={},z5;function on(){if(z5)return gt;z5=1,Object.defineProperty(gt,"__esModule",{value:!0}),gt.NoExistenceHook=gt.NoAggregator=gt.ExtensionFunctionError=gt.UnknownNamedOperator=gt.UnknownOperator=gt.InvalidTermType=gt.InvalidExpressionType=gt.InvalidExpression=gt.InvalidArity=gt.UnexpectedError=gt.ParseError=gt.EmptyAggregateError=gt.IncompatibleLanguageOperation=gt.InvalidTimezoneCall=gt.CastError=gt.InvalidCompareArgumentTypes=gt.InvalidArgumentTypes=gt.InError=gt.CoalesceError=gt.RDFEqualTypeError=gt.EBVCoercionError=gt.UnboundVariableError=gt.InvalidLexicalForm=gt.isExpressionError=gt.ExpressionError=void 0;class t extends Error{}gt.ExpressionError=t;function e(O){return O instanceof t}gt.isExpressionError=e;class u extends t{constructor(P){super(`Invalid lexical form '${E(P)}'`),this.arg=P}}gt.InvalidLexicalForm=u;class s extends t{constructor(P,j){super(`Unbound variable '${E(P)}'`),this.variable=P,this.bindings=j}}gt.UnboundVariableError=s;class n extends t{constructor(P){super(`Cannot coerce term to EBV '${E(P)}'`),this.arg=P}}gt.EBVCoercionError=n;class r extends t{constructor(P){super("Equality test for literals with unsupported datatypes"),this.args=P}}gt.RDFEqualTypeError=r;class a extends t{constructor(P){super("All COALESCE arguments threw errors"),this.errors=P}}gt.CoalesceError=a;class o extends t{constructor(P){super(`Some argument to IN errorred and none where equal. ${P.map(j=>`(${j.toString()}) `).join("and ")}`),this.errors=P}}gt.InError=o;class l extends t{constructor(P,j){super(`Argument types not valid for operator: '${E(j)}' with '${E(P)}`),this.args=P,this.op=j}}gt.InvalidArgumentTypes=l;class c extends t{constructor(P,j){super(`Compared argument types are supported: '${P.termType}' and '${j.termType}'`),this.arg0=P,this.arg1=j}}gt.InvalidCompareArgumentTypes=c;class d extends t{constructor(P,j){super(`Invalid cast: '${E(P)}' to '${E(j)}'`),this.arg=P}}gt.CastError=d;class h extends t{constructor(P){super(`TIMEZONE call on ${P} which has no timezone`),this.dateString=P}}gt.InvalidTimezoneCall=h;class f extends t{constructor(P,j){super(`Operation on incompatible language literals '${E(P)}' and '${E(j)}'`),this.arg1=P,this.arg2=j}}gt.IncompatibleLanguageOperation=f;class p extends t{constructor(){super("Empty aggregate expression")}}gt.EmptyAggregateError=p;class y extends t{constructor(P,j){super(`Failed to parse ${P} as ${j}.`)}}gt.ParseError=y;class b extends Error{constructor(P,j){super(`Programmer Error '${P}'`),this.payload=j}}gt.UnexpectedError=b;class m extends Error{constructor(P,j){super(`The number of args does not match the arity of the operator '${E(j)}'.`),this.args=P,this.op=j}}gt.InvalidArity=m;class g extends Error{constructor(P){super(`Invalid SPARQL Expression '${E(P)}'`)}}gt.InvalidExpression=g;class v extends Error{constructor(P){super(`Invalid expression type for SPARQL Expression '${E(P)}'`),this.expr=P}}gt.InvalidExpressionType=v;class _ extends Error{constructor(P){super(`Invalid term type for term '${E(P)}'`),this.term=P}}gt.InvalidTermType=_;class w extends Error{constructor(P){super(`Unknown operator: '${E(P)}`)}}gt.UnknownOperator=w;class S extends Error{constructor(P){super(`Unknown named operator: '${E(P)}'`)}}gt.UnknownNamedOperator=S;class A extends Error{constructor(P,j){j instanceof Error?super(`Error thrown in ${P}: ${j.message}${j.stack?` -${j.stack}`:""}`):super(`Error thrown in ${P}`)}}gt.ExtensionFunctionError=A;class D extends Error{constructor(P){super(`Aggregate expression ${E(P)} found, but no aggregate hook provided.`)}}gt.NoAggregator=D;class L extends Error{constructor(){super("EXISTS found, but no existence hook provided.")}}gt.NoExistenceHook=L;function E(O){return JSON.stringify(O)}return gt}var jr={},$t={},G5;function ou(){if(G5)return $t;G5=1,Object.defineProperty($t,"__esModule",{value:!0}),$t.extractTimeZone=$t.extractRawTimeZone=$t.dayTimeDurationsToSeconds=$t.yearMonthDurationsToMonths=$t.trimToDayTimeDuration=$t.trimToYearMonthDuration=$t.toUTCDate=$t.toJSDate=$t.negateDuration=$t.toDateTimeRepresentation=$t.defaultedDateTimeRepresentation=$t.simplifyDurationRepresentation=$t.defaultedDurationRepresentation=$t.defaultedYearMonthDurationRepresentation=$t.defaultedDayTimeDurationRepresentation=void 0;function t(b){return{day:b.day??0,hours:b.hours??0,minutes:b.minutes??0,seconds:b.seconds??0}}$t.defaultedDayTimeDurationRepresentation=t;function e(b){return{year:b.year??0,month:b.month??0}}$t.defaultedYearMonthDurationRepresentation=e;function u(b){return{...t(b),...e(b)}}$t.defaultedDurationRepresentation=u;function s(b){const m=u(b),g={},v=m.year+Math.trunc(m.month/12);v&&(g.year=v,m.month%=12),m.month&&(g.month=m.month);const _=m.day+Math.trunc(m.hours/24)+Math.trunc(m.minutes/(24*60))+Math.trunc(m.seconds/(24*60*60));_&&(g.day=_,m.hours%=24,m.minutes%=24*60,m.seconds%=24*60*60);const w=m.hours+Math.trunc(m.minutes/60)+Math.trunc(m.seconds/(60*60));w&&(g.hours=w,m.minutes%=60,m.seconds%=60*60);const S=m.minutes+Math.trunc(m.seconds/60);return S&&(g.minutes=S,m.seconds%=60),m.seconds&&(g.seconds=m.seconds),g}$t.simplifyDurationRepresentation=s;function n(b){return{...b,day:b.day??1,hours:b.hours??0,month:b.month??1,year:b.year??0,seconds:b.seconds??0,minutes:b.minutes??0}}$t.defaultedDateTimeRepresentation=n;function r({date:b,timeZone:m}){return{year:b.getFullYear(),month:b.getMonth()+1,day:b.getDate(),hours:b.getHours(),minutes:b.getMinutes(),seconds:b.getSeconds(),zoneHours:m.zoneHours,zoneMinutes:m.zoneMinutes}}$t.toDateTimeRepresentation=r;function a(b){return{year:b.year===void 0?void 0:-1*b.year,month:b.month===void 0?void 0:-1*b.month,day:b.day===void 0?void 0:-1*b.day,hours:b.hours===void 0?void 0:-1*b.hours,minutes:b.minutes===void 0?void 0:-1*b.minutes,seconds:b.seconds===void 0?void 0:-1*b.seconds}}$t.negateDuration=a;function o(b){const m=new Date(b.year,b.month-1,b.day,b.hours,b.minutes,Math.trunc(b.seconds),b.seconds%1*1e3);return b.year>=0&&b.year<100&&m.setFullYear(m.getFullYear()-1900),m}$t.toJSDate=o;function l(b,m){const g=o(n(b)),v=g.getTimezoneOffset(),_=b.zoneHours??m.zoneHours,w=b.zoneMinutes??m.zoneMinutes;return new Date(g.getTime()-(v+_*60+w)*60*1e3)}$t.toUTCDate=l;function c(b){return{year:b.year,month:b.month}}$t.trimToYearMonthDuration=c;function d(b){return{day:b.day,hours:b.hours,minutes:b.minutes,seconds:b.seconds}}$t.trimToDayTimeDuration=d;function h(b){return b.year*12+b.month}$t.yearMonthDurationsToMonths=h;function f(b){return((b.day*24+b.hours)*60+b.minutes)*60+b.seconds}$t.dayTimeDurationsToSeconds=f;function p(b){return/(Z|([+-]\d\d:\d\d))?$/u.exec(b)[0]}$t.extractRawTimeZone=p;function y(b){return{zoneHours:b.getTimezoneOffset()/60,zoneMinutes:b.getTimezoneOffset()%60}}return $t.extractTimeZone=y,$t}var ca={},W5;function Q7(){if(W5)return ca;W5=1,Object.defineProperty(ca,"__esModule",{value:!0}),ca.elapsedDuration=ca.addDurationToDateTime=ca.maximumDayInMonthFor=void 0;const t=ou();function e(r,a,o=0){const l=r-o,c=a-o,d=Math.floor(l/c);return{intDiv:d,remainder:r-d*c}}function u(r,a){const{intDiv:o,remainder:l}=e(a,13,1),c=r+o;return[1,3,5,7,8,10,12].includes(l)?31:[4,6,9,11].includes(l)?30:l===2&&(e(c,400).remainder===0||e(c,100).remainder!==0&&e(c,4).remainder===0)?29:28}ca.maximumDayInMonthFor=u;function s(r,a){const o={...r};let l=e(r.month+a.month,13,1);for(o.month=l.remainder,o.year=r.year+a.year+l.intDiv,l=e(r.seconds+a.seconds,60),o.seconds=l.remainder,l=e(r.minutes+a.minutes+l.intDiv,60),o.minutes=l.remainder,l=e(r.hours+a.hours+l.intDiv,24),o.hours=l.remainder,o.day=r.day+a.day+l.intDiv;;){let c;if(o.day<1)o.day+=u(o.year,o.month-1),c=-1;else if(o.day>u(o.year,o.month))o.day-=u(o.year,o.month),c=1;else break;l=e(o.month+c,13,1),o.month=l.remainder,o.year+=l.intDiv}return o}ca.addDurationToDateTime=s;function n(r,a,o){const l=(0,t.toUTCDate)(r,o),c=(0,t.toUTCDate)(a,o),d=l.getTime()-c.getTime();return{day:Math.floor(d/(1e3*60*60*24)),hours:Math.floor(d%(1e3*60*60*24)/(1e3*60*60)),minutes:Math.floor(d%(1e3*60*60)/(1e3*60)),seconds:d%(1e3*60)}}return ca.elapsedDuration=n,ca}var J5;function y3(){if(J5)return jr;J5=1,Object.defineProperty(jr,"__esModule",{value:!0}),jr.parseDayTimeDuration=jr.parseYearMonthDuration=jr.parseDuration=jr.parseTime=jr.parseDate=jr.parseDateTime=jr.parseXSDInteger=jr.parseXSDDecimal=jr.parseXSDFloat=void 0;const t=ou(),e=on(),u=Q7();function s(y){const b=Number(y);return Number.isNaN(b)?y==="NaN"?Number.NaN:y==="INF"||y==="+INF"?Number.POSITIVE_INFINITY:y==="-INF"?Number.NEGATIVE_INFINITY:void 0:b}jr.parseXSDFloat=s;function n(y){const b=Number(y);return Number.isNaN(b)?void 0:b}jr.parseXSDDecimal=n;function r(y){const b=Number.parseInt(y,10);return Number.isNaN(b)?void 0:b}jr.parseXSDInteger=r;function a(y){const[b,m]=y.split("T");return{...l(b),...c(m)}}jr.parseDateTime=a;function o(y){if(y==="")return{zoneHours:void 0,zoneMinutes:void 0};if(y==="Z")return{zoneHours:0,zoneMinutes:0};const m=y.replaceAll(/^([+|-])(\d\d):(\d\d)$/gu,"$11!$2!$3").split("!").map(Number);return{zoneHours:m[0]*m[1],zoneMinutes:m[0]*m[2]}}function l(y){const b=y.replaceAll(/^(-)?([123456789]*\d{4})-(\d\d)-(\d\d)(Z|([+-]\d\d:\d\d))?$/gu,"$11!$2!$3!$4!$5");if(b===y)throw new e.ParseError(y,"date");const m=b.split("!"),g=m.slice(0,-1).map(Number),v={year:g[0]*g[1],month:g[2],day:g[3],...o(m[4])};if(!(v.month>=1&&v.month<=12)||!(v.day>=1&&v.day<=(0,u.maximumDayInMonthFor)(v.year,v.month)))throw new e.ParseError(y,"date");return v}jr.parseDate=l;function c(y){const b=y.replaceAll(/^(\d\d):(\d\d):(\d\d(\.\d+)?)(Z|([+-]\d\d:\d\d))?$/gu,"$1!$2!$3!$5");if(b===y)throw new e.ParseError(y,"time");const m=b.split("!"),g=m.slice(0,-1).map(Number),v={hours:g[0],minutes:g[1],seconds:g[2],...o(m[3])};if(v.seconds>=60||v.minutes>=60||v.hours>24||v.hours===24&&(v.minutes!==0||v.seconds!==0))throw new e.ParseError(y,"time");return v}function d(y){const b=c(y);return b.hours%=24,b}jr.parseTime=d;function h(y){const[b,m]=y.split("T"),g=b.replaceAll(/^(-)?P(\d+Y)?(\d+M)?(\d+D)?$/gu,"$11S!$2!$3!$4");if(g===b)throw new e.ParseError(y,"duration");const v=g.split("!");if(m!==void 0){const S=m.replaceAll(/^(\d+H)?(\d+M)?(\d+(\.\d+)?S)?$/gu,"$1!$2!$3");if(m===""||m===S)throw new e.ParseError(y,"duration");v.push(...S.split("!"))}const _=v.map(S=>S.slice(0,-1));if(!_.slice(1).some(Boolean))throw new e.ParseError(y,"duration");const w=Number(_[0]);return(0,t.simplifyDurationRepresentation)({year:_[1]?w*Number(_[1]):void 0,month:_[2]?w*Number(_[2]):void 0,day:_[3]?w*Number(_[3]):void 0,hours:_[4]?w*Number(_[4]):void 0,minutes:_[5]?w*Number(_[5]):void 0,seconds:_[6]?w*Number(_[6]):void 0})}jr.parseDuration=h;function f(y){const b=h(y);if(["hours","minutes","seconds","day"].some(m=>!!b[m]))throw new e.ParseError(y,"yearMonthDuration");return b}jr.parseYearMonthDuration=f;function p(y){const b=h(y);if(["year","month"].some(m=>!!b[m]))throw new e.ParseError(y,"dayTimeDuration");return b}return jr.parseDayTimeDuration=p,jr}var Xw={},fr={},Wh={},X5;function V7(){if(X5)return Wh;X5=1,Object.defineProperty(Wh,"__esModule",{value:!0}),Wh.OverloadTree=void 0;const t=Kn(),e=Wb();let u=class b3{constructor(n,r){this.identifier=n,this.implementation=void 0,this.generalOverloads=Object.create(null),this.literalOverLoads=[],this.depth=r??0,this.promotionCount=void 0}getSubtree(n){const r=(0,e.asGeneralType)(n);if(r)return this.generalOverloads[r];for(const[a,o]of this.literalOverLoads)if(n===a)return o}getImplementationExact(n){let r=this;for(const a of n)if(r=r.getSubtree(a),!r)return;return r.implementation}search(n,r,a){let o=a[this.identifier],l=0;for(;l({node:h,index:d+1})));c.length>0;){const{index:h,node:f}=c.pop();if(h===n.length&&f.implementation)return this.addToCache(a,n,f.implementation),f.implementation;c.push(...f.getSubTreeWithArg(n[h],r).map(p=>({node:p,index:h+1})))}}addToCache(n,r,a){function o(c,d){return d in c||(c[d]={}),c[d]}let l=o(n,this.identifier);for(const c of r){const d=(0,t.isLiteralTermExpression)(c),h=d?d.dataType:c.termType;l.cache=l.cache??{},l=o(l.cache,h)}l.func=a}addOverload(n,r){this._addOverload([...n],r,0)}_addOverload(n,r,a){const[o,...l]=n;if(!o){(this.promotionCount===void 0||a<=this.promotionCount)&&(this.promotionCount=a,this.implementation=r);return}let c=this.getSubtree(o);if(!c){const d=new b3(this.identifier,this.depth+1),h=(0,e.asGeneralType)(o);h&&(this.generalOverloads[h]=d);const f=(0,e.asOverrideType)(o);f&&this.literalOverLoads.push([f,d]),c=d}if(c._addOverload(l,r,a),e.typePromotion[o])for(const d of e.typePromotion[o])this.addPromotedOverload(d.typeToPromote,r,d.conversionFunction,l,a)}addPromotedOverload(n,r,a,o,l){let c=this.getSubtree(n);if(!c){const d=new b3(this.identifier,this.depth+1);this.literalOverLoads.push([n,d]),c=d}c._addOverload(o,d=>h=>r(d)([...h.slice(0,this.depth),a(h[this.depth]),...h.slice(this.depth+1,h.length)]),l+1)}getSubTreeWithArg(n,r){const a=[],o=(0,t.isLiteralTermExpression)(n);if(this.generalOverloads.term&&a.push(this.generalOverloads.term),this.generalOverloads[n.termType]&&a.push(this.generalOverloads[n.termType]),o){const l=(0,e.asKnownLiteralType)(o.dataType);let c;l?c=e.superTypeDictTable[l]:c=(0,e.getSuperTypes)(o.dataType,r);const d=this.literalOverLoads.filter(([h,f])=>h in c).map(([h,f])=>[c[h],f]);d.sort(([h,f],[p,y])=>h-p),a.push(...d.map(([h,f])=>f))}return a}};return Wh.OverloadTree=u,Wh}var K5;function Yi(){if(K5)return fr;K5=1,Object.defineProperty(fr,"__esModule",{value:!0}),fr.expressionToVar=fr.dateTime=fr.langString=fr.string=fr.double=fr.float=fr.decimal=fr.integer=fr.bool=fr.Builder=fr.declare=void 0;const t=Et(),e=Kn(),u=Kn(),s=Cn(),n=Cn(),r=on(),a=V7(),o=new t.DataFactory;function l(_){return new c(_)}fr.declare=l;class c{constructor(w){this.overloadTree=new a.OverloadTree(w),this.collected=!1}collect(){if(this.collected)throw new Error("Builders can only be collected once!");return this.collected=!0,this.overloadTree}static wrapInvalidLexicalProtected(w){return S=>A=>{for(const[D,L]of A.entries())if(L instanceof u.NonLexicalLiteral)throw new r.InvalidLexicalForm(A[D].toRDF());return w(S)(A)}}set(w,S,A=!0){return this.overloadTree.addOverload(w,A?c.wrapInvalidLexicalProtected(S):S),this}copy({from:w,to:S}){const A=this.overloadTree.getImplementationExact(w);if(!A)throw new r.UnexpectedError("Tried to copy implementation, but types not found",{from:w,to:S});return this.set(S,A)}onUnary(w,S,A=!0){return this.set([w],D=>([L])=>S(D)(L),A)}onUnaryTyped(w,S,A=!0){return this.set([w],D=>([L])=>S(D)(L.typedValue),A)}onBinary(w,S,A=!0){return this.set(w,D=>([L,E])=>S(D)(L,E),A)}onBinaryTyped(w,S,A=!0){return this.set(w,D=>([L,E])=>S(D)(L.typedValue,E.typedValue),A)}onTernaryTyped(w,S,A=!0){return this.set(w,D=>([L,E,O])=>S(D)(L.typedValue,E.typedValue,O.typedValue),A)}onTernary(w,S,A=!0){return this.set(w,D=>([L,E,O])=>S(D)(L,E,O),A)}onQuaternaryTyped(w,S,A=!0){return this.set(w,D=>([L,E,O,P])=>S(D)(L.typedValue,E.typedValue,O.typedValue,P.typedValue),A)}onTerm1(w,S=!1){return this.set(["term"],A=>([D])=>w(A)(D),S)}onTerm3(w){return this.set(["term","term","term"],S=>([A,D,L])=>w(S)(A,D,L))}onQuad1(w){return this.set(["quad"],S=>([A])=>w(S)(A))}onLiteral1(w,S=!0){return this.set(["literal"],A=>([D])=>w(A)(D),S)}onBoolean1(w,S=!0){return this.set([s.TypeURL.XSD_BOOLEAN],A=>([D])=>w(A)(D),S)}onBoolean1Typed(w,S=!0){return this.set([s.TypeURL.XSD_BOOLEAN],A=>([D])=>w(A)(D.typedValue),S)}onString1(w,S=!0){return this.set([s.TypeURL.XSD_STRING],A=>([D])=>w(A)(D),S)}onString1Typed(w,S=!0){return this.set([s.TypeURL.XSD_STRING],A=>([D])=>w(A)(D.typedValue),S)}onLangString1(w,S=!0){return this.set([s.TypeURL.RDF_LANG_STRING],A=>([D])=>w(A)(D),S)}onStringly1(w,S=!0){return this.set([s.TypeAlias.SPARQL_STRINGLY],A=>([D])=>w(A)(D),S)}onStringly1Typed(w,S=!0){return this.set([s.TypeAlias.SPARQL_STRINGLY],A=>([D])=>w(A)(D.typedValue),S)}onNumeric1(w,S=!0){return this.set([s.TypeAlias.SPARQL_NUMERIC],A=>([D])=>w(A)(D),S)}onDateTime1(w,S=!0){return this.set([s.TypeURL.XSD_DATE_TIME],A=>([D])=>w(A)(D),S)}numericConverter(w,S=!0){const A=D=>L=>w(D)(L.typedValue);return this.onUnary(n.TypeURL.XSD_INTEGER,D=>L=>h(A(D)(L)),S).onUnary(n.TypeURL.XSD_DECIMAL,D=>L=>f(A(D)(L)),S).onUnary(n.TypeURL.XSD_FLOAT,D=>L=>p(A(D)(L)),S).onUnary(n.TypeURL.XSD_DOUBLE,D=>L=>y(A(D)(L)),S)}arithmetic(w,S=!0){const A=D=>(L,E)=>w(D)(L.typedValue,E.typedValue);return this.onBinary([n.TypeURL.XSD_INTEGER,n.TypeURL.XSD_INTEGER],D=>(L,E)=>h(A(D)(L,E)),S).onBinary([n.TypeURL.XSD_DECIMAL,n.TypeURL.XSD_DECIMAL],D=>(L,E)=>f(A(D)(L,E)),S).onBinary([n.TypeURL.XSD_FLOAT,n.TypeURL.XSD_FLOAT],D=>(L,E)=>p(A(D)(L,E)),S).onBinary([n.TypeURL.XSD_DOUBLE,n.TypeURL.XSD_DOUBLE],D=>(L,E)=>y(A(D)(L,E)),S)}numberTest(w){return this.numeric(S=>([A,D])=>{const L=w(S)(A.typedValue,D.typedValue);return d(L)})}stringTest(w,S=!0){return this.set([s.TypeURL.XSD_STRING,s.TypeURL.XSD_STRING],A=>([D,L])=>{const E=w(A)(D.typedValue,L.typedValue);return d(E)},S)}booleanTest(w,S=!0){return this.set([s.TypeURL.XSD_BOOLEAN,s.TypeURL.XSD_BOOLEAN],A=>([D,L])=>{const E=w(A)(D.typedValue,L.typedValue);return d(E)},S)}dateTimeTest(w,S=!0){return this.set([s.TypeURL.XSD_DATE_TIME,s.TypeURL.XSD_DATE_TIME],A=>([D,L])=>{const E=w(A)(D.typedValue,L.typedValue);return d(E)},S)}numeric(w){return this.set([s.TypeAlias.SPARQL_NUMERIC,s.TypeAlias.SPARQL_NUMERIC],w)}}fr.Builder=c;function d(_){return new e.BooleanLiteral(_)}fr.bool=d;function h(_){return new e.IntegerLiteral(_)}fr.integer=h;function f(_){return new e.DecimalLiteral(_)}fr.decimal=f;function p(_){return new e.FloatLiteral(_)}fr.float=p;function y(_){return new e.DoubleLiteral(_)}fr.double=y;function b(_){return new e.StringLiteral(_)}fr.string=b;function m(_,w){return new e.LangStringLiteral(_,w)}fr.langString=m;function g(_,w){return new e.DateTimeLiteral(_,w)}fr.dateTime=g;function v(_){return o.variable(_.name.slice(1))}return fr.expressionToVar=v,fr}var Y5;function Wb(){return Y5||(Y5=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.typePromotion=t.isSubTypeOf=t.getSuperTypeDict=t.isInternalSubType=t.asGeneralType=t.asOverrideType=t.asKnownLiteralType=t.asTypeAlias=t.typeAliasCheck=t.extensionTableInit=t.getSuperTypes=t.superTypeDictTable=t.extensionTableInput=void 0;const e=Kn(),u=Yi(),s=Cn();t.extensionTableInput={[s.TypeURL.XSD_DATE_TIME_STAMP]:s.TypeURL.XSD_DATE_TIME,[s.TypeURL.XSD_DAY_TIME_DURATION]:s.TypeURL.XSD_DURATION,[s.TypeURL.XSD_YEAR_MONTH_DURATION]:s.TypeURL.XSD_DURATION,[s.TypeURL.RDF_LANG_STRING]:s.TypeAlias.SPARQL_STRINGLY,[s.TypeURL.XSD_STRING]:s.TypeAlias.SPARQL_STRINGLY,[s.TypeURL.XSD_NORMALIZED_STRING]:s.TypeURL.XSD_STRING,[s.TypeURL.XSD_TOKEN]:s.TypeURL.XSD_NORMALIZED_STRING,[s.TypeURL.XSD_LANGUAGE]:s.TypeURL.XSD_TOKEN,[s.TypeURL.XSD_NM_TOKEN]:s.TypeURL.XSD_TOKEN,[s.TypeURL.XSD_NAME]:s.TypeURL.XSD_TOKEN,[s.TypeURL.XSD_NC_NAME]:s.TypeURL.XSD_NAME,[s.TypeURL.XSD_ENTITY]:s.TypeURL.XSD_NC_NAME,[s.TypeURL.XSD_ID]:s.TypeURL.XSD_NC_NAME,[s.TypeURL.XSD_ID_REF]:s.TypeURL.XSD_NC_NAME,[s.TypeURL.XSD_DOUBLE]:s.TypeAlias.SPARQL_NUMERIC,[s.TypeURL.XSD_FLOAT]:s.TypeAlias.SPARQL_NUMERIC,[s.TypeURL.XSD_DECIMAL]:s.TypeAlias.SPARQL_NUMERIC,[s.TypeURL.XSD_INTEGER]:s.TypeURL.XSD_DECIMAL,[s.TypeURL.XSD_NON_POSITIVE_INTEGER]:s.TypeURL.XSD_INTEGER,[s.TypeURL.XSD_NEGATIVE_INTEGER]:s.TypeURL.XSD_NON_POSITIVE_INTEGER,[s.TypeURL.XSD_LONG]:s.TypeURL.XSD_INTEGER,[s.TypeURL.XSD_INT]:s.TypeURL.XSD_LONG,[s.TypeURL.XSD_SHORT]:s.TypeURL.XSD_INT,[s.TypeURL.XSD_BYTE]:s.TypeURL.XSD_SHORT,[s.TypeURL.XSD_NON_NEGATIVE_INTEGER]:s.TypeURL.XSD_INTEGER,[s.TypeURL.XSD_POSITIVE_INTEGER]:s.TypeURL.XSD_NON_NEGATIVE_INTEGER,[s.TypeURL.XSD_UNSIGNED_LONG]:s.TypeURL.XSD_NON_NEGATIVE_INTEGER,[s.TypeURL.XSD_UNSIGNED_INT]:s.TypeURL.XSD_UNSIGNED_LONG,[s.TypeURL.XSD_UNSIGNED_SHORT]:s.TypeURL.XSD_UNSIGNED_INT,[s.TypeURL.XSD_UNSIGNED_BYTE]:s.TypeURL.XSD_UNSIGNED_SHORT,[s.TypeURL.XSD_DATE_TIME]:"term",[s.TypeURL.XSD_BOOLEAN]:"term",[s.TypeURL.XSD_DATE]:"term",[s.TypeURL.XSD_G_MONTH]:"term",[s.TypeURL.XSD_G_MONTHDAY]:"term",[s.TypeURL.XSD_G_YEAR]:"term",[s.TypeURL.XSD_G_YEAR_MONTH]:"term",[s.TypeURL.XSD_TIME]:"term",[s.TypeURL.XSD_G_DAY]:"term",[s.TypeURL.XSD_DURATION]:"term",[s.TypeAlias.SPARQL_NUMERIC]:"term",[s.TypeAlias.SPARQL_STRINGLY]:"term",[s.TypeURL.XSD_ANY_URI]:"term"},t.superTypeDictTable=Object.create(null);function n(b,m){const g=m.cache.get(b);if(g)return g;const v=m.discoverer(b);if(v==="term"){const S=Object.create(null);return S.__depth=0,S[b]=0,m.cache.set(b,S),S}let _;const w=c(v);return w?_={...t.superTypeDictTable[w]}:_={...n(v,m)},_.__depth++,_[b]=_.__depth,m.cache.set(b,_),_}t.getSuperTypes=n;function r(){for(const[b,m]of Object.entries(t.extensionTableInput)){const g=b;t.superTypeDictTable[g]||a(g,m,t.superTypeDictTable)}}t.extensionTableInit=r,r();function a(b,m,g){if(m==="term"||m===void 0){const v=Object.create(null);v.__depth=0,v[b]=0,g[b]=v;return}g[m]||a(m,t.extensionTableInput[m],g),g[b]={...g[m],[b]:g[m].__depth+1,__depth:g[m].__depth+1}}t.typeAliasCheck=Object.create(null);function o(){for(const b of Object.values(s.TypeAlias))t.typeAliasCheck[b]=!0}o();function l(b){if(b in t.typeAliasCheck)return b}t.asTypeAlias=l;function c(b){if(b in t.superTypeDictTable)return b}t.asKnownLiteralType=c;function d(b){if(c(b)??b==="term")return b}t.asOverrideType=d;function h(b){if(b==="term"||(0,e.asTermType)(b))return b}t.asGeneralType=h;function f(b,m){return b!=="term"&&t.superTypeDictTable[b]&&t.superTypeDictTable[b][m]!==void 0}t.isInternalSubType=f;function p(b,m){const g=c(b);return g?t.superTypeDictTable[g]:n(b,m)}t.getSuperTypeDict=p;function y(b,m,g){return b==="term"?!1:p(b,g)[m]!==void 0}t.isSubTypeOf=y,t.typePromotion={[s.TypeURL.XSD_STRING]:[{typeToPromote:s.TypeURL.XSD_ANY_URI,conversionFunction:b=>(0,u.string)(b.str())}],[s.TypeURL.XSD_DOUBLE]:[{typeToPromote:s.TypeURL.XSD_FLOAT,conversionFunction:b=>(0,u.double)(b.typedValue)},{typeToPromote:s.TypeURL.XSD_DECIMAL,conversionFunction:b=>(0,u.double)(b.typedValue)}],[s.TypeURL.XSD_FLOAT]:[{typeToPromote:s.TypeURL.XSD_DECIMAL,conversionFunction:b=>(0,u.float)(b.typedValue)}]}}(Xw)),Xw}var Z5;function ro(){if(Z5)return Gh;Z5=1,Object.defineProperty(Gh,"__esModule",{value:!0}),Gh.TermTransformer=void 0;const t=er(),e=Ot(),u=Kn(),s=Cn(),n=on(),r=on(),a=y3(),o=y3(),l=Wb();let c=class{constructor(h){this.superTypeProvider=h}transformRDFTermUnsafe(h){return this.transformTerm({term:h,type:e.Algebra.types.EXPRESSION,expressionType:e.Algebra.expressionTypes.TERM})}transformTerm(h){if(!h.term)throw new n.InvalidExpression(h);switch(h.term.termType){case"Variable":return new u.Variable(t.termToString(h.term));case"Literal":return this.transformLiteral(h.term);case"NamedNode":return new u.NamedNode(h.term.value);case"BlankNode":return new u.BlankNode(h.term.value);case"Quad":return new u.Quad(h.term,this.superTypeProvider);default:throw new n.InvalidTermType(h)}}transformLiteral(h){if(!h.datatype||[null,void 0,""].includes(h.datatype.value))return h.language?new u.LangStringLiteral(h.value,h.language):new u.StringLiteral(h.value);const f=h.datatype.value,p=(0,l.getSuperTypeDict)(f,this.superTypeProvider);try{if(s.TypeURL.XSD_STRING in p)return new u.StringLiteral(h.value,f);if(s.TypeURL.RDF_LANG_STRING in p)return new u.LangStringLiteral(h.value,h.language);if(s.TypeURL.XSD_YEAR_MONTH_DURATION in p)return new u.YearMonthDurationLiteral((0,a.parseYearMonthDuration)(h.value),h.value,f);if(s.TypeURL.XSD_DAY_TIME_DURATION in p)return new u.DayTimeDurationLiteral((0,a.parseDayTimeDuration)(h.value),h.value,f);if(s.TypeURL.XSD_DURATION in p)return new u.DurationLiteral((0,a.parseDuration)(h.value),h.value,f);if(s.TypeURL.XSD_DATE_TIME in p){const m=new Date(h.value);return Number.isNaN(m.getTime())?new u.NonLexicalLiteral(void 0,f,this.superTypeProvider,h.value):new u.DateTimeLiteral((0,a.parseDateTime)(h.value),h.value,f)}if(s.TypeURL.XSD_DATE in p)return new u.DateLiteral((0,a.parseDate)(h.value),h.value,f);if(s.TypeURL.XSD_TIME in p)return new u.TimeLiteral((0,a.parseTime)(h.value),h.value,f);if(s.TypeURL.XSD_BOOLEAN in p)return h.value!=="true"&&h.value!=="false"&&h.value!=="1"&&h.value!=="0"?new u.NonLexicalLiteral(void 0,f,this.superTypeProvider,h.value):new u.BooleanLiteral(h.value==="true"||h.value==="1",h.value);if(s.TypeURL.XSD_DECIMAL in p){const m=o.parseXSDDecimal(h.value);return m===void 0?new u.NonLexicalLiteral(void 0,f,this.superTypeProvider,h.value):s.TypeURL.XSD_INTEGER in p?new u.IntegerLiteral(m,f,h.value):new u.DecimalLiteral(m,f,h.value)}const y=s.TypeURL.XSD_FLOAT in p,b=s.TypeURL.XSD_DOUBLE in p;if(y||b){const m=o.parseXSDFloat(h.value);return m===void 0?new u.NonLexicalLiteral(void 0,f,this.superTypeProvider,h.value):y?new u.FloatLiteral(m,f,h.value):new u.DoubleLiteral(m,f,h.value)}return new u.Literal(h.value,f,h.value)}catch(y){if(y instanceof Error&&(0,r.isExpressionError)(y))return new u.NonLexicalLiteral(void 0,f,this.superTypeProvider,h.value);throw y}}};return Gh.TermTransformer=c,Gh}var yi={},ej;function zZ(){if(ej)return yi;ej=1,Object.defineProperty(yi,"__esModule",{value:!0}),yi.serializeDuration=yi.serializeTime=yi.serializeDate=yi.serializeDateTime=void 0;function t(a,o=2){return a.toLocaleString(void 0,{minimumIntegerDigits:o,useGrouping:!1})}function e(a){return`${s({year:a.year,month:a.month,day:a.day})}T${n(a)}`}yi.serializeDateTime=e;function u(a){return a.zoneHours===void 0||a.zoneMinutes===void 0?"":a.zoneHours===0&&a.zoneMinutes===0?"Z":`${a.zoneHours>=0?`+${t(a.zoneHours)}`:t(a.zoneHours)}:${t(Math.abs(a.zoneMinutes))}`}function s(a){return`${t(a.year,4)}-${t(a.month)}-${t(a.day)}${u(a)}`}yi.serializeDate=s;function n(a){return`${t(a.hours)}:${t(a.minutes)}:${t(a.seconds)}${u(a)}`}yi.serializeTime=n;function r(a,o="PT0S"){if(!Object.values(a).some(m=>(m||0)!==0))return o;const l=Object.values(a).some(m=>(m||0)<0)?"-":"",c=a.year?`${Math.abs(a.year)}Y`:"",d=a.month?`${Math.abs(a.month)}M`:"",h=a.day?`${Math.abs(a.day)}D`:"",f=`${l}P${c}${d}${h}`;if(!(a.hours||a.minutes||a.seconds))return f;const p=a.hours?`${Math.abs(a.hours)}H`:"",y=a.minutes?`${Math.abs(a.minutes)}M`:"",b=a.seconds?`${Math.abs(a.seconds)}S`:"";return`${f}T${p}${y}${b}`}return yi.serializeDuration=r,yi}var tj;function GZ(){if(tj)return At;tj=1,Object.defineProperty(At,"__esModule",{value:!0}),At.isNonLexicalLiteral=At.NonLexicalLiteral=At.YearMonthDurationLiteral=At.DayTimeDurationLiteral=At.DurationLiteral=At.DateLiteral=At.TimeLiteral=At.DateTimeLiteral=At.StringLiteral=At.LangStringLiteral=At.BooleanLiteral=At.DoubleLiteral=At.FloatLiteral=At.DecimalLiteral=At.IntegerLiteral=At.NumericLiteral=At.Literal=At.isLiteralTermExpression=At.Quad=At.BlankNode=At.NamedNode=At.Term=void 0;const t=Et(),e=ro(),u=Cn(),s=Cn(),n=on(),r=zZ(),a=Wb(),o=Ki(),l=new t.DataFactory;let c=class{constructor(){this.expressionType=o.ExpressionType.Term}str(){throw new n.InvalidArgumentTypes([this],u.RegularOperator.STR)}coerceEBV(){throw new n.EBVCoercionError(this)}};At.Term=c;class d extends c{constructor(Q){super(),this.value=Q,this.termType="namedNode"}toRDF(){return l.namedNode(this.value)}str(){return this.value}}At.NamedNode=d;class h extends c{constructor(Q){super(),this.termType="blankNode",this.value=typeof Q=="string"?l.blankNode(Q):Q}toRDF(){return this.value}}At.BlankNode=h;class f extends c{constructor(Q,Z){super(),this.termType="quad",this.transformer=new e.TermTransformer(Z),this.valueTerm=Q}toRDF(){return this.valueTerm}get subject(){return this.transformer.transformRDFTermUnsafe(this.RDFsubject)}get predicate(){return this.transformer.transformRDFTermUnsafe(this.RDFpredicate)}get object(){return this.transformer.transformRDFTermUnsafe(this.RDFobject)}get RDFsubject(){return this.toRDF().subject}get RDFpredicate(){return this.toRDF().predicate}get RDFobject(){return this.toRDF().object}}At.Quad=f;function p(q){if(q.termType==="literal")return q}At.isLiteralTermExpression=p;class y extends c{constructor(Q,Z,K,fe){super(),this.typedValue=Q,this.dataType=Z,this.strValue=K,this.language=fe,this.termType="literal"}toRDF(){return l.literal(this.strValue??this.str(),this.language??l.namedNode(this.dataType))}str(){return this.strValue??this.typedValue.toString()}}At.Literal=y;class b extends y{constructor(Q,Z,K,fe){super(Q,Z,K,fe),this.typedValue=Q,this.strValue=K,this.language=fe}coerceEBV(){return!!this.typedValue}toRDF(){const Q=super.toRDF();return Number.isFinite(this.typedValue)||(Q.value=Q.value.replace("Infinity","INF")),Q}str(){return this.strValue??this.specificFormatter(this.typedValue)}}At.NumericLiteral=b;class m extends b{constructor(Q,Z,K,fe){super(Q,Z??s.TypeURL.XSD_INTEGER,K,fe),this.typedValue=Q,this.strValue=K,this.language=fe}specificFormatter(Q){return Q.toFixed(0)}}At.IntegerLiteral=m;class g extends b{constructor(Q,Z,K,fe){super(Q,Z??s.TypeURL.XSD_DECIMAL,K,fe),this.typedValue=Q,this.strValue=K,this.language=fe}specificFormatter(Q){return Q.toString()}}At.DecimalLiteral=g;class v extends b{constructor(Q,Z,K,fe){super(Q,Z??s.TypeURL.XSD_FLOAT,K,fe),this.typedValue=Q,this.strValue=K,this.language=fe}specificFormatter(Q){return Q.toString()}}At.FloatLiteral=v;class _ extends b{constructor(Q,Z,K,fe){super(Q,Z??s.TypeURL.XSD_DOUBLE,K,fe),this.typedValue=Q,this.strValue=K,this.language=fe}specificFormatter(Q){if(!Number.isFinite(Q))return Q>0?"INF":Q<0?"-INF":"NaN";const Z=Q.toExponential(),[K,fe]=Z.split("e"),X=fe.replace(/\+/u,"");return`${K.includes(".")?K:`${K}.0`}E${X}`}}At.DoubleLiteral=_;class w extends y{constructor(Q,Z,K){super(Q,K??s.TypeURL.XSD_BOOLEAN,Z),this.typedValue=Q,this.strValue=Z}coerceEBV(){return this.typedValue}}At.BooleanLiteral=w;class S extends y{constructor(Q,Z,K){super(Q,K??s.TypeURL.RDF_LANG_STRING,Q,Z),this.typedValue=Q,this.language=Z}coerceEBV(){return this.str().length>0}}At.LangStringLiteral=S;class A extends y{constructor(Q,Z){super(Q,Z??s.TypeURL.XSD_STRING,Q),this.typedValue=Q}coerceEBV(){return this.str().length>0}}At.StringLiteral=A;class D extends y{constructor(Q,Z,K){super(Q,K??s.TypeURL.XSD_DATE_TIME,Z),this.typedValue=Q,this.strValue=Z}str(){return(0,r.serializeDateTime)(this.typedValue)}}At.DateTimeLiteral=D;class L extends y{constructor(Q,Z,K){super(Q,K??s.TypeURL.XSD_TIME,Z),this.typedValue=Q,this.strValue=Z}str(){return(0,r.serializeTime)(this.typedValue)}}At.TimeLiteral=L;class E extends y{constructor(Q,Z,K){super(Q,K??s.TypeURL.XSD_DATE,Z),this.typedValue=Q,this.strValue=Z}str(){return(0,r.serializeDate)(this.typedValue)}}At.DateLiteral=E;class O extends y{constructor(Q,Z,K){super(Q,K??s.TypeURL.XSD_DURATION,Z),this.typedValue=Q,this.strValue=Z}str(){return(0,r.serializeDuration)(this.typedValue)}}At.DurationLiteral=O;class P extends O{constructor(Q,Z,K){super(Q,Z,K??s.TypeURL.XSD_DAY_TIME_DURATION),this.typedValue=Q,this.strValue=Z}}At.DayTimeDurationLiteral=P;class j extends y{constructor(Q,Z,K){super(Q,K??s.TypeURL.XSD_YEAR_MONTH_DURATION,Z),this.typedValue=Q,this.strValue=Z}str(){return(0,r.serializeDuration)(this.typedValue,"P0M")}}At.YearMonthDurationLiteral=j;class U extends y{constructor(Q,Z,K,fe,X){super({toString:()=>"undefined"},Z,fe,X),this.openWorldType=K}coerceEBV(){if((0,a.isSubTypeOf)(this.dataType,s.TypeURL.XSD_BOOLEAN,this.openWorldType)||(0,a.isSubTypeOf)(this.dataType,s.TypeAlias.SPARQL_NUMERIC,this.openWorldType))return!1;throw new n.EBVCoercionError(this)}toRDF(){return l.literal(this.str(),this.language??l.namedNode(this.dataType))}str(){return this.strValue??""}}At.NonLexicalLiteral=U;function M(q){if(q instanceof U)return q}return At.isNonLexicalLiteral=M,At}var Jh={},rj;function WZ(){if(rj)return Jh;rj=1,Object.defineProperty(Jh,"__esModule",{value:!0}),Jh.Operator=void 0;const t=Ki();let e=class{constructor(s,n){this.args=s,this.apply=n,this.expressionType=t.ExpressionType.Operator}};return Jh.Operator=e,Jh}var Xh={},nj;function JZ(){if(nj)return Xh;nj=1,Object.defineProperty(Xh,"__esModule",{value:!0}),Xh.SpecialOperator=void 0;const t=Ki();let e=class{constructor(s,n,r){this.args=s,this.applyAsync=n,this.applySynchronously=r,this.expressionType=t.ExpressionType.SpecialOperator}};return Xh.SpecialOperator=e,Xh}var Kh={},ij;function XZ(){if(ij)return Kh;ij=1,Object.defineProperty(Kh,"__esModule",{value:!0}),Kh.Named=void 0;const t=Ki();let e=class{constructor(s,n,r){this.name=s,this.args=n,this.apply=r,this.expressionType=t.ExpressionType.Named}};return Kh.Named=e,Kh}var Yh={},aj;function KZ(){if(aj)return Yh;aj=1,Object.defineProperty(Yh,"__esModule",{value:!0}),Yh.Aggregate=void 0;const t=Ki();let e=class{constructor(s,n){this.name=s,this.expression=n,this.expressionType=t.ExpressionType.Aggregate}};return Yh.Aggregate=e,Yh}var Zh={},sj;function YZ(){if(sj)return Zh;sj=1,Object.defineProperty(Zh,"__esModule",{value:!0}),Zh.Existence=void 0;const t=Ki();let e=class{constructor(s){this.expression=s,this.expressionType=t.ExpressionType.Existence}};return Zh.Existence=e,Zh}var ep={},oj;function ZZ(){if(oj)return ep;oj=1,Object.defineProperty(ep,"__esModule",{value:!0}),ep.AsyncExtension=void 0;const t=Ki();let e=class{constructor(s,n,r){this.name=s,this.args=n,this.apply=r,this.expressionType=t.ExpressionType.AsyncExtension}};return ep.AsyncExtension=e,ep}var tp={},uj;function eee(){if(uj)return tp;uj=1,Object.defineProperty(tp,"__esModule",{value:!0}),tp.SyncExtension=void 0;const t=Ki();let e=class{constructor(s,n,r){this.name=s,this.args=n,this.apply=r,this.expressionType=t.ExpressionType.SyncExtension}};return tp.SyncExtension=e,tp}var cj;function Kn(){return cj||(cj=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Ki(),t),u(kZ(),t),u(GZ(),t),u(WZ(),t),u(JZ(),t),u(XZ(),t),u(KZ(),t),u(YZ(),t),u(ZZ(),t),u(eee(),t)}(Ww)),Ww}var Kw={},bi={},lj;function g3(){if(lj)return bi;lj=1,Object.defineProperty(bi,"__esModule",{value:!0}),bi.SpecialFunction=bi.NamedFunction=bi.RegularFunction=bi.BaseFunction=void 0;const t=on();class e{constructor(o,l){this.operator=o,this.apply=(c,d)=>(this.monomorph(c,d.superTypeProvider,d.functionArgumentsCache)??this.handleInvalidTypes(c))(d)(c),this.arity=l.arity,this.overloads=l.overloads}monomorph(o,l,c){return this.overloads.search(o,l,c)}}bi.BaseFunction=e;class u extends e{constructor(o,l){super(o,l),this.functionClass="regular"}handleInvalidTypes(o){throw new t.InvalidArgumentTypes(o,this.operator)}}bi.RegularFunction=u;class s extends e{constructor(o,l){super(o,l),this.functionClass="named"}handleInvalidTypes(o){throw new t.InvalidArgumentTypes(o,this.operator)}}bi.NamedFunction=s;class n{constructor(o,l){this.operator=o,this.functionClass="special",this.arity=l.arity,this.applySynchronously=l.applySynchronously,this.applyAsync=l.applyAsync,this.checkArity=l.checkArity??r(this.arity)}}bi.SpecialFunction=n;function r(a){return o=>a===Number.POSITIVE_INFINITY?!0:o.length===a}return bi}var rp={},dj;function tee(){if(dj)return rp;dj=1,Object.defineProperty(rp,"__esModule",{value:!0}),rp.namedDefinitions=void 0;const t=Kn(),e=Kn(),u=Cn(),s=ou(),n=on(),r=y3(),a=Yi(),o={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_STRING).onNumeric1(()=>_=>(0,a.string)((0,a.float)(_.typedValue).str())).onBoolean1Typed(()=>_=>(0,a.string)((0,a.bool)(_).str())).onTerm1(()=>_=>(0,a.string)(_.str())).collect()},l={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_FLOAT).onNumeric1(()=>_=>(0,a.float)(_.typedValue)).onBoolean1Typed(()=>_=>(0,a.float)(_?1:0)).onUnary(u.TypeURL.XSD_STRING,()=>_=>{const w=(0,r.parseXSDFloat)(_.str());if(w===void 0)throw new n.CastError(_,u.TypeURL.XSD_FLOAT);return(0,a.float)(w)},!1).collect()},c={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_DOUBLE).onNumeric1(()=>_=>(0,a.double)(_.typedValue)).onBoolean1Typed(()=>_=>(0,a.double)(_?1:0)).onUnary(u.TypeURL.XSD_STRING,()=>_=>{const w=(0,r.parseXSDFloat)(_.str());if(w===void 0)throw new n.CastError(_,u.TypeURL.XSD_DOUBLE);return(0,a.double)(w)},!1).collect()},d={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_DECIMAL).onNumeric1(()=>_=>{const w=(0,r.parseXSDDecimal)(_.str());if(w===void 0)throw new n.CastError(_,u.TypeURL.XSD_DECIMAL);return(0,a.decimal)(w)}).onString1(()=>_=>{const w=_.str(),S=/^([+-])?(\d+(\.\d+)?)$/u.test(w)?(0,r.parseXSDDecimal)(w):void 0;if(S===void 0)throw new n.CastError(_,u.TypeURL.XSD_DECIMAL);return(0,a.decimal)(S)},!1).onBoolean1Typed(()=>_=>(0,a.decimal)(_?1:0)).collect()},h={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_INTEGER).onBoolean1Typed(()=>_=>(0,a.integer)(_?1:0)).onNumeric1(()=>_=>{const w=(0,r.parseXSDInteger)(_.str());if(w===void 0)throw new n.CastError(_,u.TypeURL.XSD_INTEGER);return(0,a.integer)(w)},!1).onString1(()=>_=>{const w=_.str(),S=/^\d+$/u.test(w)?(0,r.parseXSDInteger)(w):void 0;if(S===void 0)throw new n.CastError(_,u.TypeURL.XSD_INTEGER);return(0,a.integer)(S)}).collect()},f={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_DATE_TIME).onUnary(u.TypeURL.XSD_DATE_TIME,()=>_=>_).onUnary(u.TypeURL.XSD_STRING,()=>_=>(0,a.dateTime)((0,r.parseDateTime)(_.str()),_.str()),!1).onUnary(u.TypeURL.XSD_DATE,()=>_=>new t.DateTimeLiteral({..._.typedValue,hours:0,minutes:0,seconds:0})).collect()},p={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_BOOLEAN).onNumeric1(()=>_=>(0,a.bool)(_.coerceEBV()),!0).onUnary(u.TypeURL.XSD_BOOLEAN,()=>_=>(0,a.bool)(_.coerceEBV()),!0).onUnary(u.TypeURL.XSD_STRING,()=>_=>{switch(_.str()){case"true":return(0,a.bool)(!0);case"false":return(0,a.bool)(!1);case"1":return(0,a.bool)(!0);case"0":return(0,a.bool)(!1);default:throw new n.CastError(_,u.TypeURL.XSD_BOOLEAN)}},!1).collect()},y={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_TIME).onUnary(u.TypeURL.XSD_TIME,()=>_=>new t.TimeLiteral(_.typedValue,_.strValue)).onUnary(u.TypeURL.XSD_DATE_TIME,()=>_=>new t.TimeLiteral(_.typedValue)).onStringly1(()=>_=>new t.TimeLiteral((0,r.parseTime)(_.str()))).collect()},b={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_DATE).onUnary(u.TypeURL.XSD_DATE,()=>_=>new t.DateLiteral(_.typedValue,_.strValue)).onUnary(u.TypeURL.XSD_DATE_TIME,()=>_=>new t.DateLiteral(_.typedValue)).onStringly1(()=>_=>new t.DateLiteral((0,r.parseDate)(_.str()))).collect()},m={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_DURATION).onUnary(u.TypeURL.XSD_DURATION,()=>_=>new t.DurationLiteral(_.typedValue,_.strValue)).onStringly1(()=>_=>new e.DurationLiteral((0,r.parseDuration)(_.str()))).collect()},g={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_DAY_TIME_DURATION).onUnary(u.TypeURL.XSD_DURATION,()=>_=>new t.DayTimeDurationLiteral((0,s.trimToDayTimeDuration)(_.typedValue))).onStringly1(()=>_=>new t.DayTimeDurationLiteral((0,r.parseDayTimeDuration)(_.str()))).collect()},v={arity:1,overloads:(0,a.declare)(u.TypeURL.XSD_YEAR_MONTH_DURATION).onUnary(u.TypeURL.XSD_DURATION,()=>_=>new t.YearMonthDurationLiteral((0,s.trimToYearMonthDuration)(_.typedValue))).onStringly1(()=>_=>new t.YearMonthDurationLiteral((0,r.parseYearMonthDuration)(_.str()))).collect()};return rp.namedDefinitions={[u.TypeURL.XSD_STRING]:o,[u.TypeURL.XSD_FLOAT]:l,[u.TypeURL.XSD_DOUBLE]:c,[u.TypeURL.XSD_DECIMAL]:d,[u.TypeURL.XSD_INTEGER]:h,[u.TypeURL.XSD_DATE_TIME]:f,[u.TypeURL.XSD_DATE]:b,[u.TypeURL.XSD_BOOLEAN]:p,[u.TypeURL.XSD_TIME]:y,[u.TypeURL.XSD_DURATION]:m,[u.TypeURL.XSD_DAY_TIME_DURATION]:g,[u.TypeURL.XSD_YEAR_MONTH_DURATION]:v},rp}var np={},Yw={exports:{}},fj;function ree(){return fj||(fj=1,function(t){(function(e){var u,s=/^-?(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?$/i,n=Math.ceil,r=Math.floor,a="[BigNumber Error] ",o=a+"Number primitive has more than 15 significant digits: ",l=1e14,c=14,d=9007199254740991,h=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],f=1e7,p=1e9;function y(A){var D,L,E,O=ae.prototype={constructor:ae,toString:null,valueOf:null},P=new ae(1),j=20,U=4,M=-7,q=21,Q=-1e7,Z=1e7,K=!1,fe=1,X=0,he={prefix:"",groupSize:3,secondaryGroupSize:0,groupSeparator:",",decimalSeparator:".",fractionGroupSize:0,fractionGroupSeparator:" ",suffix:""},xe="0123456789abcdefghijklmnopqrstuvwxyz",ie=!0;function ae($,N){var R,T,x,B,k,V,J,z,Y=this;if(!(Y instanceof ae))return new ae($,N);if(N==null){if($&&$._isBigNumber===!0){Y.s=$.s,!$.c||$.e>Z?Y.c=Y.e=null:$.e=10;k/=10,B++);B>Z?Y.c=Y.e=null:(Y.e=B,Y.c=[$]);return}z=String($)}else{if(!s.test(z=String($)))return E(Y,z,V);Y.s=z.charCodeAt(0)==45?(z=z.slice(1),-1):1}(B=z.indexOf("."))>-1&&(z=z.replace(".","")),(k=z.search(/e/i))>0?(B<0&&(B=k),B+=+z.slice(k+1),z=z.substring(0,k)):B<0&&(B=z.length)}else{if(v(N,2,xe.length,"Base"),N==10&&ie)return Y=new ae($),de(Y,j+Y.e+1,U);if(z=String($),V=typeof $=="number"){if($*0!=0)return E(Y,z,V,N);if(Y.s=1/$<0?(z=z.slice(1),-1):1,ae.DEBUG&&z.replace(/^0\.0*|\./,"").length>15)throw Error(o+$)}else Y.s=z.charCodeAt(0)===45?(z=z.slice(1),-1):1;for(R=xe.slice(0,N),B=k=0,J=z.length;kB){B=J;continue}}else if(!x&&(z==z.toUpperCase()&&(z=z.toLowerCase())||z==z.toLowerCase()&&(z=z.toUpperCase()))){x=!0,k=-1,B=0;continue}return E(Y,String($),V,N)}V=!1,z=L(z,N,10,Y.s),(B=z.indexOf("."))>-1?z=z.replace(".",""):B=z.length}for(k=0;z.charCodeAt(k)===48;k++);for(J=z.length;z.charCodeAt(--J)===48;);if(z=z.slice(k,++J)){if(J-=k,V&&ae.DEBUG&&J>15&&($>d||$!==r($)))throw Error(o+Y.s*$);if((B=B-k-1)>Z)Y.c=Y.e=null;else if(B=-p&&x<=p&&x===r(x)){if(T[0]===0){if(x===0&&T.length===1)return!0;break e}if(N=(x+1)%c,N<1&&(N+=c),String(T[0]).length==N){for(N=0;N=l||R!==r(R))break e;if(R!==0)return!0}}}else if(T===null&&x===null&&(B===null||B===1||B===-1))return!0;throw Error(a+"Invalid BigNumber: "+$)},ae.maximum=ae.max=function(){return Ne(arguments,-1)},ae.minimum=ae.min=function(){return Ne(arguments,1)},ae.random=function(){var $=9007199254740992,N=Math.random()*$&2097151?function(){return r(Math.random()*$)}:function(){return(Math.random()*1073741824|0)*8388608+(Math.random()*8388608|0)};return function(R){var T,x,B,k,V,J=0,z=[],Y=new ae(P);if(R==null?R=j:v(R,0,p),k=n(R/c),K)if(crypto.getRandomValues){for(T=crypto.getRandomValues(new Uint32Array(k*=2));J>>11),V>=9e15?(x=crypto.getRandomValues(new Uint32Array(2)),T[J]=x[0],T[J+1]=x[1]):(z.push(V%1e14),J+=2);J=k/2}else if(crypto.randomBytes){for(T=crypto.randomBytes(k*=7);J=9e15?crypto.randomBytes(7).copy(T,J):(z.push(V%1e14),J+=7);J=k/7}else throw K=!1,Error(a+"crypto unavailable");if(!K)for(;J=10;V/=10,J++);Jx-1&&(V[k+1]==null&&(V[k+1]=0),V[k+1]+=V[k]/x|0,V[k]%=x)}return V.reverse()}return function(R,T,x,B,k){var V,J,z,Y,te,ce,Ae,Ie,Ee=R.indexOf("."),qe=j,G=U;for(Ee>=0&&(Y=X,X=0,R=R.replace(".",""),Ie=new ae(T),ce=Ie.pow(R.length-Ee),X=Y,Ie.c=N(S(m(ce.c),ce.e,"0"),10,x,$),Ie.e=Ie.c.length),Ae=N(R,T,x,k?(V=xe,$):(V=$,xe)),z=Y=Ae.length;Ae[--Y]==0;Ae.pop());if(!Ae[0])return V.charAt(0);if(Ee<0?--z:(ce.c=Ae,ce.e=z,ce.s=B,ce=D(ce,Ie,qe,G,x),Ae=ce.c,te=ce.r,z=ce.e),J=z+qe+1,Ee=Ae[J],Y=x/2,te=te||J<0||Ae[J+1]!=null,te=G<4?(Ee!=null||te)&&(G==0||G==(ce.s<0?3:2)):Ee>Y||Ee==Y&&(G==4||te||G==6&&Ae[J-1]&1||G==(ce.s<0?8:7)),J<1||!Ae[0])R=te?S(V.charAt(1),-qe,V.charAt(0)):V.charAt(0);else{if(Ae.length=J,te)for(--x;++Ae[--J]>x;)Ae[J]=0,J||(++z,Ae=[1].concat(Ae));for(Y=Ae.length;!Ae[--Y];);for(Ee=0,R="";Ee<=Y;R+=V.charAt(Ae[Ee++]));R=S(R,z,V.charAt(0))}return R}}(),D=function(){function $(T,x,B){var k,V,J,z,Y=0,te=T.length,ce=x%f,Ae=x/f|0;for(T=T.slice();te--;)J=T[te]%f,z=T[te]/f|0,k=Ae*J+z*ce,V=ce*J+k%f*f+Y,Y=(V/B|0)+(k/f|0)+Ae*z,T[te]=V%B;return Y&&(T=[Y].concat(T)),T}function N(T,x,B,k){var V,J;if(B!=k)J=B>k?1:-1;else for(V=J=0;Vx[V]?1:-1;break}return J}function R(T,x,B,k){for(var V=0;B--;)T[B]-=V,V=T[B]1;T.splice(0,1));}return function(T,x,B,k,V){var J,z,Y,te,ce,Ae,Ie,Ee,qe,G,F,H,re,be,Re,Ce,Qe,ke=T.s==x.s?1:-1,me=T.c,Se=x.c;if(!me||!me[0]||!Se||!Se[0])return new ae(!T.s||!x.s||(me?Se&&me[0]==Se[0]:!Se)?NaN:me&&me[0]==0||!Se?ke*0:ke/0);for(Ee=new ae(ke),qe=Ee.c=[],z=T.e-x.e,ke=B+z+1,V||(V=l,z=b(T.e/c)-b(x.e/c),ke=ke/c|0),Y=0;Se[Y]==(me[Y]||0);Y++);if(Se[Y]>(me[Y]||0)&&z--,ke<0)qe.push(1),te=!0;else{for(be=me.length,Ce=Se.length,Y=0,ke+=2,ce=r(V/(Se[0]+1)),ce>1&&(Se=$(Se,ce,V),me=$(me,ce,V),Ce=Se.length,be=me.length),re=Ce,G=me.slice(0,Ce),F=G.length;F=V/2&&Re++;do{if(ce=0,J=N(Se,G,Ce,F),J<0){if(H=G[0],Ce!=F&&(H=H*V+(G[1]||0)),ce=r(H/Re),ce>1)for(ce>=V&&(ce=V-1),Ae=$(Se,ce,V),Ie=Ae.length,F=G.length;N(Ae,G,Ie,F)==1;)ce--,R(Ae,Ce=10;ke/=10,Y++);de(Ee,B+(Ee.e=Y+z*c-1)+1,k,te)}else Ee.e=z,Ee.r=+te;return Ee}}();function Oe($,N,R,T){var x,B,k,V,J;if(R==null?R=U:v(R,0,8),!$.c)return $.toString();if(x=$.c[0],k=$.e,N==null)J=m($.c),J=T==1||T==2&&(k<=M||k>=q)?w(J,k):S(J,k,"0");else if($=de(new ae($),N,R),B=$.e,J=m($.c),V=J.length,T==1||T==2&&(N<=B||B<=M)){for(;VV){if(--N>0)for(J+=".";N--;J+="0");}else if(N+=B-V,N>0)for(B+1==V&&(J+=".");N--;J+="0");return $.s<0&&x?"-"+J:J}function Ne($,N){for(var R,T,x=1,B=new ae($[0]);x<$.length;x++)T=new ae($[x]),(!T.s||(R=g(B,T))===N||R===0&&B.s===N)&&(B=T);return B}function ge($,N,R){for(var T=1,x=N.length;!N[--x];N.pop());for(x=N[0];x>=10;x/=10,T++);return(R=T+R*c-1)>Z?$.c=$.e=null:R=10;V/=10,x++);if(B=N-x,B<0)B+=c,k=N,J=te[z=0],Y=r(J/ce[x-k-1]%10);else if(z=n((B+1)/c),z>=te.length)if(T){for(;te.length<=z;te.push(0));J=Y=0,x=1,B%=c,k=B-c+1}else break e;else{for(J=V=te[z],x=1;V>=10;V/=10,x++);B%=c,k=B-c+x,Y=k<0?0:r(J/ce[x-k-1]%10)}if(T=T||N<0||te[z+1]!=null||(k<0?J:J%ce[x-k-1]),T=R<4?(Y||T)&&(R==0||R==($.s<0?3:2)):Y>5||Y==5&&(R==4||T||R==6&&(B>0?k>0?J/ce[x-k]:0:te[z-1])%10&1||R==($.s<0?8:7)),N<1||!te[0])return te.length=0,T?(N-=$.e+1,te[0]=ce[(c-N%c)%c],$.e=-N||0):te[0]=$.e=0,$;if(B==0?(te.length=z,V=1,z--):(te.length=z+1,V=ce[c-B],te[z]=k>0?r(J/ce[x-k]%ce[k])*V:0),T)for(;;)if(z==0){for(B=1,k=te[0];k>=10;k/=10,B++);for(k=te[0]+=V,V=1;k>=10;k/=10,V++);B!=V&&($.e++,te[0]==l&&(te[0]=1));break}else{if(te[z]+=V,te[z]!=l)break;te[z--]=0,V=1}for(B=te.length;te[--B]===0;te.pop());}$.e>Z?$.c=$.e=null:$.e=q?w(N,R):S(N,R,"0"),$.s<0?"-"+N:N)}return O.absoluteValue=O.abs=function(){var $=new ae(this);return $.s<0&&($.s=1),$},O.comparedTo=function($,N){return g(this,new ae($,N))},O.decimalPlaces=O.dp=function($,N){var R,T,x,B=this;if($!=null)return v($,0,p),N==null?N=U:v(N,0,8),de(new ae(B),$+B.e+1,N);if(!(R=B.c))return null;if(T=((x=R.length-1)-b(this.e/c))*c,x=R[x])for(;x%10==0;x/=10,T--);return T<0&&(T=0),T},O.dividedBy=O.div=function($,N){return D(this,new ae($,N),j,U)},O.dividedToIntegerBy=O.idiv=function($,N){return D(this,new ae($,N),0,1)},O.exponentiatedBy=O.pow=function($,N){var R,T,x,B,k,V,J,z,Y,te=this;if($=new ae($),$.c&&!$.isInteger())throw Error(a+"Exponent not an integer: "+oe($));if(N!=null&&(N=new ae(N)),V=$.e>14,!te.c||!te.c[0]||te.c[0]==1&&!te.e&&te.c.length==1||!$.c||!$.c[0])return Y=new ae(Math.pow(+oe(te),V?$.s*(2-_($)):+oe($))),N?Y.mod(N):Y;if(J=$.s<0,N){if(N.c?!N.c[0]:!N.s)return new ae(NaN);T=!J&&te.isInteger()&&N.isInteger(),T&&(te=te.mod(N))}else{if($.e>9&&(te.e>0||te.e<-1||(te.e==0?te.c[0]>1||V&&te.c[1]>=24e7:te.c[0]<8e13||V&&te.c[0]<=9999975e7)))return B=te.s<0&&_($)?-0:0,te.e>-1&&(B=1/B),new ae(J?1/B:B);X&&(B=n(X/c+2))}for(V?(R=new ae(.5),J&&($.s=1),z=_($)):(x=Math.abs(+oe($)),z=x%2),Y=new ae(P);;){if(z){if(Y=Y.times(te),!Y.c)break;B?Y.c.length>B&&(Y.c.length=B):T&&(Y=Y.mod(N))}if(x){if(x=r(x/2),x===0)break;z=x%2}else if($=$.times(R),de($,$.e+1,1),$.e>14)z=_($);else{if(x=+oe($),x===0)break;z=x%2}te=te.times(te),B?te.c&&te.c.length>B&&(te.c.length=B):T&&(te=te.mod(N))}return T?Y:(J&&(Y=P.div(Y)),N?Y.mod(N):B?de(Y,X,U,k):Y)},O.integerValue=function($){var N=new ae(this);return $==null?$=U:v($,0,8),de(N,N.e+1,$)},O.isEqualTo=O.eq=function($,N){return g(this,new ae($,N))===0},O.isFinite=function(){return!!this.c},O.isGreaterThan=O.gt=function($,N){return g(this,new ae($,N))>0},O.isGreaterThanOrEqualTo=O.gte=function($,N){return(N=g(this,new ae($,N)))===1||N===0},O.isInteger=function(){return!!this.c&&b(this.e/c)>this.c.length-2},O.isLessThan=O.lt=function($,N){return g(this,new ae($,N))<0},O.isLessThanOrEqualTo=O.lte=function($,N){return(N=g(this,new ae($,N)))===-1||N===0},O.isNaN=function(){return!this.s},O.isNegative=function(){return this.s<0},O.isPositive=function(){return this.s>0},O.isZero=function(){return!!this.c&&this.c[0]==0},O.minus=function($,N){var R,T,x,B,k=this,V=k.s;if($=new ae($,N),N=$.s,!V||!N)return new ae(NaN);if(V!=N)return $.s=-N,k.plus($);var J=k.e/c,z=$.e/c,Y=k.c,te=$.c;if(!J||!z){if(!Y||!te)return Y?($.s=-N,$):new ae(te?k:NaN);if(!Y[0]||!te[0])return te[0]?($.s=-N,$):new ae(Y[0]?k:U==3?-0:0)}if(J=b(J),z=b(z),Y=Y.slice(),V=J-z){for((B=V<0)?(V=-V,x=Y):(z=J,x=te),x.reverse(),N=V;N--;x.push(0));x.reverse()}else for(T=(B=(V=Y.length)<(N=te.length))?V:N,V=N=0;N0)for(;N--;Y[R++]=0);for(N=l-1;T>V;){if(Y[--T]=0;){for(R=0,ce=H[x]%qe,Ae=H[x]/qe|0,k=J,B=x+k;B>x;)z=F[--k]%qe,Y=F[k]/qe|0,V=Ae*z+Y*ce,z=ce*z+V%qe*qe+Ie[B]+R,R=(z/Ee|0)+(V/qe|0)+Ae*Y,Ie[B--]=z%Ee;Ie[B]=R}return R?++T:Ie.splice(0,1),ge($,Ie,T)},O.negated=function(){var $=new ae(this);return $.s=-$.s||null,$},O.plus=function($,N){var R,T=this,x=T.s;if($=new ae($,N),N=$.s,!x||!N)return new ae(NaN);if(x!=N)return $.s=-N,T.minus($);var B=T.e/c,k=$.e/c,V=T.c,J=$.c;if(!B||!k){if(!V||!J)return new ae(x/0);if(!V[0]||!J[0])return J[0]?$:new ae(V[0]?T:x*0)}if(B=b(B),k=b(k),V=V.slice(),x=B-k){for(x>0?(k=B,R=J):(x=-x,R=V),R.reverse();x--;R.push(0));R.reverse()}for(x=V.length,N=J.length,x-N<0&&(R=J,J=V,V=R,N=x),x=0;N;)x=(V[--N]=V[N]+J[N]+x)/l|0,V[N]=l===V[N]?0:V[N]%l;return x&&(V=[x].concat(V),++k),ge($,V,k)},O.precision=O.sd=function($,N){var R,T,x,B=this;if($!=null&&$!==!!$)return v($,1,p),N==null?N=U:v(N,0,8),de(new ae(B),$,N);if(!(R=B.c))return null;if(x=R.length-1,T=x*c+1,x=R[x]){for(;x%10==0;x/=10,T--);for(x=R[0];x>=10;x/=10,T++);}return $&&B.e+1>T&&(T=B.e+1),T},O.shiftedBy=function($){return v($,-d,d),this.times("1e"+$)},O.squareRoot=O.sqrt=function(){var $,N,R,T,x,B=this,k=B.c,V=B.s,J=B.e,z=j+4,Y=new ae("0.5");if(V!==1||!k||!k[0])return new ae(!V||V<0&&(!k||k[0])?NaN:k?B:1/0);if(V=Math.sqrt(+oe(B)),V==0||V==1/0?(N=m(k),(N.length+J)%2==0&&(N+="0"),V=Math.sqrt(+N),J=b((J+1)/2)-(J<0||J%2),V==1/0?N="5e"+J:(N=V.toExponential(),N=N.slice(0,N.indexOf("e")+1)+J),R=new ae(N)):R=new ae(V+""),R.c[0]){for(J=R.e,V=J+z,V<3&&(V=0);;)if(x=R,R=Y.times(x.plus(D(B,x,z,1))),m(x.c).slice(0,V)===(N=m(R.c)).slice(0,V))if(R.e0&&Ie>0){for(B=Ie%V||V,Y=Ae.substr(0,B);B0&&(Y+=z+Ae.slice(B)),ce&&(Y="-"+Y)}T=te?Y+(R.decimalSeparator||"")+((J=+R.fractionGroupSize)?te.replace(new RegExp("\\d{"+J+"}\\B","g"),"$&"+(R.fractionGroupSeparator||"")):te):Y}return(R.prefix||"")+T+(R.suffix||"")},O.toFraction=function($){var N,R,T,x,B,k,V,J,z,Y,te,ce,Ae=this,Ie=Ae.c;if($!=null&&(V=new ae($),!V.isInteger()&&(V.c||V.s!==1)||V.lt(P)))throw Error(a+"Argument "+(V.isInteger()?"out of range: ":"not an integer: ")+oe(V));if(!Ie)return new ae(Ae);for(N=new ae(P),z=R=new ae(P),T=J=new ae(P),ce=m(Ie),B=N.e=ce.length-Ae.e-1,N.c[0]=h[(k=B%c)<0?c+k:k],$=!$||V.comparedTo(N)>0?B>0?N:z:V,k=Z,Z=1/0,V=new ae(ce),J.c[0]=0;Y=D(V,N,0,1),x=R.plus(Y.times(T)),x.comparedTo($)!=1;)R=T,T=x,z=J.plus(Y.times(x=z)),J=x,N=V.minus(Y.times(x=N)),V=x;return x=D($.minus(R),T,0,1),J=J.plus(x.times(z)),R=R.plus(x.times(T)),J.s=z.s=Ae.s,B=B*2,te=D(z,T,B,U).minus(Ae).abs().comparedTo(D(J,R,B,U).minus(Ae).abs())<1?[z,T]:[J,R],Z=k,te},O.toNumber=function(){return+oe(this)},O.toPrecision=function($,N){return $!=null&&v($,1,p),Oe(this,$,N,2)},O.toString=function($){var N,R=this,T=R.s,x=R.e;return x===null?T?(N="Infinity",T<0&&(N="-"+N)):N="NaN":($==null?N=x<=M||x>=q?w(m(R.c),x):S(m(R.c),x,"0"):$===10&&ie?(R=de(new ae(R),j+x+1,U),N=S(m(R.c),R.e,"0")):(v($,2,xe.length,"Base"),N=L(S(m(R.c),x,"0"),10,$,T,!0)),T<0&&R.c[0]&&(N="-"+N)),N},O.valueOf=O.toJSON=function(){return oe(this)},O._isBigNumber=!0,A!=null&&ae.set(A),ae}function b(A){var D=A|0;return A>0||A===D?D:D-1}function m(A){for(var D,L,E=1,O=A.length,P=A[0]+"";Eq^L?1:-1;for(U=(M=O.length)<(q=P.length)?M:q,j=0;jP[j]^L?1:-1;return M==q?0:M>q^L?1:-1}function v(A,D,L,E){if(AL||A!==r(A))throw Error(a+(E||"Argument")+(typeof A=="number"?AL?" out of range: ":" not an integer: ":" not a primitive number: ")+String(A))}function _(A){var D=A.c.length-1;return b(A.e/c)==D&&A.c[D]%2!=0}function w(A,D){return(A.length>1?A.charAt(0)+"."+A.slice(1):A)+(D<0?"e":"e+")+D}function S(A,D,L){var E,O;if(D<0){for(O=L+".";++D;O+=L);A=O+A}else if(E=A.length,++D>E){for(O=L,D-=E;--D;O+=L);A+=O}else D>>25)+w|0,A+=(_&w|~_&S)+v[1]-389564586|0,A=(A<<12|A>>>20)+_|0,S+=(A&_|~A&w)+v[2]+606105819|0,S=(S<<17|S>>>15)+A|0,w+=(S&A|~S&_)+v[3]-1044525330|0,w=(w<<22|w>>>10)+S|0,_+=(w&S|~w&A)+v[4]-176418897|0,_=(_<<7|_>>>25)+w|0,A+=(_&w|~_&S)+v[5]+1200080426|0,A=(A<<12|A>>>20)+_|0,S+=(A&_|~A&w)+v[6]-1473231341|0,S=(S<<17|S>>>15)+A|0,w+=(S&A|~S&_)+v[7]-45705983|0,w=(w<<22|w>>>10)+S|0,_+=(w&S|~w&A)+v[8]+1770035416|0,_=(_<<7|_>>>25)+w|0,A+=(_&w|~_&S)+v[9]-1958414417|0,A=(A<<12|A>>>20)+_|0,S+=(A&_|~A&w)+v[10]-42063|0,S=(S<<17|S>>>15)+A|0,w+=(S&A|~S&_)+v[11]-1990404162|0,w=(w<<22|w>>>10)+S|0,_+=(w&S|~w&A)+v[12]+1804603682|0,_=(_<<7|_>>>25)+w|0,A+=(_&w|~_&S)+v[13]-40341101|0,A=(A<<12|A>>>20)+_|0,S+=(A&_|~A&w)+v[14]-1502002290|0,S=(S<<17|S>>>15)+A|0,w+=(S&A|~S&_)+v[15]+1236535329|0,w=(w<<22|w>>>10)+S|0,_+=(w&A|S&~A)+v[1]-165796510|0,_=(_<<5|_>>>27)+w|0,A+=(_&S|w&~S)+v[6]-1069501632|0,A=(A<<9|A>>>23)+_|0,S+=(A&w|_&~w)+v[11]+643717713|0,S=(S<<14|S>>>18)+A|0,w+=(S&_|A&~_)+v[0]-373897302|0,w=(w<<20|w>>>12)+S|0,_+=(w&A|S&~A)+v[5]-701558691|0,_=(_<<5|_>>>27)+w|0,A+=(_&S|w&~S)+v[10]+38016083|0,A=(A<<9|A>>>23)+_|0,S+=(A&w|_&~w)+v[15]-660478335|0,S=(S<<14|S>>>18)+A|0,w+=(S&_|A&~_)+v[4]-405537848|0,w=(w<<20|w>>>12)+S|0,_+=(w&A|S&~A)+v[9]+568446438|0,_=(_<<5|_>>>27)+w|0,A+=(_&S|w&~S)+v[14]-1019803690|0,A=(A<<9|A>>>23)+_|0,S+=(A&w|_&~w)+v[3]-187363961|0,S=(S<<14|S>>>18)+A|0,w+=(S&_|A&~_)+v[8]+1163531501|0,w=(w<<20|w>>>12)+S|0,_+=(w&A|S&~A)+v[13]-1444681467|0,_=(_<<5|_>>>27)+w|0,A+=(_&S|w&~S)+v[2]-51403784|0,A=(A<<9|A>>>23)+_|0,S+=(A&w|_&~w)+v[7]+1735328473|0,S=(S<<14|S>>>18)+A|0,w+=(S&_|A&~_)+v[12]-1926607734|0,w=(w<<20|w>>>12)+S|0,_+=(w^S^A)+v[5]-378558|0,_=(_<<4|_>>>28)+w|0,A+=(_^w^S)+v[8]-2022574463|0,A=(A<<11|A>>>21)+_|0,S+=(A^_^w)+v[11]+1839030562|0,S=(S<<16|S>>>16)+A|0,w+=(S^A^_)+v[14]-35309556|0,w=(w<<23|w>>>9)+S|0,_+=(w^S^A)+v[1]-1530992060|0,_=(_<<4|_>>>28)+w|0,A+=(_^w^S)+v[4]+1272893353|0,A=(A<<11|A>>>21)+_|0,S+=(A^_^w)+v[7]-155497632|0,S=(S<<16|S>>>16)+A|0,w+=(S^A^_)+v[10]-1094730640|0,w=(w<<23|w>>>9)+S|0,_+=(w^S^A)+v[13]+681279174|0,_=(_<<4|_>>>28)+w|0,A+=(_^w^S)+v[0]-358537222|0,A=(A<<11|A>>>21)+_|0,S+=(A^_^w)+v[3]-722521979|0,S=(S<<16|S>>>16)+A|0,w+=(S^A^_)+v[6]+76029189|0,w=(w<<23|w>>>9)+S|0,_+=(w^S^A)+v[9]-640364487|0,_=(_<<4|_>>>28)+w|0,A+=(_^w^S)+v[12]-421815835|0,A=(A<<11|A>>>21)+_|0,S+=(A^_^w)+v[15]+530742520|0,S=(S<<16|S>>>16)+A|0,w+=(S^A^_)+v[2]-995338651|0,w=(w<<23|w>>>9)+S|0,_+=(S^(w|~A))+v[0]-198630844|0,_=(_<<6|_>>>26)+w|0,A+=(w^(_|~S))+v[7]+1126891415|0,A=(A<<10|A>>>22)+_|0,S+=(_^(A|~w))+v[14]-1416354905|0,S=(S<<15|S>>>17)+A|0,w+=(A^(S|~_))+v[5]-57434055|0,w=(w<<21|w>>>11)+S|0,_+=(S^(w|~A))+v[12]+1700485571|0,_=(_<<6|_>>>26)+w|0,A+=(w^(_|~S))+v[3]-1894986606|0,A=(A<<10|A>>>22)+_|0,S+=(_^(A|~w))+v[10]-1051523|0,S=(S<<15|S>>>17)+A|0,w+=(A^(S|~_))+v[1]-2054922799|0,w=(w<<21|w>>>11)+S|0,_+=(S^(w|~A))+v[8]+1873313359|0,_=(_<<6|_>>>26)+w|0,A+=(w^(_|~S))+v[15]-30611744|0,A=(A<<10|A>>>22)+_|0,S+=(_^(A|~w))+v[6]-1560198380|0,S=(S<<15|S>>>17)+A|0,w+=(A^(S|~_))+v[13]+1309151649|0,w=(w<<21|w>>>11)+S|0,_+=(S^(w|~A))+v[4]-145523070|0,_=(_<<6|_>>>26)+w|0,A+=(w^(_|~S))+v[11]-1120210379|0,A=(A<<10|A>>>22)+_|0,S+=(_^(A|~w))+v[2]+718787259|0,S=(S<<15|S>>>17)+A|0,w+=(A^(S|~_))+v[9]-343485551|0,w=(w<<21|w>>>11)+S|0,g[0]=_+g[0]|0,g[1]=w+g[1]|0,g[2]=S+g[2]|0,g[3]=A+g[3]|0}function r(g){var v=[],_;for(_=0;_<64;_+=4)v[_>>2]=g.charCodeAt(_)+(g.charCodeAt(_+1)<<8)+(g.charCodeAt(_+2)<<16)+(g.charCodeAt(_+3)<<24);return v}function a(g){var v=[],_;for(_=0;_<64;_+=4)v[_>>2]=g[_]+(g[_+1]<<8)+(g[_+2]<<16)+(g[_+3]<<24);return v}function o(g){var v=g.length,_=[1732584193,-271733879,-1732584194,271733878],w,S,A,D,L,E;for(w=64;w<=v;w+=64)n(_,r(g.substring(w-64,w)));for(g=g.substring(w-64),S=g.length,A=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],w=0;w>2]|=g.charCodeAt(w)<<(w%4<<3);if(A[w>>2]|=128<<(w%4<<3),w>55)for(n(_,A),w=0;w<16;w+=1)A[w]=0;return D=v*8,D=D.toString(16).match(/(.*?)(.{0,8})$/),L=parseInt(D[2],16),E=parseInt(D[1],16)||0,A[14]=L,A[15]=E,n(_,A),_}function l(g){var v=g.length,_=[1732584193,-271733879,-1732584194,271733878],w,S,A,D,L,E;for(w=64;w<=v;w+=64)n(_,a(g.subarray(w-64,w)));for(g=w-64>2]|=g[w]<<(w%4<<3);if(A[w>>2]|=128<<(w%4<<3),w>55)for(n(_,A),w=0;w<16;w+=1)A[w]=0;return D=v*8,D=D.toString(16).match(/(.*?)(.{0,8})$/),L=parseInt(D[2],16),E=parseInt(D[1],16)||0,A[14]=L,A[15]=E,n(_,A),_}function c(g){var v="",_;for(_=0;_<4;_+=1)v+=s[g>>_*8+4&15]+s[g>>_*8&15];return v}function d(g){var v;for(v=0;vA?new ArrayBuffer(0):(D=A-S,L=new ArrayBuffer(D),E=new Uint8Array(L),O=new Uint8Array(this,S,D),E.set(O),L)}}();function h(g){return/[\u0080-\uFFFF]/.test(g)&&(g=unescape(encodeURIComponent(g))),g}function f(g,v){var _=g.length,w=new ArrayBuffer(_),S=new Uint8Array(w),A;for(A=0;A<_;A+=1)S[A]=g.charCodeAt(A);return v?S:w}function p(g){return String.fromCharCode.apply(null,new Uint8Array(g))}function y(g,v,_){var w=new Uint8Array(g.byteLength+v.byteLength);return w.set(new Uint8Array(g)),w.set(new Uint8Array(v),g.byteLength),_?w:w.buffer}function b(g){var v=[],_=g.length,w;for(w=0;w<_-1;w+=2)v.push(parseInt(g.substr(w,2),16));return String.fromCharCode.apply(String,v)}function m(){this.reset()}return m.prototype.append=function(g){return this.appendBinary(h(g)),this},m.prototype.appendBinary=function(g){this._buff+=g,this._length+=g.length;var v=this._buff.length,_;for(_=64;_<=v;_+=64)n(this._hash,r(this._buff.substring(_-64,_)));return this._buff=this._buff.substring(_-64),this},m.prototype.end=function(g){var v=this._buff,_=v.length,w,S=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],A;for(w=0;w<_;w+=1)S[w>>2]|=v.charCodeAt(w)<<(w%4<<3);return this._finish(S,_),A=d(this._hash),g&&(A=b(A)),this.reset(),A},m.prototype.reset=function(){return this._buff="",this._length=0,this._hash=[1732584193,-271733879,-1732584194,271733878],this},m.prototype.getState=function(){return{buff:this._buff,length:this._length,hash:this._hash.slice()}},m.prototype.setState=function(g){return this._buff=g.buff,this._length=g.length,this._hash=g.hash,this},m.prototype.destroy=function(){delete this._hash,delete this._buff,delete this._length},m.prototype._finish=function(g,v){var _=v,w,S,A;if(g[_>>2]|=128<<(_%4<<3),_>55)for(n(this._hash,g),_=0;_<16;_+=1)g[_]=0;w=this._length*8,w=w.toString(16).match(/(.*?)(.{0,8})$/),S=parseInt(w[2],16),A=parseInt(w[1],16)||0,g[14]=S,g[15]=A,n(this._hash,g)},m.hash=function(g,v){return m.hashBinary(h(g),v)},m.hashBinary=function(g,v){var _=o(g),w=d(_);return v?b(w):w},m.ArrayBuffer=function(){this.reset()},m.ArrayBuffer.prototype.append=function(g){var v=y(this._buff.buffer,g,!0),_=v.length,w;for(this._length+=g.byteLength,w=64;w<=_;w+=64)n(this._hash,a(v.subarray(w-64,w)));return this._buff=w-64<_?new Uint8Array(v.buffer.slice(w-64)):new Uint8Array(0),this},m.ArrayBuffer.prototype.end=function(g){var v=this._buff,_=v.length,w=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],S,A;for(S=0;S<_;S+=1)w[S>>2]|=v[S]<<(S%4<<3);return this._finish(w,_),A=d(this._hash),g&&(A=b(A)),this.reset(),A},m.ArrayBuffer.prototype.reset=function(){return this._buff=new Uint8Array(0),this._length=0,this._hash=[1732584193,-271733879,-1732584194,271733878],this},m.ArrayBuffer.prototype.getState=function(){var g=m.prototype.getState.call(this);return g.buff=p(g.buff),g},m.ArrayBuffer.prototype.setState=function(g){return g.buff=f(g.buff,!0),m.prototype.setState.call(this,g)},m.ArrayBuffer.prototype.destroy=m.prototype.destroy,m.ArrayBuffer.prototype._finish=m.prototype._finish,m.ArrayBuffer.hash=function(g,v){var _=l(new Uint8Array(g)),w=d(_);return v?b(w):w},m})}(Zw)),Zw.exports}var eS={},ip={},O1={},pj;function k7(){if(pj)return O1;pj=1,Object.defineProperty(O1,"__esModule",{value:!0}),O1.default=u;let t;const e=new Uint8Array(16);function u(){if(!t&&(t=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!t))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return t(e)}return O1}var _o={},ap={},sp={},yj;function iee(){if(yj)return sp;yj=1,Object.defineProperty(sp,"__esModule",{value:!0}),sp.default=void 0;var t=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;return sp.default=t,sp}var bj;function Jb(){if(bj)return ap;bj=1,Object.defineProperty(ap,"__esModule",{value:!0}),ap.default=void 0;var t=e(iee());function e(n){return n&&n.__esModule?n:{default:n}}function u(n){return typeof n=="string"&&t.default.test(n)}var s=u;return ap.default=s,ap}var gj;function Xb(){if(gj)return _o;gj=1,Object.defineProperty(_o,"__esModule",{value:!0}),_o.default=void 0,_o.unsafeStringify=s;var t=e(Jb());function e(a){return a&&a.__esModule?a:{default:a}}const u=[];for(let a=0;a<256;++a)u.push((a+256).toString(16).slice(1));function s(a,o=0){return u[a[o+0]]+u[a[o+1]]+u[a[o+2]]+u[a[o+3]]+"-"+u[a[o+4]]+u[a[o+5]]+"-"+u[a[o+6]]+u[a[o+7]]+"-"+u[a[o+8]]+u[a[o+9]]+"-"+u[a[o+10]]+u[a[o+11]]+u[a[o+12]]+u[a[o+13]]+u[a[o+14]]+u[a[o+15]]}function n(a,o=0){const l=s(a,o);if(!(0,t.default)(l))throw TypeError("Stringified UUID is invalid");return l}var r=n;return _o.default=r,_o}var mj;function aee(){if(mj)return ip;mj=1,Object.defineProperty(ip,"__esModule",{value:!0}),ip.default=void 0;var t=u(k7()),e=Xb();function u(c){return c&&c.__esModule?c:{default:c}}let s,n,r=0,a=0;function o(c,d,h){let f=d&&h||0;const p=d||new Array(16);c=c||{};let y=c.node||s,b=c.clockseq!==void 0?c.clockseq:n;if(y==null||b==null){const S=c.random||(c.rng||t.default)();y==null&&(y=s=[S[0]|1,S[1],S[2],S[3],S[4],S[5]]),b==null&&(b=n=(S[6]<<8|S[7])&16383)}let m=c.msecs!==void 0?c.msecs:Date.now(),g=c.nsecs!==void 0?c.nsecs:a+1;const v=m-r+(g-a)/1e4;if(v<0&&c.clockseq===void 0&&(b=b+1&16383),(v<0||m>r)&&c.nsecs===void 0&&(g=0),g>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");r=m,a=g,n=b,m+=122192928e5;const _=((m&268435455)*1e4+g)%4294967296;p[f++]=_>>>24&255,p[f++]=_>>>16&255,p[f++]=_>>>8&255,p[f++]=_&255;const w=m/4294967296*1e4&268435455;p[f++]=w>>>8&255,p[f++]=w&255,p[f++]=w>>>24&15|16,p[f++]=w>>>16&255,p[f++]=b>>>8|128,p[f++]=b&255;for(let S=0;S<6;++S)p[f+S]=y[S];return d||(0,e.unsafeStringify)(p)}var l=o;return ip.default=l,ip}var op={},xa={},up={},_j;function z7(){if(_j)return up;_j=1,Object.defineProperty(up,"__esModule",{value:!0}),up.default=void 0;var t=e(Jb());function e(n){return n&&n.__esModule?n:{default:n}}function u(n){if(!(0,t.default)(n))throw TypeError("Invalid UUID");let r;const a=new Uint8Array(16);return a[0]=(r=parseInt(n.slice(0,8),16))>>>24,a[1]=r>>>16&255,a[2]=r>>>8&255,a[3]=r&255,a[4]=(r=parseInt(n.slice(9,13),16))>>>8,a[5]=r&255,a[6]=(r=parseInt(n.slice(14,18),16))>>>8,a[7]=r&255,a[8]=(r=parseInt(n.slice(19,23),16))>>>8,a[9]=r&255,a[10]=(r=parseInt(n.slice(24,36),16))/1099511627776&255,a[11]=r/4294967296&255,a[12]=r>>>24&255,a[13]=r>>>16&255,a[14]=r>>>8&255,a[15]=r&255,a}var s=u;return up.default=s,up}var vj;function G7(){if(vj)return xa;vj=1,Object.defineProperty(xa,"__esModule",{value:!0}),xa.URL=xa.DNS=void 0,xa.default=a;var t=Xb(),e=u(z7());function u(o){return o&&o.__esModule?o:{default:o}}function s(o){o=unescape(encodeURIComponent(o));const l=[];for(let c=0;c>5]>>>g%32&255,_=parseInt(m.charAt(v>>>4&15)+m.charAt(v&15),16);y.push(_)}return y}function u(p){return(p+64>>>9<<4)+14+1}function s(p,y){p[y>>5]|=128<>5]|=(p[m/8]&255)<>16)+(y>>16)+(b>>16)<<16|b&65535}function a(p,y){return p<>>32-y}function o(p,y,b,m,g,v){return r(a(r(r(y,p),r(m,v)),g),b)}function l(p,y,b,m,g,v,_){return o(y&b|~y&m,p,y,g,v,_)}function c(p,y,b,m,g,v,_){return o(y&m|b&~m,p,y,g,v,_)}function d(p,y,b,m,g,v,_){return o(y^b^m,p,y,g,v,_)}function h(p,y,b,m,g,v,_){return o(b^(y|~m),p,y,g,v,_)}var f=t;return cp.default=f,cp}var Sj;function oee(){if(Sj)return op;Sj=1,Object.defineProperty(op,"__esModule",{value:!0}),op.default=void 0;var t=u(G7()),e=u(see());function u(r){return r&&r.__esModule?r:{default:r}}var n=(0,t.default)("v3",48,e.default);return op.default=n,op}var lp={},dp={},Tj;function uee(){if(Tj)return dp;Tj=1,Object.defineProperty(dp,"__esModule",{value:!0}),dp.default=void 0;var e={randomUUID:typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};return dp.default=e,dp}var Aj;function cee(){if(Aj)return lp;Aj=1,Object.defineProperty(lp,"__esModule",{value:!0}),lp.default=void 0;var t=s(uee()),e=s(k7()),u=Xb();function s(a){return a&&a.__esModule?a:{default:a}}function n(a,o,l){if(t.default.randomUUID&&!o&&!a)return t.default.randomUUID();a=a||{};const c=a.random||(a.rng||e.default)();if(c[6]=c[6]&15|64,c[8]=c[8]&63|128,o){l=l||0;for(let d=0;d<16;++d)o[l+d]=c[d];return o}return(0,u.unsafeStringify)(c)}var r=n;return lp.default=r,lp}var fp={},hp={},Ej;function lee(){if(Ej)return hp;Ej=1,Object.defineProperty(hp,"__esModule",{value:!0}),hp.default=void 0;function t(n,r,a,o){switch(n){case 0:return r&a^~r&o;case 1:return r^a^o;case 2:return r&a^r&o^a&o;case 3:return r^a^o}}function e(n,r){return n<>>32-r}function u(n){const r=[1518500249,1859775393,2400959708,3395469782],a=[1732584193,4023233417,2562383102,271733878,3285377520];if(typeof n=="string"){const d=unescape(encodeURIComponent(n));n=[];for(let h=0;h>>0;m=b,b=y,y=e(p,30)>>>0,p=f,f=_}a[0]=a[0]+f>>>0,a[1]=a[1]+p>>>0,a[2]=a[2]+y>>>0,a[3]=a[3]+b>>>0,a[4]=a[4]+m>>>0}return[a[0]>>24&255,a[0]>>16&255,a[0]>>8&255,a[0]&255,a[1]>>24&255,a[1]>>16&255,a[1]>>8&255,a[1]&255,a[2]>>24&255,a[2]>>16&255,a[2]>>8&255,a[2]&255,a[3]>>24&255,a[3]>>16&255,a[3]>>8&255,a[3]&255,a[4]>>24&255,a[4]>>16&255,a[4]>>8&255,a[4]&255]}var s=u;return hp.default=s,hp}var Oj;function dee(){if(Oj)return fp;Oj=1,Object.defineProperty(fp,"__esModule",{value:!0}),fp.default=void 0;var t=u(G7()),e=u(lee());function u(r){return r&&r.__esModule?r:{default:r}}var n=(0,t.default)("v5",80,e.default);return fp.default=n,fp}var pp={},Rj;function fee(){if(Rj)return pp;Rj=1,Object.defineProperty(pp,"__esModule",{value:!0}),pp.default=void 0;var t="00000000-0000-0000-0000-000000000000";return pp.default=t,pp}var yp={},xj;function hee(){if(xj)return yp;xj=1,Object.defineProperty(yp,"__esModule",{value:!0}),yp.default=void 0;var t=e(Jb());function e(n){return n&&n.__esModule?n:{default:n}}function u(n){if(!(0,t.default)(n))throw TypeError("Invalid UUID");return parseInt(n.slice(14,15),16)}var s=u;return yp.default=s,yp}var Ij;function W7(){return Ij||(Ij=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"NIL",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(t,"parse",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"v1",{enumerable:!0,get:function(){return e.default}}),Object.defineProperty(t,"v3",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(t,"v4",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"v5",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(t,"validate",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"version",{enumerable:!0,get:function(){return a.default}});var e=d(aee()),u=d(oee()),s=d(cee()),n=d(dee()),r=d(fee()),a=d(hee()),o=d(Jb()),l=d(Xb()),c=d(z7());function d(h){return h&&h.__esModule?h:{default:h}}}(eS)),eS}var bp={},Pj;function Kb(){if(Pj)return bp;Pj=1,Object.defineProperty(bp,"__esModule",{value:!0}),bp.orderTypes=void 0;const t=is(),e=uu(),u=ro(),s=Cn(),n=on();function r(c,d,h=!1,f,p){if(c===d)return 0;if(c===void 0)return-1;if(d===void 0)return 1;if(c.termType!==d.termType)return l[c.termType]"term"),cache:f??new t.LRUCache({max:1e3})},defaultTimeZone:{zoneHours:0,zoneMinutes:0}},m=new u.TermTransformer(b.superTypeProvider),g=m.transformLiteral(c),v=m.transformLiteral(d);try{return y.apply([g,v],b).typedValue?0:p.apply([g,v],b).typedValue?1:-1}catch{const _=o(g.dataType,v.dataType);return _!==0?_:o(g.str(),v.str())}}function o(c,d){return c===d?0:cC=>(0,b.bool)(!C.coerceEBV())).collect()},w={arity:1,overloads:(0,b.declare)(l.RegularOperator.UPLUS).numericConverter(()=>C=>C).collect()},S={arity:1,overloads:(0,b.declare)(l.RegularOperator.UMINUS).numericConverter(()=>C=>-C).collect()},A={arity:2,overloads:(0,b.declare)(l.RegularOperator.MULTIPLICATION).arithmetic(()=>(C,ee)=>new t.BigNumber(C).times(ee).toNumber()).collect()},D={arity:2,overloads:(0,b.declare)(l.RegularOperator.DIVISION).arithmetic(()=>(C,ee)=>new t.BigNumber(C).div(ee).toNumber()).onBinaryTyped([c.TypeURL.XSD_INTEGER,c.TypeURL.XSD_INTEGER],()=>(C,ee)=>{if(ee===0)throw new h.ExpressionError("Integer division by 0");return(0,b.decimal)(new t.BigNumber(C).div(ee).toNumber())}).collect()},L={arity:2,overloads:(0,b.declare)(l.RegularOperator.ADDITION).arithmetic(()=>(C,ee)=>new t.BigNumber(C).plus(ee).toNumber()).set([c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DAY_TIME_DURATION],()=>([C,ee])=>new a.DateTimeLiteral((0,p.addDurationToDateTime)(C.typedValue,(0,d.defaultedDurationRepresentation)(ee.typedValue)))).copy({from:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DAY_TIME_DURATION],to:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_YEAR_MONTH_DURATION]}).set([c.TypeURL.XSD_DATE,c.TypeURL.XSD_DAY_TIME_DURATION],()=>([C,ee])=>new a.DateLiteral((0,p.addDurationToDateTime)((0,d.defaultedDateTimeRepresentation)(C.typedValue),(0,d.defaultedDurationRepresentation)(ee.typedValue)))).copy({from:[c.TypeURL.XSD_DATE,c.TypeURL.XSD_DAY_TIME_DURATION],to:[c.TypeURL.XSD_DATE,c.TypeURL.XSD_YEAR_MONTH_DURATION]}).set([c.TypeURL.XSD_TIME,c.TypeURL.XSD_DAY_TIME_DURATION],()=>([C,ee])=>new a.TimeLiteral((0,p.addDurationToDateTime)((0,d.defaultedDateTimeRepresentation)(C.typedValue),(0,d.defaultedDurationRepresentation)(ee.typedValue)))).copy({from:[c.TypeURL.XSD_TIME,c.TypeURL.XSD_DAY_TIME_DURATION],to:[c.TypeURL.XSD_TIME,c.TypeURL.XSD_YEAR_MONTH_DURATION]}).collect()},E={arity:2,overloads:(0,b.declare)(l.RegularOperator.SUBTRACTION).arithmetic(()=>(C,ee)=>new t.BigNumber(C).minus(ee).toNumber()).set([c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DATE_TIME],({defaultTimeZone:C})=>([ee,pe])=>new a.DayTimeDurationLiteral((0,p.elapsedDuration)(ee.typedValue,pe.typedValue,C))).copy({from:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_DATE,c.TypeURL.XSD_DATE]}).copy({from:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_TIME,c.TypeURL.XSD_TIME]}).set([c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DAY_TIME_DURATION],()=>([C,ee])=>new a.DateTimeLiteral((0,p.addDurationToDateTime)(C.typedValue,(0,d.defaultedDurationRepresentation)((0,d.negateDuration)(ee.typedValue))))).copy({from:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DAY_TIME_DURATION],to:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_YEAR_MONTH_DURATION]}).set([c.TypeURL.XSD_DATE,c.TypeURL.XSD_DAY_TIME_DURATION],()=>([C,ee])=>new a.DateLiteral((0,p.addDurationToDateTime)((0,d.defaultedDateTimeRepresentation)(C.typedValue),(0,d.defaultedDurationRepresentation)((0,d.negateDuration)(ee.typedValue))))).copy({from:[c.TypeURL.XSD_DATE,c.TypeURL.XSD_DAY_TIME_DURATION],to:[c.TypeURL.XSD_DATE,c.TypeURL.XSD_YEAR_MONTH_DURATION]}).set([c.TypeURL.XSD_TIME,c.TypeURL.XSD_DAY_TIME_DURATION],()=>([C,ee])=>new a.TimeLiteral((0,p.addDurationToDateTime)((0,d.defaultedDateTimeRepresentation)(C.typedValue),(0,d.defaultedDurationRepresentation)((0,d.negateDuration)(ee.typedValue))))).collect()},O={arity:2,overloads:(0,b.declare)(l.RegularOperator.EQUAL).numberTest(()=>(C,ee)=>C===ee).stringTest(()=>(C,ee)=>C.localeCompare(ee)===0).set([c.TypeURL.RDF_LANG_STRING,c.TypeURL.RDF_LANG_STRING],()=>([C,ee])=>(0,b.bool)(C.str()===ee.str()&&C.language===ee.language)).set([c.TypeAlias.SPARQL_STRINGLY,c.TypeAlias.SPARQL_STRINGLY],()=>()=>(0,b.bool)(!1)).booleanTest(()=>(C,ee)=>C===ee).dateTimeTest(({defaultTimeZone:C})=>(ee,pe)=>(0,d.toUTCDate)(ee,C).getTime()===(0,d.toUTCDate)(pe,C).getTime()).copy({from:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_DATE,c.TypeURL.XSD_DATE]}).set(["quad","quad"],C=>([ee,pe])=>{const De=new y.RegularFunction(c.RegularOperator.EQUAL,O);return(0,b.bool)(De.apply([ee.subject,pe.subject],C).coerceEBV()&&De.apply([ee.predicate,pe.predicate],C).coerceEBV()&&De.apply([ee.object,pe.object],C).coerceEBV())},!1).set(["term","term"],()=>([C,ee])=>(0,b.bool)(P(C,ee)),!1).set([c.TypeURL.XSD_DURATION,c.TypeURL.XSD_DURATION],()=>([C,ee])=>(0,b.bool)((0,d.yearMonthDurationsToMonths)((0,d.defaultedYearMonthDurationRepresentation)(C.typedValue))===(0,d.yearMonthDurationsToMonths)((0,d.defaultedYearMonthDurationRepresentation)(ee.typedValue))&&(0,d.dayTimeDurationsToSeconds)((0,d.defaultedDayTimeDurationRepresentation)(C.typedValue))===(0,d.dayTimeDurationsToSeconds)((0,d.defaultedDayTimeDurationRepresentation)(ee.typedValue)))).set([c.TypeURL.XSD_TIME,c.TypeURL.XSD_TIME],({defaultTimeZone:C})=>([ee,pe])=>(0,b.bool)((0,d.toUTCDate)((0,d.defaultedDateTimeRepresentation)(ee.typedValue),C).getTime()===(0,d.toUTCDate)((0,d.defaultedDateTimeRepresentation)(pe.typedValue),C).getTime())).collect()};function P(C,ee){const pe=C.toRDF(),De=ee.toRDF(),Ue=pe.equals(De);if(!Ue&&pe.termType==="Literal"&&De.termType==="Literal")throw new h.RDFEqualTypeError([C,ee]);return Ue}const j={arity:2,overloads:(0,b.declare)(l.RegularOperator.NOT_EQUAL).set(["term","term"],C=>([ee,pe])=>(0,b.bool)(!g.regularFunctions[l.RegularOperator.EQUAL].apply([ee,pe],C).typedValue)).collect()},U={arity:2,overloads:(0,b.declare)(l.RegularOperator.LT).numberTest(()=>(C,ee)=>C(C,ee)=>C.localeCompare(ee)===-1).booleanTest(()=>(C,ee)=>C([C,ee])=>(0,b.bool)((0,f.orderTypes)(C.toRDF(),ee.toRDF(),!0)===-1),!1).dateTimeTest(({defaultTimeZone:C})=>(ee,pe)=>(0,d.toUTCDate)(ee,C).getTime()<(0,d.toUTCDate)(pe,C).getTime()).copy({from:[c.TypeURL.XSD_DATE_TIME,c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_DATE,c.TypeURL.XSD_DATE]}).set([c.TypeURL.XSD_YEAR_MONTH_DURATION,c.TypeURL.XSD_YEAR_MONTH_DURATION],()=>([C,ee])=>(0,b.bool)((0,d.yearMonthDurationsToMonths)((0,d.defaultedYearMonthDurationRepresentation)(C.typedValue))<(0,d.yearMonthDurationsToMonths)((0,d.defaultedYearMonthDurationRepresentation)(ee.typedValue)))).set([c.TypeURL.XSD_DAY_TIME_DURATION,c.TypeURL.XSD_DAY_TIME_DURATION],()=>([C,ee])=>(0,b.bool)((0,d.dayTimeDurationsToSeconds)((0,d.defaultedDayTimeDurationRepresentation)(C.typedValue))<(0,d.dayTimeDurationsToSeconds)((0,d.defaultedDayTimeDurationRepresentation)(ee.typedValue)))).set([c.TypeURL.XSD_TIME,c.TypeURL.XSD_TIME],({defaultTimeZone:C})=>([ee,pe])=>(0,b.bool)((0,d.toUTCDate)((0,d.defaultedDateTimeRepresentation)(ee.typedValue),C).getTime()<(0,d.toUTCDate)((0,d.defaultedDateTimeRepresentation)(pe.typedValue),C).getTime())).collect()},M={arity:2,overloads:(0,b.declare)(l.RegularOperator.GT).set(["term","term"],C=>([ee,pe])=>g.regularFunctions[l.RegularOperator.LT].apply([pe,ee],C)).collect()},q={arity:2,overloads:(0,b.declare)(l.RegularOperator.LTE).set(["term","term"],C=>([ee,pe])=>(0,b.bool)(g.regularFunctions[l.RegularOperator.LT].apply([ee,pe],C).typedValue||g.regularFunctions[l.RegularOperator.EQUAL].apply([ee,pe],C).typedValue)).collect()},Q={arity:2,overloads:(0,b.declare)(l.RegularOperator.GTE).set(["term","term"],C=>([ee,pe])=>g.regularFunctions[l.RegularOperator.LTE].apply([pe,ee],C)).collect()},Z={arity:1,overloads:(0,b.declare)(l.RegularOperator.IS_IRI).onTerm1(()=>C=>(0,b.bool)(C.termType==="namedNode")).collect()},K={arity:1,overloads:(0,b.declare)(l.RegularOperator.IS_BLANK).onTerm1(()=>C=>(0,b.bool)(C.termType==="blankNode")).collect()},fe={arity:1,overloads:(0,b.declare)(l.RegularOperator.IS_LITERAL).onTerm1(()=>C=>(0,b.bool)(C.termType==="literal")).collect()},X={arity:1,overloads:(0,b.declare)(l.RegularOperator.IS_NUMERIC).onNumeric1(()=>()=>(0,b.bool)(!0)).onTerm1(()=>()=>(0,b.bool)(!1)).collect()},he={arity:1,overloads:(0,b.declare)(l.RegularOperator.STR).onTerm1(()=>C=>(0,b.string)(C.str())).collect()},xe={arity:1,overloads:(0,b.declare)(l.RegularOperator.LANG).onLiteral1(()=>C=>(0,b.string)(C.language??"")).collect()},ie={arity:1,overloads:(0,b.declare)(l.RegularOperator.DATATYPE).onLiteral1(()=>C=>new a.NamedNode(C.dataType)).collect()},ae={arity:1,overloads:(0,b.declare)(l.RegularOperator.IRI).set(["namedNode"],C=>ee=>{const pe=ee[0],De=(0,s.resolve)(pe.str(),C.baseIRI??"");return new a.NamedNode(De)}).onString1(C=>ee=>{const pe=(0,s.resolve)(ee.str(),C.baseIRI??"");return new a.NamedNode(pe)}).collect()},Oe={arity:2,overloads:(0,b.declare)(l.RegularOperator.STRDT).set([c.TypeURL.XSD_STRING,"namedNode"],({superTypeProvider:C})=>([ee,pe])=>{const De=v.literal(ee.typedValue,v.namedNode(pe.value));return new o.TermTransformer(C).transformLiteral(De)}).collect()},Ne={arity:2,overloads:(0,b.declare)(l.RegularOperator.STRLANG).onBinaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>(C,ee)=>new a.LangStringLiteral(C,ee.toLowerCase())).collect()},ge={arity:0,overloads:(0,b.declare)(l.RegularOperator.UUID).set([],()=>()=>new a.NamedNode(`urn:uuid:${r.v4()}`)).collect()},de={arity:0,overloads:(0,b.declare)(l.RegularOperator.STRUUID).set([],()=>()=>(0,b.string)(r.v4())).collect()},oe={arity:1,overloads:(0,b.declare)(l.RegularOperator.STRLEN).onStringly1(()=>C=>(0,b.integer)([...C.typedValue].length)).collect()},$={arity:[2,3],overloads:(0,b.declare)(l.RegularOperator.SUBSTR).onBinaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_INTEGER],()=>(C,ee)=>(0,b.string)([...C].slice(ee-1).join(""))).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.XSD_INTEGER],()=>(C,ee)=>{const pe=[...C.typedValue].slice(ee.typedValue-1).join("");return(0,b.langString)(pe,C.language)}).onTernaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_INTEGER,c.TypeURL.XSD_INTEGER],()=>(C,ee,pe)=>(0,b.string)([...C].slice(ee-1,pe+ee-1).join(""))).onTernary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.XSD_INTEGER,c.TypeURL.XSD_INTEGER],()=>(C,ee,pe)=>{const De=[...C.typedValue].slice(ee.typedValue-1,pe.typedValue+ee.typedValue-1).join("");return(0,b.langString)(De,C.language)}).collect()},N={arity:1,overloads:(0,b.declare)(l.RegularOperator.UCASE).onString1Typed(()=>C=>(0,b.string)(C.toUpperCase())).onLangString1(()=>C=>(0,b.langString)(C.typedValue.toUpperCase(),C.language)).collect()},R={arity:1,overloads:(0,b.declare)(l.RegularOperator.LCASE).onString1Typed(()=>C=>(0,b.string)(C.toLowerCase())).onLangString1(()=>C=>(0,b.langString)(C.typedValue.toLowerCase(),C.language)).collect()},T={arity:2,overloads:(0,b.declare)(l.RegularOperator.STRSTARTS).onBinaryTyped([c.TypeAlias.SPARQL_STRINGLY,c.TypeURL.XSD_STRING],()=>(C,ee)=>(0,b.bool)(C.startsWith(ee))).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.RDF_LANG_STRING],()=>(C,ee)=>{if(C.language!==ee.language)throw new h.IncompatibleLanguageOperation(C,ee);return(0,b.bool)(C.typedValue.startsWith(ee.typedValue))}).collect()},x={arity:2,overloads:(0,b.declare)(l.RegularOperator.STRENDS).onBinaryTyped([c.TypeAlias.SPARQL_STRINGLY,c.TypeURL.XSD_STRING],()=>(C,ee)=>(0,b.bool)(C.endsWith(ee))).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.RDF_LANG_STRING],()=>(C,ee)=>{if(C.language!==ee.language)throw new h.IncompatibleLanguageOperation(C,ee);return(0,b.bool)(C.typedValue.endsWith(ee.typedValue))}).collect()},B={arity:2,overloads:(0,b.declare)(l.RegularOperator.CONTAINS).onBinaryTyped([c.TypeAlias.SPARQL_STRINGLY,c.TypeURL.XSD_STRING],()=>(C,ee)=>(0,b.bool)(C.includes(ee))).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.RDF_LANG_STRING],()=>(C,ee)=>{if(C.language!==ee.language)throw new h.IncompatibleLanguageOperation(C,ee);return(0,b.bool)(C.typedValue.includes(ee.typedValue))}).collect()},k={arity:2,overloads:(0,b.declare)(l.RegularOperator.STRBEFORE).onBinaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>(C,ee)=>(0,b.string)(C.slice(0,Math.max(0,C.indexOf(ee))))).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.XSD_STRING],()=>(C,ee)=>{const[pe,De]=[C.typedValue,ee.typedValue],Ue=C.typedValue.slice(0,Math.max(0,pe.indexOf(De)));return Ue||!De?(0,b.langString)(Ue,C.language):(0,b.string)(Ue)}).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.RDF_LANG_STRING],()=>(C,ee)=>{if(C.language!==ee.language)throw new h.IncompatibleLanguageOperation(C,ee);const[pe,De]=[C.typedValue,ee.typedValue],Ue=C.typedValue.slice(0,Math.max(0,pe.indexOf(De)));return Ue||!De?(0,b.langString)(Ue,C.language):(0,b.string)(Ue)}).collect()},V={arity:2,overloads:(0,b.declare)(l.RegularOperator.STRAFTER).onBinaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>(C,ee)=>(0,b.string)(C.slice(C.indexOf(ee)).slice(ee.length))).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.XSD_STRING],()=>(C,ee)=>{const[pe,De]=[C.typedValue,ee.typedValue],Ue=pe.slice(pe.indexOf(De)).slice(De.length);return Ue||!De?(0,b.langString)(Ue,C.language):(0,b.string)(Ue)}).onBinary([c.TypeURL.RDF_LANG_STRING,c.TypeURL.RDF_LANG_STRING],()=>(C,ee)=>{if(C.language!==ee.language)throw new h.IncompatibleLanguageOperation(C,ee);const[pe,De]=[C.typedValue,ee.typedValue],Ue=pe.slice(pe.indexOf(De)).slice(De.length);return Ue||!De?(0,b.langString)(Ue,C.language):(0,b.string)(Ue)}).collect()},J={arity:1,overloads:(0,b.declare)(l.RegularOperator.ENCODE_FOR_URI).onStringly1Typed(()=>C=>(0,b.string)(encodeURI(C))).collect()},z={arity:2,overloads:(0,b.declare)(l.RegularOperator.LANG_MATCHES).onBinaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>(C,ee)=>(0,b.bool)(m.langMatches(C,ee))).collect()};function Y(){return(C,ee)=>(0,b.bool)(m.matches(C,ee))}function te(){return(C,ee,pe)=>(0,b.bool)(m.matches(C,ee,pe))}const ce={arity:[2,3],overloads:(0,b.declare)(l.RegularOperator.REGEX).onBinaryTyped([c.TypeAlias.SPARQL_STRINGLY,c.TypeURL.XSD_STRING],Y).onTernaryTyped([c.TypeAlias.SPARQL_STRINGLY,c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],te).collect()},Ae={arity:[3,4],overloads:(0,b.declare)(l.RegularOperator.REPLACE).onTernaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>(C,ee,pe)=>(0,b.string)(m.replace(C,ee,pe))).set([c.TypeURL.RDF_LANG_STRING,c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>([C,ee,pe])=>{const De=m.replace(C.typedValue,ee.typedValue,pe.typedValue);return(0,b.langString)(De,C.language)}).onQuaternaryTyped([c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>(C,ee,pe,De)=>(0,b.string)(m.replace(C,ee,pe,De))).set([c.TypeURL.RDF_LANG_STRING,c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING,c.TypeURL.XSD_STRING],()=>([C,ee,pe,De])=>{const Ue=m.replace(C.typedValue,ee.typedValue,pe.typedValue,De.typedValue);return(0,b.langString)(Ue,C.language)}).collect()},Ie={arity:1,overloads:(0,b.declare)(l.RegularOperator.ABS).numericConverter(()=>C=>Math.abs(C)).collect()},Ee={arity:1,overloads:(0,b.declare)(l.RegularOperator.ROUND).numericConverter(()=>C=>Math.round(C)).collect()},qe={arity:1,overloads:(0,b.declare)(l.RegularOperator.CEIL).numericConverter(()=>C=>Math.ceil(C)).collect()},G={arity:1,overloads:(0,b.declare)(l.RegularOperator.FLOOR).numericConverter(()=>C=>Math.floor(C)).collect()},F={arity:0,overloads:(0,b.declare)(l.RegularOperator.RAND).set([],()=>()=>(0,b.double)(Math.random())).collect()},H={arity:0,overloads:(0,b.declare)(l.RegularOperator.NOW).set([],C=>()=>new a.DateTimeLiteral((0,d.toDateTimeRepresentation)({date:C.now,timeZone:C.defaultTimeZone}))).collect()},re={arity:1,overloads:(0,b.declare)(l.RegularOperator.YEAR).onDateTime1(()=>C=>(0,b.integer)(C.typedValue.year)).set([c.TypeURL.XSD_DATE],()=>([C])=>(0,b.integer)(C.typedValue.year)).collect()},be={arity:1,overloads:(0,b.declare)(l.RegularOperator.MONTH).onDateTime1(()=>C=>(0,b.integer)(C.typedValue.month)).set([c.TypeURL.XSD_DATE],()=>([C])=>(0,b.integer)(C.typedValue.month)).collect()},Re={arity:1,overloads:(0,b.declare)(l.RegularOperator.DAY).onDateTime1(()=>C=>(0,b.integer)(C.typedValue.day)).set([c.TypeURL.XSD_DATE],()=>([C])=>(0,b.integer)(C.typedValue.day)).collect()},Ce={arity:1,overloads:(0,b.declare)(l.RegularOperator.HOURS).onDateTime1(()=>C=>(0,b.integer)(C.typedValue.hours)).set([c.TypeURL.XSD_TIME],()=>([C])=>(0,b.integer)(C.typedValue.hours)).collect()},Qe={arity:1,overloads:(0,b.declare)(l.RegularOperator.MINUTES).onDateTime1(()=>C=>(0,b.integer)(C.typedValue.minutes)).set([c.TypeURL.XSD_TIME],()=>([C])=>(0,b.integer)(C.typedValue.minutes)).collect()},ke={arity:1,overloads:(0,b.declare)(l.RegularOperator.SECONDS).onDateTime1(()=>C=>(0,b.decimal)(C.typedValue.seconds)).set([c.TypeURL.XSD_TIME],()=>([C])=>(0,b.integer)(C.typedValue.seconds)).collect()},me={arity:1,overloads:(0,b.declare)(l.RegularOperator.TIMEZONE).onDateTime1(()=>C=>{const ee={hours:C.typedValue.zoneHours,minutes:C.typedValue.zoneMinutes};if(ee.hours===void 0&&ee.minutes===void 0)throw new h.InvalidTimezoneCall(C.str());return new a.DayTimeDurationLiteral(ee)}).copy({from:[c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_DATE]}).copy({from:[c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_TIME]}).collect()},Se={arity:1,overloads:(0,b.declare)(l.RegularOperator.TZ).onDateTime1(()=>C=>(0,b.string)((0,d.extractRawTimeZone)(C.str()))).copy({from:[c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_DATE]}).copy({from:[c.TypeURL.XSD_DATE_TIME],to:[c.TypeURL.XSD_TIME]}).collect()},W={arity:1,overloads:(0,b.declare)(l.RegularOperator.MD5).onString1Typed(()=>C=>(0,b.string)((0,n.hash)(C))).collect()},we={arity:1,overloads:(0,b.declare)(l.RegularOperator.SHA1).onString1Typed(()=>C=>(0,b.string)((0,e.sha1)().update(C).digest("hex"))).collect()},Te={arity:1,overloads:(0,b.declare)(l.RegularOperator.SHA256).onString1Typed(()=>C=>(0,b.string)((0,e.sha256)().update(C).digest("hex"))).collect()},Le={arity:1,overloads:(0,b.declare)(l.RegularOperator.SHA384).onString1Typed(()=>C=>(0,b.string)((0,e.sha384)().update(C).digest("hex"))).collect()},$e={arity:1,overloads:(0,b.declare)(l.RegularOperator.SHA512).onString1Typed(()=>C=>(0,b.string)((0,e.sha512)().update(C).digest("hex"))).collect()},We={arity:3,overloads:(0,b.declare)(l.RegularOperator.TRIPLE).onTerm3(C=>(...ee)=>new a.Quad(v.quad(ee[0].toRDF(),ee[1].toRDF(),ee[2].toRDF()),C.superTypeProvider)).collect()},tt={arity:1,overloads:(0,b.declare)(l.RegularOperator.SUBJECT).onQuad1(()=>C=>C.subject).collect()},lt={arity:1,overloads:(0,b.declare)(l.RegularOperator.PREDICATE).onQuad1(()=>C=>C.predicate).collect()},ut={arity:1,overloads:(0,b.declare)(l.RegularOperator.OBJECT).onQuad1(()=>C=>C.object).collect()},le={arity:1,overloads:(0,b.declare)(l.RegularOperator.IS_TRIPLE).onTerm1(()=>C=>(0,b.bool)(C.termType==="quad")).collect()};return np.definitions={"!":_,uplus:w,uminus:S,"*":A,"/":D,"+":L,"-":E,"=":O,"!=":j,"<":U,">":M,"<=":q,">=":Q,isiri:Z,isuri:Z,isblank:K,isliteral:fe,isnumeric:X,str:he,lang:xe,datatype:ie,iri:ae,uri:ae,strdt:Oe,strlang:Ne,uuid:ge,struuid:de,strlen:oe,substr:$,ucase:N,lcase:R,strstarts:T,strends:x,contains:B,strbefore:k,strafter:V,encode_for_uri:J,langmatches:z,regex:ce,replace:Ae,abs:Ie,round:Ee,ceil:qe,floor:G,rand:F,now:H,year:re,month:be,day:Re,hours:Ce,minutes:Qe,seconds:ke,timezone:me,tz:Se,md5:W,sha1:we,sha256:Te,sha384:Le,sha512:$e,triple:We,subject:tt,predicate:lt,object:ut,istriple:le},np}var gp={},Cj;function bee(){if(Cj)return gp;Cj=1,Object.defineProperty(gp,"__esModule",{value:!0}),gp.specialDefinitions=void 0;const t=W7(),e=Kn(),u=Cn(),s=on(),n=Yi(),r=uu(),a={arity:1,async applyAsync({args:D,mapping:L}){return o({args:D,mapping:L})},applySynchronously({args:D,mapping:L}){return o({args:D,mapping:L})}};function o({args:D,mapping:L}){const E=D[0];if(E.expressionType!==e.ExpressionType.Variable)throw new s.InvalidArgumentTypes(D,u.SpecialOperator.BOUND);const O=L.has((0,n.expressionToVar)(E));return(0,n.bool)(O)}const l={arity:3,async applyAsync({args:D,mapping:L,evaluate:E}){const P=(await E(D[0],L)).coerceEBV();return E(P?D[1]:D[2],L)},applySynchronously({args:D,mapping:L,evaluate:E}){const P=E(D[0],L).coerceEBV();return E(P?D[1]:D[2],L)}},c={arity:Number.POSITIVE_INFINITY,async applyAsync({args:D,mapping:L,evaluate:E}){const O=[];for(const P of D)try{return await E(P,L)}catch(j){O.push(j)}throw new s.CoalesceError(O)},applySynchronously({args:D,mapping:L,evaluate:E}){const O=[];for(const P of D)try{return E(P,L)}catch(j){O.push(j)}throw new s.CoalesceError(O)}},d={arity:2,async applyAsync({args:D,mapping:L,evaluate:E}){const[O,P]=D;try{if((await E(O,L)).coerceEBV())return(0,n.bool)(!0);const q=(await E(P,L)).coerceEBV();return(0,n.bool)(q)}catch(j){if(!(await E(P,L)).coerceEBV())throw j;return(0,n.bool)(!0)}},applySynchronously({args:D,mapping:L,evaluate:E}){const[O,P]=D;try{if(E(O,L).coerceEBV())return(0,n.bool)(!0);const q=E(P,L).coerceEBV();return(0,n.bool)(q)}catch(j){if(!E(P,L).coerceEBV())throw j;return(0,n.bool)(!0)}}},h={arity:2,async applyAsync({args:D,mapping:L,evaluate:E}){const[O,P]=D;try{if(!(await E(O,L)).coerceEBV())return(0,n.bool)(!1);const q=(await E(P,L)).coerceEBV();return(0,n.bool)(q)}catch(j){if((await E(P,L)).coerceEBV())throw j;return(0,n.bool)(!1)}},applySynchronously({args:D,mapping:L,evaluate:E}){const[O,P]=D;try{if(!E(O,L).coerceEBV())return(0,n.bool)(!1);const q=E(P,L).coerceEBV();return(0,n.bool)(q)}catch(j){if(E(P,L).coerceEBV())throw j;return(0,n.bool)(!1)}}},f={arity:2,async applyAsync({args:D,mapping:L,evaluate:E}){const[O,P]=D.map(M=>E(M,L)),[j,U]=await Promise.all([O,P]);return(0,n.bool)(j.toRDF().equals(U.toRDF()))},applySynchronously({args:D,mapping:L,evaluate:E}){const[O,P]=D.map(j=>E(j,L));return(0,n.bool)(O.toRDF().equals(P.toRDF()))}},p={arity:Number.POSITIVE_INFINITY,checkArity(D){return D.length>0},async applyAsync(D){const{args:L,mapping:E,evaluate:O}=D,[P,...j]=L,U=await O(P,E);return y(U,{...D,args:j},[])},applySynchronously(D){const{args:L,mapping:E,evaluate:O}=D,[P,...j]=L,U=O(P,E);return b(U,{...D,args:j},[])}};async function y(D,L,E){const{args:O,mapping:P,evaluate:j}=L;if(O.length===0)return E.every(M=>!M)?(0,n.bool)(!1):Promise.reject(new s.InError(E));try{const U=O.shift(),M=await j(U,P);return r.regularFunctions[u.RegularOperator.EQUAL].apply([D,M],L).typedValue?(0,n.bool)(!0):y(D,L,[...E,!1])}catch(U){return y(D,L,[...E,U])}}function b(D,L,E){const{args:O,mapping:P,evaluate:j}=L;if(O.length===0){if(E.every(M=>!M))return(0,n.bool)(!1);throw new s.InError(E)}try{const U=O.shift(),M=j(U,P);return r.regularFunctions[u.RegularOperator.EQUAL].apply([D,M],L).typedValue?(0,n.bool)(!0):b(D,L,[...E,!1])}catch(U){return b(D,L,[...E,U])}}const m={arity:Number.POSITIVE_INFINITY,checkArity(D){return D.length>0},async applyAsync(D){const E=await r.specialFunctions[u.SpecialOperator.IN].applyAsync(D);return(0,n.bool)(!E.typedValue)},applySynchronously(D){const E=r.specialFunctions[u.SpecialOperator.IN].applySynchronously(D);return(0,n.bool)(!E.typedValue)}},g=(0,n.declare)(u.SpecialOperator.CONCAT).onStringly1(()=>D=>D).collect(),v={arity:Number.POSITIVE_INFINITY,async applyAsync(D){const{args:L,mapping:E,evaluate:O,functionArgumentsCache:P,superTypeProvider:j}=D,U=L.map(async K=>O(K,E)).map(async K=>{const fe=g.search([await K],j,P);if(!fe)throw new s.InvalidArgumentTypes(L,u.SpecialOperator.CONCAT);return fe(D)([await K])}),M=await Promise.all(U),Q=M.map(K=>K.typedValue).join(""),Z=_(M)?M[0].language:void 0;return Z?(0,n.langString)(Q,Z):(0,n.string)(Q)},applySynchronously(D){const{args:L,mapping:E,evaluate:O,superTypeProvider:P,functionArgumentsCache:j}=D,U=L.map(Z=>O(Z,E)).map(Z=>{const K=g.search([Z],P,j);if(!K)throw new s.InvalidArgumentTypes(L,u.SpecialOperator.CONCAT);return K(D)([Z])}),q=U.map(Z=>Z.typedValue).join(""),Q=_(U)?U[0].language:void 0;return Q?(0,n.langString)(q,Q):(0,n.string)(q)}};function _(D){return D.length>0&&D.every(L=>L.language===D[0].language)}const w=(0,n.declare)(u.SpecialOperator.BNODE).onString1(()=>D=>D).collect(),S={arity:Number.POSITIVE_INFINITY,checkArity(D){return D.length===0||D.length===1},async applyAsync(D){const{args:L,mapping:E,evaluate:O,superTypeProvider:P,functionArgumentsCache:j}=D,U=L.length===1?await O(L[0],E):void 0;let M;if(U){const q=w.search([U],P,j);if(!q)throw new s.InvalidArgumentTypes(L,u.SpecialOperator.BNODE);M=q(D)([U]).str()}if(D.bnode){const q=await D.bnode(M);return new e.BlankNode(q)}return A(M)},applySynchronously(D){const{args:L,mapping:E,evaluate:O,superTypeProvider:P,functionArgumentsCache:j}=D,U=L.length===1?O(L[0],E):void 0;let M;if(U){const q=w.search([U],P,j);if(!q)throw new s.InvalidArgumentTypes(L,u.SpecialOperator.BNODE);M=q(D)([U]).str()}if(D.bnode){const q=D.bnode(M);return new e.BlankNode(q)}return A(M)}};function A(D){return new e.BlankNode(D??t.v4())}return gp.specialDefinitions={bound:a,if:l,coalesce:c,"&&":h,"||":d,sameterm:f,in:p,notin:m,concat:v,bnode:S},gp}var jj;function uu(){return jj||(jj=1,function(t){var e=I&&I.__createBinding||(Object.create?function(l,c,d,h){h===void 0&&(h=d);var f=Object.getOwnPropertyDescriptor(c,d);(!f||("get"in f?!c.__esModule:f.writable||f.configurable))&&(f={enumerable:!0,get:function(){return c[d]}}),Object.defineProperty(l,h,f)}:function(l,c,d,h){h===void 0&&(h=d),l[h]=c[d]}),u=I&&I.__exportStar||function(l,c){for(var d in l)d!=="default"&&!Object.prototype.hasOwnProperty.call(c,d)&&e(c,l,d)};Object.defineProperty(t,"__esModule",{value:!0}),t.OverloadTree=t.namedFunctions=t.specialFunctions=t.regularFunctions=void 0;const s=g3(),n=tee(),r=yee(),a=bee();u(g3(),t),t.regularFunctions=Object.fromEntries(Object.entries(r.definitions).map(([l,c])=>[l,new s.RegularFunction(l,c)])),t.specialFunctions=Object.fromEntries(Object.entries(a.specialDefinitions).map(([l,c])=>[l,new s.SpecialFunction(l,c)])),t.namedFunctions=Object.fromEntries(Object.entries(n.namedDefinitions).map(([l,c])=>[l,new s.NamedFunction(l,c)]));var o=V7();Object.defineProperty(t,"OverloadTree",{enumerable:!0,get:function(){return o.OverloadTree}})}(Kw)),Kw}var Lj;function J7(){if(Lj)return kh;Lj=1,Object.defineProperty(kh,"__esModule",{value:!0}),kh.AlgebraTransformer=void 0;const t=Ot(),e=Kn(),u=uu(),s=Cn(),n=on(),r=on(),a=ro();let o=class P0 extends a.TermTransformer{constructor(c){super(c.superTypeProvider),this.algebraConfig=c,this.creatorConfig={type:c.type,creator:c.creator}}transformAlgebra(c){const d=t.Algebra.expressionTypes;switch(c.expressionType){case d.TERM:return this.transformTerm(c);case d.OPERATOR:return this.transformOperator(c);case d.NAMED:return this.transformNamed(c);case d.EXISTENCE:return P0.transformExistence(c);case d.AGGREGATE:return P0.transformAggregate(c);case d.WILDCARD:return P0.transformWildcard(c)}}static transformWildcard(c){return new e.NamedNode(c.wildcard.value)}transformOperator(c){const d=c.operator.toLowerCase();if(s.SpecialOperators.has(d)){const y=d,b=c.args.map(g=>this.transformAlgebra(g)),m=u.specialFunctions[y];if(!m.checkArity(b))throw new n.InvalidArity(b,y);return new e.SpecialOperator(b,m.applyAsync,m.applySynchronously)}if(!s.Operators.has(d))throw new n.UnknownOperator(c.operator);const h=d,f=c.args.map(y=>this.transformAlgebra(y)),p=u.regularFunctions[h];if(!P0.hasCorrectArity(f,p.arity))throw new n.InvalidArity(f,h);return new e.Operator(f,y=>p.apply(y,this.algebraConfig))}wrapSyncFunction(c,d){return h=>{try{const f=c(h.map(p=>p.toRDF()));return this.transformRDFTermUnsafe(f)}catch(f){throw new r.ExtensionFunctionError(d,f)}}}wrapAsyncFunction(c,d){return async h=>{try{const f=await c(h.map(p=>p.toRDF()));return this.transformRDFTermUnsafe(f)}catch(f){throw new r.ExtensionFunctionError(d,f)}}}transformNamed(c){const d=c.name.value,h=c.args.map(f=>this.transformAlgebra(f));if(s.NamedOperators.has(d)){const f=c.name.value,p=u.namedFunctions[f];return new e.Named(c.name,h,y=>p.apply(y,this.algebraConfig))}if(this.creatorConfig.type==="sync"){const f=this.creatorConfig.creator(c.name);if(f){const p=this.wrapSyncFunction(f,c.name.value);return new e.SyncExtension(c.name,h,p)}}else{const f=this.creatorConfig.creator(c.name);if(f){const p=this.wrapAsyncFunction(f,c.name.value);return new e.AsyncExtension(c.name,h,p)}}throw new n.UnknownNamedOperator(c.name.value)}static hasCorrectArity(c,d){return Array.isArray(d)?d.includes(c.length):c.length===d}static transformAggregate(c){const d=c.aggregator;return new e.Aggregate(d,c)}static transformExistence(c){return new e.Existence(c)}};return kh.AlgebraTransformer=o,kh}var mp={},_p={},Mj;function X7(){if(Mj)return _p;Mj=1,Object.defineProperty(_p,"__esModule",{value:!0}),_p.BaseExpressionEvaluator=void 0;const t=Yi(),e=on();let u=class{constructor(n){this.termTransformer=n}term(n){return n}variable(n,r){const a=r.get((0,t.expressionToVar)(n));if(!a)throw new e.UnboundVariableError(n.name,r);return this.termTransformer.transformRDFTermUnsafe(a)}};return _p.BaseExpressionEvaluator=u,_p}var Fj;function gee(){if(Fj)return mp;Fj=1,Object.defineProperty(mp,"__esModule",{value:!0}),mp.AsyncRecursiveEvaluator=void 0;const t=Kn(),e=ro(),u=on(),s=X7();let n=class extends s.BaseExpressionEvaluator{constructor(a,o){super(o??new e.TermTransformer(a.superTypeProvider)),this.context=a,this.subEvaluators={[t.ExpressionType.Term]:(l,c)=>this.term(l),[t.ExpressionType.Variable]:(l,c)=>this.variable(l,c),[t.ExpressionType.Operator]:(l,c)=>this.evalOperator(l,c),[t.ExpressionType.SpecialOperator]:(l,c)=>this.evalSpecialOperator(l,c),[t.ExpressionType.Named]:(l,c)=>this.evalNamed(l,c),[t.ExpressionType.Existence]:(l,c)=>this.evalExistence(l,c),[t.ExpressionType.Aggregate]:(l,c)=>this.evalAggregate(l),[t.ExpressionType.AsyncExtension]:(l,c)=>this.evalAsyncExtension(l,c)}}async evaluate(a,o){const l=this.subEvaluators[a.expressionType];if(!l)throw new u.InvalidExpressionType(a);return l.bind(this)(a,o)}async evalOperator(a,o){const l=a.args.map(d=>this.evaluate(d,o)),c=await Promise.all(l);return a.apply(c)}async evalSpecialOperator(a,o){const l=this.evaluate.bind(this),c={args:a.args,mapping:o,superTypeProvider:this.context.superTypeProvider,now:this.context.now,baseIRI:this.context.baseIRI,functionArgumentsCache:this.context.functionArgumentsCache,evaluate:l,bnode:this.context.bnode,defaultTimeZone:this.context.defaultTimeZone};return a.applyAsync(c)}async _evalAsyncArgs(a,o){const l=a.map(c=>this.evaluate(c,o));return await Promise.all(l)}async evalNamed(a,o){return a.apply(await this._evalAsyncArgs(a.args,o))}async evalAsyncExtension(a,o){return await a.apply(await this._evalAsyncArgs(a.args,o))}async evalExistence(a,o){if(!this.context.exists)throw new u.NoExistenceHook;return new t.BooleanLiteral(await this.context.exists(a.expression,o))}async evalAggregate(a){if(!this.context.aggregate)throw new u.NoAggregator;return this.termTransformer.transformRDFTermUnsafe(await this.context.aggregate(a.expression))}};return mp.AsyncRecursiveEvaluator=n,mp}var qj;function Y7(){if(qj)return Vh;qj=1,Object.defineProperty(Vh,"__esModule",{value:!0}),Vh.AsyncEvaluator=void 0;const t=is(),e=J7(),u=ou(),s=gee();let n=class K7{static completeContext(a){const o=a.now??new Date(Date.now());return{now:o,baseIRI:a.baseIRI??void 0,functionArgumentsCache:a.functionArgumentsCache??{},superTypeProvider:{cache:a.typeCache??new t.LRUCache({max:1e3}),discoverer:a.getSuperType??(()=>"term")},extensionFunctionCreator:a.extensionFunctionCreator,exists:a.exists,aggregate:a.aggregate,bnode:a.bnode,defaultTimeZone:a.defaultTimeZone??(0,u.extractTimeZone)(o)}}constructor(a,o={}){this.algExpr=a;const l=o.extensionFunctionCreator??(()=>{}),c=K7.completeContext(o),d=new e.AlgebraTransformer({type:"async",creator:l,...c});this.expr=d.transformAlgebra(a),this.evaluator=new s.AsyncRecursiveEvaluator(c,d)}async evaluate(a){return(await this.evaluator.evaluate(this.expr,a)).toRDF()}async evaluateAsEBV(a){return(await this.evaluator.evaluate(this.expr,a)).coerceEBV()}async evaluateAsInternal(a){return await this.evaluator.evaluate(this.expr,a)}};return Vh.AsyncEvaluator=n,Vh}var vp={},wp={},Bj;function mee(){if(Bj)return wp;Bj=1,Object.defineProperty(wp,"__esModule",{value:!0}),wp.SyncRecursiveEvaluator=void 0;const t=Kn(),e=ro(),u=on(),s=X7();let n=class extends s.BaseExpressionEvaluator{constructor(a,o){super(o??new e.TermTransformer(a.superTypeProvider)),this.context=a,this.subEvaluators={[t.ExpressionType.Term]:(l,c)=>this.term(l),[t.ExpressionType.Variable]:(l,c)=>this.variable(l,c),[t.ExpressionType.Operator]:(l,c)=>this.evalOperator(l,c),[t.ExpressionType.SpecialOperator]:(l,c)=>this.evalSpecialOperator(l,c),[t.ExpressionType.Named]:(l,c)=>this.evalNamed(l,c),[t.ExpressionType.Existence]:(l,c)=>this.evalExistence(l,c),[t.ExpressionType.Aggregate]:(l,c)=>this.evalAggregate(l),[t.ExpressionType.SyncExtension]:(l,c)=>this.evalSyncExtension(l,c)}}evaluate(a,o){const l=this.subEvaluators[a.expressionType];if(!l)throw new u.InvalidExpressionType(a);return l.bind(this)(a,o)}evalOperator(a,o){const l=a.args.map(c=>this.evaluate(c,o));return a.apply(l)}evalSpecialOperator(a,o){const l=this.evaluate.bind(this),c={args:a.args,mapping:o,superTypeProvider:this.context.superTypeProvider,now:this.context.now,baseIRI:this.context.baseIRI,functionArgumentsCache:this.context.functionArgumentsCache,evaluate:l,bnode:this.context.bnode,defaultTimeZone:this.context.defaultTimeZone};return a.applySynchronously(c)}evalNamed(a,o){const l=a.args.map(c=>this.evaluate(c,o));return a.apply(l)}evalSyncExtension(a,o){const l=a.args.map(c=>this.evaluate(c,o));return a.apply(l)}evalExistence(a,o){if(!this.context.exists)throw new u.NoExistenceHook;return new t.BooleanLiteral(this.context.exists(a.expression,o))}evalAggregate(a){if(!this.context.aggregate)throw new u.NoAggregator;return this.termTransformer.transformRDFTermUnsafe(this.context.aggregate(a.expression))}};return wp.SyncRecursiveEvaluator=n,wp}var Uj;function eB(){if(Uj)return vp;Uj=1,Object.defineProperty(vp,"__esModule",{value:!0}),vp.SyncEvaluator=void 0;const t=is(),e=J7(),u=ou(),s=mee();let n=class Z7{static completeContext(a){const o=a.now??new Date(Date.now());return{now:o,baseIRI:a.baseIRI??void 0,functionArgumentsCache:a.functionArgumentsCache??{},superTypeProvider:{cache:a.typeCache??new t.LRUCache({max:1e3}),discoverer:a.getSuperType??(()=>"term")},extensionFunctionCreator:a.extensionFunctionCreator,exists:a.exists,aggregate:a.aggregate,bnode:a.bnode,defaultTimeZone:a.defaultTimeZone??(0,u.extractTimeZone)(o)}}constructor(a,o={}){this.algExpr=a,this.context=o;const l=o.extensionFunctionCreator??(()=>{}),c=Z7.completeContext(o),d=new e.AlgebraTransformer({type:"sync",creator:l,...c});this.expr=d.transformAlgebra(a),this.evaluator=new s.SyncRecursiveEvaluator(c,d)}evaluate(a){return this.evaluator.evaluate(this.expr,a).toRDF()}evaluateAsEBV(a){return this.evaluator.evaluate(this.expr,a).coerceEBV()}evaluateAsInternal(a){return this.evaluator.evaluate(this.expr,a)}};return vp.SyncEvaluator=n,vp}var Sp={},Tp={},Ap={},Ep={},Is={},Hj;function ss(){if(Hj)return Is;Hj=1,Object.defineProperty(Is,"__esModule",{value:!0}),Is.Aggregator=Is.AggregatorComponent=void 0;const t=er(),e=ro(),u=Cn(),s=Wb();class n{static emptyValue(){}constructor(o,l){this.sharedContext=l,this.separator=o.separator||" ",this.termTransformer=new e.TermTransformer(l.superTypeProvider)}termToNumericOrError(o){if(o.termType!=="Literal")throw new Error(`Term with value ${o.value} has type ${o.termType} and is not a numeric literal`);if(!(0,s.isSubTypeOf)(o.datatype.value,u.TypeAlias.SPARQL_NUMERIC,this.sharedContext.superTypeProvider))throw new Error(`Term datatype ${o.datatype.value} with value ${o.value} has type ${o.termType} and is not a numeric literal`);return this.termTransformer.transformLiteral(o)}}Is.AggregatorComponent=n;let r=class{constructor(o,l){this.aggregatorComponent=l,this.variableValues=new Map,this.distinct=o.distinct}static emptyValue(o){return o.emptyValue()}result(){return this.aggregatorComponent.result()}put(o,l=""){this.canSkip(o,l)||(this.aggregatorComponent.put(o),this.addSeen(o,l))}canSkip(o,l){const c=this.variableValues.get(l);return this.distinct&&c!==void 0&&c.has(t.termToString(o))}addSeen(o,l){this.distinct&&(this.variableValues.has(l)||this.variableValues.set(l,new Set),this.variableValues.get(l).add(t.termToString(o)))}};return Is.Aggregator=r,Is}var $j;function _ee(){if($j)return Ep;$j=1,Object.defineProperty(Ep,"__esModule",{value:!0}),Ep.Average=void 0;const t=Kn(),e=uu(),u=Yi(),s=Cn(),n=ss();let r=class tB extends n.AggregatorComponent{constructor(){super(...arguments),this.summer=e.regularFunctions[s.RegularOperator.ADDITION],this.divider=e.regularFunctions[s.RegularOperator.DIVISION],this.state=void 0}static emptyValue(){return(0,u.integer)(0).toRDF()}put(o){if(this.state===void 0){const l=this.termToNumericOrError(o);this.state={sum:l,count:1}}else{const l=this.termToNumericOrError(o);this.state.sum=this.summer.apply([this.state.sum,l],this.sharedContext),this.state.count++}}result(){if(this.state===void 0)return tB.emptyValue();const o=new t.IntegerLiteral(this.state.count);return this.divider.apply([this.state.sum,o],this.sharedContext).toRDF()}};return Ep.Average=r,Ep}var Op={},Qj;function vee(){if(Qj)return Op;Qj=1,Object.defineProperty(Op,"__esModule",{value:!0}),Op.Count=void 0;const t=Yi(),e=ss();let u=class rB extends e.AggregatorComponent{constructor(){super(...arguments),this.state=void 0}static emptyValue(){return(0,t.integer)(0).toRDF()}put(){this.state===void 0&&(this.state=0),this.state++}result(){return this.state===void 0?rB.emptyValue():(0,t.integer)(this.state).toRDF()}};return Op.Count=u,Op}var Rp={},Vj;function wee(){if(Vj)return Rp;Vj=1,Object.defineProperty(Rp,"__esModule",{value:!0}),Rp.GroupConcat=void 0;const t=Yi(),e=ss();let u=class nB extends e.AggregatorComponent{constructor(){super(...arguments),this.state=void 0,this.lastLanguageValid=!0,this.lastLanguage=void 0}static emptyValue(){return(0,t.string)("").toRDF()}put(n){this.state===void 0?(this.state=n.value,n.termType==="Literal"&&(this.lastLanguage=n.language)):(this.state+=this.separator+n.value,this.lastLanguageValid&&n.termType==="Literal"&&this.lastLanguage!==n.language&&(this.lastLanguageValid=!1,this.lastLanguage=void 0))}result(){return this.state===void 0?nB.emptyValue():this.lastLanguageValid&&this.lastLanguage?(0,t.langString)(this.state,this.lastLanguage).toRDF():(0,t.string)(this.state).toRDF()}};return Rp.GroupConcat=u,Rp}var xp={},kj;function See(){if(kj)return xp;kj=1,Object.defineProperty(xp,"__esModule",{value:!0}),xp.Max=void 0;const t=Kb(),e=ss();let u=class iB extends e.AggregatorComponent{constructor(){super(...arguments),this.state=void 0}put(n){if(n.termType!=="Literal")throw new Error(`Term with value ${n.value} has type ${n.termType} and is not a literal`);this.state===void 0?this.state=n:(0,t.orderTypes)(this.state,n)===-1&&(this.state=n)}result(){return this.state===void 0?iB.emptyValue():this.state}};return xp.Max=u,xp}var Ip={},zj;function Tee(){if(zj)return Ip;zj=1,Object.defineProperty(Ip,"__esModule",{value:!0}),Ip.Min=void 0;const t=Kb(),e=ss();let u=class aB extends e.AggregatorComponent{constructor(){super(...arguments),this.state=void 0}put(n){if(n.termType!=="Literal")throw new Error(`Term with value ${n.value} has type ${n.termType} and is not a literal`);this.state===void 0?this.state=n:(0,t.orderTypes)(this.state,n)===1&&(this.state=n)}result(){return this.state===void 0?aB.emptyValue():this.state}};return Ip.Min=u,Ip}var Pp={},Gj;function Aee(){if(Gj)return Pp;Gj=1,Object.defineProperty(Pp,"__esModule",{value:!0}),Pp.Sample=void 0;const t=ss();let e=class sB extends t.AggregatorComponent{constructor(){super(...arguments),this.state=void 0}put(s){this.state===void 0&&(this.state=s)}result(){return this.state===void 0?sB.emptyValue():this.state}};return Pp.Sample=e,Pp}var Dp={},Wj;function Eee(){if(Wj)return Dp;Wj=1,Object.defineProperty(Dp,"__esModule",{value:!0}),Dp.Sum=void 0;const t=uu(),e=Yi(),u=Cn(),s=ss();let n=class oB extends s.AggregatorComponent{constructor(){super(...arguments),this.state=void 0,this.summer=t.regularFunctions[u.RegularOperator.ADDITION]}static emptyValue(){return(0,e.integer)(0).toRDF()}put(a){if(this.state===void 0)this.state=this.termToNumericOrError(a);else{const o=this.termToNumericOrError(a);this.state=this.summer.apply([this.state,o],this.sharedContext)}}result(){return this.state===void 0?oB.emptyValue():this.state.toRDF()}};return Dp.Sum=n,Dp}var Jj;function Oee(){if(Jj)return Ap;Jj=1,Object.defineProperty(Ap,"__esModule",{value:!0}),Ap.aggregators=void 0;const t=_ee(),e=vee(),u=wee(),s=See(),n=Tee(),r=Aee(),a=Eee();return Ap.aggregators={count:e.Count,sum:a.Sum,min:n.Min,max:s.Max,avg:t.Average,group_concat:u.GroupConcat,sample:r.Sample},Ap}var Np={},Xj;function Ree(){if(Xj)return Np;Xj=1,Object.defineProperty(Np,"__esModule",{value:!0}),Np.WildcardCountAggregator=void 0;const t=er(),e=Yi();let u=class{constructor(n){this.bindingValues=new Map,this.counter=0,this.distinct=n.distinct}putBindings(n){this.handleDistinct(n)||(this.counter+=1)}static emptyValue(){return(0,e.integer)(0).toRDF()}result(){return(0,e.integer)(this.counter).toRDF()}handleDistinct(n){if(this.distinct){const r=[...n];r.sort((d,h)=>d[0].value.localeCompare(h[0].value));const a=r.map(([d])=>d.value).join(","),o=r.map(([,d])=>t.termToString(d)).join(","),l=this.bindingValues.get(a),c=l!==void 0&&l.has(o);return l||this.bindingValues.set(a,new Set),this.bindingValues.get(a).add(o),c}return!1}};return Np.WildcardCountAggregator=u,Np}var Kj;function uB(){if(Kj)return Tp;Kj=1,Object.defineProperty(Tp,"__esModule",{value:!0}),Tp.BaseAggregateEvaluator=void 0;const t=Ot(),e=Oee(),u=ss(),s=Ree(),n=on();let r=class{constructor(o,l,c){this.throwError=!1,this.isWildcard=!1,this.errorOccurred=!1,this.expression=o,this.aggregator=new u.Aggregator(o,new e.aggregators[o.aggregator](o,l)),this.throwError=c??!1,this.isWildcard=o.expression.expressionType===t.Algebra.expressionTypes.WILDCARD,this.isWildcard&&(this.wildcardAggregator=new s.WildcardCountAggregator(o))}static emptyValue(o,l=!1){let c;if(o.expression.expressionType===t.Algebra.expressionTypes.WILDCARD?c=s.WildcardCountAggregator.emptyValue():c=u.Aggregator.emptyValue(e.aggregators[o.aggregator]),c===void 0&&l)throw new n.EmptyAggregateError;return c}result(){if(!this.errorOccurred)return this.isWildcard?this.wildcardAggregator.result():this.aggregator.result()}};return Tp.BaseAggregateEvaluator=r,Tp}var Yj;function xee(){if(Yj)return Sp;Yj=1,Object.defineProperty(Sp,"__esModule",{value:!0}),Sp.AggregateEvaluator=void 0;const t=uB(),e=eB();let u=class extends t.BaseAggregateEvaluator{constructor(n,r,a){super(n,e.SyncEvaluator.completeContext(r??{}),a),this.evaluator=new e.SyncEvaluator(n.expression,r)}put(n){if(!this.errorOccurred)if(this.isWildcard)this.wildcardAggregator.putBindings(n);else try{const r=this.evaluator.evaluate(n);this.aggregator.put(r)}catch(r){this.safeThrow(r)}}safeThrow(n){if(this.throwError)throw n;this.errorOccurred=!0}};return Sp.AggregateEvaluator=u,Sp}var Cp={},Zj;function Iee(){if(Zj)return Cp;Zj=1,Object.defineProperty(Cp,"__esModule",{value:!0}),Cp.AsyncAggregateEvaluator=void 0;const t=Y7(),e=uB();let u=class extends e.BaseAggregateEvaluator{constructor(n,r,a){super(n,t.AsyncEvaluator.completeContext(r??{}),a),this.evaluator=new t.AsyncEvaluator(n.expression,r),this.errorOccurred=!1}async put(n){if(!this.errorOccurred)if(this.isWildcard)this.wildcardAggregator.putBindings(n);else try{const r=await this.evaluator.evaluate(n);if(!r||this.errorOccurred)return;this.aggregator.put(r)}catch(r){this.safeThrow(r)}}safeThrow(n){if(this.throwError)throw n;this.errorOccurred=!0}};return Cp.AsyncAggregateEvaluator=u,Cp}var eL;function cu(){return eL||(eL=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.AsyncAggregateEvaluator=t.orderTypes=t.isExpressionError=t.ExpressionError=t.AggregateEvaluator=t.SyncEvaluator=t.AsyncEvaluator=void 0;var e=Y7();Object.defineProperty(t,"AsyncEvaluator",{enumerable:!0,get:function(){return e.AsyncEvaluator}});var u=eB();Object.defineProperty(t,"SyncEvaluator",{enumerable:!0,get:function(){return u.SyncEvaluator}});var s=xee();Object.defineProperty(t,"AggregateEvaluator",{enumerable:!0,get:function(){return s.AggregateEvaluator}});var n=on();Object.defineProperty(t,"ExpressionError",{enumerable:!0,get:function(){return n.ExpressionError}}),Object.defineProperty(t,"isExpressionError",{enumerable:!0,get:function(){return n.isExpressionError}});var r=Kb();Object.defineProperty(t,"orderTypes",{enumerable:!0,get:function(){return r.orderTypes}});var a=Iee();Object.defineProperty(t,"AsyncAggregateEvaluator",{enumerable:!0,get:function(){return a.AsyncAggregateEvaluator}})}(Gw)),Gw}var tL;function Pee(){if(tL)return Qh;tL=1,Object.defineProperty(Qh,"__esModule",{value:!0}),Qh.ActorQueryOperationExtend=void 0;const t=xr(),e=wt(),u=cu();let s=class extends e.ActorQueryOperationTypedMediated{constructor(r){super(r,"extend")}async testOperation(r,a){const o=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,a);return new u.AsyncEvaluator(r.expression,e.ActorQueryOperation.getAsyncExpressionContext(a,this.mediatorQueryOperation,o)),!0}async runOperation(r,a){const{expression:o,input:l,variable:c}=r,d=e.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:l,context:a}));if((await d.metadata()).variables.some(m=>m.equals(c)))throw new Error(`Illegal binding to variable '${c.value}' that has already been bound`);const h=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,a),f={...e.ActorQueryOperation.getAsyncExpressionContext(a,this.mediatorQueryOperation,h)},p=new u.AsyncEvaluator(o,f),y=async(m,g,v)=>{try{const _=await p.evaluate(m),w=m.set(c,_);v(w)}catch(_){(0,u.isExpressionError)(_)?(v(m),this.logWarn(a,`Expression error for extend operation (${_.message})with bindings '${(0,t.bindingsToString)(m)}'`)):b.emit("error",_)}g()},b=d.bindingsStream.transform({autoStart:!1,transform:y});return{type:"bindings",bindingsStream:b,async metadata(){const m=await d.metadata();return{...m,variables:[...m.variables,c]}}}}};return Qh.ActorQueryOperationExtend=s,Qh}var rL;function Dee(){return rL||(rL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Pee(),t)}(zw)),zw}var tS={},jp={},nL;function Nee(){if(nL)return jp;nL=1,Object.defineProperty(jp,"__esModule",{value:!0}),jp.ActorQueryOperationFilter=void 0;const t=xr(),e=wt(),u=cu();let s=class extends e.ActorQueryOperationTypedMediated{constructor(r){super(r,"filter")}async testOperation(r,a){const o=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,a),l={...e.ActorQueryOperation.getAsyncExpressionContext(a,this.mediatorQueryOperation,o)};return new u.AsyncEvaluator(r.expression,l),!0}async runOperation(r,a){const o=await this.mediatorQueryOperation.mediate({operation:r.input,context:a}),l=e.ActorQueryOperation.getSafeBindings(o);e.ActorQueryOperation.validateQueryOutput(l,"bindings");const c=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,a),d={...e.ActorQueryOperation.getAsyncExpressionContext(a,this.mediatorQueryOperation,c)},h=new u.AsyncEvaluator(r.expression,d),f=async(y,b,m)=>{try{await h.evaluateAsEBV(y)&&m(y)}catch(g){(0,u.isExpressionError)(g)?this.logWarn(a,"Error occurred while filtering.",()=>({error:g,bindings:(0,t.bindingsToString)(y)})):p.emit("error",g)}b()},p=l.bindingsStream.transform({transform:f,autoStart:!1});return{type:"bindings",bindingsStream:p,metadata:l.metadata}}};return jp.ActorQueryOperationFilter=s,jp}var iL;function Cee(){return iL||(iL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Nee(),t)}(tS)),tS}var rS={},Lp={},Mp={},aL;function jee(){if(aL)return Mp;aL=1,Object.defineProperty(Mp,"__esModule",{value:!0}),Mp.GroupsState=void 0;const t=cu(),e=Et(),u=new e.DataFactory;let s=class{constructor(r,a,o,l){this.hashFunction=r,this.pattern=a,this.sparqleeConfig=o,this.bindingsFactory=l,this.groups=new Map,this.groupsInitializer=new Map,this.groupVariables=new Set(this.pattern.variables.map(c=>c.value)),this.waitCounter=1,this.resultHasBeenCalled=!1}consumeBindings(r){const a=this.resultCheck();if(a)return a;this.waitCounter++;const o=r.filter((h,f)=>this.groupVariables.has(f.value)),l=this.hashBindings(o);let c=this.groupsInitializer.get(l),d;if(c){const h=c;d=(async()=>{const f=await h;await Promise.all(this.pattern.aggregates.map(async p=>{const y=p.variable.value;await f.aggregators[y].put(r)}))})().then(async()=>{this.subtractWaitCounterAndCollect()})}else c=(async()=>{const h={};await Promise.all(this.pattern.aggregates.map(async p=>{const y=p.variable.value;h[y]=new t.AsyncAggregateEvaluator(p,this.sparqleeConfig),await h[y].put(r)}));const f={aggregators:h,bindings:o};return this.groups.set(l,f),this.subtractWaitCounterAndCollect(),f})(),this.groupsInitializer.set(l,c),d=c;return d}subtractWaitCounterAndCollect(){--this.waitCounter===0&&this.handleResultCollection()}handleResultCollection(){let r=[...this.groups].map(([a,o])=>{const{bindings:l,aggregators:c}=o;let d=l;for(const h in c){const f=c[h].result();f&&(d=d.set(u.variable(h),f))}return d});if(r.length===0&&this.groupVariables.size===0){const a=[];for(const o of this.pattern.aggregates){const l=o.variable,c=t.AsyncAggregateEvaluator.emptyValue(o);c!==void 0&&a.push([l,c])}r=[this.bindingsFactory.bindings(a)]}this.waitResolver(r)}resultCheck(){if(this.resultHasBeenCalled)return Promise.reject(new Error("Calling any function after calling collectResult is invalid."))}collectResults(){const r=this.resultCheck();if(r)return r;this.resultHasBeenCalled=!0;const a=new Promise(o=>{this.waitResolver=o});return this.subtractWaitCounterAndCollect(),a}hashBindings(r){return this.hashFunction(r)}};return Mp.GroupsState=s,Mp}var sL;function Lee(){if(sL)return Lp;sL=1,Object.defineProperty(Lp,"__esModule",{value:!0}),Lp.ActorQueryOperationGroup=void 0;const t=xr(),e=wt(),u=cu(),s=Nt(),n=jee();let r=class extends e.ActorQueryOperationTypedMediated{constructor(o){super(o,"group")}async testOperation(o,l){const c=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,l);for(const d of o.aggregates)new u.AsyncEvaluator(d.expression,e.ActorQueryOperation.getAsyncExpressionContext(l,this.mediatorQueryOperation,c));return!0}async runOperation(o,l){const c=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,l),{hashFunction:d}=await this.mediatorHashBindings.mediate({allowHashCollisions:!0,context:l}),{input:h,aggregates:f}=o,p=await this.mediatorQueryOperation.mediate({operation:h,context:l}),y=e.ActorQueryOperation.getSafeBindings(p),b=[...o.variables,...f.map(v=>v.variable)],m=e.ActorQueryOperation.getAsyncExpressionContext(l,this.mediatorQueryOperation,c);return{type:"bindings",bindingsStream:new s.TransformIterator(()=>new Promise((v,_)=>{const w=new n.GroupsState(d,o,m,c);y.bindingsStream.on("end",async()=>{try{const S=new s.ArrayIterator(await w.collectResults(),{autoStart:!1});v(S)}catch(S){_(S)}}),y.bindingsStream.on("error",_),y.bindingsStream.on("data",S=>{w.consumeBindings(S).catch(_)})}),{autoStart:!1}),metadata:async()=>({...await y.metadata(),variables:b})}}};return Lp.ActorQueryOperationGroup=r,Lp}var oL;function Mee(){return oL||(oL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Lee(),t)}(rS)),rS}var nS={},Fp={},uL;function Fee(){if(uL)return Fp;uL=1,Object.defineProperty(Fp,"__esModule",{value:!0}),Fp.ActorQueryOperationLeftJoin=void 0;const t=xr(),e=wt(),u=cu();let s=class extends e.ActorQueryOperationTypedMediated{constructor(r){super(r,"leftjoin")}async testOperation(r,a){return!0}async runOperation(r,a){const o=(await Promise.all(r.input.map(async c=>({output:await this.mediatorQueryOperation.mediate({operation:c,context:a}),operation:c})))).map(({output:c,operation:d})=>({output:e.ActorQueryOperation.getSafeBindings(c),operation:d})),l=await this.mediatorJoin.mediate({type:"optional",entries:o,context:a});if(r.expression){const d=(await o[1].output.metadata()).variables,h=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,a),f={...e.ActorQueryOperation.getAsyncExpressionContext(a,this.mediatorQueryOperation,h)},p=new u.AsyncEvaluator(r.expression,f),y=l.bindingsStream.transform({autoStart:!1,transform:async(b,m,g)=>{if(!d.every(v=>b.has(v.value)))return g(b),m();try{await p.evaluateAsEBV(b)&&g(b)}catch(v){(0,u.isExpressionError)(v)?this.logWarn(a,"Error occurred while filtering.",()=>({error:v,bindings:b})):y.emit("error",v)}m()}});l.bindingsStream=y}return l}};return Fp.ActorQueryOperationLeftJoin=s,Fp}var cL;function qee(){return cL||(cL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Fee(),t)}(nS)),nS}var iS={},qp={},lL;function Bee(){if(lL)return qp;lL=1,Object.defineProperty(qp,"__esModule",{value:!0}),qp.ActorQueryOperationNop=void 0;const t=xr(),e=wt(),u=jn(),s=Nt();let n=class extends e.ActorQueryOperationTypedMediated{constructor(a){super(a,"nop")}async testOperation(a,o){return!0}async runOperation(a,o){const l=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,o);return{bindingsStream:new s.SingletonIterator(l.bindings()),metadata:()=>Promise.resolve({state:new u.MetadataValidationState,cardinality:{type:"exact",value:1},canContainUndefs:!1,variables:[]}),type:"bindings"}}};return qp.ActorQueryOperationNop=n,qp}var dL;function Uee(){return dL||(dL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Bee(),t)}(iS)),iS}var aS={},Bp={},Up={},fL;function Hee(){if(fL)return Up;fL=1,Object.defineProperty(Up,"__esModule",{value:!0}),Up.SortIterator=void 0;const t=Nt();let e=class extends t.TransformIterator{constructor(s,n,r){super(s,r);const a=r&&r.window;this.windowLength=Number.isFinite(a)&&a>0?a:Number.POSITIVE_INFINITY,this.sort=n,this.sorted=[]}_read(s,n){let r,{length:a}=this.sorted;for(;a!==this.windowLength&&(r=this.source.read(),r!==null);){let o=0,l=a-1,c,d;for(;o<=l;)c=Math.trunc((o+l)/2),d=this.sort(r,this.sorted[c]),d<0?o=c+1:d>0?l=c-1:(o=c,l=-1);this.sorted.splice(o,0,r),a++}a===this.windowLength&&this._push(this.sorted.pop()),n()}_flush(s){let{length:n}=this.sorted;for(;n--;)this._push(this.sorted.pop());s()}};return Up.SortIterator=e,Up}var hL;function $ee(){if(hL)return Bp;hL=1,Object.defineProperty(Bp,"__esModule",{value:!0}),Bp.ActorQueryOperationOrderBy=void 0;const t=xr(),e=wt(),u=cu(),s=Ot(),n=Hee();let r=class extends e.ActorQueryOperationTypedMediated{constructor(o){super(o,"orderby"),this.window=o.window??Number.POSITIVE_INFINITY}async testOperation(o,l){const c=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,l);for(let d of o.expressions)d=this.extractSortExpression(d),new u.AsyncEvaluator(d,e.ActorQueryOperation.getAsyncExpressionContext(l,this.mediatorQueryOperation,c));return!0}async runOperation(o,l){const c=await this.mediatorQueryOperation.mediate({operation:o.input,context:l}),d=e.ActorQueryOperation.getSafeBindings(c),h={window:this.window},f=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,l),p={...e.ActorQueryOperation.getAsyncExpressionContext(l,this.mediatorQueryOperation,f)};let{bindingsStream:y}=d;for(let b=o.expressions.length-1;b>=0;b--){let m=o.expressions[b];const g=this.isAscending(m);m=this.extractSortExpression(m);const v=new u.AsyncEvaluator(m,p),_=async(A,D,L)=>{try{const E=await v.evaluate(A);L({bindings:A,result:E})}catch(E){(0,u.isExpressionError)(E)||y.emit("error",E),L({bindings:A,result:void 0})}D()},w=y.transform({transform:_});y=new n.SortIterator(w,(A,D)=>{let L=(0,u.orderTypes)(A.result,D.result);return g||(L*=-1),L},h).map(({bindings:A})=>A)}return{type:"bindings",bindingsStream:y,metadata:d.metadata}}extractSortExpression(o){const{expressionType:l,operator:c}=o;return l!==s.Algebra.expressionTypes.OPERATOR?o:c==="desc"?o.args[0]:o}isAscending(o){const{expressionType:l,operator:c}=o;return l!==s.Algebra.expressionTypes.OPERATOR?!0:c!=="desc"}};return Bp.ActorQueryOperationOrderBy=r,Bp}var pL;function Qee(){return pL||(pL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u($ee(),t)}(aS)),aS}var sS={},Hp={},yL;function Vee(){if(yL)return Hp;yL=1,Object.defineProperty(Hp,"__esModule",{value:!0}),Hp.ActorQueryOperationService=void 0;const t=xr(),e=wt(),u=jn(),s=Nt();let n=class extends e.ActorQueryOperationTypedMediated{constructor(a){super(a,"service")}async testOperation(a,o){if(a.name.termType!=="NamedNode")throw new Error(`${this.name} can only query services by IRI, while a ${a.name.termType} was given.`);return!0}async runOperation(a,o){const{querySource:l}=await this.mediatorQuerySourceIdentify.mediate({querySourceUnidentified:{value:a.name.value,type:this.forceSparqlEndpoint?"sparql":void 0},context:o});let c;try{c=e.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:e.ActorQueryOperation.assignOperationSource(a.input,l),context:o}))}catch(d){if(a.silent){const h=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,o);c={bindingsStream:new s.SingletonIterator(h.bindings()),type:"bindings",metadata:async()=>({state:new u.MetadataValidationState,cardinality:{type:"exact",value:1},canContainUndefs:!1,variables:[]})},this.logWarn(o,`An error occurred when executing a SERVICE clause: ${d.message}`)}else throw d}return c}};return Hp.ActorQueryOperationService=n,Hp}var bL;function kee(){return bL||(bL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Vee(),t)}(sS)),sS}var oS={},$p={},gL;function zee(){if(gL)return $p;gL=1,Object.defineProperty($p,"__esModule",{value:!0}),$p.ActorQueryOperationValues=void 0;const t=xr(),e=wt(),u=jn(),s=Nt(),n=Et(),r=new n.DataFactory;let a=class extends e.ActorQueryOperationTyped{constructor(l){super(l,"values")}async testOperation(l,c){return!0}async runOperation(l,c){const d=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,c),h=new s.ArrayIterator(l.bindings.map(y=>d.bindings(Object.entries(y).map(([b,m])=>[r.variable(b.slice(1)),m])))),f=l.variables;return{type:"bindings",bindingsStream:h,metadata:()=>Promise.resolve({state:new u.MetadataValidationState,cardinality:{type:"exact",value:l.bindings.length},canContainUndefs:l.bindings.some(y=>f.some(b=>!(`?${b.value}`in y))),variables:f})}}};return $p.ActorQueryOperationValues=a,$p}var mL;function Gee(){return mL||(mL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(zee(),t)}(oS)),oS}var uS={},Qp={},_L;function Wee(){if(_L)return Qp;_L=1,Object.defineProperty(Qp,"__esModule",{value:!0}),Qp.ActorQueryOperationPathOneOrMore=void 0;const t=as(),e=xr(),u=wt(),s=Nt(),n=Ot();let r=class extends t.ActorAbstractPath{constructor(o){super(o,n.Algebra.types.ONE_OR_MORE_PATH)}async runOperation(o,l){const c=await e.BindingsFactory.create(this.mediatorMergeBindingsContext,l),d=await this.isPathArbitraryLengthDistinct(l,o);if(d.operation)return d.operation;l=d.context;const h=o.predicate;if(o.subject.termType!=="Variable"&&o.object.termType==="Variable"){const b=o.object,m=await this.getObjectsPredicateStarEval(o.subject,h.path,b,o.graph,l,!1,c),g=o.graph.termType==="Variable"?[b,o.graph]:[b];return{type:"bindings",bindingsStream:m.bindingsStream,metadata:async()=>({...await m.metadata(),variables:g})}}if(o.subject.termType==="Variable"&&o.object.termType==="Variable"){const b=t.ActorAbstractPath.FACTORY.createDistinct(t.ActorAbstractPath.FACTORY.createPath(o.subject,o.predicate.path,o.object,o.graph)),m=u.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({context:l,operation:b})),g=o.subject,v=o.object,_={},w=new s.MultiTransformIterator(m.bindingsStream,{multiTransform:A=>{const D=A.get(g),L=A.get(v),E=o.graph.termType==="Variable"?A.get(o.graph):o.graph;return new s.TransformIterator(async()=>{const O=new s.BufferedIterator;return await this.getSubjectAndObjectBindingsPredicateStar(g,v,D,L,h.path,E,l,_,{},O,{count:0},c),O.transform({transform(P,j,U){o.graph.termType==="Variable"&&(P=P.set(o.graph,E)),U(P),j()}})},{maxBufferSize:128})},autoStart:!1}),S=o.graph.termType==="Variable"?[g,v,o.graph]:[g,v];return{type:"bindings",bindingsStream:w,metadata:async()=>({...await m.metadata(),variables:S})}}if(o.subject.termType==="Variable"&&o.object.termType!=="Variable")return this.mediatorQueryOperation.mediate({context:l,operation:t.ActorAbstractPath.FACTORY.createPath(o.object,t.ActorAbstractPath.FACTORY.createOneOrMorePath(t.ActorAbstractPath.FACTORY.createInv(h.path)),o.subject,o.graph)});const f=this.generateVariable(),p=u.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({context:l,operation:t.ActorAbstractPath.FACTORY.createPath(o.subject,h,f,o.graph)}));return{type:"bindings",bindingsStream:p.bindingsStream.transform({filter:b=>o.object.equals(b.get(f)),transform(b,m,g){const v=o.graph.termType==="Variable"?c.bindings([[o.graph,b.get(o.graph)]]):c.bindings();g(v),m()}}),metadata:async()=>({...await p.metadata(),variables:o.graph.termType==="Variable"?[o.graph]:[]})}}};return Qp.ActorQueryOperationPathOneOrMore=r,Qp}var vL;function Jee(){return vL||(vL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Wee(),t)}(uS)),uS}var cS={},Vp={},wL;function Xee(){if(wL)return Vp;wL=1,Object.defineProperty(Vp,"__esModule",{value:!0}),Vp.ActorQueryOperationPathZeroOrMore=void 0;const t=as(),e=xr(),u=wt(),s=Nt(),n=er(),r=Ot();let a=class extends t.ActorAbstractPath{constructor(l){super(l,r.Algebra.types.ZERO_OR_MORE_PATH)}async runOperation(l,c){const d=await e.BindingsFactory.create(this.mediatorMergeBindingsContext,c),h=await this.isPathArbitraryLengthDistinct(c,l);if(h.operation)return h.operation;c=h.context;const f=l.predicate,p=this.getPathSources(f),y=l.subject.termType==="Variable",b=l.object.termType==="Variable";if(l.subject.termType==="Variable"&&l.object.termType==="Variable"){const S=this.generateVariable(l),A=this.assignPatternSources(t.ActorAbstractPath.FACTORY.createPattern(l.subject,S,l.object,l.graph),p),D=u.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({context:c,operation:A})),L=l.subject,E=l.object,O=new Set,P={},j=new s.MultiTransformIterator(D.bindingsStream,{multiTransform:M=>{const q=M.get(L),Q=M.get(E),Z=l.graph.termType==="Variable"?M.get(l.graph):l.graph,K=(0,n.termToString)(q)+(0,n.termToString)(Z),fe=(0,n.termToString)(Q)+(0,n.termToString)(Z);return new s.TransformIterator(async()=>{if(O.has(K)&&O.has(fe))return new s.EmptyIterator;const X=new s.BufferedIterator,he={count:0};return O.has(K)||(O.add(K),await this.getSubjectAndObjectBindingsPredicateStar(L,E,q,q,f.path,Z,c,P,{},X,he,d)),O.has(fe)||(O.add(fe),await this.getSubjectAndObjectBindingsPredicateStar(L,E,Q,Q,f.path,Z,c,P,{},X,he,d)),X.transform({transform(xe,ie,ae){l.graph.termType==="Variable"&&(xe=xe.set(l.graph,Z)),ae(xe),ie()}})})}}),U=l.graph.termType==="Variable"?[L,l.object,l.graph]:[L,l.object];return{type:"bindings",bindingsStream:j,metadata:async()=>({...await D.metadata(),variables:U})}}if(!y&&!b){const S=this.generateVariable(),A=await this.getObjectsPredicateStarEval(l.subject,f.path,S,l.graph,c,!0,d);return{type:"bindings",bindingsStream:A.bindingsStream.transform({filter:L=>l.object.equals(L.get(S)),transform(L,E,O){const P=l.graph.termType==="Variable"?d.bindings([[l.graph,L.get(l.graph)]]):d.bindings();O(P),E()}}),metadata:async()=>({...await A.metadata(),variables:l.graph.termType==="Variable"?[l.graph]:[]})}}const m=y?l.object:l.subject,g=y?l.subject:l.object,v=y?t.ActorAbstractPath.FACTORY.createInv(f.path):f.path,_=await this.getObjectsPredicateStarEval(m,v,g,l.graph,c,!0,d),w=l.graph.termType==="Variable"?[g,l.graph]:[g];return{type:"bindings",bindingsStream:_.bindingsStream,metadata:async()=>({...await _.metadata(),variables:w})}}};return Vp.ActorQueryOperationPathZeroOrMore=a,Vp}var SL;function Kee(){return SL||(SL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Xee(),t)}(cS)),cS}var lS={},kp={},TL;function Yee(){if(TL)return kp;TL=1,Object.defineProperty(kp,"__esModule",{value:!0}),kp.ActorQueryOperationPathZeroOrOne=void 0;const t=as(),e=xr(),u=wt(),s=jn(),n=Nt(),r=Ot();let a=class extends t.ActorAbstractPath{constructor(l){super(l,r.Algebra.types.ZERO_OR_ONE_PATH)}async runOperation(l,c){const d=await e.BindingsFactory.create(this.mediatorMergeBindingsContext,c),h=l.predicate,f=this.getPathSources(h),p=[];if(l.subject.termType!=="Variable"&&l.object.termType!=="Variable"&&l.subject.equals(l.object))return{type:"bindings",bindingsStream:new n.SingletonIterator(d.bindings()),metadata:()=>Promise.resolve({state:new s.MetadataValidationState,cardinality:{type:"exact",value:1},canContainUndefs:!1,variables:[]})};const y=await this.isPathArbitraryLengthDistinct(c,l);if(y.operation)return y.operation;c=y.context;const b=u.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({context:c,operation:t.ActorAbstractPath.FACTORY.createPath(l.subject,h.path,l.object,l.graph)}));let m;if(l.subject.termType==="Variable"&&l.object.termType==="Variable"){const g=this.generateVariable(l),v=u.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({context:c,operation:t.ActorAbstractPath.FACTORY.createFilter(this.assignPatternSources(t.ActorAbstractPath.FACTORY.createPattern(l.subject,g,l.object,l.graph),f),t.ActorAbstractPath.FACTORY.createOperatorExpression("=",[t.ActorAbstractPath.FACTORY.createTermExpression(l.subject),t.ActorAbstractPath.FACTORY.createTermExpression(l.object)]))})).bindingsStream.map(_=>_.delete(g));m=new n.UnionIterator([v,b.bindingsStream],{autoStart:!1})}else l.subject.termType==="Variable"&&p.push(d.bindings([[l.subject,l.object]])),l.object.termType==="Variable"&&p.push(d.bindings([[l.object,l.subject]])),m=b.bindingsStream.prepend(p);return{type:"bindings",bindingsStream:m,metadata:b.metadata}}};return kp.ActorQueryOperationPathZeroOrOne=a,kp}var AL;function Zee(){return AL||(AL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Yee(),t)}(lS)),lS}var dS={},zp={},EL;function ete(){if(EL)return zp;EL=1,Object.defineProperty(zp,"__esModule",{value:!0}),zp.ActorQueryOperationUpdateDeleteInsert=void 0;const t=v7(),e=xr(),u=wt(),s=Nt();let n=class extends u.ActorQueryOperationTypedMediated{constructor(a){super(a,"deleteinsert"),this.blankNodeCounter=0}async testOperation(a,o){return u.ActorQueryOperation.throwOnReadOnly(o),!0}async runOperation(a,o){const l=await e.BindingsFactory.create(this.mediatorMergeBindingsContext,o),c=a.where?u.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:a.where,context:o})).bindingsStream:new s.ArrayIterator([l.bindings()],{autoStart:!1});let d,h;a.insert&&(d=new t.BindingsToQuadsIterator(a.insert.map(t.BindingsToQuadsIterator.localizeQuad.bind(null,this.blankNodeCounter)),c.clone()),this.blankNodeCounter++),a.delete&&(h=new t.BindingsToQuadsIterator(a.delete.map(t.BindingsToQuadsIterator.localizeQuad.bind(null,this.blankNodeCounter)),c.clone()),this.blankNodeCounter++);const{execute:f}=await this.mediatorUpdateQuads.mediate({quadStreamInsert:d,quadStreamDelete:h,context:o});return{type:"void",execute:f}}};return zp.ActorQueryOperationUpdateDeleteInsert=n,zp}var OL;function tte(){return OL||(OL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(ete(),t)}(dS)),dS}var fS={},Gp={},hS={},Wp={},RL;function rte(){if(RL)return Wp;RL=1,Object.defineProperty(Wp,"__esModule",{value:!0}),Wp.ActorQueryProcess=void 0;const t=ot;let e=class extends t.Actor{constructor(s){super(s)}};return Wp.ActorQueryProcess=e,Wp}var xL;function Yb(){return xL||(xL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(rte(),t)}(hS)),hS}var IL;function nte(){if(IL)return Gp;IL=1,Object.defineProperty(Gp,"__esModule",{value:!0}),Gp.ActorQueryProcessSequential=void 0;const t=xr(),e=wt(),u=Yb(),s=Lt,n=ot;let r=class extends u.ActorQueryProcess{constructor(o){super(o)}async test(o){if(o.context.get(s.KeysInitQuery.explain)||o.context.get(new n.ActionContextKey("explain")))throw new Error(`${this.name} is not able to explain queries.`);return!0}async run(o){let{operation:l,context:c}=await this.parse(o.query,o.context);return{operation:l,context:c}=await this.optimize(l,c),{result:await this.evaluate(l,c)}}async parse(o,l){l=(await this.mediatorContextPreprocess.mediate({context:l,initialize:!0})).context;let c;if(typeof o=="string"){l=l.set(s.KeysInitQuery.queryString,o);const d=l.get(s.KeysInitQuery.baseIRI),h=l.get(s.KeysInitQuery.queryFormat),f=await this.mediatorQueryParse.mediate({context:l,query:o,queryFormat:h,baseIRI:d});c=f.operation,f.baseIRI&&(l=l.set(s.KeysInitQuery.baseIRI,f.baseIRI))}else c=o;if(l.has(s.KeysInitQuery.initialBindings)){const d=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,l);c=(0,e.materializeOperation)(c,l.get(s.KeysInitQuery.initialBindings),d),l=l.delete(s.KeysInitQuery.queryString)}return{operation:c,context:l}}async optimize(o,l){return l=l.set(s.KeysInitQuery.query,o),{operation:o,context:l}=await this.mediatorOptimizeQueryOperation.mediate({context:l,operation:o}),l=l.set(s.KeysInitQuery.query,o),{operation:o,context:l}}async evaluate(o,l){const c=await this.mediatorQueryOperation.mediate({context:l,operation:o});return c.context=l,c}};return Gp.ActorQueryProcessSequential=r,Gp}var PL;function ite(){return PL||(PL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(nte(),t)}(fS)),fS}var pS={},Jp={},Xp={},Kp={},Yp={},DL;function ate(){if(DL)return Yp;DL=1,Object.defineProperty(Yp,"__esModule",{value:!0}),Yp.LinkedRdfSourcesAsyncRdfIterator=void 0;const t=jn(),e=Nt();let u=class extends e.BufferedIterator{constructor(n,r,a,o,l,c,d,h){if(super({autoStart:!1,...h}),this.started=!1,this.currentIterators=[],this.iteratorsPendingCreation=0,this.iteratorsPendingTermination=0,this.accumulatedMetadata=Promise.resolve(void 0),this._reading=!1,this.cacheSize=n,this.operation=r,this.queryBindingsOptions=a,this.context=o,this.firstUrl=l,this.maxIterators=c,this.sourceStateGetter=d,this.maxIterators<=0)throw new Error(`LinkedRdfSourcesAsyncRdfIterator.maxIterators must be larger than zero, but got ${this.maxIterators}`)}kickstart(){this.started||this._fillBufferAsync()}getProperty(n,r){return n==="metadata"&&!this.started&&(this.preflightMetadata||(this.preflightMetadata=new Promise((a,o)=>{this.sourceStateGetter({url:this.firstUrl},{}).then(l=>{const c=l.source.queryBindings(this.operation,this.context);c.getProperty("metadata",d=>{d.state=new t.MetadataValidationState,c.destroy(),this.accumulateMetadata(l.metadata,d).then(h=>{const f={...l.metadata,...d,...h};a(f)}).catch(()=>{a({...l.metadata,state:new t.MetadataValidationState})})})}).catch(o)})),this.preflightMetadata.then(a=>this.setProperty("metadata",a)).catch(()=>{})),super.getProperty(n,r)}_end(n){for(const r of this.currentIterators)r.destroy();super._end(n)}_read(n,r){if(this.started){for(const a of this.currentIterators){for(;n>0;){const o=a.read();if(o===null)break;n--,this._push(o)}if(n<=0)break}n>=0&&this.canStartNewIterator()?this.sourceStateGetter({url:this.firstUrl},{}).then(a=>{this.startIteratorsForNextUrls(a.handledDatasets,!1),r()}):r()}else this.started=!0,this.sourceStateGetter({url:this.firstUrl},{}).then(a=>{this.startIterator(a),r()}).catch(a=>setTimeout(()=>this.destroy(a)))}canStartNewIterator(){return this.currentIterators.length+this.iteratorsPendingCreation+this.iteratorsPendingTermination0}startIterator(n){try{const r=n.source.queryBindings(this.operation,this.context,this.queryBindingsOptions);this.currentIterators.push(r);let a=!1,o=!1;r._destination=this,r.on("error",l=>this.destroy(l)),r.on("readable",()=>this._fillBuffer()),r.on("end",()=>{this.currentIterators.splice(this.currentIterators.indexOf(r),1),a=!0,o||this.iteratorsPendingTermination++,o&&this.startIteratorsForNextUrls(n.handledDatasets,!0)}),r.getProperty("metadata",l=>{this.accumulatedMetadata=this.accumulatedMetadata.then(c=>(async()=>(c||(c=n.metadata),this.accumulateMetadata(c,l)))().then(d=>{const h={...n.metadata,...l,...d};return h.state=new t.MetadataValidationState,this.updateMetadata(h),this.preflightMetadata&&this.preflightMetadata.then(f=>f.state.invalidate()).catch(()=>{}),this.getSourceLinks(h).then(f=>Promise.all(f)).then(async f=>{const p=await this.getLinkQueue();for(const y of f)p.push(y,n.link);o=!0,a&&this.iteratorsPendingTermination--,this.startIteratorsForNextUrls(n.handledDatasets,!0)}).catch(f=>this.destroy(f)),h})).catch(c=>(this.destroy(c),{}))})}catch(r){this.destroy(r)}}updateMetadata(n){const r=this.getProperty("metadata");this.setProperty("metadata",n),r==null||r.state.invalidate()}isRunning(){return!this.done}startIteratorsForNextUrls(n,r){this.getLinkQueue().then(a=>{for(;this.canStartNewIterator()&&this.isRunning();){const o=a.pop();if(o)this.iteratorsPendingCreation++,this.sourceStateGetter(o,n).then(l=>{this.iteratorsPendingCreation--,this.startIterator(l)}).catch(l=>this.emit("error",l));else break}r&&this.isCloseable(a,!0)&&this.close()}).catch(a=>this.destroy(a))}isCloseable(n,r){return n.isEmpty()&&!this.areIteratorsRunning()}};return Yp.LinkedRdfSourcesAsyncRdfIterator=u,Yp}var NL;function ste(){if(NL)return Kp;NL=1,Object.defineProperty(Kp,"__esModule",{value:!0}),Kp.MediatedLinkedRdfSourcesAsyncRdfIterator=void 0;const t=Lt,e=Et(),u=Ot(),s=ate(),n=new e.DataFactory,r=new u.Factory;let a=class extends s.LinkedRdfSourcesAsyncRdfIterator{constructor(l,c,d,h,f,p,y,b,m,g,v,_){super(l,c,d,h,p,y,b,m?{maxBufferSize:Number.POSITIVE_INFINITY}:void 0),this.wasForcefullyClosed=!1,this.forceSourceType=f,this.mediatorMetadataAccumulate=g,this.mediatorRdfResolveHypermediaLinks=v,this.mediatorRdfResolveHypermediaLinksQueue=_,this.handledUrls={[p]:!0},this.aggregatedStore=m}close(){if(!this.aggregatedStore){super.close();return}this.getLinkQueue().then(l=>{this.isCloseable(l,!1)?(this.aggregatedStore&&setTimeout(()=>this.aggregatedStore.end()),super.close()):this.wasForcefullyClosed=!0}).catch(l=>super.destroy(l))}destroy(l){if(!this.aggregatedStore){super.destroy(l);return}this.getLinkQueue().then(c=>{l??this.isCloseable(c,!1)?(this.aggregatedStore&&setTimeout(()=>this.aggregatedStore.end()),super.destroy(l)):this.wasForcefullyClosed=!0}).catch(c=>super.destroy(c))}isCloseable(l,c){return(c?l.isEmpty():this.wasForcefullyClosed||l.isEmpty())&&!this.areIteratorsRunning()}canStartNewIterator(){return!this.wasForcefullyClosed&&this.aggregatedStore&&this.aggregatedStore.hasRunningIterators()||super.canStartNewIterator()}canStartNewIteratorConsiderReadable(){return!this.aggregatedStore}isRunning(){return this.aggregatedStore&&this.aggregatedStore.hasRunningIterators()||!this.done}getLinkQueue(){return this.linkQueue||(this.linkQueue=this.mediatorRdfResolveHypermediaLinksQueue.mediate({firstUrl:this.firstUrl,context:this.context}).then(l=>l.linkQueue)),this.linkQueue}async getSourceLinks(l){try{const{links:c}=await this.mediatorRdfResolveHypermediaLinks.mediate({context:this.context,metadata:l});return c.filter(d=>this.handledUrls[d.url]?!1:(this.handledUrls[d.url]=!0,!0))}catch{return[]}}startIterator(l){var c;if(this.aggregatedStore&&!this.aggregatedStore.containedSources.has(l.link.url)){(c=this.aggregatedStore)==null||c.containedSources.add(l.link.url);const d=l.source.queryBindings(r.createPattern(n.variable("s"),n.variable("p"),n.variable("o"),n.variable("g")),this.context.set(t.KeysQueryOperation.unionDefaultGraph,!0)).map(h=>n.quad(h.get("s"),h.get("p"),h.get("o"),h.get("g")));this.aggregatedStore.import(d).on("end",()=>{super.startIterator(l)})}else super.startIterator(l)}async accumulateMetadata(l,c){return(await this.mediatorMetadataAccumulate.mediate({mode:"append",accumulatedMetadata:l,appendingMetadata:c,context:this.context})).metadata}updateMetadata(l){var c;super.updateMetadata(l),(c=this.aggregatedStore)==null||c.setBaseMetadata(l,!0)}};return Kp.MediatedLinkedRdfSourcesAsyncRdfIterator=a,Kp}var Zp={},yS={},e0={},CL;function cB(){if(CL)return e0;CL=1,Object.defineProperty(e0,"__esModule",{value:!0}),e0.PendingStreamsIndex=void 0;const t=er(),e=un();let u=class Ms{constructor(){this.indexedStreams=new Map,this.allStreams=[]}termToString(n){return n&&n.termType!=="Variable"?(0,t.termToString)(n):Ms.ID_VARIABLE}addPatternListener(n,r,a,o,l){this.allStreams.push(n);const c=`${this.termToString(r)}${Ms.ID_SEPARATOR}${this.termToString(a)}${Ms.ID_SEPARATOR}${this.termToString(o)}${Ms.ID_SEPARATOR}${this.termToString(l)}`;let d=this.indexedStreams.get(c);d||(d=[],this.indexedStreams.set(c,d)),d.push(n)}getPendingStreamsForQuad(n){let r=[(0,e.getTerms)(n).map(o=>(0,t.termToString)(o))];for(let o=0;o{if(!this.ended&&!this.store.countQuads(a.subject,a.predicate,a.object,a.graph))for(const o of this.pendingStreams.getPendingStreamsForQuad(a))o.isInitialized&&(o.push(a),o.emit("quad",a))})}import(r){if(this.ended)throw new Error("Attempted to import into an ended StreamingStore");return this.importToListeners(r),this.store.import(r)}match(r,a,o,l){const c=this.store.match(r,a,o,l);let d=c;if(!this.ended){const h=new e.PassThrough({objectMode:!0});this.pendingStreams.addPatternListener(h,r,a,o,l),d=c.pipe(h,{end:!1}),d._pipeSource=c;const f=c._read;c._read=p=>{h.isInitialized=!0,f.call(c,p)}}return d}getStore(){return this.store}};return t0.StreamingStore=s,t0}var LL;function ute(){return LL||(LL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(cB(),t),u(ote(),t)}(yS)),yS}var ML;function cte(){if(ML)return Zp;ML=1,Object.defineProperty(Zp,"__esModule",{value:!0}),Zp.StreamingStoreMetadata=void 0;const t=wt(),e=jn(),u=ute();let s=class extends u.StreamingStore{constructor(r,a){super(r),this.started=!1,this.containedSources=new Set,this.runningIterators=new Set,this.iteratorCreatedListeners=new Set,this.baseMetadata={state:new e.MetadataValidationState,cardinality:{type:"exact",value:0},canContainUndefs:!1,variables:[]},this.metadataAccumulator=a}import(r){return this.ended||super.import(r),r}hasRunningIterators(){return this.runningIterators.size>0}match(r,a,o,l){const c=super.match(r,a,o,l),d=new t.ClosableTransformIterator(c,{autoStart:!1,onClose:()=>{this.runningIterators.delete(d)}});let h=this.getStore().countQuads(r,a,o,l);const f={state:new e.MetadataValidationState,cardinality:{type:"estimate",value:h},canContainUndefs:!1};d.setProperty("metadata",f),d.setProperty("lastCount",h),c.on("quad",()=>{d.setProperty("lastCount",++h),this.updateMetadataState(d,h)}),this.runningIterators.add(d);for(const p of this.iteratorCreatedListeners)p();return d}setBaseMetadata(r,a){if(this.baseMetadata={...r},this.baseMetadata.cardinality={type:"exact",value:0},a)for(const o of this.runningIterators){const l=o.getProperty("lastCount");this.updateMetadataState(o,l)}}updateMetadataState(r,a){const o={state:new e.MetadataValidationState,cardinality:{type:"estimate",value:a},canContainUndefs:!1,variables:[]};this.metadataAccumulator(this.baseMetadata,o).then(l=>{l.state=new e.MetadataValidationState;const c=r.getProperty("metadata");r.setProperty("metadata",l),c==null||c.state.invalidate()}).catch(()=>{})}addIteratorCreatedListener(r){this.iteratorCreatedListeners.add(r)}removeIteratorCreatedListener(r){this.iteratorCreatedListeners.delete(r)}};return Zp.StreamingStoreMetadata=s,Zp}var FL;function lB(){if(FL)return Xp;FL=1,Object.defineProperty(Xp,"__esModule",{value:!0}),Xp.QuerySourceHypermedia=void 0;const t=rA(),e=Lt,u=Nt(),s=is(),n=Wt(),r=ste(),a=cte();let o=class{constructor(c,d,h,f,p,y,b,m){this.referenceValue=d,this.cacheSize=c,this.firstUrl=d,this.forceSourceType=h,this.maxIterators=f,this.mediators=y,this.aggregateStore=p,this.logWarning=b,this.bindingsFactory=m,this.sourcesState=new s.LRUCache({max:this.cacheSize})}async getSelectorShape(c){return(await this.getSourceCached({url:this.firstUrl},{},c,this.getAggregateStore(c))).source.getSelectorShape(c)}queryBindings(c,d,h){const f=this.getAggregateStore(d);if(f&&c.type==="pattern"&&f.started)return new t.QuerySourceRdfJs(f,this.bindingsFactory).queryBindings(c,d);this.sourcesState.size===0&&this.getSourceCached({url:this.firstUrl},{},d,f).catch(y=>p.destroy(y));const p=new r.MediatedLinkedRdfSourcesAsyncRdfIterator(this.cacheSize,c,h,d,this.forceSourceType,this.firstUrl,this.maxIterators,(y,b)=>this.getSourceCached(y,b,d,f),f,this.mediators.mediatorMetadataAccumulate,this.mediators.mediatorRdfResolveHypermediaLinks,this.mediators.mediatorRdfResolveHypermediaLinksQueue);if(f){f.started=!0;const y=()=>p.kickstart();f.addIteratorCreatedListener(y),p.on("end",()=>f.removeIteratorCreatedListener(y))}return p}queryQuads(c,d){return new u.TransformIterator(async()=>(await this.getSourceCached({url:this.firstUrl},{},d,this.getAggregateStore(d))).source.queryQuads(c,d))}async queryBoolean(c,d){return await(await this.getSourceCached({url:this.firstUrl},{},d,this.getAggregateStore(d))).source.queryBoolean(c,d)}async queryVoid(c,d){return await(await this.getSourceCached({url:this.firstUrl},{},d,this.getAggregateStore(d))).source.queryVoid(c,d)}async getSource(c,d,h,f){var v;c.context&&(h=h.merge(c.context));let p=c.url,y,b;try{const _=await this.mediators.mediatorDereferenceRdf.mediate({context:h,url:p});p=_.url;const w=await this.mediators.mediatorMetadata.mediate({context:h,url:p,quads:_.data,triples:(v=_.metadata)==null?void 0:v.triples});w.data.on("error",()=>{}),b=(await this.mediators.mediatorMetadataExtract.mediate({context:h,url:p,metadata:w.metadata,headers:_.headers,requestTime:_.requestTime})).metadata,y=w.data,c.transform&&(y=await c.transform(y))}catch(_){y=new n.Readable,y.read=()=>(setTimeout(()=>y.emit("error",_)),null),{metadata:b}=await this.mediators.mediatorMetadataAccumulate.mediate({context:h,mode:"initialize"}),this.logWarning(`Metadata extraction for ${p} failed: ${_.message}`)}f==null||f.setBaseMetadata(b,!1),f==null||f.containedSources.add(c.url),f==null||f.import(y);const{source:m,dataset:g}=await this.mediators.mediatorQuerySourceIdentifyHypermedia.mediate({context:h,forceSourceType:c.url===this.firstUrl?this.forceSourceType:void 0,handledDatasets:d,metadata:b,quads:y,url:p});return g&&(d[g]=!0),{link:c,source:m,metadata:b,handledDatasets:d}}getSourceCached(c,d,h,f){let p=this.sourcesState.get(c.url);return p||(p=this.getSource(c,d,h,f),(c.url===this.firstUrl||f===void 0)&&this.sourcesState.set(c.url,p),p)}getAggregateStore(c){let d;if(this.aggregateStore){const h=c.get(e.KeysQuerySourceIdentify.hypermediaSourcesAggregatedStores);if(h)return d=h.get(this.firstUrl),d||(d=new a.StreamingStoreMetadata(void 0,async(f,p)=>(await this.mediators.mediatorMetadataAccumulate.mediate({mode:"append",accumulatedMetadata:f,appendingMetadata:p,context:c})).metadata),h.set(this.firstUrl,d)),d}}toString(){return`QuerySourceHypermedia(${this.firstUrl})`}};return Xp.QuerySourceHypermedia=o,Xp}var qL;function lte(){if(qL)return Jp;qL=1,Object.defineProperty(Jp,"__esModule",{value:!0}),Jp.ActorQuerySourceIdentifyHypermedia=void 0;const t=xr(),e=xy(),u=Lt,s=ot,n=lB();let r=class extends e.ActorQuerySourceIdentify{constructor(o){super(o)}async test(o){if(typeof o.querySourceUnidentified.value!="string")throw new TypeError(`${this.name} requires a single query source with a URL value to be present in the context.`);return!0}async run(o){var l;return{querySource:{source:new n.QuerySourceHypermedia(this.cacheSize,o.querySourceUnidentified.value,o.querySourceUnidentified.type,this.maxIterators,this.aggregateTraversalStore&&!!((l=o.querySourceUnidentified.context)!=null&&l.get(u.KeysQuerySourceIdentify.traverse)),{mediatorMetadata:this.mediatorMetadata,mediatorMetadataExtract:this.mediatorMetadataExtract,mediatorMetadataAccumulate:this.mediatorMetadataAccumulate,mediatorDereferenceRdf:this.mediatorDereferenceRdf,mediatorQuerySourceIdentifyHypermedia:this.mediatorQuerySourceIdentifyHypermedia,mediatorRdfResolveHypermediaLinks:this.mediatorRdfResolveHypermediaLinks,mediatorRdfResolveHypermediaLinksQueue:this.mediatorRdfResolveHypermediaLinksQueue},c=>this.logWarn(o.context,c),await t.BindingsFactory.create(this.mediatorMergeBindingsContext,o.context)),context:o.querySourceUnidentified.context??new s.ActionContext}}}};return Jp.ActorQuerySourceIdentifyHypermedia=r,Jp}var BL;function dte(){return BL||(BL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(lte(),t),u(lB(),t)}(pS)),pS}var bS={},r0={},UL;function fte(){if(UL)return r0;UL=1,Object.defineProperty(r0,"__esModule",{value:!0}),r0.ActorRdfJoinNone=void 0;const t=xr(),e=Ln(),u=jn(),s=Nt();let n=class extends e.ActorRdfJoin{constructor(a){super(a,{logicalType:"inner",physicalName:"none",limitEntries:0})}async test(a){if(a.entries.length>0)throw new Error(`Actor ${this.name} can only join zero entries`);return await this.getJoinCoefficients()}async getOutput(a){const o=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,a.context);return{result:{bindingsStream:new s.ArrayIterator([o.bindings()],{autoStart:!1}),metadata:()=>Promise.resolve({state:new u.MetadataValidationState,cardinality:{type:"exact",value:1},canContainUndefs:!1,variables:[]}),type:"bindings"}}}async getJoinCoefficients(){return{iterations:0,persistedItems:0,blockingItems:0,requestTime:0}}};return r0.ActorRdfJoinNone=n,r0}var HL;function hte(){return HL||(HL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(fte(),t)}(bS)),bS}var gS={},n0={},$L;function pte(){if($L)return n0;$L=1,Object.defineProperty(n0,"__esModule",{value:!0}),n0.ActorRdfJoinMultiBind=void 0;const t=xr(),e=wt(),u=Ln(),s=Lt,n=Nt(),r=Ot();let a=class m3 extends u.ActorRdfJoin{constructor(l){super(l,{logicalType:"inner",physicalName:"bind",canHandleUndefs:!0,isLeaf:!1})}static createBindStream(l,c,d,h,f,p){const y=l==="depth-first",b=m=>{const g=d.map(_=>(0,e.materializeOperation)(_,m,p,{bindFilter:!0})),v=_=>_.merge(m);return new n.TransformIterator(async()=>(await h(g,m)).transform({map:v}),{maxBufferSize:128,autoStart:y})};switch(l){case"depth-first":return new n.MultiTransformIterator(c,{autoStart:!1,multiTransform:b,optional:f});case"breadth-first":return new n.UnionIterator(c.transform({map:b,optional:f}),{autoStart:!1});default:throw new Error(`Received request for unknown bind order: ${l}`)}}async getOutput(l){const c=await t.BindingsFactory.create(this.mediatorMergeBindingsContext,l.context),d=await u.ActorRdfJoin.getEntriesWithMetadatas(l.entries),h=await u.ActorRdfJoin.sortJoinEntries(this.mediatorJoinEntriesSort,d,l.context);this.logDebug(l.context,"First entry for Bind Join: ",()=>({entry:h[0].operation,metadata:h[0].metadata}));for(const[m,g]of h.entries())m!==0&&g.output.bindingsStream.close();const f=h[0].output,p=[...h];p.splice(0,1);const y=l.context.set(s.KeysQueryOperation.joinLeftMetadata,h[0].metadata).set(s.KeysQueryOperation.joinRightMetadatas,p.map(m=>m.metadata));return{result:{type:"bindings",bindingsStream:m3.createBindStream(this.bindOrder,f.bindingsStream,p.map(m=>m.operation),async(m,g)=>{const v=m.length===1?m[0]:m3.FACTORY.createJoin(m);return e.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:v,context:y==null?void 0:y.set(s.KeysQueryOperation.joinBindings,g)})).bindingsStream},!1,c),metadata:()=>this.constructResultMetadata(h,h.map(m=>m.metadata),l.context)},physicalPlanMetadata:{bindIndex:d.indexOf(h[0]),bindOperation:h[0].operation,bindOperationCardinality:h[0].metadata.cardinality,bindOrder:this.bindOrder}}}canBindWithOperation(l){let c=!0;return r.Util.recurseOperation(l,{[r.Algebra.types.EXTEND](){return c=!1,!1},[r.Algebra.types.GROUP](){return c=!1,!1}}),c}async getJoinCoefficients(l,c){const d=await u.ActorRdfJoin.sortJoinEntries(this.mediatorJoinEntriesSort,l.entries.map((w,S)=>({...w,metadata:c[S]})),l.context);c=d.map(w=>w.metadata);const h=u.ActorRdfJoin.getRequestInitialTimes(c),f=u.ActorRdfJoin.getRequestItemTimes(c),p=[...d],y=[...h],b=[...f];if(p.splice(0,1),y.splice(0,1),b.splice(0,1),p.some(w=>!this.canBindWithOperation(w.operation)))throw new Error(`Actor ${this.name} can not bind on Extend and Group operations`);if(p.some(w=>w.operationModified))throw new Error(`Actor ${this.name} can not be used over remaining entries with modified operations`);const m=await Promise.all(p.map(async w=>(await this.mediatorJoinSelectivity.mediate({entries:[d[0],w],context:l.context})).selectivity*this.selectivityModifier)),g=p.map((w,S)=>w.metadata.cardinality.value*m[S]).reduce((w,S)=>w+S,0),v=y.reduce((w,S)=>w+S,0),_=b.reduce((w,S)=>w+S,0);return{iterations:c[0].cardinality.value*g,persistedItems:0,blockingItems:0,requestTime:h[0]+c[0].cardinality.value*(f[0]+v+g*_)}}};return n0.ActorRdfJoinMultiBind=a,a.FACTORY=new r.Factory,n0}var QL;function dB(){return QL||(QL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(pte(),t)}(gS)),gS}var mS={},i0={},VL;function yte(){if(VL)return i0;VL=1,Object.defineProperty(i0,"__esModule",{value:!0}),i0.ActorRdfJoinOptionalBind=void 0;const t=dB(),e=xr(),u=wt(),s=Ln(),n=Lt,r=Ot();let a=class extends s.ActorRdfJoin{constructor(l){super(l,{logicalType:"optional",physicalName:"bind",limitEntries:2,canHandleUndefs:!0,isLeaf:!1})}async getOutput(l){const c=await e.BindingsFactory.create(this.mediatorMergeBindingsContext,l.context);l.entries[1].output.bindingsStream.close();const d=l.context.set(n.KeysQueryOperation.joinLeftMetadata,await l.entries[0].output.metadata()).set(n.KeysQueryOperation.joinRightMetadatas,[await l.entries[1].output.metadata()]);return{result:{type:"bindings",bindingsStream:t.ActorRdfJoinMultiBind.createBindStream(this.bindOrder,l.entries[0].output.bindingsStream,[l.entries[1].operation],async(f,p)=>{const y=f[0];return u.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:y,context:d==null?void 0:d.set(n.KeysQueryOperation.joinBindings,p)})).bindingsStream},!0,c),metadata:async()=>await this.constructResultMetadata(l.entries,await s.ActorRdfJoin.getMetadatas(l.entries),l.context,{canContainUndefs:!0})}}}async getJoinCoefficients(l,c){if(s.ActorRdfJoin.overlappingVariables(c).length===0)throw new Error(`Actor ${this.name} only join entries with at least one common variable`);const d=s.ActorRdfJoin.getRequestInitialTimes(c),h=s.ActorRdfJoin.getRequestItemTimes(c);if(l.entries[1].operation.type===r.Algebra.types.EXTEND||l.entries[1].operation.type===r.Algebra.types.GROUP)throw new Error(`Actor ${this.name} can not bind on Extend and Group operations`);const f=(await this.mediatorJoinSelectivity.mediate({entries:l.entries,context:l.context})).selectivity*this.selectivityModifier;return{iterations:c[0].cardinality.value*c[1].cardinality.value*f,persistedItems:0,blockingItems:0,requestTime:d[0]+c[0].cardinality.value*(h[0]+d[1]+f*c[1].cardinality.value*h[1])}}};return i0.ActorRdfJoinOptionalBind=a,i0}var kL;function bte(){return kL||(kL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(yte(),t)}(mS)),mS}var _S={},a0={},zL;function gte(){if(zL)return a0;zL=1,Object.defineProperty(a0,"__esModule",{value:!0}),a0.ActorQueryProcessExplainParsed=void 0;const t=Yb(),e=Lt,u=ot;let s=class extends t.ActorQueryProcess{constructor(r){super(r)}async test(r){if((r.context.get(e.KeysInitQuery.explain)||r.context.get(new u.ActionContextKey("explain")))!=="parsed")throw new Error(`${this.name} can only explain in 'parsed' mode.`);return!0}async run(r){const{operation:a}=await this.queryProcessor.parse(r.query,r.context);return{result:{explain:!0,type:"parsed",data:a}}}};return a0.ActorQueryProcessExplainParsed=s,a0}var GL;function mte(){return GL||(GL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(gte(),t)}(_S)),_S}var vS={},s0={},WL;function _te(){if(WL)return s0;WL=1,Object.defineProperty(s0,"__esModule",{value:!0}),s0.ActorQueryProcessExplainLogical=void 0;const t=Yb(),e=Lt,u=ot;let s=class extends t.ActorQueryProcess{constructor(r){super(r)}async test(r){if((r.context.get(e.KeysInitQuery.explain)||r.context.get(new u.ActionContextKey("explain")))!=="logical")throw new Error(`${this.name} can only explain in 'logical' mode.`);return!0}async run(r){let{operation:a,context:o}=await this.queryProcessor.parse(r.query,r.context);return{operation:a,context:o}=await this.queryProcessor.optimize(a,o),{result:{explain:!0,type:"logical",data:a}}}};return s0.ActorQueryProcessExplainLogical=s,s0}var JL;function vte(){return JL||(JL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(_te(),t)}(vS)),vS}var wS={},o0={},Ps={},XL;function fB(){if(XL)return Ps;XL=1,Object.defineProperty(Ps,"__esModule",{value:!0}),Ps.numberToString=Ps.MemoryPhysicalQueryPlanLogger=void 0;const t=er();let e=class{constructor(){this.planNodes=new Map}logOperation(n,r,a,o,l,c){const d={actor:l,logicalOperator:n,physicalOperator:r,rawNode:a,children:[],metadata:c};if(this.planNodes.set(a,d),this.rootNode){if(!o)throw new Error("Detected more than one parent-less node");const h=this.planNodes.get(o);if(!h)throw new Error("Could not find parent node");h.children.push(d)}else{if(o)throw new Error("No root node has been set yet, while a parent is being referenced");this.rootNode=d}}stashChildren(n,r){const a=this.planNodes.get(n);if(!a)throw new Error("Could not find plan node");a.children=r?a.children.filter(r):[]}unstashChild(n,r){const a=this.planNodes.get(n);if(a){const o=this.planNodes.get(r);if(!o)throw new Error("Could not find plan parent node");o.children.push(a)}}appendMetadata(n,r){const a=this.planNodes.get(n);a&&(a.metadata={...a.metadata,...r})}toJson(){return this.rootNode?this.planNodeToJson(this.rootNode):{}}planNodeToJson(n){var a;const r={logical:n.logicalOperator,physical:n.physicalOperator,...this.getLogicalMetadata(n.rawNode),...this.compactMetadata(n.metadata)};if(n.children.length>0&&(r.children=n.children.map(o=>this.planNodeToJson(o))),r.physical==="bind"&&r.children){const o={};for(const c of r.children){const d=((a=c.children)==null?void 0:a.at(-1))??c,h=this.getPlanHash(d).join(",");o[h]||(o[h]=[]),o[h].push(c)}const l=[];for(const c of Object.values(o))l.push({occurrences:c.length,firstOccurrence:c[0]});r.childrenCompact=l,delete r.children}return r}getPlanHash(n){let r=[`${n.logical}-${n.physical}`];return n.children?r=[...r,...n.children.flatMap(a=>this.getPlanHash(a))]:n.childrenCompact&&(r=[...r,...n.childrenCompact.flatMap(a=>this.getPlanHash(a.firstOccurrence))]),r}compactMetadata(n){return Object.fromEntries(Object.entries(n).map(([r,a])=>[r,this.compactMetadataValue(a)]))}compactMetadataValue(n){return n&&typeof n=="object"&&"termType"in n?this.getLogicalMetadata(n):n}getLogicalMetadata(n){var a;const r={};if("type"in n){const o=n;switch((a=o.metadata)!=null&&a.scopedSource&&(r.source=o.metadata.scopedSource.source.toString()),o.type){case"pattern":r.pattern=this.quadToString(o);break;case"project":r.variables=o.variables.map(l=>l.value);break}}return r}quadToString(n){return`${(0,t.termToString)(n.subject)} ${(0,t.termToString)(n.predicate)} ${(0,t.termToString)(n.object)}${n.graph.termType==="DefaultGraph"?"":` ${(0,t.termToString)(n.graph)}`}`}toCompactString(){const n=this.toJson(),r=[],a=new Map;if("logical"in n?this.nodeToCompactString(r,a,"",n):r.push("Empty"),a.size>0){r.push(""),r.push("sources:");for(const[o,l]of a.entries())r.push(` ${l}: ${o}`)}return r.join(` -`)}nodeToCompactString(n,r,a,o,l){let c;o.source&&(c=r.get(o.source),c===void 0&&(c=r.size,r.set(o.source,c))),n.push(`${a}${o.logical}${o.physical?`(${o.physical})`:""}${o.pattern?` (${o.pattern})`:""}${o.variables?` (${o.variables.join(",")})`:""}${o.bindOperation?` bindOperation:(${o.bindOperation.pattern}) bindCardEst:${o.bindOperationCardinality.type==="estimate"?"~":""}${u(o.bindOperationCardinality.value)}`:""}${o.cardinality?` cardEst:${o.cardinality.type==="estimate"?"~":""}${u(o.cardinality.value)}`:""}${o.source?` src:${c}`:""}${o.cardinalityReal?` cardReal:${o.cardinalityReal}`:""}${o.timeSelf?` timeSelf:${u(o.timeSelf)}ms`:""}${o.timeLife?` timeLife:${u(o.timeLife)}ms`:""}${l?` ${l}`:""}`);for(const d of o.children??[])this.nodeToCompactString(n,r,`${a} `,d);for(const d of o.childrenCompact??[])this.nodeToCompactString(n,r,`${a} `,d.firstOccurrence,`compacted-occurrences:${d.occurrences}`)}};Ps.MemoryPhysicalQueryPlanLogger=e;function u(s){return s.toLocaleString("en-US",{minimumFractionDigits:0,maximumFractionDigits:3})}return Ps.numberToString=u,Ps}var KL;function wte(){if(KL)return o0;KL=1,Object.defineProperty(o0,"__esModule",{value:!0}),o0.ActorQueryProcessExplainPhysical=void 0;const t=Yb(),e=Lt,u=ot,s=fB();let n=class extends t.ActorQueryProcess{constructor(a){super(a)}async test(a){const o=a.context.get(e.KeysInitQuery.explain)||a.context.get(new u.ActionContextKey("explain"));if(o!=="physical"&&o!=="physical-json")throw new Error(`${this.name} can only explain in 'physical' or 'physical-json' mode.`);return!0}async run(a){let{operation:o,context:l}=await this.queryProcessor.parse(a.query,a.context);({operation:o,context:l}=await this.queryProcessor.optimize(o,l));const c=new s.MemoryPhysicalQueryPlanLogger;l=l.set(e.KeysInitQuery.physicalQueryPlanLogger,c);const d=await this.queryProcessor.evaluate(o,l);switch(d.type){case"bindings":await d.bindingsStream.toArray();break;case"quads":await d.quadStream.toArray();break;case"boolean":await d.execute();break;case"void":await d.execute();break}const h=a.context.get(e.KeysInitQuery.explain)??a.context.getSafe(new u.ActionContextKey("explain"));return{result:{explain:!0,type:h,data:h==="physical"?c.toCompactString():c.toJson()}}}};return o0.ActorQueryProcessExplainPhysical=n,o0}var YL;function Ste(){return YL||(YL=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(wte(),t),u(fB(),t)}(wS)),wS}var SS={},u0={},ZL;function Tte(){if(ZL)return u0;ZL=1,Object.defineProperty(u0,"__esModule",{value:!0}),u0.ActorOptimizeQueryOperationPruneEmptySourceOperations=void 0;const t=Ii(),e=wt(),u=Lt,s=Et(),n=Ot(),r=new n.Factory,a=new s.DataFactory;let o=class extends t.ActorOptimizeQueryOperation{constructor(c){super(c)}async test(c){if(e.ActorQueryOperation.getOperationSource(c.operation))throw new Error(`Actor ${this.name} does not work with top-level operation sources.`);return!0}async run(c){let d=c.operation;const h=[],f=this;n.Util.recurseOperation(d,{[n.Algebra.types.UNION](y){return f.collectMultiOperationInputs(y.input,h,n.Algebra.types.PATTERN),!0},[n.Algebra.types.ALT](y){return f.collectMultiOperationInputs(y.input,h,n.Algebra.types.LINK),!1},[n.Algebra.types.SERVICE](){return!1}});const p=new Set;return await Promise.all(h.map(async y=>{const b=y.type==="link"?r.createPattern(a.variable("?s"),y.iri,a.variable("?o")):y;await this.hasSourceResults(e.ActorQueryOperation.getOperationSource(y),b,c.context)||p.add(y)})),p.size>0&&(this.logDebug(c.context,`Pruning ${p.size} source-specific operations`),d=n.Util.mapOperation(d,{[n.Algebra.types.UNION](y,b){return f.mapMultiOperation(y,p,m=>b.createUnion(m))},[n.Algebra.types.ALT](y,b){return f.mapMultiOperation(y,p,m=>b.createAlt(m))}}),d=n.Util.mapOperation(d,{[n.Algebra.types.PROJECT](y,b){let m=!1;return n.Util.recurseOperation(y,{[n.Algebra.types.UNION](g){return g.input.length===0&&(m=!0),!0},[n.Algebra.types.ALT](g){return g.input.length===0&&(m=!0),!0}}),m?{recurse:!1,result:b.createUnion([])}:{recurse:!0,result:y}}})),{operation:d,context:c.context}}collectMultiOperationInputs(c,d,h){for(const f of c)e.ActorQueryOperation.getOperationSource(f)&&f.type===h&&d.push(f)}mapMultiOperation(c,d,h){const f=c.input.filter(p=>!d.has(p));return f.length===c.input.length?{result:c,recurse:!0}:f.length===0?{result:h([]),recurse:!1}:f.length===1?{result:f[0],recurse:!0}:{result:h(f),recurse:!0}}async hasSourceResults(c,d,h){var p;if((p=c.context)!=null&&p.get(u.KeysQuerySourceIdentify.traverse))return!0;if(this.useAskIfSupported){const y=r.createAsk(d);if(e.ActorQueryOperation.doesShapeAcceptOperation(await c.source.getSelectorShape(h),y))return c.source.queryBoolean(y,h)}const f=c.source.queryBindings(d,h);return new Promise((y,b)=>{f.on("error",b),f.getProperty("metadata",m=>{f.destroy(),y(m.cardinality.value>0)})})}};return u0.ActorOptimizeQueryOperationPruneEmptySourceOperations=o,u0}var eM;function Ate(){return eM||(eM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Tte(),t)}(SS)),SS}var TS={},c0={},tM;function Ete(){if(tM)return c0;tM=1,Object.defineProperty(c0,"__esModule",{value:!0}),c0.ActorQuerySourceIdentifySerialized=void 0;const t=xy(),e=$7(),u=Wt();let s=class extends t.ActorQuerySourceIdentify{constructor(r){super(r)}async test(r){if(!this.isStringSource(r.querySourceUnidentified))throw new Error(`${this.name} requires a single query source with serialized type to be present in the context.`);return!0}async run(r){return await this.mediatorQuerySourceIdentify.mediate({querySourceUnidentified:{type:"rdfjs",value:await this.getRdfSource(r.context,r.querySourceUnidentified),context:r.querySourceUnidentified.context},context:r.context})}async getRdfSource(r,a){const o=new u.Readable({objectMode:!0});o._read=()=>{},o.push(a.value),o.push(null);const l={context:r,handle:{metadata:{baseIRI:a.baseIRI},data:o,context:r},handleMediaType:a.mediaType},c=await this.mediatorRdfParse.mediate(l);return await(0,e.storeStream)(c.handle.data)}isStringSource(r){return"type"in r?r.type==="serialized":typeof r.value!="string"?!1:"mediaType"in r}};return c0.ActorQuerySourceIdentifySerialized=s,c0}var rM;function Ote(){return rM||(rM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Ete(),t)}(TS)),TS}var AS={},l0={},nM;function Rte(){if(nM)return l0;nM=1,Object.defineProperty(l0,"__esModule",{value:!0}),l0.ActorOptimizeQueryOperationJoinConnected=void 0;const t=Ii(),e=Ot();let u=class H1 extends t.ActorOptimizeQueryOperation{async test(n){return!0}async run(n){return{operation:e.Util.mapOperation(n.operation,{join(a,o){return{recurse:!1,result:H1.cluster(a,o)}}}),context:n.context}}static cluster(n,r){const a=n.input.map(d=>({inScopeVariables:Object.fromEntries(e.Util.inScopeVariables(d).map(h=>[h.value,!0])),entries:[d]}));let o,l=a;do o=l,l=H1.clusterIteration(o);while(o.length!==l.length);const c=l.map(d=>r.createJoin(d.entries));return c.length===1?c[0]:r.createJoin(c,!1)}static clusterIteration(n){const r=[];for(const a of n){let o=!1;for(const l of r)if(H1.haveOverlappingVariables(a.inScopeVariables,l.inScopeVariables)){l.entries=[...l.entries,...a.entries],l.inScopeVariables={...l.inScopeVariables,...a.inScopeVariables},o=!0;break}o||r.push({inScopeVariables:a.inScopeVariables,entries:a.entries})}return r}static haveOverlappingVariables(n,r){for(const a of Object.keys(n))if(r[a])return!0;return!1}};return l0.ActorOptimizeQueryOperationJoinConnected=u,l0}var iM;function xte(){return iM||(iM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Rte(),t)}(AS)),AS}var ES={},d0={},aM;function Ite(){if(aM)return d0;aM=1,Object.defineProperty(d0,"__esModule",{value:!0}),d0.ActorOptimizeQueryOperationBgpToJoin=void 0;const t=Ii(),e=Ot();let u=class extends t.ActorOptimizeQueryOperation{async test(n){return!0}async run(n){return{operation:e.Util.mapOperation(n.operation,{bgp(a,o){return{recurse:!1,result:o.createJoin(a.patterns)}}}),context:n.context}}};return d0.ActorOptimizeQueryOperationBgpToJoin=u,d0}var sM;function Pte(){return sM||(sM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Ite(),t)}(ES)),ES}var OS={},f0={},oM;function Dte(){if(oM)return f0;oM=1,Object.defineProperty(f0,"__esModule",{value:!0}),f0.ActorOptimizeQueryOperationJoinBgp=void 0;const t=Ii(),e=Ot();let u=class extends t.ActorOptimizeQueryOperation{async test(n){return!0}async run(n){return{operation:e.Util.mapOperation(n.operation,{join(a,o){return a.input.every(l=>l.type==="bgp")?{recurse:!1,result:o.createBgp(a.input.flatMap(l=>l.patterns))}:{recurse:!1,result:a}}}),context:n.context}}};return f0.ActorOptimizeQueryOperationJoinBgp=u,f0}var uM;function Nte(){return uM||(uM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Dte(),t)}(OS)),OS}var RS={},h0={},cM;function Cte(){if(cM)return h0;cM=1,Object.defineProperty(h0,"__esModule",{value:!0}),h0.ActorOptimizeQueryOperationAssignSourcesExhaustive=void 0;const t=Ii(),e=wt(),u=YT(),s=Lt,n=Ot();let r=class extends t.ActorOptimizeQueryOperation{constructor(o){super(o)}async test(o){return!0}async run(o){const l=o.context.get(s.KeysQueryOperation.querySources)??[];if(l.length===0)return{operation:o.operation,context:o.context};if(l.length===1){const c=l[0],d=o.context.get(s.KeysRdfUpdateQuads.destination);if(!d||c.source.referenceValue===(0,u.getDataDestinationValue)(d))try{const h=await c.source.getSelectorShape(o.context);if(e.ActorQueryOperation.doesShapeAcceptOperation(h,o.operation))return{operation:e.ActorQueryOperation.assignOperationSource(o.operation,c),context:o.context}}catch{}}return{operation:this.assignExhaustive(o.operation,l),context:o.context.delete(s.KeysInitQuery.queryString)}}assignExhaustive(o,l){const c=this;return n.Util.mapOperation(o,{[n.Algebra.types.PATTERN](d,h){return l.length===1?{result:e.ActorQueryOperation.assignOperationSource(d,l[0]),recurse:!1}:{result:h.createUnion(l.map(f=>e.ActorQueryOperation.assignOperationSource(d,f))),recurse:!1}},[n.Algebra.types.LINK](d,h){return l.length===1?{result:e.ActorQueryOperation.assignOperationSource(d,l[0]),recurse:!1}:{result:h.createAlt(l.map(f=>e.ActorQueryOperation.assignOperationSource(d,f))),recurse:!1}},[n.Algebra.types.NPS](d,h){return l.length===1?{result:e.ActorQueryOperation.assignOperationSource(d,l[0]),recurse:!1}:{result:h.createAlt(l.map(f=>e.ActorQueryOperation.assignOperationSource(d,f))),recurse:!1}},[n.Algebra.types.SERVICE](d){return{result:d,recurse:!1}},[n.Algebra.types.CONSTRUCT](d,h){return{result:h.createConstruct(c.assignExhaustive(d.input,l),d.template),recurse:!1}},[n.Algebra.types.DELETE_INSERT](d,h){return{result:h.createDeleteInsert(d.delete,d.insert,d.where?c.assignExhaustive(d.where,l):void 0),recurse:!1}}})}};return h0.ActorOptimizeQueryOperationAssignSourcesExhaustive=r,h0}var lM;function jte(){return lM||(lM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Cte(),t)}(RS)),RS}var xS={},p0={},dM;function Lte(){if(dM)return p0;dM=1,Object.defineProperty(p0,"__esModule",{value:!0}),p0.ActorOptimizeQueryOperationDescribeToConstructsSubject=void 0;const t=Ii(),e=Et(),u=Ot(),s=new e.DataFactory,n=new u.Factory;let r=class extends t.ActorOptimizeQueryOperation{constructor(o){super(o)}async test(o){if(o.operation.type!==u.Algebra.types.DESCRIBE)throw new Error(`Actor ${this.name} only supports describe operations, but got ${o.operation.type}`);return!0}async run(o){const l=o.operation,c=l.terms.filter(h=>h.termType!=="Variable").map(h=>{const f=[s.quad(h,s.variable("__predicate"),s.variable("__object"))];return f.forEach(y=>y.type="pattern"),{input:{type:u.Algebra.types.BGP,patterns:f},template:f,type:"construct"}});if(c.length!==l.terms.length){let h=[];l.terms.filter(f=>f.termType==="Variable").forEach((f,p)=>{const y=[s.quad(f,s.variable(`__predicate${p}`),s.variable(`__object${p}`))];y.forEach(b=>b.type="pattern"),h=[...h,...y]}),c.push({input:{type:u.Algebra.types.JOIN,input:[l.input,{type:u.Algebra.types.BGP,patterns:h}]},template:h,type:u.Algebra.types.CONSTRUCT})}return{operation:n.createUnion(c,!1),context:o.context}}};return p0.ActorOptimizeQueryOperationDescribeToConstructsSubject=r,p0}var fM;function Mte(){return fM||(fM=1,function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(Lte(),t)}(xS)),xS}var Fte=function(t){const e=new(vV()).LoggerVoid,u=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-init/^3.0.0/components/ActorInit.jsonld#ActorInit_default_bus"}),s=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-context-preprocess/^3.0.0/components/ActorContextPreprocess.jsonld#ActorContextPreprocess_default_bus"}),n=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-hash-bindings/^3.0.0/components/ActorHashBindings.jsonld#ActorHashBindings_default_bus"}),r=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-optimize-query-operation/^3.0.0/components/ActorOptimizeQueryOperation.jsonld#ActorOptimizeQueryOperation_default_bus"}),a=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-query-parse/^3.0.0/components/ActorQueryParse.jsonld#ActorQueryParse_default_bus"}),o=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-query-result-serialize/^3.0.0/components/ActorQueryResultSerialize.jsonld#ActorQueryResultSerialize_default_bus"}),l=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-query-source-identify-hypermedia/^3.0.0/components/ActorQuerySourceIdentifyHypermedia.jsonld#ActorQuerySourceIdentifyHypermedia_default_bus"}),c=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-dereference/^3.0.0/components/ActorDereference.jsonld#ActorDereference_default_bus"}),d=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-dereference-rdf/^3.0.0/components/ActorDereferenceRdf.jsonld#ActorDereferenceRdf_default_bus"}),h=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-join-entries-sort/^3.0.0/components/ActorRdfJoinEntriesSort.jsonld#ActorRdfJoinEntriesSort_default_bus"}),f=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-join-selectivity/^3.0.0/components/ActorRdfJoinSelectivity.jsonld#ActorRdfJoinSelectivity_default_bus"}),p=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-metadata/^3.0.0/components/ActorRdfMetadata.jsonld#ActorRdfMetadata_default_bus"}),y=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-metadata-accumulate/^3.0.0/components/ActorRdfMetadataAccumulate.jsonld#ActorRdfMetadataAccumulate_default_bus"}),b=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-metadata-extract/^3.0.0/components/ActorRdfMetadataExtract.jsonld#ActorRdfMetadataExtract_default_bus"}),m=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-parse/^3.0.0/components/ActorRdfParse.jsonld#ActorRdfParse_default_bus"}),g=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-parse-html/^3.0.0/components/ActorRdfParseHtml.jsonld#ActorRdfParseHtml_default_bus"}),v=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-resolve-hypermedia-links-queue/^3.0.0/components/ActorRdfResolveHypermediaLinksQueue.jsonld#ActorRdfResolveHypermediaLinksQueue_default_bus"}),_=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-resolve-hypermedia-links/^3.0.0/components/ActorRdfResolveHypermediaLinks.jsonld#ActorRdfResolveHypermediaLinks_default_bus"}),w=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-serialize/^3.0.0/components/ActorRdfSerialize.jsonld#ActorRdfSerialize_default_bus"}),S=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-update-hypermedia/^3.0.0/components/ActorRdfUpdateHypermedia.jsonld#ActorRdfUpdateHypermedia_default_bus"}),A=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-update-quads/^3.0.0/components/ActorRdfUpdateQuads.jsonld#ActorRdfUpdateQuads_default_bus"}),D=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-http/^3.0.0/components/ActorHttp.jsonld#ActorHttp_default_bus"}),L=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-http/^3.0.0/components/ActorHttp.jsonld#ActorHttp_fallback_bus"}),E=new(wt()).BusQueryOperation({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-query-operation/^3.0.0/components/ActorQueryOperation.jsonld#ActorQueryOperation_default_bus"}),O=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-query-process/^3.0.0/components/ActorQueryProcess.jsonld#ActorQueryProcess_default_bus"}),P=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-query-source-identify/^3.0.0/components/ActorQuerySourceIdentify.jsonld#ActorQuerySourceIdentify_default_bus"}),j=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-join/^3.0.0/components/ActorRdfJoin.jsonld#ActorRdfJoin_default_bus"}),U=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-http-invalidate/^3.0.0/components/ActorHttpInvalidate.jsonld#ActorHttpInvalidate_default_bus"}),M=new ot.Bus({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-merge-bindings-context/^3.0.0/components/ActorMergeBindingsContext.jsonld#ActorMergeBindingsContext_default_bus"});new(JV()).ActorContextPreprocessConvertShortcuts({contextKeyShortcuts:{baseIRI:"@comunica/actor-init-query:baseIRI",datetime:"@comunica/actor-http-memento:datetime",destination:"@comunica/bus-rdf-update-quads:destination",explain:"@comunica/actor-init-query:explain",extensionFunctionCreator:"@comunica/actor-init-query:extensionFunctionCreator",extensionFunctions:"@comunica/actor-init-query:extensionFunctions",fetch:"@comunica/bus-http:fetch",functionArgumentsCache:"@comunica/actor-init-query:functionArgumentsCache",httpAuth:"@comunica/bus-http:auth",httpBodyTimeout:"@comunica/bus-http:http-body-timeout",httpIncludeCredentials:"@comunica/bus-http:include-credentials",httpProxyHandler:"@comunica/actor-http-proxy:httpProxyHandler",httpRetryCount:"@comunica/bus-http:http-retry-count",httpRetryDelay:"@comunica/bus-http:http-retry-delay",httpRetryOnServerError:"@comunica/bus-http:http-retry-on-server-error",httpTimeout:"@comunica/bus-http:http-timeout",initialBindings:"@comunica/actor-init-query:initialBindings",lenient:"@comunica/actor-init-query:lenient",log:"@comunica/core:log",noCache:"@comunica/actor-init-query:noCache",queryFormat:"@comunica/actor-init-query:queryFormat",queryTimestamp:"@comunica/actor-init-query:queryTimestamp",readOnly:"@comunica/bus-query-operation:readOnly",recoverBrokenLinks:"@comunica/bus-http-wayback:recover-broken-links",sources:"@comunica/actor-init-query:querySourcesUnidentified",traverse:"@comunica/bus-query-source-identify:traverse",unionDefaultGraph:"@comunica/bus-query-operation:unionDefaultGraph"},name:"urn:comunica:default:context-preprocess/actors#convert-shortcuts",bus:s}),new(KV()).ActorContextPreprocessSetDefaults({logger:e,name:"urn:comunica:default:context-preprocess/actors#set-defaults",bus:s}),new(ZV()).ActorContextPreprocessSourceToDestination({name:"urn:comunica:default:context-preprocess/actors#source-to-destination",bus:s});const q=new(QF()).ActorContextPreprocessQuerySourceSkolemize({name:"urn:comunica:default:context-preprocess/actors#query-source-skolemize",bus:s}),Q=new(dR()).MediatorCombinePipeline({name:"urn:comunica:default:context-preprocess/mediators#main",bus:s});new(sk()).ActorHashBindingsSha1({name:"urn:comunica:default:hash-bindings/actors#sha1",bus:n});const Z=new(_n()).MediatorRace({name:"urn:comunica:default:hash-bindings/mediators#main",bus:n});new(lk()).ActorOptimizeQueryOperationRewriteCopy({name:"urn:comunica:default:optimize-query-operation/actors#rewrite-copy",bus:r}),new(fk()).ActorOptimizeQueryOperationRewriteMove({name:"urn:comunica:default:optimize-query-operation/actors#rewrite-move",bus:r}),new(pk()).ActorOptimizeQueryOperationRewriteAdd({name:"urn:comunica:default:optimize-query-operation/actors#rewrite-add",bus:r});const K=new(bk()).ActorOptimizeQueryOperationGroupSources({name:"urn:comunica:default:optimize-query-operation/actors#group-sources",bus:r}),fe=new(dR()).MediatorCombinePipeline({filterErrors:!0,name:"urn:comunica:default:optimize-query-operation/mediators#main",bus:r});new(_k()).ActorQueryParseSparql({prefixes:{dbpedia:"http://dbpedia.org/resource/","dbpedia-owl":"http://dbpedia.org/ontology/",dbpprop:"http://dbpedia.org/property/",dc:"http://purl.org/dc/terms/",dc11:"http://purl.org/dc/elements/1.1/",dcterms:"http://purl.org/dc/terms/",foaf:"http://xmlns.com/foaf/0.1/",geo:"http://www.w3.org/2003/01/geo/wgs84_pos#",owl:"http://www.w3.org/2002/07/owl#",rdf:"http://www.w3.org/1999/02/22-rdf-syntax-ns#",rdfs:"http://www.w3.org/2000/01/rdf-schema#",schema:"http://schema.org/",skos:"http://www.w3.org/2008/05/skos#",xsd:"http://www.w3.org/2001/XMLSchema#"},name:"urn:comunica:default:query-parse/actors#sparql",bus:a}),new(kz()).ActorQueryParseGraphql({name:"urn:comunica:default:query-parse/actors#graphql",bus:a});const X=new(_n()).MediatorRace({name:"urn:comunica:default:query-parse/mediators#main",bus:a});new(nG()).ActorQueryResultSerializeJson({mediaTypePriorities:{"application/json":1},mediaTypeFormats:{"application/json":"https://comunica.linkeddatafragments.org/#results_JSON"},name:"urn:comunica:default:query-result-serialize/actors#json",bus:o}),new(aG()).ActorQueryResultSerializeSimple({mediaTypePriorities:{simple:.9},mediaTypeFormats:{simple:"https://comunica.linkeddatafragments.org/#results_simple"},name:"urn:comunica:default:query-result-serialize/actors#simple",bus:o}),new(oG()).ActorQueryResultSerializeSparqlCsv({mediaTypePriorities:{"text/csv":.75},mediaTypeFormats:{"text/csv":"http://www.w3.org/ns/formats/SPARQL_Results_CSV"},name:"urn:comunica:default:query-result-serialize/actors#csv",bus:o}),new(lG()).ActorQueryResultSerializeSparqlTsv({mediaTypePriorities:{"text/tab-separated-values":.75},mediaTypeFormats:{"text/tab-separated-values":"http://www.w3.org/ns/formats/SPARQL_Results_TSV"},name:"urn:comunica:default:query-result-serialize/actors#sparql-tsv",bus:o}),new(hG()).ActorQueryResultSerializeSparqlXml({mediaTypePriorities:{"application/sparql-results+xml":.8},mediaTypeFormats:{"application/sparql-results+xml":"http://www.w3.org/ns/formats/SPARQL_Results_XML"},name:"urn:comunica:default:query-result-serialize/actors#sparql-xml",bus:o}),new(yG()).ActorQueryResultSerializeTable({columnWidth:50,mediaTypePriorities:{table:.6},mediaTypeFormats:{table:"https://comunica.linkeddatafragments.org/#results_table"},name:"urn:comunica:default:query-result-serialize/actors#table",bus:o}),new(OG()).ActorQueryResultSerializeTree({mediaTypePriorities:{tree:.5},mediaTypeFormats:{tree:"https://comunica.linkeddatafragments.org/#results_tree"},name:"urn:comunica:default:query-result-serialize/actors#tree",bus:o});const he=new(_n()).MediatorRace({name:"urn:comunica:default:query-result-serialize/mediators#serialize",bus:o}),xe=new(Ra()).MediatorCombineUnion({field:"mediaTypes",name:"urn:comunica:default:query-result-serialize/mediators#mediaType",bus:o}),ie=new(Ra()).MediatorCombineUnion({field:"mediaTypeFormats",name:"urn:comunica:default:query-result-serialize/mediators#mediaTypeFormat",bus:o}),ae=new(Zc()).MediatorNumber({field:"filterFactor",type:"max",ignoreErrors:!0,name:"urn:comunica:default:query-source-identify-hypermedia/mediators#main",bus:l}),Oe=new(NG()).ActorDereferenceFallback({name:"urn:comunica:default:dereference/actors#fallback",bus:c}),Ne=new(_n()).MediatorRace({name:"urn:comunica:default:dereference/mediators#main",bus:c}),ge=new(_n()).MediatorRace({name:"urn:comunica:default:dereference-rdf/mediators#main",bus:d});new(MG()).ActorRdfJoinEntriesSortCardinality({name:"urn:comunica:default:rdf-join-entries-sort/actors#cardinality",bus:h});const de=new(_n()).MediatorRace({name:"urn:comunica:default:rdf-join-entries-sort/mediators#main",bus:h});new(UG()).ActorRdfJoinSelectivityVariableCounting({name:"urn:comunica:default:rdf-join-selectivity/actors#variable-counting",bus:f});const oe=new(Zc()).MediatorNumber({field:"accuracy",type:"max",ignoreErrors:!0,name:"urn:comunica:default:rdf-join-selectivity/mediators#main",bus:f});new(QG()).ActorRdfMetadataPrimaryTopic({metadataToData:!1,dataToMetadataOnInvalidMetadataGraph:!0,name:"urn:comunica:default:rdf-metadata/actors#primary-topic",bus:p}),new(kG()).ActorRdfMetadataAll({name:"urn:comunica:default:rdf-metadata/actors#all",bus:p});const $=new(_n()).MediatorRace({name:"urn:comunica:default:rdf-metadata/mediators#main",bus:p});new(WG()).ActorRdfMetadataAccumulateCanContainUndefs({name:"urn:comunica:default:rdf-metadata-accumulate/actors#cancontainundefs",bus:y}),new(XG()).ActorRdfMetadataAccumulateCardinality({name:"urn:comunica:default:rdf-metadata-accumulate/actors#cardinality",bus:y}),new(YG()).ActorRdfMetadataAccumulatePageSize({name:"urn:comunica:default:rdf-metadata-accumulate/actors#pagesize",bus:y}),new(eW()).ActorRdfMetadataAccumulateRequestTime({name:"urn:comunica:default:rdf-metadata-accumulate/actors#requesttime",bus:y});const N=new(Ra()).MediatorCombineUnion({field:"metadata",name:"urn:comunica:default:rdf-metadata-accumulate/mediators#main",bus:y});new(iW()).ActorRdfMetadataExtractHydraControls({name:"urn:comunica:default:rdf-metadata-extract/actors#hydra-controls",bus:b}),new(sW()).ActorRdfMetadataExtractHydraCount({predicates:["http://www.w3.org/ns/hydra/core#totalItems","http://rdfs.org/ns/void#triples"],name:"urn:comunica:default:rdf-metadata-extract/actors#hydra-count",bus:b}),new(uW()).ActorRdfMetadataExtractHydraPagesize({predicates:["http://www.w3.org/ns/hydra/core#itemsPerPage"],name:"urn:comunica:default:rdf-metadata-extract/actors#hydra-pagesize",bus:b}),new(lW()).ActorRdfMetadataExtractRequestTime({name:"urn:comunica:default:rdf-metadata-extract/actors#request-time",bus:b}),new(fW()).ActorRdfMetadataExtractAllowHttpMethods({name:"urn:comunica:default:rdf-metadata-extract/actors#allow-http-methods",bus:b}),new(pW()).ActorRdfMetadataExtractPutAccepted({name:"urn:comunica:default:rdf-metadata-extract/actors#put-accepted",bus:b}),new(bW()).ActorRdfMetadataExtractPatchSparqlUpdate({name:"urn:comunica:default:rdf-metadata-extract/actors#patch-sparql-update",bus:b}),new(mW()).ActorRdfMetadataExtractSparqlService({inferHttpsEndpoint:!0,name:"urn:comunica:default:rdf-metadata-extract/actors#sparql-service",bus:b});const R=new(Ra()).MediatorCombineUnion({filterErrors:!0,field:"metadata",name:"urn:comunica:default:rdf-metadata-extract/mediators#main",bus:b});new(GW()).ActorRdfParseN3({mediaTypePriorities:{"application/n-quads":1,"application/n-triples":.8,"application/trig":.95,"text/n3":.35,"text/turtle":.6},mediaTypeFormats:{"application/n-quads":"http://www.w3.org/ns/formats/N-Quads","application/n-triples":"http://www.w3.org/ns/formats/N-Triples","application/trig":"http://www.w3.org/ns/formats/TriG","text/n3":"http://www.w3.org/ns/formats/N3","text/turtle":"http://www.w3.org/ns/formats/Turtle"},priorityScale:1,name:"urn:comunica:default:rdf-parse/actors#n3",bus:m}),new(nJ()).ActorRdfParseRdfXml({mediaTypePriorities:{"application/rdf+xml":1},mediaTypeFormats:{"application/rdf+xml":"http://www.w3.org/ns/formats/RDF_XML"},priorityScale:.5,name:"urn:comunica:default:rdf-parse/actors#rdfxml",bus:m}),new(SJ()).ActorRdfParseXmlRdfa({mediaTypePriorities:{"application/xml":1,"image/svg+xml":1,"text/xml":1},mediaTypeFormats:{"application/xml":"http://www.w3.org/ns/formats/RDFa","image/svg+xml":"http://www.w3.org/ns/formats/RDFa","text/xml":"http://www.w3.org/ns/formats/RDFa"},priorityScale:.3,name:"urn:comunica:default:rdf-parse/actors#xmlrdfa",bus:m}),new(xJ()).ActorRdfParseShaclc({mediaTypePriorities:{"text/shaclc":1,"text/shaclc-ext":.5},mediaTypeFormats:{"text/shaclc":"http://www.w3.org/ns/formats/Shaclc","text/shaclc-ext":"http://www.w3.org/ns/formats/ShaclcExtended"},priorityScale:.1,name:"urn:comunica:default:rdf-parse/actors#shaclc",bus:m});const T=new(_n()).MediatorRace({name:"urn:comunica:default:rdf-parse/mediators#parse",bus:m}),x=new(Ra()).MediatorCombineUnion({field:"mediaTypes",name:"urn:comunica:default:rdf-parse/mediators#mediaType",bus:m});new(DJ()).ActorRdfParseHtml({busRdfParseHtml:g,mediaTypePriorities:{"application/xhtml+xml":.9,"text/html":1},mediaTypeFormats:{"application/xhtml+xml":"http://www.w3.org/ns/formats/HTML","text/html":"http://www.w3.org/ns/formats/HTML"},priorityScale:.2,name:"urn:comunica:default:rdf-parse/actors#html",bus:m}),new($J()).ActorRdfParseHtmlMicrodata({name:"urn:comunica:default:rdf-parse-html/actors#microdata",bus:g}),new(VJ()).ActorRdfParseHtmlRdfa({name:"urn:comunica:default:rdf-parse-html/actors#rdfa",bus:g}),new(XJ()).ActorRdfResolveHypermediaLinksQueueFifo({name:"urn:comunica:default:rdf-resolve-hypermedia-links-queue/actors#fifo",bus:v});const B=new(_n()).MediatorRace({name:"urn:comunica:default:rdf-resolve-hypermedia-links-queue/mediators#main",bus:v});new(eX()).ActorRdfResolveHypermediaLinksNext({name:"urn:comunica:default:rdf-resolve-hypermedia-links/actors#next",bus:_});const k=new(_n()).MediatorRace({name:"urn:comunica:default:rdf-resolve-hypermedia-links/mediators#main",bus:_});new(iX()).ActorRdfSerializeN3({mediaTypePriorities:{"application/n-quads":1,"application/n-triples":.8,"application/trig":.95,"text/n3":.35,"text/turtle":.6},mediaTypeFormats:{"application/n-quads":"http://www.w3.org/ns/formats/N-Quads","application/n-triples":"http://www.w3.org/ns/formats/N-Triples","application/trig":"http://www.w3.org/ns/formats/TriG","text/n3":"http://www.w3.org/ns/formats/N3","text/turtle":"http://www.w3.org/ns/formats/Turtle"},name:"urn:comunica:default:rdf-serialize/actors#n3",bus:w}),new(cX()).ActorRdfSerializeJsonLd({jsonStringifyIndentSpaces:2,mediaTypePriorities:{"application/ld+json":1},mediaTypeFormats:{"application/ld+json":"http://www.w3.org/ns/formats/JSON-LD"},priorityScale:.9,name:"urn:comunica:default:rdf-serialize/actors#jsonld",bus:w}),new(OX()).ActorRdfSerializeShaclc({mediaTypePriorities:{"text/shaclc":1,"text/shaclc-ext":.5},mediaTypeFormats:{"text/shaclc":"http://www.w3.org/ns/formats/Shaclc","text/shaclc-ext":"http://www.w3.org/ns/formats/ShaclcExtended"},priorityScale:.1,name:"urn:comunica:default:rdf-serialize/actors#shaclc",bus:w});const V=new(_n()).MediatorRace({name:"urn:comunica:default:rdf-serialize/mediators#serialize",bus:w}),J=new(Ra()).MediatorCombineUnion({field:"mediaTypes",name:"urn:comunica:default:rdf-serialize/mediators#mediaType",bus:w}),z=new(Ra()).MediatorCombineUnion({field:"mediaTypeFormats",name:"urn:comunica:default:rdf-serialize/mediators#mediaTypeFormat",bus:w}),Y=new(_n()).MediatorRace({name:"urn:comunica:default:rdf-update-hypermedia/mediators#main",bus:S});new(CX()).ActorRdfUpdateQuadsRdfJsStore({name:"urn:comunica:default:rdf-update-quads/actors#rdfjs-store",bus:A});const te=new(_n()).MediatorRace({name:"urn:comunica:default:rdf-update-quads/mediators#main",bus:A}),ce=new(HX()).ActorHttpFetch({agentOptions:{keepAlive:!0,maxSockets:5},name:"urn:comunica:default:http/actors#fetch",bus:D}),Ae=new(Zc()).MediatorNumber({field:"time",type:"min",ignoreErrors:!0,name:"urn:comunica:default:http/mediators#no-fallback",bus:D}),Ie=new(Zc()).MediatorNumber({field:"time",type:"min",ignoreErrors:!0,name:"urn:comunica:default:http/mediators#main",bus:L});new(QX()).ActorQueryOperationSource({name:"urn:comunica:default:query-operation/actors#source",bus:E});const Ee=new(Zc()).MediatorNumber({field:"httpRequests",type:"min",ignoreErrors:!0,name:"urn:comunica:default:query-operation/mediators#main",bus:E}),qe=new(_n()).MediatorRace({name:"urn:comunica:default:query-process/mediators#main",bus:O}),G=new(_n()).MediatorRace({name:"urn:comunica:default:query-source-identify/mediators#main",bus:P}),F=new(kX()).MediatorJoinCoefficientsFixed({cpuWeight:10,memoryWeight:1,timeWeight:2,ioWeight:10,name:"urn:comunica:default:rdf-join/mediators#main",bus:j}),H=new(T1()).ActorHttpInvalidateListenable({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-context-preprocess-query-source-identify/^3.0.0/components/ActorContextPreprocessQuerySourceIdentify.jsonld#IActorContextPreprocessQuerySourceIdentifyArgs_default_invalidator",bus:U}),re=new(WX()).MediatorAll({name:"urn:comunica:default:http-invalidate/mediators#main",bus:U}),be=new(T1()).ActorHttpInvalidateListenable({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-rdf-update-quads-hypermedia/^3.0.0/components/ActorRdfUpdateQuadsHypermedia.jsonld#IActorRdfUpdateQuadsHypermediaArgs_default_invalidator",bus:U}),Re=new(T1()).ActorHttpInvalidateListenable({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-query-result-serialize-sparql-json/^3.0.0/components/ActionObserverHttp.jsonld#IActionObserverHttpArgs_default_invalidator",bus:U}),Ce=new(T1()).ActorHttpInvalidateListenable({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-query-result-serialize-stats/^3.0.0/components/ActionObserverHttp.jsonld#IActionObserverHttpArgs_default_invalidator",bus:U}),Qe=new(Ra()).MediatorCombineUnion({field:"mergeHandlers",name:"urn:comunica:default:merge-bindings-context/mediators#main",bus:M});new(ZX()).ActorRdfJoinSingle({mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#inner-single",bus:j}),new(tK()).ActorRdfJoinMultiEmpty({mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#inner-multi-empty",bus:j}),new(nK()).ActorRdfJoinMultiBindSource({selectivityModifier:1e-4,blockSize:16,mediatorJoinEntriesSort:de,mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#inner-multi-bind-source",bus:j}),new(lK()).ActorRdfJoinHash({mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#inner-hash",bus:j}),new(fK()).ActorRdfJoinSymmetricHash({mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#inner-symmetric-hash",bus:j}),new(pK()).ActorRdfJoinNestedLoop({mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#inner-nested-loop",bus:j}),new(bK()).ActorRdfJoinMinusHash({mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#minus-hash",bus:j}),new(_K()).ActorRdfJoinMinusHashUndef({mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#minus-hash-undef",bus:j}),new(A1()).ActorRdfJoinOptionalHash({canHandleUndefs:!1,blocking:!1,mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#optional-hash-def-nonblocking",bus:j}),new(A1()).ActorRdfJoinOptionalHash({canHandleUndefs:!1,blocking:!0,mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#optional-hash-def-blocking",bus:j}),new(A1()).ActorRdfJoinOptionalHash({canHandleUndefs:!0,blocking:!1,mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#optional-hash-undef-nonblocking",bus:j}),new(A1()).ActorRdfJoinOptionalHash({canHandleUndefs:!0,blocking:!0,mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#optional-hash-undef-blocking",bus:j}),new(AK()).ActorRdfJoinOptionalNestedLoop({mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#optional-nested-loop",bus:j}),new(xK()).ActorDereferenceRdfParse({mediatorDereference:Ne,mediatorParse:T,mediatorParseMediatypes:x,mediaMappings:{htm:"text/html",html:"text/html",json:"application/json",jsonld:"application/ld+json",n3:"text/n3",nq:"application/n-quads",nquads:"application/n-quads",nt:"application/n-triples",ntriples:"application/n-triples",owl:"application/rdf+xml",rdf:"application/rdf+xml",rdfxml:"application/rdf+xml",shaclc:"text/shaclc",shaclce:"text/shaclc-ext",shc:"text/shaclc",shce:"text/shaclc-ext",svg:"image/svg+xml",svgz:"image/svg+xml",trig:"application/trig",ttl:"text/turtle",turtle:"text/turtle",xht:"application/xhtml+xml",xhtml:"application/xhtml+xml",xml:"application/xml"},name:"urn:comunica:default:dereference-rdf/actors#parse",bus:d}),new(DK()).ActorRdfParseHtmlScript({mediatorRdfParseMediatypes:x,mediatorRdfParseHandle:T,name:"urn:comunica:default:rdf-parse-html/actors#script",bus:g}),new(CK()).ActorQueryResultSerializeRdf({mediatorRdfSerialize:V,mediatorMediaTypeCombiner:J,mediatorMediaTypeFormatCombiner:z,name:"urn:comunica:default:query-result-serialize/actors#rdf",bus:o}),new(LK()).ActorHttpWayback({mediatorHttp:Ae,name:"urn:comunica:default:http/actors#wayback",bus:L}),new(rY()).ActorRdfParseJsonLd({mediatorHttp:Ie,mediaTypePriorities:{"application/json":.15,"application/ld+json":1},mediaTypeFormats:{"application/json":"http://www.w3.org/ns/formats/JSON-LD","application/ld+json":"http://www.w3.org/ns/formats/JSON-LD"},priorityScale:.9,name:"urn:comunica:default:rdf-parse/actors#jsonld",bus:m}),new(aY()).ActorRdfUpdateHypermediaPatchSparqlUpdate({mediatorHttp:Ie,name:"urn:comunica:default:rdf-update-hypermedia/actors#patch-sparql-update",bus:S}),new(oY()).ActorRdfUpdateHypermediaPutLdp({mediatorHttp:Ie,mediatorRdfSerializeMediatypes:J,mediatorRdfSerialize:V,name:"urn:comunica:default:rdf-update-hypermedia/actors#put-ldp",bus:S}),new(pY()).ActorRdfUpdateHypermediaSparql({mediatorHttp:Ie,checkUrlSuffixSparql:!0,checkUrlSuffixUpdate:!0,name:"urn:comunica:default:rdf-update-hypermedia/actors#sparql",bus:S}),new(bY()).ActorQueryOperationAsk({mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#ask",bus:E}),new(mY()).ActorQueryOperationBgpJoin({mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#bgp",bus:E}),new(vY()).ActorQueryOperationDistinctHash({mediatorHashBindings:Z,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#distinct",bus:E}),new(v7()).ActorQueryOperationConstruct({mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#construct",bus:E}),new(TY()).ActorQueryOperationFromQuad({mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#from",bus:E}),new(EY()).ActorQueryOperationProject({mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#project",bus:E}),new(RY()).ActorQueryOperationReducedHash({mediatorHashBindings:Z,cacheSize:100,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#reduced",bus:E}),new(IY()).ActorQueryOperationSlice({mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#slice",bus:E}),new(S7()).ActorQueryOperationUnion({mediatorRdfMetadataAccumulate:N,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#union",bus:E}),new(CY()).ActorQueryOperationPathAlt({mediatorRdfMetadataAccumulate:N,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#path-alt",bus:E}),new(LY()).ActorQueryOperationPathInv({mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#path-inv",bus:E}),new(FY()).ActorQueryOperationPathLink({mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#path-link",bus:E}),new(BY()).ActorQueryOperationPathNps({mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#path-nps",bus:E}),new(HY()).ActorQueryOperationClear({mediatorUpdateQuads:te,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#update-clear",bus:E}),new(QY()).ActorQueryOperationUpdateCompositeUpdate({mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#update-composite",bus:E}),new(kY()).ActorQueryOperationCreate({mediatorUpdateQuads:te,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#update-create",bus:E}),new(GY()).ActorQueryOperationDrop({mediatorUpdateQuads:te,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#update-drop",bus:E}),new(JY()).ActorQueryOperationLoad({mediatorUpdateQuads:te,mediatorQuerySourceIdentify:G,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#update-load",bus:E}),new(KY()).ActorQueryOperationJoin({mediatorJoin:F,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#join",bus:E}),new(ZY()).ActorQueryOperationMinus({mediatorJoin:F,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#minus",bus:E}),new(tZ()).ActorQueryOperationPathSeq({mediatorJoin:F,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#path-seq",bus:E}),new(nZ()).ActorRdfJoinMultiSmallest({mediatorJoinEntriesSort:de,mediatorJoin:F,mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#inner-multi-smallest",bus:j}),new(sZ()).ActorRdfJoinMultiSmallestFilterBindings({selectivityModifier:1e-4,blockSize:64,mediatorJoinEntriesSort:de,mediatorJoin:F,mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#inner-multi-smallest-filter-bindings",bus:j});const ke=new(uZ()).ActorOptimizeQueryOperationFilterPushdown({name:"urn:comunica:default:optimize-query-operation/actors#filter-pushdown",bus:r,beforeActors:[K]});new(lZ()).ActorDereferenceHttp({mediatorHttp:Ie,maxAcceptHeaderLength:1024,maxAcceptHeaderLengthBrowser:128,name:"urn:comunica:default:dereference/actors#http",bus:c,beforeActors:[Oe]}),new(hZ()).ActorHttpProxy({mediatorHttp:Ie,name:"urn:comunica:default:http/actors#proxy",bus:D,beforeActors:[ce]}),new(yZ()).ActorContextPreprocessQuerySourceIdentify({cacheSize:100,httpInvalidator:H,mediatorQuerySourceIdentify:G,mediatorContextPreprocess:Q,name:"urn:comunica:default:context-preprocess/actors#query-source-identify",bus:s,beforeActors:[q]});const me=new V3.ActorInitQuery({mediatorQueryProcess:qe,mediatorQueryResultSerialize:he,mediatorQueryResultSerializeMediaTypeCombiner:xe,mediatorQueryResultSerializeMediaTypeFormatCombiner:ie,mediatorHttpInvalidate:re,defaultQueryInputFormat:"sparql",allowNoSources:!1,name:"urn:comunica:default:init/actors#query",bus:u});new(gZ()).ActorRdfUpdateQuadsHypermedia({cacheSize:100,httpInvalidator:be,mediatorDereferenceRdf:ge,mediatorMetadata:$,mediatorMetadataExtract:R,mediatorRdfUpdateHypermedia:Y,name:"urn:comunica:default:rdf-update-quads/actors#hypermedia",bus:A});const Se=new(Z8()).ActionObserverHttp({httpInvalidator:Re,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-query-result-serialize-sparql-json/^3.0.0/components/ActorQueryResultSerializeSparqlJson.jsonld#ActorQueryResultSerializeSparqlJson_default_observer",bus:D}),W=new(n5()).ActionObserverHttp({httpInvalidator:Ce,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-query-result-serialize-stats/^3.0.0/components/ActorQueryResultSerializeStats.jsonld#ActorQueryResultSerializeStats_default_observer",bus:D});new(OZ()).ActorQuerySourceIdentifyHypermediaQpf({mediatorMetadata:$,mediatorMetadataExtract:R,mediatorDereferenceRdf:ge,mediatorMergeBindingsContext:Qe,subjectUri:"http://www.w3.org/1999/02/22-rdf-syntax-ns#subject",predicateUri:"http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate",objectUri:"http://www.w3.org/1999/02/22-rdf-syntax-ns#object",graphUri:"http://www.w3.org/ns/sparql-service-description#graph",name:"urn:comunica:default:query-source-identify-hypermedia/actors#qpf",bus:l}),new(xZ()).ActorQuerySourceIdentifyHypermediaSparql({mediatorHttp:Ie,mediatorMergeBindingsContext:Qe,checkUrlSuffix:!0,forceHttpGet:!1,cacheSize:1024,bindMethod:"values",countTimeout:3e3,name:"urn:comunica:default:rdf-resolve-quad-pattern/actors#sparql",bus:l}),new(VZ()).ActorQuerySourceIdentifyHypermediaNone({mediatorMergeBindingsContext:Qe,name:"urn:comunica:default:query-source-identify-hypermedia/actors#none",bus:l}),new(Dee()).ActorQueryOperationExtend({mediatorMergeBindingsContext:Qe,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#extend",bus:E}),new(Cee()).ActorQueryOperationFilter({mediatorMergeBindingsContext:Qe,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#filter",bus:E}),new(Mee()).ActorQueryOperationGroup({mediatorHashBindings:Z,mediatorMergeBindingsContext:Qe,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#group",bus:E}),new(qee()).ActorQueryOperationLeftJoin({mediatorJoin:F,mediatorMergeBindingsContext:Qe,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#leftjoin",bus:E}),new(Uee()).ActorQueryOperationNop({mediatorMergeBindingsContext:Qe,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#nop",bus:E}),new(Qee()).ActorQueryOperationOrderBy({mediatorMergeBindingsContext:Qe,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#orderby",bus:E}),new(kee()).ActorQueryOperationService({forceSparqlEndpoint:!1,mediatorMergeBindingsContext:Qe,mediatorQuerySourceIdentify:G,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#service",bus:E}),new(Gee()).ActorQueryOperationValues({mediatorMergeBindingsContext:Qe,name:"urn:comunica:default:query-operation/actors#values",bus:E}),new(Jee()).ActorQueryOperationPathOneOrMore({mediatorMergeBindingsContext:Qe,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#path-one-or-more",bus:E}),new(Kee()).ActorQueryOperationPathZeroOrMore({mediatorMergeBindingsContext:Qe,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#path-zero-or-more",bus:E}),new(Zee()).ActorQueryOperationPathZeroOrOne({mediatorMergeBindingsContext:Qe,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#path-zero-or-one",bus:E}),new(tte()).ActorQueryOperationUpdateDeleteInsert({mediatorUpdateQuads:te,mediatorMergeBindingsContext:Qe,mediatorQueryOperation:Ee,name:"urn:comunica:default:query-operation/actors#update-delete-insert",bus:E});const we=new(ite()).ActorQueryProcessSequential({mediatorContextPreprocess:Q,mediatorQueryParse:X,mediatorOptimizeQueryOperation:fe,mediatorQueryOperation:Ee,mediatorMergeBindingsContext:Qe,name:"urn:comunica:default:query-process/actors#sequential",bus:O}),Te=new(dte()).ActorQuerySourceIdentifyHypermedia({cacheSize:100,maxIterators:64,aggregateTraversalStore:!0,mediatorDereferenceRdf:ge,mediatorMetadata:$,mediatorMetadataExtract:R,mediatorMetadataAccumulate:N,mediatorQuerySourceIdentifyHypermedia:ae,mediatorRdfResolveHypermediaLinks:k,mediatorRdfResolveHypermediaLinksQueue:B,mediatorMergeBindingsContext:Qe,name:"urn:comunica:default:query-source-identify/actors#hypermedia",bus:P});new(hte()).ActorRdfJoinNone({mediatorMergeBindingsContext:Qe,mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#inner-none",bus:j}),new(dB()).ActorRdfJoinMultiBind({bindOrder:"depth-first",selectivityModifier:1e-4,mediatorJoinEntriesSort:de,mediatorQueryOperation:Ee,mediatorMergeBindingsContext:Qe,mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#inner-multi-bind",bus:j}),new(bte()).ActorRdfJoinOptionalBind({bindOrder:"depth-first",selectivityModifier:1e-6,mediatorQueryOperation:Ee,mediatorMergeBindingsContext:Qe,mediatorJoinSelectivity:oe,name:"urn:comunica:default:rdf-join/actors#optional-bind",bus:j}),new(Z8()).ActorQueryResultSerializeSparqlJson({emitMetadata:!0,httpObserver:Se,mediaTypePriorities:{"application/sparql-results+json":.8},mediaTypeFormats:{"application/sparql-results+json":"http://www.w3.org/ns/formats/SPARQL_Results_JSON"},name:"urn:comunica:default:query-result-serialize/actors#sparql-json",bus:o}),new(n5()).ActorQueryResultSerializeStats({httpObserver:W,mediaTypePriorities:{stats:.5},mediaTypeFormats:{stats:"https://comunica.linkeddatafragments.org/#results_stats"},name:"urn:comunica:default:query-result-serialize/actors#stats",bus:o}),new(mte()).ActorQueryProcessExplainParsed({queryProcessor:we,name:"urn:comunica:default:query-process/actors#explain-parsed",bus:O}),new(vte()).ActorQueryProcessExplainLogical({queryProcessor:we,name:"urn:comunica:default:query-process/actors#explain-logical",bus:O}),new(Ste()).ActorQueryProcessExplainPhysical({queryProcessor:we,name:"urn:comunica:default:query-process/actors#explain-physical",bus:O});const Le=new(Ate()).ActorOptimizeQueryOperationPruneEmptySourceOperations({useAskIfSupported:!1,name:"urn:comunica:default:optimize-query-operation/actors#prune-empty-source-operations",bus:r,beforeActors:[ke]});new(rA()).ActorQuerySourceIdentifyRdfJs({mediatorMergeBindingsContext:Qe,name:"urn:comunica:default:query-source-identify/actors#rdfjs",bus:P,beforeActors:[Te]}),new(Ote()).ActorQuerySourceIdentifySerialized({mediatorRdfParse:T,mediatorQuerySourceIdentify:G,name:"urn:comunica:default:query-source-identify/actors#serialized",bus:P,beforeActors:[Te]});const $e=new(xte()).ActorOptimizeQueryOperationJoinConnected({name:"urn:comunica:default:optimize-query-operation/actors#join-connected",bus:r,beforeActors:[Le]}),We=new(Pte()).ActorOptimizeQueryOperationBgpToJoin({name:"urn:comunica:default:optimize-query-operation/actors#bgp-to-join",bus:r,beforeActors:[$e]}),tt=new(Nte()).ActorOptimizeQueryOperationJoinBgp({name:"urn:comunica:default:optimize-query-operation/actors#join-bgp",bus:r,beforeActors:[We]}),lt=new(jte()).ActorOptimizeQueryOperationAssignSourcesExhaustive({name:"urn:comunica:default:optimize-query-operation/actors#assign-sources-exhaustive",bus:r,beforeActors:[tt]});return new(Mte()).ActorOptimizeQueryOperationDescribeToConstructsSubject({name:"urn:comunica:default:optimize-query-operation/actors#describe-to-constructs-subject",bus:r,beforeActors:[lt]}),me};Object.defineProperty(yb,"__esModule",{value:!0});yb.QueryEngine=void 0;const qte=V3,Bte=Fte;class Ute extends qte.QueryEngineBase{constructor(e=Bte()){super(e)}}yb.QueryEngine=Ute;(function(t){var e=I&&I.__createBinding||(Object.create?function(s,n,r,a){a===void 0&&(a=r);var o=Object.getOwnPropertyDescriptor(n,r);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[r]}}),Object.defineProperty(s,a,o)}:function(s,n,r,a){a===void 0&&(a=r),s[a]=n[r]}),u=I&&I.__exportStar||function(s,n){for(var r in s)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&e(n,s,r)};Object.defineProperty(t,"__esModule",{value:!0}),u(yb,t)})(D9);var Js=globalThis&&globalThis.__awaiter||function(t,e,u,s){function n(r){return r instanceof u?r:new u(function(a){a(r)})}return new(u||(u=Promise))(function(r,a){function o(d){try{c(s.next(d))}catch(h){a(h)}}function l(d){try{c(s.throw(d))}catch(h){a(h)}}function c(d){d.done?r(d.value):n(d.value).then(o,l)}c((s=s.apply(t,e||[])).next())})};const Zb=new D9.QueryEngine;function Hte(t,e){return Js(this,void 0,void 0,function*(){let u=yield $te(e||t);return u=u.replace("{url}",t),yield Qte(u)})}function $te(t){return Js(this,void 0,void 0,function*(){var e,u;const n=(e=(yield fetch(t,{method:"HEAD"})).headers.get("Link-Template"))===null||e===void 0?void 0:e.split(",").map(a=>{const o=a.trim().split(";"),l=o[0].trim().slice(1,-1),c=o[1].trim().split("=")[1].trim().slice(1,-1);return{url:l,rel:c}}),r=(u=n==null?void 0:n.find(a=>a.rel==="eventlog"))===null||u===void 0?void 0:u.url;if(!r)throw new Error("No event log found");return console.log("Found event log: "+r),r})}function Qte(t){return Js(this,void 0,void 0,function*(){const e=` - PREFIX ldes: - PREFIX tree: - PREFIX as: - - SELECT ?member - WHERE { - ?id a ldes:EventStream; - tree:member ?member. - }`;return(yield Zb.queryBindings(e,{sources:[t],lenient:!0})).transform({map:s=>Js(this,void 0,void 0,function*(){const n=s.get("member").value;return yield Vte(n)})})})}function Vte(t){return Js(this,void 0,void 0,function*(){const e=` - PREFIX as: - - SELECT ?id ?actorUrl ?actorName ?object ?targetUrl ?targetName ?context - WHERE { - ?id as:actor ?actorUrl; - as:object ?object. - OPTIONAL { ?id as:target ?targetUrl. } - OPTIONAL { ?actorUrl as:name ?actorName. } - OPTIONAL { ?targetUrl as:name ?targetName. } - OPTIONAL { ?id as:context ?context. } - } LIMIT 1`,u=yield(yield Zb.queryBindings(e,{sources:[t],lenient:!0})).toArray();u.length!==1&&console.warn(`Found ${u.length} results for content, expected 1.`);const s=u.map(n=>{var r,a,o,l;return{id:n.get("id").value,actorUrl:n.get("actorUrl").value,actorName:(r=n.get("actorName"))===null||r===void 0?void 0:r.value,object:n.get("object").value,targetUrl:(a=n.get("targetUrl"))===null||a===void 0?void 0:a.value,targetName:(o=n.get("targetName"))===null||o===void 0?void 0:o.value,context:(l=n.get("context"))===null||l===void 0?void 0:l.value,types:[],objectTypes:[],objectRelationship:{}}})[0];return s.types=yield hM(s.id,t),s.objectTypes=yield hM(s.object,t),s.objectTypes.includes("https://www.w3.org/ns/activitystreams#Relationship")&&(s.objectRelationship=yield kte(s.object,t)),s})}function hM(t,e){return Js(this,void 0,void 0,function*(){if(!t)return[];const u=` - SELECT ?type - WHERE { - <${t}> a ?type. - }`;return(yield(yield Zb.queryBindings(u,{sources:[e],lenient:!0})).toArray()).map(n=>n.get("type").value)})}function kte(t,e){return Js(this,void 0,void 0,function*(){if(!t)return{object:void 0,relationship:void 0,subject:void 0};const u=` - PREFIX as: - - SELECT ?subject ?relationship ?object - WHERE { - <${t}> as:subject ?subject; - as:relationship ?relationship; - as:object ?object. - } LIMIT 1`;return(yield(yield Zb.queryBindings(u,{sources:[e],lenient:!0})).toArray()).map(n=>({subject:n.get("subject").value,relationship:n.get("relationship").value,object:n.get("object").value}))[0]||{}})}const zte={name:"ScholarlyBrowser",components:{MDBContainer:F$,MDBCard:m$,MDBCardBody:v$,MDBCardText:A$,MDBInput:Y$,MDBCardTitle:S$},data(){return{artifactUrl:"",serviceNodeUrl:"",members:[],loading:!1,noEventLog:!1,lastUpdated:0}},created(){this.$watch("$route.query.artifactUrl",()=>{this.artifactUrl=this.$route.query.artifactUrl||"",this.artifactUrl.trim(),this.urlUpdated()}),this.$watch("$route.query.serviceNodeUrl",()=>{this.serviceNodeUrl=this.$route.query.serviceNodeUrl||"",this.serviceNodeUrl.trim(),this.urlUpdated()})},methods:{async urlUpdated(){if(this.noEventLog=!1,this.loading=!1,this.members=[],!(Date.now()-this.lastUpdated<1e3)&&(this.lastUpdated=Date.now(),this.$router.push({query:{artifactUrl:this.artifactUrl,serviceNodeUrl:this.serviceNodeUrl}}),!!this.artifactUrl)){this.loading=!0;try{const t=await Hte(this.artifactUrl.trim(),this.serviceNodeUrl.trim());t.on("data",async e=>{e=await e,e.mainTypes=await this.getMainTypes(e.types),e.secondaryTypes=await this.getSecondaryTypes(e.types),e.objectTypes=await Promise.all(await(e==null?void 0:e.objectTypes.map(async u=>await this.getPrefixedProperty(u))))??[],this.members.push(e),this.loading=!1}),t.on("end",()=>{this.loading=!1})}catch{this.noEventLog=!0,this.loading=!1;return}}},async getMainTypes(t){return await Promise.all(t.filter(e=>e.startsWith("https://www.w3.org/ns/activitystreams#")).map(async e=>await this.getPrefixedProperty(e)))},async getSecondaryTypes(t){return await Promise.all(t.filter(e=>!e.startsWith("https://www.w3.org/ns/activitystreams#")).map(async e=>await this.getPrefixedProperty(e)))},async getPrefixedProperty(t){const e=await fetch(`https://prefixcc-proxy.smessie.com/?q=${encodeURIComponent(t)}`,{method:"HEAD"});return e.url.includes(`/?q=${encodeURIComponent(t)}`)?t:e.url.split("prefixcc-proxy.smessie.com/")[1]},getStyleByMainType(t){switch(t){case"as:Create":return"success";case"as:Remove":return"dark";case"as:Announce":return"warning";case"as:Offer":return"primary";case"as:Accept":return"info";case"as:Reject":return"danger";case"as:Undo":return"secondary";case"as:Update":default:return"light"}}}},Gte=""+new URL("../forkme_right_gray.png",import.meta.url).href;const Wte=(t,e)=>{const u=t.__vccOpts||t;for(const[s,n]of e)u[s]=n;return u},Di=t=>(UU("data-v-e979a9d8"),t=t(),HU(),t),Jte=Di(()=>Bt("a",{href:"https://github.com/MellonScholarlyCommunication/scholarly-browser"},[Bt("img",{loading:"lazy",width:"149",height:"149",src:Gte,class:"attachment-full size-full fork",alt:"Fork me on GitHub","data-recalc-dims":"1"})],-1)),Xte=Di(()=>Bt("h1",null,"Scholarly Browser",-1)),Kte=Di(()=>Bt("small",null,"Provide an optional service node URL to retrieve the event notifications from the service node.",-1)),Yte={key:0,class:"status-message"},Zte={key:1,class:"status-message"},ere=Di(()=>Bt("b",null,"No event log found.",-1)),tre=Di(()=>Bt("b",null,"Actor: ",-1)),rre=["href"],nre=Di(()=>Bt("b",null,"Target: ",-1)),ire=["href"],are={key:1},sre=Di(()=>Bt("b",null,"Context: ",-1)),ore=["href"],ure={key:1},cre=Di(()=>Bt("b",null,"Object: ",-1)),lre=["href"],dre={key:0},fre=Di(()=>Bt("b",null,"Subject: ",-1)),hre=["href"],pre=Di(()=>Bt("b",null,"Relationship: ",-1)),yre=["href"],bre=Di(()=>Bt("b",null,"Object: ",-1)),gre=["href"];function mre(t,e,u,s,n,r){const a=po("MDBInput"),o=po("MDBCardText"),l=po("MDBCardBody"),c=po("MDBCard"),d=po("MDBCardTitle"),h=po("MDBContainer");return jt(),nr(Rn,null,[Jte,ir(h,null,{default:Lr(()=>[Xte,ir(c,null,{default:Lr(()=>[ir(l,{class:"w-100"},{default:Lr(()=>[ir(o,null,{default:Lr(()=>[ir(a,{label:"Artifact URL",modelValue:n.artifactUrl,"onUpdate:modelValue":e[0]||(e[0]=f=>n.artifactUrl=f),onChange:r.urlUpdated},null,8,["modelValue","onChange"]),ir(a,{label:"Service Node URL",modelValue:n.serviceNodeUrl,"onUpdate:modelValue":e[1]||(e[1]=f=>n.serviceNodeUrl=f),onChange:r.urlUpdated,class:"mt-3"},null,8,["modelValue","onChange"]),Kte]),_:1})]),_:1})]),_:1}),ir(c,null,{default:Lr(()=>[ir(l,{class:"w-100"},{default:Lr(()=>[ir(o,null,{default:Lr(()=>[n.loading?(jt(),nr("p",Yte,"Loading notifications...")):Vr("",!0),n.noEventLog?(jt(),nr("p",Zte,[ere,m0(" Make sure the provided URL contains a ldes:EventStream Link header.")])):Vr("",!0),(jt(!0),nr(Rn,null,qA(n.members,(f,p)=>(jt(),xi(c,{key:p,border:r.getStyleByMainType(f.mainTypes[0])},{default:Lr(()=>[ir(l,{class:"w-100",style:{"padding-bottom":"0"}},{default:Lr(()=>[ir(d,null,{default:Lr(()=>[m0(Or(f.mainTypes.join(", ")),1)]),_:2},1024),ir(d,{subtitle:"",class:"mb-2 text-muted"},{default:Lr(()=>[m0(Or(f.secondaryTypes.join(", ")),1)]),_:2},1024),ir(o,null,{default:Lr(()=>[Bt("p",null,[tre,Bt("a",{href:f.actorUrl},Or(f.actorName??f.actorUrl),9,rre)]),Bt("p",null,[nre,f.targetUrl?(jt(),nr("a",{key:0,href:f.targetUrl},Or(f.targetName??f.targetUrl),9,ire)):(jt(),nr("i",are,""))]),Bt("p",null,[sre,f.context?(jt(),nr("a",{key:0,href:"?url="+f.context},Or(f.context),9,ore)):(jt(),nr("i",ure,""))]),Bt("p",null,[cre,Bt("a",{href:"?url="+f.object},Or(f.object),9,lre)]),Bt("ul",null,[(jt(!0),nr(Rn,null,qA(f.objectTypes,(y,b)=>(jt(),nr("li",{key:b},[m0(Or(y)+" ",1),y==="as:Relationship"?(jt(),nr("ul",dre,[Bt("li",null,[fre,Bt("a",{href:f.objectRelationship.subject},Or(f.objectRelationship.subject),9,hre)]),Bt("li",null,[pre,Bt("a",{href:f.objectRelationship.relationship},Or(f.objectRelationship.relationship),9,yre)]),Bt("li",null,[bre,Bt("a",{href:f.objectRelationship.object},Or(f.objectRelationship.object),9,gre)])])):Vr("",!0)]))),128))])]),_:2},1024)]),_:2},1024)]),_:2},1032,["border"]))),128))]),_:1})]),_:1})]),_:1})]),_:1})],64)}const _re=Wte(zte,[["render",mre],["__scopeId","data-v-e979a9d8"]]),hB=Ri({__name:"App",setup(t){return(e,u)=>(jt(),nr("main",null,[ir(_re)]))}});/*! - * vue-router v4.2.5 - * (c) 2023 Eduardo San Martin Morote - * @license MIT - */const So=typeof window<"u";function vre(t){return t.__esModule||t[Symbol.toStringTag]==="Module"}const Zt=Object.assign;function IS(t,e){const u={};for(const s in e){const n=e[s];u[s]=Oi(n)?n.map(t):t(n)}return u}const L0=()=>{},Oi=Array.isArray,wre=/\/$/,Sre=t=>t.replace(wre,"");function PS(t,e,u="/"){let s,n={},r="",a="";const o=e.indexOf("#");let l=e.indexOf("?");return o=0&&(l=-1),l>-1&&(s=e.slice(0,l),r=e.slice(l+1,o>-1?o:e.length),n=t(r)),o>-1&&(s=s||e.slice(0,o),a=e.slice(o,e.length)),s=Ore(s??e,u),{fullPath:s+(r&&"?")+r+a,path:s,query:n,hash:a}}function Tre(t,e){const u=e.query?t(e.query):"";return e.path+(u&&"?")+u+(e.hash||"")}function pM(t,e){return!e||!t.toLowerCase().startsWith(e.toLowerCase())?t:t.slice(e.length)||"/"}function Are(t,e,u){const s=e.matched.length-1,n=u.matched.length-1;return s>-1&&s===n&&$o(e.matched[s],u.matched[n])&&pB(e.params,u.params)&&t(e.query)===t(u.query)&&e.hash===u.hash}function $o(t,e){return(t.aliasOf||t)===(e.aliasOf||e)}function pB(t,e){if(Object.keys(t).length!==Object.keys(e).length)return!1;for(const u in t)if(!Ere(t[u],e[u]))return!1;return!0}function Ere(t,e){return Oi(t)?yM(t,e):Oi(e)?yM(e,t):t===e}function yM(t,e){return Oi(e)?t.length===e.length&&t.every((u,s)=>u===e[s]):t.length===1&&t[0]===e}function Ore(t,e){if(t.startsWith("/"))return t;if(!t)return e;const u=e.split("/"),s=t.split("/"),n=s[s.length-1];(n===".."||n===".")&&s.push("");let r=u.length-1,a,o;for(a=0;a1&&r--;else break;return u.slice(0,r).join("/")+"/"+s.slice(a-(a===s.length?1:0)).join("/")}var Z0;(function(t){t.pop="pop",t.push="push"})(Z0||(Z0={}));var M0;(function(t){t.back="back",t.forward="forward",t.unknown=""})(M0||(M0={}));function Rre(t){if(!t)if(So){const e=document.querySelector("base");t=e&&e.getAttribute("href")||"/",t=t.replace(/^\w+:\/\/[^\/]+/,"")}else t="/";return t[0]!=="/"&&t[0]!=="#"&&(t="/"+t),Sre(t)}const xre=/^[^#]+#/;function Ire(t,e){return t.replace(xre,"#")+e}function Pre(t,e){const u=document.documentElement.getBoundingClientRect(),s=t.getBoundingClientRect();return{behavior:e.behavior,left:s.left-u.left-(e.left||0),top:s.top-u.top-(e.top||0)}}const eg=()=>({left:window.pageXOffset,top:window.pageYOffset});function Dre(t){let e;if("el"in t){const u=t.el,s=typeof u=="string"&&u.startsWith("#"),n=typeof u=="string"?s?document.getElementById(u.slice(1)):document.querySelector(u):u;if(!n)return;e=Pre(n,t)}else e=t;"scrollBehavior"in document.documentElement.style?window.scrollTo(e):window.scrollTo(e.left!=null?e.left:window.pageXOffset,e.top!=null?e.top:window.pageYOffset)}function bM(t,e){return(history.state?history.state.position-e:-1)+t}const _3=new Map;function Nre(t,e){_3.set(t,e)}function Cre(t){const e=_3.get(t);return _3.delete(t),e}let jre=()=>location.protocol+"//"+location.host;function yB(t,e){const{pathname:u,search:s,hash:n}=e,r=t.indexOf("#");if(r>-1){let o=n.includes(t.slice(r))?t.slice(r).length:1,l=n.slice(o);return l[0]!=="/"&&(l="/"+l),pM(l,"")}return pM(u,t)+s+n}function Lre(t,e,u,s){let n=[],r=[],a=null;const o=({state:f})=>{const p=yB(t,location),y=u.value,b=e.value;let m=0;if(f){if(u.value=p,e.value=f,a&&a===y){a=null;return}m=b?f.position-b.position:0}else s(p);n.forEach(g=>{g(u.value,y,{delta:m,type:Z0.pop,direction:m?m>0?M0.forward:M0.back:M0.unknown})})};function l(){a=u.value}function c(f){n.push(f);const p=()=>{const y=n.indexOf(f);y>-1&&n.splice(y,1)};return r.push(p),p}function d(){const{history:f}=window;f.state&&f.replaceState(Zt({},f.state,{scroll:eg()}),"")}function h(){for(const f of r)f();r=[],window.removeEventListener("popstate",o),window.removeEventListener("beforeunload",d)}return window.addEventListener("popstate",o),window.addEventListener("beforeunload",d,{passive:!0}),{pauseListeners:l,listen:c,destroy:h}}function gM(t,e,u,s=!1,n=!1){return{back:t,current:e,forward:u,replaced:s,position:window.history.length,scroll:n?eg():null}}function Mre(t){const{history:e,location:u}=window,s={value:yB(t,u)},n={value:e.state};n.value||r(s.value,{back:null,current:s.value,forward:null,position:e.length-1,replaced:!0,scroll:null},!0);function r(l,c,d){const h=t.indexOf("#"),f=h>-1?(u.host&&document.querySelector("base")?t:t.slice(h))+l:jre()+t+l;try{e[d?"replaceState":"pushState"](c,"",f),n.value=c}catch(p){console.error(p),u[d?"replace":"assign"](f)}}function a(l,c){const d=Zt({},e.state,gM(n.value.back,l,n.value.forward,!0),c,{position:n.value.position});r(l,d,!0),s.value=l}function o(l,c){const d=Zt({},n.value,e.state,{forward:l,scroll:eg()});r(d.current,d,!0);const h=Zt({},gM(s.value,l,null),{position:d.position+1},c);r(l,h,!1),s.value=l}return{location:s,state:n,push:o,replace:a}}function Fre(t){t=Rre(t);const e=Mre(t),u=Lre(t,e.state,e.location,e.replace);function s(r,a=!0){a||u.pauseListeners(),history.go(r)}const n=Zt({location:"",base:t,go:s,createHref:Ire.bind(null,t)},e,u);return Object.defineProperty(n,"location",{enumerable:!0,get:()=>e.location.value}),Object.defineProperty(n,"state",{enumerable:!0,get:()=>e.state.value}),n}function qre(t){return typeof t=="string"||t&&typeof t=="object"}function bB(t){return typeof t=="string"||typeof t=="symbol"}const Ia={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0},gB=Symbol("");var mM;(function(t){t[t.aborted=4]="aborted",t[t.cancelled=8]="cancelled",t[t.duplicated=16]="duplicated"})(mM||(mM={}));function Qo(t,e){return Zt(new Error,{type:t,[gB]:!0},e)}function da(t,e){return t instanceof Error&&gB in t&&(e==null||!!(t.type&e))}const _M="[^/]+?",Bre={sensitive:!1,strict:!1,start:!0,end:!0},Ure=/[.+*?^${}()[\]/\\]/g;function Hre(t,e){const u=Zt({},Bre,e),s=[];let n=u.start?"^":"";const r=[];for(const c of t){const d=c.length?[]:[90];u.strict&&!c.length&&(n+="/");for(let h=0;he.length?e.length===1&&e[0]===40+40?1:-1:0}function Qre(t,e){let u=0;const s=t.score,n=e.score;for(;u0&&e[e.length-1]<0}const Vre={type:0,value:""},kre=/[a-zA-Z0-9_]/;function zre(t){if(!t)return[[]];if(t==="/")return[[Vre]];if(!t.startsWith("/"))throw new Error(`Invalid path "${t}"`);function e(p){throw new Error(`ERR (${u})/"${c}": ${p}`)}let u=0,s=u;const n=[];let r;function a(){r&&n.push(r),r=[]}let o=0,l,c="",d="";function h(){c&&(u===0?r.push({type:0,value:c}):u===1||u===2||u===3?(r.length>1&&(l==="*"||l==="+")&&e(`A repeatable param (${c}) must be alone in its segment. eg: '/:ids+.`),r.push({type:1,value:c,regexp:d,repeatable:l==="*"||l==="+",optional:l==="*"||l==="?"})):e("Invalid state to consume buffer"),c="")}function f(){c+=l}for(;o{a(v)}:L0}function a(d){if(bB(d)){const h=s.get(d);h&&(s.delete(d),u.splice(u.indexOf(h),1),h.children.forEach(a),h.alias.forEach(a))}else{const h=u.indexOf(d);h>-1&&(u.splice(h,1),d.record.name&&s.delete(d.record.name),d.children.forEach(a),d.alias.forEach(a))}}function o(){return u}function l(d){let h=0;for(;h=0&&(d.record.path!==u[h].record.path||!mB(d,u[h]));)h++;u.splice(h,0,d),d.record.name&&!SM(d)&&s.set(d.record.name,d)}function c(d,h){let f,p={},y,b;if("name"in d&&d.name){if(f=s.get(d.name),!f)throw Qo(1,{location:d});b=f.record.name,p=Zt(wM(h.params,f.keys.filter(v=>!v.optional).map(v=>v.name)),d.params&&wM(d.params,f.keys.map(v=>v.name))),y=f.stringify(p)}else if("path"in d)y=d.path,f=u.find(v=>v.re.test(y)),f&&(p=f.parse(y),b=f.record.name);else{if(f=h.name?s.get(h.name):u.find(v=>v.re.test(h.path)),!f)throw Qo(1,{location:d,currentLocation:h});b=f.record.name,p=Zt({},h.params,d.params),y=f.stringify(p)}const m=[];let g=f;for(;g;)m.unshift(g.record),g=g.parent;return{name:b,path:y,params:p,matched:m,meta:Kre(m)}}return t.forEach(d=>r(d)),{addRoute:r,resolve:c,removeRoute:a,getRoutes:o,getRecordMatcher:n}}function wM(t,e){const u={};for(const s of e)s in t&&(u[s]=t[s]);return u}function Jre(t){return{path:t.path,redirect:t.redirect,name:t.name,meta:t.meta||{},aliasOf:void 0,beforeEnter:t.beforeEnter,props:Xre(t),children:t.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in t?t.components||null:t.component&&{default:t.component}}}function Xre(t){const e={},u=t.props||!1;if("component"in t)e.default=u;else for(const s in t.components)e[s]=typeof u=="object"?u[s]:u;return e}function SM(t){for(;t;){if(t.record.aliasOf)return!0;t=t.parent}return!1}function Kre(t){return t.reduce((e,u)=>Zt(e,u.meta),{})}function TM(t,e){const u={};for(const s in t)u[s]=s in e?e[s]:t[s];return u}function mB(t,e){return e.children.some(u=>u===t||mB(t,u))}const _B=/#/g,Yre=/&/g,Zre=/\//g,ene=/=/g,tne=/\?/g,vB=/\+/g,rne=/%5B/g,nne=/%5D/g,wB=/%5E/g,ine=/%60/g,SB=/%7B/g,ane=/%7C/g,TB=/%7D/g,sne=/%20/g;function iA(t){return encodeURI(""+t).replace(ane,"|").replace(rne,"[").replace(nne,"]")}function one(t){return iA(t).replace(SB,"{").replace(TB,"}").replace(wB,"^")}function v3(t){return iA(t).replace(vB,"%2B").replace(sne,"+").replace(_B,"%23").replace(Yre,"%26").replace(ine,"`").replace(SB,"{").replace(TB,"}").replace(wB,"^")}function une(t){return v3(t).replace(ene,"%3D")}function cne(t){return iA(t).replace(_B,"%23").replace(tne,"%3F")}function lne(t){return t==null?"":cne(t).replace(Zre,"%2F")}function tb(t){try{return decodeURIComponent(""+t)}catch{}return""+t}function dne(t){const e={};if(t===""||t==="?")return e;const s=(t[0]==="?"?t.slice(1):t).split("&");for(let n=0;nr&&v3(r)):[s&&v3(s)]).forEach(r=>{r!==void 0&&(e+=(e.length?"&":"")+u,r!=null&&(e+="="+r))})}return e}function fne(t){const e={};for(const u in t){const s=t[u];s!==void 0&&(e[u]=Oi(s)?s.map(n=>n==null?null:""+n):s==null?s:""+s)}return e}const hne=Symbol(""),EM=Symbol(""),aA=Symbol(""),AB=Symbol(""),w3=Symbol("");function y0(){let t=[];function e(s){return t.push(s),()=>{const n=t.indexOf(s);n>-1&&t.splice(n,1)}}function u(){t=[]}return{add:e,list:()=>t.slice(),reset:u}}function Fa(t,e,u,s,n){const r=s&&(s.enterCallbacks[n]=s.enterCallbacks[n]||[]);return()=>new Promise((a,o)=>{const l=h=>{h===!1?o(Qo(4,{from:u,to:e})):h instanceof Error?o(h):qre(h)?o(Qo(2,{from:e,to:h})):(r&&s.enterCallbacks[n]===r&&typeof h=="function"&&r.push(h),a())},c=t.call(s&&s.instances[n],e,u,l);let d=Promise.resolve(c);t.length<3&&(d=d.then(l)),d.catch(h=>o(h))})}function DS(t,e,u,s){const n=[];for(const r of t)for(const a in r.components){let o=r.components[a];if(!(e!=="beforeRouteEnter"&&!r.instances[a]))if(pne(o)){const c=(o.__vccOpts||o)[e];c&&n.push(Fa(c,u,s,r,a))}else{let l=o();n.push(()=>l.then(c=>{if(!c)return Promise.reject(new Error(`Couldn't resolve component "${a}" at "${r.path}"`));const d=vre(c)?c.default:c;r.components[a]=d;const f=(d.__vccOpts||d)[e];return f&&Fa(f,u,s,r,a)()}))}}return n}function pne(t){return typeof t=="object"||"displayName"in t||"props"in t||"__vccOpts"in t}function OM(t){const e=Ti(aA),u=Ti(AB),s=sr(()=>e.resolve(qt(t.to))),n=sr(()=>{const{matched:l}=s.value,{length:c}=l,d=l[c-1],h=u.matched;if(!d||!h.length)return-1;const f=h.findIndex($o.bind(null,d));if(f>-1)return f;const p=RM(l[c-2]);return c>1&&RM(d)===p&&h[h.length-1].path!==p?h.findIndex($o.bind(null,l[c-2])):f}),r=sr(()=>n.value>-1&&mne(u.params,s.value.params)),a=sr(()=>n.value>-1&&n.value===u.matched.length-1&&pB(u.params,s.value.params));function o(l={}){return gne(l)?e[qt(t.replace)?"replace":"push"](qt(t.to)).catch(L0):Promise.resolve()}return{route:s,href:sr(()=>s.value.href),isActive:r,isExactActive:a,navigate:o}}const yne=Ri({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"}},useLink:OM,setup(t,{slots:e}){const u=ob(OM(t)),{options:s}=Ti(aA),n=sr(()=>({[xM(t.activeClass,s.linkActiveClass,"router-link-active")]:u.isActive,[xM(t.exactActiveClass,s.linkExactActiveClass,"router-link-exact-active")]:u.isExactActive}));return()=>{const r=e.default&&e.default(u);return t.custom?r:x9("a",{"aria-current":u.isExactActive?t.ariaCurrentValue:null,href:u.href,onClick:u.navigate,class:n.value},r)}}}),bne=yne;function gne(t){if(!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey)&&!t.defaultPrevented&&!(t.button!==void 0&&t.button!==0)){if(t.currentTarget&&t.currentTarget.getAttribute){const e=t.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(e))return}return t.preventDefault&&t.preventDefault(),!0}}function mne(t,e){for(const u in e){const s=e[u],n=t[u];if(typeof s=="string"){if(s!==n)return!1}else if(!Oi(n)||n.length!==s.length||s.some((r,a)=>r!==n[a]))return!1}return!0}function RM(t){return t?t.aliasOf?t.aliasOf.path:t.path:""}const xM=(t,e,u)=>t??e??u,_ne=Ri({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(t,{attrs:e,slots:u}){const s=Ti(w3),n=sr(()=>t.route||s.value),r=Ti(EM,0),a=sr(()=>{let c=qt(r);const{matched:d}=n.value;let h;for(;(h=d[c])&&!h.components;)c++;return c}),o=sr(()=>n.value.matched[a.value]);x1(EM,sr(()=>a.value+1)),x1(hne,o),x1(w3,n);const l=En();return Io(()=>[l.value,o.value,t.name],([c,d,h],[f,p,y])=>{d&&(d.instances[h]=c,p&&p!==d&&c&&c===f&&(d.leaveGuards.size||(d.leaveGuards=p.leaveGuards),d.updateGuards.size||(d.updateGuards=p.updateGuards))),c&&d&&(!p||!$o(d,p)||!f)&&(d.enterCallbacks[h]||[]).forEach(b=>b(c))},{flush:"post"}),()=>{const c=n.value,d=t.name,h=o.value,f=h&&h.components[d];if(!f)return IM(u.default,{Component:f,route:c});const p=h.props[d],y=p?p===!0?c.params:typeof p=="function"?p(c):p:null,m=x9(f,Zt({},y,e,{onVnodeUnmounted:g=>{g.component.isUnmounted&&(h.instances[d]=null)},ref:l}));return IM(u.default,{Component:m,route:c})||m}}});function IM(t,e){if(!t)return null;const u=t(e);return u.length===1?u[0]:u}const vne=_ne;function wne(t){const e=Wre(t.routes,t),u=t.parseQuery||dne,s=t.stringifyQuery||AM,n=t.history,r=y0(),a=y0(),o=y0(),l=IU(Ia);let c=Ia;So&&t.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const d=IS.bind(null,ge=>""+ge),h=IS.bind(null,lne),f=IS.bind(null,tb);function p(ge,de){let oe,$;return bB(ge)?(oe=e.getRecordMatcher(ge),$=de):$=ge,e.addRoute($,oe)}function y(ge){const de=e.getRecordMatcher(ge);de&&e.removeRoute(de)}function b(){return e.getRoutes().map(ge=>ge.record)}function m(ge){return!!e.getRecordMatcher(ge)}function g(ge,de){if(de=Zt({},de||l.value),typeof ge=="string"){const x=PS(u,ge,de.path),B=e.resolve({path:x.path},de),k=n.createHref(x.fullPath);return Zt(x,B,{params:f(B.params),hash:tb(x.hash),redirectedFrom:void 0,href:k})}let oe;if("path"in ge)oe=Zt({},ge,{path:PS(u,ge.path,de.path).path});else{const x=Zt({},ge.params);for(const B in x)x[B]==null&&delete x[B];oe=Zt({},ge,{params:h(x)}),de.params=h(de.params)}const $=e.resolve(oe,de),N=ge.hash||"";$.params=d(f($.params));const R=Tre(s,Zt({},ge,{hash:one(N),path:$.path})),T=n.createHref(R);return Zt({fullPath:R,hash:N,query:s===AM?fne(ge.query):ge.query||{}},$,{redirectedFrom:void 0,href:T})}function v(ge){return typeof ge=="string"?PS(u,ge,l.value.path):Zt({},ge)}function _(ge,de){if(c!==ge)return Qo(8,{from:de,to:ge})}function w(ge){return D(ge)}function S(ge){return w(Zt(v(ge),{replace:!0}))}function A(ge){const de=ge.matched[ge.matched.length-1];if(de&&de.redirect){const{redirect:oe}=de;let $=typeof oe=="function"?oe(ge):oe;return typeof $=="string"&&($=$.includes("?")||$.includes("#")?$=v($):{path:$},$.params={}),Zt({query:ge.query,hash:ge.hash,params:"path"in $?{}:ge.params},$)}}function D(ge,de){const oe=c=g(ge),$=l.value,N=ge.state,R=ge.force,T=ge.replace===!0,x=A(oe);if(x)return D(Zt(v(x),{state:typeof x=="object"?Zt({},N,x.state):N,force:R,replace:T}),de||oe);const B=oe;B.redirectedFrom=de;let k;return!R&&Are(s,$,oe)&&(k=Qo(16,{to:B,from:$}),he($,$,!0,!1)),(k?Promise.resolve(k):O(B,$)).catch(V=>da(V)?da(V,2)?V:X(V):K(V,B,$)).then(V=>{if(V){if(da(V,2))return D(Zt({replace:T},v(V.to),{state:typeof V.to=="object"?Zt({},N,V.to.state):N,force:R}),de||B)}else V=j(B,$,!0,T,N);return P(B,$,V),V})}function L(ge,de){const oe=_(ge,de);return oe?Promise.reject(oe):Promise.resolve()}function E(ge){const de=ae.values().next().value;return de&&typeof de.runWithContext=="function"?de.runWithContext(ge):ge()}function O(ge,de){let oe;const[$,N,R]=Sne(ge,de);oe=DS($.reverse(),"beforeRouteLeave",ge,de);for(const x of $)x.leaveGuards.forEach(B=>{oe.push(Fa(B,ge,de))});const T=L.bind(null,ge,de);return oe.push(T),Ne(oe).then(()=>{oe=[];for(const x of r.list())oe.push(Fa(x,ge,de));return oe.push(T),Ne(oe)}).then(()=>{oe=DS(N,"beforeRouteUpdate",ge,de);for(const x of N)x.updateGuards.forEach(B=>{oe.push(Fa(B,ge,de))});return oe.push(T),Ne(oe)}).then(()=>{oe=[];for(const x of R)if(x.beforeEnter)if(Oi(x.beforeEnter))for(const B of x.beforeEnter)oe.push(Fa(B,ge,de));else oe.push(Fa(x.beforeEnter,ge,de));return oe.push(T),Ne(oe)}).then(()=>(ge.matched.forEach(x=>x.enterCallbacks={}),oe=DS(R,"beforeRouteEnter",ge,de),oe.push(T),Ne(oe))).then(()=>{oe=[];for(const x of a.list())oe.push(Fa(x,ge,de));return oe.push(T),Ne(oe)}).catch(x=>da(x,8)?x:Promise.reject(x))}function P(ge,de,oe){o.list().forEach($=>E(()=>$(ge,de,oe)))}function j(ge,de,oe,$,N){const R=_(ge,de);if(R)return R;const T=de===Ia,x=So?history.state:{};oe&&($||T?n.replace(ge.fullPath,Zt({scroll:T&&x&&x.scroll},N)):n.push(ge.fullPath,N)),l.value=ge,he(ge,de,oe,T),X()}let U;function M(){U||(U=n.listen((ge,de,oe)=>{if(!Oe.listening)return;const $=g(ge),N=A($);if(N){D(Zt(N,{replace:!0}),$).catch(L0);return}c=$;const R=l.value;So&&Nre(bM(R.fullPath,oe.delta),eg()),O($,R).catch(T=>da(T,12)?T:da(T,2)?(D(T.to,$).then(x=>{da(x,20)&&!oe.delta&&oe.type===Z0.pop&&n.go(-1,!1)}).catch(L0),Promise.reject()):(oe.delta&&n.go(-oe.delta,!1),K(T,$,R))).then(T=>{T=T||j($,R,!1),T&&(oe.delta&&!da(T,8)?n.go(-oe.delta,!1):oe.type===Z0.pop&&da(T,20)&&n.go(-1,!1)),P($,R,T)}).catch(L0)}))}let q=y0(),Q=y0(),Z;function K(ge,de,oe){X(ge);const $=Q.list();return $.length?$.forEach(N=>N(ge,de,oe)):console.error(ge),Promise.reject(ge)}function fe(){return Z&&l.value!==Ia?Promise.resolve():new Promise((ge,de)=>{q.add([ge,de])})}function X(ge){return Z||(Z=!ge,M(),q.list().forEach(([de,oe])=>ge?oe(ge):de()),q.reset()),ge}function he(ge,de,oe,$){const{scrollBehavior:N}=t;if(!So||!N)return Promise.resolve();const R=!oe&&Cre(bM(ge.fullPath,0))||($||!oe)&&history.state&&history.state.scroll||null;return t9().then(()=>N(ge,de,R)).then(T=>T&&Dre(T)).catch(T=>K(T,ge,de))}const xe=ge=>n.go(ge);let ie;const ae=new Set,Oe={currentRoute:l,listening:!0,addRoute:p,removeRoute:y,hasRoute:m,getRoutes:b,resolve:g,options:t,push:w,replace:S,go:xe,back:()=>xe(-1),forward:()=>xe(1),beforeEach:r.add,beforeResolve:a.add,afterEach:o.add,onError:Q.add,isReady:fe,install(ge){const de=this;ge.component("RouterLink",bne),ge.component("RouterView",vne),ge.config.globalProperties.$router=de,Object.defineProperty(ge.config.globalProperties,"$route",{enumerable:!0,get:()=>qt(l)}),So&&!ie&&l.value===Ia&&(ie=!0,w(n.location).catch(N=>{}));const oe={};for(const N in Ia)Object.defineProperty(oe,N,{get:()=>l.value[N],enumerable:!0});ge.provide(aA,de),ge.provide(AB,zM(oe)),ge.provide(w3,l);const $=ge.unmount;ae.add(ge),ge.unmount=function(){ae.delete(ge),ae.size<1&&(c=Ia,U&&U(),U=null,l.value=Ia,ie=!1,Z=!1),$()}}};function Ne(ge){return ge.reduce((de,oe)=>de.then(()=>E(oe)),Promise.resolve())}return Oe}function Sne(t,e){const u=[],s=[],n=[],r=Math.max(e.matched.length,t.matched.length);for(let a=0;a$o(c,o))?s.push(o):u.push(o));const l=t.matched[a];l&&(e.matched.find(c=>$o(c,l))||n.push(l))}return[u,s,n]}const Tne=wne({history:Fre("/scholarly-browser/"),routes:[{path:"/",component:hB,props:!0}]}),EB=i$(hB);EB.use(Tne);EB.mount("#app"); diff --git a/index.html b/index.html index a78219e..dcd67f1 100644 --- a/index.html +++ b/index.html @@ -6,8 +6,8 @@ Scholarly Browser - - + +