@likec4/mcp 1.48.0 → 1.49.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/THIRD-PARTY-LICENSES.md +2417 -0
- package/dist/_chunks/libs/@chevrotain/gast.mjs +1 -1
- package/dist/_chunks/libs/@hono/mcp.mjs +34 -0
- package/dist/_chunks/libs/@mantine/colors-generator.mjs +2 -2
- package/dist/_chunks/libs/@modelcontextprotocol/sdk.mjs +7 -36
- package/dist/_chunks/libs/@radix-ui/colors.mjs +1 -0
- package/dist/_chunks/libs/chevrotain-allstar.mjs +2 -2
- package/dist/_chunks/libs/chevrotain.mjs +30 -30
- package/dist/_chunks/libs/is-error-instance.mjs +1 -1
- package/dist/_chunks/libs/khroma.mjs +1 -1
- package/dist/_chunks/libs/langium.mjs +3 -3
- package/dist/_chunks/libs/merge-error-cause.mjs +2 -2
- package/dist/_chunks/libs/mnemonist.mjs +1 -1
- package/dist/_chunks/libs/p-limit.mjs +1 -1
- package/dist/_chunks/libs/pathe.mjs +1 -0
- package/dist/_chunks/libs/remeda.mjs +1 -1
- package/dist/_chunks/libs/safe-stringify.mjs +1 -1
- package/dist/_chunks/libs/ufo.mjs +1 -1
- package/dist/_chunks/rolldown-runtime.mjs +1 -1
- package/dist/index.mjs +73 -67
- package/package.json +15 -15
- package/dist/_chunks/libs/hono.mjs +0 -1
- package/dist/_chunks/libs/nanoid.mjs +0 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{t as e}from"./is-error-instance.mjs";import{t}from"./is-plain-obj.mjs";const n=e=>{r.forEach(t=>{i(e,t)})},r=[`name`,`message`,`stack`,`cause`,`errors`],i=(e,t)=>{let n=a(e,t);if(n!==void 0){if(o(n)){c(e,t,e[t]);return}s(n)&&l(e,t,n)}},a=(e,t)=>{let n=Object.getOwnPropertyDescriptor(e,t);if(n!==void 0)return n;let r=Object.getPrototypeOf(e);return r===null?void 0:a(r,t)},o=({get:e,set:t})=>e!==void 0&&t===void 0,s=({enumerable:e,writable:t})=>e||!t,c=(e,t,n)=>{l(e,t,{value:n})},l=(e,t,n)=>{Object.defineProperty(e,t,{...n,...`get`in n||`set`in n?{}:{writable:!0},enumerable:!1,configurable:!0})},ee=(e,t)=>{Array.isArray(e.errors)?c(e,`errors`,e.errors.filter(te).map(t).filter(Boolean)):ne(e)?c(e,`errors`,[]):e.errors!==void 0&&re(e)},te=e=>e!==void 0,ne=e=>`AggregateError`in globalThis&&(e.name===`AggregateError`||e instanceof AggregateError),re=e=>{delete e.errors,e.errors!==void 0&&c(e,`errors`,[])},u=(e,t)=>{if(!(`cause`in e))return;let n=e.cause===void 0?e.cause:t(e.cause);n===void 0?delete e.cause:c(e,`cause`,n)},d=e=>!Object.isExtensible(e)||r.some(t=>f(e,t)||p(e,t)),f=(e,t)=>{let n=Object.getOwnPropertyDescriptor(e,t);return n!==void 0&&!n.configurable},p=(e,t)=>{try{return e[t],!1}catch{return!0}},m=e=>{c(e,`stack`,ie(e.message,e.name))},ie=(e=``,t=`Error`)=>{let{stack:n}=new(ae(t))(e);return typeof n==`string`&&n!==``?n:`${t}: ${e}`},ae=e=>{let t={value:e,enumerable:!1,writable:!0,configurable:!0},n=Object.defineProperty(class extends Error{},`name`,t);return Object.defineProperty(n.prototype,`name`,t),n},oe=e=>{let t={};for(let n of se(e))try{let r=e[n],{enumerable:i,configurable:o,writable:s=!0}=a(e,n);Object.defineProperty(t,n,{value:r,enumerable:i,configurable:o,writable:s})}catch{}return t},se=e=>{let t=ce(e);for(let n of r)le(e,n)&&t.push(n);return t},ce=e=>{try{return Reflect.ownKeys(e)}catch{return[]}},le=(e,t)=>{try{return t in e&&!Object.hasOwn(e,t)}catch{return!1}},h=e=>{let{name:t,message:n,stack:r,cause:i,errors:a,...o}=oe(e),s=ue(n,o),c=me(t,s);return n===s&&he(c,o),Object.entries({name:t,stack:r,cause:i,errors:a}).forEach(([e,t])=>{ge(c,e,t)}),r===void 0&&m(c),c},ue=(e,t)=>typeof e==`string`&&e!==``?e:pe(de(t)),de=e=>{try{return JSON.stringify(e)}catch{return fe(e)}},fe=e=>{try{return String(e)}catch{return`Invalid error`}},pe=e=>e.length<g?e:`${e.slice(0,g)}...`,g=1e3,me=(e,t)=>e===`AggregateError`&&`AggregateError`in globalThis?AggregateError([],t):e in _?new _[e](t):Error(t),_={Error,ReferenceError,TypeError,SyntaxError,RangeError,URIError,EvalError},he=(e,t)=>{for(let n in t)n in e||(e[n]=t[n])},ge=(e,t,n)=>{n!==void 0&&c(e,t,n)},_e=e=>{try{let t=Error(String(e));return m(t),t}catch(e){return e}},{toString:ve}=Object.prototype,ye=t=>be(t)?h(t):e(t)?v(t)?h(t):t:_e(t),be=e=>{try{return t(e)}catch{return!1}},v=e=>y(e)||d(e)||b(e),y=e=>{try{return ve.call(e)===`[object Object]`}catch{return!0}},b=e=>typeof e.constructor!=`function`||typeof e.constructor.name!=`string`||e.constructor.name===``||e.constructor.prototype!==Object.getPrototypeOf(e)
|
|
2
|
-
`,vt=({parent:e,child:t,target:n,stackError:r})=>{let i=e.message,a=r.message;return n.message=t.message,X(n,i,a)},yt=(e,t)=>Q(e)===t,Q=e=>typeof e==`object`&&e?e.stack:void 0,bt=({wrap:e,target:t,source:n,childHasStack:r})=>e===r?t:(K(t,`stack`,n.stack),n),xt=e=>{let{wrap:t,name:n}=e;return typeof t==`boolean`?(Object.hasOwn(e,`wrap`)&&delete e.wrap,t):n===`Error`}
|
|
1
|
+
import{t as e}from"./is-error-instance.mjs";import{t}from"./is-plain-obj.mjs";const n=e=>{r.forEach(t=>{i(e,t)})},r=[`name`,`message`,`stack`,`cause`,`errors`],i=(e,t)=>{let n=a(e,t);if(n!==void 0){if(o(n)){c(e,t,e[t]);return}s(n)&&l(e,t,n)}},a=(e,t)=>{let n=Object.getOwnPropertyDescriptor(e,t);if(n!==void 0)return n;let r=Object.getPrototypeOf(e);return r===null?void 0:a(r,t)},o=({get:e,set:t})=>e!==void 0&&t===void 0,s=({enumerable:e,writable:t})=>e||!t,c=(e,t,n)=>{l(e,t,{value:n})},l=(e,t,n)=>{Object.defineProperty(e,t,{...n,...`get`in n||`set`in n?{}:{writable:!0},enumerable:!1,configurable:!0})},ee=(e,t)=>{Array.isArray(e.errors)?c(e,`errors`,e.errors.filter(te).map(t).filter(Boolean)):ne(e)?c(e,`errors`,[]):e.errors!==void 0&&re(e)},te=e=>e!==void 0,ne=e=>`AggregateError`in globalThis&&(e.name===`AggregateError`||e instanceof AggregateError),re=e=>{delete e.errors,e.errors!==void 0&&c(e,`errors`,[])},u=(e,t)=>{if(!(`cause`in e))return;let n=e.cause===void 0?e.cause:t(e.cause);n===void 0?delete e.cause:c(e,`cause`,n)},d=e=>!Object.isExtensible(e)||r.some(t=>f(e,t)||p(e,t)),f=(e,t)=>{let n=Object.getOwnPropertyDescriptor(e,t);return n!==void 0&&!n.configurable},p=(e,t)=>{try{return e[t],!1}catch{return!0}},m=e=>{c(e,`stack`,ie(e.message,e.name))},ie=(e=``,t=`Error`)=>{let{stack:n}=new(ae(t))(e);return typeof n==`string`&&n!==``?n:`${t}: ${e}`},ae=e=>{let t={value:e,enumerable:!1,writable:!0,configurable:!0},n=Object.defineProperty(class extends Error{},`name`,t);return Object.defineProperty(n.prototype,`name`,t),n},oe=e=>{let t={};for(let n of se(e))try{let r=e[n],{enumerable:i,configurable:o,writable:s=!0}=a(e,n);Object.defineProperty(t,n,{value:r,enumerable:i,configurable:o,writable:s})}catch{}return t},se=e=>{let t=ce(e);for(let n of r)le(e,n)&&t.push(n);return t},ce=e=>{try{return Reflect.ownKeys(e)}catch{return[]}},le=(e,t)=>{try{return t in e&&!Object.hasOwn(e,t)}catch{return!1}},h=e=>{let{name:t,message:n,stack:r,cause:i,errors:a,...o}=oe(e),s=ue(n,o),c=me(t,s);return n===s&&he(c,o),Object.entries({name:t,stack:r,cause:i,errors:a}).forEach(([e,t])=>{ge(c,e,t)}),r===void 0&&m(c),c},ue=(e,t)=>typeof e==`string`&&e!==``?e:pe(de(t)),de=e=>{try{return JSON.stringify(e)}catch{return fe(e)}},fe=e=>{try{return String(e)}catch{return`Invalid error`}},pe=e=>e.length<g?e:`${e.slice(0,g)}...`,g=1e3,me=(e,t)=>e===`AggregateError`&&`AggregateError`in globalThis?AggregateError([],t):e in _?new _[e](t):Error(t),_={Error,ReferenceError,TypeError,SyntaxError,RangeError,URIError,EvalError},he=(e,t)=>{for(let n in t)n in e||(e[n]=t[n])},ge=(e,t,n)=>{n!==void 0&&c(e,t,n)},_e=e=>{try{let t=Error(String(e));return m(t),t}catch(e){return e}},{toString:ve}=Object.prototype,ye=t=>be(t)?h(t):e(t)?v(t)?h(t):t:_e(t),be=e=>{try{return t(e)}catch{return!1}},v=e=>y(e)||d(e)||b(e),y=e=>{try{return ve.call(e)===`[object Object]`}catch{return!0}},b=e=>typeof e.constructor!=`function`||typeof e.constructor.name!=`string`||e.constructor.name===``||e.constructor.prototype!==Object.getPrototypeOf(e),x=(e,{shallow:t=!1}={})=>S(e,[],t),S=(e,t,n)=>{if(t.includes(e))return;let r=n?C:r=>S(r,[...t,e],n),i=ye(e);return w(i,r),i},C=e=>e,w=(e,t)=>{T(e),E(e),D(e),u(e,t),ee(e,t),n(e)},T=e=>{if(O(e.name))return;let t=Object.getPrototypeOf(e).name;c(e,`name`,O(t)?t:e.constructor.name)},E=e=>{O(e.message)||c(e,`message`,``)},D=e=>{O(e.stack)||m(e)},O=e=>typeof e==`string`&&e!==``,k=(e,t,n=e.name)=>{if(A(t),typeof n!=`string`)throw TypeError(`currentName must be a string: ${n}`);return n},A=e=>{if(!j(e))throw TypeError(`ErrorClass must be a class: ${e}`);if(!M(e.prototype))throw TypeError(`ErrorClass must inherit from Error: ${e}`);if(!N(e))throw TypeError(`ErrorClass must be have a valid constructor: ${e}`)},j=e=>typeof e==`function`&&typeof e.prototype==`object`&&e.prototype!==null,M=e=>e!==null&&(e.name===`Error`||M(Object.getPrototypeOf(e))),N=e=>typeof e.prototype.constructor==`function`,P=(e,t,n)=>{Object.defineProperty(e,t,{value:n,enumerable:!1,writable:!0,configurable:!0})},xe=(e,t)=>{Object.getPrototypeOf(e)!==t.prototype&&(Se(e,t),L(e,`constructor`),Ce(e,t))},Se=(e,t)=>{Object.setPrototypeOf(e,t.prototype)},Ce=(e,t)=>{L(e,`name`);let n=F(t.prototype);e.name!==n&&P(e,`name`,n)},F=e=>we(e)??Te(e)??F(Object.getPrototypeOf(e)),we=e=>Object.hasOwn(e,`name`)&&I(e.name)?e.name:void 0,Te=e=>typeof e.constructor==`function`&&I(e.constructor.name)?e.constructor.name:void 0,I=e=>typeof e==`string`&&e!==``,L=(e,t)=>{Object.hasOwn(e,t)&&delete e[t]},Ee=(e,t)=>{De(e,t)&&P(e,`stack`,ke(e,t))},De=(e,t)=>t!==e.name&&t!==``&&e.stack.includes(t)&&Oe(),Oe=()=>{class e extends Error{}let t={value:R,enumerable:!1,writable:!0,configurable:!0};Object.defineProperty(e,`name`,t),Object.defineProperty(e.prototype,`name`,t);let{stack:n}=new e(``);return typeof n==`string`&&n.includes(R)},R=`SetErrorClassError`,ke=({name:e,stack:t},n)=>{if(t.startsWith(`${n}: `))return t.replace(n,e);let[r,i]=Ae(n,e).find(([e])=>t.includes(e));return t.replace(r,i)},Ae=(e,t)=>[[`\n${e}: `,`\n${t}: `],[`${e}: `,`${t}: `],[`${e} `,`${t} `],[e,t]],je=(e,t,n)=>{let r=x(e),i=k(r,t,n);return xe(r,t),Ee(r,i),r},Me=(e,t)=>t.configurable===!1?Ne(e,t):Ie(e,t),Ne=(e,t)=>({...t,...Pe(e,t),...Fe(e,t)}),Pe=(e,t)=>t.writable===!0&&e.writable===!1?{writable:!1}:{},Fe=(e,t)=>e.hasValue&&`value`in t&&t.writable===!0?{value:e.value}:{},Ie=(e,t)=>{let n=B(e.enumerable,t.enumerable,!0),r=B(e.writable,t.writable,!0),i=B(e.configurable,t.configurable,!0);return{...Le(e,t,r),enumerable:n,configurable:i}},Le=(e,t,n)=>e.hasValue?{value:e.value,writable:n}:!z(e)&&!z(t)?{value:t.value,writable:n}:{get:B(e.get,t.get),set:B(e.set,t.set)},z=({get:e,set:t})=>e!==void 0||t!==void 0,B=(e,t,n)=>e??t??n,Re=(e,t,n)=>{if(!ze(e))throw TypeError(`Argument must be an object: ${e}`);if(!Be(t))throw TypeError(`Property key must be a string, a symbol or an integer: ${t}`);return Ve(n)},ze=e=>typeof e==`object`&&!!e,Be=e=>{let t=typeof e;return t===`string`||t===`symbol`||t===`number`},Ve=e=>{if(!t(e))throw TypeError(`Descriptor must be a plain object: ${e}`);let{enumerable:n,writable:r,configurable:i,value:a,get:o,set:s,...c}=e,l=`value`in e;return He({enumerable:n,writable:r,configurable:i,get:o,set:s,unknownProps:c,hasValue:l}),{enumerable:n,writable:r,configurable:i,value:a,get:o,set:s,hasValue:l}},He=({enumerable:e,writable:t,configurable:n,get:r,set:i,unknownProps:a,hasValue:o})=>{V(o,r,`get`),V(o,i,`set`),H(e,`enumerable`),H(t,`writable`),H(n,`configurable`),We(a)},V=(e,t,n)=>{if(Ue(t,n),e&&t!==void 0)throw TypeError(`Descriptor property "value" and "${n}" must not both be defined: ${t}`)},Ue=(e,t)=>{if(e!==void 0&&typeof e!=`function`)throw TypeError(`Descriptor property "${t}" must be a function: ${e}`)},H=(e,t)=>{if(e!==void 0&&typeof e!=`boolean`)throw TypeError(`Descriptor property "${t}" must be a boolean: ${e}`)},We=e=>{let[t]=Object.keys(e);if(t!==void 0)throw TypeError(`Unknown descriptor property "${t}": ${e[t]}`)},Ge=(e,t,n)=>(Ke(e,t,Me(Re(e,t,n),U(e,t))),e),U=(e,t)=>{let n=Object.getOwnPropertyDescriptor(e,t);if(n!==void 0)return n;let r=Object.getPrototypeOf(e);return r===null?{}:U(r,t)},Ke=(e,t,n)=>{try{Object.defineProperty(e,t,n)}catch{}},qe=(e,t,n)=>{if(n!==void 0)return W(e,t,n);try{delete e[t]}catch{}if(e[t]!==void 0)return W(e,t)},W=(e,t,n)=>{Ge(e,t,{value:n,...Je(t)})},Je=e=>typeof e==`string`&&e.startsWith(`_`)?{enumerable:!1}:{},Ye=(e,n,r={})=>{if(G(e,`First argument`),G(n,`Second argument`),!t(r))throw TypeError(`Options must be a plain object: ${r}`);let{soft:i=!1}=r;if(typeof i!=`boolean`)throw TypeError(`Option "soft" must be a boolean: ${i}`);return{soft:i}},G=(e,t)=>{if(e===void 0)throw TypeError(`${t} is required.`);if(!Xe(e))throw TypeError(`${t} must be a plain object or an error: ${e}`)},Xe=n=>t(n)||e(n),Ze=({error:e,props:t,propName:n,soft:r})=>Qe(n)||!tt.call(t,n)||r&&e[n]!==void 0,Qe=e=>e in $e||et.has(e),$e=Error(`check`),et=new Set([`prototype`,`errors`,`cause`]),{propertyIsEnumerable:tt}=Object.prototype,nt=(e,t,n)=>{let{soft:r}=Ye(e,t,n);for(let n of Reflect.ownKeys(t))rt({error:e,props:t,propName:n,soft:r});return e},rt=({error:e,props:t,propName:n,soft:r})=>{Ze({error:e,props:t,propName:n,soft:r})||qe(e,n,t[n])},K=(e,t,n)=>{Object.defineProperty(e,t,{value:n,writable:!0,enumerable:!1,configurable:!0})},it=(e,t)=>{e.errors!==void 0&&K(e,`errors`,e.errors.map(e=>t(e).error).filter(Boolean))},at=({target:e,source:t,parent:n,child:r})=>{if(!q(e)){ot(e,t);return}q(t)&&K(e,`errors`,[...r.errors,...n.errors])},ot=(e,t)=>{t.errors!==void 0&&K(e,`errors`,t.errors)},q=e=>e.errors!==void 0&&e.errors.length!==0,st=(e,t,n=e.message)=>{if(typeof t!=`string`)throw TypeError(`newMessage must be a string: ${t}`);if(typeof n!=`string`)throw TypeError(`currentMessage must be a string: ${n}`);return n},ct=({name:e,stack:t},n,r)=>r!==``&&t.includes(r)?lt({name:e,stack:t,newMessage:n,currentMessage:r}):dt(e,t,n),lt=({name:e,stack:t,newMessage:n,currentMessage:r})=>{let[i,a]=ut(e,n,r).find(([e])=>t.includes(e));return t.replace(i,a)},ut=(e,t,n)=>[[`${e}: ${n}`,`${e}: ${t}`],[`: ${n}`,`: ${t}`],[`\n${n}`,`\n${t}`],[` ${n}`,` ${t}`],[n,t]],dt=(e,t,n)=>{let r=`${e}: `,i=n.trimEnd();return t===e||t.startsWith(`${e}\n`)?t.replace(e,`${r}${i}`):t.startsWith(r)?t.replace(r,`${r}${i}\n`):`${r}${i}\n${t}`},ft=(e,t,n)=>{let r=x(e),i=st(r,t,n);return Y(r,`message`,t),pt(r,t,i),r},pt=(e,t,n)=>{t===n||!mt()||Y(e,`stack`,ct(e,t,n))},mt=()=>{let{stack:e}=Error(J);return typeof e==`string`&&e.includes(J)},J=`set-error-message test message`,Y=(e,t,n)=>{Object.defineProperty(e,t,{value:n,enumerable:!1,writable:!0,configurable:!0})},X=(e,t,n)=>{if(typeof t!=`string`)throw TypeError(`Second argument must be a message string: ${t}`);let r=x(e);return ft(r,Z(t,r.message),n)},Z=(e,t)=>{let n=e.trim(),r=t.trim();return n===``?r:r===``?n:ht(n,r,e)},ht=(e,t,n)=>e.endsWith(gt)?n.endsWith(_t)?`${e}\n${t}`:`${e} ${t}`:`${t}\n${e}`,gt=`:`,_t=`
|
|
2
|
+
`,vt=({parent:e,child:t,target:n,stackError:r})=>{let i=e.message,a=r.message;return n.message=t.message,X(n,i,a)},yt=(e,t)=>Q(e)===t,Q=e=>typeof e==`object`&&e?e.stack:void 0,bt=({wrap:e,target:t,source:n,childHasStack:r})=>e===r?t:(K(t,`stack`,n.stack),n),xt=e=>{let{wrap:t,name:n}=e;return typeof t==`boolean`?(Object.hasOwn(e,`wrap`)&&delete e.wrap,t):n===`Error`},St=e=>$(e,[]).error,$=(e,t)=>{if(t.includes(e))return{};let n=n=>$(n,[...t,e]),r=Q(e),i=x(e,{shallow:!0}),a=yt(i,r);it(i,n);let{parent:o,childHasStack:s}=Ct(i,n);return{error:o,errorHasStack:a||s}},Ct=(e,t)=>{let n=xt(e);if(e.cause===void 0)return{parent:e,childHasStack:!1};let{error:r,errorHasStack:i}=t(e.cause);return delete e.cause,{parent:wt({parent:e,child:r,childHasStack:i,wrap:n}),childHasStack:i}},wt=({parent:e,child:t,childHasStack:n,wrap:r})=>{if(t===void 0)return e;let[i,a]=r?[t,e]:[e,t],o=bt({wrap:r,target:i,source:a,childHasStack:n}),s=vt({parent:e,child:t,target:je(i,i.constructor,o.name),stackError:o});return at({target:s,source:a,parent:e,child:t}),nt(s,a,{soft:!r})};export{X as n,St as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{s as e,t}from"../rolldown-runtime.mjs";import{a as n,i as r,o as i,r as a}from"./graphology-dag.mjs";var o=t(((e,t)=>{var n=i();function r(e){this.size=0,this.items=new Map,this.inverse=e}function a(){this.size=0,this.items=new Map,this.inverse=new r(this)}function o(){this.size=0,this.items.clear(),this.inverse.items.clear()}a.prototype.clear=o,r.prototype.clear=o;function s(e,t){if(this.items.has(e)){var n=this.items.get(e);if(n===t)return this;this.inverse.items.delete(n)}if(this.inverse.items.has(t)){var r=this.inverse.items.get(t);if(r===e)return this;this.items.delete(r)}return this.items.set(e,t),this.inverse.items.set(t,e),this.size=this.items.size,this.inverse.size=this.inverse.items.size,this}a.prototype.set=s,r.prototype.set=s;function c(e){if(this.items.has(e)){var t=this.items.get(e);return this.items.delete(e),this.inverse.items.delete(t),this.size=this.items.size,this.inverse.size=this.inverse.items.size,!0}return!1}a.prototype.delete=c,r.prototype.delete=c,[`has`,`get`,`forEach`,`keys`,`values`,`entries`].forEach(function(e){a.prototype[e]=r.prototype[e]=function(){return Map.prototype[e].apply(this.items,arguments)}}),typeof Symbol<`u`&&(a.prototype[Symbol.iterator]=a.prototype.entries,r.prototype[Symbol.iterator]=r.prototype.entries),a.prototype.inspect=function(){var e={left:this.items,right:this.inverse.items};return Object.defineProperty(e,`constructor`,{value:a,enumerable:!1}),e},typeof Symbol<`u`&&(a.prototype[Symbol.for(`nodejs.util.inspect.custom`)]=a.prototype.inspect),r.prototype.inspect=function(){var e={left:this.inverse.items,right:this.items};return Object.defineProperty(e,`constructor`,{value:r,enumerable:!1}),e},typeof Symbol<`u`&&(r.prototype[Symbol.for(`nodejs.util.inspect.custom`)]=r.prototype.inspect),a.from=function(e){var t=new a;return n(e,function(e,n){t.set(n,e)}),t},t.exports=a})),s=t(((e,t)=>{function n(e){if(typeof e!=`function`)throw Error(`mnemonist/DefaultMap.constructor: expecting a function.`);this.items=new Map,this.factory=e,this.size=0}n.prototype.clear=function(){this.items.clear(),this.size=0},n.prototype.get=function(e){var t=this.items.get(e);return t===void 0&&(t=this.factory(e,this.size),this.items.set(e,t),this.size++),t},n.prototype.peek=function(e){return this.items.get(e)},n.prototype.set=function(e,t){return this.items.set(e,t),this.size=this.items.size,this},n.prototype.has=function(e){return this.items.has(e)},n.prototype.delete=function(e){var t=this.items.delete(e);return this.size=this.items.size,t},n.prototype.forEach=function(e,t){t=arguments.length>1?t:this,this.items.forEach(e,t)},n.prototype.entries=function(){return this.items.entries()},n.prototype.keys=function(){return this.items.keys()},n.prototype.values=function(){return this.items.values()},typeof Symbol<`u`&&(n.prototype[Symbol.iterator]=n.prototype.entries),n.prototype.inspect=function(){return this.items},typeof Symbol<`u`&&(n.prototype[Symbol.for(`nodejs.util.inspect.custom`)]=n.prototype.inspect),n.autoIncrement=function(){var e=0;return function(){return e++}},t.exports=n})),c=t(((e,t)=>{function n(e){if(typeof e!=`function`)throw Error(`mnemonist/DefaultWeakMap.constructor: expecting a function.`);this.items=new WeakMap,this.factory=e}n.prototype.clear=function(){this.items=new WeakMap},n.prototype.get=function(e){var t=this.items.get(e);return t===void 0&&(t=this.factory(e),this.items.set(e,t)),t},n.prototype.peek=function(e){return this.items.get(e)},n.prototype.set=function(e,t){return this.items.set(e,t),this},n.prototype.has=function(e){return this.items.has(e)},n.prototype.delete=function(e){return this.items.delete(e)},n.prototype.inspect=function(){return this.items},typeof Symbol<`u`&&(n.prototype[Symbol.for(`nodejs.util.inspect.custom`)]=n.prototype.inspect),t.exports=n})),l=t(((e,t)=>{var r=n(),a=i();function o(){this.clear()}o.prototype.clear=function(){this.head=null,this.tail=null,this.size=0},o.prototype.first=function(){return this.head?this.head.item:void 0},o.prototype.peek=o.prototype.first,o.prototype.last=function(){return this.tail?this.tail.item:void 0},o.prototype.push=function(e){var t={item:e,next:null};return this.head?(this.tail.next=t,this.tail=t):(this.head=t,this.tail=t),this.size++,this.size},o.prototype.unshift=function(e){var t={item:e,next:null};return this.head?(this.head.next||(this.tail=this.head),t.next=this.head,this.head=t):(this.head=t,this.tail=t),this.size++,this.size},o.prototype.shift=function(){if(this.size){var e=this.head;return this.head=e.next,this.size--,e.item}},o.prototype.forEach=function(e,t){if(this.size){t=arguments.length>1?t:this;for(var n=this.head,r=0;n;)e.call(t,n.item,r,this),n=n.next,r++}},o.prototype.toArray=function(){if(!this.size)return[];for(var e=Array(this.size),t=0,n=this.size,r=this.head;t<n;t++)e[t]=r.item,r=r.next;return e},o.prototype.values=function(){var e=this.head;return new r(function(){if(!e)return{done:!0};var t=e.item;return e=e.next,{value:t,done:!1}})},o.prototype.entries=function(){var e=this.head,t=0;return new r(function(){if(!e)return{done:!0};var n=e.item;return e=e.next,t++,{value:[t-1,n],done:!1}})},typeof Symbol<`u`&&(o.prototype[Symbol.iterator]=o.prototype.values),o.prototype.toString=function(){return this.toArray().join(`,`)},o.prototype.toJSON=function(){return this.toArray()},o.prototype.inspect=function(){var e=this.toArray();return Object.defineProperty(e,`constructor`,{value:o,enumerable:!1}),e},typeof Symbol<`u`&&(o.prototype[Symbol.for(`nodejs.util.inspect.custom`)]=o.prototype.inspect),o.from=function(e){var t=new o;return a(e,function(e){t.push(e)}),t},t.exports=o})),u=t(((e,t)=>{var r=n(),a=i();function o(e){this.Container=e||Array,this.items=new Map,this.clear(),Object.defineProperty(this.items,`constructor`,{value:o,enumerable:!1})}o.prototype.clear=function(){this.size=0,this.dimension=0,this.items.clear()},o.prototype.set=function(e,t){var n=this.items.get(e),r;return n||(this.dimension++,n=new this.Container,this.items.set(e,n)),this.Container===Set?(r=n.size,n.add(t),r<n.size&&this.size++):(n.push(t),this.size++),this},o.prototype.delete=function(e){var t=this.items.get(e);return t?(this.size-=this.Container===Set?t.size:t.length,this.dimension--,this.items.delete(e),!0):!1},o.prototype.remove=function(e,t){var n=this.items.get(e),r,i;return n?this.Container===Set?(r=n.delete(t),r&&this.size--,n.size===0&&(this.items.delete(e),this.dimension--),r):(i=n.indexOf(t),i===-1?!1:(this.size--,n.length===1?(this.items.delete(e),this.dimension--,!0):(n.splice(i,1),!0))):!1},o.prototype.has=function(e){return this.items.has(e)},o.prototype.get=function(e){return this.items.get(e)},o.prototype.multiplicity=function(e){var t=this.items.get(e);return t===void 0?0:this.Container===Set?t.size:t.length},o.prototype.count=o.prototype.multiplicity,o.prototype.forEach=function(e,t){t=arguments.length>1?t:this;var n;function r(r){e.call(t,r,n)}this.items.forEach(function(e,t){n=t,e.forEach(r)})},o.prototype.forEachAssociation=function(e,t){t=arguments.length>1?t:this,this.items.forEach(e,t)},o.prototype.keys=function(){return this.items.keys()},o.prototype.values=function(){var e=this.items.values(),t=!1,n,i,a,o;return this.Container===Set?new r(function r(){if(!t){if(i=e.next(),i.done)return{done:!0};t=!0,n=i.value.values()}return i=n.next(),i.done?(t=!1,r()):{done:!1,value:i.value}}):new r(function r(){if(!t){if(i=e.next(),i.done)return{done:!0};t=!0,n=i.value,a=0,o=n.length}return a>=o?(t=!1,r()):{done:!1,value:n[a++]}})},o.prototype.entries=function(){var e=this.items.entries(),t=!1,n,i,a,o,s;return this.Container===Set?new r(function r(){if(!t){if(i=e.next(),i.done)return{done:!0};t=!0,a=i.value[0],n=i.value[1].values()}return i=n.next(),i.done?(t=!1,r()):{done:!1,value:[a,i.value]}}):new r(function r(){if(!t){if(i=e.next(),i.done)return{done:!0};t=!0,a=i.value[0],n=i.value[1],o=0,s=n.length}return o>=s?(t=!1,r()):{done:!1,value:[a,n[o++]]}})},o.prototype.containers=function(){return this.items.values()},o.prototype.associations=function(){return this.items.entries()},typeof Symbol<`u`&&(o.prototype[Symbol.iterator]=o.prototype.entries),o.prototype.inspect=function(){return this.items},typeof Symbol<`u`&&(o.prototype[Symbol.for(`nodejs.util.inspect.custom`)]=o.prototype.inspect),o.prototype.toJSON=function(){return this.items},o.from=function(e,t){var n=new o(t);return a(e,function(e,t){n.set(t,e)}),n},t.exports=o})),d=t(((e,t)=>{var o=n(),s=i(),c=r(),l=a();function u(e,t,n){if(arguments.length<2&&(n=e,e=null,t=null),this.capacity=n,typeof this.capacity!=`number`||this.capacity<=0)throw Error(`mnemonist/lru-cache: capacity should be positive number.`);if(!isFinite(this.capacity)||Math.floor(this.capacity)!==this.capacity)throw Error(`mnemonist/lru-cache: capacity should be a finite positive integer.`);var r=c.getPointerArray(n);this.forward=new r(n),this.backward=new r(n),this.K=typeof e==`function`?new e(n):Array(n),this.V=typeof t==`function`?new t(n):Array(n),this.size=0,this.head=0,this.tail=0,this.items={}}u.prototype.clear=function(){this.size=0,this.head=0,this.tail=0,this.items={}},u.prototype.splayOnTop=function(e){var t=this.head;if(this.head===e)return this;var n=this.backward[e],r=this.forward[e];return this.tail===e?this.tail=n:this.backward[r]=n,this.forward[n]=r,this.backward[t]=e,this.head=e,this.forward[e]=t,this},u.prototype.set=function(e,t){var n=this.items[e];if(n!==void 0){this.splayOnTop(n),this.V[n]=t;return}this.size<this.capacity?n=this.size++:(n=this.tail,this.tail=this.backward[n],delete this.items[this.K[n]]),this.items[e]=n,this.K[n]=e,this.V[n]=t,this.forward[n]=this.head,this.backward[this.head]=n,this.head=n},u.prototype.setpop=function(e,t){var n=null,r=null,i=this.items[e];return i===void 0?(this.size<this.capacity?i=this.size++:(i=this.tail,this.tail=this.backward[i],n=this.V[i],r=this.K[i],delete this.items[r]),this.items[e]=i,this.K[i]=e,this.V[i]=t,this.forward[i]=this.head,this.backward[this.head]=i,this.head=i,r?{evicted:!0,key:r,value:n}:null):(this.splayOnTop(i),n=this.V[i],this.V[i]=t,{evicted:!1,key:e,value:n})},u.prototype.has=function(e){return e in this.items},u.prototype.get=function(e){var t=this.items[e];if(t!==void 0)return this.splayOnTop(t),this.V[t]},u.prototype.peek=function(e){var t=this.items[e];if(t!==void 0)return this.V[t]},u.prototype.forEach=function(e,t){t=arguments.length>1?t:this;for(var n=0,r=this.size,i=this.head,a=this.K,o=this.V,s=this.forward;n<r;)e.call(t,o[i],a[i],this),i=s[i],n++},u.prototype.keys=function(){var e=0,t=this.size,n=this.head,r=this.K,i=this.forward;return new o(function(){if(e>=t)return{done:!0};var a=r[n];return e++,e<t&&(n=i[n]),{done:!1,value:a}})},u.prototype.values=function(){var e=0,t=this.size,n=this.head,r=this.V,i=this.forward;return new o(function(){if(e>=t)return{done:!0};var a=r[n];return e++,e<t&&(n=i[n]),{done:!1,value:a}})},u.prototype.entries=function(){var e=0,t=this.size,n=this.head,r=this.K,i=this.V,a=this.forward;return new o(function(){if(e>=t)return{done:!0};var o=r[n],s=i[n];return e++,e<t&&(n=a[n]),{done:!1,value:[o,s]}})},typeof Symbol<`u`&&(u.prototype[Symbol.iterator]=u.prototype.entries),u.prototype.inspect=function(){for(var e=new Map,t=this.entries(),n;n=t.next(),!n.done;)e.set(n.value[0],n.value[1]);return Object.defineProperty(e,`constructor`,{value:u,enumerable:!1}),e},typeof Symbol<`u`&&(u.prototype[Symbol.for(`nodejs.util.inspect.custom`)]=u.prototype.inspect),u.from=function(e,t,n,r){if(arguments.length<2){if(r=l.guessLength(e),typeof r!=`number`)throw Error(`mnemonist/lru-cache.from: could not guess iterable length. Please provide desired capacity as last argument.`)}else arguments.length===2&&(r=t,t=null,n=null);var i=new u(t,n,r);return s(e,function(e,t){i.set(t,e)}),i},t.exports=u})),f=t(((e,t)=>{var n=d(),o=i(),s=r(),c=a();function l(e,t,n){if(arguments.length<2&&(n=e,e=null,t=null),this.capacity=n,typeof this.capacity!=`number`||this.capacity<=0)throw Error(`mnemonist/lru-map: capacity should be positive number.`);if(!isFinite(this.capacity)||Math.floor(this.capacity)!==this.capacity)throw Error(`mnemonist/lru-map: capacity should be a finite positive integer.`);var r=s.getPointerArray(n);this.forward=new r(n),this.backward=new r(n),this.K=typeof e==`function`?new e(n):Array(n),this.V=typeof t==`function`?new t(n):Array(n),this.size=0,this.head=0,this.tail=0,this.items=new Map}l.prototype.clear=function(){this.size=0,this.head=0,this.tail=0,this.items.clear()},l.prototype.set=function(e,t){var n=this.items.get(e);if(n!==void 0){this.splayOnTop(n),this.V[n]=t;return}this.size<this.capacity?n=this.size++:(n=this.tail,this.tail=this.backward[n],this.items.delete(this.K[n])),this.items.set(e,n),this.K[n]=e,this.V[n]=t,this.forward[n]=this.head,this.backward[this.head]=n,this.head=n},l.prototype.setpop=function(e,t){var n=null,r=null,i=this.items.get(e);return i===void 0?(this.size<this.capacity?i=this.size++:(i=this.tail,this.tail=this.backward[i],n=this.V[i],r=this.K[i],this.items.delete(r)),this.items.set(e,i),this.K[i]=e,this.V[i]=t,this.forward[i]=this.head,this.backward[this.head]=i,this.head=i,r?{evicted:!0,key:r,value:n}:null):(this.splayOnTop(i),n=this.V[i],this.V[i]=t,{evicted:!1,key:e,value:n})},l.prototype.has=function(e){return this.items.has(e)},l.prototype.get=function(e){var t=this.items.get(e);if(t!==void 0)return this.splayOnTop(t),this.V[t]},l.prototype.peek=function(e){var t=this.items.get(e);if(t!==void 0)return this.V[t]},l.prototype.splayOnTop=n.prototype.splayOnTop,l.prototype.forEach=n.prototype.forEach,l.prototype.keys=n.prototype.keys,l.prototype.values=n.prototype.values,l.prototype.entries=n.prototype.entries,typeof Symbol<`u`&&(l.prototype[Symbol.iterator]=l.prototype.entries),l.prototype.inspect=n.prototype.inspect,l.from=function(e,t,n,r){if(arguments.length<2){if(r=c.guessLength(e),typeof r!=`number`)throw Error(`mnemonist/lru-cache.from: could not guess iterable length. Please provide desired capacity as last argument.`)}else arguments.length===2&&(r=t,t=null,n=null);var i=new l(t,n,r);return o(e,function(e,t){i.set(t,e)}),i},t.exports=l})),p=t((e=>{e.intersection=function(){if(arguments.length<2)throw Error(`mnemonist/Set.intersection: needs at least two arguments.`);var e=new Set,t=1/0,n=null,r,i,a=arguments.length;for(i=0;i<a;i++){if(r=arguments[i],r.size===0)return e;r.size<t&&(t=r.size,n=r)}for(var o=n.values(),s,c,l,u;s=o.next(),!s.done;){for(c=s.value,l=!0,i=0;i<a;i++)if(u=arguments[i],u!==n&&!u.has(c)){l=!1;break}l&&e.add(c)}return e},e.union=function(){if(arguments.length<2)throw Error(`mnemonist/Set.union: needs at least two arguments.`);var e=new Set,t,n=arguments.length,r,i;for(t=0;t<n;t++)for(r=arguments[t].values();i=r.next(),!i.done;)e.add(i.value);return e},e.difference=function(e,t){if(!e.size)return new Set;if(!t.size)return new Set(e);for(var n=new Set,r=e.values(),i;i=r.next(),!i.done;)t.has(i.value)||n.add(i.value);return n},e.symmetricDifference=function(e,t){for(var n=new Set,r=e.values(),i;i=r.next(),!i.done;)t.has(i.value)||n.add(i.value);for(r=t.values();i=r.next(),!i.done;)e.has(i.value)||n.add(i.value);return n},e.isSubset=function(e,t){var n=e.values(),r;if(e===t)return!0;if(e.size>t.size)return!1;for(;r=n.next(),!r.done;)if(!t.has(r.value))return!1;return!0},e.isSuperset=function(t,n){return e.isSubset(n,t)},e.add=function(e,t){for(var n=t.values(),r;r=n.next(),!r.done;)e.add(r.value)},e.subtract=function(e,t){for(var n=t.values(),r;r=n.next(),!r.done;)e.delete(r.value)},e.intersect=function(e,t){for(var n=e.values(),r;r=n.next(),!r.done;)t.has(r.value)||e.delete(r.value)},e.disjunct=function(e,t){for(var n=e.values(),r,i=[];r=n.next(),!r.done;)t.has(r.value)&&i.push(r.value);for(n=t.values();r=n.next(),!r.done;)e.has(r.value)||e.add(r.value);for(var a=0,o=i.length;a<o;a++)e.delete(i[a])},e.intersectionSize=function(e,t){var n;if(e.size>t.size&&(n=e,e=t,t=n),e.size===0)return 0;if(e===t)return e.size;for(var r=e.values(),i,a=0;i=r.next(),!i.done;)t.has(i.value)&&a++;return a},e.unionSize=function(t,n){var r=e.intersectionSize(t,n);return t.size+n.size-r},e.jaccard=function(t,n){var r=e.intersectionSize(t,n);return r===0?0:r/(t.size+n.size-r)},e.overlap=function(t,n){var r=e.intersectionSize(t,n);return r===0?0:r/Math.min(t.size,n.size)}})),m=t(((e,t)=>{var r=n(),a=i();function o(){this.clear()}o.prototype.clear=function(){this.items=[],this.size=0},o.prototype.push=function(e){return this.items.push(e),++this.size},o.prototype.pop=function(){if(this.size!==0)return this.size--,this.items.pop()},o.prototype.peek=function(){return this.items[this.size-1]},o.prototype.forEach=function(e,t){t=arguments.length>1?t:this;for(var n=0,r=this.items.length;n<r;n++)e.call(t,this.items[r-n-1],n,this)},o.prototype.toArray=function(){for(var e=Array(this.size),t=this.size-1,n=this.size;n--;)e[n]=this.items[t-n];return e},o.prototype.values=function(){var e=this.items,t=e.length,n=0;return new r(function(){if(n>=t)return{done:!0};var r=e[t-n-1];return n++,{value:r,done:!1}})},o.prototype.entries=function(){var e=this.items,t=e.length,n=0;return new r(function(){if(n>=t)return{done:!0};var r=e[t-n-1];return{value:[n++,r],done:!1}})},typeof Symbol<`u`&&(o.prototype[Symbol.iterator]=o.prototype.values),o.prototype.toString=function(){return this.toArray().join(`,`)},o.prototype.toJSON=function(){return this.toArray()},o.prototype.inspect=function(){var e=this.toArray();return Object.defineProperty(e,`constructor`,{value:o,enumerable:!1}),e},typeof Symbol<`u`&&(o.prototype[Symbol.for(`nodejs.util.inspect.custom`)]=o.prototype.inspect),o.from=function(e){var t=new o;return a(e,function(e){t.push(e)}),t},o.of=function(){return o.from(arguments)},t.exports=o})),h=e(o(),1),g=e(s(),1),_=e(c(),1),v=e(l(),1),y=e(u(),1),b=e(f(),1),x=p(),S=e(m(),1);export{b as a,S as c,v as i,g as n,y as o,_ as r,x as s,h as t};
|
|
1
|
+
import{s as e,t}from"../rolldown-runtime.mjs";import{a as n,i as r,o as i,r as a}from"./graphology-dag.mjs";var o=t(((e,t)=>{function n(e){if(typeof e!=`function`)throw Error(`mnemonist/DefaultMap.constructor: expecting a function.`);this.items=new Map,this.factory=e,this.size=0}n.prototype.clear=function(){this.items.clear(),this.size=0},n.prototype.get=function(e){var t=this.items.get(e);return t===void 0&&(t=this.factory(e,this.size),this.items.set(e,t),this.size++),t},n.prototype.peek=function(e){return this.items.get(e)},n.prototype.set=function(e,t){return this.items.set(e,t),this.size=this.items.size,this},n.prototype.has=function(e){return this.items.has(e)},n.prototype.delete=function(e){var t=this.items.delete(e);return this.size=this.items.size,t},n.prototype.forEach=function(e,t){t=arguments.length>1?t:this,this.items.forEach(e,t)},n.prototype.entries=function(){return this.items.entries()},n.prototype.keys=function(){return this.items.keys()},n.prototype.values=function(){return this.items.values()},typeof Symbol<`u`&&(n.prototype[Symbol.iterator]=n.prototype.entries),n.prototype.inspect=function(){return this.items},typeof Symbol<`u`&&(n.prototype[Symbol.for(`nodejs.util.inspect.custom`)]=n.prototype.inspect),n.autoIncrement=function(){var e=0;return function(){return e++}},t.exports=n})),s=t(((e,t)=>{function n(e){if(typeof e!=`function`)throw Error(`mnemonist/DefaultWeakMap.constructor: expecting a function.`);this.items=new WeakMap,this.factory=e}n.prototype.clear=function(){this.items=new WeakMap},n.prototype.get=function(e){var t=this.items.get(e);return t===void 0&&(t=this.factory(e),this.items.set(e,t)),t},n.prototype.peek=function(e){return this.items.get(e)},n.prototype.set=function(e,t){return this.items.set(e,t),this},n.prototype.has=function(e){return this.items.has(e)},n.prototype.delete=function(e){return this.items.delete(e)},n.prototype.inspect=function(){return this.items},typeof Symbol<`u`&&(n.prototype[Symbol.for(`nodejs.util.inspect.custom`)]=n.prototype.inspect),t.exports=n})),c=t(((e,t)=>{var r=n(),a=i();function o(){this.clear()}o.prototype.clear=function(){this.head=null,this.tail=null,this.size=0},o.prototype.first=function(){return this.head?this.head.item:void 0},o.prototype.peek=o.prototype.first,o.prototype.last=function(){return this.tail?this.tail.item:void 0},o.prototype.push=function(e){var t={item:e,next:null};return this.head?(this.tail.next=t,this.tail=t):(this.head=t,this.tail=t),this.size++,this.size},o.prototype.unshift=function(e){var t={item:e,next:null};return this.head?(this.head.next||(this.tail=this.head),t.next=this.head,this.head=t):(this.head=t,this.tail=t),this.size++,this.size},o.prototype.shift=function(){if(this.size){var e=this.head;return this.head=e.next,this.size--,e.item}},o.prototype.forEach=function(e,t){if(this.size){t=arguments.length>1?t:this;for(var n=this.head,r=0;n;)e.call(t,n.item,r,this),n=n.next,r++}},o.prototype.toArray=function(){if(!this.size)return[];for(var e=Array(this.size),t=0,n=this.size,r=this.head;t<n;t++)e[t]=r.item,r=r.next;return e},o.prototype.values=function(){var e=this.head;return new r(function(){if(!e)return{done:!0};var t=e.item;return e=e.next,{value:t,done:!1}})},o.prototype.entries=function(){var e=this.head,t=0;return new r(function(){if(!e)return{done:!0};var n=e.item;return e=e.next,t++,{value:[t-1,n],done:!1}})},typeof Symbol<`u`&&(o.prototype[Symbol.iterator]=o.prototype.values),o.prototype.toString=function(){return this.toArray().join(`,`)},o.prototype.toJSON=function(){return this.toArray()},o.prototype.inspect=function(){var e=this.toArray();return Object.defineProperty(e,`constructor`,{value:o,enumerable:!1}),e},typeof Symbol<`u`&&(o.prototype[Symbol.for(`nodejs.util.inspect.custom`)]=o.prototype.inspect),o.from=function(e){var t=new o;return a(e,function(e){t.push(e)}),t},t.exports=o})),l=t(((e,t)=>{var r=n(),a=i();function o(e){this.Container=e||Array,this.items=new Map,this.clear(),Object.defineProperty(this.items,`constructor`,{value:o,enumerable:!1})}o.prototype.clear=function(){this.size=0,this.dimension=0,this.items.clear()},o.prototype.set=function(e,t){var n=this.items.get(e),r;return n||(this.dimension++,n=new this.Container,this.items.set(e,n)),this.Container===Set?(r=n.size,n.add(t),r<n.size&&this.size++):(n.push(t),this.size++),this},o.prototype.delete=function(e){var t=this.items.get(e);return t?(this.size-=this.Container===Set?t.size:t.length,this.dimension--,this.items.delete(e),!0):!1},o.prototype.remove=function(e,t){var n=this.items.get(e),r,i;return n?this.Container===Set?(r=n.delete(t),r&&this.size--,n.size===0&&(this.items.delete(e),this.dimension--),r):(i=n.indexOf(t),i===-1?!1:(this.size--,n.length===1?(this.items.delete(e),this.dimension--,!0):(n.splice(i,1),!0))):!1},o.prototype.has=function(e){return this.items.has(e)},o.prototype.get=function(e){return this.items.get(e)},o.prototype.multiplicity=function(e){var t=this.items.get(e);return t===void 0?0:this.Container===Set?t.size:t.length},o.prototype.count=o.prototype.multiplicity,o.prototype.forEach=function(e,t){t=arguments.length>1?t:this;var n;function r(r){e.call(t,r,n)}this.items.forEach(function(e,t){n=t,e.forEach(r)})},o.prototype.forEachAssociation=function(e,t){t=arguments.length>1?t:this,this.items.forEach(e,t)},o.prototype.keys=function(){return this.items.keys()},o.prototype.values=function(){var e=this.items.values(),t=!1,n,i,a,o;return this.Container===Set?new r(function r(){if(!t){if(i=e.next(),i.done)return{done:!0};t=!0,n=i.value.values()}return i=n.next(),i.done?(t=!1,r()):{done:!1,value:i.value}}):new r(function r(){if(!t){if(i=e.next(),i.done)return{done:!0};t=!0,n=i.value,a=0,o=n.length}return a>=o?(t=!1,r()):{done:!1,value:n[a++]}})},o.prototype.entries=function(){var e=this.items.entries(),t=!1,n,i,a,o,s;return this.Container===Set?new r(function r(){if(!t){if(i=e.next(),i.done)return{done:!0};t=!0,a=i.value[0],n=i.value[1].values()}return i=n.next(),i.done?(t=!1,r()):{done:!1,value:[a,i.value]}}):new r(function r(){if(!t){if(i=e.next(),i.done)return{done:!0};t=!0,a=i.value[0],n=i.value[1],o=0,s=n.length}return o>=s?(t=!1,r()):{done:!1,value:[a,n[o++]]}})},o.prototype.containers=function(){return this.items.values()},o.prototype.associations=function(){return this.items.entries()},typeof Symbol<`u`&&(o.prototype[Symbol.iterator]=o.prototype.entries),o.prototype.inspect=function(){return this.items},typeof Symbol<`u`&&(o.prototype[Symbol.for(`nodejs.util.inspect.custom`)]=o.prototype.inspect),o.prototype.toJSON=function(){return this.items},o.from=function(e,t){var n=new o(t);return a(e,function(e,t){n.set(t,e)}),n},t.exports=o})),u=t(((e,t)=>{var o=n(),s=i(),c=r(),l=a();function u(e,t,n){if(arguments.length<2&&(n=e,e=null,t=null),this.capacity=n,typeof this.capacity!=`number`||this.capacity<=0)throw Error(`mnemonist/lru-cache: capacity should be positive number.`);if(!isFinite(this.capacity)||Math.floor(this.capacity)!==this.capacity)throw Error(`mnemonist/lru-cache: capacity should be a finite positive integer.`);var r=c.getPointerArray(n);this.forward=new r(n),this.backward=new r(n),this.K=typeof e==`function`?new e(n):Array(n),this.V=typeof t==`function`?new t(n):Array(n),this.size=0,this.head=0,this.tail=0,this.items={}}u.prototype.clear=function(){this.size=0,this.head=0,this.tail=0,this.items={}},u.prototype.splayOnTop=function(e){var t=this.head;if(this.head===e)return this;var n=this.backward[e],r=this.forward[e];return this.tail===e?this.tail=n:this.backward[r]=n,this.forward[n]=r,this.backward[t]=e,this.head=e,this.forward[e]=t,this},u.prototype.set=function(e,t){var n=this.items[e];if(n!==void 0){this.splayOnTop(n),this.V[n]=t;return}this.size<this.capacity?n=this.size++:(n=this.tail,this.tail=this.backward[n],delete this.items[this.K[n]]),this.items[e]=n,this.K[n]=e,this.V[n]=t,this.forward[n]=this.head,this.backward[this.head]=n,this.head=n},u.prototype.setpop=function(e,t){var n=null,r=null,i=this.items[e];return i===void 0?(this.size<this.capacity?i=this.size++:(i=this.tail,this.tail=this.backward[i],n=this.V[i],r=this.K[i],delete this.items[r]),this.items[e]=i,this.K[i]=e,this.V[i]=t,this.forward[i]=this.head,this.backward[this.head]=i,this.head=i,r?{evicted:!0,key:r,value:n}:null):(this.splayOnTop(i),n=this.V[i],this.V[i]=t,{evicted:!1,key:e,value:n})},u.prototype.has=function(e){return e in this.items},u.prototype.get=function(e){var t=this.items[e];if(t!==void 0)return this.splayOnTop(t),this.V[t]},u.prototype.peek=function(e){var t=this.items[e];if(t!==void 0)return this.V[t]},u.prototype.forEach=function(e,t){t=arguments.length>1?t:this;for(var n=0,r=this.size,i=this.head,a=this.K,o=this.V,s=this.forward;n<r;)e.call(t,o[i],a[i],this),i=s[i],n++},u.prototype.keys=function(){var e=0,t=this.size,n=this.head,r=this.K,i=this.forward;return new o(function(){if(e>=t)return{done:!0};var a=r[n];return e++,e<t&&(n=i[n]),{done:!1,value:a}})},u.prototype.values=function(){var e=0,t=this.size,n=this.head,r=this.V,i=this.forward;return new o(function(){if(e>=t)return{done:!0};var a=r[n];return e++,e<t&&(n=i[n]),{done:!1,value:a}})},u.prototype.entries=function(){var e=0,t=this.size,n=this.head,r=this.K,i=this.V,a=this.forward;return new o(function(){if(e>=t)return{done:!0};var o=r[n],s=i[n];return e++,e<t&&(n=a[n]),{done:!1,value:[o,s]}})},typeof Symbol<`u`&&(u.prototype[Symbol.iterator]=u.prototype.entries),u.prototype.inspect=function(){for(var e=new Map,t=this.entries(),n;n=t.next(),!n.done;)e.set(n.value[0],n.value[1]);return Object.defineProperty(e,`constructor`,{value:u,enumerable:!1}),e},typeof Symbol<`u`&&(u.prototype[Symbol.for(`nodejs.util.inspect.custom`)]=u.prototype.inspect),u.from=function(e,t,n,r){if(arguments.length<2){if(r=l.guessLength(e),typeof r!=`number`)throw Error(`mnemonist/lru-cache.from: could not guess iterable length. Please provide desired capacity as last argument.`)}else arguments.length===2&&(r=t,t=null,n=null);var i=new u(t,n,r);return s(e,function(e,t){i.set(t,e)}),i},t.exports=u})),d=t(((e,t)=>{var n=u(),o=i(),s=r(),c=a();function l(e,t,n){if(arguments.length<2&&(n=e,e=null,t=null),this.capacity=n,typeof this.capacity!=`number`||this.capacity<=0)throw Error(`mnemonist/lru-map: capacity should be positive number.`);if(!isFinite(this.capacity)||Math.floor(this.capacity)!==this.capacity)throw Error(`mnemonist/lru-map: capacity should be a finite positive integer.`);var r=s.getPointerArray(n);this.forward=new r(n),this.backward=new r(n),this.K=typeof e==`function`?new e(n):Array(n),this.V=typeof t==`function`?new t(n):Array(n),this.size=0,this.head=0,this.tail=0,this.items=new Map}l.prototype.clear=function(){this.size=0,this.head=0,this.tail=0,this.items.clear()},l.prototype.set=function(e,t){var n=this.items.get(e);if(n!==void 0){this.splayOnTop(n),this.V[n]=t;return}this.size<this.capacity?n=this.size++:(n=this.tail,this.tail=this.backward[n],this.items.delete(this.K[n])),this.items.set(e,n),this.K[n]=e,this.V[n]=t,this.forward[n]=this.head,this.backward[this.head]=n,this.head=n},l.prototype.setpop=function(e,t){var n=null,r=null,i=this.items.get(e);return i===void 0?(this.size<this.capacity?i=this.size++:(i=this.tail,this.tail=this.backward[i],n=this.V[i],r=this.K[i],this.items.delete(r)),this.items.set(e,i),this.K[i]=e,this.V[i]=t,this.forward[i]=this.head,this.backward[this.head]=i,this.head=i,r?{evicted:!0,key:r,value:n}:null):(this.splayOnTop(i),n=this.V[i],this.V[i]=t,{evicted:!1,key:e,value:n})},l.prototype.has=function(e){return this.items.has(e)},l.prototype.get=function(e){var t=this.items.get(e);if(t!==void 0)return this.splayOnTop(t),this.V[t]},l.prototype.peek=function(e){var t=this.items.get(e);if(t!==void 0)return this.V[t]},l.prototype.splayOnTop=n.prototype.splayOnTop,l.prototype.forEach=n.prototype.forEach,l.prototype.keys=n.prototype.keys,l.prototype.values=n.prototype.values,l.prototype.entries=n.prototype.entries,typeof Symbol<`u`&&(l.prototype[Symbol.iterator]=l.prototype.entries),l.prototype.inspect=n.prototype.inspect,l.from=function(e,t,n,r){if(arguments.length<2){if(r=c.guessLength(e),typeof r!=`number`)throw Error(`mnemonist/lru-cache.from: could not guess iterable length. Please provide desired capacity as last argument.`)}else arguments.length===2&&(r=t,t=null,n=null);var i=new l(t,n,r);return o(e,function(e,t){i.set(t,e)}),i},t.exports=l})),f=t((e=>{e.intersection=function(){if(arguments.length<2)throw Error(`mnemonist/Set.intersection: needs at least two arguments.`);var e=new Set,t=1/0,n=null,r,i,a=arguments.length;for(i=0;i<a;i++){if(r=arguments[i],r.size===0)return e;r.size<t&&(t=r.size,n=r)}for(var o=n.values(),s,c,l,u;s=o.next(),!s.done;){for(c=s.value,l=!0,i=0;i<a;i++)if(u=arguments[i],u!==n&&!u.has(c)){l=!1;break}l&&e.add(c)}return e},e.union=function(){if(arguments.length<2)throw Error(`mnemonist/Set.union: needs at least two arguments.`);var e=new Set,t,n=arguments.length,r,i;for(t=0;t<n;t++)for(r=arguments[t].values();i=r.next(),!i.done;)e.add(i.value);return e},e.difference=function(e,t){if(!e.size)return new Set;if(!t.size)return new Set(e);for(var n=new Set,r=e.values(),i;i=r.next(),!i.done;)t.has(i.value)||n.add(i.value);return n},e.symmetricDifference=function(e,t){for(var n=new Set,r=e.values(),i;i=r.next(),!i.done;)t.has(i.value)||n.add(i.value);for(r=t.values();i=r.next(),!i.done;)e.has(i.value)||n.add(i.value);return n},e.isSubset=function(e,t){var n=e.values(),r;if(e===t)return!0;if(e.size>t.size)return!1;for(;r=n.next(),!r.done;)if(!t.has(r.value))return!1;return!0},e.isSuperset=function(t,n){return e.isSubset(n,t)},e.add=function(e,t){for(var n=t.values(),r;r=n.next(),!r.done;)e.add(r.value)},e.subtract=function(e,t){for(var n=t.values(),r;r=n.next(),!r.done;)e.delete(r.value)},e.intersect=function(e,t){for(var n=e.values(),r;r=n.next(),!r.done;)t.has(r.value)||e.delete(r.value)},e.disjunct=function(e,t){for(var n=e.values(),r,i=[];r=n.next(),!r.done;)t.has(r.value)&&i.push(r.value);for(n=t.values();r=n.next(),!r.done;)e.has(r.value)||e.add(r.value);for(var a=0,o=i.length;a<o;a++)e.delete(i[a])},e.intersectionSize=function(e,t){var n;if(e.size>t.size&&(n=e,e=t,t=n),e.size===0)return 0;if(e===t)return e.size;for(var r=e.values(),i,a=0;i=r.next(),!i.done;)t.has(i.value)&&a++;return a},e.unionSize=function(t,n){var r=e.intersectionSize(t,n);return t.size+n.size-r},e.jaccard=function(t,n){var r=e.intersectionSize(t,n);return r===0?0:r/(t.size+n.size-r)},e.overlap=function(t,n){var r=e.intersectionSize(t,n);return r===0?0:r/Math.min(t.size,n.size)}})),p=t(((e,t)=>{var r=n(),a=i();function o(){this.clear()}o.prototype.clear=function(){this.items=[],this.size=0},o.prototype.push=function(e){return this.items.push(e),++this.size},o.prototype.pop=function(){if(this.size!==0)return this.size--,this.items.pop()},o.prototype.peek=function(){return this.items[this.size-1]},o.prototype.forEach=function(e,t){t=arguments.length>1?t:this;for(var n=0,r=this.items.length;n<r;n++)e.call(t,this.items[r-n-1],n,this)},o.prototype.toArray=function(){for(var e=Array(this.size),t=this.size-1,n=this.size;n--;)e[n]=this.items[t-n];return e},o.prototype.values=function(){var e=this.items,t=e.length,n=0;return new r(function(){if(n>=t)return{done:!0};var r=e[t-n-1];return n++,{value:r,done:!1}})},o.prototype.entries=function(){var e=this.items,t=e.length,n=0;return new r(function(){if(n>=t)return{done:!0};var r=e[t-n-1];return{value:[n++,r],done:!1}})},typeof Symbol<`u`&&(o.prototype[Symbol.iterator]=o.prototype.values),o.prototype.toString=function(){return this.toArray().join(`,`)},o.prototype.toJSON=function(){return this.toArray()},o.prototype.inspect=function(){var e=this.toArray();return Object.defineProperty(e,`constructor`,{value:o,enumerable:!1}),e},typeof Symbol<`u`&&(o.prototype[Symbol.for(`nodejs.util.inspect.custom`)]=o.prototype.inspect),o.from=function(e){var t=new o;return a(e,function(e){t.push(e)}),t},o.of=function(){return o.from(arguments)},t.exports=o})),m=e(o(),1),h=e(s(),1),g=e(c(),1),_=e(l(),1),v=e(d(),1),y=f(),b=e(p(),1);export{_ as a,v as i,h as n,y as o,g as r,b as s,m as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var e=class{value;next;constructor(e){this.value=e}},t=class{#e;#t;#n;constructor(){this.clear()}enqueue(t){let n=new e(t);this.#e?(this.#t.next=n,this.#t=n):(this.#e=n,this.#t=n),this.#n++}dequeue(){let e=this.#e;if(e)return this.#e=this.#e.next,this.#n--,this.#e||(this.#t=void 0),e.value}peek(){if(this.#e)return this.#e.value}clear(){this.#e=void 0,this.#t=void 0,this.#n=0}get size(){return this.#n}*[Symbol.iterator](){let e=this.#e;for(;e;)yield e.value,e=e.next}*drain(){for(;this.#e;)yield this.dequeue()}};function n(e){r(e);let
|
|
1
|
+
var e=class{value;next;constructor(e){this.value=e}},t=class{#e;#t;#n;constructor(){this.clear()}enqueue(t){let n=new e(t);this.#e?(this.#t.next=n,this.#t=n):(this.#e=n,this.#t=n),this.#n++}dequeue(){let e=this.#e;if(e)return this.#e=this.#e.next,this.#n--,this.#e||(this.#t=void 0),e.value}peek(){if(this.#e)return this.#e.value}clear(){this.#e=void 0,this.#t=void 0,this.#n=0}get size(){return this.#n}*[Symbol.iterator](){let e=this.#e;for(;e;)yield e.value,e=e.next}*drain(){for(;this.#e;)yield this.dequeue()}};function n(e){let n=!1;if(typeof e==`object`&&({concurrency:e,rejectOnClear:n=!1}=e),r(e),typeof n!=`boolean`)throw TypeError("Expected `rejectOnClear` to be a boolean");let i=new t,a=0,o=()=>{a<e&&i.size>0&&(a++,i.dequeue().run())},s=()=>{a--,o()},c=async(e,t,n)=>{let r=(async()=>e(...n))();t(r);try{await r}catch{}s()},l=(t,n,r,s)=>{let l={reject:r};new Promise(e=>{l.run=e,i.enqueue(l)}).then(c.bind(void 0,t,n,s)),a<e&&o()},u=(e,...t)=>new Promise((n,r)=>{l(e,n,r,t)});return Object.defineProperties(u,{activeCount:{get:()=>a},pendingCount:{get:()=>i.size},clearQueue:{value(){if(!n){i.clear();return}let e=AbortSignal.abort().reason;for(;i.size>0;)i.dequeue().reject(e)}},concurrency:{get:()=>e,set(t){r(t),e=t,queueMicrotask(()=>{for(;a<e&&i.size>0;)o()})}},map:{async value(e,t){let n=Array.from(e,(e,n)=>this(t,e,n));return Promise.all(n)}}}),u}function r(e){if(!((Number.isInteger(e)||e===1/0)&&e>0))throw TypeError("Expected `concurrency` to be a number from 1 and up")}export{n as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e=/^[A-Za-z]:\//;function t(t=``){return t&&t.replace(/\\/g,`/`).replace(e,e=>e.toUpperCase())}const n=function(e,n){let r=t(e).split(`/`),i=``;for(let e=r.length-1;e>=0;e--){let t=r[e];if(t){i=t;break}}return n&&i.endsWith(n)?i.slice(0,-n.length):i};export{n as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function e(e,t,n){let r=n=>e(n,...t);return n===void 0?r:Object.assign(r,{lazy:n,lazyArgs:t})}function t(t,n,r){let i=t.length-n.length;if(i===0)return t(...n);if(i===1)return e(t,n,r);throw Error(`Wrong number of arguments`)}function n(...e){return t(r,e)}const r=(e,t)=>t.every(t=>t(e));function i(...e){return t(a,e)}const a=(e,t)=>t.some(t=>t(e));function o(...e){return t(s,e)}function s(e,t){if(t<1)throw RangeError(`chunk: A chunk size of '${t.toString()}' would result in an infinite array`);if(e.length===0)return[];if(t>=e.length)return[[...e]];let n=Math.ceil(e.length/t),r=Array(n);if(t===1)for(let[t,n]of e.entries())r[t]=[n];else for(let i=0;i<n;i+=1){let n=i*t;r[i]=e.slice(n,n+t)}return r}function c(...e){return t(l,e)}const l=(e,{min:t,max:n})=>t!==void 0&&e<t?t:n!==void 0&&e>n?n:e;function u(...e){return t(d,e)}const d=(e,t)=>[...e,...t];function f(e){return()=>e}const ee={done:!0,hasNext:!1},p={done:!1,hasNext:!1},m=()=>ee,h=e=>({hasNext:!0,next:e,done:!1});function g(e,...t){let n=e,r=t.map(e=>`lazy`in e?te(e):void 0),i=0;for(;i<t.length;){if(r[i]===void 0||!ne(n)){let e=t[i];n=e(n),i+=1;continue}let e=[];for(let n=i;n<t.length;n++){let t=r[n];if(t===void 0||(e.push(t),t.isSingle))break}let a=[];for(let t of n)if(_(t,a,e))break;let{isSingle:o}=e.at(-1);n=o?a[0]:a,i+=e.length}return n}function _(e,t,n){if(n.length===0)return t.push(e),!1;let r=e,i=p,a=!1;for(let[e,o]of n.entries()){let{index:s,items:c}=o;if(c.push(r),i=o(r,s,c),o.index+=1,i.hasNext){if(i.hasMany??!1){for(let r of i.next)if(_(r,t,n.slice(e+1)))return!0;return a}r=i.next}if(!i.hasNext)break;i.done&&(a=!0)}return i.hasNext&&t.push(r),a}function te(e){let{lazy:t,lazyArgs:n}=e,r=t(...n);return Object.assign(r,{isSingle:t.single??!1,index:0,items:[]})}function ne(e){return typeof e==`string`||typeof e==`object`&&!!e&&Symbol.iterator in e}function v(e,t){let n=t.length-e.length;if(n===1){let[n,...r]=t;return g(n,{lazy:e,lazyArgs:r})}if(n===0){let n={lazy:e,lazyArgs:t};return Object.assign(e=>g(e,n),n)}throw Error(`Wrong number of arguments`)}function y(...e){return v(b,e)}function b(e){if(e.length===0)return h;let t=new Map;for(let n of e)t.set(n,(t.get(n)??0)+1);return e=>{let n=t.get(e);return n===void 0||n===0?{done:!1,hasNext:!0,next:e}:(t.set(e,n-1),p)}}function x(...e){return t(re,e)}const re=(e,t)=>e.length>=t,S={asc:(e,t)=>e>t,desc:(e,t)=>e<t};function ie(e,t){let[n,...r]=t;if(!ae(n))return e(n,C(...r));let i=C(n,...r);return t=>e(t,i)}function C(e,t,...n){let r=typeof e==`function`?e:e[0],i=typeof e==`function`?`asc`:e[1],{[i]:a}=S,o=t===void 0?void 0:C(t,...n);return(e,t)=>{let n=r(e),i=r(t);return a(n,i)?1:a(i,n)?-1:o?.(e,t)??0}}function ae(e){if(w(e))return!0;if(typeof e!=`object`||!Array.isArray(e))return!1;let[t,n,...r]=e;return w(t)&&typeof n==`string`&&n in S&&r.length===0}const w=e=>typeof e==`function`&&e.length===1;function T(...e){return t(E,e)}function E(e,t){for(let[n,r]of e.entries())if(!t(r,n,e))return e.slice(n);return[]}function D(...e){return t(Object.entries,e)}function O(...e){return t(k,e,A)}const k=(e,t)=>e.filter(t),A=e=>(t,n,r)=>e(t,n,r)?{done:!1,hasNext:!0,next:t}:p,j=e=>Object.assign(e,{single:!0});function M(...e){return t(N,e,j(P))}const N=(e,t)=>e.find(t),P=e=>(t,n,r)=>e(t,n,r)?{done:!0,hasNext:!0,next:t}:p;function F(...e){return t(I,e)}const I=(e,t)=>{for(let n=e.length-1;n>=0;n--){let r=e[n];if(t(r,n,e))return r}};function L(...e){return t(R,e,j(z))}const R=([e])=>e,z=()=>B,B=e=>({hasNext:!0,next:e,done:!0});function V(t,n){return typeof t==`object`?H(t,n):e(H,t===void 0?[]:[t],U)}const H=(e,t)=>t===void 0?e.flat():e.flat(t),U=e=>e===void 0||e===1?W:e<=0?h:t=>Array.isArray(t)?{next:t.flat(e-1),hasNext:!0,hasMany:!0,done:!1}:{next:t,hasNext:!0,done:!1},W=e=>Array.isArray(e)?{next:e,hasNext:!0,hasMany:!0,done:!1}:{next:e,hasNext:!0,done:!1};function G(...e){return t(K,e,q)}const K=(e,t)=>e.flatMap(t),q=e=>(t,n,r)=>{let i=e(t,n,r);return Array.isArray(i)?{done:!1,hasNext:!0,hasMany:!0,next:i}:{done:!1,hasNext:!0,next:i}};function J(...e){return t(oe,e,se)}function oe(e,t){return e.forEach(t),e}const se=e=>(t,n,r)=>(e(t,n,r),{done:!1,hasNext:!0,next:t});function ce(...e){return t(le,e)}function le(e,t){for(let[n,r]of Object.entries(e))t(r,n,e);return e}function ue(...e){return t(de,e)}function de(e,t){let n={};for(let[r,i]of e.entries())n[i]=t(i,r,e);return n}const Y=Symbol(`funnel/voidReducer`),fe=()=>Y;function pe(e,{triggerAt:t=`end`,minQuietPeriodMs:n,maxBurstDurationMs:r,minGapMs:i,reducer:a=fe}){let o,s,c,l,u=()=>{let t=c;t!==void 0&&(c=void 0,t===Y?e():e(t),i!==void 0&&(s=setTimeout(d,i)))},d=()=>{clearTimeout(s),s=void 0,o===void 0&&u()},f=()=>{clearTimeout(o),o=void 0,l=void 0,s===void 0&&u()};return{call:(...e)=>{let d=o===void 0&&s===void 0;if((t!==`start`||d)&&(c=a(c,...e)),!(o===void 0&&!d)){if(n!==void 0||r!==void 0||i===void 0){clearTimeout(o);let e=Date.now();l??=e;let t=r===void 0?n??0:Math.min(n??r,r-(e-l));o=setTimeout(f,t)}t!==`end`&&d&&u()}},cancel:()=>{clearTimeout(o),o=void 0,l=void 0,clearTimeout(s),s=void 0,c=void 0},flush:()=>{f(),d()},get isIdle(){return o===void 0&&s===void 0}}}function me(...e){return t(he,e)}const he=(e,t)=>{let n=Object.create(null);for(let r=0;r<e.length;r++){let i=e[r],a=t(i,r,e);if(a!==void 0){let e=n[a];e===void 0?n[a]=[i]:e.push(i)}}return Object.setPrototypeOf(n,Object.prototype),n};function ge(...e){return t(_e,e)}function _e(e,t){let n=Object.create(null);for(let r of e){let e=r?.[t];if(e!==void 0){let t=n[e];t===void 0?n[e]=[r]:t.push(r)}}return Object.setPrototypeOf(n,Object.prototype),n}function ve(...e){return t(X,e)}function X(e,t){if(e===t||Object.is(e,t))return!0;if(typeof e!=`object`||typeof t!=`object`||e===null||t===null||Object.getPrototypeOf(e)!==Object.getPrototypeOf(t))return!1;if(Array.isArray(e))return ye(e,t);if(e instanceof Map)return be(e,t);if(e instanceof Set)return xe(e,t);if(e instanceof Date)return e.getTime()===t.getTime();if(e instanceof RegExp)return e.toString()===t.toString();if(Object.keys(e).length!==Object.keys(t).length)return!1;for(let[n,r]of Object.entries(e))if(!(n in t)||!X(r,t[n]))return!1;return!0}function ye(e,t){if(e.length!==t.length)return!1;for(let[n,r]of e.entries())if(!X(r,t[n]))return!1;return!0}function be(e,t){if(e.size!==t.size)return!1;for(let[n,r]of e.entries())if(!t.has(n)||!X(r,t.get(n)))return!1;return!0}function xe(e,t){if(e.size!==t.size)return!1;let n=[...t];for(let t of e){let e=!1;for(let[r,i]of n.entries())if(X(t,i)){e=!0,n.splice(r,1);break}if(!e)return!1}return!0}function Se(){return Ce}const Ce=e=>e;function we(...e){return t(Te,e)}function Te(e,t){let n={};for(let[r,i]of e.entries()){let a=t(i,r,e);n[a]=i}return n}function Ee(e){return Array.isArray(e)}function De(e){return typeof e==`boolean`}function Oe(e){return e!==void 0}function ke(e){return e===``||e===void 0?!0:Array.isArray(e)?e.length===0:Object.keys(e).length===0}function Ae(e){if(e==null||e===``)return!0;if(typeof e!=`object`)return!1;if(`length`in e&&typeof e.length==`number`)return e.length===0;if(`size`in e&&typeof e.size==`number`)return e.size===0;for(let t in e)return!1;return Object.getOwnPropertySymbols(e).length===0}const je=e=>typeof e==`function`;function Me(e){return e!=null}function Ne(e){return t=>!e(t)}function Pe(e){return e==null}function Fe(e){return typeof e==`number`&&!Number.isNaN(e)}function Ie(e){return e instanceof Promise}function Le(...e){return t(Re,e)}function Re(e,t){if(e===t||Object.is(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;if(e instanceof Map&&t instanceof Map)return ze(e,t);if(e instanceof Set&&t instanceof Set)return Be(e,t);let n=Object.keys(e);if(n.length!==Object.keys(t).length)return!1;for(let r of n){if(!Object.hasOwn(t,r))return!1;let{[r]:n}=e,{[r]:i}=t;if(n!==i||!Object.is(n,i))return!1}return!0}function ze(e,t){if(e.size!==t.size)return!1;for(let[n,r]of e){let e=t.get(n);if(r!==e||!Object.is(r,e))return!1}return!0}function Be(e,t){if(e.size!==t.size)return!1;for(let n of e)if(!t.has(n))return!1;return!0}function Ve(e){return typeof e==`string`}function He(e){return!!e}function Ue(...e){return t(Object.keys,e)}function We(...e){return t(Ge,e)}const Ge=e=>e.at(-1);function Ke(...e){return t(qe,e,Je)}const qe=(e,t)=>e.map(t),Je=e=>(t,n,r)=>({done:!1,hasNext:!0,next:e(t,n,r)});function Ye(...e){return t(Xe,e)}function Xe(e,t){let n={};for(let[r,i]of e.entries()){let[a,o]=t(i,r,e);n[a]=o}return n}function Ze(...e){return t(Qe,e)}function Qe(e,t){let n={};for(let[r,i]of Object.entries(e))n[r]=t(i,r,e);return n}function $e(...e){return t(et,e)}function et(e,t){if(!x(t,1))return{...e};if(!x(t,2)){let{[t[0]]:n,...r}=e;return r}let n={...e};for(let e of t)delete n[e];return n}function tt(...e){return t(nt,e)}function nt(e,t){let n={...e};for(let[r,i]of Object.entries(n))t(i,r,e)&&delete n[r];return n}function rt(...e){return t(it,e)}const it=e=>e.length===1?e[0]:void 0;function at(...e){return t(ot,e)}const ot=(e,t)=>{let n=[[],[]];for(let[r,i]of e.entries())t(i,r,e)?n[0].push(i):n[1].push(i);return n};function st(...e){return t(ct,e)}function ct(e,t){let n={};for(let r of t)r in e&&(n[r]=e[r]);return n}function lt(...e){return t(ut,e)}function ut(e,t){let n={};for(let[r,i]of Object.entries(e))t(i,r,e)&&(n[r]=i);return n}function dt(...e){return t=>g(t,...e)}function ft(e,...t){return typeof e==`string`||typeof e==`number`||typeof e==`symbol`?n=>Z(n,e,...t):Z(e,...t)}function Z(e,...t){let n=e;for(let e of t){if(n==null)return;n=n[e]}return n}function pt(...e){return t(mt,e)}function mt(e,t,n){let r={};for(let[i,a]of e.entries()){let o=t(a,i,e);r[o]=n(a,i,e)}return r}function ht(e,t){let n=Math.ceil(e),r=Math.floor(t);if(r<n)throw RangeError(`randomInteger: The range [${e.toString()},${t.toString()}] contains no integer`);return Math.floor(Math.random()*(r-n+1)+n)}function gt(...e){return t(_t,e)}const _t=(e,t,n)=>e.reduce(t,n);function vt(...e){return t(yt,e)}function yt(e){return[...e].reverse()}function bt(...e){return t(xt,e)}function xt(e,t){let n=[...e];return n.sort(t),n}function St(...e){return ie(Ct,e)}const Ct=(e,t)=>[...e].sort(t);function wt(e,t,n){return typeof t==`number`||t===void 0?n=>n.split(e,t):e.split(t,n)}function Tt(...e){return t(Et,e,Dt)}const Et=(e,t)=>t<0?[]:e.slice(0,t);function Dt(e){if(e<=0)return m;let t=e;return e=>(--t,{done:t<=0,hasNext:!0,next:e})}function Q(...e){return t(Ot,e)}function Ot(e,t){let n=[];for(let[r,i]of e.entries()){if(!t(i,r,e))break;n.push(i)}return n}function kt(...e){return t(At,e)}function At(e,t){return t(e),e}function jt(...e){return v(Mt,e)}function Mt(){let e=new Set;return t=>e.has(t)?p:(e.add(t),{done:!1,hasNext:!0,next:t})}function Nt(...e){return v(Pt,e)}function Pt(e){let t=e,n=new Set;return(e,r,i)=>{let a=t(e,r,i);return n.has(a)?p:(n.add(a),{done:!1,hasNext:!0,next:e})}}function Ft(...e){return t(Object.values,e)}function It(...e){return e.length===2?(t,...n)=>$(t,...e,...n):$(...e)}const $=(e,t,n,...r)=>t(e,...r)?typeof n==`function`?n(e,...r):n.onTrue(e,...r):typeof n==`function`?e:n.onFalse(e,...r);function Lt(...e){return t(Rt,e,zt)}const Rt=(e,t)=>e.length<t.length?e.map((e,n)=>[e,t[n]]):t.map((t,n)=>[e[n],t]),zt=e=>(t,n)=>({hasNext:!0,next:[t,e[n]],done:n>=e.length-1});export{V as $,Ve as A,Oe as B,$e as C,We as D,Ke as E,Ne as F,ve as G,Ee as H,Me as I,pe as J,ge as K,je as L,Ie as M,Fe as N,Ue as O,Pe as P,G as Q,Ae as R,tt as S,Ye as T,we as U,De as V,Se as W,ce as X,ue as Y,J as Z,dt as _,jt as a,T as at,at as b,Tt as c,g as ct,bt as d,c as dt,L as et,vt as f,o as ft,ft as g,pt as h,Nt as i,D as it,Le as j,He as k,wt as l,f as lt,ht as m,n as mt,It as n,M as nt,kt as o,x as ot,gt as p,i as pt,me as q,Ft as r,O as rt,Q as s,y as st,Lt as t,F as tt,St as u,u as ut,lt as v,Ze as w,rt as x,st as y,ke as z};
|
|
1
|
+
function e(e,t,n){let r=n=>e(n,...t);return n===void 0?r:Object.assign(r,{lazy:n,lazyArgs:t})}function t(t,n,r){let i=t.length-n.length;if(i===0)return t(...n);if(i===1)return e(t,n,r);throw Error(`Wrong number of arguments`)}function n(...e){return t(r,e)}const r=(e,t)=>t.every(t=>t(e));function i(...e){return t(a,e)}const a=(e,t)=>t.some(t=>t(e));function o(...e){return t(s,e)}function s(e,t){if(t<1)throw RangeError(`chunk: A chunk size of '${t.toString()}' would result in an infinite array`);if(e.length===0)return[];if(t>=e.length)return[[...e]];let n=Math.ceil(e.length/t),r=Array(n);if(t===1)for(let[t,n]of e.entries())r[t]=[n];else for(let i=0;i<n;i+=1){let n=i*t;r[i]=e.slice(n,n+t)}return r}function c(...e){return t(l,e)}const l=(e,{min:t,max:n})=>t!==void 0&&e<t?t:n!==void 0&&e>n?n:e;function u(...e){return t(d,e)}const d=(e,t)=>[...e,...t];function f(e){return()=>e}const ee={done:!0,hasNext:!1},p={done:!1,hasNext:!1},m=()=>ee,h=e=>({hasNext:!0,next:e,done:!1});function g(e,...t){let n=e,r=t.map(e=>`lazy`in e?te(e):void 0),i=0;for(;i<t.length;){if(r[i]===void 0||!ne(n)){let e=t[i];n=e(n),i+=1;continue}let e=[];for(let n=i;n<t.length;n++){let t=r[n];if(t===void 0||(e.push(t),t.isSingle))break}let a=[];for(let t of n)if(_(t,a,e))break;let{isSingle:o}=e.at(-1);n=o?a[0]:a,i+=e.length}return n}function _(e,t,n){if(n.length===0)return t.push(e),!1;let r=e,i=p,a=!1;for(let[e,o]of n.entries()){let{index:s,items:c}=o;if(c.push(r),i=o(r,s,c),o.index+=1,i.hasNext){if(i.hasMany??!1){for(let r of i.next)if(_(r,t,n.slice(e+1)))return!0;return a}r=i.next}if(!i.hasNext)break;i.done&&(a=!0)}return i.hasNext&&t.push(r),a}function te(e){let{lazy:t,lazyArgs:n}=e,r=t(...n);return Object.assign(r,{isSingle:t.single??!1,index:0,items:[]})}function ne(e){return typeof e==`string`||typeof e==`object`&&!!e&&Symbol.iterator in e}function v(e,t){let n=t.length-e.length;if(n===1){let[n,...r]=t;return g(n,{lazy:e,lazyArgs:r})}if(n===0){let n={lazy:e,lazyArgs:t};return Object.assign(e=>g(e,n),n)}throw Error(`Wrong number of arguments`)}function y(...e){return v(b,e)}function b(e){if(e.length===0)return h;let t=new Map;for(let n of e)t.set(n,(t.get(n)??0)+1);return e=>{let n=t.get(e);return n===void 0||n===0?{done:!1,hasNext:!0,next:e}:(t.set(e,n-1),p)}}function x(...e){return t(re,e)}const re=(e,t)=>e.length>=t,S={asc:(e,t)=>e>t,desc:(e,t)=>e<t};function ie(e,t){let[n,...r]=t;if(!ae(n))return e(n,C(...r));let i=C(n,...r);return t=>e(t,i)}function C(e,t,...n){let r=typeof e==`function`?e:e[0],i=typeof e==`function`?`asc`:e[1],{[i]:a}=S,o=t===void 0?void 0:C(t,...n);return(e,t)=>{let n=r(e),i=r(t);return a(n,i)?1:a(i,n)?-1:o?.(e,t)??0}}function ae(e){if(w(e))return!0;if(typeof e!=`object`||!Array.isArray(e))return!1;let[t,n,...r]=e;return w(t)&&typeof n==`string`&&n in S&&r.length===0}const w=e=>typeof e==`function`&&e.length===1;function T(...e){return t(E,e)}function E(e,t){for(let[n,r]of e.entries())if(!t(r,n,e))return e.slice(n);return[]}function D(...e){return t(Object.entries,e)}function O(...e){return t(k,e,A)}const k=(e,t)=>e.filter(t),A=e=>(t,n,r)=>e(t,n,r)?{done:!1,hasNext:!0,next:t}:p,j=e=>Object.assign(e,{single:!0});function M(...e){return t(N,e,j(P))}const N=(e,t)=>e.find(t),P=e=>(t,n,r)=>e(t,n,r)?{done:!0,hasNext:!0,next:t}:p;function F(...e){return t(I,e)}const I=(e,t)=>{for(let n=e.length-1;n>=0;n--){let r=e[n];if(t(r,n,e))return r}};function L(...e){return t(R,e,j(z))}const R=([e])=>e,z=()=>B,B=e=>({hasNext:!0,next:e,done:!0});function V(t,n){return typeof t==`object`?H(t,n):e(H,t===void 0?[]:[t],U)}const H=(e,t)=>t===void 0?e.flat():e.flat(t),U=e=>e===void 0||e===1?W:e<=0?h:t=>Array.isArray(t)?{next:t.flat(e-1),hasNext:!0,hasMany:!0,done:!1}:{next:t,hasNext:!0,done:!1},W=e=>Array.isArray(e)?{next:e,hasNext:!0,hasMany:!0,done:!1}:{next:e,hasNext:!0,done:!1};function G(...e){return t(K,e,q)}const K=(e,t)=>e.flatMap(t),q=e=>(t,n,r)=>{let i=e(t,n,r);return Array.isArray(i)?{done:!1,hasNext:!0,hasMany:!0,next:i}:{done:!1,hasNext:!0,next:i}};function J(...e){return t(oe,e,se)}function oe(e,t){return e.forEach(t),e}const se=e=>(t,n,r)=>(e(t,n,r),{done:!1,hasNext:!0,next:t});function ce(...e){return t(le,e)}function le(e,t){for(let[n,r]of Object.entries(e))t(r,n,e);return e}const Y=Symbol(`funnel/voidReducer`),ue=()=>Y;function de(e,{triggerAt:t=`end`,minQuietPeriodMs:n,maxBurstDurationMs:r,minGapMs:i,reducer:a=ue}){let o,s,c,l,u=()=>{let t=c;t!==void 0&&(c=void 0,t===Y?e():e(t),i!==void 0&&(s=setTimeout(d,i)))},d=()=>{clearTimeout(s),s=void 0,o===void 0&&u()},f=()=>{clearTimeout(o),o=void 0,l=void 0,s===void 0&&u()};return{call:(...e)=>{let d=o===void 0&&s===void 0;if((t!==`start`||d)&&(c=a(c,...e)),!(o===void 0&&!d)){if(n!==void 0||r!==void 0||i===void 0){clearTimeout(o);let e=Date.now();l??=e;let t=r===void 0?n??0:Math.min(n??r,Math.max(0,r-(e-l)));o=setTimeout(f,t)}t!==`end`&&d&&u()}},cancel:()=>{clearTimeout(o),o=void 0,l=void 0,clearTimeout(s),s=void 0,c=void 0},flush:()=>{f(),d()},get isIdle(){return o===void 0&&s===void 0}}}function fe(...e){return t(pe,e)}const pe=(e,t)=>{let n=Object.create(null);for(let r=0;r<e.length;r++){let i=e[r],a=t(i,r,e);if(a!==void 0){let e=n[a];e===void 0?n[a]=[i]:e.push(i)}}return Object.setPrototypeOf(n,Object.prototype),n};function me(...e){return t(he,e)}function he(e,t){let n=Object.create(null);for(let r of e){let e=r?.[t];if(e!==void 0){let t=n[e];t===void 0?n[e]=[r]:t.push(r)}}return Object.setPrototypeOf(n,Object.prototype),n}function ge(...e){return t(X,e)}function X(e,t){if(e===t||Object.is(e,t))return!0;if(typeof e!=`object`||typeof t!=`object`||e===null||t===null||Object.getPrototypeOf(e)!==Object.getPrototypeOf(t))return!1;if(Array.isArray(e))return _e(e,t);if(e instanceof Map)return ve(e,t);if(e instanceof Set)return ye(e,t);if(e instanceof Date)return e.getTime()===t.getTime();if(e instanceof RegExp)return e.toString()===t.toString();if(Object.keys(e).length!==Object.keys(t).length)return!1;for(let[n,r]of Object.entries(e))if(!(n in t)||!X(r,t[n]))return!1;return!0}function _e(e,t){if(e.length!==t.length)return!1;for(let[n,r]of e.entries())if(!X(r,t[n]))return!1;return!0}function ve(e,t){if(e.size!==t.size)return!1;for(let[n,r]of e.entries())if(!t.has(n)||!X(r,t.get(n)))return!1;return!0}function ye(e,t){if(e.size!==t.size)return!1;let n=[...t];for(let t of e){let e=!1;for(let[r,i]of n.entries())if(X(t,i)){e=!0,n.splice(r,1);break}if(!e)return!1}return!0}function be(){return xe}const xe=e=>e;function Se(...e){return t(Ce,e)}function Ce(e,t){let n={};for(let[r,i]of e.entries()){let a=t(i,r,e);n[a]=i}return n}function we(e){return Array.isArray(e)}function Te(e){return typeof e==`boolean`}function Ee(e){return e!==void 0}function De(e){return e===``||e===void 0?!0:Array.isArray(e)?e.length===0:Object.keys(e).length===0}function Oe(e){if(e==null||e===``)return!0;if(typeof e!=`object`)return!1;if(`length`in e&&typeof e.length==`number`)return e.length===0;if(`size`in e&&typeof e.size==`number`)return e.size===0;for(let t in e)return!1;return Object.getOwnPropertySymbols(e).length===0}const ke=e=>typeof e==`function`;function Ae(e){return e!=null}function je(e){return t=>!e(t)}function Me(e){return e==null}function Ne(e){return typeof e==`number`&&!Number.isNaN(e)}function Pe(e){return e instanceof Promise}function Fe(...e){return t(Ie,e)}function Ie(e,t){if(e===t||Object.is(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;if(e instanceof Map&&t instanceof Map)return Le(e,t);if(e instanceof Set&&t instanceof Set)return Re(e,t);let n=Object.keys(e);if(n.length!==Object.keys(t).length)return!1;for(let r of n){if(!Object.hasOwn(t,r))return!1;let{[r]:n}=e,{[r]:i}=t;if(n!==i||!Object.is(n,i))return!1}return!0}function Le(e,t){if(e.size!==t.size)return!1;for(let[n,r]of e){let e=t.get(n);if(r!==e||!Object.is(r,e))return!1}return!0}function Re(e,t){if(e.size!==t.size)return!1;for(let n of e)if(!t.has(n))return!1;return!0}function ze(e){return typeof e==`string`}function Be(e){return!!e}function Ve(...e){return t(Object.keys,e)}function He(...e){return t(Ue,e)}const Ue=e=>e.at(-1);function We(...e){return t(Ge,e,Ke)}const Ge=(e,t)=>e.map(t),Ke=e=>(t,n,r)=>({done:!1,hasNext:!0,next:e(t,n,r)});function qe(...e){return t(Je,e)}function Je(e,t){let n={};for(let[r,i]of e.entries()){let[a,o]=t(i,r,e);n[a]=o}return n}function Ye(...e){return t(Xe,e)}function Xe(e,t){let n={};for(let[r,i]of Object.entries(e))n[r]=t(i,r,e);return n}function Ze(...e){return t(Qe,e)}function Qe(e,t){if(!x(t,1))return{...e};if(!x(t,2)){let{[t[0]]:n,...r}=e;return r}let n={...e};for(let e of t)delete n[e];return n}function $e(...e){return t(et,e)}function et(e,t){let n={...e};for(let[r,i]of Object.entries(n))t(i,r,e)&&delete n[r];return n}function tt(e){let t=!1,n;return()=>(t||=(n=e(),!0),n)}function nt(...e){return t(rt,e)}const rt=e=>e.length===1?e[0]:void 0;function it(...e){return t(at,e)}const at=(e,t)=>{let n=[[],[]];for(let[r,i]of e.entries())t(i,r,e)?n[0].push(i):n[1].push(i);return n};function ot(...e){return t(st,e)}function st(e,t){let n={};for(let r of t)r in e&&(n[r]=e[r]);return n}function ct(...e){return t(lt,e)}function lt(e,t){let n={};for(let[r,i]of Object.entries(e))t(i,r,e)&&(n[r]=i);return n}function ut(...e){return t=>g(t,...e)}function dt(e,...t){return typeof e==`string`||typeof e==`number`||typeof e==`symbol`?n=>Z(n,e,...t):Z(e,...t)}function Z(e,...t){let n=e;for(let e of t){if(n==null)return;n=n[e]}return n}function ft(...e){return t(pt,e)}function pt(e,t,n){let r={};for(let[i,a]of e.entries()){let o=t(a,i,e);r[o]=n(a,i,e)}return r}function mt(e,t){let n=Math.ceil(e),r=Math.floor(t);if(r<n)throw RangeError(`randomInteger: The range [${e.toString()},${t.toString()}] contains no integer`);return Math.floor(Math.random()*(r-n+1)+n)}function ht(...e){return t(gt,e)}const gt=(e,t,n)=>e.reduce(t,n);function _t(...e){return t(vt,e)}function vt(e){return[...e].reverse()}function yt(...e){return t(bt,e)}function bt(e,t){let n=[...e];return n.sort(t),n}function xt(...e){return ie(St,e)}const St=(e,t)=>[...e].sort(t);function Ct(e,t,n){return typeof t==`number`||t===void 0?n=>n.split(e,t):e.split(t,n)}function wt(...e){return t(Tt,e,Et)}const Tt=(e,t)=>t<0?[]:e.slice(0,t);function Et(e){if(e<=0)return m;let t=e;return e=>(--t,{done:t<=0,hasNext:!0,next:e})}function Dt(...e){return t(Q,e)}function Q(e,t){let n=[];for(let[r,i]of e.entries()){if(!t(i,r,e))break;n.push(i)}return n}function Ot(...e){return t(kt,e)}function kt(e,t){return t(e),e}function At(...e){return v(jt,e)}function jt(){let e=new Set;return t=>e.has(t)?p:(e.add(t),{done:!1,hasNext:!0,next:t})}function Mt(...e){return v(Nt,e)}function Nt(e){let t=e,n=new Set;return(e,r,i)=>{let a=t(e,r,i);return n.has(a)?p:(n.add(a),{done:!1,hasNext:!0,next:e})}}function Pt(...e){return t(Object.values,e)}function Ft(...e){return e.length===2?(t,...n)=>$(t,...e,...n):$(...e)}const $=(e,t,n,...r)=>t(e,...r)?typeof n==`function`?n(e,...r):n.onTrue(e,...r):typeof n==`function`?e:n.onFalse(e,...r);function It(...e){return t(Lt,e,Rt)}const Lt=(e,t)=>e.length<t.length?e.map((e,n)=>[e,t[n]]):t.map((t,n)=>[e[n],t]),Rt=e=>(t,n)=>({hasNext:!0,next:[t,e[n]],done:n>=e.length-1});export{V as $,Be as A,De as B,$e as C,We as D,qe as E,Me as F,be as G,Te as H,je as I,fe as J,ge as K,Ae as L,Fe as M,Pe as N,He as O,Ne as P,G as Q,ke as R,tt as S,Ye as T,we as U,Ee as V,Se as W,ce as X,de as Y,J as Z,ut as _,At as a,T as at,it as b,wt as c,g as ct,yt as d,c as dt,L as et,_t as f,o as ft,dt as g,ft as h,t as ht,Mt as i,D as it,ze as j,Ve as k,Ct as l,f as lt,mt as m,n as mt,Ft as n,M as nt,Ot as o,x as ot,ht as p,i as pt,me as q,Pt as r,O as rt,Dt as s,y as st,It as t,F as tt,xt as u,u as ut,ct as v,Ze as w,nt as x,ot as y,Oe as z};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function e(
|
|
1
|
+
function e(t,n,r,i){if(typeof t?.toJSON==`function`&&(t=t.toJSON()),!(typeof t==`object`&&t))return t;if(n.has(t)){if(!r)return`[Circular]`;let e=n.get(t);return`[Circular ${e===``?`*`:`*${e}`}]`}n.set(t,i);let a=Array.isArray(t)?[]:{};for(let[o,s]of Object.entries(t))a[o]=e(s,n,r,i===``?o:`${i}.${o}`);return n.delete(t),a}function t(t,{indentation:n,trace:r}={}){let i=e(t,new WeakMap,r,``);return JSON.stringify(i,void 0,n)}export{t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
String.fromCharCode;const e=/^[\s\w\0+.-]{2,}:([/\\]{1,2})/,t=/^[\s\w\0+.-]{2,}:([/\\]{2})?/,n=/^([/\\]\s*){2,}[^/\\]/,r=/\/$|\/\?|\/#/,i=/^\.?\//;function a(e){return[`./`,`../`].some(t=>e.startsWith(t))}function o(r,i={}){return typeof i==`boolean`&&(i={acceptRelative:i}),i.strict?e.test(r):t.test(r)||(i.acceptRelative?n.test(r):!1)}function s(e=``,t){return t?r.test(e):e.endsWith(`/`)}function c(e=``,t){if(!t)return(s(e)?e.slice(0,-1):e)||`/`;if(!s(e,!0))return e||`/`;let n=e,r=``,i=e.indexOf(`#`);i!==-1&&(n=e.slice(0,i),r=e.slice(i));let[a,...o]=n.split(`?`);return((a.endsWith(`/`)?a.slice(0,-1):a)||`/`)+(o.length>0?`?${o.join(`?`)}`:``)+r}function l(e=``,t){if(!t)return e.endsWith(`/`)?e:e+`/`;if(s(e,!0))return e||`/`;let n=e,r=``,i=e.indexOf(`#`);if(i!==-1&&(n=e.slice(0,i),r=e.slice(i),!n))return r;let[a,...o]=n.split(`?`);return a+`/`+(o.length>0?`?${o.join(`?`)}`:``)+r}function u(e=``){return e.startsWith(`/`)}function d(e=``){return(u(e)?e.slice(1):e)||`/`}function f(e=``){return e.split(`://`).map(e=>e.replace(/\/{2,}/g,`/`)).join(`://`)}function p(e,t){if(m(t))return e;let n=c(t);if(!e.startsWith(n))return e;let r=e[n.length];if(r&&r!==`/`&&r!==`?`)return e;let i=e.slice(n.length);return i[0]===`/`?i:`/`+i}function m(e){return!e||e===`/`}function h(e){return e&&e!==`/`}function g(e,...t){let n=e||``;for(let e of t.filter(e=>h(e)))if(n){let t=e.replace(i,``);n=l(n)+t}else n=e;return n}function _(...e){let t=/\/(?!\/)/,n=e.filter(Boolean),r=[],i=0;for(let e of n)if(!(!e||e===`/`)){for(let[n,a]of e.split(t).entries())if(!(!a||a===`.`)){if(a===`..`){if(r.length===1&&o(r[0]))continue;r.pop(),i--;continue}if(n===1&&r[r.length-1]?.endsWith(`:/`)){r[r.length-1]+=`/`+a;continue}r.push(a),i++}}let a=r.join(`/`);return i>=0?n[0]?.startsWith(`/`)&&!a.startsWith(`/`)?a=`/`+a:n[0]?.startsWith(`./`)&&!a.startsWith(`./`)&&(a=`./`+a):a=`../`.repeat(-1*i)+a,n[n.length-1]?.endsWith(`/`)&&!a.endsWith(`/`)&&(a+=`/`),a}function v(e){return y(e,``)}function y(e,n){let r=e.match(t);return r||=e.match(/^\/{2,}/),r?n+e.slice(r[0].length):n+e}
|
|
1
|
+
String.fromCharCode;const e=/^[\s\w\0+.-]{2,}:([/\\]{1,2})/,t=/^[\s\w\0+.-]{2,}:([/\\]{2})?/,n=/^([/\\]\s*){2,}[^/\\]/,r=/\/$|\/\?|\/#/,i=/^\.?\//;function a(e){return[`./`,`../`].some(t=>e.startsWith(t))}function o(r,i={}){return typeof i==`boolean`&&(i={acceptRelative:i}),i.strict?e.test(r):t.test(r)||(i.acceptRelative?n.test(r):!1)}function s(e=``,t){return t?r.test(e):e.endsWith(`/`)}function c(e=``,t){if(!t)return(s(e)?e.slice(0,-1):e)||`/`;if(!s(e,!0))return e||`/`;let n=e,r=``,i=e.indexOf(`#`);i!==-1&&(n=e.slice(0,i),r=e.slice(i));let[a,...o]=n.split(`?`);return((a.endsWith(`/`)?a.slice(0,-1):a)||`/`)+(o.length>0?`?${o.join(`?`)}`:``)+r}function l(e=``,t){if(!t)return e.endsWith(`/`)?e:e+`/`;if(s(e,!0))return e||`/`;let n=e,r=``,i=e.indexOf(`#`);if(i!==-1&&(n=e.slice(0,i),r=e.slice(i),!n))return r;let[a,...o]=n.split(`?`);return a+`/`+(o.length>0?`?${o.join(`?`)}`:``)+r}function u(e=``){return e.startsWith(`/`)}function d(e=``){return(u(e)?e.slice(1):e)||`/`}function f(e=``){return e.split(`://`).map(e=>e.replace(/\/{2,}/g,`/`)).join(`://`)}function p(e,t){if(m(t))return e;let n=c(t);if(!e.startsWith(n))return e;let r=e[n.length];if(r&&r!==`/`&&r!==`?`)return e;let i=e.slice(n.length);return i[0]===`/`?i:`/`+i}function m(e){return!e||e===`/`}function h(e){return e&&e!==`/`}function g(e,...t){let n=e||``;for(let e of t.filter(e=>h(e)))if(n){let t=e.replace(i,``);n=l(n)+t}else n=e;return n}function _(...e){let t=/\/(?!\/)/,n=e.filter(Boolean),r=[],i=0;for(let e of n)if(!(!e||e===`/`)){for(let[n,a]of e.split(t).entries())if(!(!a||a===`.`)){if(a===`..`){if(r.length===1&&o(r[0]))continue;r.pop(),i--;continue}if(n===1&&r[r.length-1]?.endsWith(`:/`)){r[r.length-1]+=`/`+a;continue}r.push(a),i++}}let a=r.join(`/`);return i>=0?n[0]?.startsWith(`/`)&&!a.startsWith(`/`)?a=`/`+a:n[0]?.startsWith(`./`)&&!a.startsWith(`./`)&&(a=`./`+a):a=`../`.repeat(-1*i)+a,n[n.length-1]?.endsWith(`/`)&&!a.endsWith(`/`)&&(a+=`/`),a}function v(e){return y(e,``)}function y(e,n){let r=e.match(t);return r||=e.match(/^\/{2,}/),r?n+e.slice(r[0].length):n+e}export{_ as a,p as c,c as d,a as i,d as l,u as n,g as o,o as r,l as s,f as t,v as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createRequire as e}from"node:module";var t=Object.create,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.getPrototypeOf,o=Object.prototype.hasOwnProperty,s=(e,t)=>()=>(e&&(t=e(e=0)),t),c=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),l=(e,t)=>{let r={};for(var i in e)n(r,i,{get:e[i],enumerable:!0});return t
|
|
1
|
+
import{createRequire as e}from"node:module";var t=Object.create,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.getPrototypeOf,o=Object.prototype.hasOwnProperty,s=(e,t)=>()=>(e&&(t=e(e=0)),t),c=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),l=(e,t)=>{let r={};for(var i in e)n(r,i,{get:e[i],enumerable:!0});return t||n(r,Symbol.toStringTag,{value:`Module`}),r},u=(e,t,a,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var c=i(t),l=0,u=c.length,d;l<u;l++)d=c[l],!o.call(e,d)&&d!==a&&n(e,d,{get:(e=>t[e]).bind(null,d),enumerable:!(s=r(t,d))||s.enumerable});return e},d=(e,t,n)=>(u(e,t,`default`),n&&u(n,t,`default`)),f=(e,r,i)=>(i=e==null?{}:t(a(e)),u(r||!e||!e.__esModule?n(i,`default`,{value:e,enumerable:!0}):i,e)),p=e=>o.call(e,`module.exports`)?e[`module.exports`]:u(n({},`__esModule`,{value:!0}),e),m=e(import.meta.url);export{m as a,d as i,s as n,p as o,l as r,f as s,c as t};
|