From a827e526ac65f84a35b0e01422435a17b25f6af4 Mon Sep 17 00:00:00 2001 From: David Newell Date: Fri, 28 Nov 2025 11:01:23 +0100 Subject: [PATCH 1/3] Removing jshint, karma, browserify, bower and updating the index.d.ts --- .eslintrc.json | 41 +- .github/workflows/build.yml | 17 +- Makefile | 68 +- build.js | 62 + dist/dagre.cjs.js | 2 + dist/dagre.cjs.js.map | 7 + dist/dagre.d.ts | 598 + dist/dagre.esm.js | 2 + dist/dagre.esm.js.map | 7 + dist/dagre.js | 1241 ++ dist/dagre.js.map | 7 + dist/dagre.min.js | 2 + dist/dagre.min.js.map | 7 + dist/graphlib.core.js | 1396 -- dist/graphlib.core.min.js | 304 - dist/graphlib.js | 1396 -- dist/graphlib.min.js | 304 - index.d.ts | 1207 +- jest.config.js | 25 + karma.conf.js | 68 - karma.core.conf.js | 68 - package-lock.json | 14565 +++++++++------- package.json | 45 +- src/bench.js | 100 +- src/release/bump-version.js | 4 +- src/release/check-version.js | 4 +- src/release/make-version.js | 4 +- test/alg/components-test.js | 9 +- test/alg/dijkstra-all-test.js | 5 +- test/alg/dijkstra-test.js | 15 +- test/alg/find-cycles-test.js | 13 +- test/alg/floyd-warshall-test.js | 7 +- test/alg/is-acyclic-test.js | 9 +- test/alg/postorder-test.js | 31 +- test/alg/preorder-test.js | 23 +- test/alg/prim-test.js | 21 +- test/alg/tarjan-test.js | 11 +- test/alg/topsort-test.js | 19 +- .../{ => utils}/all-shortest-paths-test.js | 13 +- test/bundle-test.js | 26 +- test/chai.js | 5 - test/data/priority-queue-test.js | 50 +- test/graph-test.js | 488 +- test/json-test.js | 51 +- test/test-main.js | 39 - test/version-test.js | 4 +- 46 files changed, 11037 insertions(+), 11353 deletions(-) create mode 100644 build.js create mode 100644 dist/dagre.cjs.js create mode 100644 dist/dagre.cjs.js.map create mode 100644 dist/dagre.d.ts create mode 100644 dist/dagre.esm.js create mode 100644 dist/dagre.esm.js.map create mode 100644 dist/dagre.js create mode 100644 dist/dagre.js.map create mode 100644 dist/dagre.min.js create mode 100644 dist/dagre.min.js.map delete mode 100644 dist/graphlib.core.js delete mode 100644 dist/graphlib.core.min.js delete mode 100644 dist/graphlib.js delete mode 100644 dist/graphlib.min.js create mode 100644 jest.config.js delete mode 100644 karma.conf.js delete mode 100644 karma.core.conf.js rename test/alg/{ => utils}/all-shortest-paths-test.js (92%) delete mode 100644 test/chai.js delete mode 100644 test/test-main.js diff --git a/.eslintrc.json b/.eslintrc.json index 67a5caa7..a54ca15a 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -1,22 +1,21 @@ -{ - "extends": "eslint:recommended", - "env": { - "browser": true, - "node": true, - "mocha": true - }, - "parserOptions": { - "ecmaVersion": "latest" - }, - "env": { - "es6": true, - "mocha": true, - "node": true - }, - "rules": { - "indent": [ "error", 2 ], - "linebreak-style": [ "error", "unix" ], - "no-prototype-builtins": 0, - "semi": [ "error", "always" ] - } +{ + "extends": "eslint:recommended", + "env": { + "browser": true, + "es6": true, + "node": true, + "jest": true + }, + "parserOptions": { + "ecmaVersion": "latest", + "sourceType": "module", + "allowImportExportEverywhere": true + }, + "rules": { + "indent": [ "error", 2 ], + "linebreak-style": [ "error", "unix" ], + "no-prototype-builtins": 0, + "semi": [ "error", "always" ] + }, + "ignorePatterns": ["dist/*", "build/*", "index.d.ts"] } diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d5e5c6c7..65dea2e7 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -14,11 +14,11 @@ jobs: node-version: [18.x] steps: - - uses: actions/checkout@v2 - - uses: browser-actions/setup-chrome@latest + - name: Checkout repository + uses: actions/checkout@v4 - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} cache: 'npm' @@ -27,16 +27,15 @@ jobs: - name: Install dependencies run: | npm install - sudo apt-get install graphviz xvfb - - - name: Build - run: | - make build/graphlib.js build/graphlib.min.js - name: Lint run: | make lint + - name: Build + run: | + make build + - name: Test run: | - KARMA_OPTS="--browsers Chrome" xvfb-run --auto-servernum make -e test + make test diff --git a/Makefile b/Makefile index 7b3bded5..4781bf30 100644 --- a/Makefile +++ b/Makefile @@ -1,74 +1,36 @@ MOD = graphlib NPM = npm -NYC = nyc -BROWSERIFY = ./node_modules/browserify/bin/cmd.js -JSHINT = ./node_modules/jshint/bin/jshint -ESLINT = ./node_modules/eslint/bin/eslint.js -KARMA = ./node_modules/karma/bin/karma -MOCHA = ./node_modules/mocha/bin/_mocha -UGLIFY = ./node_modules/uglify-js/bin/uglifyjs -JSHINT_OPTS = --reporter node_modules/jshint-stylish/index.js -MOCHA_OPTS = -R dot - -BUILD_DIR = build -COVERAGE_DIR = ./.nyc_output DIST_DIR = dist SRC_FILES = index.js lib/version.js $(shell find lib -type f -name '*.js') -TEST_FILES = $(shell find test -type f -name '*.js' | grep -v 'bundle-test.js' | grep -v 'test-main.js') -BUILD_FILES = $(addprefix $(BUILD_DIR)/, \ - $(MOD).js $(MOD).min.js \ - $(MOD).core.js $(MOD).core.min.js) - -DIRS = $(BUILD_DIR) +TEST_FILES = $(shell find test -type f -name '*.js' | grep -v 'bundle-test.js') +BUILD_FILES = $(addprefix $(DIST_DIR)/, $(MOD).cjs.js $(MOD).esm.js $(MOD).min.js $(MOD).js) -.PHONY: all bench clean browser-test unit-test test dist +.PHONY: all bench clean test dist lint build release node_modules -all: unit-test lint +all: build test -bench: unit-test lint +bench: test @src/bench.js lib/version.js: package.json @src/release/make-version.js > $@ -$(DIRS): - @mkdir -p $@ - -test: unit-test browser-test - -unit-test: $(SRC_FILES) $(TEST_FILES) node_modules | $(BUILD_DIR) - $(NYC) $(MOCHA) --dir $(COVERAGE_DIR) -- $(MOCHA_OPTS) $(TEST_FILES) || $(MOCHA) $(MOCHA_OPTS) $(TEST_FILES) - -browser-test: $(BUILD_DIR)/$(MOD).js $(BUILD_DIR)/$(MOD).core.js - $(KARMA) start --single-run $(KARMA_OPTS) - $(KARMA) start karma.core.conf.js --single-run $(KARMA_OPTS) - -bower.json: package.json src/release/make-bower.json.js - @src/release/make-bower.json.js > $@ - lint: - @$(JSHINT) $(JSHINT_OPTS) $(filter-out node_modules, $?) - @$(ESLINT) $(SRC_FILES) $(TEST_FILES) - -$(BUILD_DIR)/$(MOD).js: index.js $(SRC_FILES) | unit-test - @$(BROWSERIFY) $< > $@ -s graphlib - -$(BUILD_DIR)/$(MOD).min.js: $(BUILD_DIR)/$(MOD).js - @$(UGLIFY) $< --comments '@license' > $@ + @echo "Running lint check via npm (ESLint)..." + @$(NPM) run lint -$(BUILD_DIR)/$(MOD).core.js: index.js $(SRC_FILES) | unit-test - @$(BROWSERIFY) $< > $@ --no-bundle-external -s graphlib +build: + @echo "Running project build via npm (esbuild)..." + @$(NPM) run build -$(BUILD_DIR)/$(MOD).core.min.js: $(BUILD_DIR)/$(MOD).core.js - @$(UGLIFY) $< --comments '@license' > $@ +test: lint + @$(NPM) run test -dist: $(BUILD_FILES) | bower.json test - @rm -rf $@ - @mkdir -p $@ - @cp $^ dist +dist: build test + @echo "Dist files are built in 'dist/' by the 'build' target." release: dist @echo @@ -77,7 +39,7 @@ release: dist @src/release/release.sh $(MOD) dist clean: - rm -rf $(BUILD_DIR) + rm -rf build dist coverage node_modules: package.json @$(NPM) install diff --git a/build.js b/build.js new file mode 100644 index 00000000..3d7b0cda --- /dev/null +++ b/build.js @@ -0,0 +1,62 @@ +const esbuild = require('esbuild'); +const fs = require('fs'); +const { dependencies } = require('./package.json'); + +// Get all production dependencies to be marked as external (not bundled) +const external = Object.keys(dependencies || {}); + +const sharedConfig = { + entryPoints: ['index.js'], + bundle: true, + minify: true, + sourcemap: true, + target: 'es2018', + legalComments: 'linked', + external: external.concat([ + '@dagrejs/graphlib' + ]), +}; + +async function build() { + // 1. CommonJS (CJS) - For Node.js `require()` + await esbuild.build({ + ...sharedConfig, + outfile: 'dist/dagre.cjs.js', + format: 'cjs', + platform: 'node', + }); + + // 2. ES Module (ESM) - For modern bundlers/native ES imports + await esbuild.build({ + ...sharedConfig, + outfile: 'dist/dagre.esm.js', + format: 'esm', + platform: 'neutral', + }); + + const iifeConfig = { + ...sharedConfig, + format: 'iife', + globalName: 'dagre', + platform: 'browser', + }; + + // 3. IIFE/UMD - For direct browser script tag + await esbuild.build({ + ...iifeConfig, + outfile: 'dist/dagre.min.js', + }); + + // 4. IIFE/UMD - For direct browser script tag, unminified + await esbuild.build({ + ...iifeConfig, + outfile: 'dist/dagre.js', + minify: false, + }); + + fs.copyFileSync('index.d.ts', 'dist/dagre.d.ts'); + + console.log('Build complete! 🚀'); +} + +build().catch(() => process.exit(1)); \ No newline at end of file diff --git a/dist/dagre.cjs.js b/dist/dagre.cjs.js new file mode 100644 index 00000000..cee90e92 --- /dev/null +++ b/dist/dagre.cjs.js @@ -0,0 +1,2 @@ +var ce=Object.defineProperty;var fe=(n,e,r)=>e in n?ce(n,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):n[e]=r;var c=(n,e)=>()=>(e||n((e={exports:{}}).exports,e),e.exports);var d=(n,e,r)=>fe(n,typeof e!="symbol"?e+"":e,r);var b=c((He,D)=>{"use strict";var le="\0",p="\0",C="",m=class{constructor(e){d(this,"_isDirected",!0);d(this,"_isMultigraph",!1);d(this,"_isCompound",!1);d(this,"_label");d(this,"_defaultNodeLabelFn",()=>{});d(this,"_defaultEdgeLabelFn",()=>{});d(this,"_nodes",{});d(this,"_in",{});d(this,"_preds",{});d(this,"_out",{});d(this,"_sucs",{});d(this,"_edgeObjs",{});d(this,"_edgeLabels",{});d(this,"_nodeCount",0);d(this,"_edgeCount",0);d(this,"_parent");d(this,"_children");e&&(this._isDirected=Object.hasOwn(e,"directed")?e.directed:!0,this._isMultigraph=Object.hasOwn(e,"multigraph")?e.multigraph:!1,this._isCompound=Object.hasOwn(e,"compound")?e.compound:!1),this._isCompound&&(this._parent={},this._children={},this._children[p]={})}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return this._defaultNodeLabelFn=e,typeof e!="function"&&(this._defaultNodeLabelFn=()=>e),this}nodeCount(){return this._nodeCount}nodes(){return Object.keys(this._nodes)}sources(){var e=this;return this.nodes().filter(r=>Object.keys(e._in[r]).length===0)}sinks(){var e=this;return this.nodes().filter(r=>Object.keys(e._out[r]).length===0)}setNodes(e,r){var t=arguments,s=this;return e.forEach(function(i){t.length>1?s.setNode(i,r):s.setNode(i)}),this}setNode(e,r){return Object.hasOwn(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=r),this):(this._nodes[e]=arguments.length>1?r:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=p,this._children[e]={},this._children[p][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.hasOwn(this._nodes,e)}removeNode(e){var r=this;if(Object.hasOwn(this._nodes,e)){var t=s=>r.removeEdge(r._edgeObjs[s]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],this.children(e).forEach(function(s){r.setParent(s)}),delete this._children[e]),Object.keys(this._in[e]).forEach(t),delete this._in[e],delete this._preds[e],Object.keys(this._out[e]).forEach(t),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,r){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(r===void 0)r=p;else{r+="";for(var t=r;t!==void 0;t=this.parent(t))if(t===e)throw new Error("Setting "+r+" as parent of "+e+" would create a cycle");this.setNode(r)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=r,this._children[r][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var r=this._parent[e];if(r!==p)return r}}children(e=p){if(this._isCompound){var r=this._children[e];if(r)return Object.keys(r)}else{if(e===p)return this.nodes();if(this.hasNode(e))return[]}}predecessors(e){var r=this._preds[e];if(r)return Object.keys(r)}successors(e){var r=this._sucs[e];if(r)return Object.keys(r)}neighbors(e){var r=this.predecessors(e);if(r){let s=new Set(r);for(var t of this.successors(e))s.add(t);return Array.from(s.values())}}isLeaf(e){var r;return this.isDirected()?r=this.successors(e):r=this.neighbors(e),r.length===0}filterNodes(e){var r=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});r.setGraph(this.graph());var t=this;Object.entries(this._nodes).forEach(function([a,o]){e(a)&&r.setNode(a,o)}),Object.values(this._edgeObjs).forEach(function(a){r.hasNode(a.v)&&r.hasNode(a.w)&&r.setEdge(a,t.edge(a))});var s={};function i(a){var o=t.parent(a);return o===void 0||r.hasNode(o)?(s[a]=o,o):o in s?s[o]:i(o)}return this._isCompound&&r.nodes().forEach(a=>r.setParent(a,i(a))),r}setDefaultEdgeLabel(e){return this._defaultEdgeLabelFn=e,typeof e!="function"&&(this._defaultEdgeLabelFn=()=>e),this}edgeCount(){return this._edgeCount}edges(){return Object.values(this._edgeObjs)}setPath(e,r){var t=this,s=arguments;return e.reduce(function(i,a){return s.length>1?t.setEdge(i,a,r):t.setEdge(i,a),a}),this}setEdge(){var e,r,t,s,i=!1,a=arguments[0];typeof a=="object"&&a!==null&&"v"in a?(e=a.v,r=a.w,t=a.name,arguments.length===2&&(s=arguments[1],i=!0)):(e=a,r=arguments[1],t=arguments[3],arguments.length>2&&(s=arguments[2],i=!0)),e=""+e,r=""+r,t!==void 0&&(t=""+t);var o=g(this._isDirected,e,r,t);if(Object.hasOwn(this._edgeLabels,o))return i&&(this._edgeLabels[o]=s),this;if(t!==void 0&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(r),this._edgeLabels[o]=i?s:this._defaultEdgeLabelFn(e,r,t);var u=_e(this._isDirected,e,r,t);return e=u.v,r=u.w,Object.freeze(u),this._edgeObjs[o]=u,q(this._preds[r],e),q(this._sucs[e],r),this._in[r][o]=u,this._out[e][o]=u,this._edgeCount++,this}edge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t);return this._edgeLabels[s]}edgeAsObj(){let e=this.edge(...arguments);return typeof e!="object"?{label:e}:e}hasEdge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t);return Object.hasOwn(this._edgeLabels,s)}removeEdge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t),i=this._edgeObjs[s];return i&&(e=i.v,r=i.w,delete this._edgeLabels[s],delete this._edgeObjs[s],x(this._preds[r],e),x(this._sucs[e],r),delete this._in[r][s],delete this._out[e][s],this._edgeCount--),this}inEdges(e,r){var t=this._in[e];if(t){var s=Object.values(t);return r?s.filter(i=>i.v===r):s}}outEdges(e,r){var t=this._out[e];if(t){var s=Object.values(t);return r?s.filter(i=>i.w===r):s}}nodeEdges(e,r){var t=this.inEdges(e,r);if(t)return t.concat(this.outEdges(e,r))}};function q(n,e){n[e]?n[e]++:n[e]=1}function x(n,e){--n[e]||delete n[e]}function g(n,e,r,t){var s=""+e,i=""+r;if(!n&&s>i){var a=s;s=i,i=a}return s+C+i+C+(t===void 0?le:t)}function _e(n,e,r,t){var s=""+e,i=""+r;if(!n&&s>i){var a=s;s=i,i=a}var o={v:s,w:i};return t&&(o.name=t),o}function w(n,e){return g(n,e.v,e.w,e.name)}D.exports=m});var F=c((Re,L)=>{L.exports="2.2.5-pre"});var T=c((Qe,A)=>{A.exports={Graph:b(),version:F()}});var P=c((Be,M)=>{var pe=b();M.exports={write:ve,read:be};function ve(n){var e={options:{directed:n.isDirected(),multigraph:n.isMultigraph(),compound:n.isCompound()},nodes:ge(n),edges:Ee(n)};return n.graph()!==void 0&&(e.value=structuredClone(n.graph())),e}function ge(n){return n.nodes().map(function(e){var r=n.node(e),t=n.parent(e),s={v:e};return r!==void 0&&(s.value=r),t!==void 0&&(s.parent=t),s})}function Ee(n){return n.edges().map(function(e){var r=n.edge(e),t={v:e.v,w:e.w};return e.name!==void 0&&(t.name=e.name),r!==void 0&&(t.value=r),t})}function be(n){var e=new pe(n.options).setGraph(n.value);return n.nodes.forEach(function(r){e.setNode(r.v,r.value),r.parent&&e.setParent(r.v,r.parent)}),n.edges.forEach(function(r){e.setEdge({v:r.v,w:r.w,name:r.name},r.value)}),e}});var S=c((Je,G)=>{G.exports=we;function we(n){var e={},r=[],t;function s(i){Object.hasOwn(e,i)||(e[i]=!0,t.push(i),n.successors(i).forEach(s),n.predecessors(i).forEach(s))}return n.nodes().forEach(function(i){t=[],s(i),t.length&&r.push(t)}),r}});var j=c((Xe,V)=>{var O=class{constructor(){d(this,"_arr",[]);d(this,"_keyIndices",{})}size(){return this._arr.length}keys(){return this._arr.map(function(e){return e.key})}has(e){return Object.hasOwn(this._keyIndices,e)}priority(e){var r=this._keyIndices[e];if(r!==void 0)return this._arr[r].priority}min(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key}add(e,r){var t=this._keyIndices;if(e=String(e),!Object.hasOwn(t,e)){var s=this._arr,i=s.length;return t[e]=i,s.push({key:e,priority:r}),this._decrease(i),!0}return!1}removeMin(){this._swap(0,this._arr.length-1);var e=this._arr.pop();return delete this._keyIndices[e.key],this._heapify(0),e.key}decrease(e,r){var t=this._keyIndices[e];if(r>this._arr[t].priority)throw new Error("New priority is greater than current priority. Key: "+e+" Old: "+this._arr[t].priority+" New: "+r);this._arr[t].priority=r,this._decrease(t)}_heapify(e){var r=this._arr,t=2*e,s=t+1,i=e;t>1,!(r[s].priority{var me=j();z.exports=je;var Oe=()=>1;function je(n,e,r,t){return ye(n,String(e),r||Oe,t||function(s){return n.outEdges(s)})}function ye(n,e,r,t){var s={},i=new me,a,o,u=function(h){var f=h.v!==a?h.v:h.w,l=s[f],_=r(h),v=o.distance+_;if(_<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+h+" Weight: "+_);v0&&(a=i.removeMin(),o=s[a],o.distance!==Number.POSITIVE_INFINITY);)t(a).forEach(u);return s}});var W=c((er,U)=>{var Ne=y();U.exports=ke;function ke(n,e,r){return n.nodes().reduce(function(t,s){return t[s]=Ne(n,s,e,r),t},{})}});var N=c((rr,Y)=>{Y.exports=Ie;function Ie(n){var e=0,r=[],t={},s=[];function i(a){var o=t[a]={onStack:!0,lowlink:e,index:e++};if(r.push(a),n.successors(a).forEach(function(f){Object.hasOwn(t,f)?t[f].onStack&&(o.lowlink=Math.min(o.lowlink,t[f].index)):(i(f),o.lowlink=Math.min(o.lowlink,t[f].lowlink))}),o.lowlink===o.index){var u=[],h;do h=r.pop(),t[h].onStack=!1,u.push(h);while(a!==h);s.push(u)}}return n.nodes().forEach(function(a){Object.hasOwn(t,a)||i(a)}),s}});var K=c((tr,H)=>{var Ce=N();H.exports=qe;function qe(n){return Ce(n).filter(function(e){return e.length>1||e.length===1&&n.hasEdge(e[0],e[0])})}});var Q=c((sr,R)=>{R.exports=De;var xe=()=>1;function De(n,e,r){return Le(n,e||xe,r||function(t){return n.outEdges(t)})}function Le(n,e,r){var t={},s=n.nodes();return s.forEach(function(i){t[i]={},t[i][i]={distance:0},s.forEach(function(a){i!==a&&(t[i][a]={distance:Number.POSITIVE_INFINITY})}),r(i).forEach(function(a){var o=a.v===i?a.w:a.v,u=e(a);t[i][o]={distance:u,predecessor:i}})}),s.forEach(function(i){var a=t[i];s.forEach(function(o){var u=t[o];s.forEach(function(h){var f=u[i],l=a[h],_=u[h],v=f.distance+l.distance;v<_.distance&&(_.distance=v,_.predecessor=l.predecessor)})})}),t}});var k=c((ir,J)=>{function B(n){var e={},r={},t=[];function s(i){if(Object.hasOwn(r,i))throw new E;Object.hasOwn(e,i)||(r[i]=!0,e[i]=!0,n.predecessors(i).forEach(s),delete r[i],t.push(i))}if(n.sinks().forEach(s),Object.keys(e).length!==n.nodeCount())throw new E;return t}var E=class extends Error{constructor(){super(...arguments)}};J.exports=B;B.CycleException=E});var $=c((nr,Z)=>{var X=k();Z.exports=Fe;function Fe(n){try{X(n)}catch(e){if(e instanceof X.CycleException)return!1;throw e}return!0}});var I=c((ar,re)=>{re.exports=Ae;function Ae(n,e,r){Array.isArray(e)||(e=[e]);var t=n.isDirected()?o=>n.successors(o):o=>n.neighbors(o),s=r==="post"?Te:Me,i=[],a={};return e.forEach(o=>{if(!n.hasNode(o))throw new Error("Graph does not have node: "+o);s(o,t,a,i)}),i}function Te(n,e,r,t){for(var s=[[n,!1]];s.length>0;){var i=s.pop();i[1]?t.push(i[0]):Object.hasOwn(r,i[0])||(r[i[0]]=!0,s.push([i[0],!0]),ee(e(i[0]),a=>s.push([a,!1])))}}function Me(n,e,r,t){for(var s=[n];s.length>0;){var i=s.pop();Object.hasOwn(r,i)||(r[i]=!0,t.push(i),ee(e(i),a=>s.push(a)))}}function ee(n,e){for(var r=n.length;r--;)e(n[r],r,n);return n}});var se=c((or,te)=>{var Pe=I();te.exports=Ge;function Ge(n,e){return Pe(n,e,"post")}});var ne=c((ur,ie)=>{var Se=I();ie.exports=Ve;function Ve(n,e){return Se(n,e,"pre")}});var oe=c((hr,ae)=>{var ze=b(),Ue=j();ae.exports=We;function We(n,e){var r=new ze,t={},s=new Ue,i;function a(u){var h=u.v===i?u.w:u.v,f=s.priority(h);if(f!==void 0){var l=e(u);l0;){if(i=s.removeMin(),Object.hasOwn(t,i))r.setEdge(i,t[i]);else{if(o)throw new Error("Input graph is not connected: "+n);o=!0}n.nodeEdges(i).forEach(a)}return r}});var he=c((dr,ue)=>{ue.exports={components:S(),dijkstra:y(),dijkstraAll:W(),findCycles:K(),floydWarshall:Q(),isAcyclic:$(),postorder:se(),preorder:ne(),prim:oe(),tarjan:N(),topsort:k()}});var de=T();module.exports={Graph:de.Graph,json:P(),alg:he(),version:de.version}; +//# sourceMappingURL=dagre.cjs.js.map diff --git a/dist/dagre.cjs.js.map b/dist/dagre.cjs.js.map new file mode 100644 index 00000000..4ec97e79 --- /dev/null +++ b/dist/dagre.cjs.js.map @@ -0,0 +1,7 @@ +{ + "version": 3, + "sources": ["../lib/graph.js", "../lib/version.js", "../lib/index.js", "../lib/json.js", "../lib/alg/components.js", "../lib/data/priority-queue.js", "../lib/alg/dijkstra.js", "../lib/alg/dijkstra-all.js", "../lib/alg/tarjan.js", "../lib/alg/find-cycles.js", "../lib/alg/floyd-warshall.js", "../lib/alg/topsort.js", "../lib/alg/is-acyclic.js", "../lib/alg/dfs.js", "../lib/alg/postorder.js", "../lib/alg/preorder.js", "../lib/alg/prim.js", "../lib/alg/index.js", "../index.js"], + "sourcesContent": ["\"use strict\";\n\nvar DEFAULT_EDGE_NAME = \"\\x00\";\nvar GRAPH_NODE = \"\\x00\";\nvar EDGE_KEY_DELIM = \"\\x01\";\n\n// Implementation notes:\n//\n// * Node id query functions should return string ids for the nodes\n// * Edge id query functions should return an \"edgeObj\", edge object, that is\n// composed of enough information to uniquely identify an edge: {v, w, name}.\n// * Internally we use an \"edgeId\", a stringified form of the edgeObj, to\n// reference edges. This is because we need a performant way to look these\n// edges up and, object properties, which have string keys, are the closest\n// we're going to get to a performant hashtable in JavaScript.\n\nclass Graph {\n _isDirected = true;\n _isMultigraph = false;\n _isCompound = false;\n\n // Label for the graph itself\n _label;\n\n // Defaults to be set when creating a new node\n _defaultNodeLabelFn = () => undefined;\n\n // Defaults to be set when creating a new edge\n _defaultEdgeLabelFn = () => undefined;\n\n // v -> label\n _nodes = {};\n\n // v -> edgeObj\n _in = {};\n\n // u -> v -> Number\n _preds = {};\n\n // v -> edgeObj\n _out = {};\n\n // v -> w -> Number\n _sucs = {};\n\n // e -> edgeObj\n _edgeObjs = {};\n\n // e -> label\n _edgeLabels = {};\n\n /* Number of nodes in the graph. Should only be changed by the implementation. */\n _nodeCount = 0;\n\n /* Number of edges in the graph. Should only be changed by the implementation. */\n _edgeCount = 0;\n\n _parent;\n\n _children;\n\n constructor(opts) {\n if (opts) {\n this._isDirected = Object.hasOwn(opts, \"directed\") ? opts.directed : true;\n this._isMultigraph = Object.hasOwn(opts, \"multigraph\") ? opts.multigraph : false;\n this._isCompound = Object.hasOwn(opts, \"compound\") ? opts.compound : false;\n }\n\n if (this._isCompound) {\n // v -> parent\n this._parent = {};\n\n // v -> children\n this._children = {};\n this._children[GRAPH_NODE] = {};\n }\n }\n\n /* === Graph functions ========= */\n\n /**\n * Whether graph was created with 'directed' flag set to true or not.\n */\n isDirected() {\n return this._isDirected;\n }\n\n /**\n * Whether graph was created with 'multigraph' flag set to true or not.\n */\n isMultigraph() {\n return this._isMultigraph;\n }\n\n /**\n * Whether graph was created with 'compound' flag set to true or not.\n */\n isCompound() {\n return this._isCompound;\n }\n\n /**\n * Sets the label of the graph.\n */\n setGraph(label) {\n this._label = label;\n return this;\n }\n\n /**\n * Gets the graph label.\n */\n graph() {\n return this._label;\n }\n\n\n /* === Node functions ========== */\n\n /**\n * Sets the default node label. If newDefault is a function, it will be\n * invoked ach time when setting a label for a node. Otherwise, this label\n * will be assigned as default label in case if no label was specified while\n * setting a node.\n * Complexity: O(1).\n */\n setDefaultNodeLabel(newDefault) {\n this._defaultNodeLabelFn = newDefault;\n if (typeof newDefault !== 'function') {\n this._defaultNodeLabelFn = () => newDefault;\n }\n\n return this;\n }\n\n /**\n * Gets the number of nodes in the graph.\n * Complexity: O(1).\n */\n nodeCount() {\n return this._nodeCount;\n }\n\n /**\n * Gets all nodes of the graph. Note, the in case of compound graph subnodes are\n * not included in list.\n * Complexity: O(1).\n */\n nodes() {\n return Object.keys(this._nodes);\n }\n\n /**\n * Gets list of nodes without in-edges.\n * Complexity: O(|V|).\n */\n sources() {\n var self = this;\n return this.nodes().filter(v => Object.keys(self._in[v]).length === 0);\n }\n\n /**\n * Gets list of nodes without out-edges.\n * Complexity: O(|V|).\n */\n sinks() {\n var self = this;\n return this.nodes().filter(v => Object.keys(self._out[v]).length === 0);\n }\n\n /**\n * Invokes setNode method for each node in names list.\n * Complexity: O(|names|).\n */\n setNodes(vs, value) {\n var args = arguments;\n var self = this;\n vs.forEach(function(v) {\n if (args.length > 1) {\n self.setNode(v, value);\n } else {\n self.setNode(v);\n }\n });\n return this;\n }\n\n /**\n * Creates or updates the value for the node v in the graph. If label is supplied\n * it is set as the value for the node. If label is not supplied and the node was\n * created by this call then the default node label will be assigned.\n * Complexity: O(1).\n */\n setNode(v, value) {\n if (Object.hasOwn(this._nodes, v)) {\n if (arguments.length > 1) {\n this._nodes[v] = value;\n }\n return this;\n }\n\n this._nodes[v] = arguments.length > 1 ? value : this._defaultNodeLabelFn(v);\n if (this._isCompound) {\n this._parent[v] = GRAPH_NODE;\n this._children[v] = {};\n this._children[GRAPH_NODE][v] = true;\n }\n this._in[v] = {};\n this._preds[v] = {};\n this._out[v] = {};\n this._sucs[v] = {};\n ++this._nodeCount;\n return this;\n }\n\n /**\n * Gets the label of node with specified name.\n * Complexity: O(|V|).\n */\n node(v) {\n return this._nodes[v];\n }\n\n /**\n * Detects whether graph has a node with specified name or not.\n */\n hasNode(v) {\n return Object.hasOwn(this._nodes, v);\n }\n\n /**\n * Remove the node with the name from the graph or do nothing if the node is not in\n * the graph. If the node was removed this function also removes any incident\n * edges.\n * Complexity: O(1).\n */\n removeNode(v) {\n var self = this;\n if (Object.hasOwn(this._nodes, v)) {\n var removeEdge = e => self.removeEdge(self._edgeObjs[e]);\n delete this._nodes[v];\n if (this._isCompound) {\n this._removeFromParentsChildList(v);\n delete this._parent[v];\n this.children(v).forEach(function(child) {\n self.setParent(child);\n });\n delete this._children[v];\n }\n Object.keys(this._in[v]).forEach(removeEdge);\n delete this._in[v];\n delete this._preds[v];\n Object.keys(this._out[v]).forEach(removeEdge);\n delete this._out[v];\n delete this._sucs[v];\n --this._nodeCount;\n }\n return this;\n }\n\n /**\n * Sets node p as a parent for node v if it is defined, or removes the\n * parent for v if p is undefined. Method throws an exception in case of\n * invoking it in context of noncompound graph.\n * Average-case complexity: O(1).\n */\n setParent(v, parent) {\n if (!this._isCompound) {\n throw new Error(\"Cannot set parent in a non-compound graph\");\n }\n\n if (parent === undefined) {\n parent = GRAPH_NODE;\n } else {\n // Coerce parent to string\n parent += \"\";\n for (var ancestor = parent; ancestor !== undefined; ancestor = this.parent(ancestor)) {\n if (ancestor === v) {\n throw new Error(\"Setting \" + parent+ \" as parent of \" + v +\n \" would create a cycle\");\n }\n }\n\n this.setNode(parent);\n }\n\n this.setNode(v);\n this._removeFromParentsChildList(v);\n this._parent[v] = parent;\n this._children[parent][v] = true;\n return this;\n }\n\n _removeFromParentsChildList(v) {\n delete this._children[this._parent[v]][v];\n }\n\n /**\n * Gets parent node for node v.\n * Complexity: O(1).\n */\n parent(v) {\n if (this._isCompound) {\n var parent = this._parent[v];\n if (parent !== GRAPH_NODE) {\n return parent;\n }\n }\n }\n\n /**\n * Gets list of direct children of node v.\n * Complexity: O(1).\n */\n children(v = GRAPH_NODE) {\n if (this._isCompound) {\n var children = this._children[v];\n if (children) {\n return Object.keys(children);\n }\n } else if (v === GRAPH_NODE) {\n return this.nodes();\n } else if (this.hasNode(v)) {\n return [];\n }\n }\n\n /**\n * Return all nodes that are predecessors of the specified node or undefined if node v is not in\n * the graph. Behavior is undefined for undirected graphs - use neighbors instead.\n * Complexity: O(|V|).\n */\n predecessors(v) {\n var predsV = this._preds[v];\n if (predsV) {\n return Object.keys(predsV);\n }\n }\n\n /**\n * Return all nodes that are successors of the specified node or undefined if node v is not in\n * the graph. Behavior is undefined for undirected graphs - use neighbors instead.\n * Complexity: O(|V|).\n */\n successors(v) {\n var sucsV = this._sucs[v];\n if (sucsV) {\n return Object.keys(sucsV);\n }\n }\n\n /**\n * Return all nodes that are predecessors or successors of the specified node or undefined if\n * node v is not in the graph.\n * Complexity: O(|V|).\n */\n neighbors(v) {\n var preds = this.predecessors(v);\n if (preds) {\n const union = new Set(preds);\n for (var succ of this.successors(v)) {\n union.add(succ);\n }\n\n return Array.from(union.values());\n }\n }\n\n isLeaf(v) {\n var neighbors;\n if (this.isDirected()) {\n neighbors = this.successors(v);\n } else {\n neighbors = this.neighbors(v);\n }\n return neighbors.length === 0;\n }\n\n /**\n * Creates new graph with nodes filtered via filter. Edges incident to rejected node\n * are also removed. In case of compound graph, if parent is rejected by filter,\n * than all its children are rejected too.\n * Average-case complexity: O(|E|+|V|).\n */\n filterNodes(filter) {\n var copy = new this.constructor({\n directed: this._isDirected,\n multigraph: this._isMultigraph,\n compound: this._isCompound\n });\n\n copy.setGraph(this.graph());\n\n var self = this;\n Object.entries(this._nodes).forEach(function([v, value]) {\n if (filter(v)) {\n copy.setNode(v, value);\n }\n });\n\n Object.values(this._edgeObjs).forEach(function(e) {\n if (copy.hasNode(e.v) && copy.hasNode(e.w)) {\n copy.setEdge(e, self.edge(e));\n }\n });\n\n var parents = {};\n function findParent(v) {\n var parent = self.parent(v);\n if (parent === undefined || copy.hasNode(parent)) {\n parents[v] = parent;\n return parent;\n } else if (parent in parents) {\n return parents[parent];\n } else {\n return findParent(parent);\n }\n }\n\n if (this._isCompound) {\n copy.nodes().forEach(v => copy.setParent(v, findParent(v)));\n }\n\n return copy;\n }\n\n /* === Edge functions ========== */\n\n /**\n * Sets the default edge label or factory function. This label will be\n * assigned as default label in case if no label was specified while setting\n * an edge or this function will be invoked each time when setting an edge\n * with no label specified and returned value * will be used as a label for edge.\n * Complexity: O(1).\n */\n setDefaultEdgeLabel(newDefault) {\n this._defaultEdgeLabelFn = newDefault;\n if (typeof newDefault !== 'function') {\n this._defaultEdgeLabelFn = () => newDefault;\n }\n\n return this;\n }\n\n /**\n * Gets the number of edges in the graph.\n * Complexity: O(1).\n */\n edgeCount() {\n return this._edgeCount;\n }\n\n /**\n * Gets edges of the graph. In case of compound graph subgraphs are not considered.\n * Complexity: O(|E|).\n */\n edges() {\n return Object.values(this._edgeObjs);\n }\n\n /**\n * Establish an edges path over the nodes in nodes list. If some edge is already\n * exists, it will update its label, otherwise it will create an edge between pair\n * of nodes with label provided or default label if no label provided.\n * Complexity: O(|nodes|).\n */\n setPath(vs, value) {\n var self = this;\n var args = arguments;\n vs.reduce(function(v, w) {\n if (args.length > 1) {\n self.setEdge(v, w, value);\n } else {\n self.setEdge(v, w);\n }\n return w;\n });\n return this;\n }\n\n /**\n * Creates or updates the label for the edge (v, w) with the optionally supplied\n * name. If label is supplied it is set as the value for the edge. If label is not\n * supplied and the edge was created by this call then the default edge label will\n * be assigned. The name parameter is only useful with multigraphs.\n */\n setEdge() {\n var v, w, name, value;\n var valueSpecified = false;\n var arg0 = arguments[0];\n\n if (typeof arg0 === \"object\" && arg0 !== null && \"v\" in arg0) {\n v = arg0.v;\n w = arg0.w;\n name = arg0.name;\n if (arguments.length === 2) {\n value = arguments[1];\n valueSpecified = true;\n }\n } else {\n v = arg0;\n w = arguments[1];\n name = arguments[3];\n if (arguments.length > 2) {\n value = arguments[2];\n valueSpecified = true;\n }\n }\n\n v = \"\" + v;\n w = \"\" + w;\n if (name !== undefined) {\n name = \"\" + name;\n }\n\n var e = edgeArgsToId(this._isDirected, v, w, name);\n if (Object.hasOwn(this._edgeLabels, e)) {\n if (valueSpecified) {\n this._edgeLabels[e] = value;\n }\n return this;\n }\n\n if (name !== undefined && !this._isMultigraph) {\n throw new Error(\"Cannot set a named edge when isMultigraph = false\");\n }\n\n // It didn't exist, so we need to create it.\n // First ensure the nodes exist.\n this.setNode(v);\n this.setNode(w);\n\n this._edgeLabels[e] = valueSpecified ? value : this._defaultEdgeLabelFn(v, w, name);\n\n var edgeObj = edgeArgsToObj(this._isDirected, v, w, name);\n // Ensure we add undirected edges in a consistent way.\n v = edgeObj.v;\n w = edgeObj.w;\n\n Object.freeze(edgeObj);\n this._edgeObjs[e] = edgeObj;\n incrementOrInitEntry(this._preds[w], v);\n incrementOrInitEntry(this._sucs[v], w);\n this._in[w][e] = edgeObj;\n this._out[v][e] = edgeObj;\n this._edgeCount++;\n return this;\n }\n\n /**\n * Gets the label for the specified edge.\n * Complexity: O(1).\n */\n edge(v, w, name) {\n var e = (arguments.length === 1\n ? edgeObjToId(this._isDirected, arguments[0])\n : edgeArgsToId(this._isDirected, v, w, name));\n return this._edgeLabels[e];\n }\n\n /**\n * Gets the label for the specified edge and converts it to an object.\n * Complexity: O(1)\n */\n edgeAsObj() {\n const edge = this.edge(...arguments);\n if (typeof edge !== \"object\") {\n return {label: edge};\n }\n\n return edge;\n }\n\n /**\n * Detects whether the graph contains specified edge or not. No subgraphs are considered.\n * Complexity: O(1).\n */\n hasEdge(v, w, name) {\n var e = (arguments.length === 1\n ? edgeObjToId(this._isDirected, arguments[0])\n : edgeArgsToId(this._isDirected, v, w, name));\n return Object.hasOwn(this._edgeLabels, e);\n }\n\n /**\n * Removes the specified edge from the graph. No subgraphs are considered.\n * Complexity: O(1).\n */\n removeEdge(v, w, name) {\n var e = (arguments.length === 1\n ? edgeObjToId(this._isDirected, arguments[0])\n : edgeArgsToId(this._isDirected, v, w, name));\n var edge = this._edgeObjs[e];\n if (edge) {\n v = edge.v;\n w = edge.w;\n delete this._edgeLabels[e];\n delete this._edgeObjs[e];\n decrementOrRemoveEntry(this._preds[w], v);\n decrementOrRemoveEntry(this._sucs[v], w);\n delete this._in[w][e];\n delete this._out[v][e];\n this._edgeCount--;\n }\n return this;\n }\n\n /**\n * Return all edges that point to the node v. Optionally filters those edges down to just those\n * coming from node u. Behavior is undefined for undirected graphs - use nodeEdges instead.\n * Complexity: O(|E|).\n */\n inEdges(v, u) {\n var inV = this._in[v];\n if (inV) {\n var edges = Object.values(inV);\n if (!u) {\n return edges;\n }\n return edges.filter(edge => edge.v === u);\n }\n }\n\n /**\n * Return all edges that are pointed at by node v. Optionally filters those edges down to just\n * those point to w. Behavior is undefined for undirected graphs - use nodeEdges instead.\n * Complexity: O(|E|).\n */\n outEdges(v, w) {\n var outV = this._out[v];\n if (outV) {\n var edges = Object.values(outV);\n if (!w) {\n return edges;\n }\n return edges.filter(edge => edge.w === w);\n }\n }\n\n /**\n * Returns all edges to or from node v regardless of direction. Optionally filters those edges\n * down to just those between nodes v and w regardless of direction.\n * Complexity: O(|E|).\n */\n nodeEdges(v, w) {\n var inEdges = this.inEdges(v, w);\n if (inEdges) {\n return inEdges.concat(this.outEdges(v, w));\n }\n }\n}\n\nfunction incrementOrInitEntry(map, k) {\n if (map[k]) {\n map[k]++;\n } else {\n map[k] = 1;\n }\n}\n\nfunction decrementOrRemoveEntry(map, k) {\n if (!--map[k]) { delete map[k]; }\n}\n\nfunction edgeArgsToId(isDirected, v_, w_, name) {\n var v = \"\" + v_;\n var w = \"\" + w_;\n if (!isDirected && v > w) {\n var tmp = v;\n v = w;\n w = tmp;\n }\n return v + EDGE_KEY_DELIM + w + EDGE_KEY_DELIM +\n (name === undefined ? DEFAULT_EDGE_NAME : name);\n}\n\nfunction edgeArgsToObj(isDirected, v_, w_, name) {\n var v = \"\" + v_;\n var w = \"\" + w_;\n if (!isDirected && v > w) {\n var tmp = v;\n v = w;\n w = tmp;\n }\n var edgeObj = { v: v, w: w };\n if (name) {\n edgeObj.name = name;\n }\n return edgeObj;\n}\n\nfunction edgeObjToId(isDirected, edgeObj) {\n return edgeArgsToId(isDirected, edgeObj.v, edgeObj.w, edgeObj.name);\n}\n\nmodule.exports = Graph;\n", "module.exports = '2.2.5-pre';\n", "// Includes only the \"core\" of graphlib\nmodule.exports = {\n Graph: require(\"./graph\"),\n version: require(\"./version\")\n};\n", "var Graph = require(\"./graph\");\n\nmodule.exports = {\n write: write,\n read: read\n};\n\n/**\n * Creates a JSON representation of the graph that can be serialized to a string with\n * JSON.stringify. The graph can later be restored using json.read.\n */\nfunction write(g) {\n var json = {\n options: {\n directed: g.isDirected(),\n multigraph: g.isMultigraph(),\n compound: g.isCompound()\n },\n nodes: writeNodes(g),\n edges: writeEdges(g)\n };\n\n if (g.graph() !== undefined) {\n json.value = structuredClone(g.graph());\n }\n return json;\n}\n\nfunction writeNodes(g) {\n return g.nodes().map(function(v) {\n var nodeValue = g.node(v);\n var parent = g.parent(v);\n var node = { v: v };\n if (nodeValue !== undefined) {\n node.value = nodeValue;\n }\n if (parent !== undefined) {\n node.parent = parent;\n }\n return node;\n });\n}\n\nfunction writeEdges(g) {\n return g.edges().map(function(e) {\n var edgeValue = g.edge(e);\n var edge = { v: e.v, w: e.w };\n if (e.name !== undefined) {\n edge.name = e.name;\n }\n if (edgeValue !== undefined) {\n edge.value = edgeValue;\n }\n return edge;\n });\n}\n\n/**\n * Takes JSON as input and returns the graph representation.\n *\n * @example\n * var g2 = graphlib.json.read(JSON.parse(str));\n * g2.nodes();\n * // ['a', 'b']\n * g2.edges()\n * // [ { v: 'a', w: 'b' } ]\n */\nfunction read(json) {\n var g = new Graph(json.options).setGraph(json.value);\n json.nodes.forEach(function(entry) {\n g.setNode(entry.v, entry.value);\n if (entry.parent) {\n g.setParent(entry.v, entry.parent);\n }\n });\n json.edges.forEach(function(entry) {\n g.setEdge({ v: entry.v, w: entry.w, name: entry.name }, entry.value);\n });\n return g;\n}\n", "module.exports = components;\n\nfunction components(g) {\n var visited = {};\n var cmpts = [];\n var cmpt;\n\n function dfs(v) {\n if (Object.hasOwn(visited, v)) return;\n visited[v] = true;\n cmpt.push(v);\n g.successors(v).forEach(dfs);\n g.predecessors(v).forEach(dfs);\n }\n\n g.nodes().forEach(function(v) {\n cmpt = [];\n dfs(v);\n if (cmpt.length) {\n cmpts.push(cmpt);\n }\n });\n\n return cmpts;\n}\n", "/**\n * A min-priority queue data structure. This algorithm is derived from Cormen,\n * et al., \"Introduction to Algorithms\". The basic idea of a min-priority\n * queue is that you can efficiently (in O(1) time) get the smallest key in\n * the queue. Adding and removing elements takes O(log n) time. A key can\n * have its priority decreased in O(log n) time.\n */\nclass PriorityQueue {\n _arr = [];\n _keyIndices = {};\n\n /**\n * Returns the number of elements in the queue. Takes `O(1)` time.\n */\n size() {\n return this._arr.length;\n }\n\n /**\n * Returns the keys that are in the queue. Takes `O(n)` time.\n */\n keys() {\n return this._arr.map(function(x) { return x.key; });\n }\n\n /**\n * Returns `true` if **key** is in the queue and `false` if not.\n */\n has(key) {\n return Object.hasOwn(this._keyIndices, key);\n }\n\n /**\n * Returns the priority for **key**. If **key** is not present in the queue\n * then this function returns `undefined`. Takes `O(1)` time.\n *\n * @param {Object} key\n */\n priority(key) {\n var index = this._keyIndices[key];\n if (index !== undefined) {\n return this._arr[index].priority;\n }\n }\n\n /**\n * Returns the key for the minimum element in this queue. If the queue is\n * empty this function throws an Error. Takes `O(1)` time.\n */\n min() {\n if (this.size() === 0) {\n throw new Error(\"Queue underflow\");\n }\n return this._arr[0].key;\n }\n\n /**\n * Inserts a new key into the priority queue. If the key already exists in\n * the queue this function returns `false`; otherwise it will return `true`.\n * Takes `O(n)` time.\n *\n * @param {Object} key the key to add\n * @param {Number} priority the initial priority for the key\n */\n add(key, priority) {\n var keyIndices = this._keyIndices;\n key = String(key);\n if (!Object.hasOwn(keyIndices, key)) {\n var arr = this._arr;\n var index = arr.length;\n keyIndices[key] = index;\n arr.push({key: key, priority: priority});\n this._decrease(index);\n return true;\n }\n return false;\n }\n\n /**\n * Removes and returns the smallest key in the queue. Takes `O(log n)` time.\n */\n removeMin() {\n this._swap(0, this._arr.length - 1);\n var min = this._arr.pop();\n delete this._keyIndices[min.key];\n this._heapify(0);\n return min.key;\n }\n\n /**\n * Decreases the priority for **key** to **priority**. If the new priority is\n * greater than the previous priority, this function will throw an Error.\n *\n * @param {Object} key the key for which to raise priority\n * @param {Number} priority the new priority for the key\n */\n decrease(key, priority) {\n var index = this._keyIndices[key];\n if (priority > this._arr[index].priority) {\n throw new Error(\"New priority is greater than current priority. \" +\n \"Key: \" + key + \" Old: \" + this._arr[index].priority + \" New: \" + priority);\n }\n this._arr[index].priority = priority;\n this._decrease(index);\n }\n\n _heapify(i) {\n var arr = this._arr;\n var l = 2 * i;\n var r = l + 1;\n var largest = i;\n if (l < arr.length) {\n largest = arr[l].priority < arr[largest].priority ? l : largest;\n if (r < arr.length) {\n largest = arr[r].priority < arr[largest].priority ? r : largest;\n }\n if (largest !== i) {\n this._swap(i, largest);\n this._heapify(largest);\n }\n }\n }\n\n _decrease(index) {\n var arr = this._arr;\n var priority = arr[index].priority;\n var parent;\n while (index !== 0) {\n parent = index >> 1;\n if (arr[parent].priority < priority) {\n break;\n }\n this._swap(index, parent);\n index = parent;\n }\n }\n\n _swap(i, j) {\n var arr = this._arr;\n var keyIndices = this._keyIndices;\n var origArrI = arr[i];\n var origArrJ = arr[j];\n arr[i] = origArrJ;\n arr[j] = origArrI;\n keyIndices[origArrJ.key] = i;\n keyIndices[origArrI.key] = j;\n }\n}\n\nmodule.exports = PriorityQueue;\n", "var PriorityQueue = require(\"../data/priority-queue\");\n\nmodule.exports = dijkstra;\n\nvar DEFAULT_WEIGHT_FUNC = () => 1;\n\nfunction dijkstra(g, source, weightFn, edgeFn) {\n return runDijkstra(g, String(source),\n weightFn || DEFAULT_WEIGHT_FUNC,\n edgeFn || function(v) { return g.outEdges(v); });\n}\n\nfunction runDijkstra(g, source, weightFn, edgeFn) {\n var results = {};\n var pq = new PriorityQueue();\n var v, vEntry;\n\n var updateNeighbors = function(edge) {\n var w = edge.v !== v ? edge.v : edge.w;\n var wEntry = results[w];\n var weight = weightFn(edge);\n var distance = vEntry.distance + weight;\n\n if (weight < 0) {\n throw new Error(\"dijkstra does not allow negative edge weights. \" +\n \"Bad edge: \" + edge + \" Weight: \" + weight);\n }\n\n if (distance < wEntry.distance) {\n wEntry.distance = distance;\n wEntry.predecessor = v;\n pq.decrease(w, distance);\n }\n };\n\n g.nodes().forEach(function(v) {\n var distance = v === source ? 0 : Number.POSITIVE_INFINITY;\n results[v] = { distance: distance };\n pq.add(v, distance);\n });\n\n while (pq.size() > 0) {\n v = pq.removeMin();\n vEntry = results[v];\n if (vEntry.distance === Number.POSITIVE_INFINITY) {\n break;\n }\n\n edgeFn(v).forEach(updateNeighbors);\n }\n\n return results;\n}\n", "var dijkstra = require(\"./dijkstra\");\n\nmodule.exports = dijkstraAll;\n\nfunction dijkstraAll(g, weightFunc, edgeFunc) {\n return g.nodes().reduce(function(acc, v) {\n acc[v] = dijkstra(g, v, weightFunc, edgeFunc);\n return acc;\n }, {});\n}\n", "module.exports = tarjan;\n\nfunction tarjan(g) {\n var index = 0;\n var stack = [];\n var visited = {}; // node id -> { onStack, lowlink, index }\n var results = [];\n\n function dfs(v) {\n var entry = visited[v] = {\n onStack: true,\n lowlink: index,\n index: index++\n };\n stack.push(v);\n\n g.successors(v).forEach(function(w) {\n if (!Object.hasOwn(visited, w)) {\n dfs(w);\n entry.lowlink = Math.min(entry.lowlink, visited[w].lowlink);\n } else if (visited[w].onStack) {\n entry.lowlink = Math.min(entry.lowlink, visited[w].index);\n }\n });\n\n if (entry.lowlink === entry.index) {\n var cmpt = [];\n var w;\n do {\n w = stack.pop();\n visited[w].onStack = false;\n cmpt.push(w);\n } while (v !== w);\n results.push(cmpt);\n }\n }\n\n g.nodes().forEach(function(v) {\n if (!Object.hasOwn(visited, v)) {\n dfs(v);\n }\n });\n\n return results;\n}\n", "var tarjan = require(\"./tarjan\");\n\nmodule.exports = findCycles;\n\nfunction findCycles(g) {\n return tarjan(g).filter(function(cmpt) {\n return cmpt.length > 1 || (cmpt.length === 1 && g.hasEdge(cmpt[0], cmpt[0]));\n });\n}\n", "module.exports = floydWarshall;\n\nvar DEFAULT_WEIGHT_FUNC = () => 1;\n\nfunction floydWarshall(g, weightFn, edgeFn) {\n return runFloydWarshall(g,\n weightFn || DEFAULT_WEIGHT_FUNC,\n edgeFn || function(v) { return g.outEdges(v); });\n}\n\nfunction runFloydWarshall(g, weightFn, edgeFn) {\n var results = {};\n var nodes = g.nodes();\n\n nodes.forEach(function(v) {\n results[v] = {};\n results[v][v] = { distance: 0 };\n nodes.forEach(function(w) {\n if (v !== w) {\n results[v][w] = { distance: Number.POSITIVE_INFINITY };\n }\n });\n edgeFn(v).forEach(function(edge) {\n var w = edge.v === v ? edge.w : edge.v;\n var d = weightFn(edge);\n results[v][w] = { distance: d, predecessor: v };\n });\n });\n\n nodes.forEach(function(k) {\n var rowK = results[k];\n nodes.forEach(function(i) {\n var rowI = results[i];\n nodes.forEach(function(j) {\n var ik = rowI[k];\n var kj = rowK[j];\n var ij = rowI[j];\n var altDistance = ik.distance + kj.distance;\n if (altDistance < ij.distance) {\n ij.distance = altDistance;\n ij.predecessor = kj.predecessor;\n }\n });\n });\n });\n\n return results;\n}\n", "function topsort(g) {\n var visited = {};\n var stack = {};\n var results = [];\n\n function visit(node) {\n if (Object.hasOwn(stack, node)) {\n throw new CycleException();\n }\n\n if (!Object.hasOwn(visited, node)) {\n stack[node] = true;\n visited[node] = true;\n g.predecessors(node).forEach(visit);\n delete stack[node];\n results.push(node);\n }\n }\n\n g.sinks().forEach(visit);\n\n if (Object.keys(visited).length !== g.nodeCount()) {\n throw new CycleException();\n }\n\n return results;\n}\n\nclass CycleException extends Error {\n constructor() {\n super(...arguments);\n }\n}\n\nmodule.exports = topsort;\ntopsort.CycleException = CycleException;\n", "var topsort = require(\"./topsort\");\n\nmodule.exports = isAcyclic;\n\nfunction isAcyclic(g) {\n try {\n topsort(g);\n } catch (e) {\n if (e instanceof topsort.CycleException) {\n return false;\n }\n throw e;\n }\n return true;\n}\n", "module.exports = dfs;\n\n/*\n * A helper that preforms a pre- or post-order traversal on the input graph\n * and returns the nodes in the order they were visited. If the graph is\n * undirected then this algorithm will navigate using neighbors. If the graph\n * is directed then this algorithm will navigate using successors.\n *\n * If the order is not \"post\", it will be treated as \"pre\".\n */\nfunction dfs(g, vs, order) {\n if (!Array.isArray(vs)) {\n vs = [vs];\n }\n\n var navigation = g.isDirected() ? v => g.successors(v) : v => g.neighbors(v);\n var orderFunc = order === \"post\" ? postOrderDfs : preOrderDfs;\n\n var acc = [];\n var visited = {};\n vs.forEach(v => {\n if (!g.hasNode(v)) {\n throw new Error(\"Graph does not have node: \" + v);\n }\n\n orderFunc(v, navigation, visited, acc);\n });\n\n return acc;\n}\n\nfunction postOrderDfs(v, navigation, visited, acc) {\n var stack = [[v, false]];\n while (stack.length > 0) {\n var curr = stack.pop();\n if (curr[1]) {\n acc.push(curr[0]);\n } else {\n if (!Object.hasOwn(visited, curr[0])) {\n visited[curr[0]] = true;\n stack.push([curr[0], true]);\n forEachRight(navigation(curr[0]), w => stack.push([w, false]));\n }\n }\n }\n}\n\nfunction preOrderDfs(v, navigation, visited, acc) {\n var stack = [v];\n while (stack.length > 0) {\n var curr = stack.pop();\n if (!Object.hasOwn(visited, curr)) {\n visited[curr] = true;\n acc.push(curr);\n forEachRight(navigation(curr), w => stack.push(w));\n }\n }\n}\n\nfunction forEachRight(array, iteratee) {\n var length = array.length;\n while (length--) {\n iteratee(array[length], length, array);\n }\n\n return array;\n}\n", "var dfs = require(\"./dfs\");\n\nmodule.exports = postorder;\n\nfunction postorder(g, vs) {\n return dfs(g, vs, \"post\");\n}\n", "var dfs = require(\"./dfs\");\n\nmodule.exports = preorder;\n\nfunction preorder(g, vs) {\n return dfs(g, vs, \"pre\");\n}\n", "var Graph = require(\"../graph\");\nvar PriorityQueue = require(\"../data/priority-queue\");\n\nmodule.exports = prim;\n\nfunction prim(g, weightFunc) {\n var result = new Graph();\n var parents = {};\n var pq = new PriorityQueue();\n var v;\n\n function updateNeighbors(edge) {\n var w = edge.v === v ? edge.w : edge.v;\n var pri = pq.priority(w);\n if (pri !== undefined) {\n var edgeWeight = weightFunc(edge);\n if (edgeWeight < pri) {\n parents[w] = v;\n pq.decrease(w, edgeWeight);\n }\n }\n }\n\n if (g.nodeCount() === 0) {\n return result;\n }\n\n g.nodes().forEach(function(v) {\n pq.add(v, Number.POSITIVE_INFINITY);\n result.setNode(v);\n });\n\n // Start from an arbitrary node\n pq.decrease(g.nodes()[0], 0);\n\n var init = false;\n while (pq.size() > 0) {\n v = pq.removeMin();\n if (Object.hasOwn(parents, v)) {\n result.setEdge(v, parents[v]);\n } else if (init) {\n throw new Error(\"Input graph is not connected: \" + g);\n } else {\n init = true;\n }\n\n g.nodeEdges(v).forEach(updateNeighbors);\n }\n\n return result;\n}\n", "module.exports = {\n components: require(\"./components\"),\n dijkstra: require(\"./dijkstra\"),\n dijkstraAll: require(\"./dijkstra-all\"),\n findCycles: require(\"./find-cycles\"),\n floydWarshall: require(\"./floyd-warshall\"),\n isAcyclic: require(\"./is-acyclic\"),\n postorder: require(\"./postorder\"),\n preorder: require(\"./preorder\"),\n prim: require(\"./prim\"),\n tarjan: require(\"./tarjan\"),\n topsort: require(\"./topsort\")\n};\n", "/**\n * Copyright (c) 2014, Chris Pettitt\n * All rights reserved.\n *\n * Redistribution and use in source and binary forms, with or without\n * modification, are permitted provided that the following conditions are met:\n *\n * 1. Redistributions of source code must retain the above copyright notice, this\n * list of conditions and the following disclaimer.\n *\n * 2. Redistributions in binary form must reproduce the above copyright notice,\n * this list of conditions and the following disclaimer in the documentation\n * and/or other materials provided with the distribution.\n *\n * 3. Neither the name of the copyright holder nor the names of its contributors\n * may be used to endorse or promote products derived from this software without\n * specific prior written permission.\n *\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND\n * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED\n * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\n * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE\n * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL\n * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR\n * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER\n * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,\n * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\n * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n */\n\nvar lib = require(\"./lib\");\n\nmodule.exports = {\n Graph: lib.Graph,\n json: require(\"./lib/json\"),\n alg: require(\"./lib/alg\"),\n version: lib.version\n};\n"], + "m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AAC,EAC1BH,EAAO,QAAQG,EAAGF,EAAQE,CAAC,CAAC,MACvB,IAAIM,EACT,MAAM,IAAI,MAAM,iCAAmCX,CAAC,EAEpDW,EAAO,GAGTX,EAAE,UAAUK,CAAC,EAAE,QAAQC,CAAe,CACxC,CAEA,OAAOJ,CACT,IClDA,IAAAU,GAAAC,EAAA,CAAAC,GAAAC,KAAA,CAAAA,GAAO,QAAU,CACf,WAAY,IACZ,SAAU,IACV,YAAa,IACb,WAAY,IACZ,cAAe,IACf,UAAW,IACX,UAAW,KACX,SAAU,KACV,KAAM,KACN,OAAQ,IACR,QAAS,GACX,ICkBA,IAAIC,GAAM,IAEV,OAAO,QAAU,CACf,MAAOA,GAAI,MACX,KAAM,IACN,IAAK,KACL,QAASA,GAAI,OACf", + "names": ["require_graph", "__commonJSMin", "exports", "module", "DEFAULT_EDGE_NAME", "GRAPH_NODE", "EDGE_KEY_DELIM", "Graph", "opts", "__publicField", "label", "newDefault", "self", "v", "vs", "value", "args", "removeEdge", "e", "child", "parent", "ancestor", "children", "predsV", "sucsV", "preds", "union", "succ", "neighbors", "filter", "copy", "parents", "findParent", "w", "name", "valueSpecified", "arg0", "edgeArgsToId", "edgeObj", "edgeArgsToObj", "incrementOrInitEntry", "edgeObjToId", "edge", "decrementOrRemoveEntry", "u", "inV", "edges", "outV", "inEdges", "map", "k", "isDirected", "v_", "w_", "tmp", "require_version", "__commonJSMin", "exports", "module", "require_lib", "__commonJSMin", "exports", "module", "require_json", "__commonJSMin", "exports", "module", "Graph", "write", "read", "g", "json", "writeNodes", "writeEdges", "v", "nodeValue", "parent", "node", "edgeValue", "edge", "entry", "require_components", "__commonJSMin", "exports", "module", "components", "g", "visited", "cmpts", "cmpt", "dfs", "v", "require_priority_queue", "__commonJSMin", "exports", "module", "PriorityQueue", "__publicField", "x", "key", "index", "priority", "keyIndices", "arr", "min", "i", "l", "r", "largest", "parent", "j", "origArrI", "origArrJ", "require_dijkstra", "__commonJSMin", "exports", "module", "PriorityQueue", "dijkstra", "DEFAULT_WEIGHT_FUNC", "g", "source", "weightFn", "edgeFn", "runDijkstra", "v", "results", "pq", "vEntry", "updateNeighbors", "edge", "w", "wEntry", "weight", "distance", "require_dijkstra_all", "__commonJSMin", "exports", "module", "dijkstra", "dijkstraAll", "g", "weightFunc", "edgeFunc", "acc", "v", "require_tarjan", "__commonJSMin", "exports", "module", "tarjan", "g", "index", "stack", "visited", "results", "dfs", "v", "entry", "w", "cmpt", "require_find_cycles", "__commonJSMin", "exports", "module", "tarjan", "findCycles", "g", "cmpt", "require_floyd_warshall", "__commonJSMin", "exports", "module", "floydWarshall", "DEFAULT_WEIGHT_FUNC", "g", "weightFn", "edgeFn", "runFloydWarshall", "v", "results", "nodes", "w", "edge", "d", "k", "rowK", "i", "rowI", "j", "ik", "kj", "ij", "altDistance", "require_topsort", "__commonJSMin", "exports", "module", "topsort", "g", "visited", "stack", "results", "visit", "node", "CycleException", "require_is_acyclic", "__commonJSMin", "exports", "module", "topsort", "isAcyclic", "g", "require_dfs", "__commonJSMin", "exports", "module", "dfs", "g", "vs", "order", "navigation", "v", "orderFunc", "postOrderDfs", "preOrderDfs", "acc", "visited", "stack", "curr", "forEachRight", "w", "array", "iteratee", "length", "require_postorder", "__commonJSMin", "exports", "module", "dfs", "postorder", "g", "vs", "require_preorder", "__commonJSMin", "exports", "module", "dfs", "preorder", "g", "vs", "require_prim", "__commonJSMin", "exports", "module", "Graph", "PriorityQueue", "prim", "g", "weightFunc", "result", "parents", "pq", "v", "updateNeighbors", "edge", "w", "pri", "edgeWeight", "init", "require_alg", "__commonJSMin", "exports", "module", "lib"] +} diff --git a/dist/dagre.d.ts b/dist/dagre.d.ts new file mode 100644 index 00000000..aa3cc62d --- /dev/null +++ b/dist/dagre.d.ts @@ -0,0 +1,598 @@ +// Type definitions for graphlib 3.0.0 +// Project: https://github.com/cpettitt/graphlib +// Definitions by: Dan Vanderkam , Dan Mironenko +// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped + +export interface GraphOptions { + directed?: boolean; // default: true. + multigraph?: boolean; // default: false. + compound?: boolean; // default: false. +} + +export interface Edge { + v: string; + w: string; + /** The name that uniquely identifies a multi-edge. */ + name?: string; +} + +export class Graph { + constructor(options?: GraphOptions); + + /** + * Sets the default node label. This label will be assigned as default label + * in case if no label was specified while setting a node. + * Complexity: O(1). + * + * @argument labelOrFn - default node label or label factory function. + * @returns the graph, allowing this to be chained with other functions. + */ + setDefaultNodeLabel(labelOrFn: NodeLabel | ((v: string) => NodeLabel)): this; + + /** + * Creates or updates the value for the node v in the graph. If label is supplied + * it is set as the value for the node. If label is not supplied and the node was + * created by this call then the default node label will be assigned. + * Complexity: O(1). + * + * @argument name - node name. + * @argument label - value to set for node. + * @returns the graph, allowing this to be chained with other functions. + */ + setNode(name: string, label?: NodeLabel): this; + + /** + * Invokes setNode method for each node in names list. + * Complexity: O(|names|). + * + * @argument names - list of nodes names to be set. + * @argument label - value to set for each node in list. + * @returns the graph, allowing this to be chained with other functions. + */ + setNodes(names: string[], label?: NodeLabel): this; + + /** + * Sets node p as a parent for node v if it is defined, or removes the + * parent for v if p is undefined. Method throws an exception in case of + * invoking it in context of noncompound graph. + * Average-case complexity: O(1). + * + * @argument v - node to be child for p. + * @argument p - node to be parent for v. + * @returns the graph, allowing this to be chained with other functions. + */ + setParent(v: string, p?: string): this; + + /** + * Gets parent node for node v. + * Complexity: O(1). + * + * @argument v - node to get parent of. + * @returns parent node name or void if v has no parent. + */ + parent(v: string): string | void; + + /** + * Gets list of direct children of node v. + * Complexity: O(1). + * + * @argument v - node to get children of. + * @returns children nodes names list. + */ + children(v: string): string[]; + + /** + * Creates new graph with nodes filtered via filter. Edges incident to rejected node + * are also removed. In case of compound graph, if parent is rejected by filter, + * than all its children are rejected too. + * Average-case complexity: O(|E|+|V|). + * + * @argument filter - filtration function detecting whether the node should stay or not. + * @returns new graph made from current and nodes filtered. + */ + filterNodes(filter: (v: string) => boolean): this; + + /** + * Sets the default edge label. This label will be assigned as default label + * in case if no label was specified while setting an edge. + * Complexity: O(1). + * + * @argument labelOrFn - default edge label or label factory function. + * @returns the graph, allowing this to be chained with other functions. + */ + setDefaultEdgeLabel(labelOrFn: EdgeLabel | ((v: string, w: string, name?: string) => EdgeLabel)): this; + + /** + * Establish an edges path over the nodes in nodes list. If some edge is already + * exists, it will update its label, otherwise it will create an edge between pair + * of nodes with label provided or default label if no label provided. + * Complexity: O(|nodes|). + * + * @argument nodes - list of nodes to be connected in series. + * @argument label - value to set for each edge between pairs of nodes. + * @returns the graph, allowing this to be chained with other functions. + */ + setPath(nodes: string[], label?: EdgeLabel): this; + + /** + * Detects whether graph has a node with specified name or not. + * + * @argument name - name of the node. + * @returns true if graph has node with specified name, false - otherwise. + */ + hasNode(name: string): boolean; + + /** + * Remove the node with the name from the graph or do nothing if the node is not in + * the graph. If the node was removed this function also removes any incident + * edges. + * Complexity: O(1). + * + * @argument name - name of the node. + * @returns the graph, allowing this to be chained with other functions. + */ + removeNode(name: string): this; + + /** + * Gets all nodes of the graph. Note, the in case of compound graph subnodes are + * not included in list. + * Complexity: O(1). + * + * @returns list of graph nodes. + */ + nodes(): string[]; + + /** + * Gets the label of node with specified name. + * Complexity: O(|V|). + * + * @returns label value of the node. + */ + node(name: string): NodeLabel; + + /** + * Creates or updates the label for the edge (v, w) with the optionally supplied + * name. If label is supplied it is set as the value for the edge. If label is not + * supplied and the edge was created by this call then the default edge label will + * be assigned. The name parameter is only useful with multigraphs. + * Complexity: O(1). + * + * @argument v - edge source node. + * @argument w - edge sink node. + * @argument label - value to associate with the edge. + * @argument name - unique name of the edge in order to identify it in multigraph. + * @returns the graph, allowing this to be chained with other functions. + */ + setEdge(v: string, w: string, label?: EdgeLabel, name?: string): this; + + /** + * Creates or updates the label for the specified edge. If label is supplied it is + * set as the value for the edge. If label is not supplied and the edge was created + * by this call then the default edge label will be assigned. The name parameter is + * only useful with multigraphs. + * Complexity: O(1). + * + * @argument edge - edge descriptor. + * @argument label - value to associate with the edge. + * @returns the graph, allowing this to be chained with other functions. + */ + setEdge(edge: Edge, label?: EdgeLabel): this; + + /** + * Gets edges of the graph. In case of compound graph subgraphs are not considered. + * Complexity: O(|E|). + * + * @return graph edges list. + */ + edges(): Edge[]; + + /** + * Gets the label for the specified edge. + * Complexity: O(1). + * + * @argument v - edge source node. + * @argument w - edge sink node. + * @argument name - name of the edge (actual for multigraph). + * @returns value associated with specified edge. + */ + edge(v: string, w: string, name?: string): EdgeLabel; + + /** + * Gets the label for the specified edge. + * Complexity: O(1). + * + * @argument edge - edge descriptor. + * @returns value associated with specified edge. + */ + edge(e: Edge): EdgeLabel; + + /** + * Gets the label for the specified edge and converts it to an object. + * Complexity: O(1). + * + * @argument v - edge source node. + * @argument w - edge sink node. + * @argument name - name of the edge (actual for multigraph). + * @returns value associated with specified edge. + */ + edgeAsObj(v: string, w: string, name?: string): Object; + + /** + * Gets the label for the specified edge and converts it to an object. + * Complexity: O(1). + * + * @argument edge - edge descriptor. + * @returns value associated with specified edge. + */ + edgeAsObj(e: Edge): Object; + + /** + * Detects whether the graph contains specified edge or not. No subgraphs are considered. + * Complexity: O(1). + * + * @argument v - edge source node. + * @argument w - edge sink node. + * @argument name - name of the edge (actual for multigraph). + * @returns whether the graph contains the specified edge or not. + */ + hasEdge(v: string, w: string, name?: string): boolean; + + /** + * Detects whether the graph contains specified edge or not. No subgraphs are considered. + * Complexity: O(1). + * + * @argument edge - edge descriptor. + * @returns whether the graph contains the specified edge or not. + */ + hasEdge(edge: Edge): boolean; + + /** + * Removes the specified edge from the graph. No subgraphs are considered. + * Complexity: O(1). + * + * @argument edge - edge descriptor. + * @returns the graph, allowing this to be chained with other functions. + */ + removeEdge(edge: Edge): this; + + /** + * Removes the specified edge from the graph. No subgraphs are considered. + * Complexity: O(1). + * + * @argument v - edge source node. + * @argument w - edge sink node. + * @argument name - name of the edge (actual for multigraph). + * @returns the graph, allowing this to be chained with other functions. + */ + removeEdge(v: string, w: string, name?: string): this; + + /** + * Return all edges that point to the node v. Optionally filters those edges down to just those + * coming from node u. Behavior is undefined for undirected graphs - use nodeEdges instead. + * Complexity: O(|E|). + * + * @argument v - edge sink node. + * @argument w - edge source node. + * @returns edges descriptors list if v is in the graph, or undefined otherwise. + */ + inEdges(v: string, w?: string): void | Edge[]; + + /** + * Return all edges that are pointed at by node v. Optionally filters those edges down to just + * those point to w. Behavior is undefined for undirected graphs - use nodeEdges instead. + * Complexity: O(|E|). + * + * @argument v - edge source node. + * @argument w - edge sink node. + * @returns edges descriptors list if v is in the graph, or undefined otherwise. + */ + outEdges(v: string, w?: string): void | Edge[]; + +/** + * Returns all edges to or from node v regardless of direction. Optionally filters those edges + * down to just those between nodes v and w regardless of direction. + * Complexity: O(|E|). + * + * @argument v - edge adjacent node. + * @argument w - edge adjacent node. + * @returns edges descriptors list if v is in the graph, or undefined otherwise. + */ + nodeEdges(v: string, w?: string): void | Edge[]; + + /** + * Return all nodes that are predecessors of the specified node or undefined if node v is not in + * the graph. Behavior is undefined for undirected graphs - use neighbors instead. + * Complexity: O(|V|). + * + * @argument v - node identifier. + * @returns node identifiers list or undefined if v is not in the graph. + */ + predecessors(v: string): void | string[]; + + /** + * Return all nodes that are successors of the specified node or undefined if node v is not in + * the graph. Behavior is undefined for undirected graphs - use neighbors instead. + * Complexity: O(|V|). + * + * @argument v - node identifier. + * @returns node identifiers list or undefined if v is not in the graph. + */ + successors(v: string): void | string[]; + + /** + * Return all nodes that are predecessors or successors of the specified node or undefined if + * node v is not in the graph. + * Complexity: O(|V|). + * + * @argument v - node identifier. + * @returns node identifiers list or undefined if v is not in the graph. + */ + + neighbors(v: string): void | string[]; + + /** + * Whether graph was created with 'directed' flag set to true or not. + * + * @returns whether the graph edges have an orientation. + */ + isDirected(): boolean; + + /** + * Whether graph was created with 'multigraph' flag set to true or not. + * + * @returns whether the pair of nodes of the graph can have multiple edges. + */ + isMultigraph(): boolean; + + /** + * Whether graph was created with 'compound' flag set to true or not. + * + * @returns whether a node of the graph can have subnodes. + */ + isCompound(): boolean; + + /** + * Sets the label of the graph. + * + * @argument label - label value. + * @returns the graph, allowing this to be chained with other functions. + */ + setGraph(label: GraphLabel): this; + + /** + * Gets the graph label. + * + * @returns currently assigned label for the graph or undefined if no label assigned. + */ + graph(): GraphLabel; + + /** + * Gets the number of nodes in the graph. + * Complexity: O(1). + * + * @returns nodes count. + */ + nodeCount(): number; + + /** + * Gets the number of edges in the graph. + * Complexity: O(1). + * + * @returns edges count. + */ + edgeCount(): number; + + /** + * Gets list of nodes without in-edges. + * Complexity: O(|V|). + * + * @returns the graph source nodes. + */ + sources(): string[]; + + /** + * Gets list of nodes without out-edges. + * Complexity: O(|V|). + * + * @returns the graph source nodes. + */ + sinks(): string[]; +} + +export namespace json { + /** + * Creates a JSON representation of the graph that can be serialized to a string with + * JSON.stringify. The graph can later be restored using json.read. + * + * @argument graph - target to create JSON representation of. + * @returns JSON serializable graph representation + */ + function write(graph: Graph): Object; + + /** + * Takes JSON as input and returns the graph representation. + * + * @example + * var g2 = graphlib.json.read(JSON.parse(str)); + * g2.nodes(); + * // ['a', 'b'] + * g2.edges() + * // [ { v: 'a', w: 'b' } ] + * + * @argument json - JSON serializable graph representation + * @returns graph constructed acccording to specified representation + */ + function read( + json: Object, + ): Graph; +} + +export interface Path { + distance: number; + predecessor: string; +} + +export namespace alg { + /** + * Finds all connected components in a graph and returns an array of these components. + * Each component is itself an array that contains the ids of nodes in the component. + * Complexity: O(|V|). + * + * @argument graph - graph to find components in. + * @returns array of nodes list representing components + */ + function components(graph: Graph): string[][]; + + /** + * This function is an implementation of Dijkstra's algorithm which finds the shortest + * path from source to all other nodes in graph. This function returns a map of + * v -> { distance, predecessor }. The distance property holds the sum of the weights + * from source to v along the shortest path or Number.POSITIVE_INFINITY if there is no path + * from source. The predecessor property can be used to walk the individual elements of the + * path from source to v in reverse order. + * Complexity: O((|E| + |V|) * log |V|). + * + * @argument graph - graph where to search pathes. + * @argument source - node to start pathes from. + * @argument weightFn - function which takes edge e and returns the weight of it. If no weightFn + * is supplied then each edge is assumed to have a weight of 1. This function throws an + * Error if any of the traversed edges have a negative edge weight. + * @argument edgeFn - function which takes a node v and returns the ids of all edges incident to it + * for the purposes of shortest path traversal. By default this function uses the graph.outEdges. + * @returns shortest pathes map that starts from node source + */ + function dijkstra( + graph: Graph, + source: string, + weightFn?: (e: Edge) => number, + edgeFn?: (v: string) => Edge[], + ): { [node: string]: Path }; + + /** + * This function finds the shortest path from each node to every other reachable node in + * the graph. It is similar to alg.dijkstra, but instead of returning a single-source + * array, it returns a mapping of source -> alg.dijksta(g, source, weightFn, edgeFn). + * Complexity: O(|V| * (|E| + |V|) * log |V|). + * + * @argument graph - graph where to search pathes. + * @argument weightFn - function which takes edge e and returns the weight of it. If no weightFn + * is supplied then each edge is assumed to have a weight of 1. This function throws an + * Error if any of the traversed edges have a negative edge weight. + * @argument edgeFn - function which takes a node v and returns the ids of all edges incident to it + * for the purposes of shortest path traversal. By default this function uses the graph.outEdges. + * @returns shortest pathes map. + */ + function dijkstraAll( + graph: Graph, + weightFn?: (e: Edge) => number, + edgeFn?: (v: string) => Edge[], + ): { : { [node: string]: Path } }; + + /** + * Given a Graph, graph, this function returns all nodes that are part of a cycle. As there + * may be more than one cycle in a graph this function return an array of these cycles, + * where each cycle is itself represented by an array of ids for each node involved in + * that cycle. Method alg.isAcyclic is more efficient if you only need to determine whether a graph has a + * cycle or not. + * Complexity: O(|V| + |E|). + * + * @argument graph - graph where to search cycles. + * @returns cycles list. + */ + function findCycles(graph: Graph): string[][]; + + /** + * Given a Graph, graph, this function returns true if the graph has no cycles and returns false if it + * does. This algorithm returns as soon as it detects the first cycle. You can use alg.findCycles + * to get the actual list of cycles in the graph. + * + * @argument graph - graph to detect whether it acyclic ot not. + * @returns whether graph contain cycles or not. + */ + function isAcyclic(graph: Graph): boolean; + + /** + * This function is an implementation of the Floyd-Warshall algorithm, which finds the + * shortest path from each node to every other reachable node in the graph. It is similar + * to alg.dijkstraAll, but it handles negative edge weights and is more efficient for some types + * of graphs. This function returns a map of source -> { target -> { distance, predecessor }. + * The distance property holds the sum of the weights from source to target along the shortest + * path of Number.POSITIVE_INFINITY if there is no path from source. The predecessor property + * can be used to walk the individual elements of the path from source to target in reverse + * order. + * Complexity: O(|V|^3). + * + * @argument graph - graph where to search pathes. + * @argument weightFn - function which takes edge e and returns the weight of it. If no weightFn + * is supplied then each edge is assumed to have a weight of 1. This function throws an + * Error if any of the traversed edges have a negative edge weight. + * @argument edgeFn - function which takes a node v and returns the ids of all edges incident to it + * for the purposes of shortest path traversal. By default this function uses the graph.outEdges. + * @returns shortest pathes map. + */ + function floydWarshall( + graph: Graph, + weightFn?: (e: Edge) => number, + edgeFn?: (v: string) => Edge[], + ): { [source: string]: { [node: string]: Path } }; + + /** + * Prim's algorithm takes a connected undirected graph and generates a minimum spanning tree. This + * function returns the minimum spanning tree as an undirected graph. This algorithm is derived + * from the description in "Introduction to Algorithms", Third Edition, Cormen, et al., Pg 634. + * Complexity: O(|E| * log |V|); + * + * @argument graph - graph to generate a minimum spanning tree of. + * @argument weightFn - function which takes edge e and returns the weight of it. It throws an Error if + * the graph is not connected. + * @returns minimum spanning tree of graph. + */ + function prim(graph: Graph, weightFn: (e: Edge) => number): Graph; + + /** + * This function is an implementation of Tarjan's algorithm which finds all strongly connected + * components in the directed graph g. Each strongly connected component is composed of nodes that + * can reach all other nodes in the component via directed edges. A strongly connected component + * can consist of a single node if that node cannot both reach and be reached by any other + * specific node in the graph. Components of more than one node are guaranteed to have at least + * one cycle. + * Complexity: O(|V| + |E|). + * + * @argument graph - graph to find all strongly connected components of. + * @return an array of components. Each component is itself an array that contains + * the ids of all nodes in the component. + */ + function tarjan(graph: Graph): string[][]; + + /** + * Given a Graph graph this function applies topological sorting to it. + * If the graph has a cycle it is impossible to generate such a list and CycleException is thrown. + * Complexity: O(|V| + |E|). + * + * @argument graph - graph to apply topological sorting to. + * @returns an array of nodes such that for each edge u -> v, u appears before v in the array. + */ + function topsort(graph: Graph): string[]; + + /** + * Performs pre-order depth first traversal on the input graph. If the graph is + * undirected then this algorithm will navigate using neighbors. If the graph + * is directed then this algorithm will navigate using successors. + * + * @argument graph - depth first traversal target. + * @argument vs - nodes list to traverse. + * @returns the nodes in the order they were visited as a list of their names. + */ + function preorder(graph: Graph, vs: string[]): string[]; + + /** + * Performs post-order depth first traversal on the input graph. If the graph is + * undirected then this algorithm will navigate using neighbors. If the graph + * is directed then this algorithm will navigate using successors. + * + * @argument graph - depth first traversal target. + * @argument vs - nodes list to traverse. + * @returns the nodes in the order they were visited as a list of their names. + */ + function postorder(graph: Graph, vs: string[]): string[]; +} \ No newline at end of file diff --git a/dist/dagre.esm.js b/dist/dagre.esm.js new file mode 100644 index 00000000..66b4cf4c --- /dev/null +++ b/dist/dagre.esm.js @@ -0,0 +1,2 @@ +var fe=Object.defineProperty;var le=(n,e,r)=>e in n?fe(n,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):n[e]=r;var c=(n,e)=>()=>(e||n((e={exports:{}}).exports,e),e.exports);var d=(n,e,r)=>le(n,typeof e!="symbol"?e+"":e,r);var b=c((Re,D)=>{"use strict";var _e="\0",p="\0",C="",m=class{constructor(e){d(this,"_isDirected",!0);d(this,"_isMultigraph",!1);d(this,"_isCompound",!1);d(this,"_label");d(this,"_defaultNodeLabelFn",()=>{});d(this,"_defaultEdgeLabelFn",()=>{});d(this,"_nodes",{});d(this,"_in",{});d(this,"_preds",{});d(this,"_out",{});d(this,"_sucs",{});d(this,"_edgeObjs",{});d(this,"_edgeLabels",{});d(this,"_nodeCount",0);d(this,"_edgeCount",0);d(this,"_parent");d(this,"_children");e&&(this._isDirected=Object.hasOwn(e,"directed")?e.directed:!0,this._isMultigraph=Object.hasOwn(e,"multigraph")?e.multigraph:!1,this._isCompound=Object.hasOwn(e,"compound")?e.compound:!1),this._isCompound&&(this._parent={},this._children={},this._children[p]={})}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return this._defaultNodeLabelFn=e,typeof e!="function"&&(this._defaultNodeLabelFn=()=>e),this}nodeCount(){return this._nodeCount}nodes(){return Object.keys(this._nodes)}sources(){var e=this;return this.nodes().filter(r=>Object.keys(e._in[r]).length===0)}sinks(){var e=this;return this.nodes().filter(r=>Object.keys(e._out[r]).length===0)}setNodes(e,r){var t=arguments,s=this;return e.forEach(function(i){t.length>1?s.setNode(i,r):s.setNode(i)}),this}setNode(e,r){return Object.hasOwn(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=r),this):(this._nodes[e]=arguments.length>1?r:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=p,this._children[e]={},this._children[p][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.hasOwn(this._nodes,e)}removeNode(e){var r=this;if(Object.hasOwn(this._nodes,e)){var t=s=>r.removeEdge(r._edgeObjs[s]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],this.children(e).forEach(function(s){r.setParent(s)}),delete this._children[e]),Object.keys(this._in[e]).forEach(t),delete this._in[e],delete this._preds[e],Object.keys(this._out[e]).forEach(t),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,r){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(r===void 0)r=p;else{r+="";for(var t=r;t!==void 0;t=this.parent(t))if(t===e)throw new Error("Setting "+r+" as parent of "+e+" would create a cycle");this.setNode(r)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=r,this._children[r][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var r=this._parent[e];if(r!==p)return r}}children(e=p){if(this._isCompound){var r=this._children[e];if(r)return Object.keys(r)}else{if(e===p)return this.nodes();if(this.hasNode(e))return[]}}predecessors(e){var r=this._preds[e];if(r)return Object.keys(r)}successors(e){var r=this._sucs[e];if(r)return Object.keys(r)}neighbors(e){var r=this.predecessors(e);if(r){let s=new Set(r);for(var t of this.successors(e))s.add(t);return Array.from(s.values())}}isLeaf(e){var r;return this.isDirected()?r=this.successors(e):r=this.neighbors(e),r.length===0}filterNodes(e){var r=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});r.setGraph(this.graph());var t=this;Object.entries(this._nodes).forEach(function([a,o]){e(a)&&r.setNode(a,o)}),Object.values(this._edgeObjs).forEach(function(a){r.hasNode(a.v)&&r.hasNode(a.w)&&r.setEdge(a,t.edge(a))});var s={};function i(a){var o=t.parent(a);return o===void 0||r.hasNode(o)?(s[a]=o,o):o in s?s[o]:i(o)}return this._isCompound&&r.nodes().forEach(a=>r.setParent(a,i(a))),r}setDefaultEdgeLabel(e){return this._defaultEdgeLabelFn=e,typeof e!="function"&&(this._defaultEdgeLabelFn=()=>e),this}edgeCount(){return this._edgeCount}edges(){return Object.values(this._edgeObjs)}setPath(e,r){var t=this,s=arguments;return e.reduce(function(i,a){return s.length>1?t.setEdge(i,a,r):t.setEdge(i,a),a}),this}setEdge(){var e,r,t,s,i=!1,a=arguments[0];typeof a=="object"&&a!==null&&"v"in a?(e=a.v,r=a.w,t=a.name,arguments.length===2&&(s=arguments[1],i=!0)):(e=a,r=arguments[1],t=arguments[3],arguments.length>2&&(s=arguments[2],i=!0)),e=""+e,r=""+r,t!==void 0&&(t=""+t);var o=g(this._isDirected,e,r,t);if(Object.hasOwn(this._edgeLabels,o))return i&&(this._edgeLabels[o]=s),this;if(t!==void 0&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(r),this._edgeLabels[o]=i?s:this._defaultEdgeLabelFn(e,r,t);var u=pe(this._isDirected,e,r,t);return e=u.v,r=u.w,Object.freeze(u),this._edgeObjs[o]=u,q(this._preds[r],e),q(this._sucs[e],r),this._in[r][o]=u,this._out[e][o]=u,this._edgeCount++,this}edge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t);return this._edgeLabels[s]}edgeAsObj(){let e=this.edge(...arguments);return typeof e!="object"?{label:e}:e}hasEdge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t);return Object.hasOwn(this._edgeLabels,s)}removeEdge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t),i=this._edgeObjs[s];return i&&(e=i.v,r=i.w,delete this._edgeLabels[s],delete this._edgeObjs[s],x(this._preds[r],e),x(this._sucs[e],r),delete this._in[r][s],delete this._out[e][s],this._edgeCount--),this}inEdges(e,r){var t=this._in[e];if(t){var s=Object.values(t);return r?s.filter(i=>i.v===r):s}}outEdges(e,r){var t=this._out[e];if(t){var s=Object.values(t);return r?s.filter(i=>i.w===r):s}}nodeEdges(e,r){var t=this.inEdges(e,r);if(t)return t.concat(this.outEdges(e,r))}};function q(n,e){n[e]?n[e]++:n[e]=1}function x(n,e){--n[e]||delete n[e]}function g(n,e,r,t){var s=""+e,i=""+r;if(!n&&s>i){var a=s;s=i,i=a}return s+C+i+C+(t===void 0?_e:t)}function pe(n,e,r,t){var s=""+e,i=""+r;if(!n&&s>i){var a=s;s=i,i=a}var o={v:s,w:i};return t&&(o.name=t),o}function w(n,e){return g(n,e.v,e.w,e.name)}D.exports=m});var F=c((Be,L)=>{L.exports="2.2.5-pre"});var T=c((Je,A)=>{A.exports={Graph:b(),version:F()}});var P=c((Xe,M)=>{var ve=b();M.exports={write:ge,read:we};function ge(n){var e={options:{directed:n.isDirected(),multigraph:n.isMultigraph(),compound:n.isCompound()},nodes:Ee(n),edges:be(n)};return n.graph()!==void 0&&(e.value=structuredClone(n.graph())),e}function Ee(n){return n.nodes().map(function(e){var r=n.node(e),t=n.parent(e),s={v:e};return r!==void 0&&(s.value=r),t!==void 0&&(s.parent=t),s})}function be(n){return n.edges().map(function(e){var r=n.edge(e),t={v:e.v,w:e.w};return e.name!==void 0&&(t.name=e.name),r!==void 0&&(t.value=r),t})}function we(n){var e=new ve(n.options).setGraph(n.value);return n.nodes.forEach(function(r){e.setNode(r.v,r.value),r.parent&&e.setParent(r.v,r.parent)}),n.edges.forEach(function(r){e.setEdge({v:r.v,w:r.w,name:r.name},r.value)}),e}});var S=c((Ze,G)=>{G.exports=me;function me(n){var e={},r=[],t;function s(i){Object.hasOwn(e,i)||(e[i]=!0,t.push(i),n.successors(i).forEach(s),n.predecessors(i).forEach(s))}return n.nodes().forEach(function(i){t=[],s(i),t.length&&r.push(t)}),r}});var j=c(($e,V)=>{var O=class{constructor(){d(this,"_arr",[]);d(this,"_keyIndices",{})}size(){return this._arr.length}keys(){return this._arr.map(function(e){return e.key})}has(e){return Object.hasOwn(this._keyIndices,e)}priority(e){var r=this._keyIndices[e];if(r!==void 0)return this._arr[r].priority}min(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key}add(e,r){var t=this._keyIndices;if(e=String(e),!Object.hasOwn(t,e)){var s=this._arr,i=s.length;return t[e]=i,s.push({key:e,priority:r}),this._decrease(i),!0}return!1}removeMin(){this._swap(0,this._arr.length-1);var e=this._arr.pop();return delete this._keyIndices[e.key],this._heapify(0),e.key}decrease(e,r){var t=this._keyIndices[e];if(r>this._arr[t].priority)throw new Error("New priority is greater than current priority. Key: "+e+" Old: "+this._arr[t].priority+" New: "+r);this._arr[t].priority=r,this._decrease(t)}_heapify(e){var r=this._arr,t=2*e,s=t+1,i=e;t>1,!(r[s].priority{var Oe=j();z.exports=ye;var je=()=>1;function ye(n,e,r,t){return Ne(n,String(e),r||je,t||function(s){return n.outEdges(s)})}function Ne(n,e,r,t){var s={},i=new Oe,a,o,u=function(h){var f=h.v!==a?h.v:h.w,l=s[f],_=r(h),v=o.distance+_;if(_<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+h+" Weight: "+_);v0&&(a=i.removeMin(),o=s[a],o.distance!==Number.POSITIVE_INFINITY);)t(a).forEach(u);return s}});var W=c((tr,U)=>{var ke=y();U.exports=Ie;function Ie(n,e,r){return n.nodes().reduce(function(t,s){return t[s]=ke(n,s,e,r),t},{})}});var N=c((sr,Y)=>{Y.exports=Ce;function Ce(n){var e=0,r=[],t={},s=[];function i(a){var o=t[a]={onStack:!0,lowlink:e,index:e++};if(r.push(a),n.successors(a).forEach(function(f){Object.hasOwn(t,f)?t[f].onStack&&(o.lowlink=Math.min(o.lowlink,t[f].index)):(i(f),o.lowlink=Math.min(o.lowlink,t[f].lowlink))}),o.lowlink===o.index){var u=[],h;do h=r.pop(),t[h].onStack=!1,u.push(h);while(a!==h);s.push(u)}}return n.nodes().forEach(function(a){Object.hasOwn(t,a)||i(a)}),s}});var K=c((ir,H)=>{var qe=N();H.exports=xe;function xe(n){return qe(n).filter(function(e){return e.length>1||e.length===1&&n.hasEdge(e[0],e[0])})}});var Q=c((nr,R)=>{R.exports=Le;var De=()=>1;function Le(n,e,r){return Fe(n,e||De,r||function(t){return n.outEdges(t)})}function Fe(n,e,r){var t={},s=n.nodes();return s.forEach(function(i){t[i]={},t[i][i]={distance:0},s.forEach(function(a){i!==a&&(t[i][a]={distance:Number.POSITIVE_INFINITY})}),r(i).forEach(function(a){var o=a.v===i?a.w:a.v,u=e(a);t[i][o]={distance:u,predecessor:i}})}),s.forEach(function(i){var a=t[i];s.forEach(function(o){var u=t[o];s.forEach(function(h){var f=u[i],l=a[h],_=u[h],v=f.distance+l.distance;v<_.distance&&(_.distance=v,_.predecessor=l.predecessor)})})}),t}});var k=c((ar,J)=>{function B(n){var e={},r={},t=[];function s(i){if(Object.hasOwn(r,i))throw new E;Object.hasOwn(e,i)||(r[i]=!0,e[i]=!0,n.predecessors(i).forEach(s),delete r[i],t.push(i))}if(n.sinks().forEach(s),Object.keys(e).length!==n.nodeCount())throw new E;return t}var E=class extends Error{constructor(){super(...arguments)}};J.exports=B;B.CycleException=E});var $=c((or,Z)=>{var X=k();Z.exports=Ae;function Ae(n){try{X(n)}catch(e){if(e instanceof X.CycleException)return!1;throw e}return!0}});var I=c((ur,re)=>{re.exports=Te;function Te(n,e,r){Array.isArray(e)||(e=[e]);var t=n.isDirected()?o=>n.successors(o):o=>n.neighbors(o),s=r==="post"?Me:Pe,i=[],a={};return e.forEach(o=>{if(!n.hasNode(o))throw new Error("Graph does not have node: "+o);s(o,t,a,i)}),i}function Me(n,e,r,t){for(var s=[[n,!1]];s.length>0;){var i=s.pop();i[1]?t.push(i[0]):Object.hasOwn(r,i[0])||(r[i[0]]=!0,s.push([i[0],!0]),ee(e(i[0]),a=>s.push([a,!1])))}}function Pe(n,e,r,t){for(var s=[n];s.length>0;){var i=s.pop();Object.hasOwn(r,i)||(r[i]=!0,t.push(i),ee(e(i),a=>s.push(a)))}}function ee(n,e){for(var r=n.length;r--;)e(n[r],r,n);return n}});var se=c((hr,te)=>{var Ge=I();te.exports=Se;function Se(n,e){return Ge(n,e,"post")}});var ne=c((dr,ie)=>{var Ve=I();ie.exports=ze;function ze(n,e){return Ve(n,e,"pre")}});var oe=c((cr,ae)=>{var Ue=b(),We=j();ae.exports=Ye;function Ye(n,e){var r=new Ue,t={},s=new We,i;function a(u){var h=u.v===i?u.w:u.v,f=s.priority(h);if(f!==void 0){var l=e(u);l0;){if(i=s.removeMin(),Object.hasOwn(t,i))r.setEdge(i,t[i]);else{if(o)throw new Error("Input graph is not connected: "+n);o=!0}n.nodeEdges(i).forEach(a)}return r}});var he=c((fr,ue)=>{ue.exports={components:S(),dijkstra:y(),dijkstraAll:W(),findCycles:K(),floydWarshall:Q(),isAcyclic:$(),postorder:se(),preorder:ne(),prim:oe(),tarjan:N(),topsort:k()}});var He=c((lr,ce)=>{var de=T();ce.exports={Graph:de.Graph,json:P(),alg:he(),version:de.version}});export default He(); +//# sourceMappingURL=dagre.esm.js.map diff --git a/dist/dagre.esm.js.map b/dist/dagre.esm.js.map new file mode 100644 index 00000000..daf91858 --- /dev/null +++ b/dist/dagre.esm.js.map @@ -0,0 +1,7 @@ +{ + "version": 3, + "sources": ["../lib/graph.js", "../lib/version.js", "../lib/index.js", "../lib/json.js", "../lib/alg/components.js", "../lib/data/priority-queue.js", "../lib/alg/dijkstra.js", "../lib/alg/dijkstra-all.js", "../lib/alg/tarjan.js", "../lib/alg/find-cycles.js", "../lib/alg/floyd-warshall.js", "../lib/alg/topsort.js", "../lib/alg/is-acyclic.js", "../lib/alg/dfs.js", "../lib/alg/postorder.js", "../lib/alg/preorder.js", "../lib/alg/prim.js", "../lib/alg/index.js", "../index.js"], + "sourcesContent": ["\"use strict\";\n\nvar DEFAULT_EDGE_NAME = \"\\x00\";\nvar GRAPH_NODE = \"\\x00\";\nvar EDGE_KEY_DELIM = \"\\x01\";\n\n// Implementation notes:\n//\n// * Node id query functions should return string ids for the nodes\n// * Edge id query functions should return an \"edgeObj\", edge object, that is\n// composed of enough information to uniquely identify an edge: {v, w, name}.\n// * Internally we use an \"edgeId\", a stringified form of the edgeObj, to\n// reference edges. This is because we need a performant way to look these\n// edges up and, object properties, which have string keys, are the closest\n// we're going to get to a performant hashtable in JavaScript.\n\nclass Graph {\n _isDirected = true;\n _isMultigraph = false;\n _isCompound = false;\n\n // Label for the graph itself\n _label;\n\n // Defaults to be set when creating a new node\n _defaultNodeLabelFn = () => undefined;\n\n // Defaults to be set when creating a new edge\n _defaultEdgeLabelFn = () => undefined;\n\n // v -> label\n _nodes = {};\n\n // v -> edgeObj\n _in = {};\n\n // u -> v -> Number\n _preds = {};\n\n // v -> edgeObj\n _out = {};\n\n // v -> w -> Number\n _sucs = {};\n\n // e -> edgeObj\n _edgeObjs = {};\n\n // e -> label\n _edgeLabels = {};\n\n /* Number of nodes in the graph. Should only be changed by the implementation. */\n _nodeCount = 0;\n\n /* Number of edges in the graph. Should only be changed by the implementation. */\n _edgeCount = 0;\n\n _parent;\n\n _children;\n\n constructor(opts) {\n if (opts) {\n this._isDirected = Object.hasOwn(opts, \"directed\") ? opts.directed : true;\n this._isMultigraph = Object.hasOwn(opts, \"multigraph\") ? opts.multigraph : false;\n this._isCompound = Object.hasOwn(opts, \"compound\") ? opts.compound : false;\n }\n\n if (this._isCompound) {\n // v -> parent\n this._parent = {};\n\n // v -> children\n this._children = {};\n this._children[GRAPH_NODE] = {};\n }\n }\n\n /* === Graph functions ========= */\n\n /**\n * Whether graph was created with 'directed' flag set to true or not.\n */\n isDirected() {\n return this._isDirected;\n }\n\n /**\n * Whether graph was created with 'multigraph' flag set to true or not.\n */\n isMultigraph() {\n return this._isMultigraph;\n }\n\n /**\n * Whether graph was created with 'compound' flag set to true or not.\n */\n isCompound() {\n return this._isCompound;\n }\n\n /**\n * Sets the label of the graph.\n */\n setGraph(label) {\n this._label = label;\n return this;\n }\n\n /**\n * Gets the graph label.\n */\n graph() {\n return this._label;\n }\n\n\n /* === Node functions ========== */\n\n /**\n * Sets the default node label. If newDefault is a function, it will be\n * invoked ach time when setting a label for a node. Otherwise, this label\n * will be assigned as default label in case if no label was specified while\n * setting a node.\n * Complexity: O(1).\n */\n setDefaultNodeLabel(newDefault) {\n this._defaultNodeLabelFn = newDefault;\n if (typeof newDefault !== 'function') {\n this._defaultNodeLabelFn = () => newDefault;\n }\n\n return this;\n }\n\n /**\n * Gets the number of nodes in the graph.\n * Complexity: O(1).\n */\n nodeCount() {\n return this._nodeCount;\n }\n\n /**\n * Gets all nodes of the graph. Note, the in case of compound graph subnodes are\n * not included in list.\n * Complexity: O(1).\n */\n nodes() {\n return Object.keys(this._nodes);\n }\n\n /**\n * Gets list of nodes without in-edges.\n * Complexity: O(|V|).\n */\n sources() {\n var self = this;\n return this.nodes().filter(v => Object.keys(self._in[v]).length === 0);\n }\n\n /**\n * Gets list of nodes without out-edges.\n * Complexity: O(|V|).\n */\n sinks() {\n var self = this;\n return this.nodes().filter(v => Object.keys(self._out[v]).length === 0);\n }\n\n /**\n * Invokes setNode method for each node in names list.\n * Complexity: O(|names|).\n */\n setNodes(vs, value) {\n var args = arguments;\n var self = this;\n vs.forEach(function(v) {\n if (args.length > 1) {\n self.setNode(v, value);\n } else {\n self.setNode(v);\n }\n });\n return this;\n }\n\n /**\n * Creates or updates the value for the node v in the graph. If label is supplied\n * it is set as the value for the node. If label is not supplied and the node was\n * created by this call then the default node label will be assigned.\n * Complexity: O(1).\n */\n setNode(v, value) {\n if (Object.hasOwn(this._nodes, v)) {\n if (arguments.length > 1) {\n this._nodes[v] = value;\n }\n return this;\n }\n\n this._nodes[v] = arguments.length > 1 ? value : this._defaultNodeLabelFn(v);\n if (this._isCompound) {\n this._parent[v] = GRAPH_NODE;\n this._children[v] = {};\n this._children[GRAPH_NODE][v] = true;\n }\n this._in[v] = {};\n this._preds[v] = {};\n this._out[v] = {};\n this._sucs[v] = {};\n ++this._nodeCount;\n return this;\n }\n\n /**\n * Gets the label of node with specified name.\n * Complexity: O(|V|).\n */\n node(v) {\n return this._nodes[v];\n }\n\n /**\n * Detects whether graph has a node with specified name or not.\n */\n hasNode(v) {\n return Object.hasOwn(this._nodes, v);\n }\n\n /**\n * Remove the node with the name from the graph or do nothing if the node is not in\n * the graph. If the node was removed this function also removes any incident\n * edges.\n * Complexity: O(1).\n */\n removeNode(v) {\n var self = this;\n if (Object.hasOwn(this._nodes, v)) {\n var removeEdge = e => self.removeEdge(self._edgeObjs[e]);\n delete this._nodes[v];\n if (this._isCompound) {\n this._removeFromParentsChildList(v);\n delete this._parent[v];\n this.children(v).forEach(function(child) {\n self.setParent(child);\n });\n delete this._children[v];\n }\n Object.keys(this._in[v]).forEach(removeEdge);\n delete this._in[v];\n delete this._preds[v];\n Object.keys(this._out[v]).forEach(removeEdge);\n delete this._out[v];\n delete this._sucs[v];\n --this._nodeCount;\n }\n return this;\n }\n\n /**\n * Sets node p as a parent for node v if it is defined, or removes the\n * parent for v if p is undefined. Method throws an exception in case of\n * invoking it in context of noncompound graph.\n * Average-case complexity: O(1).\n */\n setParent(v, parent) {\n if (!this._isCompound) {\n throw new Error(\"Cannot set parent in a non-compound graph\");\n }\n\n if (parent === undefined) {\n parent = GRAPH_NODE;\n } else {\n // Coerce parent to string\n parent += \"\";\n for (var ancestor = parent; ancestor !== undefined; ancestor = this.parent(ancestor)) {\n if (ancestor === v) {\n throw new Error(\"Setting \" + parent+ \" as parent of \" + v +\n \" would create a cycle\");\n }\n }\n\n this.setNode(parent);\n }\n\n this.setNode(v);\n this._removeFromParentsChildList(v);\n this._parent[v] = parent;\n this._children[parent][v] = true;\n return this;\n }\n\n _removeFromParentsChildList(v) {\n delete this._children[this._parent[v]][v];\n }\n\n /**\n * Gets parent node for node v.\n * Complexity: O(1).\n */\n parent(v) {\n if (this._isCompound) {\n var parent = this._parent[v];\n if (parent !== GRAPH_NODE) {\n return parent;\n }\n }\n }\n\n /**\n * Gets list of direct children of node v.\n * Complexity: O(1).\n */\n children(v = GRAPH_NODE) {\n if (this._isCompound) {\n var children = this._children[v];\n if (children) {\n return Object.keys(children);\n }\n } else if (v === GRAPH_NODE) {\n return this.nodes();\n } else if (this.hasNode(v)) {\n return [];\n }\n }\n\n /**\n * Return all nodes that are predecessors of the specified node or undefined if node v is not in\n * the graph. Behavior is undefined for undirected graphs - use neighbors instead.\n * Complexity: O(|V|).\n */\n predecessors(v) {\n var predsV = this._preds[v];\n if (predsV) {\n return Object.keys(predsV);\n }\n }\n\n /**\n * Return all nodes that are successors of the specified node or undefined if node v is not in\n * the graph. Behavior is undefined for undirected graphs - use neighbors instead.\n * Complexity: O(|V|).\n */\n successors(v) {\n var sucsV = this._sucs[v];\n if (sucsV) {\n return Object.keys(sucsV);\n }\n }\n\n /**\n * Return all nodes that are predecessors or successors of the specified node or undefined if\n * node v is not in the graph.\n * Complexity: O(|V|).\n */\n neighbors(v) {\n var preds = this.predecessors(v);\n if (preds) {\n const union = new Set(preds);\n for (var succ of this.successors(v)) {\n union.add(succ);\n }\n\n return Array.from(union.values());\n }\n }\n\n isLeaf(v) {\n var neighbors;\n if (this.isDirected()) {\n neighbors = this.successors(v);\n } else {\n neighbors = this.neighbors(v);\n }\n return neighbors.length === 0;\n }\n\n /**\n * Creates new graph with nodes filtered via filter. Edges incident to rejected node\n * are also removed. In case of compound graph, if parent is rejected by filter,\n * than all its children are rejected too.\n * Average-case complexity: O(|E|+|V|).\n */\n filterNodes(filter) {\n var copy = new this.constructor({\n directed: this._isDirected,\n multigraph: this._isMultigraph,\n compound: this._isCompound\n });\n\n copy.setGraph(this.graph());\n\n var self = this;\n Object.entries(this._nodes).forEach(function([v, value]) {\n if (filter(v)) {\n copy.setNode(v, value);\n }\n });\n\n Object.values(this._edgeObjs).forEach(function(e) {\n if (copy.hasNode(e.v) && copy.hasNode(e.w)) {\n copy.setEdge(e, self.edge(e));\n }\n });\n\n var parents = {};\n function findParent(v) {\n var parent = self.parent(v);\n if (parent === undefined || copy.hasNode(parent)) {\n parents[v] = parent;\n return parent;\n } else if (parent in parents) {\n return parents[parent];\n } else {\n return findParent(parent);\n }\n }\n\n if (this._isCompound) {\n copy.nodes().forEach(v => copy.setParent(v, findParent(v)));\n }\n\n return copy;\n }\n\n /* === Edge functions ========== */\n\n /**\n * Sets the default edge label or factory function. This label will be\n * assigned as default label in case if no label was specified while setting\n * an edge or this function will be invoked each time when setting an edge\n * with no label specified and returned value * will be used as a label for edge.\n * Complexity: O(1).\n */\n setDefaultEdgeLabel(newDefault) {\n this._defaultEdgeLabelFn = newDefault;\n if (typeof newDefault !== 'function') {\n this._defaultEdgeLabelFn = () => newDefault;\n }\n\n return this;\n }\n\n /**\n * Gets the number of edges in the graph.\n * Complexity: O(1).\n */\n edgeCount() {\n return this._edgeCount;\n }\n\n /**\n * Gets edges of the graph. In case of compound graph subgraphs are not considered.\n * Complexity: O(|E|).\n */\n edges() {\n return Object.values(this._edgeObjs);\n }\n\n /**\n * Establish an edges path over the nodes in nodes list. If some edge is already\n * exists, it will update its label, otherwise it will create an edge between pair\n * of nodes with label provided or default label if no label provided.\n * Complexity: O(|nodes|).\n */\n setPath(vs, value) {\n var self = this;\n var args = arguments;\n vs.reduce(function(v, w) {\n if (args.length > 1) {\n self.setEdge(v, w, value);\n } else {\n self.setEdge(v, w);\n }\n return w;\n });\n return this;\n }\n\n /**\n * Creates or updates the label for the edge (v, w) with the optionally supplied\n * name. If label is supplied it is set as the value for the edge. If label is not\n * supplied and the edge was created by this call then the default edge label will\n * be assigned. The name parameter is only useful with multigraphs.\n */\n setEdge() {\n var v, w, name, value;\n var valueSpecified = false;\n var arg0 = arguments[0];\n\n if (typeof arg0 === \"object\" && arg0 !== null && \"v\" in arg0) {\n v = arg0.v;\n w = arg0.w;\n name = arg0.name;\n if (arguments.length === 2) {\n value = arguments[1];\n valueSpecified = true;\n }\n } else {\n v = arg0;\n w = arguments[1];\n name = arguments[3];\n if (arguments.length > 2) {\n value = arguments[2];\n valueSpecified = true;\n }\n }\n\n v = \"\" + v;\n w = \"\" + w;\n if (name !== undefined) {\n name = \"\" + name;\n }\n\n var e = edgeArgsToId(this._isDirected, v, w, name);\n if (Object.hasOwn(this._edgeLabels, e)) {\n if (valueSpecified) {\n this._edgeLabels[e] = value;\n }\n return this;\n }\n\n if (name !== undefined && !this._isMultigraph) {\n throw new Error(\"Cannot set a named edge when isMultigraph = false\");\n }\n\n // It didn't exist, so we need to create it.\n // First ensure the nodes exist.\n this.setNode(v);\n this.setNode(w);\n\n this._edgeLabels[e] = valueSpecified ? value : this._defaultEdgeLabelFn(v, w, name);\n\n var edgeObj = edgeArgsToObj(this._isDirected, v, w, name);\n // Ensure we add undirected edges in a consistent way.\n v = edgeObj.v;\n w = edgeObj.w;\n\n Object.freeze(edgeObj);\n this._edgeObjs[e] = edgeObj;\n incrementOrInitEntry(this._preds[w], v);\n incrementOrInitEntry(this._sucs[v], w);\n this._in[w][e] = edgeObj;\n this._out[v][e] = edgeObj;\n this._edgeCount++;\n return this;\n }\n\n /**\n * Gets the label for the specified edge.\n * Complexity: O(1).\n */\n edge(v, w, name) {\n var e = (arguments.length === 1\n ? edgeObjToId(this._isDirected, arguments[0])\n : edgeArgsToId(this._isDirected, v, w, name));\n return this._edgeLabels[e];\n }\n\n /**\n * Gets the label for the specified edge and converts it to an object.\n * Complexity: O(1)\n */\n edgeAsObj() {\n const edge = this.edge(...arguments);\n if (typeof edge !== \"object\") {\n return {label: edge};\n }\n\n return edge;\n }\n\n /**\n * Detects whether the graph contains specified edge or not. No subgraphs are considered.\n * Complexity: O(1).\n */\n hasEdge(v, w, name) {\n var e = (arguments.length === 1\n ? edgeObjToId(this._isDirected, arguments[0])\n : edgeArgsToId(this._isDirected, v, w, name));\n return Object.hasOwn(this._edgeLabels, e);\n }\n\n /**\n * Removes the specified edge from the graph. No subgraphs are considered.\n * Complexity: O(1).\n */\n removeEdge(v, w, name) {\n var e = (arguments.length === 1\n ? edgeObjToId(this._isDirected, arguments[0])\n : edgeArgsToId(this._isDirected, v, w, name));\n var edge = this._edgeObjs[e];\n if (edge) {\n v = edge.v;\n w = edge.w;\n delete this._edgeLabels[e];\n delete this._edgeObjs[e];\n decrementOrRemoveEntry(this._preds[w], v);\n decrementOrRemoveEntry(this._sucs[v], w);\n delete this._in[w][e];\n delete this._out[v][e];\n this._edgeCount--;\n }\n return this;\n }\n\n /**\n * Return all edges that point to the node v. Optionally filters those edges down to just those\n * coming from node u. Behavior is undefined for undirected graphs - use nodeEdges instead.\n * Complexity: O(|E|).\n */\n inEdges(v, u) {\n var inV = this._in[v];\n if (inV) {\n var edges = Object.values(inV);\n if (!u) {\n return edges;\n }\n return edges.filter(edge => edge.v === u);\n }\n }\n\n /**\n * Return all edges that are pointed at by node v. Optionally filters those edges down to just\n * those point to w. Behavior is undefined for undirected graphs - use nodeEdges instead.\n * Complexity: O(|E|).\n */\n outEdges(v, w) {\n var outV = this._out[v];\n if (outV) {\n var edges = Object.values(outV);\n if (!w) {\n return edges;\n }\n return edges.filter(edge => edge.w === w);\n }\n }\n\n /**\n * Returns all edges to or from node v regardless of direction. Optionally filters those edges\n * down to just those between nodes v and w regardless of direction.\n * Complexity: O(|E|).\n */\n nodeEdges(v, w) {\n var inEdges = this.inEdges(v, w);\n if (inEdges) {\n return inEdges.concat(this.outEdges(v, w));\n }\n }\n}\n\nfunction incrementOrInitEntry(map, k) {\n if (map[k]) {\n map[k]++;\n } else {\n map[k] = 1;\n }\n}\n\nfunction decrementOrRemoveEntry(map, k) {\n if (!--map[k]) { delete map[k]; }\n}\n\nfunction edgeArgsToId(isDirected, v_, w_, name) {\n var v = \"\" + v_;\n var w = \"\" + w_;\n if (!isDirected && v > w) {\n var tmp = v;\n v = w;\n w = tmp;\n }\n return v + EDGE_KEY_DELIM + w + EDGE_KEY_DELIM +\n (name === undefined ? DEFAULT_EDGE_NAME : name);\n}\n\nfunction edgeArgsToObj(isDirected, v_, w_, name) {\n var v = \"\" + v_;\n var w = \"\" + w_;\n if (!isDirected && v > w) {\n var tmp = v;\n v = w;\n w = tmp;\n }\n var edgeObj = { v: v, w: w };\n if (name) {\n edgeObj.name = name;\n }\n return edgeObj;\n}\n\nfunction edgeObjToId(isDirected, edgeObj) {\n return edgeArgsToId(isDirected, edgeObj.v, edgeObj.w, edgeObj.name);\n}\n\nmodule.exports = Graph;\n", "module.exports = '2.2.5-pre';\n", "// Includes only the \"core\" of graphlib\nmodule.exports = {\n Graph: require(\"./graph\"),\n version: require(\"./version\")\n};\n", "var Graph = require(\"./graph\");\n\nmodule.exports = {\n write: write,\n read: read\n};\n\n/**\n * Creates a JSON representation of the graph that can be serialized to a string with\n * JSON.stringify. The graph can later be restored using json.read.\n */\nfunction write(g) {\n var json = {\n options: {\n directed: g.isDirected(),\n multigraph: g.isMultigraph(),\n compound: g.isCompound()\n },\n nodes: writeNodes(g),\n edges: writeEdges(g)\n };\n\n if (g.graph() !== undefined) {\n json.value = structuredClone(g.graph());\n }\n return json;\n}\n\nfunction writeNodes(g) {\n return g.nodes().map(function(v) {\n var nodeValue = g.node(v);\n var parent = g.parent(v);\n var node = { v: v };\n if (nodeValue !== undefined) {\n node.value = nodeValue;\n }\n if (parent !== undefined) {\n node.parent = parent;\n }\n return node;\n });\n}\n\nfunction writeEdges(g) {\n return g.edges().map(function(e) {\n var edgeValue = g.edge(e);\n var edge = { v: e.v, w: e.w };\n if (e.name !== undefined) {\n edge.name = e.name;\n }\n if (edgeValue !== undefined) {\n edge.value = edgeValue;\n }\n return edge;\n });\n}\n\n/**\n * Takes JSON as input and returns the graph representation.\n *\n * @example\n * var g2 = graphlib.json.read(JSON.parse(str));\n * g2.nodes();\n * // ['a', 'b']\n * g2.edges()\n * // [ { v: 'a', w: 'b' } ]\n */\nfunction read(json) {\n var g = new Graph(json.options).setGraph(json.value);\n json.nodes.forEach(function(entry) {\n g.setNode(entry.v, entry.value);\n if (entry.parent) {\n g.setParent(entry.v, entry.parent);\n }\n });\n json.edges.forEach(function(entry) {\n g.setEdge({ v: entry.v, w: entry.w, name: entry.name }, entry.value);\n });\n return g;\n}\n", "module.exports = components;\n\nfunction components(g) {\n var visited = {};\n var cmpts = [];\n var cmpt;\n\n function dfs(v) {\n if (Object.hasOwn(visited, v)) return;\n visited[v] = true;\n cmpt.push(v);\n g.successors(v).forEach(dfs);\n g.predecessors(v).forEach(dfs);\n }\n\n g.nodes().forEach(function(v) {\n cmpt = [];\n dfs(v);\n if (cmpt.length) {\n cmpts.push(cmpt);\n }\n });\n\n return cmpts;\n}\n", "/**\n * A min-priority queue data structure. This algorithm is derived from Cormen,\n * et al., \"Introduction to Algorithms\". The basic idea of a min-priority\n * queue is that you can efficiently (in O(1) time) get the smallest key in\n * the queue. Adding and removing elements takes O(log n) time. A key can\n * have its priority decreased in O(log n) time.\n */\nclass PriorityQueue {\n _arr = [];\n _keyIndices = {};\n\n /**\n * Returns the number of elements in the queue. Takes `O(1)` time.\n */\n size() {\n return this._arr.length;\n }\n\n /**\n * Returns the keys that are in the queue. Takes `O(n)` time.\n */\n keys() {\n return this._arr.map(function(x) { return x.key; });\n }\n\n /**\n * Returns `true` if **key** is in the queue and `false` if not.\n */\n has(key) {\n return Object.hasOwn(this._keyIndices, key);\n }\n\n /**\n * Returns the priority for **key**. If **key** is not present in the queue\n * then this function returns `undefined`. Takes `O(1)` time.\n *\n * @param {Object} key\n */\n priority(key) {\n var index = this._keyIndices[key];\n if (index !== undefined) {\n return this._arr[index].priority;\n }\n }\n\n /**\n * Returns the key for the minimum element in this queue. If the queue is\n * empty this function throws an Error. Takes `O(1)` time.\n */\n min() {\n if (this.size() === 0) {\n throw new Error(\"Queue underflow\");\n }\n return this._arr[0].key;\n }\n\n /**\n * Inserts a new key into the priority queue. If the key already exists in\n * the queue this function returns `false`; otherwise it will return `true`.\n * Takes `O(n)` time.\n *\n * @param {Object} key the key to add\n * @param {Number} priority the initial priority for the key\n */\n add(key, priority) {\n var keyIndices = this._keyIndices;\n key = String(key);\n if (!Object.hasOwn(keyIndices, key)) {\n var arr = this._arr;\n var index = arr.length;\n keyIndices[key] = index;\n arr.push({key: key, priority: priority});\n this._decrease(index);\n return true;\n }\n return false;\n }\n\n /**\n * Removes and returns the smallest key in the queue. Takes `O(log n)` time.\n */\n removeMin() {\n this._swap(0, this._arr.length - 1);\n var min = this._arr.pop();\n delete this._keyIndices[min.key];\n this._heapify(0);\n return min.key;\n }\n\n /**\n * Decreases the priority for **key** to **priority**. If the new priority is\n * greater than the previous priority, this function will throw an Error.\n *\n * @param {Object} key the key for which to raise priority\n * @param {Number} priority the new priority for the key\n */\n decrease(key, priority) {\n var index = this._keyIndices[key];\n if (priority > this._arr[index].priority) {\n throw new Error(\"New priority is greater than current priority. \" +\n \"Key: \" + key + \" Old: \" + this._arr[index].priority + \" New: \" + priority);\n }\n this._arr[index].priority = priority;\n this._decrease(index);\n }\n\n _heapify(i) {\n var arr = this._arr;\n var l = 2 * i;\n var r = l + 1;\n var largest = i;\n if (l < arr.length) {\n largest = arr[l].priority < arr[largest].priority ? l : largest;\n if (r < arr.length) {\n largest = arr[r].priority < arr[largest].priority ? r : largest;\n }\n if (largest !== i) {\n this._swap(i, largest);\n this._heapify(largest);\n }\n }\n }\n\n _decrease(index) {\n var arr = this._arr;\n var priority = arr[index].priority;\n var parent;\n while (index !== 0) {\n parent = index >> 1;\n if (arr[parent].priority < priority) {\n break;\n }\n this._swap(index, parent);\n index = parent;\n }\n }\n\n _swap(i, j) {\n var arr = this._arr;\n var keyIndices = this._keyIndices;\n var origArrI = arr[i];\n var origArrJ = arr[j];\n arr[i] = origArrJ;\n arr[j] = origArrI;\n keyIndices[origArrJ.key] = i;\n keyIndices[origArrI.key] = j;\n }\n}\n\nmodule.exports = PriorityQueue;\n", "var PriorityQueue = require(\"../data/priority-queue\");\n\nmodule.exports = dijkstra;\n\nvar DEFAULT_WEIGHT_FUNC = () => 1;\n\nfunction dijkstra(g, source, weightFn, edgeFn) {\n return runDijkstra(g, String(source),\n weightFn || DEFAULT_WEIGHT_FUNC,\n edgeFn || function(v) { return g.outEdges(v); });\n}\n\nfunction runDijkstra(g, source, weightFn, edgeFn) {\n var results = {};\n var pq = new PriorityQueue();\n var v, vEntry;\n\n var updateNeighbors = function(edge) {\n var w = edge.v !== v ? edge.v : edge.w;\n var wEntry = results[w];\n var weight = weightFn(edge);\n var distance = vEntry.distance + weight;\n\n if (weight < 0) {\n throw new Error(\"dijkstra does not allow negative edge weights. \" +\n \"Bad edge: \" + edge + \" Weight: \" + weight);\n }\n\n if (distance < wEntry.distance) {\n wEntry.distance = distance;\n wEntry.predecessor = v;\n pq.decrease(w, distance);\n }\n };\n\n g.nodes().forEach(function(v) {\n var distance = v === source ? 0 : Number.POSITIVE_INFINITY;\n results[v] = { distance: distance };\n pq.add(v, distance);\n });\n\n while (pq.size() > 0) {\n v = pq.removeMin();\n vEntry = results[v];\n if (vEntry.distance === Number.POSITIVE_INFINITY) {\n break;\n }\n\n edgeFn(v).forEach(updateNeighbors);\n }\n\n return results;\n}\n", "var dijkstra = require(\"./dijkstra\");\n\nmodule.exports = dijkstraAll;\n\nfunction dijkstraAll(g, weightFunc, edgeFunc) {\n return g.nodes().reduce(function(acc, v) {\n acc[v] = dijkstra(g, v, weightFunc, edgeFunc);\n return acc;\n }, {});\n}\n", "module.exports = tarjan;\n\nfunction tarjan(g) {\n var index = 0;\n var stack = [];\n var visited = {}; // node id -> { onStack, lowlink, index }\n var results = [];\n\n function dfs(v) {\n var entry = visited[v] = {\n onStack: true,\n lowlink: index,\n index: index++\n };\n stack.push(v);\n\n g.successors(v).forEach(function(w) {\n if (!Object.hasOwn(visited, w)) {\n dfs(w);\n entry.lowlink = Math.min(entry.lowlink, visited[w].lowlink);\n } else if (visited[w].onStack) {\n entry.lowlink = Math.min(entry.lowlink, visited[w].index);\n }\n });\n\n if (entry.lowlink === entry.index) {\n var cmpt = [];\n var w;\n do {\n w = stack.pop();\n visited[w].onStack = false;\n cmpt.push(w);\n } while (v !== w);\n results.push(cmpt);\n }\n }\n\n g.nodes().forEach(function(v) {\n if (!Object.hasOwn(visited, v)) {\n dfs(v);\n }\n });\n\n return results;\n}\n", "var tarjan = require(\"./tarjan\");\n\nmodule.exports = findCycles;\n\nfunction findCycles(g) {\n return tarjan(g).filter(function(cmpt) {\n return cmpt.length > 1 || (cmpt.length === 1 && g.hasEdge(cmpt[0], cmpt[0]));\n });\n}\n", "module.exports = floydWarshall;\n\nvar DEFAULT_WEIGHT_FUNC = () => 1;\n\nfunction floydWarshall(g, weightFn, edgeFn) {\n return runFloydWarshall(g,\n weightFn || DEFAULT_WEIGHT_FUNC,\n edgeFn || function(v) { return g.outEdges(v); });\n}\n\nfunction runFloydWarshall(g, weightFn, edgeFn) {\n var results = {};\n var nodes = g.nodes();\n\n nodes.forEach(function(v) {\n results[v] = {};\n results[v][v] = { distance: 0 };\n nodes.forEach(function(w) {\n if (v !== w) {\n results[v][w] = { distance: Number.POSITIVE_INFINITY };\n }\n });\n edgeFn(v).forEach(function(edge) {\n var w = edge.v === v ? edge.w : edge.v;\n var d = weightFn(edge);\n results[v][w] = { distance: d, predecessor: v };\n });\n });\n\n nodes.forEach(function(k) {\n var rowK = results[k];\n nodes.forEach(function(i) {\n var rowI = results[i];\n nodes.forEach(function(j) {\n var ik = rowI[k];\n var kj = rowK[j];\n var ij = rowI[j];\n var altDistance = ik.distance + kj.distance;\n if (altDistance < ij.distance) {\n ij.distance = altDistance;\n ij.predecessor = kj.predecessor;\n }\n });\n });\n });\n\n return results;\n}\n", "function topsort(g) {\n var visited = {};\n var stack = {};\n var results = [];\n\n function visit(node) {\n if (Object.hasOwn(stack, node)) {\n throw new CycleException();\n }\n\n if (!Object.hasOwn(visited, node)) {\n stack[node] = true;\n visited[node] = true;\n g.predecessors(node).forEach(visit);\n delete stack[node];\n results.push(node);\n }\n }\n\n g.sinks().forEach(visit);\n\n if (Object.keys(visited).length !== g.nodeCount()) {\n throw new CycleException();\n }\n\n return results;\n}\n\nclass CycleException extends Error {\n constructor() {\n super(...arguments);\n }\n}\n\nmodule.exports = topsort;\ntopsort.CycleException = CycleException;\n", "var topsort = require(\"./topsort\");\n\nmodule.exports = isAcyclic;\n\nfunction isAcyclic(g) {\n try {\n topsort(g);\n } catch (e) {\n if (e instanceof topsort.CycleException) {\n return false;\n }\n throw e;\n }\n return true;\n}\n", "module.exports = dfs;\n\n/*\n * A helper that preforms a pre- or post-order traversal on the input graph\n * and returns the nodes in the order they were visited. If the graph is\n * undirected then this algorithm will navigate using neighbors. If the graph\n * is directed then this algorithm will navigate using successors.\n *\n * If the order is not \"post\", it will be treated as \"pre\".\n */\nfunction dfs(g, vs, order) {\n if (!Array.isArray(vs)) {\n vs = [vs];\n }\n\n var navigation = g.isDirected() ? v => g.successors(v) : v => g.neighbors(v);\n var orderFunc = order === \"post\" ? postOrderDfs : preOrderDfs;\n\n var acc = [];\n var visited = {};\n vs.forEach(v => {\n if (!g.hasNode(v)) {\n throw new Error(\"Graph does not have node: \" + v);\n }\n\n orderFunc(v, navigation, visited, acc);\n });\n\n return acc;\n}\n\nfunction postOrderDfs(v, navigation, visited, acc) {\n var stack = [[v, false]];\n while (stack.length > 0) {\n var curr = stack.pop();\n if (curr[1]) {\n acc.push(curr[0]);\n } else {\n if (!Object.hasOwn(visited, curr[0])) {\n visited[curr[0]] = true;\n stack.push([curr[0], true]);\n forEachRight(navigation(curr[0]), w => stack.push([w, false]));\n }\n }\n }\n}\n\nfunction preOrderDfs(v, navigation, visited, acc) {\n var stack = [v];\n while (stack.length > 0) {\n var curr = stack.pop();\n if (!Object.hasOwn(visited, curr)) {\n visited[curr] = true;\n acc.push(curr);\n forEachRight(navigation(curr), w => stack.push(w));\n }\n }\n}\n\nfunction forEachRight(array, iteratee) {\n var length = array.length;\n while (length--) {\n iteratee(array[length], length, array);\n }\n\n return array;\n}\n", "var dfs = require(\"./dfs\");\n\nmodule.exports = postorder;\n\nfunction postorder(g, vs) {\n return dfs(g, vs, \"post\");\n}\n", "var dfs = require(\"./dfs\");\n\nmodule.exports = preorder;\n\nfunction preorder(g, vs) {\n return dfs(g, vs, \"pre\");\n}\n", "var Graph = require(\"../graph\");\nvar PriorityQueue = require(\"../data/priority-queue\");\n\nmodule.exports = prim;\n\nfunction prim(g, weightFunc) {\n var result = new Graph();\n var parents = {};\n var pq = new PriorityQueue();\n var v;\n\n function updateNeighbors(edge) {\n var w = edge.v === v ? edge.w : edge.v;\n var pri = pq.priority(w);\n if (pri !== undefined) {\n var edgeWeight = weightFunc(edge);\n if (edgeWeight < pri) {\n parents[w] = v;\n pq.decrease(w, edgeWeight);\n }\n }\n }\n\n if (g.nodeCount() === 0) {\n return result;\n }\n\n g.nodes().forEach(function(v) {\n pq.add(v, Number.POSITIVE_INFINITY);\n result.setNode(v);\n });\n\n // Start from an arbitrary node\n pq.decrease(g.nodes()[0], 0);\n\n var init = false;\n while (pq.size() > 0) {\n v = pq.removeMin();\n if (Object.hasOwn(parents, v)) {\n result.setEdge(v, parents[v]);\n } else if (init) {\n throw new Error(\"Input graph is not connected: \" + g);\n } else {\n init = true;\n }\n\n g.nodeEdges(v).forEach(updateNeighbors);\n }\n\n return result;\n}\n", "module.exports = {\n components: require(\"./components\"),\n dijkstra: require(\"./dijkstra\"),\n dijkstraAll: require(\"./dijkstra-all\"),\n findCycles: require(\"./find-cycles\"),\n floydWarshall: require(\"./floyd-warshall\"),\n isAcyclic: require(\"./is-acyclic\"),\n postorder: require(\"./postorder\"),\n preorder: require(\"./preorder\"),\n prim: require(\"./prim\"),\n tarjan: require(\"./tarjan\"),\n topsort: require(\"./topsort\")\n};\n", "/**\n * Copyright (c) 2014, Chris Pettitt\n * All rights reserved.\n *\n * Redistribution and use in source and binary forms, with or without\n * modification, are permitted provided that the following conditions are met:\n *\n * 1. Redistributions of source code must retain the above copyright notice, this\n * list of conditions and the following disclaimer.\n *\n * 2. Redistributions in binary form must reproduce the above copyright notice,\n * this list of conditions and the following disclaimer in the documentation\n * and/or other materials provided with the distribution.\n *\n * 3. Neither the name of the copyright holder nor the names of its contributors\n * may be used to endorse or promote products derived from this software without\n * specific prior written permission.\n *\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND\n * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED\n * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\n * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE\n * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL\n * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR\n * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER\n * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,\n * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\n * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n */\n\nvar lib = require(\"./lib\");\n\nmodule.exports = {\n Graph: lib.Graph,\n json: require(\"./lib/json\"),\n alg: require(\"./lib/alg\"),\n version: lib.version\n};\n"], + "mapp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AC,EAC1BH,EAAO,QAAQG,EAAGF,EAAQE,CAAC,CAAC,MACvB,IAAIM,EACT,MAAM,IAAI,MAAM,iCAAmCX,CAAC,EAEpDW,EAAO,GAGTX,EAAE,UAAUK,CAAC,EAAE,QAAQC,CAAe,CACxC,CAEA,OAAOJ,CACT,IClDA,IAAAU,GAAAC,EAAA,CAAAC,GAAAC,KAAA,CAAAA,GAAO,QAAU,CACf,WAAY,IACZ,SAAU,IACV,YAAa,IACb,WAAY,IACZ,cAAe,IACf,UAAW,IACX,UAAW,KACX,SAAU,KACV,KAAM,KACN,OAAQ,IACR,QAAS,GACX,ICZA,IAAAC,GAAAC,EAAA,CAAAC,GAAAC,KAAA,CA8BA,IAAIC,GAAM,IAEVD,GAAO,QAAU,CACf,MAAOC,GAAI,MACX,KAAM,IACN,IAAK,KACL,QAASA,GAAI,OACf", + "names": ["require_graph", "__commonJSMin", "exports", "module", "DEFAULT_EDGE_NAME", "GRAPH_NODE", "EDGE_KEY_DELIM", "Graph", "opts", "__publicField", "label", "newDefault", "self", "v", "vs", "value", "args", "removeEdge", "e", "child", "parent", "ancestor", "children", "predsV", "sucsV", "preds", "union", "succ", "neighbors", "filter", "copy", "parents", "findParent", "w", "name", "valueSpecified", "arg0", "edgeArgsToId", "edgeObj", "edgeArgsToObj", "incrementOrInitEntry", "edgeObjToId", "edge", "decrementOrRemoveEntry", "u", "inV", "edges", "outV", "inEdges", "map", "k", "isDirected", "v_", "w_", "tmp", "require_version", "__commonJSMin", "exports", "module", "require_lib", "__commonJSMin", "exports", "module", "require_json", "__commonJSMin", "exports", "module", "Graph", "write", "read", "g", "json", "writeNodes", "writeEdges", "v", "nodeValue", "parent", "node", "edgeValue", "edge", "entry", "require_components", "__commonJSMin", "exports", "module", "components", "g", "visited", "cmpts", "cmpt", "dfs", "v", "require_priority_queue", "__commonJSMin", "exports", "module", "PriorityQueue", "__publicField", "x", "key", "index", "priority", "keyIndices", "arr", "min", "i", "l", "r", "largest", "parent", "j", "origArrI", "origArrJ", "require_dijkstra", "__commonJSMin", "exports", "module", "PriorityQueue", "dijkstra", "DEFAULT_WEIGHT_FUNC", "g", "source", "weightFn", "edgeFn", "runDijkstra", "v", "results", "pq", "vEntry", "updateNeighbors", "edge", "w", "wEntry", "weight", "distance", "require_dijkstra_all", "__commonJSMin", "exports", "module", "dijkstra", "dijkstraAll", "g", "weightFunc", "edgeFunc", "acc", "v", "require_tarjan", "__commonJSMin", "exports", "module", "tarjan", "g", "index", "stack", "visited", "results", "dfs", "v", "entry", "w", "cmpt", "require_find_cycles", "__commonJSMin", "exports", "module", "tarjan", "findCycles", "g", "cmpt", "require_floyd_warshall", "__commonJSMin", "exports", "module", "floydWarshall", "DEFAULT_WEIGHT_FUNC", "g", "weightFn", "edgeFn", "runFloydWarshall", "v", "results", "nodes", "w", "edge", "d", "k", "rowK", "i", "rowI", "j", "ik", "kj", "ij", "altDistance", "require_topsort", "__commonJSMin", "exports", "module", "topsort", "g", "visited", "stack", "results", "visit", "node", "CycleException", "require_is_acyclic", "__commonJSMin", "exports", "module", "topsort", "isAcyclic", "g", "require_dfs", "__commonJSMin", "exports", "module", "dfs", "g", "vs", "order", "navigation", "v", "orderFunc", "postOrderDfs", "preOrderDfs", "acc", "visited", "stack", "curr", "forEachRight", "w", "array", "iteratee", "length", "require_postorder", "__commonJSMin", "exports", "module", "dfs", "postorder", "g", "vs", "require_preorder", "__commonJSMin", "exports", "module", "dfs", "preorder", "g", "vs", "require_prim", "__commonJSMin", "exports", "module", "Graph", "PriorityQueue", "prim", "g", "weightFunc", "result", "parents", "pq", "v", "updateNeighbors", "edge", "w", "pri", "edgeWeight", "init", "require_alg", "__commonJSMin", "exports", "module", "require_index", "__commonJSMin", "exports", "module", "lib"] +} diff --git a/dist/dagre.js b/dist/dagre.js new file mode 100644 index 00000000..509dc0d1 --- /dev/null +++ b/dist/dagre.js @@ -0,0 +1,1241 @@ +var dagre = (() => { + var __defProp = Object.defineProperty; + var __getOwnPropNames = Object.getOwnPropertyNames; + var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value; + var __commonJS = (cb, mod) => function __require() { + return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports; + }; + var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value); + + // lib/graph.js + var require_graph = __commonJS({ + "lib/graph.js"(exports, module) { + "use strict"; + var DEFAULT_EDGE_NAME = "\0"; + var GRAPH_NODE = "\0"; + var EDGE_KEY_DELIM = ""; + var Graph = class { + constructor(opts) { + __publicField(this, "_isDirected", true); + __publicField(this, "_isMultigraph", false); + __publicField(this, "_isCompound", false); + // Label for the graph itself + __publicField(this, "_label"); + // Defaults to be set when creating a new node + __publicField(this, "_defaultNodeLabelFn", () => void 0); + // Defaults to be set when creating a new edge + __publicField(this, "_defaultEdgeLabelFn", () => void 0); + // v -> label + __publicField(this, "_nodes", {}); + // v -> edgeObj + __publicField(this, "_in", {}); + // u -> v -> Number + __publicField(this, "_preds", {}); + // v -> edgeObj + __publicField(this, "_out", {}); + // v -> w -> Number + __publicField(this, "_sucs", {}); + // e -> edgeObj + __publicField(this, "_edgeObjs", {}); + // e -> label + __publicField(this, "_edgeLabels", {}); + /* Number of nodes in the graph. Should only be changed by the implementation. */ + __publicField(this, "_nodeCount", 0); + /* Number of edges in the graph. Should only be changed by the implementation. */ + __publicField(this, "_edgeCount", 0); + __publicField(this, "_parent"); + __publicField(this, "_children"); + if (opts) { + this._isDirected = Object.hasOwn(opts, "directed") ? opts.directed : true; + this._isMultigraph = Object.hasOwn(opts, "multigraph") ? opts.multigraph : false; + this._isCompound = Object.hasOwn(opts, "compound") ? opts.compound : false; + } + if (this._isCompound) { + this._parent = {}; + this._children = {}; + this._children[GRAPH_NODE] = {}; + } + } + /* === Graph functions ========= */ + /** + * Whether graph was created with 'directed' flag set to true or not. + */ + isDirected() { + return this._isDirected; + } + /** + * Whether graph was created with 'multigraph' flag set to true or not. + */ + isMultigraph() { + return this._isMultigraph; + } + /** + * Whether graph was created with 'compound' flag set to true or not. + */ + isCompound() { + return this._isCompound; + } + /** + * Sets the label of the graph. + */ + setGraph(label) { + this._label = label; + return this; + } + /** + * Gets the graph label. + */ + graph() { + return this._label; + } + /* === Node functions ========== */ + /** + * Sets the default node label. If newDefault is a function, it will be + * invoked ach time when setting a label for a node. Otherwise, this label + * will be assigned as default label in case if no label was specified while + * setting a node. + * Complexity: O(1). + */ + setDefaultNodeLabel(newDefault) { + this._defaultNodeLabelFn = newDefault; + if (typeof newDefault !== "function") { + this._defaultNodeLabelFn = () => newDefault; + } + return this; + } + /** + * Gets the number of nodes in the graph. + * Complexity: O(1). + */ + nodeCount() { + return this._nodeCount; + } + /** + * Gets all nodes of the graph. Note, the in case of compound graph subnodes are + * not included in list. + * Complexity: O(1). + */ + nodes() { + return Object.keys(this._nodes); + } + /** + * Gets list of nodes without in-edges. + * Complexity: O(|V|). + */ + sources() { + var self = this; + return this.nodes().filter((v) => Object.keys(self._in[v]).length === 0); + } + /** + * Gets list of nodes without out-edges. + * Complexity: O(|V|). + */ + sinks() { + var self = this; + return this.nodes().filter((v) => Object.keys(self._out[v]).length === 0); + } + /** + * Invokes setNode method for each node in names list. + * Complexity: O(|names|). + */ + setNodes(vs, value) { + var args = arguments; + var self = this; + vs.forEach(function(v) { + if (args.length > 1) { + self.setNode(v, value); + } else { + self.setNode(v); + } + }); + return this; + } + /** + * Creates or updates the value for the node v in the graph. If label is supplied + * it is set as the value for the node. If label is not supplied and the node was + * created by this call then the default node label will be assigned. + * Complexity: O(1). + */ + setNode(v, value) { + if (Object.hasOwn(this._nodes, v)) { + if (arguments.length > 1) { + this._nodes[v] = value; + } + return this; + } + this._nodes[v] = arguments.length > 1 ? value : this._defaultNodeLabelFn(v); + if (this._isCompound) { + this._parent[v] = GRAPH_NODE; + this._children[v] = {}; + this._children[GRAPH_NODE][v] = true; + } + this._in[v] = {}; + this._preds[v] = {}; + this._out[v] = {}; + this._sucs[v] = {}; + ++this._nodeCount; + return this; + } + /** + * Gets the label of node with specified name. + * Complexity: O(|V|). + */ + node(v) { + return this._nodes[v]; + } + /** + * Detects whether graph has a node with specified name or not. + */ + hasNode(v) { + return Object.hasOwn(this._nodes, v); + } + /** + * Remove the node with the name from the graph or do nothing if the node is not in + * the graph. If the node was removed this function also removes any incident + * edges. + * Complexity: O(1). + */ + removeNode(v) { + var self = this; + if (Object.hasOwn(this._nodes, v)) { + var removeEdge = (e) => self.removeEdge(self._edgeObjs[e]); + delete this._nodes[v]; + if (this._isCompound) { + this._removeFromParentsChildList(v); + delete this._parent[v]; + this.children(v).forEach(function(child) { + self.setParent(child); + }); + delete this._children[v]; + } + Object.keys(this._in[v]).forEach(removeEdge); + delete this._in[v]; + delete this._preds[v]; + Object.keys(this._out[v]).forEach(removeEdge); + delete this._out[v]; + delete this._sucs[v]; + --this._nodeCount; + } + return this; + } + /** + * Sets node p as a parent for node v if it is defined, or removes the + * parent for v if p is undefined. Method throws an exception in case of + * invoking it in context of noncompound graph. + * Average-case complexity: O(1). + */ + setParent(v, parent) { + if (!this._isCompound) { + throw new Error("Cannot set parent in a non-compound graph"); + } + if (parent === void 0) { + parent = GRAPH_NODE; + } else { + parent += ""; + for (var ancestor = parent; ancestor !== void 0; ancestor = this.parent(ancestor)) { + if (ancestor === v) { + throw new Error("Setting " + parent + " as parent of " + v + " would create a cycle"); + } + } + this.setNode(parent); + } + this.setNode(v); + this._removeFromParentsChildList(v); + this._parent[v] = parent; + this._children[parent][v] = true; + return this; + } + _removeFromParentsChildList(v) { + delete this._children[this._parent[v]][v]; + } + /** + * Gets parent node for node v. + * Complexity: O(1). + */ + parent(v) { + if (this._isCompound) { + var parent = this._parent[v]; + if (parent !== GRAPH_NODE) { + return parent; + } + } + } + /** + * Gets list of direct children of node v. + * Complexity: O(1). + */ + children(v = GRAPH_NODE) { + if (this._isCompound) { + var children = this._children[v]; + if (children) { + return Object.keys(children); + } + } else if (v === GRAPH_NODE) { + return this.nodes(); + } else if (this.hasNode(v)) { + return []; + } + } + /** + * Return all nodes that are predecessors of the specified node or undefined if node v is not in + * the graph. Behavior is undefined for undirected graphs - use neighbors instead. + * Complexity: O(|V|). + */ + predecessors(v) { + var predsV = this._preds[v]; + if (predsV) { + return Object.keys(predsV); + } + } + /** + * Return all nodes that are successors of the specified node or undefined if node v is not in + * the graph. Behavior is undefined for undirected graphs - use neighbors instead. + * Complexity: O(|V|). + */ + successors(v) { + var sucsV = this._sucs[v]; + if (sucsV) { + return Object.keys(sucsV); + } + } + /** + * Return all nodes that are predecessors or successors of the specified node or undefined if + * node v is not in the graph. + * Complexity: O(|V|). + */ + neighbors(v) { + var preds = this.predecessors(v); + if (preds) { + const union = new Set(preds); + for (var succ of this.successors(v)) { + union.add(succ); + } + return Array.from(union.values()); + } + } + isLeaf(v) { + var neighbors; + if (this.isDirected()) { + neighbors = this.successors(v); + } else { + neighbors = this.neighbors(v); + } + return neighbors.length === 0; + } + /** + * Creates new graph with nodes filtered via filter. Edges incident to rejected node + * are also removed. In case of compound graph, if parent is rejected by filter, + * than all its children are rejected too. + * Average-case complexity: O(|E|+|V|). + */ + filterNodes(filter) { + var copy = new this.constructor({ + directed: this._isDirected, + multigraph: this._isMultigraph, + compound: this._isCompound + }); + copy.setGraph(this.graph()); + var self = this; + Object.entries(this._nodes).forEach(function([v, value]) { + if (filter(v)) { + copy.setNode(v, value); + } + }); + Object.values(this._edgeObjs).forEach(function(e) { + if (copy.hasNode(e.v) && copy.hasNode(e.w)) { + copy.setEdge(e, self.edge(e)); + } + }); + var parents = {}; + function findParent(v) { + var parent = self.parent(v); + if (parent === void 0 || copy.hasNode(parent)) { + parents[v] = parent; + return parent; + } else if (parent in parents) { + return parents[parent]; + } else { + return findParent(parent); + } + } + if (this._isCompound) { + copy.nodes().forEach((v) => copy.setParent(v, findParent(v))); + } + return copy; + } + /* === Edge functions ========== */ + /** + * Sets the default edge label or factory function. This label will be + * assigned as default label in case if no label was specified while setting + * an edge or this function will be invoked each time when setting an edge + * with no label specified and returned value * will be used as a label for edge. + * Complexity: O(1). + */ + setDefaultEdgeLabel(newDefault) { + this._defaultEdgeLabelFn = newDefault; + if (typeof newDefault !== "function") { + this._defaultEdgeLabelFn = () => newDefault; + } + return this; + } + /** + * Gets the number of edges in the graph. + * Complexity: O(1). + */ + edgeCount() { + return this._edgeCount; + } + /** + * Gets edges of the graph. In case of compound graph subgraphs are not considered. + * Complexity: O(|E|). + */ + edges() { + return Object.values(this._edgeObjs); + } + /** + * Establish an edges path over the nodes in nodes list. If some edge is already + * exists, it will update its label, otherwise it will create an edge between pair + * of nodes with label provided or default label if no label provided. + * Complexity: O(|nodes|). + */ + setPath(vs, value) { + var self = this; + var args = arguments; + vs.reduce(function(v, w) { + if (args.length > 1) { + self.setEdge(v, w, value); + } else { + self.setEdge(v, w); + } + return w; + }); + return this; + } + /** + * Creates or updates the label for the edge (v, w) with the optionally supplied + * name. If label is supplied it is set as the value for the edge. If label is not + * supplied and the edge was created by this call then the default edge label will + * be assigned. The name parameter is only useful with multigraphs. + */ + setEdge() { + var v, w, name, value; + var valueSpecified = false; + var arg0 = arguments[0]; + if (typeof arg0 === "object" && arg0 !== null && "v" in arg0) { + v = arg0.v; + w = arg0.w; + name = arg0.name; + if (arguments.length === 2) { + value = arguments[1]; + valueSpecified = true; + } + } else { + v = arg0; + w = arguments[1]; + name = arguments[3]; + if (arguments.length > 2) { + value = arguments[2]; + valueSpecified = true; + } + } + v = "" + v; + w = "" + w; + if (name !== void 0) { + name = "" + name; + } + var e = edgeArgsToId(this._isDirected, v, w, name); + if (Object.hasOwn(this._edgeLabels, e)) { + if (valueSpecified) { + this._edgeLabels[e] = value; + } + return this; + } + if (name !== void 0 && !this._isMultigraph) { + throw new Error("Cannot set a named edge when isMultigraph = false"); + } + this.setNode(v); + this.setNode(w); + this._edgeLabels[e] = valueSpecified ? value : this._defaultEdgeLabelFn(v, w, name); + var edgeObj = edgeArgsToObj(this._isDirected, v, w, name); + v = edgeObj.v; + w = edgeObj.w; + Object.freeze(edgeObj); + this._edgeObjs[e] = edgeObj; + incrementOrInitEntry(this._preds[w], v); + incrementOrInitEntry(this._sucs[v], w); + this._in[w][e] = edgeObj; + this._out[v][e] = edgeObj; + this._edgeCount++; + return this; + } + /** + * Gets the label for the specified edge. + * Complexity: O(1). + */ + edge(v, w, name) { + var e = arguments.length === 1 ? edgeObjToId(this._isDirected, arguments[0]) : edgeArgsToId(this._isDirected, v, w, name); + return this._edgeLabels[e]; + } + /** + * Gets the label for the specified edge and converts it to an object. + * Complexity: O(1) + */ + edgeAsObj() { + const edge = this.edge(...arguments); + if (typeof edge !== "object") { + return { label: edge }; + } + return edge; + } + /** + * Detects whether the graph contains specified edge or not. No subgraphs are considered. + * Complexity: O(1). + */ + hasEdge(v, w, name) { + var e = arguments.length === 1 ? edgeObjToId(this._isDirected, arguments[0]) : edgeArgsToId(this._isDirected, v, w, name); + return Object.hasOwn(this._edgeLabels, e); + } + /** + * Removes the specified edge from the graph. No subgraphs are considered. + * Complexity: O(1). + */ + removeEdge(v, w, name) { + var e = arguments.length === 1 ? edgeObjToId(this._isDirected, arguments[0]) : edgeArgsToId(this._isDirected, v, w, name); + var edge = this._edgeObjs[e]; + if (edge) { + v = edge.v; + w = edge.w; + delete this._edgeLabels[e]; + delete this._edgeObjs[e]; + decrementOrRemoveEntry(this._preds[w], v); + decrementOrRemoveEntry(this._sucs[v], w); + delete this._in[w][e]; + delete this._out[v][e]; + this._edgeCount--; + } + return this; + } + /** + * Return all edges that point to the node v. Optionally filters those edges down to just those + * coming from node u. Behavior is undefined for undirected graphs - use nodeEdges instead. + * Complexity: O(|E|). + */ + inEdges(v, u) { + var inV = this._in[v]; + if (inV) { + var edges = Object.values(inV); + if (!u) { + return edges; + } + return edges.filter((edge) => edge.v === u); + } + } + /** + * Return all edges that are pointed at by node v. Optionally filters those edges down to just + * those point to w. Behavior is undefined for undirected graphs - use nodeEdges instead. + * Complexity: O(|E|). + */ + outEdges(v, w) { + var outV = this._out[v]; + if (outV) { + var edges = Object.values(outV); + if (!w) { + return edges; + } + return edges.filter((edge) => edge.w === w); + } + } + /** + * Returns all edges to or from node v regardless of direction. Optionally filters those edges + * down to just those between nodes v and w regardless of direction. + * Complexity: O(|E|). + */ + nodeEdges(v, w) { + var inEdges = this.inEdges(v, w); + if (inEdges) { + return inEdges.concat(this.outEdges(v, w)); + } + } + }; + function incrementOrInitEntry(map, k) { + if (map[k]) { + map[k]++; + } else { + map[k] = 1; + } + } + function decrementOrRemoveEntry(map, k) { + if (!--map[k]) { + delete map[k]; + } + } + function edgeArgsToId(isDirected, v_, w_, name) { + var v = "" + v_; + var w = "" + w_; + if (!isDirected && v > w) { + var tmp = v; + v = w; + w = tmp; + } + return v + EDGE_KEY_DELIM + w + EDGE_KEY_DELIM + (name === void 0 ? DEFAULT_EDGE_NAME : name); + } + function edgeArgsToObj(isDirected, v_, w_, name) { + var v = "" + v_; + var w = "" + w_; + if (!isDirected && v > w) { + var tmp = v; + v = w; + w = tmp; + } + var edgeObj = { v, w }; + if (name) { + edgeObj.name = name; + } + return edgeObj; + } + function edgeObjToId(isDirected, edgeObj) { + return edgeArgsToId(isDirected, edgeObj.v, edgeObj.w, edgeObj.name); + } + module.exports = Graph; + } + }); + + // lib/version.js + var require_version = __commonJS({ + "lib/version.js"(exports, module) { + module.exports = "2.2.5-pre"; + } + }); + + // lib/index.js + var require_lib = __commonJS({ + "lib/index.js"(exports, module) { + module.exports = { + Graph: require_graph(), + version: require_version() + }; + } + }); + + // lib/json.js + var require_json = __commonJS({ + "lib/json.js"(exports, module) { + var Graph = require_graph(); + module.exports = { + write, + read + }; + function write(g) { + var json = { + options: { + directed: g.isDirected(), + multigraph: g.isMultigraph(), + compound: g.isCompound() + }, + nodes: writeNodes(g), + edges: writeEdges(g) + }; + if (g.graph() !== void 0) { + json.value = structuredClone(g.graph()); + } + return json; + } + function writeNodes(g) { + return g.nodes().map(function(v) { + var nodeValue = g.node(v); + var parent = g.parent(v); + var node = { v }; + if (nodeValue !== void 0) { + node.value = nodeValue; + } + if (parent !== void 0) { + node.parent = parent; + } + return node; + }); + } + function writeEdges(g) { + return g.edges().map(function(e) { + var edgeValue = g.edge(e); + var edge = { v: e.v, w: e.w }; + if (e.name !== void 0) { + edge.name = e.name; + } + if (edgeValue !== void 0) { + edge.value = edgeValue; + } + return edge; + }); + } + function read(json) { + var g = new Graph(json.options).setGraph(json.value); + json.nodes.forEach(function(entry) { + g.setNode(entry.v, entry.value); + if (entry.parent) { + g.setParent(entry.v, entry.parent); + } + }); + json.edges.forEach(function(entry) { + g.setEdge({ v: entry.v, w: entry.w, name: entry.name }, entry.value); + }); + return g; + } + } + }); + + // lib/alg/components.js + var require_components = __commonJS({ + "lib/alg/components.js"(exports, module) { + module.exports = components; + function components(g) { + var visited = {}; + var cmpts = []; + var cmpt; + function dfs(v) { + if (Object.hasOwn(visited, v)) return; + visited[v] = true; + cmpt.push(v); + g.successors(v).forEach(dfs); + g.predecessors(v).forEach(dfs); + } + g.nodes().forEach(function(v) { + cmpt = []; + dfs(v); + if (cmpt.length) { + cmpts.push(cmpt); + } + }); + return cmpts; + } + } + }); + + // lib/data/priority-queue.js + var require_priority_queue = __commonJS({ + "lib/data/priority-queue.js"(exports, module) { + var PriorityQueue = class { + constructor() { + __publicField(this, "_arr", []); + __publicField(this, "_keyIndices", {}); + } + /** + * Returns the number of elements in the queue. Takes `O(1)` time. + */ + size() { + return this._arr.length; + } + /** + * Returns the keys that are in the queue. Takes `O(n)` time. + */ + keys() { + return this._arr.map(function(x) { + return x.key; + }); + } + /** + * Returns `true` if **key** is in the queue and `false` if not. + */ + has(key) { + return Object.hasOwn(this._keyIndices, key); + } + /** + * Returns the priority for **key**. If **key** is not present in the queue + * then this function returns `undefined`. Takes `O(1)` time. + * + * @param {Object} key + */ + priority(key) { + var index = this._keyIndices[key]; + if (index !== void 0) { + return this._arr[index].priority; + } + } + /** + * Returns the key for the minimum element in this queue. If the queue is + * empty this function throws an Error. Takes `O(1)` time. + */ + min() { + if (this.size() === 0) { + throw new Error("Queue underflow"); + } + return this._arr[0].key; + } + /** + * Inserts a new key into the priority queue. If the key already exists in + * the queue this function returns `false`; otherwise it will return `true`. + * Takes `O(n)` time. + * + * @param {Object} key the key to add + * @param {Number} priority the initial priority for the key + */ + add(key, priority) { + var keyIndices = this._keyIndices; + key = String(key); + if (!Object.hasOwn(keyIndices, key)) { + var arr = this._arr; + var index = arr.length; + keyIndices[key] = index; + arr.push({ key, priority }); + this._decrease(index); + return true; + } + return false; + } + /** + * Removes and returns the smallest key in the queue. Takes `O(log n)` time. + */ + removeMin() { + this._swap(0, this._arr.length - 1); + var min = this._arr.pop(); + delete this._keyIndices[min.key]; + this._heapify(0); + return min.key; + } + /** + * Decreases the priority for **key** to **priority**. If the new priority is + * greater than the previous priority, this function will throw an Error. + * + * @param {Object} key the key for which to raise priority + * @param {Number} priority the new priority for the key + */ + decrease(key, priority) { + var index = this._keyIndices[key]; + if (priority > this._arr[index].priority) { + throw new Error("New priority is greater than current priority. Key: " + key + " Old: " + this._arr[index].priority + " New: " + priority); + } + this._arr[index].priority = priority; + this._decrease(index); + } + _heapify(i) { + var arr = this._arr; + var l = 2 * i; + var r = l + 1; + var largest = i; + if (l < arr.length) { + largest = arr[l].priority < arr[largest].priority ? l : largest; + if (r < arr.length) { + largest = arr[r].priority < arr[largest].priority ? r : largest; + } + if (largest !== i) { + this._swap(i, largest); + this._heapify(largest); + } + } + } + _decrease(index) { + var arr = this._arr; + var priority = arr[index].priority; + var parent; + while (index !== 0) { + parent = index >> 1; + if (arr[parent].priority < priority) { + break; + } + this._swap(index, parent); + index = parent; + } + } + _swap(i, j) { + var arr = this._arr; + var keyIndices = this._keyIndices; + var origArrI = arr[i]; + var origArrJ = arr[j]; + arr[i] = origArrJ; + arr[j] = origArrI; + keyIndices[origArrJ.key] = i; + keyIndices[origArrI.key] = j; + } + }; + module.exports = PriorityQueue; + } + }); + + // lib/alg/dijkstra.js + var require_dijkstra = __commonJS({ + "lib/alg/dijkstra.js"(exports, module) { + var PriorityQueue = require_priority_queue(); + module.exports = dijkstra; + var DEFAULT_WEIGHT_FUNC = () => 1; + function dijkstra(g, source, weightFn, edgeFn) { + return runDijkstra( + g, + String(source), + weightFn || DEFAULT_WEIGHT_FUNC, + edgeFn || function(v) { + return g.outEdges(v); + } + ); + } + function runDijkstra(g, source, weightFn, edgeFn) { + var results = {}; + var pq = new PriorityQueue(); + var v, vEntry; + var updateNeighbors = function(edge) { + var w = edge.v !== v ? edge.v : edge.w; + var wEntry = results[w]; + var weight = weightFn(edge); + var distance = vEntry.distance + weight; + if (weight < 0) { + throw new Error("dijkstra does not allow negative edge weights. Bad edge: " + edge + " Weight: " + weight); + } + if (distance < wEntry.distance) { + wEntry.distance = distance; + wEntry.predecessor = v; + pq.decrease(w, distance); + } + }; + g.nodes().forEach(function(v2) { + var distance = v2 === source ? 0 : Number.POSITIVE_INFINITY; + results[v2] = { distance }; + pq.add(v2, distance); + }); + while (pq.size() > 0) { + v = pq.removeMin(); + vEntry = results[v]; + if (vEntry.distance === Number.POSITIVE_INFINITY) { + break; + } + edgeFn(v).forEach(updateNeighbors); + } + return results; + } + } + }); + + // lib/alg/dijkstra-all.js + var require_dijkstra_all = __commonJS({ + "lib/alg/dijkstra-all.js"(exports, module) { + var dijkstra = require_dijkstra(); + module.exports = dijkstraAll; + function dijkstraAll(g, weightFunc, edgeFunc) { + return g.nodes().reduce(function(acc, v) { + acc[v] = dijkstra(g, v, weightFunc, edgeFunc); + return acc; + }, {}); + } + } + }); + + // lib/alg/tarjan.js + var require_tarjan = __commonJS({ + "lib/alg/tarjan.js"(exports, module) { + module.exports = tarjan; + function tarjan(g) { + var index = 0; + var stack = []; + var visited = {}; + var results = []; + function dfs(v) { + var entry = visited[v] = { + onStack: true, + lowlink: index, + index: index++ + }; + stack.push(v); + g.successors(v).forEach(function(w2) { + if (!Object.hasOwn(visited, w2)) { + dfs(w2); + entry.lowlink = Math.min(entry.lowlink, visited[w2].lowlink); + } else if (visited[w2].onStack) { + entry.lowlink = Math.min(entry.lowlink, visited[w2].index); + } + }); + if (entry.lowlink === entry.index) { + var cmpt = []; + var w; + do { + w = stack.pop(); + visited[w].onStack = false; + cmpt.push(w); + } while (v !== w); + results.push(cmpt); + } + } + g.nodes().forEach(function(v) { + if (!Object.hasOwn(visited, v)) { + dfs(v); + } + }); + return results; + } + } + }); + + // lib/alg/find-cycles.js + var require_find_cycles = __commonJS({ + "lib/alg/find-cycles.js"(exports, module) { + var tarjan = require_tarjan(); + module.exports = findCycles; + function findCycles(g) { + return tarjan(g).filter(function(cmpt) { + return cmpt.length > 1 || cmpt.length === 1 && g.hasEdge(cmpt[0], cmpt[0]); + }); + } + } + }); + + // lib/alg/floyd-warshall.js + var require_floyd_warshall = __commonJS({ + "lib/alg/floyd-warshall.js"(exports, module) { + module.exports = floydWarshall; + var DEFAULT_WEIGHT_FUNC = () => 1; + function floydWarshall(g, weightFn, edgeFn) { + return runFloydWarshall( + g, + weightFn || DEFAULT_WEIGHT_FUNC, + edgeFn || function(v) { + return g.outEdges(v); + } + ); + } + function runFloydWarshall(g, weightFn, edgeFn) { + var results = {}; + var nodes = g.nodes(); + nodes.forEach(function(v) { + results[v] = {}; + results[v][v] = { distance: 0 }; + nodes.forEach(function(w) { + if (v !== w) { + results[v][w] = { distance: Number.POSITIVE_INFINITY }; + } + }); + edgeFn(v).forEach(function(edge) { + var w = edge.v === v ? edge.w : edge.v; + var d = weightFn(edge); + results[v][w] = { distance: d, predecessor: v }; + }); + }); + nodes.forEach(function(k) { + var rowK = results[k]; + nodes.forEach(function(i) { + var rowI = results[i]; + nodes.forEach(function(j) { + var ik = rowI[k]; + var kj = rowK[j]; + var ij = rowI[j]; + var altDistance = ik.distance + kj.distance; + if (altDistance < ij.distance) { + ij.distance = altDistance; + ij.predecessor = kj.predecessor; + } + }); + }); + }); + return results; + } + } + }); + + // lib/alg/topsort.js + var require_topsort = __commonJS({ + "lib/alg/topsort.js"(exports, module) { + function topsort(g) { + var visited = {}; + var stack = {}; + var results = []; + function visit(node) { + if (Object.hasOwn(stack, node)) { + throw new CycleException(); + } + if (!Object.hasOwn(visited, node)) { + stack[node] = true; + visited[node] = true; + g.predecessors(node).forEach(visit); + delete stack[node]; + results.push(node); + } + } + g.sinks().forEach(visit); + if (Object.keys(visited).length !== g.nodeCount()) { + throw new CycleException(); + } + return results; + } + var CycleException = class extends Error { + constructor() { + super(...arguments); + } + }; + module.exports = topsort; + topsort.CycleException = CycleException; + } + }); + + // lib/alg/is-acyclic.js + var require_is_acyclic = __commonJS({ + "lib/alg/is-acyclic.js"(exports, module) { + var topsort = require_topsort(); + module.exports = isAcyclic; + function isAcyclic(g) { + try { + topsort(g); + } catch (e) { + if (e instanceof topsort.CycleException) { + return false; + } + throw e; + } + return true; + } + } + }); + + // lib/alg/dfs.js + var require_dfs = __commonJS({ + "lib/alg/dfs.js"(exports, module) { + module.exports = dfs; + function dfs(g, vs, order) { + if (!Array.isArray(vs)) { + vs = [vs]; + } + var navigation = g.isDirected() ? (v) => g.successors(v) : (v) => g.neighbors(v); + var orderFunc = order === "post" ? postOrderDfs : preOrderDfs; + var acc = []; + var visited = {}; + vs.forEach((v) => { + if (!g.hasNode(v)) { + throw new Error("Graph does not have node: " + v); + } + orderFunc(v, navigation, visited, acc); + }); + return acc; + } + function postOrderDfs(v, navigation, visited, acc) { + var stack = [[v, false]]; + while (stack.length > 0) { + var curr = stack.pop(); + if (curr[1]) { + acc.push(curr[0]); + } else { + if (!Object.hasOwn(visited, curr[0])) { + visited[curr[0]] = true; + stack.push([curr[0], true]); + forEachRight(navigation(curr[0]), (w) => stack.push([w, false])); + } + } + } + } + function preOrderDfs(v, navigation, visited, acc) { + var stack = [v]; + while (stack.length > 0) { + var curr = stack.pop(); + if (!Object.hasOwn(visited, curr)) { + visited[curr] = true; + acc.push(curr); + forEachRight(navigation(curr), (w) => stack.push(w)); + } + } + } + function forEachRight(array, iteratee) { + var length = array.length; + while (length--) { + iteratee(array[length], length, array); + } + return array; + } + } + }); + + // lib/alg/postorder.js + var require_postorder = __commonJS({ + "lib/alg/postorder.js"(exports, module) { + var dfs = require_dfs(); + module.exports = postorder; + function postorder(g, vs) { + return dfs(g, vs, "post"); + } + } + }); + + // lib/alg/preorder.js + var require_preorder = __commonJS({ + "lib/alg/preorder.js"(exports, module) { + var dfs = require_dfs(); + module.exports = preorder; + function preorder(g, vs) { + return dfs(g, vs, "pre"); + } + } + }); + + // lib/alg/prim.js + var require_prim = __commonJS({ + "lib/alg/prim.js"(exports, module) { + var Graph = require_graph(); + var PriorityQueue = require_priority_queue(); + module.exports = prim; + function prim(g, weightFunc) { + var result = new Graph(); + var parents = {}; + var pq = new PriorityQueue(); + var v; + function updateNeighbors(edge) { + var w = edge.v === v ? edge.w : edge.v; + var pri = pq.priority(w); + if (pri !== void 0) { + var edgeWeight = weightFunc(edge); + if (edgeWeight < pri) { + parents[w] = v; + pq.decrease(w, edgeWeight); + } + } + } + if (g.nodeCount() === 0) { + return result; + } + g.nodes().forEach(function(v2) { + pq.add(v2, Number.POSITIVE_INFINITY); + result.setNode(v2); + }); + pq.decrease(g.nodes()[0], 0); + var init = false; + while (pq.size() > 0) { + v = pq.removeMin(); + if (Object.hasOwn(parents, v)) { + result.setEdge(v, parents[v]); + } else if (init) { + throw new Error("Input graph is not connected: " + g); + } else { + init = true; + } + g.nodeEdges(v).forEach(updateNeighbors); + } + return result; + } + } + }); + + // lib/alg/index.js + var require_alg = __commonJS({ + "lib/alg/index.js"(exports, module) { + module.exports = { + components: require_components(), + dijkstra: require_dijkstra(), + dijkstraAll: require_dijkstra_all(), + findCycles: require_find_cycles(), + floydWarshall: require_floyd_warshall(), + isAcyclic: require_is_acyclic(), + postorder: require_postorder(), + preorder: require_preorder(), + prim: require_prim(), + tarjan: require_tarjan(), + topsort: require_topsort() + }; + } + }); + + // index.js + var require_index = __commonJS({ + "index.js"(exports, module) { + var lib = require_lib(); + module.exports = { + Graph: lib.Graph, + json: require_json(), + alg: require_alg(), + version: lib.version + }; + } + }); + return require_index(); +})(); +//# sourceMappingURL=dagre.js.map diff --git a/dist/dagre.js.map b/dist/dagre.js.map new file mode 100644 index 00000000..9dcc6176 --- /dev/null +++ b/dist/dagre.js.map @@ -0,0 +1,7 @@ +{ + "version": 3, + "sources": ["../lib/graph.js", "../lib/version.js", "../lib/index.js", "../lib/json.js", "../lib/alg/components.js", "../lib/data/priority-queue.js", "../lib/alg/dijkstra.js", "../lib/alg/dijkstra-all.js", "../lib/alg/tarjan.js", "../lib/alg/find-cycles.js", "../lib/alg/floyd-warshall.js", "../lib/alg/topsort.js", "../lib/alg/is-acyclic.js", "../lib/alg/dfs.js", "../lib/alg/postorder.js", "../lib/alg/preorder.js", "../lib/alg/prim.js", "../lib/alg/index.js", "../index.js"], + "sourcesContent": ["\"use strict\";\n\nvar DEFAULT_EDGE_NAME = \"\\x00\";\nvar GRAPH_NODE = \"\\x00\";\nvar EDGE_KEY_DELIM = \"\\x01\";\n\n// Implementation notes:\n//\n// * Node id query functions should return string ids for the nodes\n// * Edge id query functions should return an \"edgeObj\", edge object, that is\n// composed of enough information to uniquely identify an edge: {v, w, name}.\n// * Internally we use an \"edgeId\", a stringified form of the edgeObj, to\n// reference edges. This is because we need a performant way to look these\n// edges up and, object properties, which have string keys, are the closest\n// we're going to get to a performant hashtable in JavaScript.\n\nclass Graph {\n _isDirected = true;\n _isMultigraph = false;\n _isCompound = false;\n\n // Label for the graph itself\n _label;\n\n // Defaults to be set when creating a new node\n _defaultNodeLabelFn = () => undefined;\n\n // Defaults to be set when creating a new edge\n _defaultEdgeLabelFn = () => undefined;\n\n // v -> label\n _nodes = {};\n\n // v -> edgeObj\n _in = {};\n\n // u -> v -> Number\n _preds = {};\n\n // v -> edgeObj\n _out = {};\n\n // v -> w -> Number\n _sucs = {};\n\n // e -> edgeObj\n _edgeObjs = {};\n\n // e -> label\n _edgeLabels = {};\n\n /* Number of nodes in the graph. Should only be changed by the implementation. */\n _nodeCount = 0;\n\n /* Number of edges in the graph. Should only be changed by the implementation. */\n _edgeCount = 0;\n\n _parent;\n\n _children;\n\n constructor(opts) {\n if (opts) {\n this._isDirected = Object.hasOwn(opts, \"directed\") ? opts.directed : true;\n this._isMultigraph = Object.hasOwn(opts, \"multigraph\") ? opts.multigraph : false;\n this._isCompound = Object.hasOwn(opts, \"compound\") ? opts.compound : false;\n }\n\n if (this._isCompound) {\n // v -> parent\n this._parent = {};\n\n // v -> children\n this._children = {};\n this._children[GRAPH_NODE] = {};\n }\n }\n\n /* === Graph functions ========= */\n\n /**\n * Whether graph was created with 'directed' flag set to true or not.\n */\n isDirected() {\n return this._isDirected;\n }\n\n /**\n * Whether graph was created with 'multigraph' flag set to true or not.\n */\n isMultigraph() {\n return this._isMultigraph;\n }\n\n /**\n * Whether graph was created with 'compound' flag set to true or not.\n */\n isCompound() {\n return this._isCompound;\n }\n\n /**\n * Sets the label of the graph.\n */\n setGraph(label) {\n this._label = label;\n return this;\n }\n\n /**\n * Gets the graph label.\n */\n graph() {\n return this._label;\n }\n\n\n /* === Node functions ========== */\n\n /**\n * Sets the default node label. If newDefault is a function, it will be\n * invoked ach time when setting a label for a node. Otherwise, this label\n * will be assigned as default label in case if no label was specified while\n * setting a node.\n * Complexity: O(1).\n */\n setDefaultNodeLabel(newDefault) {\n this._defaultNodeLabelFn = newDefault;\n if (typeof newDefault !== 'function') {\n this._defaultNodeLabelFn = () => newDefault;\n }\n\n return this;\n }\n\n /**\n * Gets the number of nodes in the graph.\n * Complexity: O(1).\n */\n nodeCount() {\n return this._nodeCount;\n }\n\n /**\n * Gets all nodes of the graph. Note, the in case of compound graph subnodes are\n * not included in list.\n * Complexity: O(1).\n */\n nodes() {\n return Object.keys(this._nodes);\n }\n\n /**\n * Gets list of nodes without in-edges.\n * Complexity: O(|V|).\n */\n sources() {\n var self = this;\n return this.nodes().filter(v => Object.keys(self._in[v]).length === 0);\n }\n\n /**\n * Gets list of nodes without out-edges.\n * Complexity: O(|V|).\n */\n sinks() {\n var self = this;\n return this.nodes().filter(v => Object.keys(self._out[v]).length === 0);\n }\n\n /**\n * Invokes setNode method for each node in names list.\n * Complexity: O(|names|).\n */\n setNodes(vs, value) {\n var args = arguments;\n var self = this;\n vs.forEach(function(v) {\n if (args.length > 1) {\n self.setNode(v, value);\n } else {\n self.setNode(v);\n }\n });\n return this;\n }\n\n /**\n * Creates or updates the value for the node v in the graph. If label is supplied\n * it is set as the value for the node. If label is not supplied and the node was\n * created by this call then the default node label will be assigned.\n * Complexity: O(1).\n */\n setNode(v, value) {\n if (Object.hasOwn(this._nodes, v)) {\n if (arguments.length > 1) {\n this._nodes[v] = value;\n }\n return this;\n }\n\n this._nodes[v] = arguments.length > 1 ? value : this._defaultNodeLabelFn(v);\n if (this._isCompound) {\n this._parent[v] = GRAPH_NODE;\n this._children[v] = {};\n this._children[GRAPH_NODE][v] = true;\n }\n this._in[v] = {};\n this._preds[v] = {};\n this._out[v] = {};\n this._sucs[v] = {};\n ++this._nodeCount;\n return this;\n }\n\n /**\n * Gets the label of node with specified name.\n * Complexity: O(|V|).\n */\n node(v) {\n return this._nodes[v];\n }\n\n /**\n * Detects whether graph has a node with specified name or not.\n */\n hasNode(v) {\n return Object.hasOwn(this._nodes, v);\n }\n\n /**\n * Remove the node with the name from the graph or do nothing if the node is not in\n * the graph. If the node was removed this function also removes any incident\n * edges.\n * Complexity: O(1).\n */\n removeNode(v) {\n var self = this;\n if (Object.hasOwn(this._nodes, v)) {\n var removeEdge = e => self.removeEdge(self._edgeObjs[e]);\n delete this._nodes[v];\n if (this._isCompound) {\n this._removeFromParentsChildList(v);\n delete this._parent[v];\n this.children(v).forEach(function(child) {\n self.setParent(child);\n });\n delete this._children[v];\n }\n Object.keys(this._in[v]).forEach(removeEdge);\n delete this._in[v];\n delete this._preds[v];\n Object.keys(this._out[v]).forEach(removeEdge);\n delete this._out[v];\n delete this._sucs[v];\n --this._nodeCount;\n }\n return this;\n }\n\n /**\n * Sets node p as a parent for node v if it is defined, or removes the\n * parent for v if p is undefined. Method throws an exception in case of\n * invoking it in context of noncompound graph.\n * Average-case complexity: O(1).\n */\n setParent(v, parent) {\n if (!this._isCompound) {\n throw new Error(\"Cannot set parent in a non-compound graph\");\n }\n\n if (parent === undefined) {\n parent = GRAPH_NODE;\n } else {\n // Coerce parent to string\n parent += \"\";\n for (var ancestor = parent; ancestor !== undefined; ancestor = this.parent(ancestor)) {\n if (ancestor === v) {\n throw new Error(\"Setting \" + parent+ \" as parent of \" + v +\n \" would create a cycle\");\n }\n }\n\n this.setNode(parent);\n }\n\n this.setNode(v);\n this._removeFromParentsChildList(v);\n this._parent[v] = parent;\n this._children[parent][v] = true;\n return this;\n }\n\n _removeFromParentsChildList(v) {\n delete this._children[this._parent[v]][v];\n }\n\n /**\n * Gets parent node for node v.\n * Complexity: O(1).\n */\n parent(v) {\n if (this._isCompound) {\n var parent = this._parent[v];\n if (parent !== GRAPH_NODE) {\n return parent;\n }\n }\n }\n\n /**\n * Gets list of direct children of node v.\n * Complexity: O(1).\n */\n children(v = GRAPH_NODE) {\n if (this._isCompound) {\n var children = this._children[v];\n if (children) {\n return Object.keys(children);\n }\n } else if (v === GRAPH_NODE) {\n return this.nodes();\n } else if (this.hasNode(v)) {\n return [];\n }\n }\n\n /**\n * Return all nodes that are predecessors of the specified node or undefined if node v is not in\n * the graph. Behavior is undefined for undirected graphs - use neighbors instead.\n * Complexity: O(|V|).\n */\n predecessors(v) {\n var predsV = this._preds[v];\n if (predsV) {\n return Object.keys(predsV);\n }\n }\n\n /**\n * Return all nodes that are successors of the specified node or undefined if node v is not in\n * the graph. Behavior is undefined for undirected graphs - use neighbors instead.\n * Complexity: O(|V|).\n */\n successors(v) {\n var sucsV = this._sucs[v];\n if (sucsV) {\n return Object.keys(sucsV);\n }\n }\n\n /**\n * Return all nodes that are predecessors or successors of the specified node or undefined if\n * node v is not in the graph.\n * Complexity: O(|V|).\n */\n neighbors(v) {\n var preds = this.predecessors(v);\n if (preds) {\n const union = new Set(preds);\n for (var succ of this.successors(v)) {\n union.add(succ);\n }\n\n return Array.from(union.values());\n }\n }\n\n isLeaf(v) {\n var neighbors;\n if (this.isDirected()) {\n neighbors = this.successors(v);\n } else {\n neighbors = this.neighbors(v);\n }\n return neighbors.length === 0;\n }\n\n /**\n * Creates new graph with nodes filtered via filter. Edges incident to rejected node\n * are also removed. In case of compound graph, if parent is rejected by filter,\n * than all its children are rejected too.\n * Average-case complexity: O(|E|+|V|).\n */\n filterNodes(filter) {\n var copy = new this.constructor({\n directed: this._isDirected,\n multigraph: this._isMultigraph,\n compound: this._isCompound\n });\n\n copy.setGraph(this.graph());\n\n var self = this;\n Object.entries(this._nodes).forEach(function([v, value]) {\n if (filter(v)) {\n copy.setNode(v, value);\n }\n });\n\n Object.values(this._edgeObjs).forEach(function(e) {\n if (copy.hasNode(e.v) && copy.hasNode(e.w)) {\n copy.setEdge(e, self.edge(e));\n }\n });\n\n var parents = {};\n function findParent(v) {\n var parent = self.parent(v);\n if (parent === undefined || copy.hasNode(parent)) {\n parents[v] = parent;\n return parent;\n } else if (parent in parents) {\n return parents[parent];\n } else {\n return findParent(parent);\n }\n }\n\n if (this._isCompound) {\n copy.nodes().forEach(v => copy.setParent(v, findParent(v)));\n }\n\n return copy;\n }\n\n /* === Edge functions ========== */\n\n /**\n * Sets the default edge label or factory function. This label will be\n * assigned as default label in case if no label was specified while setting\n * an edge or this function will be invoked each time when setting an edge\n * with no label specified and returned value * will be used as a label for edge.\n * Complexity: O(1).\n */\n setDefaultEdgeLabel(newDefault) {\n this._defaultEdgeLabelFn = newDefault;\n if (typeof newDefault !== 'function') {\n this._defaultEdgeLabelFn = () => newDefault;\n }\n\n return this;\n }\n\n /**\n * Gets the number of edges in the graph.\n * Complexity: O(1).\n */\n edgeCount() {\n return this._edgeCount;\n }\n\n /**\n * Gets edges of the graph. In case of compound graph subgraphs are not considered.\n * Complexity: O(|E|).\n */\n edges() {\n return Object.values(this._edgeObjs);\n }\n\n /**\n * Establish an edges path over the nodes in nodes list. If some edge is already\n * exists, it will update its label, otherwise it will create an edge between pair\n * of nodes with label provided or default label if no label provided.\n * Complexity: O(|nodes|).\n */\n setPath(vs, value) {\n var self = this;\n var args = arguments;\n vs.reduce(function(v, w) {\n if (args.length > 1) {\n self.setEdge(v, w, value);\n } else {\n self.setEdge(v, w);\n }\n return w;\n });\n return this;\n }\n\n /**\n * Creates or updates the label for the edge (v, w) with the optionally supplied\n * name. If label is supplied it is set as the value for the edge. If label is not\n * supplied and the edge was created by this call then the default edge label will\n * be assigned. The name parameter is only useful with multigraphs.\n */\n setEdge() {\n var v, w, name, value;\n var valueSpecified = false;\n var arg0 = arguments[0];\n\n if (typeof arg0 === \"object\" && arg0 !== null && \"v\" in arg0) {\n v = arg0.v;\n w = arg0.w;\n name = arg0.name;\n if (arguments.length === 2) {\n value = arguments[1];\n valueSpecified = true;\n }\n } else {\n v = arg0;\n w = arguments[1];\n name = arguments[3];\n if (arguments.length > 2) {\n value = arguments[2];\n valueSpecified = true;\n }\n }\n\n v = \"\" + v;\n w = \"\" + w;\n if (name !== undefined) {\n name = \"\" + name;\n }\n\n var e = edgeArgsToId(this._isDirected, v, w, name);\n if (Object.hasOwn(this._edgeLabels, e)) {\n if (valueSpecified) {\n this._edgeLabels[e] = value;\n }\n return this;\n }\n\n if (name !== undefined && !this._isMultigraph) {\n throw new Error(\"Cannot set a named edge when isMultigraph = false\");\n }\n\n // It didn't exist, so we need to create it.\n // First ensure the nodes exist.\n this.setNode(v);\n this.setNode(w);\n\n this._edgeLabels[e] = valueSpecified ? value : this._defaultEdgeLabelFn(v, w, name);\n\n var edgeObj = edgeArgsToObj(this._isDirected, v, w, name);\n // Ensure we add undirected edges in a consistent way.\n v = edgeObj.v;\n w = edgeObj.w;\n\n Object.freeze(edgeObj);\n this._edgeObjs[e] = edgeObj;\n incrementOrInitEntry(this._preds[w], v);\n incrementOrInitEntry(this._sucs[v], w);\n this._in[w][e] = edgeObj;\n this._out[v][e] = edgeObj;\n this._edgeCount++;\n return this;\n }\n\n /**\n * Gets the label for the specified edge.\n * Complexity: O(1).\n */\n edge(v, w, name) {\n var e = (arguments.length === 1\n ? edgeObjToId(this._isDirected, arguments[0])\n : edgeArgsToId(this._isDirected, v, w, name));\n return this._edgeLabels[e];\n }\n\n /**\n * Gets the label for the specified edge and converts it to an object.\n * Complexity: O(1)\n */\n edgeAsObj() {\n const edge = this.edge(...arguments);\n if (typeof edge !== \"object\") {\n return {label: edge};\n }\n\n return edge;\n }\n\n /**\n * Detects whether the graph contains specified edge or not. No subgraphs are considered.\n * Complexity: O(1).\n */\n hasEdge(v, w, name) {\n var e = (arguments.length === 1\n ? edgeObjToId(this._isDirected, arguments[0])\n : edgeArgsToId(this._isDirected, v, w, name));\n return Object.hasOwn(this._edgeLabels, e);\n }\n\n /**\n * Removes the specified edge from the graph. No subgraphs are considered.\n * Complexity: O(1).\n */\n removeEdge(v, w, name) {\n var e = (arguments.length === 1\n ? edgeObjToId(this._isDirected, arguments[0])\n : edgeArgsToId(this._isDirected, v, w, name));\n var edge = this._edgeObjs[e];\n if (edge) {\n v = edge.v;\n w = edge.w;\n delete this._edgeLabels[e];\n delete this._edgeObjs[e];\n decrementOrRemoveEntry(this._preds[w], v);\n decrementOrRemoveEntry(this._sucs[v], w);\n delete this._in[w][e];\n delete this._out[v][e];\n this._edgeCount--;\n }\n return this;\n }\n\n /**\n * Return all edges that point to the node v. Optionally filters those edges down to just those\n * coming from node u. Behavior is undefined for undirected graphs - use nodeEdges instead.\n * Complexity: O(|E|).\n */\n inEdges(v, u) {\n var inV = this._in[v];\n if (inV) {\n var edges = Object.values(inV);\n if (!u) {\n return edges;\n }\n return edges.filter(edge => edge.v === u);\n }\n }\n\n /**\n * Return all edges that are pointed at by node v. Optionally filters those edges down to just\n * those point to w. Behavior is undefined for undirected graphs - use nodeEdges instead.\n * Complexity: O(|E|).\n */\n outEdges(v, w) {\n var outV = this._out[v];\n if (outV) {\n var edges = Object.values(outV);\n if (!w) {\n return edges;\n }\n return edges.filter(edge => edge.w === w);\n }\n }\n\n /**\n * Returns all edges to or from node v regardless of direction. Optionally filters those edges\n * down to just those between nodes v and w regardless of direction.\n * Complexity: O(|E|).\n */\n nodeEdges(v, w) {\n var inEdges = this.inEdges(v, w);\n if (inEdges) {\n return inEdges.concat(this.outEdges(v, w));\n }\n }\n}\n\nfunction incrementOrInitEntry(map, k) {\n if (map[k]) {\n map[k]++;\n } else {\n map[k] = 1;\n }\n}\n\nfunction decrementOrRemoveEntry(map, k) {\n if (!--map[k]) { delete map[k]; }\n}\n\nfunction edgeArgsToId(isDirected, v_, w_, name) {\n var v = \"\" + v_;\n var w = \"\" + w_;\n if (!isDirected && v > w) {\n var tmp = v;\n v = w;\n w = tmp;\n }\n return v + EDGE_KEY_DELIM + w + EDGE_KEY_DELIM +\n (name === undefined ? DEFAULT_EDGE_NAME : name);\n}\n\nfunction edgeArgsToObj(isDirected, v_, w_, name) {\n var v = \"\" + v_;\n var w = \"\" + w_;\n if (!isDirected && v > w) {\n var tmp = v;\n v = w;\n w = tmp;\n }\n var edgeObj = { v: v, w: w };\n if (name) {\n edgeObj.name = name;\n }\n return edgeObj;\n}\n\nfunction edgeObjToId(isDirected, edgeObj) {\n return edgeArgsToId(isDirected, edgeObj.v, edgeObj.w, edgeObj.name);\n}\n\nmodule.exports = Graph;\n", "module.exports = '2.2.5-pre';\n", "// Includes only the \"core\" of graphlib\nmodule.exports = {\n Graph: require(\"./graph\"),\n version: require(\"./version\")\n};\n", "var Graph = require(\"./graph\");\n\nmodule.exports = {\n write: write,\n read: read\n};\n\n/**\n * Creates a JSON representation of the graph that can be serialized to a string with\n * JSON.stringify. The graph can later be restored using json.read.\n */\nfunction write(g) {\n var json = {\n options: {\n directed: g.isDirected(),\n multigraph: g.isMultigraph(),\n compound: g.isCompound()\n },\n nodes: writeNodes(g),\n edges: writeEdges(g)\n };\n\n if (g.graph() !== undefined) {\n json.value = structuredClone(g.graph());\n }\n return json;\n}\n\nfunction writeNodes(g) {\n return g.nodes().map(function(v) {\n var nodeValue = g.node(v);\n var parent = g.parent(v);\n var node = { v: v };\n if (nodeValue !== undefined) {\n node.value = nodeValue;\n }\n if (parent !== undefined) {\n node.parent = parent;\n }\n return node;\n });\n}\n\nfunction writeEdges(g) {\n return g.edges().map(function(e) {\n var edgeValue = g.edge(e);\n var edge = { v: e.v, w: e.w };\n if (e.name !== undefined) {\n edge.name = e.name;\n }\n if (edgeValue !== undefined) {\n edge.value = edgeValue;\n }\n return edge;\n });\n}\n\n/**\n * Takes JSON as input and returns the graph representation.\n *\n * @example\n * var g2 = graphlib.json.read(JSON.parse(str));\n * g2.nodes();\n * // ['a', 'b']\n * g2.edges()\n * // [ { v: 'a', w: 'b' } ]\n */\nfunction read(json) {\n var g = new Graph(json.options).setGraph(json.value);\n json.nodes.forEach(function(entry) {\n g.setNode(entry.v, entry.value);\n if (entry.parent) {\n g.setParent(entry.v, entry.parent);\n }\n });\n json.edges.forEach(function(entry) {\n g.setEdge({ v: entry.v, w: entry.w, name: entry.name }, entry.value);\n });\n return g;\n}\n", "module.exports = components;\n\nfunction components(g) {\n var visited = {};\n var cmpts = [];\n var cmpt;\n\n function dfs(v) {\n if (Object.hasOwn(visited, v)) return;\n visited[v] = true;\n cmpt.push(v);\n g.successors(v).forEach(dfs);\n g.predecessors(v).forEach(dfs);\n }\n\n g.nodes().forEach(function(v) {\n cmpt = [];\n dfs(v);\n if (cmpt.length) {\n cmpts.push(cmpt);\n }\n });\n\n return cmpts;\n}\n", "/**\n * A min-priority queue data structure. This algorithm is derived from Cormen,\n * et al., \"Introduction to Algorithms\". The basic idea of a min-priority\n * queue is that you can efficiently (in O(1) time) get the smallest key in\n * the queue. Adding and removing elements takes O(log n) time. A key can\n * have its priority decreased in O(log n) time.\n */\nclass PriorityQueue {\n _arr = [];\n _keyIndices = {};\n\n /**\n * Returns the number of elements in the queue. Takes `O(1)` time.\n */\n size() {\n return this._arr.length;\n }\n\n /**\n * Returns the keys that are in the queue. Takes `O(n)` time.\n */\n keys() {\n return this._arr.map(function(x) { return x.key; });\n }\n\n /**\n * Returns `true` if **key** is in the queue and `false` if not.\n */\n has(key) {\n return Object.hasOwn(this._keyIndices, key);\n }\n\n /**\n * Returns the priority for **key**. If **key** is not present in the queue\n * then this function returns `undefined`. Takes `O(1)` time.\n *\n * @param {Object} key\n */\n priority(key) {\n var index = this._keyIndices[key];\n if (index !== undefined) {\n return this._arr[index].priority;\n }\n }\n\n /**\n * Returns the key for the minimum element in this queue. If the queue is\n * empty this function throws an Error. Takes `O(1)` time.\n */\n min() {\n if (this.size() === 0) {\n throw new Error(\"Queue underflow\");\n }\n return this._arr[0].key;\n }\n\n /**\n * Inserts a new key into the priority queue. If the key already exists in\n * the queue this function returns `false`; otherwise it will return `true`.\n * Takes `O(n)` time.\n *\n * @param {Object} key the key to add\n * @param {Number} priority the initial priority for the key\n */\n add(key, priority) {\n var keyIndices = this._keyIndices;\n key = String(key);\n if (!Object.hasOwn(keyIndices, key)) {\n var arr = this._arr;\n var index = arr.length;\n keyIndices[key] = index;\n arr.push({key: key, priority: priority});\n this._decrease(index);\n return true;\n }\n return false;\n }\n\n /**\n * Removes and returns the smallest key in the queue. Takes `O(log n)` time.\n */\n removeMin() {\n this._swap(0, this._arr.length - 1);\n var min = this._arr.pop();\n delete this._keyIndices[min.key];\n this._heapify(0);\n return min.key;\n }\n\n /**\n * Decreases the priority for **key** to **priority**. If the new priority is\n * greater than the previous priority, this function will throw an Error.\n *\n * @param {Object} key the key for which to raise priority\n * @param {Number} priority the new priority for the key\n */\n decrease(key, priority) {\n var index = this._keyIndices[key];\n if (priority > this._arr[index].priority) {\n throw new Error(\"New priority is greater than current priority. \" +\n \"Key: \" + key + \" Old: \" + this._arr[index].priority + \" New: \" + priority);\n }\n this._arr[index].priority = priority;\n this._decrease(index);\n }\n\n _heapify(i) {\n var arr = this._arr;\n var l = 2 * i;\n var r = l + 1;\n var largest = i;\n if (l < arr.length) {\n largest = arr[l].priority < arr[largest].priority ? l : largest;\n if (r < arr.length) {\n largest = arr[r].priority < arr[largest].priority ? r : largest;\n }\n if (largest !== i) {\n this._swap(i, largest);\n this._heapify(largest);\n }\n }\n }\n\n _decrease(index) {\n var arr = this._arr;\n var priority = arr[index].priority;\n var parent;\n while (index !== 0) {\n parent = index >> 1;\n if (arr[parent].priority < priority) {\n break;\n }\n this._swap(index, parent);\n index = parent;\n }\n }\n\n _swap(i, j) {\n var arr = this._arr;\n var keyIndices = this._keyIndices;\n var origArrI = arr[i];\n var origArrJ = arr[j];\n arr[i] = origArrJ;\n arr[j] = origArrI;\n keyIndices[origArrJ.key] = i;\n keyIndices[origArrI.key] = j;\n }\n}\n\nmodule.exports = PriorityQueue;\n", "var PriorityQueue = require(\"../data/priority-queue\");\n\nmodule.exports = dijkstra;\n\nvar DEFAULT_WEIGHT_FUNC = () => 1;\n\nfunction dijkstra(g, source, weightFn, edgeFn) {\n return runDijkstra(g, String(source),\n weightFn || DEFAULT_WEIGHT_FUNC,\n edgeFn || function(v) { return g.outEdges(v); });\n}\n\nfunction runDijkstra(g, source, weightFn, edgeFn) {\n var results = {};\n var pq = new PriorityQueue();\n var v, vEntry;\n\n var updateNeighbors = function(edge) {\n var w = edge.v !== v ? edge.v : edge.w;\n var wEntry = results[w];\n var weight = weightFn(edge);\n var distance = vEntry.distance + weight;\n\n if (weight < 0) {\n throw new Error(\"dijkstra does not allow negative edge weights. \" +\n \"Bad edge: \" + edge + \" Weight: \" + weight);\n }\n\n if (distance < wEntry.distance) {\n wEntry.distance = distance;\n wEntry.predecessor = v;\n pq.decrease(w, distance);\n }\n };\n\n g.nodes().forEach(function(v) {\n var distance = v === source ? 0 : Number.POSITIVE_INFINITY;\n results[v] = { distance: distance };\n pq.add(v, distance);\n });\n\n while (pq.size() > 0) {\n v = pq.removeMin();\n vEntry = results[v];\n if (vEntry.distance === Number.POSITIVE_INFINITY) {\n break;\n }\n\n edgeFn(v).forEach(updateNeighbors);\n }\n\n return results;\n}\n", "var dijkstra = require(\"./dijkstra\");\n\nmodule.exports = dijkstraAll;\n\nfunction dijkstraAll(g, weightFunc, edgeFunc) {\n return g.nodes().reduce(function(acc, v) {\n acc[v] = dijkstra(g, v, weightFunc, edgeFunc);\n return acc;\n }, {});\n}\n", "module.exports = tarjan;\n\nfunction tarjan(g) {\n var index = 0;\n var stack = [];\n var visited = {}; // node id -> { onStack, lowlink, index }\n var results = [];\n\n function dfs(v) {\n var entry = visited[v] = {\n onStack: true,\n lowlink: index,\n index: index++\n };\n stack.push(v);\n\n g.successors(v).forEach(function(w) {\n if (!Object.hasOwn(visited, w)) {\n dfs(w);\n entry.lowlink = Math.min(entry.lowlink, visited[w].lowlink);\n } else if (visited[w].onStack) {\n entry.lowlink = Math.min(entry.lowlink, visited[w].index);\n }\n });\n\n if (entry.lowlink === entry.index) {\n var cmpt = [];\n var w;\n do {\n w = stack.pop();\n visited[w].onStack = false;\n cmpt.push(w);\n } while (v !== w);\n results.push(cmpt);\n }\n }\n\n g.nodes().forEach(function(v) {\n if (!Object.hasOwn(visited, v)) {\n dfs(v);\n }\n });\n\n return results;\n}\n", "var tarjan = require(\"./tarjan\");\n\nmodule.exports = findCycles;\n\nfunction findCycles(g) {\n return tarjan(g).filter(function(cmpt) {\n return cmpt.length > 1 || (cmpt.length === 1 && g.hasEdge(cmpt[0], cmpt[0]));\n });\n}\n", "module.exports = floydWarshall;\n\nvar DEFAULT_WEIGHT_FUNC = () => 1;\n\nfunction floydWarshall(g, weightFn, edgeFn) {\n return runFloydWarshall(g,\n weightFn || DEFAULT_WEIGHT_FUNC,\n edgeFn || function(v) { return g.outEdges(v); });\n}\n\nfunction runFloydWarshall(g, weightFn, edgeFn) {\n var results = {};\n var nodes = g.nodes();\n\n nodes.forEach(function(v) {\n results[v] = {};\n results[v][v] = { distance: 0 };\n nodes.forEach(function(w) {\n if (v !== w) {\n results[v][w] = { distance: Number.POSITIVE_INFINITY };\n }\n });\n edgeFn(v).forEach(function(edge) {\n var w = edge.v === v ? edge.w : edge.v;\n var d = weightFn(edge);\n results[v][w] = { distance: d, predecessor: v };\n });\n });\n\n nodes.forEach(function(k) {\n var rowK = results[k];\n nodes.forEach(function(i) {\n var rowI = results[i];\n nodes.forEach(function(j) {\n var ik = rowI[k];\n var kj = rowK[j];\n var ij = rowI[j];\n var altDistance = ik.distance + kj.distance;\n if (altDistance < ij.distance) {\n ij.distance = altDistance;\n ij.predecessor = kj.predecessor;\n }\n });\n });\n });\n\n return results;\n}\n", "function topsort(g) {\n var visited = {};\n var stack = {};\n var results = [];\n\n function visit(node) {\n if (Object.hasOwn(stack, node)) {\n throw new CycleException();\n }\n\n if (!Object.hasOwn(visited, node)) {\n stack[node] = true;\n visited[node] = true;\n g.predecessors(node).forEach(visit);\n delete stack[node];\n results.push(node);\n }\n }\n\n g.sinks().forEach(visit);\n\n if (Object.keys(visited).length !== g.nodeCount()) {\n throw new CycleException();\n }\n\n return results;\n}\n\nclass CycleException extends Error {\n constructor() {\n super(...arguments);\n }\n}\n\nmodule.exports = topsort;\ntopsort.CycleException = CycleException;\n", "var topsort = require(\"./topsort\");\n\nmodule.exports = isAcyclic;\n\nfunction isAcyclic(g) {\n try {\n topsort(g);\n } catch (e) {\n if (e instanceof topsort.CycleException) {\n return false;\n }\n throw e;\n }\n return true;\n}\n", "module.exports = dfs;\n\n/*\n * A helper that preforms a pre- or post-order traversal on the input graph\n * and returns the nodes in the order they were visited. If the graph is\n * undirected then this algorithm will navigate using neighbors. If the graph\n * is directed then this algorithm will navigate using successors.\n *\n * If the order is not \"post\", it will be treated as \"pre\".\n */\nfunction dfs(g, vs, order) {\n if (!Array.isArray(vs)) {\n vs = [vs];\n }\n\n var navigation = g.isDirected() ? v => g.successors(v) : v => g.neighbors(v);\n var orderFunc = order === \"post\" ? postOrderDfs : preOrderDfs;\n\n var acc = [];\n var visited = {};\n vs.forEach(v => {\n if (!g.hasNode(v)) {\n throw new Error(\"Graph does not have node: \" + v);\n }\n\n orderFunc(v, navigation, visited, acc);\n });\n\n return acc;\n}\n\nfunction postOrderDfs(v, navigation, visited, acc) {\n var stack = [[v, false]];\n while (stack.length > 0) {\n var curr = stack.pop();\n if (curr[1]) {\n acc.push(curr[0]);\n } else {\n if (!Object.hasOwn(visited, curr[0])) {\n visited[curr[0]] = true;\n stack.push([curr[0], true]);\n forEachRight(navigation(curr[0]), w => stack.push([w, false]));\n }\n }\n }\n}\n\nfunction preOrderDfs(v, navigation, visited, acc) {\n var stack = [v];\n while (stack.length > 0) {\n var curr = stack.pop();\n if (!Object.hasOwn(visited, curr)) {\n visited[curr] = true;\n acc.push(curr);\n forEachRight(navigation(curr), w => stack.push(w));\n }\n }\n}\n\nfunction forEachRight(array, iteratee) {\n var length = array.length;\n while (length--) {\n iteratee(array[length], length, array);\n }\n\n return array;\n}\n", "var dfs = require(\"./dfs\");\n\nmodule.exports = postorder;\n\nfunction postorder(g, vs) {\n return dfs(g, vs, \"post\");\n}\n", "var dfs = require(\"./dfs\");\n\nmodule.exports = preorder;\n\nfunction preorder(g, vs) {\n return dfs(g, vs, \"pre\");\n}\n", "var Graph = require(\"../graph\");\nvar PriorityQueue = require(\"../data/priority-queue\");\n\nmodule.exports = prim;\n\nfunction prim(g, weightFunc) {\n var result = new Graph();\n var parents = {};\n var pq = new PriorityQueue();\n var v;\n\n function updateNeighbors(edge) {\n var w = edge.v === v ? edge.w : edge.v;\n var pri = pq.priority(w);\n if (pri !== undefined) {\n var edgeWeight = weightFunc(edge);\n if (edgeWeight < pri) {\n parents[w] = v;\n pq.decrease(w, edgeWeight);\n }\n }\n }\n\n if (g.nodeCount() === 0) {\n return result;\n }\n\n g.nodes().forEach(function(v) {\n pq.add(v, Number.POSITIVE_INFINITY);\n result.setNode(v);\n });\n\n // Start from an arbitrary node\n pq.decrease(g.nodes()[0], 0);\n\n var init = false;\n while (pq.size() > 0) {\n v = pq.removeMin();\n if (Object.hasOwn(parents, v)) {\n result.setEdge(v, parents[v]);\n } else if (init) {\n throw new Error(\"Input graph is not connected: \" + g);\n } else {\n init = true;\n }\n\n g.nodeEdges(v).forEach(updateNeighbors);\n }\n\n return result;\n}\n", "module.exports = {\n components: require(\"./components\"),\n dijkstra: require(\"./dijkstra\"),\n dijkstraAll: require(\"./dijkstra-all\"),\n findCycles: require(\"./find-cycles\"),\n floydWarshall: require(\"./floyd-warshall\"),\n isAcyclic: require(\"./is-acyclic\"),\n postorder: require(\"./postorder\"),\n preorder: require(\"./preorder\"),\n prim: require(\"./prim\"),\n tarjan: require(\"./tarjan\"),\n topsort: require(\"./topsort\")\n};\n", "/**\n * Copyright (c) 2014, Chris Pettitt\n * All rights reserved.\n *\n * Redistribution and use in source and binary forms, with or without\n * modification, are permitted provided that the following conditions are met:\n *\n * 1. Redistributions of source code must retain the above copyright notice, this\n * list of conditions and the following disclaimer.\n *\n * 2. Redistributions in binary form must reproduce the above copyright notice,\n * this list of conditions and the following disclaimer in the documentation\n * and/or other materials provided with the distribution.\n *\n * 3. Neither the name of the copyright holder nor the names of its contributors\n * may be used to endorse or promote products derived from this software without\n * specific prior written permission.\n *\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND\n * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED\n * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\n * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE\n * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL\n * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR\n * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER\n * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,\n * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\n * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n */\n\nvar lib = require(\"./lib\");\n\nmodule.exports = {\n Graph: lib.Graph,\n json: require(\"./lib/json\"),\n alg: require(\"./lib/alg\"),\n version: lib.version\n};\n"], + "mappings": ";;;;;;;;;;AAAA;AAAA;AAAA;AAEA,UAAI,oBAAoB;AACxB,UAAI,aAAa;AACjB,UAAI,iBAAiB;AAYrB,UAAM,QAAN,MAAY;AAAA,QA6CV,YAAY,MAAM;AA5ClB,6CAAc;AACd,+CAAgB;AAChB,6CAAc;AAGd;AAAA;AAGA;AAAA,qDAAsB,MAAM;AAG5B;AAAA,qDAAsB,MAAM;AAG5B;AAAA,wCAAS,CAAC;AAGV;AAAA,qCAAM,CAAC;AAGP;AAAA,wCAAS,CAAC;AAGV;AAAA,sCAAO,CAAC;AAGR;AAAA,uCAAQ,CAAC;AAGT;AAAA,2CAAY,CAAC;AAGb;AAAA,6CAAc,CAAC;AAGf;AAAA,4CAAa;AAGb;AAAA,4CAAa;AAEb;AAEA;AAGE,cAAI,MAAM;AACR,iBAAK,cAAc,OAAO,OAAO,MAAM,UAAU,IAAI,KAAK,WAAW;AACrE,iBAAK,gBAAgB,OAAO,OAAO,MAAM,YAAY,IAAI,KAAK,aAAa;AAC3E,iBAAK,cAAc,OAAO,OAAO,MAAM,UAAU,IAAI,KAAK,WAAW;AAAA,UACvE;AAEA,cAAI,KAAK,aAAa;AAEpB,iBAAK,UAAU,CAAC;AAGhB,iBAAK,YAAY,CAAC;AAClB,iBAAK,UAAU,UAAU,IAAI,CAAC;AAAA,UAChC;AAAA,QACF;AAAA;AAAA;AAAA;AAAA;AAAA,QAOA,aAAa;AACX,iBAAO,KAAK;AAAA,QACd;AAAA;AAAA;AAAA;AAAA,QAKA,eAAe;AACb,iBAAO,KAAK;AAAA,QACd;AAAA;AAAA;AAAA;AAAA,QAKA,aAA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AAmC,CAAC;AAAA,UACtD,OAAO;AACL,mBAAO;AAAA,UACT;AAEA,YAAE,UAAU,CAAC,EAAE,QAAQ,eAAe;AAAA,QACxC;AAEA,eAAO;AAAA,MACT;AAAA;AAAA;;;AClDA;AAAA;AAAA,aAAO,UAAU;AAAA,QACf,YAAY;AAAA,QACZ,UAAU;AAAA,QACV,aAAa;AAAA,QACb,YAAY;AAAA,QACZ,eAAe;AAAA,QACf,WAAW;AAAA,QACX,WAAW;AAAA,QACX,UAAU;AAAA,QACV,MAAM;AAAA,QACN,QAAQ;AAAA,QACR,SAAS;AAAA,MACX;AAAA;AAAA;;;ACZA;AAAA;AA8BA,UAAI,MAAM;AAEV,aAAO,UAAU;AAAA,QACf,OAAO,IAAI;AAAA,QACX,MAAM;AAAA,QACN,KAAK;AAAA,QACL,SAAS,IAAI;AAAA,MACf;AAAA;AAAA;", + "names": ["v", "w", "v"] +} diff --git a/dist/dagre.min.js b/dist/dagre.min.js new file mode 100644 index 00000000..bee96600 --- /dev/null +++ b/dist/dagre.min.js @@ -0,0 +1,2 @@ +var dagre=(()=>{var fe=Object.defineProperty;var le=(n,e,r)=>e in n?fe(n,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):n[e]=r;var c=(n,e)=>()=>(e||n((e={exports:{}}).exports,e),e.exports);var d=(n,e,r)=>le(n,typeof e!="symbol"?e+"":e,r);var b=c((Re,D)=>{"use strict";var _e="\0",p="\0",C="",m=class{constructor(e){d(this,"_isDirected",!0);d(this,"_isMultigraph",!1);d(this,"_isCompound",!1);d(this,"_label");d(this,"_defaultNodeLabelFn",()=>{});d(this,"_defaultEdgeLabelFn",()=>{});d(this,"_nodes",{});d(this,"_in",{});d(this,"_preds",{});d(this,"_out",{});d(this,"_sucs",{});d(this,"_edgeObjs",{});d(this,"_edgeLabels",{});d(this,"_nodeCount",0);d(this,"_edgeCount",0);d(this,"_parent");d(this,"_children");e&&(this._isDirected=Object.hasOwn(e,"directed")?e.directed:!0,this._isMultigraph=Object.hasOwn(e,"multigraph")?e.multigraph:!1,this._isCompound=Object.hasOwn(e,"compound")?e.compound:!1),this._isCompound&&(this._parent={},this._children={},this._children[p]={})}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return this._defaultNodeLabelFn=e,typeof e!="function"&&(this._defaultNodeLabelFn=()=>e),this}nodeCount(){return this._nodeCount}nodes(){return Object.keys(this._nodes)}sources(){var e=this;return this.nodes().filter(r=>Object.keys(e._in[r]).length===0)}sinks(){var e=this;return this.nodes().filter(r=>Object.keys(e._out[r]).length===0)}setNodes(e,r){var t=arguments,s=this;return e.forEach(function(i){t.length>1?s.setNode(i,r):s.setNode(i)}),this}setNode(e,r){return Object.hasOwn(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=r),this):(this._nodes[e]=arguments.length>1?r:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=p,this._children[e]={},this._children[p][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.hasOwn(this._nodes,e)}removeNode(e){var r=this;if(Object.hasOwn(this._nodes,e)){var t=s=>r.removeEdge(r._edgeObjs[s]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],this.children(e).forEach(function(s){r.setParent(s)}),delete this._children[e]),Object.keys(this._in[e]).forEach(t),delete this._in[e],delete this._preds[e],Object.keys(this._out[e]).forEach(t),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,r){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(r===void 0)r=p;else{r+="";for(var t=r;t!==void 0;t=this.parent(t))if(t===e)throw new Error("Setting "+r+" as parent of "+e+" would create a cycle");this.setNode(r)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=r,this._children[r][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var r=this._parent[e];if(r!==p)return r}}children(e=p){if(this._isCompound){var r=this._children[e];if(r)return Object.keys(r)}else{if(e===p)return this.nodes();if(this.hasNode(e))return[]}}predecessors(e){var r=this._preds[e];if(r)return Object.keys(r)}successors(e){var r=this._sucs[e];if(r)return Object.keys(r)}neighbors(e){var r=this.predecessors(e);if(r){let s=new Set(r);for(var t of this.successors(e))s.add(t);return Array.from(s.values())}}isLeaf(e){var r;return this.isDirected()?r=this.successors(e):r=this.neighbors(e),r.length===0}filterNodes(e){var r=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});r.setGraph(this.graph());var t=this;Object.entries(this._nodes).forEach(function([a,o]){e(a)&&r.setNode(a,o)}),Object.values(this._edgeObjs).forEach(function(a){r.hasNode(a.v)&&r.hasNode(a.w)&&r.setEdge(a,t.edge(a))});var s={};function i(a){var o=t.parent(a);return o===void 0||r.hasNode(o)?(s[a]=o,o):o in s?s[o]:i(o)}return this._isCompound&&r.nodes().forEach(a=>r.setParent(a,i(a))),r}setDefaultEdgeLabel(e){return this._defaultEdgeLabelFn=e,typeof e!="function"&&(this._defaultEdgeLabelFn=()=>e),this}edgeCount(){return this._edgeCount}edges(){return Object.values(this._edgeObjs)}setPath(e,r){var t=this,s=arguments;return e.reduce(function(i,a){return s.length>1?t.setEdge(i,a,r):t.setEdge(i,a),a}),this}setEdge(){var e,r,t,s,i=!1,a=arguments[0];typeof a=="object"&&a!==null&&"v"in a?(e=a.v,r=a.w,t=a.name,arguments.length===2&&(s=arguments[1],i=!0)):(e=a,r=arguments[1],t=arguments[3],arguments.length>2&&(s=arguments[2],i=!0)),e=""+e,r=""+r,t!==void 0&&(t=""+t);var o=g(this._isDirected,e,r,t);if(Object.hasOwn(this._edgeLabels,o))return i&&(this._edgeLabels[o]=s),this;if(t!==void 0&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(r),this._edgeLabels[o]=i?s:this._defaultEdgeLabelFn(e,r,t);var u=pe(this._isDirected,e,r,t);return e=u.v,r=u.w,Object.freeze(u),this._edgeObjs[o]=u,q(this._preds[r],e),q(this._sucs[e],r),this._in[r][o]=u,this._out[e][o]=u,this._edgeCount++,this}edge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t);return this._edgeLabels[s]}edgeAsObj(){let e=this.edge(...arguments);return typeof e!="object"?{label:e}:e}hasEdge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t);return Object.hasOwn(this._edgeLabels,s)}removeEdge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t),i=this._edgeObjs[s];return i&&(e=i.v,r=i.w,delete this._edgeLabels[s],delete this._edgeObjs[s],x(this._preds[r],e),x(this._sucs[e],r),delete this._in[r][s],delete this._out[e][s],this._edgeCount--),this}inEdges(e,r){var t=this._in[e];if(t){var s=Object.values(t);return r?s.filter(i=>i.v===r):s}}outEdges(e,r){var t=this._out[e];if(t){var s=Object.values(t);return r?s.filter(i=>i.w===r):s}}nodeEdges(e,r){var t=this.inEdges(e,r);if(t)return t.concat(this.outEdges(e,r))}};function q(n,e){n[e]?n[e]++:n[e]=1}function x(n,e){--n[e]||delete n[e]}function g(n,e,r,t){var s=""+e,i=""+r;if(!n&&s>i){var a=s;s=i,i=a}return s+C+i+C+(t===void 0?_e:t)}function pe(n,e,r,t){var s=""+e,i=""+r;if(!n&&s>i){var a=s;s=i,i=a}var o={v:s,w:i};return t&&(o.name=t),o}function w(n,e){return g(n,e.v,e.w,e.name)}D.exports=m});var F=c((Be,L)=>{L.exports="2.2.5-pre"});var T=c((Je,A)=>{A.exports={Graph:b(),version:F()}});var P=c((Xe,M)=>{var ve=b();M.exports={write:ge,read:we};function ge(n){var e={options:{directed:n.isDirected(),multigraph:n.isMultigraph(),compound:n.isCompound()},nodes:Ee(n),edges:be(n)};return n.graph()!==void 0&&(e.value=structuredClone(n.graph())),e}function Ee(n){return n.nodes().map(function(e){var r=n.node(e),t=n.parent(e),s={v:e};return r!==void 0&&(s.value=r),t!==void 0&&(s.parent=t),s})}function be(n){return n.edges().map(function(e){var r=n.edge(e),t={v:e.v,w:e.w};return e.name!==void 0&&(t.name=e.name),r!==void 0&&(t.value=r),t})}function we(n){var e=new ve(n.options).setGraph(n.value);return n.nodes.forEach(function(r){e.setNode(r.v,r.value),r.parent&&e.setParent(r.v,r.parent)}),n.edges.forEach(function(r){e.setEdge({v:r.v,w:r.w,name:r.name},r.value)}),e}});var S=c((Ze,G)=>{G.exports=me;function me(n){var e={},r=[],t;function s(i){Object.hasOwn(e,i)||(e[i]=!0,t.push(i),n.successors(i).forEach(s),n.predecessors(i).forEach(s))}return n.nodes().forEach(function(i){t=[],s(i),t.length&&r.push(t)}),r}});var j=c(($e,V)=>{var O=class{constructor(){d(this,"_arr",[]);d(this,"_keyIndices",{})}size(){return this._arr.length}keys(){return this._arr.map(function(e){return e.key})}has(e){return Object.hasOwn(this._keyIndices,e)}priority(e){var r=this._keyIndices[e];if(r!==void 0)return this._arr[r].priority}min(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key}add(e,r){var t=this._keyIndices;if(e=String(e),!Object.hasOwn(t,e)){var s=this._arr,i=s.length;return t[e]=i,s.push({key:e,priority:r}),this._decrease(i),!0}return!1}removeMin(){this._swap(0,this._arr.length-1);var e=this._arr.pop();return delete this._keyIndices[e.key],this._heapify(0),e.key}decrease(e,r){var t=this._keyIndices[e];if(r>this._arr[t].priority)throw new Error("New priority is greater than current priority. Key: "+e+" Old: "+this._arr[t].priority+" New: "+r);this._arr[t].priority=r,this._decrease(t)}_heapify(e){var r=this._arr,t=2*e,s=t+1,i=e;t>1,!(r[s].priority{var Oe=j();z.exports=ye;var je=()=>1;function ye(n,e,r,t){return Ne(n,String(e),r||je,t||function(s){return n.outEdges(s)})}function Ne(n,e,r,t){var s={},i=new Oe,a,o,u=function(h){var f=h.v!==a?h.v:h.w,l=s[f],_=r(h),v=o.distance+_;if(_<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+h+" Weight: "+_);v0&&(a=i.removeMin(),o=s[a],o.distance!==Number.POSITIVE_INFINITY);)t(a).forEach(u);return s}});var W=c((tr,U)=>{var ke=y();U.exports=Ie;function Ie(n,e,r){return n.nodes().reduce(function(t,s){return t[s]=ke(n,s,e,r),t},{})}});var N=c((sr,Y)=>{Y.exports=Ce;function Ce(n){var e=0,r=[],t={},s=[];function i(a){var o=t[a]={onStack:!0,lowlink:e,index:e++};if(r.push(a),n.successors(a).forEach(function(f){Object.hasOwn(t,f)?t[f].onStack&&(o.lowlink=Math.min(o.lowlink,t[f].index)):(i(f),o.lowlink=Math.min(o.lowlink,t[f].lowlink))}),o.lowlink===o.index){var u=[],h;do h=r.pop(),t[h].onStack=!1,u.push(h);while(a!==h);s.push(u)}}return n.nodes().forEach(function(a){Object.hasOwn(t,a)||i(a)}),s}});var K=c((ir,H)=>{var qe=N();H.exports=xe;function xe(n){return qe(n).filter(function(e){return e.length>1||e.length===1&&n.hasEdge(e[0],e[0])})}});var Q=c((nr,R)=>{R.exports=Le;var De=()=>1;function Le(n,e,r){return Fe(n,e||De,r||function(t){return n.outEdges(t)})}function Fe(n,e,r){var t={},s=n.nodes();return s.forEach(function(i){t[i]={},t[i][i]={distance:0},s.forEach(function(a){i!==a&&(t[i][a]={distance:Number.POSITIVE_INFINITY})}),r(i).forEach(function(a){var o=a.v===i?a.w:a.v,u=e(a);t[i][o]={distance:u,predecessor:i}})}),s.forEach(function(i){var a=t[i];s.forEach(function(o){var u=t[o];s.forEach(function(h){var f=u[i],l=a[h],_=u[h],v=f.distance+l.distance;v<_.distance&&(_.distance=v,_.predecessor=l.predecessor)})})}),t}});var k=c((ar,J)=>{function B(n){var e={},r={},t=[];function s(i){if(Object.hasOwn(r,i))throw new E;Object.hasOwn(e,i)||(r[i]=!0,e[i]=!0,n.predecessors(i).forEach(s),delete r[i],t.push(i))}if(n.sinks().forEach(s),Object.keys(e).length!==n.nodeCount())throw new E;return t}var E=class extends Error{constructor(){super(...arguments)}};J.exports=B;B.CycleException=E});var $=c((or,Z)=>{var X=k();Z.exports=Ae;function Ae(n){try{X(n)}catch(e){if(e instanceof X.CycleException)return!1;throw e}return!0}});var I=c((ur,re)=>{re.exports=Te;function Te(n,e,r){Array.isArray(e)||(e=[e]);var t=n.isDirected()?o=>n.successors(o):o=>n.neighbors(o),s=r==="post"?Me:Pe,i=[],a={};return e.forEach(o=>{if(!n.hasNode(o))throw new Error("Graph does not have node: "+o);s(o,t,a,i)}),i}function Me(n,e,r,t){for(var s=[[n,!1]];s.length>0;){var i=s.pop();i[1]?t.push(i[0]):Object.hasOwn(r,i[0])||(r[i[0]]=!0,s.push([i[0],!0]),ee(e(i[0]),a=>s.push([a,!1])))}}function Pe(n,e,r,t){for(var s=[n];s.length>0;){var i=s.pop();Object.hasOwn(r,i)||(r[i]=!0,t.push(i),ee(e(i),a=>s.push(a)))}}function ee(n,e){for(var r=n.length;r--;)e(n[r],r,n);return n}});var se=c((hr,te)=>{var Ge=I();te.exports=Se;function Se(n,e){return Ge(n,e,"post")}});var ne=c((dr,ie)=>{var Ve=I();ie.exports=ze;function ze(n,e){return Ve(n,e,"pre")}});var oe=c((cr,ae)=>{var Ue=b(),We=j();ae.exports=Ye;function Ye(n,e){var r=new Ue,t={},s=new We,i;function a(u){var h=u.v===i?u.w:u.v,f=s.priority(h);if(f!==void 0){var l=e(u);l0;){if(i=s.removeMin(),Object.hasOwn(t,i))r.setEdge(i,t[i]);else{if(o)throw new Error("Input graph is not connected: "+n);o=!0}n.nodeEdges(i).forEach(a)}return r}});var he=c((fr,ue)=>{ue.exports={components:S(),dijkstra:y(),dijkstraAll:W(),findCycles:K(),floydWarshall:Q(),isAcyclic:$(),postorder:se(),preorder:ne(),prim:oe(),tarjan:N(),topsort:k()}});var He=c((lr,ce)=>{var de=T();ce.exports={Graph:de.Graph,json:P(),alg:he(),version:de.version}});return He();})(); +//# sourceMappingURL=dagre.min.js.map diff --git a/dist/dagre.min.js.map b/dist/dagre.min.js.map new file mode 100644 index 00000000..db0d2d00 --- /dev/null +++ b/dist/dagre.min.js.map @@ -0,0 +1,7 @@ +{ + "version": 3, + "sources": ["../lib/graph.js", "../lib/version.js", "../lib/index.js", "../lib/json.js", "../lib/alg/components.js", "../lib/data/priority-queue.js", "../lib/alg/dijkstra.js", "../lib/alg/dijkstra-all.js", "../lib/alg/tarjan.js", "../lib/alg/find-cycles.js", "../lib/alg/floyd-warshall.js", "../lib/alg/topsort.js", "../lib/alg/is-acyclic.js", "../lib/alg/dfs.js", "../lib/alg/postorder.js", "../lib/alg/preorder.js", "../lib/alg/prim.js", "../lib/alg/index.js", "../index.js"], + "sourcesContent": ["\"use strict\";\n\nvar DEFAULT_EDGE_NAME = \"\\x00\";\nvar GRAPH_NODE = \"\\x00\";\nvar EDGE_KEY_DELIM = \"\\x01\";\n\n// Implementation notes:\n//\n// * Node id query functions should return string ids for the nodes\n// * Edge id query functions should return an \"edgeObj\", edge object, that is\n// composed of enough information to uniquely identify an edge: {v, w, name}.\n// * Internally we use an \"edgeId\", a stringified form of the edgeObj, to\n// reference edges. This is because we need a performant way to look these\n// edges up and, object properties, which have string keys, are the closest\n// we're going to get to a performant hashtable in JavaScript.\n\nclass Graph {\n _isDirected = true;\n _isMultigraph = false;\n _isCompound = false;\n\n // Label for the graph itself\n _label;\n\n // Defaults to be set when creating a new node\n _defaultNodeLabelFn = () => undefined;\n\n // Defaults to be set when creating a new edge\n _defaultEdgeLabelFn = () => undefined;\n\n // v -> label\n _nodes = {};\n\n // v -> edgeObj\n _in = {};\n\n // u -> v -> Number\n _preds = {};\n\n // v -> edgeObj\n _out = {};\n\n // v -> w -> Number\n _sucs = {};\n\n // e -> edgeObj\n _edgeObjs = {};\n\n // e -> label\n _edgeLabels = {};\n\n /* Number of nodes in the graph. Should only be changed by the implementation. */\n _nodeCount = 0;\n\n /* Number of edges in the graph. Should only be changed by the implementation. */\n _edgeCount = 0;\n\n _parent;\n\n _children;\n\n constructor(opts) {\n if (opts) {\n this._isDirected = Object.hasOwn(opts, \"directed\") ? opts.directed : true;\n this._isMultigraph = Object.hasOwn(opts, \"multigraph\") ? opts.multigraph : false;\n this._isCompound = Object.hasOwn(opts, \"compound\") ? opts.compound : false;\n }\n\n if (this._isCompound) {\n // v -> parent\n this._parent = {};\n\n // v -> children\n this._children = {};\n this._children[GRAPH_NODE] = {};\n }\n }\n\n /* === Graph functions ========= */\n\n /**\n * Whether graph was created with 'directed' flag set to true or not.\n */\n isDirected() {\n return this._isDirected;\n }\n\n /**\n * Whether graph was created with 'multigraph' flag set to true or not.\n */\n isMultigraph() {\n return this._isMultigraph;\n }\n\n /**\n * Whether graph was created with 'compound' flag set to true or not.\n */\n isCompound() {\n return this._isCompound;\n }\n\n /**\n * Sets the label of the graph.\n */\n setGraph(label) {\n this._label = label;\n return this;\n }\n\n /**\n * Gets the graph label.\n */\n graph() {\n return this._label;\n }\n\n\n /* === Node functions ========== */\n\n /**\n * Sets the default node label. If newDefault is a function, it will be\n * invoked ach time when setting a label for a node. Otherwise, this label\n * will be assigned as default label in case if no label was specified while\n * setting a node.\n * Complexity: O(1).\n */\n setDefaultNodeLabel(newDefault) {\n this._defaultNodeLabelFn = newDefault;\n if (typeof newDefault !== 'function') {\n this._defaultNodeLabelFn = () => newDefault;\n }\n\n return this;\n }\n\n /**\n * Gets the number of nodes in the graph.\n * Complexity: O(1).\n */\n nodeCount() {\n return this._nodeCount;\n }\n\n /**\n * Gets all nodes of the graph. Note, the in case of compound graph subnodes are\n * not included in list.\n * Complexity: O(1).\n */\n nodes() {\n return Object.keys(this._nodes);\n }\n\n /**\n * Gets list of nodes without in-edges.\n * Complexity: O(|V|).\n */\n sources() {\n var self = this;\n return this.nodes().filter(v => Object.keys(self._in[v]).length === 0);\n }\n\n /**\n * Gets list of nodes without out-edges.\n * Complexity: O(|V|).\n */\n sinks() {\n var self = this;\n return this.nodes().filter(v => Object.keys(self._out[v]).length === 0);\n }\n\n /**\n * Invokes setNode method for each node in names list.\n * Complexity: O(|names|).\n */\n setNodes(vs, value) {\n var args = arguments;\n var self = this;\n vs.forEach(function(v) {\n if (args.length > 1) {\n self.setNode(v, value);\n } else {\n self.setNode(v);\n }\n });\n return this;\n }\n\n /**\n * Creates or updates the value for the node v in the graph. If label is supplied\n * it is set as the value for the node. If label is not supplied and the node was\n * created by this call then the default node label will be assigned.\n * Complexity: O(1).\n */\n setNode(v, value) {\n if (Object.hasOwn(this._nodes, v)) {\n if (arguments.length > 1) {\n this._nodes[v] = value;\n }\n return this;\n }\n\n this._nodes[v] = arguments.length > 1 ? value : this._defaultNodeLabelFn(v);\n if (this._isCompound) {\n this._parent[v] = GRAPH_NODE;\n this._children[v] = {};\n this._children[GRAPH_NODE][v] = true;\n }\n this._in[v] = {};\n this._preds[v] = {};\n this._out[v] = {};\n this._sucs[v] = {};\n ++this._nodeCount;\n return this;\n }\n\n /**\n * Gets the label of node with specified name.\n * Complexity: O(|V|).\n */\n node(v) {\n return this._nodes[v];\n }\n\n /**\n * Detects whether graph has a node with specified name or not.\n */\n hasNode(v) {\n return Object.hasOwn(this._nodes, v);\n }\n\n /**\n * Remove the node with the name from the graph or do nothing if the node is not in\n * the graph. If the node was removed this function also removes any incident\n * edges.\n * Complexity: O(1).\n */\n removeNode(v) {\n var self = this;\n if (Object.hasOwn(this._nodes, v)) {\n var removeEdge = e => self.removeEdge(self._edgeObjs[e]);\n delete this._nodes[v];\n if (this._isCompound) {\n this._removeFromParentsChildList(v);\n delete this._parent[v];\n this.children(v).forEach(function(child) {\n self.setParent(child);\n });\n delete this._children[v];\n }\n Object.keys(this._in[v]).forEach(removeEdge);\n delete this._in[v];\n delete this._preds[v];\n Object.keys(this._out[v]).forEach(removeEdge);\n delete this._out[v];\n delete this._sucs[v];\n --this._nodeCount;\n }\n return this;\n }\n\n /**\n * Sets node p as a parent for node v if it is defined, or removes the\n * parent for v if p is undefined. Method throws an exception in case of\n * invoking it in context of noncompound graph.\n * Average-case complexity: O(1).\n */\n setParent(v, parent) {\n if (!this._isCompound) {\n throw new Error(\"Cannot set parent in a non-compound graph\");\n }\n\n if (parent === undefined) {\n parent = GRAPH_NODE;\n } else {\n // Coerce parent to string\n parent += \"\";\n for (var ancestor = parent; ancestor !== undefined; ancestor = this.parent(ancestor)) {\n if (ancestor === v) {\n throw new Error(\"Setting \" + parent+ \" as parent of \" + v +\n \" would create a cycle\");\n }\n }\n\n this.setNode(parent);\n }\n\n this.setNode(v);\n this._removeFromParentsChildList(v);\n this._parent[v] = parent;\n this._children[parent][v] = true;\n return this;\n }\n\n _removeFromParentsChildList(v) {\n delete this._children[this._parent[v]][v];\n }\n\n /**\n * Gets parent node for node v.\n * Complexity: O(1).\n */\n parent(v) {\n if (this._isCompound) {\n var parent = this._parent[v];\n if (parent !== GRAPH_NODE) {\n return parent;\n }\n }\n }\n\n /**\n * Gets list of direct children of node v.\n * Complexity: O(1).\n */\n children(v = GRAPH_NODE) {\n if (this._isCompound) {\n var children = this._children[v];\n if (children) {\n return Object.keys(children);\n }\n } else if (v === GRAPH_NODE) {\n return this.nodes();\n } else if (this.hasNode(v)) {\n return [];\n }\n }\n\n /**\n * Return all nodes that are predecessors of the specified node or undefined if node v is not in\n * the graph. Behavior is undefined for undirected graphs - use neighbors instead.\n * Complexity: O(|V|).\n */\n predecessors(v) {\n var predsV = this._preds[v];\n if (predsV) {\n return Object.keys(predsV);\n }\n }\n\n /**\n * Return all nodes that are successors of the specified node or undefined if node v is not in\n * the graph. Behavior is undefined for undirected graphs - use neighbors instead.\n * Complexity: O(|V|).\n */\n successors(v) {\n var sucsV = this._sucs[v];\n if (sucsV) {\n return Object.keys(sucsV);\n }\n }\n\n /**\n * Return all nodes that are predecessors or successors of the specified node or undefined if\n * node v is not in the graph.\n * Complexity: O(|V|).\n */\n neighbors(v) {\n var preds = this.predecessors(v);\n if (preds) {\n const union = new Set(preds);\n for (var succ of this.successors(v)) {\n union.add(succ);\n }\n\n return Array.from(union.values());\n }\n }\n\n isLeaf(v) {\n var neighbors;\n if (this.isDirected()) {\n neighbors = this.successors(v);\n } else {\n neighbors = this.neighbors(v);\n }\n return neighbors.length === 0;\n }\n\n /**\n * Creates new graph with nodes filtered via filter. Edges incident to rejected node\n * are also removed. In case of compound graph, if parent is rejected by filter,\n * than all its children are rejected too.\n * Average-case complexity: O(|E|+|V|).\n */\n filterNodes(filter) {\n var copy = new this.constructor({\n directed: this._isDirected,\n multigraph: this._isMultigraph,\n compound: this._isCompound\n });\n\n copy.setGraph(this.graph());\n\n var self = this;\n Object.entries(this._nodes).forEach(function([v, value]) {\n if (filter(v)) {\n copy.setNode(v, value);\n }\n });\n\n Object.values(this._edgeObjs).forEach(function(e) {\n if (copy.hasNode(e.v) && copy.hasNode(e.w)) {\n copy.setEdge(e, self.edge(e));\n }\n });\n\n var parents = {};\n function findParent(v) {\n var parent = self.parent(v);\n if (parent === undefined || copy.hasNode(parent)) {\n parents[v] = parent;\n return parent;\n } else if (parent in parents) {\n return parents[parent];\n } else {\n return findParent(parent);\n }\n }\n\n if (this._isCompound) {\n copy.nodes().forEach(v => copy.setParent(v, findParent(v)));\n }\n\n return copy;\n }\n\n /* === Edge functions ========== */\n\n /**\n * Sets the default edge label or factory function. This label will be\n * assigned as default label in case if no label was specified while setting\n * an edge or this function will be invoked each time when setting an edge\n * with no label specified and returned value * will be used as a label for edge.\n * Complexity: O(1).\n */\n setDefaultEdgeLabel(newDefault) {\n this._defaultEdgeLabelFn = newDefault;\n if (typeof newDefault !== 'function') {\n this._defaultEdgeLabelFn = () => newDefault;\n }\n\n return this;\n }\n\n /**\n * Gets the number of edges in the graph.\n * Complexity: O(1).\n */\n edgeCount() {\n return this._edgeCount;\n }\n\n /**\n * Gets edges of the graph. In case of compound graph subgraphs are not considered.\n * Complexity: O(|E|).\n */\n edges() {\n return Object.values(this._edgeObjs);\n }\n\n /**\n * Establish an edges path over the nodes in nodes list. If some edge is already\n * exists, it will update its label, otherwise it will create an edge between pair\n * of nodes with label provided or default label if no label provided.\n * Complexity: O(|nodes|).\n */\n setPath(vs, value) {\n var self = this;\n var args = arguments;\n vs.reduce(function(v, w) {\n if (args.length > 1) {\n self.setEdge(v, w, value);\n } else {\n self.setEdge(v, w);\n }\n return w;\n });\n return this;\n }\n\n /**\n * Creates or updates the label for the edge (v, w) with the optionally supplied\n * name. If label is supplied it is set as the value for the edge. If label is not\n * supplied and the edge was created by this call then the default edge label will\n * be assigned. The name parameter is only useful with multigraphs.\n */\n setEdge() {\n var v, w, name, value;\n var valueSpecified = false;\n var arg0 = arguments[0];\n\n if (typeof arg0 === \"object\" && arg0 !== null && \"v\" in arg0) {\n v = arg0.v;\n w = arg0.w;\n name = arg0.name;\n if (arguments.length === 2) {\n value = arguments[1];\n valueSpecified = true;\n }\n } else {\n v = arg0;\n w = arguments[1];\n name = arguments[3];\n if (arguments.length > 2) {\n value = arguments[2];\n valueSpecified = true;\n }\n }\n\n v = \"\" + v;\n w = \"\" + w;\n if (name !== undefined) {\n name = \"\" + name;\n }\n\n var e = edgeArgsToId(this._isDirected, v, w, name);\n if (Object.hasOwn(this._edgeLabels, e)) {\n if (valueSpecified) {\n this._edgeLabels[e] = value;\n }\n return this;\n }\n\n if (name !== undefined && !this._isMultigraph) {\n throw new Error(\"Cannot set a named edge when isMultigraph = false\");\n }\n\n // It didn't exist, so we need to create it.\n // First ensure the nodes exist.\n this.setNode(v);\n this.setNode(w);\n\n this._edgeLabels[e] = valueSpecified ? value : this._defaultEdgeLabelFn(v, w, name);\n\n var edgeObj = edgeArgsToObj(this._isDirected, v, w, name);\n // Ensure we add undirected edges in a consistent way.\n v = edgeObj.v;\n w = edgeObj.w;\n\n Object.freeze(edgeObj);\n this._edgeObjs[e] = edgeObj;\n incrementOrInitEntry(this._preds[w], v);\n incrementOrInitEntry(this._sucs[v], w);\n this._in[w][e] = edgeObj;\n this._out[v][e] = edgeObj;\n this._edgeCount++;\n return this;\n }\n\n /**\n * Gets the label for the specified edge.\n * Complexity: O(1).\n */\n edge(v, w, name) {\n var e = (arguments.length === 1\n ? edgeObjToId(this._isDirected, arguments[0])\n : edgeArgsToId(this._isDirected, v, w, name));\n return this._edgeLabels[e];\n }\n\n /**\n * Gets the label for the specified edge and converts it to an object.\n * Complexity: O(1)\n */\n edgeAsObj() {\n const edge = this.edge(...arguments);\n if (typeof edge !== \"object\") {\n return {label: edge};\n }\n\n return edge;\n }\n\n /**\n * Detects whether the graph contains specified edge or not. No subgraphs are considered.\n * Complexity: O(1).\n */\n hasEdge(v, w, name) {\n var e = (arguments.length === 1\n ? edgeObjToId(this._isDirected, arguments[0])\n : edgeArgsToId(this._isDirected, v, w, name));\n return Object.hasOwn(this._edgeLabels, e);\n }\n\n /**\n * Removes the specified edge from the graph. No subgraphs are considered.\n * Complexity: O(1).\n */\n removeEdge(v, w, name) {\n var e = (arguments.length === 1\n ? edgeObjToId(this._isDirected, arguments[0])\n : edgeArgsToId(this._isDirected, v, w, name));\n var edge = this._edgeObjs[e];\n if (edge) {\n v = edge.v;\n w = edge.w;\n delete this._edgeLabels[e];\n delete this._edgeObjs[e];\n decrementOrRemoveEntry(this._preds[w], v);\n decrementOrRemoveEntry(this._sucs[v], w);\n delete this._in[w][e];\n delete this._out[v][e];\n this._edgeCount--;\n }\n return this;\n }\n\n /**\n * Return all edges that point to the node v. Optionally filters those edges down to just those\n * coming from node u. Behavior is undefined for undirected graphs - use nodeEdges instead.\n * Complexity: O(|E|).\n */\n inEdges(v, u) {\n var inV = this._in[v];\n if (inV) {\n var edges = Object.values(inV);\n if (!u) {\n return edges;\n }\n return edges.filter(edge => edge.v === u);\n }\n }\n\n /**\n * Return all edges that are pointed at by node v. Optionally filters those edges down to just\n * those point to w. Behavior is undefined for undirected graphs - use nodeEdges instead.\n * Complexity: O(|E|).\n */\n outEdges(v, w) {\n var outV = this._out[v];\n if (outV) {\n var edges = Object.values(outV);\n if (!w) {\n return edges;\n }\n return edges.filter(edge => edge.w === w);\n }\n }\n\n /**\n * Returns all edges to or from node v regardless of direction. Optionally filters those edges\n * down to just those between nodes v and w regardless of direction.\n * Complexity: O(|E|).\n */\n nodeEdges(v, w) {\n var inEdges = this.inEdges(v, w);\n if (inEdges) {\n return inEdges.concat(this.outEdges(v, w));\n }\n }\n}\n\nfunction incrementOrInitEntry(map, k) {\n if (map[k]) {\n map[k]++;\n } else {\n map[k] = 1;\n }\n}\n\nfunction decrementOrRemoveEntry(map, k) {\n if (!--map[k]) { delete map[k]; }\n}\n\nfunction edgeArgsToId(isDirected, v_, w_, name) {\n var v = \"\" + v_;\n var w = \"\" + w_;\n if (!isDirected && v > w) {\n var tmp = v;\n v = w;\n w = tmp;\n }\n return v + EDGE_KEY_DELIM + w + EDGE_KEY_DELIM +\n (name === undefined ? DEFAULT_EDGE_NAME : name);\n}\n\nfunction edgeArgsToObj(isDirected, v_, w_, name) {\n var v = \"\" + v_;\n var w = \"\" + w_;\n if (!isDirected && v > w) {\n var tmp = v;\n v = w;\n w = tmp;\n }\n var edgeObj = { v: v, w: w };\n if (name) {\n edgeObj.name = name;\n }\n return edgeObj;\n}\n\nfunction edgeObjToId(isDirected, edgeObj) {\n return edgeArgsToId(isDirected, edgeObj.v, edgeObj.w, edgeObj.name);\n}\n\nmodule.exports = Graph;\n", "module.exports = '2.2.5-pre';\n", "// Includes only the \"core\" of graphlib\nmodule.exports = {\n Graph: require(\"./graph\"),\n version: require(\"./version\")\n};\n", "var Graph = require(\"./graph\");\n\nmodule.exports = {\n write: write,\n read: read\n};\n\n/**\n * Creates a JSON representation of the graph that can be serialized to a string with\n * JSON.stringify. The graph can later be restored using json.read.\n */\nfunction write(g) {\n var json = {\n options: {\n directed: g.isDirected(),\n multigraph: g.isMultigraph(),\n compound: g.isCompound()\n },\n nodes: writeNodes(g),\n edges: writeEdges(g)\n };\n\n if (g.graph() !== undefined) {\n json.value = structuredClone(g.graph());\n }\n return json;\n}\n\nfunction writeNodes(g) {\n return g.nodes().map(function(v) {\n var nodeValue = g.node(v);\n var parent = g.parent(v);\n var node = { v: v };\n if (nodeValue !== undefined) {\n node.value = nodeValue;\n }\n if (parent !== undefined) {\n node.parent = parent;\n }\n return node;\n });\n}\n\nfunction writeEdges(g) {\n return g.edges().map(function(e) {\n var edgeValue = g.edge(e);\n var edge = { v: e.v, w: e.w };\n if (e.name !== undefined) {\n edge.name = e.name;\n }\n if (edgeValue !== undefined) {\n edge.value = edgeValue;\n }\n return edge;\n });\n}\n\n/**\n * Takes JSON as input and returns the graph representation.\n *\n * @example\n * var g2 = graphlib.json.read(JSON.parse(str));\n * g2.nodes();\n * // ['a', 'b']\n * g2.edges()\n * // [ { v: 'a', w: 'b' } ]\n */\nfunction read(json) {\n var g = new Graph(json.options).setGraph(json.value);\n json.nodes.forEach(function(entry) {\n g.setNode(entry.v, entry.value);\n if (entry.parent) {\n g.setParent(entry.v, entry.parent);\n }\n });\n json.edges.forEach(function(entry) {\n g.setEdge({ v: entry.v, w: entry.w, name: entry.name }, entry.value);\n });\n return g;\n}\n", "module.exports = components;\n\nfunction components(g) {\n var visited = {};\n var cmpts = [];\n var cmpt;\n\n function dfs(v) {\n if (Object.hasOwn(visited, v)) return;\n visited[v] = true;\n cmpt.push(v);\n g.successors(v).forEach(dfs);\n g.predecessors(v).forEach(dfs);\n }\n\n g.nodes().forEach(function(v) {\n cmpt = [];\n dfs(v);\n if (cmpt.length) {\n cmpts.push(cmpt);\n }\n });\n\n return cmpts;\n}\n", "/**\n * A min-priority queue data structure. This algorithm is derived from Cormen,\n * et al., \"Introduction to Algorithms\". The basic idea of a min-priority\n * queue is that you can efficiently (in O(1) time) get the smallest key in\n * the queue. Adding and removing elements takes O(log n) time. A key can\n * have its priority decreased in O(log n) time.\n */\nclass PriorityQueue {\n _arr = [];\n _keyIndices = {};\n\n /**\n * Returns the number of elements in the queue. Takes `O(1)` time.\n */\n size() {\n return this._arr.length;\n }\n\n /**\n * Returns the keys that are in the queue. Takes `O(n)` time.\n */\n keys() {\n return this._arr.map(function(x) { return x.key; });\n }\n\n /**\n * Returns `true` if **key** is in the queue and `false` if not.\n */\n has(key) {\n return Object.hasOwn(this._keyIndices, key);\n }\n\n /**\n * Returns the priority for **key**. If **key** is not present in the queue\n * then this function returns `undefined`. Takes `O(1)` time.\n *\n * @param {Object} key\n */\n priority(key) {\n var index = this._keyIndices[key];\n if (index !== undefined) {\n return this._arr[index].priority;\n }\n }\n\n /**\n * Returns the key for the minimum element in this queue. If the queue is\n * empty this function throws an Error. Takes `O(1)` time.\n */\n min() {\n if (this.size() === 0) {\n throw new Error(\"Queue underflow\");\n }\n return this._arr[0].key;\n }\n\n /**\n * Inserts a new key into the priority queue. If the key already exists in\n * the queue this function returns `false`; otherwise it will return `true`.\n * Takes `O(n)` time.\n *\n * @param {Object} key the key to add\n * @param {Number} priority the initial priority for the key\n */\n add(key, priority) {\n var keyIndices = this._keyIndices;\n key = String(key);\n if (!Object.hasOwn(keyIndices, key)) {\n var arr = this._arr;\n var index = arr.length;\n keyIndices[key] = index;\n arr.push({key: key, priority: priority});\n this._decrease(index);\n return true;\n }\n return false;\n }\n\n /**\n * Removes and returns the smallest key in the queue. Takes `O(log n)` time.\n */\n removeMin() {\n this._swap(0, this._arr.length - 1);\n var min = this._arr.pop();\n delete this._keyIndices[min.key];\n this._heapify(0);\n return min.key;\n }\n\n /**\n * Decreases the priority for **key** to **priority**. If the new priority is\n * greater than the previous priority, this function will throw an Error.\n *\n * @param {Object} key the key for which to raise priority\n * @param {Number} priority the new priority for the key\n */\n decrease(key, priority) {\n var index = this._keyIndices[key];\n if (priority > this._arr[index].priority) {\n throw new Error(\"New priority is greater than current priority. \" +\n \"Key: \" + key + \" Old: \" + this._arr[index].priority + \" New: \" + priority);\n }\n this._arr[index].priority = priority;\n this._decrease(index);\n }\n\n _heapify(i) {\n var arr = this._arr;\n var l = 2 * i;\n var r = l + 1;\n var largest = i;\n if (l < arr.length) {\n largest = arr[l].priority < arr[largest].priority ? l : largest;\n if (r < arr.length) {\n largest = arr[r].priority < arr[largest].priority ? r : largest;\n }\n if (largest !== i) {\n this._swap(i, largest);\n this._heapify(largest);\n }\n }\n }\n\n _decrease(index) {\n var arr = this._arr;\n var priority = arr[index].priority;\n var parent;\n while (index !== 0) {\n parent = index >> 1;\n if (arr[parent].priority < priority) {\n break;\n }\n this._swap(index, parent);\n index = parent;\n }\n }\n\n _swap(i, j) {\n var arr = this._arr;\n var keyIndices = this._keyIndices;\n var origArrI = arr[i];\n var origArrJ = arr[j];\n arr[i] = origArrJ;\n arr[j] = origArrI;\n keyIndices[origArrJ.key] = i;\n keyIndices[origArrI.key] = j;\n }\n}\n\nmodule.exports = PriorityQueue;\n", "var PriorityQueue = require(\"../data/priority-queue\");\n\nmodule.exports = dijkstra;\n\nvar DEFAULT_WEIGHT_FUNC = () => 1;\n\nfunction dijkstra(g, source, weightFn, edgeFn) {\n return runDijkstra(g, String(source),\n weightFn || DEFAULT_WEIGHT_FUNC,\n edgeFn || function(v) { return g.outEdges(v); });\n}\n\nfunction runDijkstra(g, source, weightFn, edgeFn) {\n var results = {};\n var pq = new PriorityQueue();\n var v, vEntry;\n\n var updateNeighbors = function(edge) {\n var w = edge.v !== v ? edge.v : edge.w;\n var wEntry = results[w];\n var weight = weightFn(edge);\n var distance = vEntry.distance + weight;\n\n if (weight < 0) {\n throw new Error(\"dijkstra does not allow negative edge weights. \" +\n \"Bad edge: \" + edge + \" Weight: \" + weight);\n }\n\n if (distance < wEntry.distance) {\n wEntry.distance = distance;\n wEntry.predecessor = v;\n pq.decrease(w, distance);\n }\n };\n\n g.nodes().forEach(function(v) {\n var distance = v === source ? 0 : Number.POSITIVE_INFINITY;\n results[v] = { distance: distance };\n pq.add(v, distance);\n });\n\n while (pq.size() > 0) {\n v = pq.removeMin();\n vEntry = results[v];\n if (vEntry.distance === Number.POSITIVE_INFINITY) {\n break;\n }\n\n edgeFn(v).forEach(updateNeighbors);\n }\n\n return results;\n}\n", "var dijkstra = require(\"./dijkstra\");\n\nmodule.exports = dijkstraAll;\n\nfunction dijkstraAll(g, weightFunc, edgeFunc) {\n return g.nodes().reduce(function(acc, v) {\n acc[v] = dijkstra(g, v, weightFunc, edgeFunc);\n return acc;\n }, {});\n}\n", "module.exports = tarjan;\n\nfunction tarjan(g) {\n var index = 0;\n var stack = [];\n var visited = {}; // node id -> { onStack, lowlink, index }\n var results = [];\n\n function dfs(v) {\n var entry = visited[v] = {\n onStack: true,\n lowlink: index,\n index: index++\n };\n stack.push(v);\n\n g.successors(v).forEach(function(w) {\n if (!Object.hasOwn(visited, w)) {\n dfs(w);\n entry.lowlink = Math.min(entry.lowlink, visited[w].lowlink);\n } else if (visited[w].onStack) {\n entry.lowlink = Math.min(entry.lowlink, visited[w].index);\n }\n });\n\n if (entry.lowlink === entry.index) {\n var cmpt = [];\n var w;\n do {\n w = stack.pop();\n visited[w].onStack = false;\n cmpt.push(w);\n } while (v !== w);\n results.push(cmpt);\n }\n }\n\n g.nodes().forEach(function(v) {\n if (!Object.hasOwn(visited, v)) {\n dfs(v);\n }\n });\n\n return results;\n}\n", "var tarjan = require(\"./tarjan\");\n\nmodule.exports = findCycles;\n\nfunction findCycles(g) {\n return tarjan(g).filter(function(cmpt) {\n return cmpt.length > 1 || (cmpt.length === 1 && g.hasEdge(cmpt[0], cmpt[0]));\n });\n}\n", "module.exports = floydWarshall;\n\nvar DEFAULT_WEIGHT_FUNC = () => 1;\n\nfunction floydWarshall(g, weightFn, edgeFn) {\n return runFloydWarshall(g,\n weightFn || DEFAULT_WEIGHT_FUNC,\n edgeFn || function(v) { return g.outEdges(v); });\n}\n\nfunction runFloydWarshall(g, weightFn, edgeFn) {\n var results = {};\n var nodes = g.nodes();\n\n nodes.forEach(function(v) {\n results[v] = {};\n results[v][v] = { distance: 0 };\n nodes.forEach(function(w) {\n if (v !== w) {\n results[v][w] = { distance: Number.POSITIVE_INFINITY };\n }\n });\n edgeFn(v).forEach(function(edge) {\n var w = edge.v === v ? edge.w : edge.v;\n var d = weightFn(edge);\n results[v][w] = { distance: d, predecessor: v };\n });\n });\n\n nodes.forEach(function(k) {\n var rowK = results[k];\n nodes.forEach(function(i) {\n var rowI = results[i];\n nodes.forEach(function(j) {\n var ik = rowI[k];\n var kj = rowK[j];\n var ij = rowI[j];\n var altDistance = ik.distance + kj.distance;\n if (altDistance < ij.distance) {\n ij.distance = altDistance;\n ij.predecessor = kj.predecessor;\n }\n });\n });\n });\n\n return results;\n}\n", "function topsort(g) {\n var visited = {};\n var stack = {};\n var results = [];\n\n function visit(node) {\n if (Object.hasOwn(stack, node)) {\n throw new CycleException();\n }\n\n if (!Object.hasOwn(visited, node)) {\n stack[node] = true;\n visited[node] = true;\n g.predecessors(node).forEach(visit);\n delete stack[node];\n results.push(node);\n }\n }\n\n g.sinks().forEach(visit);\n\n if (Object.keys(visited).length !== g.nodeCount()) {\n throw new CycleException();\n }\n\n return results;\n}\n\nclass CycleException extends Error {\n constructor() {\n super(...arguments);\n }\n}\n\nmodule.exports = topsort;\ntopsort.CycleException = CycleException;\n", "var topsort = require(\"./topsort\");\n\nmodule.exports = isAcyclic;\n\nfunction isAcyclic(g) {\n try {\n topsort(g);\n } catch (e) {\n if (e instanceof topsort.CycleException) {\n return false;\n }\n throw e;\n }\n return true;\n}\n", "module.exports = dfs;\n\n/*\n * A helper that preforms a pre- or post-order traversal on the input graph\n * and returns the nodes in the order they were visited. If the graph is\n * undirected then this algorithm will navigate using neighbors. If the graph\n * is directed then this algorithm will navigate using successors.\n *\n * If the order is not \"post\", it will be treated as \"pre\".\n */\nfunction dfs(g, vs, order) {\n if (!Array.isArray(vs)) {\n vs = [vs];\n }\n\n var navigation = g.isDirected() ? v => g.successors(v) : v => g.neighbors(v);\n var orderFunc = order === \"post\" ? postOrderDfs : preOrderDfs;\n\n var acc = [];\n var visited = {};\n vs.forEach(v => {\n if (!g.hasNode(v)) {\n throw new Error(\"Graph does not have node: \" + v);\n }\n\n orderFunc(v, navigation, visited, acc);\n });\n\n return acc;\n}\n\nfunction postOrderDfs(v, navigation, visited, acc) {\n var stack = [[v, false]];\n while (stack.length > 0) {\n var curr = stack.pop();\n if (curr[1]) {\n acc.push(curr[0]);\n } else {\n if (!Object.hasOwn(visited, curr[0])) {\n visited[curr[0]] = true;\n stack.push([curr[0], true]);\n forEachRight(navigation(curr[0]), w => stack.push([w, false]));\n }\n }\n }\n}\n\nfunction preOrderDfs(v, navigation, visited, acc) {\n var stack = [v];\n while (stack.length > 0) {\n var curr = stack.pop();\n if (!Object.hasOwn(visited, curr)) {\n visited[curr] = true;\n acc.push(curr);\n forEachRight(navigation(curr), w => stack.push(w));\n }\n }\n}\n\nfunction forEachRight(array, iteratee) {\n var length = array.length;\n while (length--) {\n iteratee(array[length], length, array);\n }\n\n return array;\n}\n", "var dfs = require(\"./dfs\");\n\nmodule.exports = postorder;\n\nfunction postorder(g, vs) {\n return dfs(g, vs, \"post\");\n}\n", "var dfs = require(\"./dfs\");\n\nmodule.exports = preorder;\n\nfunction preorder(g, vs) {\n return dfs(g, vs, \"pre\");\n}\n", "var Graph = require(\"../graph\");\nvar PriorityQueue = require(\"../data/priority-queue\");\n\nmodule.exports = prim;\n\nfunction prim(g, weightFunc) {\n var result = new Graph();\n var parents = {};\n var pq = new PriorityQueue();\n var v;\n\n function updateNeighbors(edge) {\n var w = edge.v === v ? edge.w : edge.v;\n var pri = pq.priority(w);\n if (pri !== undefined) {\n var edgeWeight = weightFunc(edge);\n if (edgeWeight < pri) {\n parents[w] = v;\n pq.decrease(w, edgeWeight);\n }\n }\n }\n\n if (g.nodeCount() === 0) {\n return result;\n }\n\n g.nodes().forEach(function(v) {\n pq.add(v, Number.POSITIVE_INFINITY);\n result.setNode(v);\n });\n\n // Start from an arbitrary node\n pq.decrease(g.nodes()[0], 0);\n\n var init = false;\n while (pq.size() > 0) {\n v = pq.removeMin();\n if (Object.hasOwn(parents, v)) {\n result.setEdge(v, parents[v]);\n } else if (init) {\n throw new Error(\"Input graph is not connected: \" + g);\n } else {\n init = true;\n }\n\n g.nodeEdges(v).forEach(updateNeighbors);\n }\n\n return result;\n}\n", "module.exports = {\n components: require(\"./components\"),\n dijkstra: require(\"./dijkstra\"),\n dijkstraAll: require(\"./dijkstra-all\"),\n findCycles: require(\"./find-cycles\"),\n floydWarshall: require(\"./floyd-warshall\"),\n isAcyclic: require(\"./is-acyclic\"),\n postorder: require(\"./postorder\"),\n preorder: require(\"./preorder\"),\n prim: require(\"./prim\"),\n tarjan: require(\"./tarjan\"),\n topsort: require(\"./topsort\")\n};\n", "/**\n * Copyright (c) 2014, Chris Pettitt\n * All rights reserved.\n *\n * Redistribution and use in source and binary forms, with or without\n * modification, are permitted provided that the following conditions are met:\n *\n * 1. Redistributions of source code must retain the above copyright notice, this\n * list of conditions and the following disclaimer.\n *\n * 2. Redistributions in binary form must reproduce the above copyright notice,\n * this list of conditions and the following disclaimer in the documentation\n * and/or other materials provided with the distribution.\n *\n * 3. Neither the name of the copyright holder nor the names of its contributors\n * may be used to endorse or promote products derived from this software without\n * specific prior written permission.\n *\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND\n * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED\n * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\n * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE\n * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL\n * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR\n * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER\n * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,\n * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\n * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n */\n\nvar lib = require(\"./lib\");\n\nmodule.exports = {\n Graph: lib.Graph,\n json: require(\"./lib/json\"),\n alg: require(\"./lib/alg\"),\n version: lib.version\n};\n"], + "mappings": "sPAAA,IAAAA,EAAAC,EAAA,CAAAC,GAAAC,IAAA,cAEA,IAAIC,GAAoB,KACpBC,EAAa,KACbC,EAAiB,IAYfC,EAAN,KAAY,CA6CV,YAAYC,EAAM,CA5ClBC,EAAA,mBAAc,IACdA,EAAA,qBAAgB,IAChBA,EAAA,mBAAc,IAGdA,EAAA,eAGAA,EAAA,2BAAsB,IAAG,IAGzBA,EAAA,2BAAsB,IAAG,IAGzBA,EAAA,cAAS,CAAC,GAGVA,EAAA,WAAM,CAAC,GAGPA,EAAA,cAAS,CAAC,GAGVA,EAAA,YAAO,CAAC,GAGRA,EAAA,aAAQ,CAAC,GAGTA,EAAA,iBAAY,CAAC,GAGbA,EAAA,mBAAc,CAAC,GAGfA,EAAA,kBAAa,GAGbA,EAAA,kBAAa,GAEbA,EAAA,gBAEAA,EAAA,kBAGMD,IACF,KAAK,YAAc,OAAO,OAAOA,EAAM,UAAU,EAAIA,EAAK,SAAW,GACrE,KAAK,cAAgB,OAAO,OAAOA,EAAM,YAAY,EAAIA,EAAK,WAAa,GAC3E,KAAK,YAAc,OAAO,OAAOA,EAAM,UAAU,EAAIA,EAAK,SAAW,IAGnE,KAAK,cAEP,KAAK,QAAU,CAAC,EAGhB,KAAK,UAAY,CAAC,EAClB,KAAK,UAAUH,CAAU,EAAI,CAAC,EAElC,CAOA,YAAa,CACX,OAAO,KAAK,WACd,CAKA,cAAe,CACb,OAAO,KAAK,aACd,CAKA,YAAa,CACX,OAAO,KAAK,WACd,CAKA,SAASK,EAAO,CACd,YAAK,OAASA,EACP,IACT,CAKA,OAAQ,CACN,OAAO,KAAK,MACd,CAYA,oBAAoBC,EAAY,CAC9B,YAAK,oBAAsBA,EACv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C,CAClB,CAAC,EAGDD,EAAG,SAASJ,EAAE,MAAM,EAAE,CAAC,EAAG,CAAC,EAG3B,QADIW,EAAO,GACJP,EAAG,KAAK,EAAI,GAAG,CAEpB,GADAC,EAAID,EAAG,UAAU,EACb,OAAO,OAAOD,EAASE,CAAC,EAC1BH,EAAO,QAAQG,EAAGF,EAAQE,CAAC,CAAC,MACvB,IAAIM,EACT,MAAM,IAAI,MAAM,iCAAmCX,CAAC,EAEpDW,EAAO,GAGTX,EAAE,UAAUK,CAAC,EAAE,QAAQC,CAAe,CACxC,CAEA,OAAOJ,CACT,IClDA,IAAAU,GAAAC,EAAA,CAAAC,GAAAC,KAAA,CAAAA,GAAO,QAAU,CACf,WAAY,IACZ,SAAU,IACV,YAAa,IACb,WAAY,IACZ,cAAe,IACf,UAAW,IACX,UAAW,KACX,SAAU,KACV,KAAM,KACN,OAAQ,IACR,QAAS,GACX,ICZA,IAAAC,GAAAC,EAAA,CAAAC,GAAAC,KAAA,CA8BA,IAAIC,GAAM,IAEVD,GAAO,QAAU,CACf,MAAOC,GAAI,MACX,KAAM,IACN,IAAK,KACL,QAASA,GAAI,OACf", + "names": ["require_graph", "__commonJSMin", "exports", "module", "DEFAULT_EDGE_NAME", "GRAPH_NODE", "EDGE_KEY_DELIM", "Graph", "opts", "__publicField", "label", "newDefault", "self", "v", "vs", "value", "args", "removeEdge", "e", "child", "parent", "ancestor", "children", "predsV", "sucsV", "preds", "union", "succ", "neighbors", "filter", "copy", "parents", "findParent", "w", "name", "valueSpecified", "arg0", "edgeArgsToId", "edgeObj", "edgeArgsToObj", "incrementOrInitEntry", "edgeObjToId", "edge", "decrementOrRemoveEntry", "u", "inV", "edges", "outV", "inEdges", "map", "k", "isDirected", "v_", "w_", "tmp", "require_version", "__commonJSMin", "exports", "module", "require_lib", "__commonJSMin", "exports", "module", "require_json", "__commonJSMin", "exports", "module", "Graph", "write", "read", "g", "json", "writeNodes", "writeEdges", "v", "nodeValue", "parent", "node", "edgeValue", "edge", "entry", "require_components", "__commonJSMin", "exports", "module", "components", "g", "visited", "cmpts", "cmpt", "dfs", "v", "require_priority_queue", "__commonJSMin", "exports", "module", "PriorityQueue", "__publicField", "x", "key", "index", "priority", "keyIndices", "arr", "min", "i", "l", "r", "largest", "parent", "j", "origArrI", "origArrJ", "require_dijkstra", "__commonJSMin", "exports", "module", "PriorityQueue", "dijkstra", "DEFAULT_WEIGHT_FUNC", "g", "source", "weightFn", "edgeFn", "runDijkstra", "v", "results", "pq", "vEntry", "updateNeighbors", "edge", "w", "wEntry", "weight", "distance", "require_dijkstra_all", "__commonJSMin", "exports", "module", "dijkstra", "dijkstraAll", "g", "weightFunc", "edgeFunc", "acc", "v", "require_tarjan", "__commonJSMin", "exports", "module", "tarjan", "g", "index", "stack", "visited", "results", "dfs", "v", "entry", "w", "cmpt", "require_find_cycles", "__commonJSMin", "exports", "module", "tarjan", "findCycles", "g", "cmpt", "require_floyd_warshall", "__commonJSMin", "exports", "module", "floydWarshall", "DEFAULT_WEIGHT_FUNC", "g", "weightFn", "edgeFn", "runFloydWarshall", "v", "results", "nodes", "w", "edge", "d", "k", "rowK", "i", "rowI", "j", "ik", "kj", "ij", "altDistance", "require_topsort", "__commonJSMin", "exports", "module", "topsort", "g", "visited", "stack", "results", "visit", "node", "CycleException", "require_is_acyclic", "__commonJSMin", "exports", "module", "topsort", "isAcyclic", "g", "require_dfs", "__commonJSMin", "exports", "module", "dfs", "g", "vs", "order", "navigation", "v", "orderFunc", "postOrderDfs", "preOrderDfs", "acc", "visited", "stack", "curr", "forEachRight", "w", "array", "iteratee", "length", "require_postorder", "__commonJSMin", "exports", "module", "dfs", "postorder", "g", "vs", "require_preorder", "__commonJSMin", "exports", "module", "dfs", "preorder", "g", "vs", "require_prim", "__commonJSMin", "exports", "module", "Graph", "PriorityQueue", "prim", "g", "weightFunc", "result", "parents", "pq", "v", "updateNeighbors", "edge", "w", "pri", "edgeWeight", "init", "require_alg", "__commonJSMin", "exports", "module", "require_index", "__commonJSMin", "exports", "module", "lib"] +} diff --git a/dist/graphlib.core.js b/dist/graphlib.core.js deleted file mode 100644 index 2e297c95..00000000 --- a/dist/graphlib.core.js +++ /dev/null @@ -1,1396 +0,0 @@ -(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.graphlib = f()}})(function(){var define,module,exports;return (function(){function r(e,n,t){function o(i,f){if(!n[i]){if(!e[i]){var c="function"==typeof require&&require;if(!f&&c)return c(i,!0);if(u)return u(i,!0);var a=new Error("Cannot find module '"+i+"'");throw a.code="MODULE_NOT_FOUND",a}var p=n[i]={exports:{}};e[i][0].call(p.exports,function(r){var n=e[i][1][r];return o(n||r)},p,p.exports,r,e,n,t)}return n[i].exports}for(var u="function"==typeof require&&require,i=0;i g.successors(v) : v => g.neighbors(v); - var orderFunc = order === "post" ? postOrderDfs : preOrderDfs; - - var acc = []; - var visited = {}; - vs.forEach(v => { - if (!g.hasNode(v)) { - throw new Error("Graph does not have node: " + v); - } - - orderFunc(v, navigation, visited, acc); - }); - - return acc; -} - -function postOrderDfs(v, navigation, visited, acc) { - var stack = [[v, false]]; - while (stack.length > 0) { - var curr = stack.pop(); - if (curr[1]) { - acc.push(curr[0]); - } else { - if (!Object.hasOwn(visited, curr[0])) { - visited[curr[0]] = true; - stack.push([curr[0], true]); - forEachRight(navigation(curr[0]), w => stack.push([w, false])); - } - } - } -} - -function preOrderDfs(v, navigation, visited, acc) { - var stack = [v]; - while (stack.length > 0) { - var curr = stack.pop(); - if (!Object.hasOwn(visited, curr)) { - visited[curr] = true; - acc.push(curr); - forEachRight(navigation(curr), w => stack.push(w)); - } - } -} - -function forEachRight(array, iteratee) { - var length = array.length; - while (length--) { - iteratee(array[length], length, array); - } - - return array; -} - -},{}],4:[function(require,module,exports){ -var dijkstra = require("./dijkstra"); - -module.exports = dijkstraAll; - -function dijkstraAll(g, weightFunc, edgeFunc) { - return g.nodes().reduce(function(acc, v) { - acc[v] = dijkstra(g, v, weightFunc, edgeFunc); - return acc; - }, {}); -} - -},{"./dijkstra":5}],5:[function(require,module,exports){ -var PriorityQueue = require("../data/priority-queue"); - -module.exports = dijkstra; - -var DEFAULT_WEIGHT_FUNC = () => 1; - -function dijkstra(g, source, weightFn, edgeFn) { - return runDijkstra(g, String(source), - weightFn || DEFAULT_WEIGHT_FUNC, - edgeFn || function(v) { return g.outEdges(v); }); -} - -function runDijkstra(g, source, weightFn, edgeFn) { - var results = {}; - var pq = new PriorityQueue(); - var v, vEntry; - - var updateNeighbors = function(edge) { - var w = edge.v !== v ? edge.v : edge.w; - var wEntry = results[w]; - var weight = weightFn(edge); - var distance = vEntry.distance + weight; - - if (weight < 0) { - throw new Error("dijkstra does not allow negative edge weights. " + - "Bad edge: " + edge + " Weight: " + weight); - } - - if (distance < wEntry.distance) { - wEntry.distance = distance; - wEntry.predecessor = v; - pq.decrease(w, distance); - } - }; - - g.nodes().forEach(function(v) { - var distance = v === source ? 0 : Number.POSITIVE_INFINITY; - results[v] = { distance: distance }; - pq.add(v, distance); - }); - - while (pq.size() > 0) { - v = pq.removeMin(); - vEntry = results[v]; - if (vEntry.distance === Number.POSITIVE_INFINITY) { - break; - } - - edgeFn(v).forEach(updateNeighbors); - } - - return results; -} - -},{"../data/priority-queue":15}],6:[function(require,module,exports){ -var tarjan = require("./tarjan"); - -module.exports = findCycles; - -function findCycles(g) { - return tarjan(g).filter(function(cmpt) { - return cmpt.length > 1 || (cmpt.length === 1 && g.hasEdge(cmpt[0], cmpt[0])); - }); -} - -},{"./tarjan":13}],7:[function(require,module,exports){ -module.exports = floydWarshall; - -var DEFAULT_WEIGHT_FUNC = () => 1; - -function floydWarshall(g, weightFn, edgeFn) { - return runFloydWarshall(g, - weightFn || DEFAULT_WEIGHT_FUNC, - edgeFn || function(v) { return g.outEdges(v); }); -} - -function runFloydWarshall(g, weightFn, edgeFn) { - var results = {}; - var nodes = g.nodes(); - - nodes.forEach(function(v) { - results[v] = {}; - results[v][v] = { distance: 0 }; - nodes.forEach(function(w) { - if (v !== w) { - results[v][w] = { distance: Number.POSITIVE_INFINITY }; - } - }); - edgeFn(v).forEach(function(edge) { - var w = edge.v === v ? edge.w : edge.v; - var d = weightFn(edge); - results[v][w] = { distance: d, predecessor: v }; - }); - }); - - nodes.forEach(function(k) { - var rowK = results[k]; - nodes.forEach(function(i) { - var rowI = results[i]; - nodes.forEach(function(j) { - var ik = rowI[k]; - var kj = rowK[j]; - var ij = rowI[j]; - var altDistance = ik.distance + kj.distance; - if (altDistance < ij.distance) { - ij.distance = altDistance; - ij.predecessor = kj.predecessor; - } - }); - }); - }); - - return results; -} - -},{}],8:[function(require,module,exports){ -module.exports = { - components: require("./components"), - dijkstra: require("./dijkstra"), - dijkstraAll: require("./dijkstra-all"), - findCycles: require("./find-cycles"), - floydWarshall: require("./floyd-warshall"), - isAcyclic: require("./is-acyclic"), - postorder: require("./postorder"), - preorder: require("./preorder"), - prim: require("./prim"), - tarjan: require("./tarjan"), - topsort: require("./topsort") -}; - -},{"./components":2,"./dijkstra":5,"./dijkstra-all":4,"./find-cycles":6,"./floyd-warshall":7,"./is-acyclic":9,"./postorder":10,"./preorder":11,"./prim":12,"./tarjan":13,"./topsort":14}],9:[function(require,module,exports){ -var topsort = require("./topsort"); - -module.exports = isAcyclic; - -function isAcyclic(g) { - try { - topsort(g); - } catch (e) { - if (e instanceof topsort.CycleException) { - return false; - } - throw e; - } - return true; -} - -},{"./topsort":14}],10:[function(require,module,exports){ -var dfs = require("./dfs"); - -module.exports = postorder; - -function postorder(g, vs) { - return dfs(g, vs, "post"); -} - -},{"./dfs":3}],11:[function(require,module,exports){ -var dfs = require("./dfs"); - -module.exports = preorder; - -function preorder(g, vs) { - return dfs(g, vs, "pre"); -} - -},{"./dfs":3}],12:[function(require,module,exports){ -var Graph = require("../graph"); -var PriorityQueue = require("../data/priority-queue"); - -module.exports = prim; - -function prim(g, weightFunc) { - var result = new Graph(); - var parents = {}; - var pq = new PriorityQueue(); - var v; - - function updateNeighbors(edge) { - var w = edge.v === v ? edge.w : edge.v; - var pri = pq.priority(w); - if (pri !== undefined) { - var edgeWeight = weightFunc(edge); - if (edgeWeight < pri) { - parents[w] = v; - pq.decrease(w, edgeWeight); - } - } - } - - if (g.nodeCount() === 0) { - return result; - } - - g.nodes().forEach(function(v) { - pq.add(v, Number.POSITIVE_INFINITY); - result.setNode(v); - }); - - // Start from an arbitrary node - pq.decrease(g.nodes()[0], 0); - - var init = false; - while (pq.size() > 0) { - v = pq.removeMin(); - if (Object.hasOwn(parents, v)) { - result.setEdge(v, parents[v]); - } else if (init) { - throw new Error("Input graph is not connected: " + g); - } else { - init = true; - } - - g.nodeEdges(v).forEach(updateNeighbors); - } - - return result; -} - -},{"../data/priority-queue":15,"../graph":16}],13:[function(require,module,exports){ -module.exports = tarjan; - -function tarjan(g) { - var index = 0; - var stack = []; - var visited = {}; // node id -> { onStack, lowlink, index } - var results = []; - - function dfs(v) { - var entry = visited[v] = { - onStack: true, - lowlink: index, - index: index++ - }; - stack.push(v); - - g.successors(v).forEach(function(w) { - if (!Object.hasOwn(visited, w)) { - dfs(w); - entry.lowlink = Math.min(entry.lowlink, visited[w].lowlink); - } else if (visited[w].onStack) { - entry.lowlink = Math.min(entry.lowlink, visited[w].index); - } - }); - - if (entry.lowlink === entry.index) { - var cmpt = []; - var w; - do { - w = stack.pop(); - visited[w].onStack = false; - cmpt.push(w); - } while (v !== w); - results.push(cmpt); - } - } - - g.nodes().forEach(function(v) { - if (!Object.hasOwn(visited, v)) { - dfs(v); - } - }); - - return results; -} - -},{}],14:[function(require,module,exports){ -function topsort(g) { - var visited = {}; - var stack = {}; - var results = []; - - function visit(node) { - if (Object.hasOwn(stack, node)) { - throw new CycleException(); - } - - if (!Object.hasOwn(visited, node)) { - stack[node] = true; - visited[node] = true; - g.predecessors(node).forEach(visit); - delete stack[node]; - results.push(node); - } - } - - g.sinks().forEach(visit); - - if (Object.keys(visited).length !== g.nodeCount()) { - throw new CycleException(); - } - - return results; -} - -class CycleException extends Error { - constructor() { - super(...arguments); - } -} - -module.exports = topsort; -topsort.CycleException = CycleException; - -},{}],15:[function(require,module,exports){ -/** - * A min-priority queue data structure. This algorithm is derived from Cormen, - * et al., "Introduction to Algorithms". The basic idea of a min-priority - * queue is that you can efficiently (in O(1) time) get the smallest key in - * the queue. Adding and removing elements takes O(log n) time. A key can - * have its priority decreased in O(log n) time. - */ -class PriorityQueue { - _arr = []; - _keyIndices = {}; - - /** - * Returns the number of elements in the queue. Takes `O(1)` time. - */ - size() { - return this._arr.length; - } - - /** - * Returns the keys that are in the queue. Takes `O(n)` time. - */ - keys() { - return this._arr.map(function(x) { return x.key; }); - } - - /** - * Returns `true` if **key** is in the queue and `false` if not. - */ - has(key) { - return Object.hasOwn(this._keyIndices, key); - } - - /** - * Returns the priority for **key**. If **key** is not present in the queue - * then this function returns `undefined`. Takes `O(1)` time. - * - * @param {Object} key - */ - priority(key) { - var index = this._keyIndices[key]; - if (index !== undefined) { - return this._arr[index].priority; - } - } - - /** - * Returns the key for the minimum element in this queue. If the queue is - * empty this function throws an Error. Takes `O(1)` time. - */ - min() { - if (this.size() === 0) { - throw new Error("Queue underflow"); - } - return this._arr[0].key; - } - - /** - * Inserts a new key into the priority queue. If the key already exists in - * the queue this function returns `false`; otherwise it will return `true`. - * Takes `O(n)` time. - * - * @param {Object} key the key to add - * @param {Number} priority the initial priority for the key - */ - add(key, priority) { - var keyIndices = this._keyIndices; - key = String(key); - if (!Object.hasOwn(keyIndices, key)) { - var arr = this._arr; - var index = arr.length; - keyIndices[key] = index; - arr.push({key: key, priority: priority}); - this._decrease(index); - return true; - } - return false; - } - - /** - * Removes and returns the smallest key in the queue. Takes `O(log n)` time. - */ - removeMin() { - this._swap(0, this._arr.length - 1); - var min = this._arr.pop(); - delete this._keyIndices[min.key]; - this._heapify(0); - return min.key; - } - - /** - * Decreases the priority for **key** to **priority**. If the new priority is - * greater than the previous priority, this function will throw an Error. - * - * @param {Object} key the key for which to raise priority - * @param {Number} priority the new priority for the key - */ - decrease(key, priority) { - var index = this._keyIndices[key]; - if (priority > this._arr[index].priority) { - throw new Error("New priority is greater than current priority. " + - "Key: " + key + " Old: " + this._arr[index].priority + " New: " + priority); - } - this._arr[index].priority = priority; - this._decrease(index); - } - - _heapify(i) { - var arr = this._arr; - var l = 2 * i; - var r = l + 1; - var largest = i; - if (l < arr.length) { - largest = arr[l].priority < arr[largest].priority ? l : largest; - if (r < arr.length) { - largest = arr[r].priority < arr[largest].priority ? r : largest; - } - if (largest !== i) { - this._swap(i, largest); - this._heapify(largest); - } - } - } - - _decrease(index) { - var arr = this._arr; - var priority = arr[index].priority; - var parent; - while (index !== 0) { - parent = index >> 1; - if (arr[parent].priority < priority) { - break; - } - this._swap(index, parent); - index = parent; - } - } - - _swap(i, j) { - var arr = this._arr; - var keyIndices = this._keyIndices; - var origArrI = arr[i]; - var origArrJ = arr[j]; - arr[i] = origArrJ; - arr[j] = origArrI; - keyIndices[origArrJ.key] = i; - keyIndices[origArrI.key] = j; - } -} - -module.exports = PriorityQueue; - -},{}],16:[function(require,module,exports){ -"use strict"; - -var DEFAULT_EDGE_NAME = "\x00"; -var GRAPH_NODE = "\x00"; -var EDGE_KEY_DELIM = "\x01"; - -// Implementation notes: -// -// * Node id query functions should return string ids for the nodes -// * Edge id query functions should return an "edgeObj", edge object, that is -// composed of enough information to uniquely identify an edge: {v, w, name}. -// * Internally we use an "edgeId", a stringified form of the edgeObj, to -// reference edges. This is because we need a performant way to look these -// edges up and, object properties, which have string keys, are the closest -// we're going to get to a performant hashtable in JavaScript. - -class Graph { - _isDirected = true; - _isMultigraph = false; - _isCompound = false; - - // Label for the graph itself - _label; - - // Defaults to be set when creating a new node - _defaultNodeLabelFn = () => undefined; - - // Defaults to be set when creating a new edge - _defaultEdgeLabelFn = () => undefined; - - // v -> label - _nodes = {}; - - // v -> edgeObj - _in = {}; - - // u -> v -> Number - _preds = {}; - - // v -> edgeObj - _out = {}; - - // v -> w -> Number - _sucs = {}; - - // e -> edgeObj - _edgeObjs = {}; - - // e -> label - _edgeLabels = {}; - - /* Number of nodes in the graph. Should only be changed by the implementation. */ - _nodeCount = 0; - - /* Number of edges in the graph. Should only be changed by the implementation. */ - _edgeCount = 0; - - _parent; - - _children; - - constructor(opts) { - if (opts) { - this._isDirected = Object.hasOwn(opts, "directed") ? opts.directed : true; - this._isMultigraph = Object.hasOwn(opts, "multigraph") ? opts.multigraph : false; - this._isCompound = Object.hasOwn(opts, "compound") ? opts.compound : false; - } - - if (this._isCompound) { - // v -> parent - this._parent = {}; - - // v -> children - this._children = {}; - this._children[GRAPH_NODE] = {}; - } - } - - /* === Graph functions ========= */ - - /** - * Whether graph was created with 'directed' flag set to true or not. - */ - isDirected() { - return this._isDirected; - } - - /** - * Whether graph was created with 'multigraph' flag set to true or not. - */ - isMultigraph() { - return this._isMultigraph; - } - - /** - * Whether graph was created with 'compound' flag set to true or not. - */ - isCompound() { - return this._isCompound; - } - - /** - * Sets the label of the graph. - */ - setGraph(label) { - this._label = label; - return this; - } - - /** - * Gets the graph label. - */ - graph() { - return this._label; - } - - - /* === Node functions ========== */ - - /** - * Sets the default node label. If newDefault is a function, it will be - * invoked ach time when setting a label for a node. Otherwise, this label - * will be assigned as default label in case if no label was specified while - * setting a node. - * Complexity: O(1). - */ - setDefaultNodeLabel(newDefault) { - this._defaultNodeLabelFn = newDefault; - if (typeof newDefault !== 'function') { - this._defaultNodeLabelFn = () => newDefault; - } - - return this; - } - - /** - * Gets the number of nodes in the graph. - * Complexity: O(1). - */ - nodeCount() { - return this._nodeCount; - } - - /** - * Gets all nodes of the graph. Note, the in case of compound graph subnodes are - * not included in list. - * Complexity: O(1). - */ - nodes() { - return Object.keys(this._nodes); - } - - /** - * Gets list of nodes without in-edges. - * Complexity: O(|V|). - */ - sources() { - var self = this; - return this.nodes().filter(v => Object.keys(self._in[v]).length === 0); - } - - /** - * Gets list of nodes without out-edges. - * Complexity: O(|V|). - */ - sinks() { - var self = this; - return this.nodes().filter(v => Object.keys(self._out[v]).length === 0); - } - - /** - * Invokes setNode method for each node in names list. - * Complexity: O(|names|). - */ - setNodes(vs, value) { - var args = arguments; - var self = this; - vs.forEach(function(v) { - if (args.length > 1) { - self.setNode(v, value); - } else { - self.setNode(v); - } - }); - return this; - } - - /** - * Creates or updates the value for the node v in the graph. If label is supplied - * it is set as the value for the node. If label is not supplied and the node was - * created by this call then the default node label will be assigned. - * Complexity: O(1). - */ - setNode(v, value) { - if (Object.hasOwn(this._nodes, v)) { - if (arguments.length > 1) { - this._nodes[v] = value; - } - return this; - } - - this._nodes[v] = arguments.length > 1 ? value : this._defaultNodeLabelFn(v); - if (this._isCompound) { - this._parent[v] = GRAPH_NODE; - this._children[v] = {}; - this._children[GRAPH_NODE][v] = true; - } - this._in[v] = {}; - this._preds[v] = {}; - this._out[v] = {}; - this._sucs[v] = {}; - ++this._nodeCount; - return this; - } - - /** - * Gets the label of node with specified name. - * Complexity: O(|V|). - */ - node(v) { - return this._nodes[v]; - } - - /** - * Detects whether graph has a node with specified name or not. - */ - hasNode(v) { - return Object.hasOwn(this._nodes, v); - } - - /** - * Remove the node with the name from the graph or do nothing if the node is not in - * the graph. If the node was removed this function also removes any incident - * edges. - * Complexity: O(1). - */ - removeNode(v) { - var self = this; - if (Object.hasOwn(this._nodes, v)) { - var removeEdge = e => self.removeEdge(self._edgeObjs[e]); - delete this._nodes[v]; - if (this._isCompound) { - this._removeFromParentsChildList(v); - delete this._parent[v]; - this.children(v).forEach(function(child) { - self.setParent(child); - }); - delete this._children[v]; - } - Object.keys(this._in[v]).forEach(removeEdge); - delete this._in[v]; - delete this._preds[v]; - Object.keys(this._out[v]).forEach(removeEdge); - delete this._out[v]; - delete this._sucs[v]; - --this._nodeCount; - } - return this; - } - - /** - * Sets node p as a parent for node v if it is defined, or removes the - * parent for v if p is undefined. Method throws an exception in case of - * invoking it in context of noncompound graph. - * Average-case complexity: O(1). - */ - setParent(v, parent) { - if (!this._isCompound) { - throw new Error("Cannot set parent in a non-compound graph"); - } - - if (parent === undefined) { - parent = GRAPH_NODE; - } else { - // Coerce parent to string - parent += ""; - for (var ancestor = parent; ancestor !== undefined; ancestor = this.parent(ancestor)) { - if (ancestor === v) { - throw new Error("Setting " + parent+ " as parent of " + v + - " would create a cycle"); - } - } - - this.setNode(parent); - } - - this.setNode(v); - this._removeFromParentsChildList(v); - this._parent[v] = parent; - this._children[parent][v] = true; - return this; - } - - _removeFromParentsChildList(v) { - delete this._children[this._parent[v]][v]; - } - - /** - * Gets parent node for node v. - * Complexity: O(1). - */ - parent(v) { - if (this._isCompound) { - var parent = this._parent[v]; - if (parent !== GRAPH_NODE) { - return parent; - } - } - } - - /** - * Gets list of direct children of node v. - * Complexity: O(1). - */ - children(v = GRAPH_NODE) { - if (this._isCompound) { - var children = this._children[v]; - if (children) { - return Object.keys(children); - } - } else if (v === GRAPH_NODE) { - return this.nodes(); - } else if (this.hasNode(v)) { - return []; - } - } - - /** - * Return all nodes that are predecessors of the specified node or undefined if node v is not in - * the graph. Behavior is undefined for undirected graphs - use neighbors instead. - * Complexity: O(|V|). - */ - predecessors(v) { - var predsV = this._preds[v]; - if (predsV) { - return Object.keys(predsV); - } - } - - /** - * Return all nodes that are successors of the specified node or undefined if node v is not in - * the graph. Behavior is undefined for undirected graphs - use neighbors instead. - * Complexity: O(|V|). - */ - successors(v) { - var sucsV = this._sucs[v]; - if (sucsV) { - return Object.keys(sucsV); - } - } - - /** - * Return all nodes that are predecessors or successors of the specified node or undefined if - * node v is not in the graph. - * Complexity: O(|V|). - */ - neighbors(v) { - var preds = this.predecessors(v); - if (preds) { - const union = new Set(preds); - for (var succ of this.successors(v)) { - union.add(succ); - } - - return Array.from(union.values()); - } - } - - isLeaf(v) { - var neighbors; - if (this.isDirected()) { - neighbors = this.successors(v); - } else { - neighbors = this.neighbors(v); - } - return neighbors.length === 0; - } - - /** - * Creates new graph with nodes filtered via filter. Edges incident to rejected node - * are also removed. In case of compound graph, if parent is rejected by filter, - * than all its children are rejected too. - * Average-case complexity: O(|E|+|V|). - */ - filterNodes(filter) { - var copy = new this.constructor({ - directed: this._isDirected, - multigraph: this._isMultigraph, - compound: this._isCompound - }); - - copy.setGraph(this.graph()); - - var self = this; - Object.entries(this._nodes).forEach(function([v, value]) { - if (filter(v)) { - copy.setNode(v, value); - } - }); - - Object.values(this._edgeObjs).forEach(function(e) { - if (copy.hasNode(e.v) && copy.hasNode(e.w)) { - copy.setEdge(e, self.edge(e)); - } - }); - - var parents = {}; - function findParent(v) { - var parent = self.parent(v); - if (parent === undefined || copy.hasNode(parent)) { - parents[v] = parent; - return parent; - } else if (parent in parents) { - return parents[parent]; - } else { - return findParent(parent); - } - } - - if (this._isCompound) { - copy.nodes().forEach(v => copy.setParent(v, findParent(v))); - } - - return copy; - } - - /* === Edge functions ========== */ - - /** - * Sets the default edge label or factory function. This label will be - * assigned as default label in case if no label was specified while setting - * an edge or this function will be invoked each time when setting an edge - * with no label specified and returned value * will be used as a label for edge. - * Complexity: O(1). - */ - setDefaultEdgeLabel(newDefault) { - this._defaultEdgeLabelFn = newDefault; - if (typeof newDefault !== 'function') { - this._defaultEdgeLabelFn = () => newDefault; - } - - return this; - } - - /** - * Gets the number of edges in the graph. - * Complexity: O(1). - */ - edgeCount() { - return this._edgeCount; - } - - /** - * Gets edges of the graph. In case of compound graph subgraphs are not considered. - * Complexity: O(|E|). - */ - edges() { - return Object.values(this._edgeObjs); - } - - /** - * Establish an edges path over the nodes in nodes list. If some edge is already - * exists, it will update its label, otherwise it will create an edge between pair - * of nodes with label provided or default label if no label provided. - * Complexity: O(|nodes|). - */ - setPath(vs, value) { - var self = this; - var args = arguments; - vs.reduce(function(v, w) { - if (args.length > 1) { - self.setEdge(v, w, value); - } else { - self.setEdge(v, w); - } - return w; - }); - return this; - } - - /** - * Creates or updates the label for the edge (v, w) with the optionally supplied - * name. If label is supplied it is set as the value for the edge. If label is not - * supplied and the edge was created by this call then the default edge label will - * be assigned. The name parameter is only useful with multigraphs. - */ - setEdge() { - var v, w, name, value; - var valueSpecified = false; - var arg0 = arguments[0]; - - if (typeof arg0 === "object" && arg0 !== null && "v" in arg0) { - v = arg0.v; - w = arg0.w; - name = arg0.name; - if (arguments.length === 2) { - value = arguments[1]; - valueSpecified = true; - } - } else { - v = arg0; - w = arguments[1]; - name = arguments[3]; - if (arguments.length > 2) { - value = arguments[2]; - valueSpecified = true; - } - } - - v = "" + v; - w = "" + w; - if (name !== undefined) { - name = "" + name; - } - - var e = edgeArgsToId(this._isDirected, v, w, name); - if (Object.hasOwn(this._edgeLabels, e)) { - if (valueSpecified) { - this._edgeLabels[e] = value; - } - return this; - } - - if (name !== undefined && !this._isMultigraph) { - throw new Error("Cannot set a named edge when isMultigraph = false"); - } - - // It didn't exist, so we need to create it. - // First ensure the nodes exist. - this.setNode(v); - this.setNode(w); - - this._edgeLabels[e] = valueSpecified ? value : this._defaultEdgeLabelFn(v, w, name); - - var edgeObj = edgeArgsToObj(this._isDirected, v, w, name); - // Ensure we add undirected edges in a consistent way. - v = edgeObj.v; - w = edgeObj.w; - - Object.freeze(edgeObj); - this._edgeObjs[e] = edgeObj; - incrementOrInitEntry(this._preds[w], v); - incrementOrInitEntry(this._sucs[v], w); - this._in[w][e] = edgeObj; - this._out[v][e] = edgeObj; - this._edgeCount++; - return this; - } - - /** - * Gets the label for the specified edge. - * Complexity: O(1). - */ - edge(v, w, name) { - var e = (arguments.length === 1 - ? edgeObjToId(this._isDirected, arguments[0]) - : edgeArgsToId(this._isDirected, v, w, name)); - return this._edgeLabels[e]; - } - - /** - * Gets the label for the specified edge and converts it to an object. - * Complexity: O(1) - */ - edgeAsObj() { - const edge = this.edge(...arguments); - if (typeof edge !== "object") { - return {label: edge}; - } - - return edge; - } - - /** - * Detects whether the graph contains specified edge or not. No subgraphs are considered. - * Complexity: O(1). - */ - hasEdge(v, w, name) { - var e = (arguments.length === 1 - ? edgeObjToId(this._isDirected, arguments[0]) - : edgeArgsToId(this._isDirected, v, w, name)); - return Object.hasOwn(this._edgeLabels, e); - } - - /** - * Removes the specified edge from the graph. No subgraphs are considered. - * Complexity: O(1). - */ - removeEdge(v, w, name) { - var e = (arguments.length === 1 - ? edgeObjToId(this._isDirected, arguments[0]) - : edgeArgsToId(this._isDirected, v, w, name)); - var edge = this._edgeObjs[e]; - if (edge) { - v = edge.v; - w = edge.w; - delete this._edgeLabels[e]; - delete this._edgeObjs[e]; - decrementOrRemoveEntry(this._preds[w], v); - decrementOrRemoveEntry(this._sucs[v], w); - delete this._in[w][e]; - delete this._out[v][e]; - this._edgeCount--; - } - return this; - } - - /** - * Return all edges that point to the node v. Optionally filters those edges down to just those - * coming from node u. Behavior is undefined for undirected graphs - use nodeEdges instead. - * Complexity: O(|E|). - */ - inEdges(v, u) { - var inV = this._in[v]; - if (inV) { - var edges = Object.values(inV); - if (!u) { - return edges; - } - return edges.filter(edge => edge.v === u); - } - } - - /** - * Return all edges that are pointed at by node v. Optionally filters those edges down to just - * those point to w. Behavior is undefined for undirected graphs - use nodeEdges instead. - * Complexity: O(|E|). - */ - outEdges(v, w) { - var outV = this._out[v]; - if (outV) { - var edges = Object.values(outV); - if (!w) { - return edges; - } - return edges.filter(edge => edge.w === w); - } - } - - /** - * Returns all edges to or from node v regardless of direction. Optionally filters those edges - * down to just those between nodes v and w regardless of direction. - * Complexity: O(|E|). - */ - nodeEdges(v, w) { - var inEdges = this.inEdges(v, w); - if (inEdges) { - return inEdges.concat(this.outEdges(v, w)); - } - } -} - -function incrementOrInitEntry(map, k) { - if (map[k]) { - map[k]++; - } else { - map[k] = 1; - } -} - -function decrementOrRemoveEntry(map, k) { - if (!--map[k]) { delete map[k]; } -} - -function edgeArgsToId(isDirected, v_, w_, name) { - var v = "" + v_; - var w = "" + w_; - if (!isDirected && v > w) { - var tmp = v; - v = w; - w = tmp; - } - return v + EDGE_KEY_DELIM + w + EDGE_KEY_DELIM + - (name === undefined ? DEFAULT_EDGE_NAME : name); -} - -function edgeArgsToObj(isDirected, v_, w_, name) { - var v = "" + v_; - var w = "" + w_; - if (!isDirected && v > w) { - var tmp = v; - v = w; - w = tmp; - } - var edgeObj = { v: v, w: w }; - if (name) { - edgeObj.name = name; - } - return edgeObj; -} - -function edgeObjToId(isDirected, edgeObj) { - return edgeArgsToId(isDirected, edgeObj.v, edgeObj.w, edgeObj.name); -} - -module.exports = Graph; - -},{}],17:[function(require,module,exports){ -// Includes only the "core" of graphlib -module.exports = { - Graph: require("./graph"), - version: require("./version") -}; - -},{"./graph":16,"./version":19}],18:[function(require,module,exports){ -var Graph = require("./graph"); - -module.exports = { - write: write, - read: read -}; - -/** - * Creates a JSON representation of the graph that can be serialized to a string with - * JSON.stringify. The graph can later be restored using json.read. - */ -function write(g) { - var json = { - options: { - directed: g.isDirected(), - multigraph: g.isMultigraph(), - compound: g.isCompound() - }, - nodes: writeNodes(g), - edges: writeEdges(g) - }; - - if (g.graph() !== undefined) { - json.value = structuredClone(g.graph()); - } - return json; -} - -function writeNodes(g) { - return g.nodes().map(function(v) { - var nodeValue = g.node(v); - var parent = g.parent(v); - var node = { v: v }; - if (nodeValue !== undefined) { - node.value = nodeValue; - } - if (parent !== undefined) { - node.parent = parent; - } - return node; - }); -} - -function writeEdges(g) { - return g.edges().map(function(e) { - var edgeValue = g.edge(e); - var edge = { v: e.v, w: e.w }; - if (e.name !== undefined) { - edge.name = e.name; - } - if (edgeValue !== undefined) { - edge.value = edgeValue; - } - return edge; - }); -} - -/** - * Takes JSON as input and returns the graph representation. - * - * @example - * var g2 = graphlib.json.read(JSON.parse(str)); - * g2.nodes(); - * // ['a', 'b'] - * g2.edges() - * // [ { v: 'a', w: 'b' } ] - */ -function read(json) { - var g = new Graph(json.options).setGraph(json.value); - json.nodes.forEach(function(entry) { - g.setNode(entry.v, entry.value); - if (entry.parent) { - g.setParent(entry.v, entry.parent); - } - }); - json.edges.forEach(function(entry) { - g.setEdge({ v: entry.v, w: entry.w, name: entry.name }, entry.value); - }); - return g; -} - -},{"./graph":16}],19:[function(require,module,exports){ -module.exports = '2.2.4'; - -},{}]},{},[1])(1) -}); diff --git a/dist/graphlib.core.min.js b/dist/graphlib.core.min.js deleted file mode 100644 index c925c2b6..00000000 --- a/dist/graphlib.core.min.js +++ /dev/null @@ -1,304 +0,0 @@ -(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.graphlib=f()}})(function(){var define,module,exports;return function(){function r(e,n,t){function o(i,f){if(!n[i]){if(!e[i]){var c="function"==typeof require&&require;if(!f&&c)return c(i,!0);if(u)return u(i,!0);var a=new Error("Cannot find module '"+i+"'");throw a.code="MODULE_NOT_FOUND",a}var p=n[i]={exports:{}};e[i][0].call(p.exports,function(r){var n=e[i][1][r];return o(n||r)},p,p.exports,r,e,n,t)}return n[i].exports}for(var u="function"==typeof require&&require,i=0;ig.successors(v):v=>g.neighbors(v);var orderFunc=order==="post"?postOrderDfs:preOrderDfs;var acc=[];var visited={};vs.forEach(v=>{if(!g.hasNode(v)){throw new Error("Graph does not have node: "+v)}orderFunc(v,navigation,visited,acc)});return acc}function postOrderDfs(v,navigation,visited,acc){var stack=[[v,false]];while(stack.length>0){var curr=stack.pop();if(curr[1]){acc.push(curr[0])}else{if(!Object.hasOwn(visited,curr[0])){visited[curr[0]]=true;stack.push([curr[0],true]);forEachRight(navigation(curr[0]),w=>stack.push([w,false]))}}}}function preOrderDfs(v,navigation,visited,acc){var stack=[v];while(stack.length>0){var curr=stack.pop();if(!Object.hasOwn(visited,curr)){visited[curr]=true;acc.push(curr);forEachRight(navigation(curr),w=>stack.push(w))}}}function forEachRight(array,iteratee){var length=array.length;while(length--){iteratee(array[length],length,array)}return array}},{}],4:[function(require,module,exports){var dijkstra=require("./dijkstra");module.exports=dijkstraAll;function dijkstraAll(g,weightFunc,edgeFunc){return g.nodes().reduce(function(acc,v){acc[v]=dijkstra(g,v,weightFunc,edgeFunc);return acc},{})}},{"./dijkstra":5}],5:[function(require,module,exports){var PriorityQueue=require("../data/priority-queue");module.exports=dijkstra;var DEFAULT_WEIGHT_FUNC=()=>1;function dijkstra(g,source,weightFn,edgeFn){return runDijkstra(g,String(source),weightFn||DEFAULT_WEIGHT_FUNC,edgeFn||function(v){return g.outEdges(v)})}function runDijkstra(g,source,weightFn,edgeFn){var results={};var pq=new PriorityQueue;var v,vEntry;var updateNeighbors=function(edge){var w=edge.v!==v?edge.v:edge.w;var wEntry=results[w];var weight=weightFn(edge);var distance=vEntry.distance+weight;if(weight<0){throw new Error("dijkstra does not allow negative edge weights. "+"Bad edge: "+edge+" Weight: "+weight)}if(distance0){v=pq.removeMin();vEntry=results[v];if(vEntry.distance===Number.POSITIVE_INFINITY){break}edgeFn(v).forEach(updateNeighbors)}return results}},{"../data/priority-queue":15}],6:[function(require,module,exports){var tarjan=require("./tarjan");module.exports=findCycles;function findCycles(g){return tarjan(g).filter(function(cmpt){return cmpt.length>1||cmpt.length===1&&g.hasEdge(cmpt[0],cmpt[0])})}},{"./tarjan":13}],7:[function(require,module,exports){module.exports=floydWarshall;var DEFAULT_WEIGHT_FUNC=()=>1;function floydWarshall(g,weightFn,edgeFn){return runFloydWarshall(g,weightFn||DEFAULT_WEIGHT_FUNC,edgeFn||function(v){return g.outEdges(v)})}function runFloydWarshall(g,weightFn,edgeFn){var results={};var nodes=g.nodes();nodes.forEach(function(v){results[v]={};results[v][v]={distance:0};nodes.forEach(function(w){if(v!==w){results[v][w]={distance:Number.POSITIVE_INFINITY}}});edgeFn(v).forEach(function(edge){var w=edge.v===v?edge.w:edge.v;var d=weightFn(edge);results[v][w]={distance:d,predecessor:v}})});nodes.forEach(function(k){var rowK=results[k];nodes.forEach(function(i){var rowI=results[i];nodes.forEach(function(j){var ik=rowI[k];var kj=rowK[j];var ij=rowI[j];var altDistance=ik.distance+kj.distance;if(altDistance0){v=pq.removeMin();if(Object.hasOwn(parents,v)){result.setEdge(v,parents[v])}else if(init){throw new Error("Input graph is not connected: "+g)}else{init=true}g.nodeEdges(v).forEach(updateNeighbors)}return result}},{"../data/priority-queue":15,"../graph":16}],13:[function(require,module,exports){module.exports=tarjan;function tarjan(g){var index=0;var stack=[];var visited={};// node id -> { onStack, lowlink, index } -var results=[];function dfs(v){var entry=visited[v]={onStack:true,lowlink:index,index:index++};stack.push(v);g.successors(v).forEach(function(w){if(!Object.hasOwn(visited,w)){dfs(w);entry.lowlink=Math.min(entry.lowlink,visited[w].lowlink)}else if(visited[w].onStack){entry.lowlink=Math.min(entry.lowlink,visited[w].index)}});if(entry.lowlink===entry.index){var cmpt=[];var w;do{w=stack.pop();visited[w].onStack=false;cmpt.push(w)}while(v!==w);results.push(cmpt)}}g.nodes().forEach(function(v){if(!Object.hasOwn(visited,v)){dfs(v)}});return results}},{}],14:[function(require,module,exports){function topsort(g){var visited={};var stack={};var results=[];function visit(node){if(Object.hasOwn(stack,node)){throw new CycleException}if(!Object.hasOwn(visited,node)){stack[node]=true;visited[node]=true;g.predecessors(node).forEach(visit);delete stack[node];results.push(node)}}g.sinks().forEach(visit);if(Object.keys(visited).length!==g.nodeCount()){throw new CycleException}return results}class CycleException extends Error{constructor(){super(...arguments)}}module.exports=topsort;topsort.CycleException=CycleException},{}],15:[function(require,module,exports){ -/** - * A min-priority queue data structure. This algorithm is derived from Cormen, - * et al., "Introduction to Algorithms". The basic idea of a min-priority - * queue is that you can efficiently (in O(1) time) get the smallest key in - * the queue. Adding and removing elements takes O(log n) time. A key can - * have its priority decreased in O(log n) time. - */ -class PriorityQueue{_arr=[];_keyIndices={}; -/** - * Returns the number of elements in the queue. Takes `O(1)` time. - */size(){return this._arr.length} -/** - * Returns the keys that are in the queue. Takes `O(n)` time. - */keys(){return this._arr.map(function(x){return x.key})} -/** - * Returns `true` if **key** is in the queue and `false` if not. - */has(key){return Object.hasOwn(this._keyIndices,key)} -/** - * Returns the priority for **key**. If **key** is not present in the queue - * then this function returns `undefined`. Takes `O(1)` time. - * - * @param {Object} key - */priority(key){var index=this._keyIndices[key];if(index!==undefined){return this._arr[index].priority}} -/** - * Returns the key for the minimum element in this queue. If the queue is - * empty this function throws an Error. Takes `O(1)` time. - */min(){if(this.size()===0){throw new Error("Queue underflow")}return this._arr[0].key} -/** - * Inserts a new key into the priority queue. If the key already exists in - * the queue this function returns `false`; otherwise it will return `true`. - * Takes `O(n)` time. - * - * @param {Object} key the key to add - * @param {Number} priority the initial priority for the key - */add(key,priority){var keyIndices=this._keyIndices;key=String(key);if(!Object.hasOwn(keyIndices,key)){var arr=this._arr;var index=arr.length;keyIndices[key]=index;arr.push({key:key,priority:priority});this._decrease(index);return true}return false} -/** - * Removes and returns the smallest key in the queue. Takes `O(log n)` time. - */removeMin(){this._swap(0,this._arr.length-1);var min=this._arr.pop();delete this._keyIndices[min.key];this._heapify(0);return min.key} -/** - * Decreases the priority for **key** to **priority**. If the new priority is - * greater than the previous priority, this function will throw an Error. - * - * @param {Object} key the key for which to raise priority - * @param {Number} priority the new priority for the key - */decrease(key,priority){var index=this._keyIndices[key];if(priority>this._arr[index].priority){throw new Error("New priority is greater than current priority. "+"Key: "+key+" Old: "+this._arr[index].priority+" New: "+priority)}this._arr[index].priority=priority;this._decrease(index)}_heapify(i){var arr=this._arr;var l=2*i;var r=l+1;var largest=i;if(l>1;if(arr[parent].priorityundefined; -// Defaults to be set when creating a new edge -_defaultEdgeLabelFn=()=>undefined; -// v -> label -_nodes={}; -// v -> edgeObj -_in={}; -// u -> v -> Number -_preds={}; -// v -> edgeObj -_out={}; -// v -> w -> Number -_sucs={}; -// e -> edgeObj -_edgeObjs={}; -// e -> label -_edgeLabels={}; -/* Number of nodes in the graph. Should only be changed by the implementation. */_nodeCount=0; -/* Number of edges in the graph. Should only be changed by the implementation. */_edgeCount=0;_parent;_children;constructor(opts){if(opts){this._isDirected=Object.hasOwn(opts,"directed")?opts.directed:true;this._isMultigraph=Object.hasOwn(opts,"multigraph")?opts.multigraph:false;this._isCompound=Object.hasOwn(opts,"compound")?opts.compound:false}if(this._isCompound){ -// v -> parent -this._parent={}; -// v -> children -this._children={};this._children[GRAPH_NODE]={}}} -/* === Graph functions ========= */ -/** - * Whether graph was created with 'directed' flag set to true or not. - */isDirected(){return this._isDirected} -/** - * Whether graph was created with 'multigraph' flag set to true or not. - */isMultigraph(){return this._isMultigraph} -/** - * Whether graph was created with 'compound' flag set to true or not. - */isCompound(){return this._isCompound} -/** - * Sets the label of the graph. - */setGraph(label){this._label=label;return this} -/** - * Gets the graph label. - */graph(){return this._label} -/* === Node functions ========== */ -/** - * Sets the default node label. If newDefault is a function, it will be - * invoked ach time when setting a label for a node. Otherwise, this label - * will be assigned as default label in case if no label was specified while - * setting a node. - * Complexity: O(1). - */setDefaultNodeLabel(newDefault){this._defaultNodeLabelFn=newDefault;if(typeof newDefault!=="function"){this._defaultNodeLabelFn=()=>newDefault}return this} -/** - * Gets the number of nodes in the graph. - * Complexity: O(1). - */nodeCount(){return this._nodeCount} -/** - * Gets all nodes of the graph. Note, the in case of compound graph subnodes are - * not included in list. - * Complexity: O(1). - */nodes(){return Object.keys(this._nodes)} -/** - * Gets list of nodes without in-edges. - * Complexity: O(|V|). - */sources(){var self=this;return this.nodes().filter(v=>Object.keys(self._in[v]).length===0)} -/** - * Gets list of nodes without out-edges. - * Complexity: O(|V|). - */sinks(){var self=this;return this.nodes().filter(v=>Object.keys(self._out[v]).length===0)} -/** - * Invokes setNode method for each node in names list. - * Complexity: O(|names|). - */setNodes(vs,value){var args=arguments;var self=this;vs.forEach(function(v){if(args.length>1){self.setNode(v,value)}else{self.setNode(v)}});return this} -/** - * Creates or updates the value for the node v in the graph. If label is supplied - * it is set as the value for the node. If label is not supplied and the node was - * created by this call then the default node label will be assigned. - * Complexity: O(1). - */setNode(v,value){if(Object.hasOwn(this._nodes,v)){if(arguments.length>1){this._nodes[v]=value}return this}this._nodes[v]=arguments.length>1?value:this._defaultNodeLabelFn(v);if(this._isCompound){this._parent[v]=GRAPH_NODE;this._children[v]={};this._children[GRAPH_NODE][v]=true}this._in[v]={};this._preds[v]={};this._out[v]={};this._sucs[v]={};++this._nodeCount;return this} -/** - * Gets the label of node with specified name. - * Complexity: O(|V|). - */node(v){return this._nodes[v]} -/** - * Detects whether graph has a node with specified name or not. - */hasNode(v){return Object.hasOwn(this._nodes,v)} -/** - * Remove the node with the name from the graph or do nothing if the node is not in - * the graph. If the node was removed this function also removes any incident - * edges. - * Complexity: O(1). - */removeNode(v){var self=this;if(Object.hasOwn(this._nodes,v)){var removeEdge=e=>self.removeEdge(self._edgeObjs[e]);delete this._nodes[v];if(this._isCompound){this._removeFromParentsChildList(v);delete this._parent[v];this.children(v).forEach(function(child){self.setParent(child)});delete this._children[v]}Object.keys(this._in[v]).forEach(removeEdge);delete this._in[v];delete this._preds[v];Object.keys(this._out[v]).forEach(removeEdge);delete this._out[v];delete this._sucs[v];--this._nodeCount}return this} -/** - * Sets node p as a parent for node v if it is defined, or removes the - * parent for v if p is undefined. Method throws an exception in case of - * invoking it in context of noncompound graph. - * Average-case complexity: O(1). - */setParent(v,parent){if(!this._isCompound){throw new Error("Cannot set parent in a non-compound graph")}if(parent===undefined){parent=GRAPH_NODE}else{ -// Coerce parent to string -parent+="";for(var ancestor=parent;ancestor!==undefined;ancestor=this.parent(ancestor)){if(ancestor===v){throw new Error("Setting "+parent+" as parent of "+v+" would create a cycle")}}this.setNode(parent)}this.setNode(v);this._removeFromParentsChildList(v);this._parent[v]=parent;this._children[parent][v]=true;return this}_removeFromParentsChildList(v){delete this._children[this._parent[v]][v]} -/** - * Gets parent node for node v. - * Complexity: O(1). - */parent(v){if(this._isCompound){var parent=this._parent[v];if(parent!==GRAPH_NODE){return parent}}} -/** - * Gets list of direct children of node v. - * Complexity: O(1). - */children(v=GRAPH_NODE){if(this._isCompound){var children=this._children[v];if(children){return Object.keys(children)}}else if(v===GRAPH_NODE){return this.nodes()}else if(this.hasNode(v)){return[]}} -/** - * Return all nodes that are predecessors of the specified node or undefined if node v is not in - * the graph. Behavior is undefined for undirected graphs - use neighbors instead. - * Complexity: O(|V|). - */predecessors(v){var predsV=this._preds[v];if(predsV){return Object.keys(predsV)}} -/** - * Return all nodes that are successors of the specified node or undefined if node v is not in - * the graph. Behavior is undefined for undirected graphs - use neighbors instead. - * Complexity: O(|V|). - */successors(v){var sucsV=this._sucs[v];if(sucsV){return Object.keys(sucsV)}} -/** - * Return all nodes that are predecessors or successors of the specified node or undefined if - * node v is not in the graph. - * Complexity: O(|V|). - */neighbors(v){var preds=this.predecessors(v);if(preds){const union=new Set(preds);for(var succ of this.successors(v)){union.add(succ)}return Array.from(union.values())}}isLeaf(v){var neighbors;if(this.isDirected()){neighbors=this.successors(v)}else{neighbors=this.neighbors(v)}return neighbors.length===0} -/** - * Creates new graph with nodes filtered via filter. Edges incident to rejected node - * are also removed. In case of compound graph, if parent is rejected by filter, - * than all its children are rejected too. - * Average-case complexity: O(|E|+|V|). - */filterNodes(filter){var copy=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});copy.setGraph(this.graph());var self=this;Object.entries(this._nodes).forEach(function([v,value]){if(filter(v)){copy.setNode(v,value)}});Object.values(this._edgeObjs).forEach(function(e){if(copy.hasNode(e.v)&©.hasNode(e.w)){copy.setEdge(e,self.edge(e))}});var parents={};function findParent(v){var parent=self.parent(v);if(parent===undefined||copy.hasNode(parent)){parents[v]=parent;return parent}else if(parent in parents){return parents[parent]}else{return findParent(parent)}}if(this._isCompound){copy.nodes().forEach(v=>copy.setParent(v,findParent(v)))}return copy} -/* === Edge functions ========== */ -/** - * Sets the default edge label or factory function. This label will be - * assigned as default label in case if no label was specified while setting - * an edge or this function will be invoked each time when setting an edge - * with no label specified and returned value * will be used as a label for edge. - * Complexity: O(1). - */setDefaultEdgeLabel(newDefault){this._defaultEdgeLabelFn=newDefault;if(typeof newDefault!=="function"){this._defaultEdgeLabelFn=()=>newDefault}return this} -/** - * Gets the number of edges in the graph. - * Complexity: O(1). - */edgeCount(){return this._edgeCount} -/** - * Gets edges of the graph. In case of compound graph subgraphs are not considered. - * Complexity: O(|E|). - */edges(){return Object.values(this._edgeObjs)} -/** - * Establish an edges path over the nodes in nodes list. If some edge is already - * exists, it will update its label, otherwise it will create an edge between pair - * of nodes with label provided or default label if no label provided. - * Complexity: O(|nodes|). - */setPath(vs,value){var self=this;var args=arguments;vs.reduce(function(v,w){if(args.length>1){self.setEdge(v,w,value)}else{self.setEdge(v,w)}return w});return this} -/** - * Creates or updates the label for the edge (v, w) with the optionally supplied - * name. If label is supplied it is set as the value for the edge. If label is not - * supplied and the edge was created by this call then the default edge label will - * be assigned. The name parameter is only useful with multigraphs. - */setEdge(){var v,w,name,value;var valueSpecified=false;var arg0=arguments[0];if(typeof arg0==="object"&&arg0!==null&&"v"in arg0){v=arg0.v;w=arg0.w;name=arg0.name;if(arguments.length===2){value=arguments[1];valueSpecified=true}}else{v=arg0;w=arguments[1];name=arguments[3];if(arguments.length>2){value=arguments[2];valueSpecified=true}}v=""+v;w=""+w;if(name!==undefined){name=""+name}var e=edgeArgsToId(this._isDirected,v,w,name);if(Object.hasOwn(this._edgeLabels,e)){if(valueSpecified){this._edgeLabels[e]=value}return this}if(name!==undefined&&!this._isMultigraph){throw new Error("Cannot set a named edge when isMultigraph = false")} -// It didn't exist, so we need to create it. -// First ensure the nodes exist. -this.setNode(v);this.setNode(w);this._edgeLabels[e]=valueSpecified?value:this._defaultEdgeLabelFn(v,w,name);var edgeObj=edgeArgsToObj(this._isDirected,v,w,name); -// Ensure we add undirected edges in a consistent way. -v=edgeObj.v;w=edgeObj.w;Object.freeze(edgeObj);this._edgeObjs[e]=edgeObj;incrementOrInitEntry(this._preds[w],v);incrementOrInitEntry(this._sucs[v],w);this._in[w][e]=edgeObj;this._out[v][e]=edgeObj;this._edgeCount++;return this} -/** - * Gets the label for the specified edge. - * Complexity: O(1). - */edge(v,w,name){var e=arguments.length===1?edgeObjToId(this._isDirected,arguments[0]):edgeArgsToId(this._isDirected,v,w,name);return this._edgeLabels[e]} -/** - * Gets the label for the specified edge and converts it to an object. - * Complexity: O(1) - */edgeAsObj(){const edge=this.edge(...arguments);if(typeof edge!=="object"){return{label:edge}}return edge} -/** - * Detects whether the graph contains specified edge or not. No subgraphs are considered. - * Complexity: O(1). - */hasEdge(v,w,name){var e=arguments.length===1?edgeObjToId(this._isDirected,arguments[0]):edgeArgsToId(this._isDirected,v,w,name);return Object.hasOwn(this._edgeLabels,e)} -/** - * Removes the specified edge from the graph. No subgraphs are considered. - * Complexity: O(1). - */removeEdge(v,w,name){var e=arguments.length===1?edgeObjToId(this._isDirected,arguments[0]):edgeArgsToId(this._isDirected,v,w,name);var edge=this._edgeObjs[e];if(edge){v=edge.v;w=edge.w;delete this._edgeLabels[e];delete this._edgeObjs[e];decrementOrRemoveEntry(this._preds[w],v);decrementOrRemoveEntry(this._sucs[v],w);delete this._in[w][e];delete this._out[v][e];this._edgeCount--}return this} -/** - * Return all edges that point to the node v. Optionally filters those edges down to just those - * coming from node u. Behavior is undefined for undirected graphs - use nodeEdges instead. - * Complexity: O(|E|). - */inEdges(v,u){var inV=this._in[v];if(inV){var edges=Object.values(inV);if(!u){return edges}return edges.filter(edge=>edge.v===u)}} -/** - * Return all edges that are pointed at by node v. Optionally filters those edges down to just - * those point to w. Behavior is undefined for undirected graphs - use nodeEdges instead. - * Complexity: O(|E|). - */outEdges(v,w){var outV=this._out[v];if(outV){var edges=Object.values(outV);if(!w){return edges}return edges.filter(edge=>edge.w===w)}} -/** - * Returns all edges to or from node v regardless of direction. Optionally filters those edges - * down to just those between nodes v and w regardless of direction. - * Complexity: O(|E|). - */nodeEdges(v,w){var inEdges=this.inEdges(v,w);if(inEdges){return inEdges.concat(this.outEdges(v,w))}}}function incrementOrInitEntry(map,k){if(map[k]){map[k]++}else{map[k]=1}}function decrementOrRemoveEntry(map,k){if(!--map[k]){delete map[k]}}function edgeArgsToId(isDirected,v_,w_,name){var v=""+v_;var w=""+w_;if(!isDirected&&v>w){var tmp=v;v=w;w=tmp}return v+EDGE_KEY_DELIM+w+EDGE_KEY_DELIM+(name===undefined?DEFAULT_EDGE_NAME:name)}function edgeArgsToObj(isDirected,v_,w_,name){var v=""+v_;var w=""+w_;if(!isDirected&&v>w){var tmp=v;v=w;w=tmp}var edgeObj={v:v,w:w};if(name){edgeObj.name=name}return edgeObj}function edgeObjToId(isDirected,edgeObj){return edgeArgsToId(isDirected,edgeObj.v,edgeObj.w,edgeObj.name)}module.exports=Graph},{}],17:[function(require,module,exports){ -// Includes only the "core" of graphlib -module.exports={Graph:require("./graph"),version:require("./version")}},{"./graph":16,"./version":19}],18:[function(require,module,exports){var Graph=require("./graph");module.exports={write:write,read:read}; -/** - * Creates a JSON representation of the graph that can be serialized to a string with - * JSON.stringify. The graph can later be restored using json.read. - */function write(g){var json={options:{directed:g.isDirected(),multigraph:g.isMultigraph(),compound:g.isCompound()},nodes:writeNodes(g),edges:writeEdges(g)};if(g.graph()!==undefined){json.value=structuredClone(g.graph())}return json}function writeNodes(g){return g.nodes().map(function(v){var nodeValue=g.node(v);var parent=g.parent(v);var node={v:v};if(nodeValue!==undefined){node.value=nodeValue}if(parent!==undefined){node.parent=parent}return node})}function writeEdges(g){return g.edges().map(function(e){var edgeValue=g.edge(e);var edge={v:e.v,w:e.w};if(e.name!==undefined){edge.name=e.name}if(edgeValue!==undefined){edge.value=edgeValue}return edge})} -/** - * Takes JSON as input and returns the graph representation. - * - * @example - * var g2 = graphlib.json.read(JSON.parse(str)); - * g2.nodes(); - * // ['a', 'b'] - * g2.edges() - * // [ { v: 'a', w: 'b' } ] - */function read(json){var g=new Graph(json.options).setGraph(json.value);json.nodes.forEach(function(entry){g.setNode(entry.v,entry.value);if(entry.parent){g.setParent(entry.v,entry.parent)}});json.edges.forEach(function(entry){g.setEdge({v:entry.v,w:entry.w,name:entry.name},entry.value)});return g}},{"./graph":16}],19:[function(require,module,exports){module.exports="2.2.4"},{}]},{},[1])(1)}); diff --git a/dist/graphlib.js b/dist/graphlib.js deleted file mode 100644 index 2e297c95..00000000 --- a/dist/graphlib.js +++ /dev/null @@ -1,1396 +0,0 @@ -(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.graphlib = f()}})(function(){var define,module,exports;return (function(){function r(e,n,t){function o(i,f){if(!n[i]){if(!e[i]){var c="function"==typeof require&&require;if(!f&&c)return c(i,!0);if(u)return u(i,!0);var a=new Error("Cannot find module '"+i+"'");throw a.code="MODULE_NOT_FOUND",a}var p=n[i]={exports:{}};e[i][0].call(p.exports,function(r){var n=e[i][1][r];return o(n||r)},p,p.exports,r,e,n,t)}return n[i].exports}for(var u="function"==typeof require&&require,i=0;i g.successors(v) : v => g.neighbors(v); - var orderFunc = order === "post" ? postOrderDfs : preOrderDfs; - - var acc = []; - var visited = {}; - vs.forEach(v => { - if (!g.hasNode(v)) { - throw new Error("Graph does not have node: " + v); - } - - orderFunc(v, navigation, visited, acc); - }); - - return acc; -} - -function postOrderDfs(v, navigation, visited, acc) { - var stack = [[v, false]]; - while (stack.length > 0) { - var curr = stack.pop(); - if (curr[1]) { - acc.push(curr[0]); - } else { - if (!Object.hasOwn(visited, curr[0])) { - visited[curr[0]] = true; - stack.push([curr[0], true]); - forEachRight(navigation(curr[0]), w => stack.push([w, false])); - } - } - } -} - -function preOrderDfs(v, navigation, visited, acc) { - var stack = [v]; - while (stack.length > 0) { - var curr = stack.pop(); - if (!Object.hasOwn(visited, curr)) { - visited[curr] = true; - acc.push(curr); - forEachRight(navigation(curr), w => stack.push(w)); - } - } -} - -function forEachRight(array, iteratee) { - var length = array.length; - while (length--) { - iteratee(array[length], length, array); - } - - return array; -} - -},{}],4:[function(require,module,exports){ -var dijkstra = require("./dijkstra"); - -module.exports = dijkstraAll; - -function dijkstraAll(g, weightFunc, edgeFunc) { - return g.nodes().reduce(function(acc, v) { - acc[v] = dijkstra(g, v, weightFunc, edgeFunc); - return acc; - }, {}); -} - -},{"./dijkstra":5}],5:[function(require,module,exports){ -var PriorityQueue = require("../data/priority-queue"); - -module.exports = dijkstra; - -var DEFAULT_WEIGHT_FUNC = () => 1; - -function dijkstra(g, source, weightFn, edgeFn) { - return runDijkstra(g, String(source), - weightFn || DEFAULT_WEIGHT_FUNC, - edgeFn || function(v) { return g.outEdges(v); }); -} - -function runDijkstra(g, source, weightFn, edgeFn) { - var results = {}; - var pq = new PriorityQueue(); - var v, vEntry; - - var updateNeighbors = function(edge) { - var w = edge.v !== v ? edge.v : edge.w; - var wEntry = results[w]; - var weight = weightFn(edge); - var distance = vEntry.distance + weight; - - if (weight < 0) { - throw new Error("dijkstra does not allow negative edge weights. " + - "Bad edge: " + edge + " Weight: " + weight); - } - - if (distance < wEntry.distance) { - wEntry.distance = distance; - wEntry.predecessor = v; - pq.decrease(w, distance); - } - }; - - g.nodes().forEach(function(v) { - var distance = v === source ? 0 : Number.POSITIVE_INFINITY; - results[v] = { distance: distance }; - pq.add(v, distance); - }); - - while (pq.size() > 0) { - v = pq.removeMin(); - vEntry = results[v]; - if (vEntry.distance === Number.POSITIVE_INFINITY) { - break; - } - - edgeFn(v).forEach(updateNeighbors); - } - - return results; -} - -},{"../data/priority-queue":15}],6:[function(require,module,exports){ -var tarjan = require("./tarjan"); - -module.exports = findCycles; - -function findCycles(g) { - return tarjan(g).filter(function(cmpt) { - return cmpt.length > 1 || (cmpt.length === 1 && g.hasEdge(cmpt[0], cmpt[0])); - }); -} - -},{"./tarjan":13}],7:[function(require,module,exports){ -module.exports = floydWarshall; - -var DEFAULT_WEIGHT_FUNC = () => 1; - -function floydWarshall(g, weightFn, edgeFn) { - return runFloydWarshall(g, - weightFn || DEFAULT_WEIGHT_FUNC, - edgeFn || function(v) { return g.outEdges(v); }); -} - -function runFloydWarshall(g, weightFn, edgeFn) { - var results = {}; - var nodes = g.nodes(); - - nodes.forEach(function(v) { - results[v] = {}; - results[v][v] = { distance: 0 }; - nodes.forEach(function(w) { - if (v !== w) { - results[v][w] = { distance: Number.POSITIVE_INFINITY }; - } - }); - edgeFn(v).forEach(function(edge) { - var w = edge.v === v ? edge.w : edge.v; - var d = weightFn(edge); - results[v][w] = { distance: d, predecessor: v }; - }); - }); - - nodes.forEach(function(k) { - var rowK = results[k]; - nodes.forEach(function(i) { - var rowI = results[i]; - nodes.forEach(function(j) { - var ik = rowI[k]; - var kj = rowK[j]; - var ij = rowI[j]; - var altDistance = ik.distance + kj.distance; - if (altDistance < ij.distance) { - ij.distance = altDistance; - ij.predecessor = kj.predecessor; - } - }); - }); - }); - - return results; -} - -},{}],8:[function(require,module,exports){ -module.exports = { - components: require("./components"), - dijkstra: require("./dijkstra"), - dijkstraAll: require("./dijkstra-all"), - findCycles: require("./find-cycles"), - floydWarshall: require("./floyd-warshall"), - isAcyclic: require("./is-acyclic"), - postorder: require("./postorder"), - preorder: require("./preorder"), - prim: require("./prim"), - tarjan: require("./tarjan"), - topsort: require("./topsort") -}; - -},{"./components":2,"./dijkstra":5,"./dijkstra-all":4,"./find-cycles":6,"./floyd-warshall":7,"./is-acyclic":9,"./postorder":10,"./preorder":11,"./prim":12,"./tarjan":13,"./topsort":14}],9:[function(require,module,exports){ -var topsort = require("./topsort"); - -module.exports = isAcyclic; - -function isAcyclic(g) { - try { - topsort(g); - } catch (e) { - if (e instanceof topsort.CycleException) { - return false; - } - throw e; - } - return true; -} - -},{"./topsort":14}],10:[function(require,module,exports){ -var dfs = require("./dfs"); - -module.exports = postorder; - -function postorder(g, vs) { - return dfs(g, vs, "post"); -} - -},{"./dfs":3}],11:[function(require,module,exports){ -var dfs = require("./dfs"); - -module.exports = preorder; - -function preorder(g, vs) { - return dfs(g, vs, "pre"); -} - -},{"./dfs":3}],12:[function(require,module,exports){ -var Graph = require("../graph"); -var PriorityQueue = require("../data/priority-queue"); - -module.exports = prim; - -function prim(g, weightFunc) { - var result = new Graph(); - var parents = {}; - var pq = new PriorityQueue(); - var v; - - function updateNeighbors(edge) { - var w = edge.v === v ? edge.w : edge.v; - var pri = pq.priority(w); - if (pri !== undefined) { - var edgeWeight = weightFunc(edge); - if (edgeWeight < pri) { - parents[w] = v; - pq.decrease(w, edgeWeight); - } - } - } - - if (g.nodeCount() === 0) { - return result; - } - - g.nodes().forEach(function(v) { - pq.add(v, Number.POSITIVE_INFINITY); - result.setNode(v); - }); - - // Start from an arbitrary node - pq.decrease(g.nodes()[0], 0); - - var init = false; - while (pq.size() > 0) { - v = pq.removeMin(); - if (Object.hasOwn(parents, v)) { - result.setEdge(v, parents[v]); - } else if (init) { - throw new Error("Input graph is not connected: " + g); - } else { - init = true; - } - - g.nodeEdges(v).forEach(updateNeighbors); - } - - return result; -} - -},{"../data/priority-queue":15,"../graph":16}],13:[function(require,module,exports){ -module.exports = tarjan; - -function tarjan(g) { - var index = 0; - var stack = []; - var visited = {}; // node id -> { onStack, lowlink, index } - var results = []; - - function dfs(v) { - var entry = visited[v] = { - onStack: true, - lowlink: index, - index: index++ - }; - stack.push(v); - - g.successors(v).forEach(function(w) { - if (!Object.hasOwn(visited, w)) { - dfs(w); - entry.lowlink = Math.min(entry.lowlink, visited[w].lowlink); - } else if (visited[w].onStack) { - entry.lowlink = Math.min(entry.lowlink, visited[w].index); - } - }); - - if (entry.lowlink === entry.index) { - var cmpt = []; - var w; - do { - w = stack.pop(); - visited[w].onStack = false; - cmpt.push(w); - } while (v !== w); - results.push(cmpt); - } - } - - g.nodes().forEach(function(v) { - if (!Object.hasOwn(visited, v)) { - dfs(v); - } - }); - - return results; -} - -},{}],14:[function(require,module,exports){ -function topsort(g) { - var visited = {}; - var stack = {}; - var results = []; - - function visit(node) { - if (Object.hasOwn(stack, node)) { - throw new CycleException(); - } - - if (!Object.hasOwn(visited, node)) { - stack[node] = true; - visited[node] = true; - g.predecessors(node).forEach(visit); - delete stack[node]; - results.push(node); - } - } - - g.sinks().forEach(visit); - - if (Object.keys(visited).length !== g.nodeCount()) { - throw new CycleException(); - } - - return results; -} - -class CycleException extends Error { - constructor() { - super(...arguments); - } -} - -module.exports = topsort; -topsort.CycleException = CycleException; - -},{}],15:[function(require,module,exports){ -/** - * A min-priority queue data structure. This algorithm is derived from Cormen, - * et al., "Introduction to Algorithms". The basic idea of a min-priority - * queue is that you can efficiently (in O(1) time) get the smallest key in - * the queue. Adding and removing elements takes O(log n) time. A key can - * have its priority decreased in O(log n) time. - */ -class PriorityQueue { - _arr = []; - _keyIndices = {}; - - /** - * Returns the number of elements in the queue. Takes `O(1)` time. - */ - size() { - return this._arr.length; - } - - /** - * Returns the keys that are in the queue. Takes `O(n)` time. - */ - keys() { - return this._arr.map(function(x) { return x.key; }); - } - - /** - * Returns `true` if **key** is in the queue and `false` if not. - */ - has(key) { - return Object.hasOwn(this._keyIndices, key); - } - - /** - * Returns the priority for **key**. If **key** is not present in the queue - * then this function returns `undefined`. Takes `O(1)` time. - * - * @param {Object} key - */ - priority(key) { - var index = this._keyIndices[key]; - if (index !== undefined) { - return this._arr[index].priority; - } - } - - /** - * Returns the key for the minimum element in this queue. If the queue is - * empty this function throws an Error. Takes `O(1)` time. - */ - min() { - if (this.size() === 0) { - throw new Error("Queue underflow"); - } - return this._arr[0].key; - } - - /** - * Inserts a new key into the priority queue. If the key already exists in - * the queue this function returns `false`; otherwise it will return `true`. - * Takes `O(n)` time. - * - * @param {Object} key the key to add - * @param {Number} priority the initial priority for the key - */ - add(key, priority) { - var keyIndices = this._keyIndices; - key = String(key); - if (!Object.hasOwn(keyIndices, key)) { - var arr = this._arr; - var index = arr.length; - keyIndices[key] = index; - arr.push({key: key, priority: priority}); - this._decrease(index); - return true; - } - return false; - } - - /** - * Removes and returns the smallest key in the queue. Takes `O(log n)` time. - */ - removeMin() { - this._swap(0, this._arr.length - 1); - var min = this._arr.pop(); - delete this._keyIndices[min.key]; - this._heapify(0); - return min.key; - } - - /** - * Decreases the priority for **key** to **priority**. If the new priority is - * greater than the previous priority, this function will throw an Error. - * - * @param {Object} key the key for which to raise priority - * @param {Number} priority the new priority for the key - */ - decrease(key, priority) { - var index = this._keyIndices[key]; - if (priority > this._arr[index].priority) { - throw new Error("New priority is greater than current priority. " + - "Key: " + key + " Old: " + this._arr[index].priority + " New: " + priority); - } - this._arr[index].priority = priority; - this._decrease(index); - } - - _heapify(i) { - var arr = this._arr; - var l = 2 * i; - var r = l + 1; - var largest = i; - if (l < arr.length) { - largest = arr[l].priority < arr[largest].priority ? l : largest; - if (r < arr.length) { - largest = arr[r].priority < arr[largest].priority ? r : largest; - } - if (largest !== i) { - this._swap(i, largest); - this._heapify(largest); - } - } - } - - _decrease(index) { - var arr = this._arr; - var priority = arr[index].priority; - var parent; - while (index !== 0) { - parent = index >> 1; - if (arr[parent].priority < priority) { - break; - } - this._swap(index, parent); - index = parent; - } - } - - _swap(i, j) { - var arr = this._arr; - var keyIndices = this._keyIndices; - var origArrI = arr[i]; - var origArrJ = arr[j]; - arr[i] = origArrJ; - arr[j] = origArrI; - keyIndices[origArrJ.key] = i; - keyIndices[origArrI.key] = j; - } -} - -module.exports = PriorityQueue; - -},{}],16:[function(require,module,exports){ -"use strict"; - -var DEFAULT_EDGE_NAME = "\x00"; -var GRAPH_NODE = "\x00"; -var EDGE_KEY_DELIM = "\x01"; - -// Implementation notes: -// -// * Node id query functions should return string ids for the nodes -// * Edge id query functions should return an "edgeObj", edge object, that is -// composed of enough information to uniquely identify an edge: {v, w, name}. -// * Internally we use an "edgeId", a stringified form of the edgeObj, to -// reference edges. This is because we need a performant way to look these -// edges up and, object properties, which have string keys, are the closest -// we're going to get to a performant hashtable in JavaScript. - -class Graph { - _isDirected = true; - _isMultigraph = false; - _isCompound = false; - - // Label for the graph itself - _label; - - // Defaults to be set when creating a new node - _defaultNodeLabelFn = () => undefined; - - // Defaults to be set when creating a new edge - _defaultEdgeLabelFn = () => undefined; - - // v -> label - _nodes = {}; - - // v -> edgeObj - _in = {}; - - // u -> v -> Number - _preds = {}; - - // v -> edgeObj - _out = {}; - - // v -> w -> Number - _sucs = {}; - - // e -> edgeObj - _edgeObjs = {}; - - // e -> label - _edgeLabels = {}; - - /* Number of nodes in the graph. Should only be changed by the implementation. */ - _nodeCount = 0; - - /* Number of edges in the graph. Should only be changed by the implementation. */ - _edgeCount = 0; - - _parent; - - _children; - - constructor(opts) { - if (opts) { - this._isDirected = Object.hasOwn(opts, "directed") ? opts.directed : true; - this._isMultigraph = Object.hasOwn(opts, "multigraph") ? opts.multigraph : false; - this._isCompound = Object.hasOwn(opts, "compound") ? opts.compound : false; - } - - if (this._isCompound) { - // v -> parent - this._parent = {}; - - // v -> children - this._children = {}; - this._children[GRAPH_NODE] = {}; - } - } - - /* === Graph functions ========= */ - - /** - * Whether graph was created with 'directed' flag set to true or not. - */ - isDirected() { - return this._isDirected; - } - - /** - * Whether graph was created with 'multigraph' flag set to true or not. - */ - isMultigraph() { - return this._isMultigraph; - } - - /** - * Whether graph was created with 'compound' flag set to true or not. - */ - isCompound() { - return this._isCompound; - } - - /** - * Sets the label of the graph. - */ - setGraph(label) { - this._label = label; - return this; - } - - /** - * Gets the graph label. - */ - graph() { - return this._label; - } - - - /* === Node functions ========== */ - - /** - * Sets the default node label. If newDefault is a function, it will be - * invoked ach time when setting a label for a node. Otherwise, this label - * will be assigned as default label in case if no label was specified while - * setting a node. - * Complexity: O(1). - */ - setDefaultNodeLabel(newDefault) { - this._defaultNodeLabelFn = newDefault; - if (typeof newDefault !== 'function') { - this._defaultNodeLabelFn = () => newDefault; - } - - return this; - } - - /** - * Gets the number of nodes in the graph. - * Complexity: O(1). - */ - nodeCount() { - return this._nodeCount; - } - - /** - * Gets all nodes of the graph. Note, the in case of compound graph subnodes are - * not included in list. - * Complexity: O(1). - */ - nodes() { - return Object.keys(this._nodes); - } - - /** - * Gets list of nodes without in-edges. - * Complexity: O(|V|). - */ - sources() { - var self = this; - return this.nodes().filter(v => Object.keys(self._in[v]).length === 0); - } - - /** - * Gets list of nodes without out-edges. - * Complexity: O(|V|). - */ - sinks() { - var self = this; - return this.nodes().filter(v => Object.keys(self._out[v]).length === 0); - } - - /** - * Invokes setNode method for each node in names list. - * Complexity: O(|names|). - */ - setNodes(vs, value) { - var args = arguments; - var self = this; - vs.forEach(function(v) { - if (args.length > 1) { - self.setNode(v, value); - } else { - self.setNode(v); - } - }); - return this; - } - - /** - * Creates or updates the value for the node v in the graph. If label is supplied - * it is set as the value for the node. If label is not supplied and the node was - * created by this call then the default node label will be assigned. - * Complexity: O(1). - */ - setNode(v, value) { - if (Object.hasOwn(this._nodes, v)) { - if (arguments.length > 1) { - this._nodes[v] = value; - } - return this; - } - - this._nodes[v] = arguments.length > 1 ? value : this._defaultNodeLabelFn(v); - if (this._isCompound) { - this._parent[v] = GRAPH_NODE; - this._children[v] = {}; - this._children[GRAPH_NODE][v] = true; - } - this._in[v] = {}; - this._preds[v] = {}; - this._out[v] = {}; - this._sucs[v] = {}; - ++this._nodeCount; - return this; - } - - /** - * Gets the label of node with specified name. - * Complexity: O(|V|). - */ - node(v) { - return this._nodes[v]; - } - - /** - * Detects whether graph has a node with specified name or not. - */ - hasNode(v) { - return Object.hasOwn(this._nodes, v); - } - - /** - * Remove the node with the name from the graph or do nothing if the node is not in - * the graph. If the node was removed this function also removes any incident - * edges. - * Complexity: O(1). - */ - removeNode(v) { - var self = this; - if (Object.hasOwn(this._nodes, v)) { - var removeEdge = e => self.removeEdge(self._edgeObjs[e]); - delete this._nodes[v]; - if (this._isCompound) { - this._removeFromParentsChildList(v); - delete this._parent[v]; - this.children(v).forEach(function(child) { - self.setParent(child); - }); - delete this._children[v]; - } - Object.keys(this._in[v]).forEach(removeEdge); - delete this._in[v]; - delete this._preds[v]; - Object.keys(this._out[v]).forEach(removeEdge); - delete this._out[v]; - delete this._sucs[v]; - --this._nodeCount; - } - return this; - } - - /** - * Sets node p as a parent for node v if it is defined, or removes the - * parent for v if p is undefined. Method throws an exception in case of - * invoking it in context of noncompound graph. - * Average-case complexity: O(1). - */ - setParent(v, parent) { - if (!this._isCompound) { - throw new Error("Cannot set parent in a non-compound graph"); - } - - if (parent === undefined) { - parent = GRAPH_NODE; - } else { - // Coerce parent to string - parent += ""; - for (var ancestor = parent; ancestor !== undefined; ancestor = this.parent(ancestor)) { - if (ancestor === v) { - throw new Error("Setting " + parent+ " as parent of " + v + - " would create a cycle"); - } - } - - this.setNode(parent); - } - - this.setNode(v); - this._removeFromParentsChildList(v); - this._parent[v] = parent; - this._children[parent][v] = true; - return this; - } - - _removeFromParentsChildList(v) { - delete this._children[this._parent[v]][v]; - } - - /** - * Gets parent node for node v. - * Complexity: O(1). - */ - parent(v) { - if (this._isCompound) { - var parent = this._parent[v]; - if (parent !== GRAPH_NODE) { - return parent; - } - } - } - - /** - * Gets list of direct children of node v. - * Complexity: O(1). - */ - children(v = GRAPH_NODE) { - if (this._isCompound) { - var children = this._children[v]; - if (children) { - return Object.keys(children); - } - } else if (v === GRAPH_NODE) { - return this.nodes(); - } else if (this.hasNode(v)) { - return []; - } - } - - /** - * Return all nodes that are predecessors of the specified node or undefined if node v is not in - * the graph. Behavior is undefined for undirected graphs - use neighbors instead. - * Complexity: O(|V|). - */ - predecessors(v) { - var predsV = this._preds[v]; - if (predsV) { - return Object.keys(predsV); - } - } - - /** - * Return all nodes that are successors of the specified node or undefined if node v is not in - * the graph. Behavior is undefined for undirected graphs - use neighbors instead. - * Complexity: O(|V|). - */ - successors(v) { - var sucsV = this._sucs[v]; - if (sucsV) { - return Object.keys(sucsV); - } - } - - /** - * Return all nodes that are predecessors or successors of the specified node or undefined if - * node v is not in the graph. - * Complexity: O(|V|). - */ - neighbors(v) { - var preds = this.predecessors(v); - if (preds) { - const union = new Set(preds); - for (var succ of this.successors(v)) { - union.add(succ); - } - - return Array.from(union.values()); - } - } - - isLeaf(v) { - var neighbors; - if (this.isDirected()) { - neighbors = this.successors(v); - } else { - neighbors = this.neighbors(v); - } - return neighbors.length === 0; - } - - /** - * Creates new graph with nodes filtered via filter. Edges incident to rejected node - * are also removed. In case of compound graph, if parent is rejected by filter, - * than all its children are rejected too. - * Average-case complexity: O(|E|+|V|). - */ - filterNodes(filter) { - var copy = new this.constructor({ - directed: this._isDirected, - multigraph: this._isMultigraph, - compound: this._isCompound - }); - - copy.setGraph(this.graph()); - - var self = this; - Object.entries(this._nodes).forEach(function([v, value]) { - if (filter(v)) { - copy.setNode(v, value); - } - }); - - Object.values(this._edgeObjs).forEach(function(e) { - if (copy.hasNode(e.v) && copy.hasNode(e.w)) { - copy.setEdge(e, self.edge(e)); - } - }); - - var parents = {}; - function findParent(v) { - var parent = self.parent(v); - if (parent === undefined || copy.hasNode(parent)) { - parents[v] = parent; - return parent; - } else if (parent in parents) { - return parents[parent]; - } else { - return findParent(parent); - } - } - - if (this._isCompound) { - copy.nodes().forEach(v => copy.setParent(v, findParent(v))); - } - - return copy; - } - - /* === Edge functions ========== */ - - /** - * Sets the default edge label or factory function. This label will be - * assigned as default label in case if no label was specified while setting - * an edge or this function will be invoked each time when setting an edge - * with no label specified and returned value * will be used as a label for edge. - * Complexity: O(1). - */ - setDefaultEdgeLabel(newDefault) { - this._defaultEdgeLabelFn = newDefault; - if (typeof newDefault !== 'function') { - this._defaultEdgeLabelFn = () => newDefault; - } - - return this; - } - - /** - * Gets the number of edges in the graph. - * Complexity: O(1). - */ - edgeCount() { - return this._edgeCount; - } - - /** - * Gets edges of the graph. In case of compound graph subgraphs are not considered. - * Complexity: O(|E|). - */ - edges() { - return Object.values(this._edgeObjs); - } - - /** - * Establish an edges path over the nodes in nodes list. If some edge is already - * exists, it will update its label, otherwise it will create an edge between pair - * of nodes with label provided or default label if no label provided. - * Complexity: O(|nodes|). - */ - setPath(vs, value) { - var self = this; - var args = arguments; - vs.reduce(function(v, w) { - if (args.length > 1) { - self.setEdge(v, w, value); - } else { - self.setEdge(v, w); - } - return w; - }); - return this; - } - - /** - * Creates or updates the label for the edge (v, w) with the optionally supplied - * name. If label is supplied it is set as the value for the edge. If label is not - * supplied and the edge was created by this call then the default edge label will - * be assigned. The name parameter is only useful with multigraphs. - */ - setEdge() { - var v, w, name, value; - var valueSpecified = false; - var arg0 = arguments[0]; - - if (typeof arg0 === "object" && arg0 !== null && "v" in arg0) { - v = arg0.v; - w = arg0.w; - name = arg0.name; - if (arguments.length === 2) { - value = arguments[1]; - valueSpecified = true; - } - } else { - v = arg0; - w = arguments[1]; - name = arguments[3]; - if (arguments.length > 2) { - value = arguments[2]; - valueSpecified = true; - } - } - - v = "" + v; - w = "" + w; - if (name !== undefined) { - name = "" + name; - } - - var e = edgeArgsToId(this._isDirected, v, w, name); - if (Object.hasOwn(this._edgeLabels, e)) { - if (valueSpecified) { - this._edgeLabels[e] = value; - } - return this; - } - - if (name !== undefined && !this._isMultigraph) { - throw new Error("Cannot set a named edge when isMultigraph = false"); - } - - // It didn't exist, so we need to create it. - // First ensure the nodes exist. - this.setNode(v); - this.setNode(w); - - this._edgeLabels[e] = valueSpecified ? value : this._defaultEdgeLabelFn(v, w, name); - - var edgeObj = edgeArgsToObj(this._isDirected, v, w, name); - // Ensure we add undirected edges in a consistent way. - v = edgeObj.v; - w = edgeObj.w; - - Object.freeze(edgeObj); - this._edgeObjs[e] = edgeObj; - incrementOrInitEntry(this._preds[w], v); - incrementOrInitEntry(this._sucs[v], w); - this._in[w][e] = edgeObj; - this._out[v][e] = edgeObj; - this._edgeCount++; - return this; - } - - /** - * Gets the label for the specified edge. - * Complexity: O(1). - */ - edge(v, w, name) { - var e = (arguments.length === 1 - ? edgeObjToId(this._isDirected, arguments[0]) - : edgeArgsToId(this._isDirected, v, w, name)); - return this._edgeLabels[e]; - } - - /** - * Gets the label for the specified edge and converts it to an object. - * Complexity: O(1) - */ - edgeAsObj() { - const edge = this.edge(...arguments); - if (typeof edge !== "object") { - return {label: edge}; - } - - return edge; - } - - /** - * Detects whether the graph contains specified edge or not. No subgraphs are considered. - * Complexity: O(1). - */ - hasEdge(v, w, name) { - var e = (arguments.length === 1 - ? edgeObjToId(this._isDirected, arguments[0]) - : edgeArgsToId(this._isDirected, v, w, name)); - return Object.hasOwn(this._edgeLabels, e); - } - - /** - * Removes the specified edge from the graph. No subgraphs are considered. - * Complexity: O(1). - */ - removeEdge(v, w, name) { - var e = (arguments.length === 1 - ? edgeObjToId(this._isDirected, arguments[0]) - : edgeArgsToId(this._isDirected, v, w, name)); - var edge = this._edgeObjs[e]; - if (edge) { - v = edge.v; - w = edge.w; - delete this._edgeLabels[e]; - delete this._edgeObjs[e]; - decrementOrRemoveEntry(this._preds[w], v); - decrementOrRemoveEntry(this._sucs[v], w); - delete this._in[w][e]; - delete this._out[v][e]; - this._edgeCount--; - } - return this; - } - - /** - * Return all edges that point to the node v. Optionally filters those edges down to just those - * coming from node u. Behavior is undefined for undirected graphs - use nodeEdges instead. - * Complexity: O(|E|). - */ - inEdges(v, u) { - var inV = this._in[v]; - if (inV) { - var edges = Object.values(inV); - if (!u) { - return edges; - } - return edges.filter(edge => edge.v === u); - } - } - - /** - * Return all edges that are pointed at by node v. Optionally filters those edges down to just - * those point to w. Behavior is undefined for undirected graphs - use nodeEdges instead. - * Complexity: O(|E|). - */ - outEdges(v, w) { - var outV = this._out[v]; - if (outV) { - var edges = Object.values(outV); - if (!w) { - return edges; - } - return edges.filter(edge => edge.w === w); - } - } - - /** - * Returns all edges to or from node v regardless of direction. Optionally filters those edges - * down to just those between nodes v and w regardless of direction. - * Complexity: O(|E|). - */ - nodeEdges(v, w) { - var inEdges = this.inEdges(v, w); - if (inEdges) { - return inEdges.concat(this.outEdges(v, w)); - } - } -} - -function incrementOrInitEntry(map, k) { - if (map[k]) { - map[k]++; - } else { - map[k] = 1; - } -} - -function decrementOrRemoveEntry(map, k) { - if (!--map[k]) { delete map[k]; } -} - -function edgeArgsToId(isDirected, v_, w_, name) { - var v = "" + v_; - var w = "" + w_; - if (!isDirected && v > w) { - var tmp = v; - v = w; - w = tmp; - } - return v + EDGE_KEY_DELIM + w + EDGE_KEY_DELIM + - (name === undefined ? DEFAULT_EDGE_NAME : name); -} - -function edgeArgsToObj(isDirected, v_, w_, name) { - var v = "" + v_; - var w = "" + w_; - if (!isDirected && v > w) { - var tmp = v; - v = w; - w = tmp; - } - var edgeObj = { v: v, w: w }; - if (name) { - edgeObj.name = name; - } - return edgeObj; -} - -function edgeObjToId(isDirected, edgeObj) { - return edgeArgsToId(isDirected, edgeObj.v, edgeObj.w, edgeObj.name); -} - -module.exports = Graph; - -},{}],17:[function(require,module,exports){ -// Includes only the "core" of graphlib -module.exports = { - Graph: require("./graph"), - version: require("./version") -}; - -},{"./graph":16,"./version":19}],18:[function(require,module,exports){ -var Graph = require("./graph"); - -module.exports = { - write: write, - read: read -}; - -/** - * Creates a JSON representation of the graph that can be serialized to a string with - * JSON.stringify. The graph can later be restored using json.read. - */ -function write(g) { - var json = { - options: { - directed: g.isDirected(), - multigraph: g.isMultigraph(), - compound: g.isCompound() - }, - nodes: writeNodes(g), - edges: writeEdges(g) - }; - - if (g.graph() !== undefined) { - json.value = structuredClone(g.graph()); - } - return json; -} - -function writeNodes(g) { - return g.nodes().map(function(v) { - var nodeValue = g.node(v); - var parent = g.parent(v); - var node = { v: v }; - if (nodeValue !== undefined) { - node.value = nodeValue; - } - if (parent !== undefined) { - node.parent = parent; - } - return node; - }); -} - -function writeEdges(g) { - return g.edges().map(function(e) { - var edgeValue = g.edge(e); - var edge = { v: e.v, w: e.w }; - if (e.name !== undefined) { - edge.name = e.name; - } - if (edgeValue !== undefined) { - edge.value = edgeValue; - } - return edge; - }); -} - -/** - * Takes JSON as input and returns the graph representation. - * - * @example - * var g2 = graphlib.json.read(JSON.parse(str)); - * g2.nodes(); - * // ['a', 'b'] - * g2.edges() - * // [ { v: 'a', w: 'b' } ] - */ -function read(json) { - var g = new Graph(json.options).setGraph(json.value); - json.nodes.forEach(function(entry) { - g.setNode(entry.v, entry.value); - if (entry.parent) { - g.setParent(entry.v, entry.parent); - } - }); - json.edges.forEach(function(entry) { - g.setEdge({ v: entry.v, w: entry.w, name: entry.name }, entry.value); - }); - return g; -} - -},{"./graph":16}],19:[function(require,module,exports){ -module.exports = '2.2.4'; - -},{}]},{},[1])(1) -}); diff --git a/dist/graphlib.min.js b/dist/graphlib.min.js deleted file mode 100644 index c925c2b6..00000000 --- a/dist/graphlib.min.js +++ /dev/null @@ -1,304 +0,0 @@ -(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.graphlib=f()}})(function(){var define,module,exports;return function(){function r(e,n,t){function o(i,f){if(!n[i]){if(!e[i]){var c="function"==typeof require&&require;if(!f&&c)return c(i,!0);if(u)return u(i,!0);var a=new Error("Cannot find module '"+i+"'");throw a.code="MODULE_NOT_FOUND",a}var p=n[i]={exports:{}};e[i][0].call(p.exports,function(r){var n=e[i][1][r];return o(n||r)},p,p.exports,r,e,n,t)}return n[i].exports}for(var u="function"==typeof require&&require,i=0;ig.successors(v):v=>g.neighbors(v);var orderFunc=order==="post"?postOrderDfs:preOrderDfs;var acc=[];var visited={};vs.forEach(v=>{if(!g.hasNode(v)){throw new Error("Graph does not have node: "+v)}orderFunc(v,navigation,visited,acc)});return acc}function postOrderDfs(v,navigation,visited,acc){var stack=[[v,false]];while(stack.length>0){var curr=stack.pop();if(curr[1]){acc.push(curr[0])}else{if(!Object.hasOwn(visited,curr[0])){visited[curr[0]]=true;stack.push([curr[0],true]);forEachRight(navigation(curr[0]),w=>stack.push([w,false]))}}}}function preOrderDfs(v,navigation,visited,acc){var stack=[v];while(stack.length>0){var curr=stack.pop();if(!Object.hasOwn(visited,curr)){visited[curr]=true;acc.push(curr);forEachRight(navigation(curr),w=>stack.push(w))}}}function forEachRight(array,iteratee){var length=array.length;while(length--){iteratee(array[length],length,array)}return array}},{}],4:[function(require,module,exports){var dijkstra=require("./dijkstra");module.exports=dijkstraAll;function dijkstraAll(g,weightFunc,edgeFunc){return g.nodes().reduce(function(acc,v){acc[v]=dijkstra(g,v,weightFunc,edgeFunc);return acc},{})}},{"./dijkstra":5}],5:[function(require,module,exports){var PriorityQueue=require("../data/priority-queue");module.exports=dijkstra;var DEFAULT_WEIGHT_FUNC=()=>1;function dijkstra(g,source,weightFn,edgeFn){return runDijkstra(g,String(source),weightFn||DEFAULT_WEIGHT_FUNC,edgeFn||function(v){return g.outEdges(v)})}function runDijkstra(g,source,weightFn,edgeFn){var results={};var pq=new PriorityQueue;var v,vEntry;var updateNeighbors=function(edge){var w=edge.v!==v?edge.v:edge.w;var wEntry=results[w];var weight=weightFn(edge);var distance=vEntry.distance+weight;if(weight<0){throw new Error("dijkstra does not allow negative edge weights. "+"Bad edge: "+edge+" Weight: "+weight)}if(distance0){v=pq.removeMin();vEntry=results[v];if(vEntry.distance===Number.POSITIVE_INFINITY){break}edgeFn(v).forEach(updateNeighbors)}return results}},{"../data/priority-queue":15}],6:[function(require,module,exports){var tarjan=require("./tarjan");module.exports=findCycles;function findCycles(g){return tarjan(g).filter(function(cmpt){return cmpt.length>1||cmpt.length===1&&g.hasEdge(cmpt[0],cmpt[0])})}},{"./tarjan":13}],7:[function(require,module,exports){module.exports=floydWarshall;var DEFAULT_WEIGHT_FUNC=()=>1;function floydWarshall(g,weightFn,edgeFn){return runFloydWarshall(g,weightFn||DEFAULT_WEIGHT_FUNC,edgeFn||function(v){return g.outEdges(v)})}function runFloydWarshall(g,weightFn,edgeFn){var results={};var nodes=g.nodes();nodes.forEach(function(v){results[v]={};results[v][v]={distance:0};nodes.forEach(function(w){if(v!==w){results[v][w]={distance:Number.POSITIVE_INFINITY}}});edgeFn(v).forEach(function(edge){var w=edge.v===v?edge.w:edge.v;var d=weightFn(edge);results[v][w]={distance:d,predecessor:v}})});nodes.forEach(function(k){var rowK=results[k];nodes.forEach(function(i){var rowI=results[i];nodes.forEach(function(j){var ik=rowI[k];var kj=rowK[j];var ij=rowI[j];var altDistance=ik.distance+kj.distance;if(altDistance0){v=pq.removeMin();if(Object.hasOwn(parents,v)){result.setEdge(v,parents[v])}else if(init){throw new Error("Input graph is not connected: "+g)}else{init=true}g.nodeEdges(v).forEach(updateNeighbors)}return result}},{"../data/priority-queue":15,"../graph":16}],13:[function(require,module,exports){module.exports=tarjan;function tarjan(g){var index=0;var stack=[];var visited={};// node id -> { onStack, lowlink, index } -var results=[];function dfs(v){var entry=visited[v]={onStack:true,lowlink:index,index:index++};stack.push(v);g.successors(v).forEach(function(w){if(!Object.hasOwn(visited,w)){dfs(w);entry.lowlink=Math.min(entry.lowlink,visited[w].lowlink)}else if(visited[w].onStack){entry.lowlink=Math.min(entry.lowlink,visited[w].index)}});if(entry.lowlink===entry.index){var cmpt=[];var w;do{w=stack.pop();visited[w].onStack=false;cmpt.push(w)}while(v!==w);results.push(cmpt)}}g.nodes().forEach(function(v){if(!Object.hasOwn(visited,v)){dfs(v)}});return results}},{}],14:[function(require,module,exports){function topsort(g){var visited={};var stack={};var results=[];function visit(node){if(Object.hasOwn(stack,node)){throw new CycleException}if(!Object.hasOwn(visited,node)){stack[node]=true;visited[node]=true;g.predecessors(node).forEach(visit);delete stack[node];results.push(node)}}g.sinks().forEach(visit);if(Object.keys(visited).length!==g.nodeCount()){throw new CycleException}return results}class CycleException extends Error{constructor(){super(...arguments)}}module.exports=topsort;topsort.CycleException=CycleException},{}],15:[function(require,module,exports){ -/** - * A min-priority queue data structure. This algorithm is derived from Cormen, - * et al., "Introduction to Algorithms". The basic idea of a min-priority - * queue is that you can efficiently (in O(1) time) get the smallest key in - * the queue. Adding and removing elements takes O(log n) time. A key can - * have its priority decreased in O(log n) time. - */ -class PriorityQueue{_arr=[];_keyIndices={}; -/** - * Returns the number of elements in the queue. Takes `O(1)` time. - */size(){return this._arr.length} -/** - * Returns the keys that are in the queue. Takes `O(n)` time. - */keys(){return this._arr.map(function(x){return x.key})} -/** - * Returns `true` if **key** is in the queue and `false` if not. - */has(key){return Object.hasOwn(this._keyIndices,key)} -/** - * Returns the priority for **key**. If **key** is not present in the queue - * then this function returns `undefined`. Takes `O(1)` time. - * - * @param {Object} key - */priority(key){var index=this._keyIndices[key];if(index!==undefined){return this._arr[index].priority}} -/** - * Returns the key for the minimum element in this queue. If the queue is - * empty this function throws an Error. Takes `O(1)` time. - */min(){if(this.size()===0){throw new Error("Queue underflow")}return this._arr[0].key} -/** - * Inserts a new key into the priority queue. If the key already exists in - * the queue this function returns `false`; otherwise it will return `true`. - * Takes `O(n)` time. - * - * @param {Object} key the key to add - * @param {Number} priority the initial priority for the key - */add(key,priority){var keyIndices=this._keyIndices;key=String(key);if(!Object.hasOwn(keyIndices,key)){var arr=this._arr;var index=arr.length;keyIndices[key]=index;arr.push({key:key,priority:priority});this._decrease(index);return true}return false} -/** - * Removes and returns the smallest key in the queue. Takes `O(log n)` time. - */removeMin(){this._swap(0,this._arr.length-1);var min=this._arr.pop();delete this._keyIndices[min.key];this._heapify(0);return min.key} -/** - * Decreases the priority for **key** to **priority**. If the new priority is - * greater than the previous priority, this function will throw an Error. - * - * @param {Object} key the key for which to raise priority - * @param {Number} priority the new priority for the key - */decrease(key,priority){var index=this._keyIndices[key];if(priority>this._arr[index].priority){throw new Error("New priority is greater than current priority. "+"Key: "+key+" Old: "+this._arr[index].priority+" New: "+priority)}this._arr[index].priority=priority;this._decrease(index)}_heapify(i){var arr=this._arr;var l=2*i;var r=l+1;var largest=i;if(l>1;if(arr[parent].priorityundefined; -// Defaults to be set when creating a new edge -_defaultEdgeLabelFn=()=>undefined; -// v -> label -_nodes={}; -// v -> edgeObj -_in={}; -// u -> v -> Number -_preds={}; -// v -> edgeObj -_out={}; -// v -> w -> Number -_sucs={}; -// e -> edgeObj -_edgeObjs={}; -// e -> label -_edgeLabels={}; -/* Number of nodes in the graph. Should only be changed by the implementation. */_nodeCount=0; -/* Number of edges in the graph. Should only be changed by the implementation. */_edgeCount=0;_parent;_children;constructor(opts){if(opts){this._isDirected=Object.hasOwn(opts,"directed")?opts.directed:true;this._isMultigraph=Object.hasOwn(opts,"multigraph")?opts.multigraph:false;this._isCompound=Object.hasOwn(opts,"compound")?opts.compound:false}if(this._isCompound){ -// v -> parent -this._parent={}; -// v -> children -this._children={};this._children[GRAPH_NODE]={}}} -/* === Graph functions ========= */ -/** - * Whether graph was created with 'directed' flag set to true or not. - */isDirected(){return this._isDirected} -/** - * Whether graph was created with 'multigraph' flag set to true or not. - */isMultigraph(){return this._isMultigraph} -/** - * Whether graph was created with 'compound' flag set to true or not. - */isCompound(){return this._isCompound} -/** - * Sets the label of the graph. - */setGraph(label){this._label=label;return this} -/** - * Gets the graph label. - */graph(){return this._label} -/* === Node functions ========== */ -/** - * Sets the default node label. If newDefault is a function, it will be - * invoked ach time when setting a label for a node. Otherwise, this label - * will be assigned as default label in case if no label was specified while - * setting a node. - * Complexity: O(1). - */setDefaultNodeLabel(newDefault){this._defaultNodeLabelFn=newDefault;if(typeof newDefault!=="function"){this._defaultNodeLabelFn=()=>newDefault}return this} -/** - * Gets the number of nodes in the graph. - * Complexity: O(1). - */nodeCount(){return this._nodeCount} -/** - * Gets all nodes of the graph. Note, the in case of compound graph subnodes are - * not included in list. - * Complexity: O(1). - */nodes(){return Object.keys(this._nodes)} -/** - * Gets list of nodes without in-edges. - * Complexity: O(|V|). - */sources(){var self=this;return this.nodes().filter(v=>Object.keys(self._in[v]).length===0)} -/** - * Gets list of nodes without out-edges. - * Complexity: O(|V|). - */sinks(){var self=this;return this.nodes().filter(v=>Object.keys(self._out[v]).length===0)} -/** - * Invokes setNode method for each node in names list. - * Complexity: O(|names|). - */setNodes(vs,value){var args=arguments;var self=this;vs.forEach(function(v){if(args.length>1){self.setNode(v,value)}else{self.setNode(v)}});return this} -/** - * Creates or updates the value for the node v in the graph. If label is supplied - * it is set as the value for the node. If label is not supplied and the node was - * created by this call then the default node label will be assigned. - * Complexity: O(1). - */setNode(v,value){if(Object.hasOwn(this._nodes,v)){if(arguments.length>1){this._nodes[v]=value}return this}this._nodes[v]=arguments.length>1?value:this._defaultNodeLabelFn(v);if(this._isCompound){this._parent[v]=GRAPH_NODE;this._children[v]={};this._children[GRAPH_NODE][v]=true}this._in[v]={};this._preds[v]={};this._out[v]={};this._sucs[v]={};++this._nodeCount;return this} -/** - * Gets the label of node with specified name. - * Complexity: O(|V|). - */node(v){return this._nodes[v]} -/** - * Detects whether graph has a node with specified name or not. - */hasNode(v){return Object.hasOwn(this._nodes,v)} -/** - * Remove the node with the name from the graph or do nothing if the node is not in - * the graph. If the node was removed this function also removes any incident - * edges. - * Complexity: O(1). - */removeNode(v){var self=this;if(Object.hasOwn(this._nodes,v)){var removeEdge=e=>self.removeEdge(self._edgeObjs[e]);delete this._nodes[v];if(this._isCompound){this._removeFromParentsChildList(v);delete this._parent[v];this.children(v).forEach(function(child){self.setParent(child)});delete this._children[v]}Object.keys(this._in[v]).forEach(removeEdge);delete this._in[v];delete this._preds[v];Object.keys(this._out[v]).forEach(removeEdge);delete this._out[v];delete this._sucs[v];--this._nodeCount}return this} -/** - * Sets node p as a parent for node v if it is defined, or removes the - * parent for v if p is undefined. Method throws an exception in case of - * invoking it in context of noncompound graph. - * Average-case complexity: O(1). - */setParent(v,parent){if(!this._isCompound){throw new Error("Cannot set parent in a non-compound graph")}if(parent===undefined){parent=GRAPH_NODE}else{ -// Coerce parent to string -parent+="";for(var ancestor=parent;ancestor!==undefined;ancestor=this.parent(ancestor)){if(ancestor===v){throw new Error("Setting "+parent+" as parent of "+v+" would create a cycle")}}this.setNode(parent)}this.setNode(v);this._removeFromParentsChildList(v);this._parent[v]=parent;this._children[parent][v]=true;return this}_removeFromParentsChildList(v){delete this._children[this._parent[v]][v]} -/** - * Gets parent node for node v. - * Complexity: O(1). - */parent(v){if(this._isCompound){var parent=this._parent[v];if(parent!==GRAPH_NODE){return parent}}} -/** - * Gets list of direct children of node v. - * Complexity: O(1). - */children(v=GRAPH_NODE){if(this._isCompound){var children=this._children[v];if(children){return Object.keys(children)}}else if(v===GRAPH_NODE){return this.nodes()}else if(this.hasNode(v)){return[]}} -/** - * Return all nodes that are predecessors of the specified node or undefined if node v is not in - * the graph. Behavior is undefined for undirected graphs - use neighbors instead. - * Complexity: O(|V|). - */predecessors(v){var predsV=this._preds[v];if(predsV){return Object.keys(predsV)}} -/** - * Return all nodes that are successors of the specified node or undefined if node v is not in - * the graph. Behavior is undefined for undirected graphs - use neighbors instead. - * Complexity: O(|V|). - */successors(v){var sucsV=this._sucs[v];if(sucsV){return Object.keys(sucsV)}} -/** - * Return all nodes that are predecessors or successors of the specified node or undefined if - * node v is not in the graph. - * Complexity: O(|V|). - */neighbors(v){var preds=this.predecessors(v);if(preds){const union=new Set(preds);for(var succ of this.successors(v)){union.add(succ)}return Array.from(union.values())}}isLeaf(v){var neighbors;if(this.isDirected()){neighbors=this.successors(v)}else{neighbors=this.neighbors(v)}return neighbors.length===0} -/** - * Creates new graph with nodes filtered via filter. Edges incident to rejected node - * are also removed. In case of compound graph, if parent is rejected by filter, - * than all its children are rejected too. - * Average-case complexity: O(|E|+|V|). - */filterNodes(filter){var copy=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});copy.setGraph(this.graph());var self=this;Object.entries(this._nodes).forEach(function([v,value]){if(filter(v)){copy.setNode(v,value)}});Object.values(this._edgeObjs).forEach(function(e){if(copy.hasNode(e.v)&©.hasNode(e.w)){copy.setEdge(e,self.edge(e))}});var parents={};function findParent(v){var parent=self.parent(v);if(parent===undefined||copy.hasNode(parent)){parents[v]=parent;return parent}else if(parent in parents){return parents[parent]}else{return findParent(parent)}}if(this._isCompound){copy.nodes().forEach(v=>copy.setParent(v,findParent(v)))}return copy} -/* === Edge functions ========== */ -/** - * Sets the default edge label or factory function. This label will be - * assigned as default label in case if no label was specified while setting - * an edge or this function will be invoked each time when setting an edge - * with no label specified and returned value * will be used as a label for edge. - * Complexity: O(1). - */setDefaultEdgeLabel(newDefault){this._defaultEdgeLabelFn=newDefault;if(typeof newDefault!=="function"){this._defaultEdgeLabelFn=()=>newDefault}return this} -/** - * Gets the number of edges in the graph. - * Complexity: O(1). - */edgeCount(){return this._edgeCount} -/** - * Gets edges of the graph. In case of compound graph subgraphs are not considered. - * Complexity: O(|E|). - */edges(){return Object.values(this._edgeObjs)} -/** - * Establish an edges path over the nodes in nodes list. If some edge is already - * exists, it will update its label, otherwise it will create an edge between pair - * of nodes with label provided or default label if no label provided. - * Complexity: O(|nodes|). - */setPath(vs,value){var self=this;var args=arguments;vs.reduce(function(v,w){if(args.length>1){self.setEdge(v,w,value)}else{self.setEdge(v,w)}return w});return this} -/** - * Creates or updates the label for the edge (v, w) with the optionally supplied - * name. If label is supplied it is set as the value for the edge. If label is not - * supplied and the edge was created by this call then the default edge label will - * be assigned. The name parameter is only useful with multigraphs. - */setEdge(){var v,w,name,value;var valueSpecified=false;var arg0=arguments[0];if(typeof arg0==="object"&&arg0!==null&&"v"in arg0){v=arg0.v;w=arg0.w;name=arg0.name;if(arguments.length===2){value=arguments[1];valueSpecified=true}}else{v=arg0;w=arguments[1];name=arguments[3];if(arguments.length>2){value=arguments[2];valueSpecified=true}}v=""+v;w=""+w;if(name!==undefined){name=""+name}var e=edgeArgsToId(this._isDirected,v,w,name);if(Object.hasOwn(this._edgeLabels,e)){if(valueSpecified){this._edgeLabels[e]=value}return this}if(name!==undefined&&!this._isMultigraph){throw new Error("Cannot set a named edge when isMultigraph = false")} -// It didn't exist, so we need to create it. -// First ensure the nodes exist. -this.setNode(v);this.setNode(w);this._edgeLabels[e]=valueSpecified?value:this._defaultEdgeLabelFn(v,w,name);var edgeObj=edgeArgsToObj(this._isDirected,v,w,name); -// Ensure we add undirected edges in a consistent way. -v=edgeObj.v;w=edgeObj.w;Object.freeze(edgeObj);this._edgeObjs[e]=edgeObj;incrementOrInitEntry(this._preds[w],v);incrementOrInitEntry(this._sucs[v],w);this._in[w][e]=edgeObj;this._out[v][e]=edgeObj;this._edgeCount++;return this} -/** - * Gets the label for the specified edge. - * Complexity: O(1). - */edge(v,w,name){var e=arguments.length===1?edgeObjToId(this._isDirected,arguments[0]):edgeArgsToId(this._isDirected,v,w,name);return this._edgeLabels[e]} -/** - * Gets the label for the specified edge and converts it to an object. - * Complexity: O(1) - */edgeAsObj(){const edge=this.edge(...arguments);if(typeof edge!=="object"){return{label:edge}}return edge} -/** - * Detects whether the graph contains specified edge or not. No subgraphs are considered. - * Complexity: O(1). - */hasEdge(v,w,name){var e=arguments.length===1?edgeObjToId(this._isDirected,arguments[0]):edgeArgsToId(this._isDirected,v,w,name);return Object.hasOwn(this._edgeLabels,e)} -/** - * Removes the specified edge from the graph. No subgraphs are considered. - * Complexity: O(1). - */removeEdge(v,w,name){var e=arguments.length===1?edgeObjToId(this._isDirected,arguments[0]):edgeArgsToId(this._isDirected,v,w,name);var edge=this._edgeObjs[e];if(edge){v=edge.v;w=edge.w;delete this._edgeLabels[e];delete this._edgeObjs[e];decrementOrRemoveEntry(this._preds[w],v);decrementOrRemoveEntry(this._sucs[v],w);delete this._in[w][e];delete this._out[v][e];this._edgeCount--}return this} -/** - * Return all edges that point to the node v. Optionally filters those edges down to just those - * coming from node u. Behavior is undefined for undirected graphs - use nodeEdges instead. - * Complexity: O(|E|). - */inEdges(v,u){var inV=this._in[v];if(inV){var edges=Object.values(inV);if(!u){return edges}return edges.filter(edge=>edge.v===u)}} -/** - * Return all edges that are pointed at by node v. Optionally filters those edges down to just - * those point to w. Behavior is undefined for undirected graphs - use nodeEdges instead. - * Complexity: O(|E|). - */outEdges(v,w){var outV=this._out[v];if(outV){var edges=Object.values(outV);if(!w){return edges}return edges.filter(edge=>edge.w===w)}} -/** - * Returns all edges to or from node v regardless of direction. Optionally filters those edges - * down to just those between nodes v and w regardless of direction. - * Complexity: O(|E|). - */nodeEdges(v,w){var inEdges=this.inEdges(v,w);if(inEdges){return inEdges.concat(this.outEdges(v,w))}}}function incrementOrInitEntry(map,k){if(map[k]){map[k]++}else{map[k]=1}}function decrementOrRemoveEntry(map,k){if(!--map[k]){delete map[k]}}function edgeArgsToId(isDirected,v_,w_,name){var v=""+v_;var w=""+w_;if(!isDirected&&v>w){var tmp=v;v=w;w=tmp}return v+EDGE_KEY_DELIM+w+EDGE_KEY_DELIM+(name===undefined?DEFAULT_EDGE_NAME:name)}function edgeArgsToObj(isDirected,v_,w_,name){var v=""+v_;var w=""+w_;if(!isDirected&&v>w){var tmp=v;v=w;w=tmp}var edgeObj={v:v,w:w};if(name){edgeObj.name=name}return edgeObj}function edgeObjToId(isDirected,edgeObj){return edgeArgsToId(isDirected,edgeObj.v,edgeObj.w,edgeObj.name)}module.exports=Graph},{}],17:[function(require,module,exports){ -// Includes only the "core" of graphlib -module.exports={Graph:require("./graph"),version:require("./version")}},{"./graph":16,"./version":19}],18:[function(require,module,exports){var Graph=require("./graph");module.exports={write:write,read:read}; -/** - * Creates a JSON representation of the graph that can be serialized to a string with - * JSON.stringify. The graph can later be restored using json.read. - */function write(g){var json={options:{directed:g.isDirected(),multigraph:g.isMultigraph(),compound:g.isCompound()},nodes:writeNodes(g),edges:writeEdges(g)};if(g.graph()!==undefined){json.value=structuredClone(g.graph())}return json}function writeNodes(g){return g.nodes().map(function(v){var nodeValue=g.node(v);var parent=g.parent(v);var node={v:v};if(nodeValue!==undefined){node.value=nodeValue}if(parent!==undefined){node.parent=parent}return node})}function writeEdges(g){return g.edges().map(function(e){var edgeValue=g.edge(e);var edge={v:e.v,w:e.w};if(e.name!==undefined){edge.name=e.name}if(edgeValue!==undefined){edge.value=edgeValue}return edge})} -/** - * Takes JSON as input and returns the graph representation. - * - * @example - * var g2 = graphlib.json.read(JSON.parse(str)); - * g2.nodes(); - * // ['a', 'b'] - * g2.edges() - * // [ { v: 'a', w: 'b' } ] - */function read(json){var g=new Graph(json.options).setGraph(json.value);json.nodes.forEach(function(entry){g.setNode(entry.v,entry.value);if(entry.parent){g.setParent(entry.v,entry.parent)}});json.edges.forEach(function(entry){g.setEdge({v:entry.v,w:entry.w,name:entry.name},entry.value)});return g}},{"./graph":16}],19:[function(require,module,exports){module.exports="2.2.4"},{}]},{},[1])(1)}); diff --git a/index.d.ts b/index.d.ts index 77583f78..aa3cc62d 100644 --- a/index.d.ts +++ b/index.d.ts @@ -1,623 +1,598 @@ -// Type definitions for graphlib 2.1.1 +// Type definitions for graphlib 3.0.0 // Project: https://github.com/cpettitt/graphlib // Definitions by: Dan Vanderkam , Dan Mironenko // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped -declare module "@dagrejs/graphlib" { - export interface GraphOptions { - directed?: boolean; // default: true. - multigraph?: boolean; // default: false. - compound?: boolean; // default: false. - } - - export interface Edge { - v: string; - w: string; - /** The name that uniquely identifies a multi-edge. */ - name?: string; - } - - export class Graph { - constructor(options?: GraphOptions); - - /** - * Sets the default node label. This label will be assigned as default label - * in case if no label was specified while setting a node. - * Complexity: O(1). - * - * @argument label - default node label. - * @returns the graph, allowing this to be chained with other functions. - */ - setDefaultNodeLabel(label: NodeLabel): this; - - /** - * Sets the default node label factory function. This function will be invoked - * each time when setting a node with no label specified and returned value - * will be used as a label for node. - * Complexity: O(1). - * - * @argument labelFn - default node label factory function. - * @returns the graph, allowing this to be chained with other functions. - */ - setDefaultNodeLabel(labelFn: (v: string) => NodeLabel): this; - - /** - * Creates or updates the value for the node v in the graph. If label is supplied - * it is set as the value for the node. If label is not supplied and the node was - * created by this call then the default node label will be assigned. - * Complexity: O(1). - * - * @argument name - node name. - * @argument label - value to set for node. - * @returns the graph, allowing this to be chained with other functions. - */ - setNode(name: string, label?: NodeLabel): this; - - /** - * Invokes setNode method for each node in names list. - * Complexity: O(|names|). - * - * @argument names - list of nodes names to be set. - * @argument label - value to set for each node in list. - * @returns the graph, allowing this to be chained with other functions. - */ - setNodes(names: string[], label?: NodeLabel): this; - - /** - * Sets node p as a parent for node v if it is defined, or removes the - * parent for v if p is undefined. Method throws an exception in case of - * invoking it in context of noncompound graph. - * Average-case complexity: O(1). - * - * @argument v - node to be child for p. - * @argument p - node to be parent for v. - * @returns the graph, allowing this to be chained with other functions. - */ - setParent(v: string, p?: string): this; - - /** - * Gets parent node for node v. - * Complexity: O(1). - * - * @argument v - node to get parent of. - * @returns parent node name or void if v has no parent. - */ - parent(v: string): string | void; - - /** - * Gets list of direct children of node v. - * Complexity: O(1). - * - * @argument v - node to get children of. - * @returns children nodes names list. - */ - children(v: string): string[]; - - /** - * Creates new graph with nodes filtered via filter. Edges incident to rejected node - * are also removed. In case of compound graph, if parent is rejected by filter, - * than all its children are rejected too. - * Average-case complexity: O(|E|+|V|). - * - * @argument filter - filtration function detecting whether the node should stay or not. - * @returns new graph made from current and nodes filtered. - */ - filterNodes(filter: (v: string) => boolean): this; - - /** - * Sets the default edge label. This label will be assigned as default label - * in case if no label was specified while setting an edge. - * Complexity: O(1). - * - * @argument label - default edge label. - * @returns the graph, allowing this to be chained with other functions. - */ - setDefaultEdgeLabel(label: EdgeLabel): this; - - /** - * Sets the default edge label factory function. This function will be invoked - * each time when setting an edge with no label specified and returned value - * will be used as a label for edge. - * Complexity: O(1). - * - * @argument labelFn - default edge label factory function. - * @returns the graph, allowing this to be chained with other functions. - */ - setDefaultEdgeLabel(labelFn: (v: string) => EdgeLabel): this; - - /** - * Establish an edges path over the nodes in nodes list. If some edge is already - * exists, it will update its label, otherwise it will create an edge between pair - * of nodes with label provided or default label if no label provided. - * Complexity: O(|nodes|). - * - * @argument nodes - list of nodes to be connected in series. - * @argument label - value to set for each edge between pairs of nodes. - * @returns the graph, allowing this to be chained with other functions. - */ - setPath(nodes: string[], label?: EdgeLabel): this; - - /** - * Detects whether graph has a node with specified name or not. - - * - * @argument name - name of the node. - * @returns true if graph has node with specified name, false - otherwise. - */ - hasNode(name: string): boolean; - - /** - * Remove the node with the name from the graph or do nothing if the node is not in - * the graph. If the node was removed this function also removes any incident - * edges. - * Complexity: O(1). - * - * @argument name - name of the node. - * @returns the graph, allowing this to be chained with other functions. - */ - removeNode(name: string): this; - - /** - * Gets all nodes of the graph. Note, the in case of compound graph subnodes are - * not included in list. - * Complexity: O(1). - * - * @returns list of graph nodes. - */ - nodes(): string[]; - - /** - * Gets the label of node with specified name. - * Complexity: O(|V|). - * - * @returns label value of the node. - */ - node(name: string): NodeLabel; - - /** - * Creates or updates the label for the edge (v, w) with the optionally supplied - * name. If label is supplied it is set as the value for the edge. If label is not - * supplied and the edge was created by this call then the default edge label will - * be assigned. The name parameter is only useful with multigraphs. - * Complexity: O(1). - * - * @argument v - edge source node. - * @argument w - edge sink node. - * @argument label - value to associate with the edge. - * @argument name - unique name of the edge in order to identify it in multigraph. - * @returns the graph, allowing this to be chained with other functions. - */ - setEdge(v: string, w: string, label?: EdgeLabel, name?: string): this; - - /** - * Creates or updates the label for the specified edge. If label is supplied it is - * set as the value for the edge. If label is not supplied and the edge was created - * by this call then the default edge label will be assigned. The name parameter is - * only useful with multigraphs. - * Complexity: O(1). - * - * @argument edge - edge descriptor. - * @argument label - value to associate with the edge. - * @returns the graph, allowing this to be chained with other functions. - */ - setEdge(edge: Edge, label?: EdgeLabel): this; - - /** - * Gets edges of the graph. In case of compound graph subgraphs are not considered. - * Complexity: O(|E|). - * - * @return graph edges list. - */ - edges(): Edge[]; - - /** - * Gets the label for the specified edge. - * Complexity: O(1). - * - * @argument v - edge source node. - * @argument w - edge sink node. - * @argument name - name of the edge (actual for multigraph). - * @returns value associated with specified edge. - */ - edge(v: string, w: string, name?: string): EdgeLabel; - - /** - * Gets the label for the specified edge. - * Complexity: O(1). - * - * @argument edge - edge descriptor. - * @returns value associated with specified edge. - */ - edge(e: Edge): EdgeLabel; - - /** - * Gets the label for the specified edge and converts it to an object. - * Complexity: O(1). - * - * @argument v - edge source node. - * @argument w - edge sink node. - * @argument name - name of the edge (actual for multigraph). - * @returns value associated with specified edge. - */ - edgeAsObj(v: string, w: string, name?: string): Object; - - /** - * Gets the label for the specified edge and converts it to an object. - * Complexity: O(1). - * - * @argument edge - edge descriptor. - * @returns value associated with specified edge. - */ - edgeAsObj(e: Edge): Object; - - /** - * Detects whether the graph contains specified edge or not. No subgraphs are considered. - * Complexity: O(1). - * - * @argument v - edge source node. - * @argument w - edge sink node. - * @argument name - name of the edge (actual for multigraph). - * @returns whether the graph contains the specified edge or not. - */ - hasEdge(v: string, w: string, name?: string): boolean; - - /** - * Detects whether the graph contains specified edge or not. No subgraphs are considered. - * Complexity: O(1). - * - * @argument edge - edge descriptor. - * @returns whether the graph contains the specified edge or not. - */ - hasEdge(edge: Edge): boolean; - - /** - * Removes the specified edge from the graph. No subgraphs are considered. - * Complexity: O(1). - * - * @argument edge - edge descriptor. - * @returns the graph, allowing this to be chained with other functions. - */ - removeEdge(edge: Edge): this; - - /** - * Removes the specified edge from the graph. No subgraphs are considered. - * Complexity: O(1). - * - * @argument v - edge source node. - * @argument w - edge sink node. - * @argument name - name of the edge (actual for multigraph). - * @returns the graph, allowing this to be chained with other functions. - */ - removeEdge(v: string, w: string, name?: string): this; - - /** - * Return all edges that point to the node v. Optionally filters those edges down to just those - * coming from node u. Behavior is undefined for undirected graphs - use nodeEdges instead. - * Complexity: O(|E|). - * - * @argument v - edge sink node. - * @argument w - edge source node. - * @returns edges descriptors list if v is in the graph, or undefined otherwise. - */ - inEdges(v: string, w?: string): void | Edge[]; - - /** - * Return all edges that are pointed at by node v. Optionally filters those edges down to just - * those point to w. Behavior is undefined for undirected graphs - use nodeEdges instead. - * Complexity: O(|E|). - * - * @argument v - edge source node. - * @argument w - edge sink node. - * @returns edges descriptors list if v is in the graph, or undefined otherwise. - */ - outEdges(v: string, w?: string): void | Edge[]; - - /** - * Returns all edges to or from node v regardless of direction. Optionally filters those edges - * down to just those between nodes v and w regardless of direction. - * Complexity: O(|E|). - * - * @argument v - edge adjacent node. - * @argument w - edge adjacent node. - * @returns edges descriptors list if v is in the graph, or undefined otherwise. - */ - nodeEdges(v: string, w?: string): void | Edge[]; - - /** - * Return all nodes that are predecessors of the specified node or undefined if node v is not in - * the graph. Behavior is undefined for undirected graphs - use neighbors instead. - * Complexity: O(|V|). - * - * @argument v - node identifier. - * @returns node identifiers list or undefined if v is not in the graph. - */ - predecessors(v: string): void | string[]; - - /** - * Return all nodes that are successors of the specified node or undefined if node v is not in - * the graph. Behavior is undefined for undirected graphs - use neighbors instead. - * Complexity: O(|V|). - * - * @argument v - node identifier. - * @returns node identifiers list or undefined if v is not in the graph. - */ - successors(v: string): void | string[]; - - /** - * Return all nodes that are predecessors or successors of the specified node or undefined if - * node v is not in the graph. - * Complexity: O(|V|). - * - * @argument v - node identifier. - * @returns node identifiers list or undefined if v is not in the graph. - */ - - neighbors(v: string): void | string[]; - - /** - * Whether graph was created with 'directed' flag set to true or not. - * - * @returns whether the graph edges have an orientation. - */ - isDirected(): boolean; - - /** - * Whether graph was created with 'multigraph' flag set to true or not. - * - * @returns whether the pair of nodes of the graph can have multiple edges. - */ - isMultigraph(): boolean; - - /** - * Whether graph was created with 'compound' flag set to true or not. - * - * @returns whether a node of the graph can have subnodes. - */ - isCompound(): boolean; - - /** - * Sets the label of the graph. - * - * @argument label - label value. - * @returns the graph, allowing this to be chained with other functions. - */ - setGraph(label: GraphLabel): this; - - /** - * Gets the graph label. - * - * @returns currently assigned label for the graph or undefined if no label assigned. - */ - graph(): GraphLabel; - - /** - * Gets the number of nodes in the graph. - * Complexity: O(1). - * - * @returns nodes count. - */ - nodeCount(): number; - - /** - * Gets the number of edges in the graph. - * Complexity: O(1). - * - * @returns edges count. - */ - edgeCount(): number; - - /** - * Gets list of nodes without in-edges. - * Complexity: O(|V|). - * - * @returns the graph source nodes. - */ - sources(): string[]; - - /** - * Gets list of nodes without out-edges. - * Complexity: O(|V|). - * - * @returns the graph source nodes. - */ - sinks(): string[]; - } - - export namespace json { - /** - * Creates a JSON representation of the graph that can be serialized to a string with - * JSON.stringify. The graph can later be restored using json.read. - * - * @argument graph - target to create JSON representation of. - * @returns JSON serializable graph representation - */ - function write(graph: Graph): Object; - - /** - * Takes JSON as input and returns the graph representation. - * - * @example - * var g2 = graphlib.json.read(JSON.parse(str)); - * g2.nodes(); - * // ['a', 'b'] - * g2.edges() - * // [ { v: 'a', w: 'b' } ] - * - * @argument json - JSON serializable graph representation - * @returns graph constructed acccording to specified representation - */ - function read( - json: Object, - ): Graph; - } - - export interface Path { - distance: number; - predecessor: string; - } - - export namespace alg { - /** - * Finds all connected components in a graph and returns an array of these components. - * Each component is itself an array that contains the ids of nodes in the component. - * Complexity: O(|V|). - * - * @argument graph - graph to find components in. - * @returns array of nodes list representing components - */ - function components(graph: Graph): string[][]; - - /** - * This function is an implementation of Dijkstra's algorithm which finds the shortest - * path from source to all other nodes in graph. This function returns a map of - * v -> { distance, predecessor }. The distance property holds the sum of the weights - * from source to v along the shortest path or Number.POSITIVE_INFINITY if there is no path - * from source. The predecessor property can be used to walk the individual elements of the - * path from source to v in reverse order. - * Complexity: O((|E| + |V|) * log |V|). - * - * @argument graph - graph where to search pathes. - * @argument source - node to start pathes from. - * @argument weightFn - function which takes edge e and returns the weight of it. If no weightFn - * is supplied then each edge is assumed to have a weight of 1. This function throws an - * Error if any of the traversed edges have a negative edge weight. - * @argument edgeFn - function which takes a node v and returns the ids of all edges incident to it - * for the purposes of shortest path traversal. By default this function uses the graph.outEdges. - * @returns shortest pathes map that starts from node source - */ - function dijkstra( - graph: Graph, - source: string, - weightFn?: (e: Edge) => number, - edgeFn?: (v: string) => Edge[], - ): { [node: string]: Path }; - - /** - * This function finds the shortest path from each node to every other reachable node in - * the graph. It is similar to alg.dijkstra, but instead of returning a single-source - * array, it returns a mapping of source -> alg.dijksta(g, source, weightFn, edgeFn). - * Complexity: O(|V| * (|E| + |V|) * log |V|). - * - * @argument graph - graph where to search pathes. - * @argument weightFn - function which takes edge e and returns the weight of it. If no weightFn - * is supplied then each edge is assumed to have a weight of 1. This function throws an - * Error if any of the traversed edges have a negative edge weight. - * @argument edgeFn - function which takes a node v and returns the ids of all edges incident to it - * for the purposes of shortest path traversal. By default this function uses the graph.outEdges. - * @returns shortest pathes map. - */ - function dijkstraAll( - graph: Graph, - weightFn?: (e: Edge) => number, - edgeFn?: (v: string) => Edge[], - ): { [source: string]: { [node: string]: Path } }; +export interface GraphOptions { + directed?: boolean; // default: true. + multigraph?: boolean; // default: false. + compound?: boolean; // default: false. +} - /** - * Given a Graph, graph, this function returns all nodes that are part of a cycle. As there - * may be more than one cycle in a graph this function return an array of these cycles, - * where each cycle is itself represented by an array of ids for each node involved in - * that cycle. Method alg.isAcyclic is more efficient if you only need to determine whether a graph has a - * cycle or not. - * Complexity: O(|V| + |E|). - * - * @argument graph - graph where to search cycles. - * @returns cycles list. - */ - function findCycles(graph: Graph): string[][]; - - /** - * Given a Graph, graph, this function returns true if the graph has no cycles and returns false if it - * does. This algorithm returns as soon as it detects the first cycle. You can use alg.findCycles - * to get the actual list of cycles in the graph. - * - * @argument graph - graph to detect whether it acyclic ot not. - * @returns whether graph contain cycles or not. - */ - function isAcyclic(graph: Graph): boolean; - - /** - * This function is an implementation of the Floyd-Warshall algorithm, which finds the - * shortest path from each node to every other reachable node in the graph. It is similar - * to alg.dijkstraAll, but it handles negative edge weights and is more efficient for some types - * of graphs. This function returns a map of source -> { target -> { distance, predecessor }. - * The distance property holds the sum of the weights from source to target along the shortest - * path of Number.POSITIVE_INFINITY if there is no path from source. The predecessor property - * can be used to walk the individual elements of the path from source to target in reverse - * order. - * Complexity: O(|V|^3). - * - * @argument graph - graph where to search pathes. - * @argument weightFn - function which takes edge e and returns the weight of it. If no weightFn - * is supplied then each edge is assumed to have a weight of 1. This function throws an - * Error if any of the traversed edges have a negative edge weight. - * @argument edgeFn - function which takes a node v and returns the ids of all edges incident to it - * for the purposes of shortest path traversal. By default this function uses the graph.outEdges. - * @returns shortest pathes map. - */ - function floydWarshall( - graph: Graph, - weightFn?: (e: Edge) => number, - edgeFn?: (v: string) => Edge[], - ): { [source: string]: { [node: string]: Path } }; +export interface Edge { + v: string; + w: string; + /** The name that uniquely identifies a multi-edge. */ + name?: string; +} + +export class Graph { + constructor(options?: GraphOptions); + + /** + * Sets the default node label. This label will be assigned as default label + * in case if no label was specified while setting a node. + * Complexity: O(1). + * + * @argument labelOrFn - default node label or label factory function. + * @returns the graph, allowing this to be chained with other functions. + */ + setDefaultNodeLabel(labelOrFn: NodeLabel | ((v: string) => NodeLabel)): this; + + /** + * Creates or updates the value for the node v in the graph. If label is supplied + * it is set as the value for the node. If label is not supplied and the node was + * created by this call then the default node label will be assigned. + * Complexity: O(1). + * + * @argument name - node name. + * @argument label - value to set for node. + * @returns the graph, allowing this to be chained with other functions. + */ + setNode(name: string, label?: NodeLabel): this; + + /** + * Invokes setNode method for each node in names list. + * Complexity: O(|names|). + * + * @argument names - list of nodes names to be set. + * @argument label - value to set for each node in list. + * @returns the graph, allowing this to be chained with other functions. + */ + setNodes(names: string[], label?: NodeLabel): this; + + /** + * Sets node p as a parent for node v if it is defined, or removes the + * parent for v if p is undefined. Method throws an exception in case of + * invoking it in context of noncompound graph. + * Average-case complexity: O(1). + * + * @argument v - node to be child for p. + * @argument p - node to be parent for v. + * @returns the graph, allowing this to be chained with other functions. + */ + setParent(v: string, p?: string): this; + + /** + * Gets parent node for node v. + * Complexity: O(1). + * + * @argument v - node to get parent of. + * @returns parent node name or void if v has no parent. + */ + parent(v: string): string | void; + + /** + * Gets list of direct children of node v. + * Complexity: O(1). + * + * @argument v - node to get children of. + * @returns children nodes names list. + */ + children(v: string): string[]; + + /** + * Creates new graph with nodes filtered via filter. Edges incident to rejected node + * are also removed. In case of compound graph, if parent is rejected by filter, + * than all its children are rejected too. + * Average-case complexity: O(|E|+|V|). + * + * @argument filter - filtration function detecting whether the node should stay or not. + * @returns new graph made from current and nodes filtered. + */ + filterNodes(filter: (v: string) => boolean): this; + + /** + * Sets the default edge label. This label will be assigned as default label + * in case if no label was specified while setting an edge. + * Complexity: O(1). + * + * @argument labelOrFn - default edge label or label factory function. + * @returns the graph, allowing this to be chained with other functions. + */ + setDefaultEdgeLabel(labelOrFn: EdgeLabel | ((v: string, w: string, name?: string) => EdgeLabel)): this; + + /** + * Establish an edges path over the nodes in nodes list. If some edge is already + * exists, it will update its label, otherwise it will create an edge between pair + * of nodes with label provided or default label if no label provided. + * Complexity: O(|nodes|). + * + * @argument nodes - list of nodes to be connected in series. + * @argument label - value to set for each edge between pairs of nodes. + * @returns the graph, allowing this to be chained with other functions. + */ + setPath(nodes: string[], label?: EdgeLabel): this; + + /** + * Detects whether graph has a node with specified name or not. + * + * @argument name - name of the node. + * @returns true if graph has node with specified name, false - otherwise. + */ + hasNode(name: string): boolean; + + /** + * Remove the node with the name from the graph or do nothing if the node is not in + * the graph. If the node was removed this function also removes any incident + * edges. + * Complexity: O(1). + * + * @argument name - name of the node. + * @returns the graph, allowing this to be chained with other functions. + */ + removeNode(name: string): this; + + /** + * Gets all nodes of the graph. Note, the in case of compound graph subnodes are + * not included in list. + * Complexity: O(1). + * + * @returns list of graph nodes. + */ + nodes(): string[]; + + /** + * Gets the label of node with specified name. + * Complexity: O(|V|). + * + * @returns label value of the node. + */ + node(name: string): NodeLabel; + + /** + * Creates or updates the label for the edge (v, w) with the optionally supplied + * name. If label is supplied it is set as the value for the edge. If label is not + * supplied and the edge was created by this call then the default edge label will + * be assigned. The name parameter is only useful with multigraphs. + * Complexity: O(1). + * + * @argument v - edge source node. + * @argument w - edge sink node. + * @argument label - value to associate with the edge. + * @argument name - unique name of the edge in order to identify it in multigraph. + * @returns the graph, allowing this to be chained with other functions. + */ + setEdge(v: string, w: string, label?: EdgeLabel, name?: string): this; + + /** + * Creates or updates the label for the specified edge. If label is supplied it is + * set as the value for the edge. If label is not supplied and the edge was created + * by this call then the default edge label will be assigned. The name parameter is + * only useful with multigraphs. + * Complexity: O(1). + * + * @argument edge - edge descriptor. + * @argument label - value to associate with the edge. + * @returns the graph, allowing this to be chained with other functions. + */ + setEdge(edge: Edge, label?: EdgeLabel): this; + + /** + * Gets edges of the graph. In case of compound graph subgraphs are not considered. + * Complexity: O(|E|). + * + * @return graph edges list. + */ + edges(): Edge[]; + + /** + * Gets the label for the specified edge. + * Complexity: O(1). + * + * @argument v - edge source node. + * @argument w - edge sink node. + * @argument name - name of the edge (actual for multigraph). + * @returns value associated with specified edge. + */ + edge(v: string, w: string, name?: string): EdgeLabel; + + /** + * Gets the label for the specified edge. + * Complexity: O(1). + * + * @argument edge - edge descriptor. + * @returns value associated with specified edge. + */ + edge(e: Edge): EdgeLabel; + + /** + * Gets the label for the specified edge and converts it to an object. + * Complexity: O(1). + * + * @argument v - edge source node. + * @argument w - edge sink node. + * @argument name - name of the edge (actual for multigraph). + * @returns value associated with specified edge. + */ + edgeAsObj(v: string, w: string, name?: string): Object; + + /** + * Gets the label for the specified edge and converts it to an object. + * Complexity: O(1). + * + * @argument edge - edge descriptor. + * @returns value associated with specified edge. + */ + edgeAsObj(e: Edge): Object; + + /** + * Detects whether the graph contains specified edge or not. No subgraphs are considered. + * Complexity: O(1). + * + * @argument v - edge source node. + * @argument w - edge sink node. + * @argument name - name of the edge (actual for multigraph). + * @returns whether the graph contains the specified edge or not. + */ + hasEdge(v: string, w: string, name?: string): boolean; + + /** + * Detects whether the graph contains specified edge or not. No subgraphs are considered. + * Complexity: O(1). + * + * @argument edge - edge descriptor. + * @returns whether the graph contains the specified edge or not. + */ + hasEdge(edge: Edge): boolean; + + /** + * Removes the specified edge from the graph. No subgraphs are considered. + * Complexity: O(1). + * + * @argument edge - edge descriptor. + * @returns the graph, allowing this to be chained with other functions. + */ + removeEdge(edge: Edge): this; + + /** + * Removes the specified edge from the graph. No subgraphs are considered. + * Complexity: O(1). + * + * @argument v - edge source node. + * @argument w - edge sink node. + * @argument name - name of the edge (actual for multigraph). + * @returns the graph, allowing this to be chained with other functions. + */ + removeEdge(v: string, w: string, name?: string): this; + + /** + * Return all edges that point to the node v. Optionally filters those edges down to just those + * coming from node u. Behavior is undefined for undirected graphs - use nodeEdges instead. + * Complexity: O(|E|). + * + * @argument v - edge sink node. + * @argument w - edge source node. + * @returns edges descriptors list if v is in the graph, or undefined otherwise. + */ + inEdges(v: string, w?: string): void | Edge[]; + + /** + * Return all edges that are pointed at by node v. Optionally filters those edges down to just + * those point to w. Behavior is undefined for undirected graphs - use nodeEdges instead. + * Complexity: O(|E|). + * + * @argument v - edge source node. + * @argument w - edge sink node. + * @returns edges descriptors list if v is in the graph, or undefined otherwise. + */ + outEdges(v: string, w?: string): void | Edge[]; + +/** + * Returns all edges to or from node v regardless of direction. Optionally filters those edges + * down to just those between nodes v and w regardless of direction. + * Complexity: O(|E|). + * + * @argument v - edge adjacent node. + * @argument w - edge adjacent node. + * @returns edges descriptors list if v is in the graph, or undefined otherwise. + */ + nodeEdges(v: string, w?: string): void | Edge[]; + + /** + * Return all nodes that are predecessors of the specified node or undefined if node v is not in + * the graph. Behavior is undefined for undirected graphs - use neighbors instead. + * Complexity: O(|V|). + * + * @argument v - node identifier. + * @returns node identifiers list or undefined if v is not in the graph. + */ + predecessors(v: string): void | string[]; + + /** + * Return all nodes that are successors of the specified node or undefined if node v is not in + * the graph. Behavior is undefined for undirected graphs - use neighbors instead. + * Complexity: O(|V|). + * + * @argument v - node identifier. + * @returns node identifiers list or undefined if v is not in the graph. + */ + successors(v: string): void | string[]; + + /** + * Return all nodes that are predecessors or successors of the specified node or undefined if + * node v is not in the graph. + * Complexity: O(|V|). + * + * @argument v - node identifier. + * @returns node identifiers list or undefined if v is not in the graph. + */ + + neighbors(v: string): void | string[]; + + /** + * Whether graph was created with 'directed' flag set to true or not. + * + * @returns whether the graph edges have an orientation. + */ + isDirected(): boolean; + + /** + * Whether graph was created with 'multigraph' flag set to true or not. + * + * @returns whether the pair of nodes of the graph can have multiple edges. + */ + isMultigraph(): boolean; + + /** + * Whether graph was created with 'compound' flag set to true or not. + * + * @returns whether a node of the graph can have subnodes. + */ + isCompound(): boolean; + + /** + * Sets the label of the graph. + * + * @argument label - label value. + * @returns the graph, allowing this to be chained with other functions. + */ + setGraph(label: GraphLabel): this; + + /** + * Gets the graph label. + * + * @returns currently assigned label for the graph or undefined if no label assigned. + */ + graph(): GraphLabel; + + /** + * Gets the number of nodes in the graph. + * Complexity: O(1). + * + * @returns nodes count. + */ + nodeCount(): number; + + /** + * Gets the number of edges in the graph. + * Complexity: O(1). + * + * @returns edges count. + */ + edgeCount(): number; + + /** + * Gets list of nodes without in-edges. + * Complexity: O(|V|). + * + * @returns the graph source nodes. + */ + sources(): string[]; + + /** + * Gets list of nodes without out-edges. + * Complexity: O(|V|). + * + * @returns the graph source nodes. + */ + sinks(): string[]; +} - /** - * Prim's algorithm takes a connected undirected graph and generates a minimum spanning tree. This - * function returns the minimum spanning tree as an undirected graph. This algorithm is derived - * from the description in "Introduction to Algorithms", Third Edition, Cormen, et al., Pg 634. - * Complexity: O(|E| * log |V|); - * - * @argument graph - graph to generate a minimum spanning tree of. - * @argument weightFn - function which takes edge e and returns the weight of it. It throws an Error if - * the graph is not connected. - * @returns minimum spanning tree of graph. - */ - function prim(graph: Graph, weightFn: (e: Edge) => number): Graph; - - /** - * This function is an implementation of Tarjan's algorithm which finds all strongly connected - * components in the directed graph g. Each strongly connected component is composed of nodes that - * can reach all other nodes in the component via directed edges. A strongly connected component - * can consist of a single node if that node cannot both reach and be reached by any other - * specific node in the graph. Components of more than one node are guaranteed to have at least - * one cycle. - * Complexity: O(|V| + |E|). - * - * @argument graph - graph to find all strongly connected components of. - * @return an array of components. Each component is itself an array that contains - * the ids of all nodes in the component. - */ - function tarjan(graph: Graph): string[][]; - - /** - * Given a Graph graph this function applies topological sorting to it. - * If the graph has a cycle it is impossible to generate such a list and CycleException is thrown. - * Complexity: O(|V| + |E|). - * - * @argument graph - graph to apply topological sorting to. - * @returns an array of nodes such that for each edge u -> v, u appears before v in the array. - */ - function topsort(graph: Graph): string[]; - - /** - * Performs pre-order depth first traversal on the input graph. If the graph is - * undirected then this algorithm will navigate using neighbors. If the graph - * is directed then this algorithm will navigate using successors. - * - * @argument graph - depth first traversal target. - * @argument vs - nodes list to traverse. - * @returns the nodes in the order they were visited as a list of their names. - */ - function preorder(graph: Graph, vs: string[]): string[]; - - /** - * Performs post-order depth first traversal on the input graph. If the graph is - * undirected then this algorithm will navigate using neighbors. If the graph - * is directed then this algorithm will navigate using successors. - * - * @argument graph - depth first traversal target. - * @argument vs - nodes list to traverse. - * @returns the nodes in the order they were visited as a list of their names. - */ - function postorder(graph: Graph, vs: string[]): string[]; - } +export namespace json { + /** + * Creates a JSON representation of the graph that can be serialized to a string with + * JSON.stringify. The graph can later be restored using json.read. + * + * @argument graph - target to create JSON representation of. + * @returns JSON serializable graph representation + */ + function write(graph: Graph): Object; + + /** + * Takes JSON as input and returns the graph representation. + * + * @example + * var g2 = graphlib.json.read(JSON.parse(str)); + * g2.nodes(); + * // ['a', 'b'] + * g2.edges() + * // [ { v: 'a', w: 'b' } ] + * + * @argument json - JSON serializable graph representation + * @returns graph constructed acccording to specified representation + */ + function read( + json: Object, + ): Graph; } + +export interface Path { + distance: number; + predecessor: string; +} + +export namespace alg { + /** + * Finds all connected components in a graph and returns an array of these components. + * Each component is itself an array that contains the ids of nodes in the component. + * Complexity: O(|V|). + * + * @argument graph - graph to find components in. + * @returns array of nodes list representing components + */ + function components(graph: Graph): string[][]; + + /** + * This function is an implementation of Dijkstra's algorithm which finds the shortest + * path from source to all other nodes in graph. This function returns a map of + * v -> { distance, predecessor }. The distance property holds the sum of the weights + * from source to v along the shortest path or Number.POSITIVE_INFINITY if there is no path + * from source. The predecessor property can be used to walk the individual elements of the + * path from source to v in reverse order. + * Complexity: O((|E| + |V|) * log |V|). + * + * @argument graph - graph where to search pathes. + * @argument source - node to start pathes from. + * @argument weightFn - function which takes edge e and returns the weight of it. If no weightFn + * is supplied then each edge is assumed to have a weight of 1. This function throws an + * Error if any of the traversed edges have a negative edge weight. + * @argument edgeFn - function which takes a node v and returns the ids of all edges incident to it + * for the purposes of shortest path traversal. By default this function uses the graph.outEdges. + * @returns shortest pathes map that starts from node source + */ + function dijkstra( + graph: Graph, + source: string, + weightFn?: (e: Edge) => number, + edgeFn?: (v: string) => Edge[], + ): { [node: string]: Path }; + + /** + * This function finds the shortest path from each node to every other reachable node in + * the graph. It is similar to alg.dijkstra, but instead of returning a single-source + * array, it returns a mapping of source -> alg.dijksta(g, source, weightFn, edgeFn). + * Complexity: O(|V| * (|E| + |V|) * log |V|). + * + * @argument graph - graph where to search pathes. + * @argument weightFn - function which takes edge e and returns the weight of it. If no weightFn + * is supplied then each edge is assumed to have a weight of 1. This function throws an + * Error if any of the traversed edges have a negative edge weight. + * @argument edgeFn - function which takes a node v and returns the ids of all edges incident to it + * for the purposes of shortest path traversal. By default this function uses the graph.outEdges. + * @returns shortest pathes map. + */ + function dijkstraAll( + graph: Graph, + weightFn?: (e: Edge) => number, + edgeFn?: (v: string) => Edge[], + ): { : { [node: string]: Path } }; + + /** + * Given a Graph, graph, this function returns all nodes that are part of a cycle. As there + * may be more than one cycle in a graph this function return an array of these cycles, + * where each cycle is itself represented by an array of ids for each node involved in + * that cycle. Method alg.isAcyclic is more efficient if you only need to determine whether a graph has a + * cycle or not. + * Complexity: O(|V| + |E|). + * + * @argument graph - graph where to search cycles. + * @returns cycles list. + */ + function findCycles(graph: Graph): string[][]; + + /** + * Given a Graph, graph, this function returns true if the graph has no cycles and returns false if it + * does. This algorithm returns as soon as it detects the first cycle. You can use alg.findCycles + * to get the actual list of cycles in the graph. + * + * @argument graph - graph to detect whether it acyclic ot not. + * @returns whether graph contain cycles or not. + */ + function isAcyclic(graph: Graph): boolean; + + /** + * This function is an implementation of the Floyd-Warshall algorithm, which finds the + * shortest path from each node to every other reachable node in the graph. It is similar + * to alg.dijkstraAll, but it handles negative edge weights and is more efficient for some types + * of graphs. This function returns a map of source -> { target -> { distance, predecessor }. + * The distance property holds the sum of the weights from source to target along the shortest + * path of Number.POSITIVE_INFINITY if there is no path from source. The predecessor property + * can be used to walk the individual elements of the path from source to target in reverse + * order. + * Complexity: O(|V|^3). + * + * @argument graph - graph where to search pathes. + * @argument weightFn - function which takes edge e and returns the weight of it. If no weightFn + * is supplied then each edge is assumed to have a weight of 1. This function throws an + * Error if any of the traversed edges have a negative edge weight. + * @argument edgeFn - function which takes a node v and returns the ids of all edges incident to it + * for the purposes of shortest path traversal. By default this function uses the graph.outEdges. + * @returns shortest pathes map. + */ + function floydWarshall( + graph: Graph, + weightFn?: (e: Edge) => number, + edgeFn?: (v: string) => Edge[], + ): { [source: string]: { [node: string]: Path } }; + + /** + * Prim's algorithm takes a connected undirected graph and generates a minimum spanning tree. This + * function returns the minimum spanning tree as an undirected graph. This algorithm is derived + * from the description in "Introduction to Algorithms", Third Edition, Cormen, et al., Pg 634. + * Complexity: O(|E| * log |V|); + * + * @argument graph - graph to generate a minimum spanning tree of. + * @argument weightFn - function which takes edge e and returns the weight of it. It throws an Error if + * the graph is not connected. + * @returns minimum spanning tree of graph. + */ + function prim(graph: Graph, weightFn: (e: Edge) => number): Graph; + + /** + * This function is an implementation of Tarjan's algorithm which finds all strongly connected + * components in the directed graph g. Each strongly connected component is composed of nodes that + * can reach all other nodes in the component via directed edges. A strongly connected component + * can consist of a single node if that node cannot both reach and be reached by any other + * specific node in the graph. Components of more than one node are guaranteed to have at least + * one cycle. + * Complexity: O(|V| + |E|). + * + * @argument graph - graph to find all strongly connected components of. + * @return an array of components. Each component is itself an array that contains + * the ids of all nodes in the component. + */ + function tarjan(graph: Graph): string[][]; + + /** + * Given a Graph graph this function applies topological sorting to it. + * If the graph has a cycle it is impossible to generate such a list and CycleException is thrown. + * Complexity: O(|V| + |E|). + * + * @argument graph - graph to apply topological sorting to. + * @returns an array of nodes such that for each edge u -> v, u appears before v in the array. + */ + function topsort(graph: Graph): string[]; + + /** + * Performs pre-order depth first traversal on the input graph. If the graph is + * undirected then this algorithm will navigate using neighbors. If the graph + * is directed then this algorithm will navigate using successors. + * + * @argument graph - depth first traversal target. + * @argument vs - nodes list to traverse. + * @returns the nodes in the order they were visited as a list of their names. + */ + function preorder(graph: Graph, vs: string[]): string[]; + + /** + * Performs post-order depth first traversal on the input graph. If the graph is + * undirected then this algorithm will navigate using neighbors. If the graph + * is directed then this algorithm will navigate using successors. + * + * @argument graph - depth first traversal target. + * @argument vs - nodes list to traverse. + * @returns the nodes in the order they were visited as a list of their names. + */ + function postorder(graph: Graph, vs: string[]): string[]; +} \ No newline at end of file diff --git a/jest.config.js b/jest.config.js new file mode 100644 index 00000000..abaab747 --- /dev/null +++ b/jest.config.js @@ -0,0 +1,25 @@ +module.exports = { + // Use jsdom for any browser-like behavior (optional, may not be needed) + // testEnvironment: 'jsdom', + + // Look for test files ending in .test.js or .spec.js inside the test directory + testMatch: [ + "**/test/**/*.js" + ], + + // Collect coverage from files in the lib/ directory + collectCoverageFrom: [ + "lib/**/*.js" + ], + + // Ignore specific files/directories from coverage + coveragePathIgnorePatterns: [ + "/node_modules/", + "/test/" + ], + + testPathIgnorePatterns: ["/test/alg/utils/"], + + // Setup to handle module resolution if needed (for cjs tests) + moduleFileExtensions: ['js', 'json', 'node'], +}; \ No newline at end of file diff --git a/karma.conf.js b/karma.conf.js deleted file mode 100644 index fc038e37..00000000 --- a/karma.conf.js +++ /dev/null @@ -1,68 +0,0 @@ -// Karma configuration -// Generated on Sat Oct 18 2014 17:38:05 GMT-0700 (PDT) - -module.exports = function(config) { - config.set({ - - // base path that will be used to resolve all patterns (eg. files, exclude) - basePath: '', - - - // frameworks to use - // available frameworks: https://npmjs.org/browse/keyword/karma-adapter - frameworks: ['mocha'], - - - // list of files / patterns to load in the browser - files: [ - 'build/graphlib.js', - - 'node_modules/chai/chai.js', - 'test/bundle-test.js' - ], - - - // list of files to exclude - exclude: [ - ], - - - // preprocess matching files before serving them to the browser - // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor - preprocessors: { - }, - - - // test results reporter to use - // possible values: 'dots', 'progress' - // available reporters: https://npmjs.org/browse/keyword/karma-reporter - reporters: ['progress'], - - - // web server port - port: 9876, - - - // enable / disable colors in the output (reporters and logs) - colors: true, - - - // level of logging - // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG - logLevel: config.LOG_INFO, - - - // enable / disable watching file and executing tests whenever any file changes - autoWatch: true, - - - // start these browsers - // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher - browsers: ['Chrome'], - - - // Continuous Integration mode - // if true, Karma captures browsers, runs the tests and exits - singleRun: false - }); -}; diff --git a/karma.core.conf.js b/karma.core.conf.js deleted file mode 100644 index 745c954a..00000000 --- a/karma.core.conf.js +++ /dev/null @@ -1,68 +0,0 @@ -// Karma configuration -// Generated on Sat Oct 18 2014 17:38:05 GMT-0700 (PDT) - -module.exports = function(config) { - config.set({ - - // base path that will be used to resolve all patterns (eg. files, exclude) - basePath: '', - - - // frameworks to use - // available frameworks: https://npmjs.org/browse/keyword/karma-adapter - frameworks: ['mocha'], - - - // list of files / patterns to load in the browser - files: [ - 'build/graphlib.core.js', - - 'node_modules/chai/chai.js', - 'test/bundle-test.js' - ], - - - // list of files to exclude - exclude: [ - ], - - - // preprocess matching files before serving them to the browser - // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor - preprocessors: { - }, - - - // test results reporter to use - // possible values: 'dots', 'progress' - // available reporters: https://npmjs.org/browse/keyword/karma-reporter - reporters: ['progress'], - - - // web server port - port: 9876, - - - // enable / disable colors in the output (reporters and logs) - colors: true, - - - // level of logging - // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG - logLevel: config.LOG_INFO, - - - // enable / disable watching file and executing tests whenever any file changes - autoWatch: true, - - - // start these browsers - // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher - browsers: ['Chrome'], - - - // Continuous Integration mode - // if true, Karma captures browsers, runs the tests and exits - singleRun: false - }); -}; diff --git a/package-lock.json b/package-lock.json index 47104843..cd4af9e7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,56 +9,37 @@ "version": "2.2.5-pre", "license": "MIT", "devDependencies": { + "@types/jest": "^29.5.12", + "@types/node": "^20.14.9", "benchmark": "2.1.4", - "browserify": "16.5.1", - "chai": "^4.3.6", + "esbuild": "^0.27.0", "eslint": "8.35.0", - "jshint": "2.13.5", - "jshint-stylish": "2.2.1", - "karma": "6.4.1", - "karma-chrome-launcher": "3.1.0", - "karma-mocha": "2.0.1", - "karma-requirejs": "1.1.0", - "karma-safari-launcher": "1.0.0", - "mocha": "10.8.2", - "nyc": "^15.1.0", + "jest": "^30.2.0", "requirejs": "2.3.7", - "seedrandom": "3.0.5", "semver": "7.5.4", "sprintf": "0.1.5", "uglify-js": "3.17.4" - }, - "engines": { - "node": ">17.0.0" - } - }, - "node_modules/@ampproject/remapping": { - "version": "2.2.0", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@jridgewell/gen-mapping": "^0.1.0", - "@jridgewell/trace-mapping": "^0.3.9" - }, - "engines": { - "node": ">=6.0.0" } }, "node_modules/@babel/code-frame": { - "version": "7.22.13", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.22.13.tgz", - "integrity": "sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w==", + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.27.1.tgz", + "integrity": "sha512-cjQ7ZlQ0Mv3b47hABuTevyTuYN4i+loJKGeV9flcCgIK37cCXRh+L1bd3iBHlynerhQ7BhCkn2BPbQUL+rGqFg==", "dev": true, + "license": "MIT", "dependencies": { - "@babel/highlight": "^7.22.13", - "chalk": "^2.4.2" + "@babel/helper-validator-identifier": "^7.27.1", + "js-tokens": "^4.0.0", + "picocolors": "^1.1.1" }, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/compat-data": { - "version": "7.21.0", + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.28.5.tgz", + "integrity": "sha512-6uFXyCayocRbqhZOB+6XcuZbkMNimwfVGFji8CTZnCzOHVGvDqzvitu1re2AU5LROliz7eQPhB8CpAMvnx9EjA==", "dev": true, "license": "MIT", "engines": { @@ -66,25 +47,27 @@ } }, "node_modules/@babel/core": { - "version": "7.21.0", - "dev": true, - "license": "MIT", - "dependencies": { - "@ampproject/remapping": "^2.2.0", - "@babel/code-frame": "^7.18.6", - "@babel/generator": "^7.21.0", - "@babel/helper-compilation-targets": "^7.20.7", - "@babel/helper-module-transforms": "^7.21.0", - "@babel/helpers": "^7.21.0", - "@babel/parser": "^7.21.0", - "@babel/template": "^7.20.7", - "@babel/traverse": "^7.21.0", - "@babel/types": "^7.21.0", - "convert-source-map": "^1.7.0", + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.28.5.tgz", + "integrity": "sha512-e7jT4DxYvIDLk1ZHmU/m/mB19rex9sv0c2ftBtjSBv+kVM/902eh0fINUzD7UwLLNR+jU585GxUJ8/EBfAM5fw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.27.1", + "@babel/generator": "^7.28.5", + "@babel/helper-compilation-targets": "^7.27.2", + "@babel/helper-module-transforms": "^7.28.3", + "@babel/helpers": "^7.28.4", + "@babel/parser": "^7.28.5", + "@babel/template": "^7.27.2", + "@babel/traverse": "^7.28.5", + "@babel/types": "^7.28.5", + "@jridgewell/remapping": "^2.3.5", + "convert-source-map": "^2.0.0", "debug": "^4.1.0", "gensync": "^1.0.0-beta.2", - "json5": "^2.2.2", - "semver": "^6.3.0" + "json5": "^2.2.3", + "semver": "^6.3.1" }, "engines": { "node": ">=6.9.0" @@ -95,12 +78,16 @@ } }, "node_modules/@babel/core/node_modules/convert-source-map": { - "version": "1.9.0", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", "dev": true, "license": "MIT" }, "node_modules/@babel/core/node_modules/semver": { - "version": "6.3.0", + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", + "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", "dev": true, "license": "ISC", "bin": { @@ -108,165 +95,125 @@ } }, "node_modules/@babel/generator": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.23.0.tgz", - "integrity": "sha512-lN85QRR+5IbYrMWM6Y4pE/noaQtg4pNiqeNGX60eqOfo6gtEj6uw/JagelB8vVztSd7R6M5n1+PQkDbHbBRU4g==", - "dev": true, - "dependencies": { - "@babel/types": "^7.23.0", - "@jridgewell/gen-mapping": "^0.3.2", - "@jridgewell/trace-mapping": "^0.3.17", - "jsesc": "^2.5.1" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@babel/generator/node_modules/@jridgewell/gen-mapping": { - "version": "0.3.2", + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.28.5.tgz", + "integrity": "sha512-3EwLFhZ38J4VyIP6WNtt2kUdW9dokXA9Cr4IVIFHuCpZ3H8/YFOl5JjZHisrn1fATPBmKKqXzDFvh9fUwHz6CQ==", "dev": true, "license": "MIT", "dependencies": { - "@jridgewell/set-array": "^1.0.1", - "@jridgewell/sourcemap-codec": "^1.4.10", - "@jridgewell/trace-mapping": "^0.3.9" + "@babel/parser": "^7.28.5", + "@babel/types": "^7.28.5", + "@jridgewell/gen-mapping": "^0.3.12", + "@jridgewell/trace-mapping": "^0.3.28", + "jsesc": "^3.0.2" }, "engines": { - "node": ">=6.0.0" + "node": ">=6.9.0" } }, "node_modules/@babel/helper-compilation-targets": { - "version": "7.20.7", + "version": "7.27.2", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.27.2.tgz", + "integrity": "sha512-2+1thGUUWWjLTYTHZWK1n8Yga0ijBz1XAhUXcKy81rd5g6yh7hGqMp45v7cadSbEHc9G3OTv45SyneRN3ps4DQ==", "dev": true, "license": "MIT", "dependencies": { - "@babel/compat-data": "^7.20.5", - "@babel/helper-validator-option": "^7.18.6", - "browserslist": "^4.21.3", + "@babel/compat-data": "^7.27.2", + "@babel/helper-validator-option": "^7.27.1", + "browserslist": "^4.24.0", "lru-cache": "^5.1.1", - "semver": "^6.3.0" + "semver": "^6.3.1" }, "engines": { "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0" } }, "node_modules/@babel/helper-compilation-targets/node_modules/semver": { - "version": "6.3.0", + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", + "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", "dev": true, "license": "ISC", "bin": { "semver": "bin/semver.js" } }, - "node_modules/@babel/helper-environment-visitor": { - "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.22.20.tgz", - "integrity": "sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA==", - "dev": true, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@babel/helper-function-name": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.23.0.tgz", - "integrity": "sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==", - "dev": true, - "dependencies": { - "@babel/template": "^7.22.15", - "@babel/types": "^7.23.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@babel/helper-hoist-variables": { - "version": "7.22.5", - "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.22.5.tgz", - "integrity": "sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==", + "node_modules/@babel/helper-globals": { + "version": "7.28.0", + "resolved": "https://registry.npmjs.org/@babel/helper-globals/-/helper-globals-7.28.0.tgz", + "integrity": "sha512-+W6cISkXFa1jXsDEdYA8HeevQT/FULhxzR99pxphltZcVaugps53THCeiWA8SguxxpSp3gKPiuYfSWopkLQ4hw==", "dev": true, - "dependencies": { - "@babel/types": "^7.22.5" - }, + "license": "MIT", "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helper-module-imports": { - "version": "7.18.6", + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.27.1.tgz", + "integrity": "sha512-0gSFWUPNXNopqtIPQvlD5WgXYI5GY2kP2cCvoT8kczjbfcfuIljTbcWrulD1CIPIX2gt1wghbDy08yE1p+/r3w==", "dev": true, "license": "MIT", "dependencies": { - "@babel/types": "^7.18.6" + "@babel/traverse": "^7.27.1", + "@babel/types": "^7.27.1" }, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helper-module-transforms": { - "version": "7.21.2", + "version": "7.28.3", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.28.3.tgz", + "integrity": "sha512-gytXUbs8k2sXS9PnQptz5o0QnpLL51SwASIORY6XaBKF88nsOT0Zw9szLqlSGQDP/4TljBAD5y98p2U1fqkdsw==", "dev": true, "license": "MIT", "dependencies": { - "@babel/helper-environment-visitor": "^7.18.9", - "@babel/helper-module-imports": "^7.18.6", - "@babel/helper-simple-access": "^7.20.2", - "@babel/helper-split-export-declaration": "^7.18.6", - "@babel/helper-validator-identifier": "^7.19.1", - "@babel/template": "^7.20.7", - "@babel/traverse": "^7.21.2", - "@babel/types": "^7.21.2" + "@babel/helper-module-imports": "^7.27.1", + "@babel/helper-validator-identifier": "^7.27.1", + "@babel/traverse": "^7.28.3" }, "engines": { "node": ">=6.9.0" - } - }, - "node_modules/@babel/helper-simple-access": { - "version": "7.20.2", - "dev": true, - "license": "MIT", - "dependencies": { - "@babel/types": "^7.20.2" }, - "engines": { - "node": ">=6.9.0" + "peerDependencies": { + "@babel/core": "^7.0.0" } }, - "node_modules/@babel/helper-split-export-declaration": { - "version": "7.22.6", - "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.22.6.tgz", - "integrity": "sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==", + "node_modules/@babel/helper-plugin-utils": { + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.27.1.tgz", + "integrity": "sha512-1gn1Up5YXka3YYAHGKpbideQ5Yjf1tDa9qYcgysz+cNCXukyLl6DjPXhD3VRwSb8c0J9tA4b2+rHEZtc6R0tlw==", "dev": true, - "dependencies": { - "@babel/types": "^7.22.5" - }, + "license": "MIT", "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helper-string-parser": { - "version": "7.22.5", - "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.22.5.tgz", - "integrity": "sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw==", + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.27.1.tgz", + "integrity": "sha512-qMlSxKbpRlAridDExk92nSobyDdpPijUq2DW6oDnUqd0iOGxmQjyqhMIihI9+zv4LPyZdRje2cavWPbCbWm3eA==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helper-validator-identifier": { - "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.20.tgz", - "integrity": "sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==", + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.28.5.tgz", + "integrity": "sha512-qSs4ifwzKJSV39ucNjsvc6WVHs6b7S03sOh2OcHF9UHfVPqWWALUsNUVzhSBiItjRZoLHx7nIarVjqKVusUZ1Q==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helper-validator-option": { - "version": "7.21.0", + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.27.1.tgz", + "integrity": "sha512-YvjJow9FxbhFFKDSuFnVCe2WxXk1zWc22fFePVNEaWJEu8IrZVlda6N0uHwzZrUM1il7NC9Mlp4MaJYbYd9JSg==", "dev": true, "license": "MIT", "engines": { @@ -274,37 +221,28 @@ } }, "node_modules/@babel/helpers": { - "version": "7.21.0", + "version": "7.28.4", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.28.4.tgz", + "integrity": "sha512-HFN59MmQXGHVyYadKLVumYsA9dBFun/ldYxipEjzA4196jpLZd8UjEEBLkbEkvfYreDqJhZxYAWFPtrfhNpj4w==", "dev": true, "license": "MIT", "dependencies": { - "@babel/template": "^7.20.7", - "@babel/traverse": "^7.21.0", - "@babel/types": "^7.21.0" + "@babel/template": "^7.27.2", + "@babel/types": "^7.28.4" }, "engines": { "node": ">=6.9.0" } }, - "node_modules/@babel/highlight": { - "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.22.20.tgz", - "integrity": "sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg==", + "node_modules/@babel/parser": { + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.28.5.tgz", + "integrity": "sha512-KKBU1VGYR7ORr3At5HAtUQ+TV3SzRCXmA/8OdDZiLDBIZxVyzXuztPjfLd3BV1PRAQGCMWWSHYhL0F8d5uHBDQ==", "dev": true, + "license": "MIT", "dependencies": { - "@babel/helper-validator-identifier": "^7.22.20", - "chalk": "^2.4.2", - "js-tokens": "^4.0.0" + "@babel/types": "^7.28.5" }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@babel/parser": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.23.0.tgz", - "integrity": "sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw==", - "dev": true, "bin": { "parser": "bin/babel-parser.js" }, @@ -312,2826 +250,3800 @@ "node": ">=6.0.0" } }, - "node_modules/@babel/template": { - "version": "7.22.15", - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.22.15.tgz", - "integrity": "sha512-QPErUVm4uyJa60rkI73qneDacvdvzxshT3kksGqlGWYdOTIUOwJ7RDUL8sGqslY1uXWSL6xMFKEXDS3ox2uF0w==", + "node_modules/@babel/plugin-syntax-async-generators": { + "version": "7.8.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz", + "integrity": "sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==", "dev": true, + "license": "MIT", "dependencies": { - "@babel/code-frame": "^7.22.13", - "@babel/parser": "^7.22.15", - "@babel/types": "^7.22.15" + "@babel/helper-plugin-utils": "^7.8.0" }, - "engines": { - "node": ">=6.9.0" + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@babel/traverse": { - "version": "7.23.2", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.23.2.tgz", - "integrity": "sha512-azpe59SQ48qG6nu2CzcMLbxUudtN+dOM9kDbUqGq3HXUJRlo7i8fvPoxQUzYgLZ4cMVmuZgm8vvBpNeRhd6XSw==", - "dev": true, - "dependencies": { - "@babel/code-frame": "^7.22.13", - "@babel/generator": "^7.23.0", - "@babel/helper-environment-visitor": "^7.22.20", - "@babel/helper-function-name": "^7.23.0", - "@babel/helper-hoist-variables": "^7.22.5", - "@babel/helper-split-export-declaration": "^7.22.6", - "@babel/parser": "^7.23.0", - "@babel/types": "^7.23.0", - "debug": "^4.1.0", - "globals": "^11.1.0" + "node_modules/@babel/plugin-syntax-bigint": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-bigint/-/plugin-syntax-bigint-7.8.3.tgz", + "integrity": "sha512-wnTnFlG+YxQm3vDxpGE57Pj0srRU4sHE/mDkt1qv2YJJSeUAec2ma4WLUnUPeKjyrfntVwe/N6dCXpU+zL3Npg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" }, - "engines": { - "node": ">=6.9.0" + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@babel/traverse/node_modules/globals": { - "version": "11.12.0", + "node_modules/@babel/plugin-syntax-class-properties": { + "version": "7.12.13", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz", + "integrity": "sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==", "dev": true, "license": "MIT", - "engines": { - "node": ">=4" + "dependencies": { + "@babel/helper-plugin-utils": "^7.12.13" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@babel/types": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.23.0.tgz", - "integrity": "sha512-0oIyUfKoI3mSqMvsxBdclDwxXKXAUA8v/apZbc+iSyARYou1o8ZGDxbUYyLFoW2arqS2jDGqJuZvv1d/io1axg==", + "node_modules/@babel/plugin-syntax-class-static-block": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-static-block/-/plugin-syntax-class-static-block-7.14.5.tgz", + "integrity": "sha512-b+YyPmr6ldyNnM6sqYeMWE+bgJcJpO6yS4QD7ymxgH34GBPNDM/THBh8iunyvKIZztiwLH4CJZ0RxTk9emgpjw==", "dev": true, + "license": "MIT", "dependencies": { - "@babel/helper-string-parser": "^7.22.5", - "@babel/helper-validator-identifier": "^7.22.20", - "to-fast-properties": "^2.0.0" + "@babel/helper-plugin-utils": "^7.14.5" }, "engines": { "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@colors/colors": { - "version": "1.5.0", + "node_modules/@babel/plugin-syntax-import-attributes": { + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-attributes/-/plugin-syntax-import-attributes-7.27.1.tgz", + "integrity": "sha512-oFT0FrKHgF53f4vOsZGi2Hh3I35PfSmVs4IBFLFj4dnafP+hIWDLg3VyKmUHfLoLHlyxY4C7DGtmHuJgn+IGww==", "dev": true, "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.27.1" + }, "engines": { - "node": ">=0.1.90" + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@eslint/eslintrc": { - "version": "2.0.0", + "node_modules/@babel/plugin-syntax-import-meta": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-meta/-/plugin-syntax-import-meta-7.10.4.tgz", + "integrity": "sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g==", "dev": true, "license": "MIT", "dependencies": { - "ajv": "^6.12.4", - "debug": "^4.3.2", - "espree": "^9.4.0", - "globals": "^13.19.0", - "ignore": "^5.2.0", - "import-fresh": "^3.2.1", - "js-yaml": "^4.1.0", - "minimatch": "^3.1.2", - "strip-json-comments": "^3.1.1" - }, - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "@babel/helper-plugin-utils": "^7.10.4" }, - "funding": { - "url": "https://opencollective.com/eslint" + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@eslint/eslintrc/node_modules/argparse": { - "version": "2.0.1", - "dev": true, - "license": "Python-2.0" - }, - "node_modules/@eslint/eslintrc/node_modules/js-yaml": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.1.tgz", - "integrity": "sha512-qQKT4zQxXl8lLwBtHMWwaTcGfFOZviOJet3Oy/xmGk2gZH677CJM9EvtfdSkgWcATZhj/55JZ0rmy3myCT5lsA==", + "node_modules/@babel/plugin-syntax-json-strings": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz", + "integrity": "sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==", "dev": true, + "license": "MIT", "dependencies": { - "argparse": "^2.0.1" + "@babel/helper-plugin-utils": "^7.8.0" }, - "bin": { - "js-yaml": "bin/js-yaml.js" + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@eslint/eslintrc/node_modules/minimatch": { - "version": "3.1.2", + "node_modules/@babel/plugin-syntax-jsx": { + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.27.1.tgz", + "integrity": "sha512-y8YTNIeKoyhGd9O0Jiyzyyqk8gdjnumGTQPsz0xOZOQ2RmkVJeZ1vmmfIvFEKqucBG6axJGBZDE/7iI5suUI/w==", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "brace-expansion": "^1.1.7" + "@babel/helper-plugin-utils": "^7.27.1" }, "engines": { - "node": "*" + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@eslint/js": { - "version": "8.35.0", + "node_modules/@babel/plugin-syntax-logical-assignment-operators": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz", + "integrity": "sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==", "dev": true, "license": "MIT", - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@humanwhocodes/config-array": { - "version": "0.11.8", + "node_modules/@babel/plugin-syntax-nullish-coalescing-operator": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz", + "integrity": "sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==", "dev": true, - "license": "Apache-2.0", + "license": "MIT", "dependencies": { - "@humanwhocodes/object-schema": "^1.2.1", - "debug": "^4.1.1", - "minimatch": "^3.0.5" + "@babel/helper-plugin-utils": "^7.8.0" }, - "engines": { - "node": ">=10.10.0" + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@humanwhocodes/config-array/node_modules/minimatch": { - "version": "3.1.2", + "node_modules/@babel/plugin-syntax-numeric-separator": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz", + "integrity": "sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "brace-expansion": "^1.1.7" + "@babel/helper-plugin-utils": "^7.10.4" }, - "engines": { - "node": "*" + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@humanwhocodes/module-importer": { - "version": "1.0.1", + "node_modules/@babel/plugin-syntax-object-rest-spread": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz", + "integrity": "sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==", "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=12.22" + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/nzakas" + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@humanwhocodes/object-schema": { - "version": "1.2.1", - "dev": true, - "license": "BSD-3-Clause" - }, - "node_modules/@istanbuljs/load-nyc-config": { - "version": "1.1.0", + "node_modules/@babel/plugin-syntax-optional-catch-binding": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz", + "integrity": "sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "camelcase": "^5.3.1", - "find-up": "^4.1.0", - "get-package-type": "^0.1.0", - "js-yaml": "^3.13.1", - "resolve-from": "^5.0.0" + "@babel/helper-plugin-utils": "^7.8.0" }, - "engines": { - "node": ">=8" + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@istanbuljs/load-nyc-config/node_modules/camelcase": { - "version": "5.3.1", + "node_modules/@babel/plugin-syntax-optional-chaining": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz", + "integrity": "sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==", "dev": true, "license": "MIT", - "engines": { - "node": ">=6" + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@istanbuljs/load-nyc-config/node_modules/find-up": { - "version": "4.1.0", + "node_modules/@babel/plugin-syntax-private-property-in-object": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-private-property-in-object/-/plugin-syntax-private-property-in-object-7.14.5.tgz", + "integrity": "sha512-0wVnp9dxJ72ZUJDV27ZfbSj6iHLoytYZmh3rFcxNnvsJF3ktkzLDZPy/mA17HGsaQT3/DQsWYX1f1QGWkCoVUg==", "dev": true, "license": "MIT", "dependencies": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" + "@babel/helper-plugin-utils": "^7.14.5" }, "engines": { - "node": ">=8" + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@istanbuljs/load-nyc-config/node_modules/locate-path": { - "version": "5.0.0", + "node_modules/@babel/plugin-syntax-top-level-await": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.14.5.tgz", + "integrity": "sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==", "dev": true, "license": "MIT", "dependencies": { - "p-locate": "^4.1.0" + "@babel/helper-plugin-utils": "^7.14.5" }, "engines": { - "node": ">=8" + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@istanbuljs/load-nyc-config/node_modules/p-limit": { - "version": "2.3.0", + "node_modules/@babel/plugin-syntax-typescript": { + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.27.1.tgz", + "integrity": "sha512-xfYCBMxveHrRMnAWl1ZlPXOZjzkN82THFvLhQhFXFt81Z5HnN+EtUkZhv/zcKpmT3fzmWZB0ywiBrbC3vogbwQ==", "dev": true, "license": "MIT", "dependencies": { - "p-try": "^2.0.0" + "@babel/helper-plugin-utils": "^7.27.1" }, "engines": { - "node": ">=6" + "node": ">=6.9.0" }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@istanbuljs/load-nyc-config/node_modules/p-locate": { - "version": "4.1.0", + "node_modules/@babel/template": { + "version": "7.27.2", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.27.2.tgz", + "integrity": "sha512-LPDZ85aEJyYSd18/DkjNh4/y1ntkE5KwUHWTiqgRxruuZL2F1yuHligVHLvcHY2vMHXttKFpJn6LwfI7cw7ODw==", "dev": true, "license": "MIT", "dependencies": { - "p-limit": "^2.2.0" + "@babel/code-frame": "^7.27.1", + "@babel/parser": "^7.27.2", + "@babel/types": "^7.27.1" }, "engines": { - "node": ">=8" + "node": ">=6.9.0" } }, - "node_modules/@istanbuljs/load-nyc-config/node_modules/resolve-from": { - "version": "5.0.0", + "node_modules/@babel/traverse": { + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.28.5.tgz", + "integrity": "sha512-TCCj4t55U90khlYkVV/0TfkJkAkUg3jZFA3Neb7unZT8CPok7iiRfaX0F+WnqWqt7OxhOn0uBKXCw4lbL8W0aQ==", "dev": true, "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.27.1", + "@babel/generator": "^7.28.5", + "@babel/helper-globals": "^7.28.0", + "@babel/parser": "^7.28.5", + "@babel/template": "^7.27.2", + "@babel/types": "^7.28.5", + "debug": "^4.3.1" + }, "engines": { - "node": ">=8" + "node": ">=6.9.0" } }, - "node_modules/@istanbuljs/schema": { - "version": "0.1.3", + "node_modules/@babel/types": { + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.28.5.tgz", + "integrity": "sha512-qQ5m48eI/MFLQ5PxQj4PFaprjyCTLI37ElWMmNs0K8Lk3dVeOdNpB3ks8jc7yM5CDmVC73eMVk/trk3fgmrUpA==", "dev": true, "license": "MIT", + "dependencies": { + "@babel/helper-string-parser": "^7.27.1", + "@babel/helper-validator-identifier": "^7.28.5" + }, "engines": { - "node": ">=8" + "node": ">=6.9.0" } }, - "node_modules/@jridgewell/gen-mapping": { - "version": "0.1.1", + "node_modules/@bcoe/v8-coverage": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz", + "integrity": "sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==", + "dev": true, + "license": "MIT" + }, + "node_modules/@emnapi/core": { + "version": "1.7.1", + "resolved": "https://registry.npmjs.org/@emnapi/core/-/core-1.7.1.tgz", + "integrity": "sha512-o1uhUASyo921r2XtHYOHy7gdkGLge8ghBEQHMWmyJFoXlpU58kIrhhN3w26lpQb6dspetweapMn2CSNwQ8I4wg==", "dev": true, "license": "MIT", + "optional": true, "dependencies": { - "@jridgewell/set-array": "^1.0.0", - "@jridgewell/sourcemap-codec": "^1.4.10" - }, - "engines": { - "node": ">=6.0.0" + "@emnapi/wasi-threads": "1.1.0", + "tslib": "^2.4.0" } }, - "node_modules/@jridgewell/resolve-uri": { - "version": "3.1.0", + "node_modules/@emnapi/runtime": { + "version": "1.7.1", + "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.7.1.tgz", + "integrity": "sha512-PVtJr5CmLwYAU9PZDMITZoR5iAOShYREoR45EyyLrbntV50mdePTgUn4AmOw90Ifcj+x2kRjdzr1HP3RrNiHGA==", "dev": true, "license": "MIT", - "engines": { - "node": ">=6.0.0" + "optional": true, + "dependencies": { + "tslib": "^2.4.0" } }, - "node_modules/@jridgewell/set-array": { - "version": "1.1.2", + "node_modules/@emnapi/wasi-threads": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@emnapi/wasi-threads/-/wasi-threads-1.1.0.tgz", + "integrity": "sha512-WI0DdZ8xFSbgMjR1sFsKABJ/C5OnRrjT06JXbZKexJGrDuPTzZdDYfFlsgcCXCyf+suG5QU2e/y1Wo2V/OapLQ==", "dev": true, "license": "MIT", - "engines": { - "node": ">=6.0.0" + "optional": true, + "dependencies": { + "tslib": "^2.4.0" } }, - "node_modules/@jridgewell/sourcemap-codec": { - "version": "1.4.14", - "dev": true, - "license": "MIT" - }, - "node_modules/@jridgewell/trace-mapping": { - "version": "0.3.17", + "node_modules/@esbuild/aix-ppc64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.27.0.tgz", + "integrity": "sha512-KuZrd2hRjz01y5JK9mEBSD3Vj3mbCvemhT466rSuJYeE/hjuBrHfjjcjMdTm/sz7au+++sdbJZJmuBwQLuw68A==", + "cpu": [ + "ppc64" + ], "dev": true, "license": "MIT", - "dependencies": { - "@jridgewell/resolve-uri": "3.1.0", - "@jridgewell/sourcemap-codec": "1.4.14" + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=18" } }, - "node_modules/@nodelib/fs.scandir": { - "version": "2.1.5", + "node_modules/@esbuild/android-arm": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.27.0.tgz", + "integrity": "sha512-j67aezrPNYWJEOHUNLPj9maeJte7uSMM6gMoxfPC9hOg8N02JuQi/T7ewumf4tNvJadFkvLZMlAq73b9uwdMyQ==", + "cpu": [ + "arm" + ], "dev": true, "license": "MIT", - "dependencies": { - "@nodelib/fs.stat": "2.0.5", - "run-parallel": "^1.1.9" - }, + "optional": true, + "os": [ + "android" + ], "engines": { - "node": ">= 8" + "node": ">=18" } }, - "node_modules/@nodelib/fs.stat": { - "version": "2.0.5", + "node_modules/@esbuild/android-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.27.0.tgz", + "integrity": "sha512-CC3vt4+1xZrs97/PKDkl0yN7w8edvU2vZvAFGD16n9F0Cvniy5qvzRXjfO1l94efczkkQE6g1x0i73Qf5uthOQ==", + "cpu": [ + "arm64" + ], "dev": true, "license": "MIT", + "optional": true, + "os": [ + "android" + ], "engines": { - "node": ">= 8" + "node": ">=18" } }, - "node_modules/@nodelib/fs.walk": { - "version": "1.2.8", + "node_modules/@esbuild/android-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.27.0.tgz", + "integrity": "sha512-wurMkF1nmQajBO1+0CJmcN17U4BP6GqNSROP8t0X/Jiw2ltYGLHpEksp9MpoBqkrFR3kv2/te6Sha26k3+yZ9Q==", + "cpu": [ + "x64" + ], "dev": true, "license": "MIT", - "dependencies": { - "@nodelib/fs.scandir": "2.1.5", - "fastq": "^1.6.0" - }, + "optional": true, + "os": [ + "android" + ], "engines": { - "node": ">= 8" + "node": ">=18" } }, - "node_modules/@socket.io/component-emitter": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.2.tgz", - "integrity": "sha512-9BCxFwvbGg/RsZK9tjXd8s4UcwR0MWeFQ1XEKIQVVvAGJyINdrqKMcTRyLoK8Rse1GjzLV9cwjWV1olXRWEXVA==", - "dev": true - }, - "node_modules/@types/cookie": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/@types/cookie/-/cookie-0.4.1.tgz", - "integrity": "sha512-XW/Aa8APYr6jSVVA1y/DEIZX0/GMKLEVekNG727R8cs56ahETkRAy/3DR7+fJyh7oUgGwNQaRfXCun0+KbWY7Q==", - "dev": true - }, - "node_modules/@types/cors": { - "version": "2.8.17", - "resolved": "https://registry.npmjs.org/@types/cors/-/cors-2.8.17.tgz", - "integrity": "sha512-8CGDvrBj1zgo2qE+oS3pOCyYNqCPryMWY2bGfwA0dcfopWGgxs+78df0Rs3rc9THP4JkOhLsAa+15VdpAqkcUA==", + "node_modules/@esbuild/darwin-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.27.0.tgz", + "integrity": "sha512-uJOQKYCcHhg07DL7i8MzjvS2LaP7W7Pn/7uA0B5S1EnqAirJtbyw4yC5jQ5qcFjHK9l6o/MX9QisBg12kNkdHg==", + "cpu": [ + "arm64" + ], "dev": true, - "dependencies": { - "@types/node": "*" + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" } }, - "node_modules/@types/node": { - "version": "22.7.5", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.7.5.tgz", - "integrity": "sha512-jML7s2NAzMWc//QSJ1a3prpk78cOPchGvXJsC3C6R6PSMoooztvRVQEz89gmBTBY1SPMaqo5teB4uNHPdetShQ==", + "node_modules/@esbuild/darwin-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.27.0.tgz", + "integrity": "sha512-8mG6arH3yB/4ZXiEnXof5MK72dE6zM9cDvUcPtxhUZsDjESl9JipZYW60C3JGreKCEP+p8P/72r69m4AZGJd5g==", + "cpu": [ + "x64" + ], "dev": true, - "dependencies": { - "undici-types": "~6.19.2" + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" } }, - "node_modules/accepts": { - "version": "1.3.8", - "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.8.tgz", - "integrity": "sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw==", + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.27.0.tgz", + "integrity": "sha512-9FHtyO988CwNMMOE3YIeci+UV+x5Zy8fI2qHNpsEtSF83YPBmE8UWmfYAQg6Ux7Gsmd4FejZqnEUZCMGaNQHQw==", + "cpu": [ + "arm64" + ], "dev": true, - "dependencies": { - "mime-types": "~2.1.34", - "negotiator": "0.6.3" - }, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], "engines": { - "node": ">= 0.6" + "node": ">=18" } }, - "node_modules/acorn": { - "version": "7.4.1", + "node_modules/@esbuild/freebsd-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.27.0.tgz", + "integrity": "sha512-zCMeMXI4HS/tXvJz8vWGexpZj2YVtRAihHLk1imZj4efx1BQzN76YFeKqlDr3bUWI26wHwLWPd3rwh6pe4EV7g==", + "cpu": [ + "x64" + ], "dev": true, "license": "MIT", - "bin": { - "acorn": "bin/acorn" - }, + "optional": true, + "os": [ + "freebsd" + ], "engines": { - "node": ">=0.4.0" + "node": ">=18" } }, - "node_modules/acorn-jsx": { - "version": "5.3.2", + "node_modules/@esbuild/linux-arm": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.27.0.tgz", + "integrity": "sha512-t76XLQDpxgmq2cNXKTVEB7O7YMb42atj2Re2Haf45HkaUpjM2J0UuJZDuaGbPbamzZ7bawyGFUkodL+zcE+jvQ==", + "cpu": [ + "arm" + ], "dev": true, "license": "MIT", - "peerDependencies": { - "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" } }, - "node_modules/acorn-node": { - "version": "1.8.2", + "node_modules/@esbuild/linux-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.27.0.tgz", + "integrity": "sha512-AS18v0V+vZiLJyi/4LphvBE+OIX682Pu7ZYNsdUHyUKSoRwdnOsMf6FDekwoAFKej14WAkOef3zAORJgAtXnlQ==", + "cpu": [ + "arm64" + ], "dev": true, - "license": "Apache-2.0", - "dependencies": { - "acorn": "^7.0.0", - "acorn-walk": "^7.0.0", - "xtend": "^4.0.2" + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" } }, - "node_modules/acorn-walk": { - "version": "7.0.0", + "node_modules/@esbuild/linux-ia32": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.27.0.tgz", + "integrity": "sha512-Mz1jxqm/kfgKkc/KLHC5qIujMvnnarD9ra1cEcrs7qshTUSksPihGrWHVG5+osAIQ68577Zpww7SGapmzSt4Nw==", + "cpu": [ + "ia32" + ], "dev": true, "license": "MIT", + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">=0.4.0" + "node": ">=18" } }, - "node_modules/aggregate-error": { - "version": "3.1.0", + "node_modules/@esbuild/linux-loong64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.27.0.tgz", + "integrity": "sha512-QbEREjdJeIreIAbdG2hLU1yXm1uu+LTdzoq1KCo4G4pFOLlvIspBm36QrQOar9LFduavoWX2msNFAAAY9j4BDg==", + "cpu": [ + "loong64" + ], "dev": true, "license": "MIT", - "dependencies": { - "clean-stack": "^2.0.0", - "indent-string": "^4.0.0" - }, + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">=8" + "node": ">=18" } }, - "node_modules/ajv": { - "version": "6.12.6", + "node_modules/@esbuild/linux-mips64el": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.27.0.tgz", + "integrity": "sha512-sJz3zRNe4tO2wxvDpH/HYJilb6+2YJxo/ZNbVdtFiKDufzWq4JmKAiHy9iGoLjAV7r/W32VgaHGkk35cUXlNOg==", + "cpu": [ + "mips64el" + ], "dev": true, "license": "MIT", - "dependencies": { - "fast-deep-equal": "^3.1.1", - "fast-json-stable-stringify": "^2.0.0", - "json-schema-traverse": "^0.4.1", - "uri-js": "^4.2.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" } }, - "node_modules/ansi-colors": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.3.tgz", - "integrity": "sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==", + "node_modules/@esbuild/linux-ppc64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.27.0.tgz", + "integrity": "sha512-z9N10FBD0DCS2dmSABDBb5TLAyF1/ydVb+N4pi88T45efQ/w4ohr/F/QYCkxDPnkhkp6AIpIcQKQ8F0ANoA2JA==", + "cpu": [ + "ppc64" + ], "dev": true, "license": "MIT", + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">=6" + "node": ">=18" } }, - "node_modules/ansi-regex": { - "version": "5.0.1", + "node_modules/@esbuild/linux-riscv64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.27.0.tgz", + "integrity": "sha512-pQdyAIZ0BWIC5GyvVFn5awDiO14TkT/19FTmFcPdDec94KJ1uZcmFs21Fo8auMXzD4Tt+diXu1LW1gHus9fhFQ==", + "cpu": [ + "riscv64" + ], "dev": true, "license": "MIT", + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">=8" + "node": ">=18" } }, - "node_modules/ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "node_modules/@esbuild/linux-s390x": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.27.0.tgz", + "integrity": "sha512-hPlRWR4eIDDEci953RI1BLZitgi5uqcsjKMxwYfmi4LcwyWo2IcRP+lThVnKjNtk90pLS8nKdroXYOqW+QQH+w==", + "cpu": [ + "s390x" + ], "dev": true, - "dependencies": { - "color-convert": "^1.9.0" - }, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">=4" + "node": ">=18" } }, - "node_modules/anymatch": { - "version": "3.1.3", + "node_modules/@esbuild/linux-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.27.0.tgz", + "integrity": "sha512-1hBWx4OUJE2cab++aVZ7pObD6s+DK4mPGpemtnAORBvb5l/g5xFGk0vc0PjSkrDs0XaXj9yyob3d14XqvnQ4gw==", + "cpu": [ + "x64" + ], "dev": true, - "license": "ISC", - "dependencies": { - "normalize-path": "^3.0.0", - "picomatch": "^2.0.4" - }, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">= 8" + "node": ">=18" } }, - "node_modules/append-transform": { - "version": "2.0.0", + "node_modules/@esbuild/netbsd-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.27.0.tgz", + "integrity": "sha512-6m0sfQfxfQfy1qRuecMkJlf1cIzTOgyaeXaiVaaki8/v+WB+U4hc6ik15ZW6TAllRlg/WuQXxWj1jx6C+dfy3w==", + "cpu": [ + "arm64" + ], "dev": true, "license": "MIT", - "dependencies": { - "default-require-extensions": "^3.0.0" - }, + "optional": true, + "os": [ + "netbsd" + ], "engines": { - "node": ">=8" + "node": ">=18" } }, - "node_modules/archy": { - "version": "1.0.0", - "dev": true, - "license": "MIT" - }, - "node_modules/argparse": { - "version": "1.0.10", + "node_modules/@esbuild/netbsd-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.27.0.tgz", + "integrity": "sha512-xbbOdfn06FtcJ9d0ShxxvSn2iUsGd/lgPIO2V3VZIPDbEaIj1/3nBBe1AwuEZKXVXkMmpr6LUAgMkLD/4D2PPA==", + "cpu": [ + "x64" + ], "dev": true, "license": "MIT", - "dependencies": { - "sprintf-js": "~1.0.2" + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=18" } }, - "node_modules/asn1.js": { - "version": "5.4.1", - "resolved": "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz", - "integrity": "sha512-+I//4cYPccV8LdmBLiX8CYvf9Sp3vQsrqu2QNXRcrbiWvcx/UdlFiqUJJzxRQxgsZmvhXhn4cSKeSmoFjVdupA==", + "node_modules/@esbuild/openbsd-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.27.0.tgz", + "integrity": "sha512-fWgqR8uNbCQ/GGv0yhzttj6sU/9Z5/Sv/VGU3F5OuXK6J6SlriONKrQ7tNlwBrJZXRYk5jUhuWvF7GYzGguBZQ==", + "cpu": [ + "arm64" + ], "dev": true, - "dependencies": { - "bn.js": "^4.0.0", - "inherits": "^2.0.1", - "minimalistic-assert": "^1.0.0", - "safer-buffer": "^2.1.0" + "license": "MIT", + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" } }, - "node_modules/assert": { - "version": "1.5.0", + "node_modules/@esbuild/openbsd-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.27.0.tgz", + "integrity": "sha512-aCwlRdSNMNxkGGqQajMUza6uXzR/U0dIl1QmLjPtRbLOx3Gy3otfFu/VjATy4yQzo9yFDGTxYDo1FfAD9oRD2A==", + "cpu": [ + "x64" + ], "dev": true, "license": "MIT", - "dependencies": { - "object-assign": "^4.1.1", - "util": "0.10.3" + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" } }, - "node_modules/assert/node_modules/inherits": { - "version": "2.0.1", - "dev": true, - "license": "ISC" - }, - "node_modules/assert/node_modules/util": { - "version": "0.10.3", + "node_modules/@esbuild/openharmony-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.27.0.tgz", + "integrity": "sha512-nyvsBccxNAsNYz2jVFYwEGuRRomqZ149A39SHWk4hV0jWxKM0hjBPm3AmdxcbHiFLbBSwG6SbpIcUbXjgyECfA==", + "cpu": [ + "arm64" + ], "dev": true, "license": "MIT", - "dependencies": { - "inherits": "2.0.1" + "optional": true, + "os": [ + "openharmony" + ], + "engines": { + "node": ">=18" } }, - "node_modules/assertion-error": { - "version": "1.1.0", + "node_modules/@esbuild/sunos-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.27.0.tgz", + "integrity": "sha512-Q1KY1iJafM+UX6CFEL+F4HRTgygmEW568YMqDA5UV97AuZSm21b7SXIrRJDwXWPzr8MGr75fUZPV67FdtMHlHA==", + "cpu": [ + "x64" + ], "dev": true, "license": "MIT", + "optional": true, + "os": [ + "sunos" + ], "engines": { - "node": "*" + "node": ">=18" } }, - "node_modules/available-typed-arrays": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.7.tgz", - "integrity": "sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==", + "node_modules/@esbuild/win32-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.27.0.tgz", + "integrity": "sha512-W1eyGNi6d+8kOmZIwi/EDjrL9nxQIQ0MiGqe/AWc6+IaHloxHSGoeRgDRKHFISThLmsewZ5nHFvGFWdBYlgKPg==", + "cpu": [ + "arm64" + ], "dev": true, "license": "MIT", - "dependencies": { - "possible-typed-array-names": "^1.0.0" - }, + "optional": true, + "os": [ + "win32" + ], "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": ">=18" } }, - "node_modules/balanced-match": { - "version": "1.0.0", - "dev": true, - "license": "MIT" - }, - "node_modules/base64-js": { - "version": "1.5.1", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } + "node_modules/@esbuild/win32-ia32": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.27.0.tgz", + "integrity": "sha512-30z1aKL9h22kQhilnYkORFYt+3wp7yZsHWus+wSKAJR8JtdfI76LJ4SBdMsCopTR3z/ORqVu5L1vtnHZWVj4cQ==", + "cpu": [ + "ia32" ], - "license": "MIT" - }, - "node_modules/base64id": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/base64id/-/base64id-2.0.0.tgz", - "integrity": "sha512-lGe34o6EHj9y3Kts9R4ZYs/Gr+6N7MCaMlIFA3F1R2O5/m7K06AxfSeO5530PEERE6/WyEg3lsuyw4GHlPZHog==", "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], "engines": { - "node": "^4.5.0 || >= 5.9" + "node": ">=18" } }, - "node_modules/beeper": { - "version": "1.1.1", + "node_modules/@esbuild/win32-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.27.0.tgz", + "integrity": "sha512-aIitBcjQeyOhMTImhLZmtxfdOcuNRpwlPNmlFKPcHQYPhEssw75Cl1TSXJXpMkzaua9FUetx/4OQKq7eJul5Cg==", + "cpu": [ + "x64" + ], "dev": true, "license": "MIT", + "optional": true, + "os": [ + "win32" + ], "engines": { - "node": ">=0.10.0" + "node": ">=18" } }, - "node_modules/benchmark": { - "version": "2.1.4", + "node_modules/@eslint/eslintrc": { + "version": "2.0.0", "dev": true, "license": "MIT", "dependencies": { - "lodash": "^4.17.4", - "platform": "^1.3.3" + "ajv": "^6.12.4", + "debug": "^4.3.2", + "espree": "^9.4.0", + "globals": "^13.19.0", + "ignore": "^5.2.0", + "import-fresh": "^3.2.1", + "js-yaml": "^4.1.0", + "minimatch": "^3.1.2", + "strip-json-comments": "^3.1.1" + }, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" } }, - "node_modules/binary-extensions": { - "version": "2.2.0", + "node_modules/@eslint/eslintrc/node_modules/argparse": { + "version": "2.0.1", "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } + "license": "Python-2.0" }, - "node_modules/bn.js": { - "version": "4.12.0", + "node_modules/@eslint/eslintrc/node_modules/js-yaml": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.1.tgz", + "integrity": "sha512-qQKT4zQxXl8lLwBtHMWwaTcGfFOZviOJet3Oy/xmGk2gZH677CJM9EvtfdSkgWcATZhj/55JZ0rmy3myCT5lsA==", "dev": true, - "license": "MIT" + "dependencies": { + "argparse": "^2.0.1" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } }, - "node_modules/body-parser": { - "version": "1.20.3", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", - "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", + "node_modules/@eslint/eslintrc/node_modules/minimatch": { + "version": "3.1.2", "dev": true, + "license": "ISC", "dependencies": { - "bytes": "3.1.2", - "content-type": "~1.0.5", - "debug": "2.6.9", - "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.13.0", - "raw-body": "2.5.2", - "type-is": "~1.6.18", - "unpipe": "1.0.0" + "brace-expansion": "^1.1.7" }, "engines": { - "node": ">= 0.8", - "npm": "1.2.8000 || >= 1.4.16" + "node": "*" } }, - "node_modules/body-parser/node_modules/debug": { - "version": "2.6.9", + "node_modules/@eslint/js": { + "version": "8.35.0", "dev": true, "license": "MIT", - "dependencies": { - "ms": "2.0.0" + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" } }, - "node_modules/body-parser/node_modules/ms": { - "version": "2.0.0", + "node_modules/@humanwhocodes/config-array": { + "version": "0.11.8", "dev": true, - "license": "MIT" + "license": "Apache-2.0", + "dependencies": { + "@humanwhocodes/object-schema": "^1.2.1", + "debug": "^4.1.1", + "minimatch": "^3.0.5" + }, + "engines": { + "node": ">=10.10.0" + } }, - "node_modules/body-parser/node_modules/on-finished": { - "version": "2.4.1", + "node_modules/@humanwhocodes/config-array/node_modules/minimatch": { + "version": "3.1.2", "dev": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "ee-first": "1.1.1" + "brace-expansion": "^1.1.7" }, "engines": { - "node": ">= 0.8" + "node": "*" } }, - "node_modules/brace-expansion": { - "version": "1.1.11", + "node_modules/@humanwhocodes/module-importer": { + "version": "1.0.1", "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" + "license": "Apache-2.0", + "engines": { + "node": ">=12.22" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/nzakas" } }, - "node_modules/braces": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", - "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", + "node_modules/@humanwhocodes/object-schema": { + "version": "1.2.1", + "dev": true, + "license": "BSD-3-Clause" + }, + "node_modules/@isaacs/cliui": { + "version": "8.0.2", + "resolved": "https://registry.npmjs.org/@isaacs/cliui/-/cliui-8.0.2.tgz", + "integrity": "sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA==", "dev": true, + "license": "ISC", "dependencies": { - "fill-range": "^7.1.1" + "string-width": "^5.1.2", + "string-width-cjs": "npm:string-width@^4.2.0", + "strip-ansi": "^7.0.1", + "strip-ansi-cjs": "npm:strip-ansi@^6.0.1", + "wrap-ansi": "^8.1.0", + "wrap-ansi-cjs": "npm:wrap-ansi@^7.0.0" }, "engines": { - "node": ">=8" + "node": ">=12" } }, - "node_modules/brorand": { - "version": "1.1.0", - "dev": true, - "license": "MIT" - }, - "node_modules/browser-pack": { - "version": "6.1.0", + "node_modules/@isaacs/cliui/node_modules/ansi-regex": { + "version": "6.2.2", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-6.2.2.tgz", + "integrity": "sha512-Bq3SmSpyFHaWjPk8If9yc6svM8c56dB5BAtW4Qbw5jHTwwXXcTLoRMkpDJp6VL0XzlWaCHTXrkFURMYmD0sLqg==", "dev": true, "license": "MIT", - "dependencies": { - "combine-source-map": "~0.8.0", - "defined": "^1.0.0", - "JSONStream": "^1.0.3", - "safe-buffer": "^5.1.1", - "through2": "^2.0.0", - "umd": "^3.0.0" + "engines": { + "node": ">=12" }, - "bin": { - "browser-pack": "bin/cmd.js" + "funding": { + "url": "https://github.com/chalk/ansi-regex?sponsor=1" } }, - "node_modules/browser-resolve": { - "version": "1.11.3", + "node_modules/@isaacs/cliui/node_modules/ansi-styles": { + "version": "6.2.3", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-6.2.3.tgz", + "integrity": "sha512-4Dj6M28JB+oAH8kFkTLUo+a2jwOFkuqb3yucU0CANcRRUbxS0cP0nZYCGjcc3BNXwRIsUVmDGgzawme7zvJHvg==", "dev": true, "license": "MIT", - "dependencies": { - "resolve": "1.1.7" + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/browser-resolve/node_modules/resolve": { - "version": "1.1.7", + "node_modules/@isaacs/cliui/node_modules/emoji-regex": { + "version": "9.2.2", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-9.2.2.tgz", + "integrity": "sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==", "dev": true, "license": "MIT" }, - "node_modules/browser-stdout": { - "version": "1.3.1", + "node_modules/@isaacs/cliui/node_modules/string-width": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-5.1.2.tgz", + "integrity": "sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==", "dev": true, - "license": "ISC" - }, - "node_modules/browserify": { - "version": "16.5.1", - "dev": true, - "license": "MIT", - "dependencies": { - "assert": "^1.4.0", - "browser-pack": "^6.0.1", - "browser-resolve": "^1.11.0", - "browserify-zlib": "~0.2.0", - "buffer": "~5.2.1", - "cached-path-relative": "^1.0.0", - "concat-stream": "^1.6.0", - "console-browserify": "^1.1.0", - "constants-browserify": "~1.0.0", - "crypto-browserify": "^3.0.0", - "defined": "^1.0.0", - "deps-sort": "^2.0.0", - "domain-browser": "^1.2.0", - "duplexer2": "~0.1.2", - "events": "^2.0.0", - "glob": "^7.1.0", - "has": "^1.0.0", - "htmlescape": "^1.1.0", - "https-browserify": "^1.0.0", - "inherits": "~2.0.1", - "insert-module-globals": "^7.0.0", - "JSONStream": "^1.0.3", - "labeled-stream-splicer": "^2.0.0", - "mkdirp-classic": "^0.5.2", - "module-deps": "^6.0.0", - "os-browserify": "~0.3.0", - "parents": "^1.0.1", - "path-browserify": "~0.0.0", - "process": "~0.11.0", - "punycode": "^1.3.2", - "querystring-es3": "~0.2.0", - "read-only-stream": "^2.0.0", - "readable-stream": "^2.0.2", - "resolve": "^1.1.4", - "shasum": "^1.0.0", - "shell-quote": "^1.6.1", - "stream-browserify": "^2.0.0", - "stream-http": "^3.0.0", - "string_decoder": "^1.1.1", - "subarg": "^1.0.0", - "syntax-error": "^1.1.1", - "through2": "^2.0.0", - "timers-browserify": "^1.0.1", - "tty-browserify": "0.0.1", - "url": "~0.11.0", - "util": "~0.10.1", - "vm-browserify": "^1.0.0", - "xtend": "^4.0.0" - }, - "bin": { - "browserify": "bin/cmd.js" + "license": "MIT", + "dependencies": { + "eastasianwidth": "^0.2.0", + "emoji-regex": "^9.2.2", + "strip-ansi": "^7.0.1" }, "engines": { - "node": ">= 0.8" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/browserify-aes": { - "version": "1.2.0", + "node_modules/@isaacs/cliui/node_modules/strip-ansi": { + "version": "7.1.2", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-7.1.2.tgz", + "integrity": "sha512-gmBGslpoQJtgnMAvOVqGZpEz9dyoKTCzy2nfz/n8aIFhN/jCE/rCmcxabB6jOOHV+0WNnylOxaxBQPSvcWklhA==", "dev": true, "license": "MIT", "dependencies": { - "buffer-xor": "^1.0.3", - "cipher-base": "^1.0.0", - "create-hash": "^1.1.0", - "evp_bytestokey": "^1.0.3", - "inherits": "^2.0.1", - "safe-buffer": "^5.0.1" + "ansi-regex": "^6.0.1" + }, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/strip-ansi?sponsor=1" } }, - "node_modules/browserify-cipher": { - "version": "1.0.1", + "node_modules/@isaacs/cliui/node_modules/wrap-ansi": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-8.1.0.tgz", + "integrity": "sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==", "dev": true, "license": "MIT", "dependencies": { - "browserify-aes": "^1.0.4", - "browserify-des": "^1.0.0", - "evp_bytestokey": "^1.0.0" + "ansi-styles": "^6.1.0", + "string-width": "^5.0.1", + "strip-ansi": "^7.0.1" + }, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" } }, - "node_modules/browserify-des": { - "version": "1.0.2", + "node_modules/@istanbuljs/load-nyc-config": { + "version": "1.1.0", "dev": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "cipher-base": "^1.0.1", - "des.js": "^1.0.0", - "inherits": "^2.0.1", - "safe-buffer": "^5.1.2" + "camelcase": "^5.3.1", + "find-up": "^4.1.0", + "get-package-type": "^0.1.0", + "js-yaml": "^3.13.1", + "resolve-from": "^5.0.0" + }, + "engines": { + "node": ">=8" } }, - "node_modules/browserify-rsa": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/browserify-rsa/-/browserify-rsa-4.1.0.tgz", - "integrity": "sha512-AdEER0Hkspgno2aR97SAf6vi0y0k8NuOpGnVH3O99rcA5Q6sh8QxcngtHuJ6uXwnfAXNM4Gn1Gb7/MV1+Ymbog==", + "node_modules/@istanbuljs/load-nyc-config/node_modules/camelcase": { + "version": "5.3.1", "dev": true, - "dependencies": { - "bn.js": "^5.0.0", - "randombytes": "^2.0.1" + "license": "MIT", + "engines": { + "node": ">=6" } }, - "node_modules/browserify-rsa/node_modules/bn.js": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", - "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==", - "dev": true - }, - "node_modules/browserify-sign": { - "version": "4.2.2", - "resolved": "https://registry.npmjs.org/browserify-sign/-/browserify-sign-4.2.2.tgz", - "integrity": "sha512-1rudGyeYY42Dk6texmv7c4VcQ0EsvVbLwZkA+AQB7SxvXxmcD93jcHie8bzecJ+ChDlmAm2Qyu0+Ccg5uhZXCg==", + "node_modules/@istanbuljs/load-nyc-config/node_modules/find-up": { + "version": "4.1.0", "dev": true, + "license": "MIT", "dependencies": { - "bn.js": "^5.2.1", - "browserify-rsa": "^4.1.0", - "create-hash": "^1.2.0", - "create-hmac": "^1.1.7", - "elliptic": "^6.5.4", - "inherits": "^2.0.4", - "parse-asn1": "^5.1.6", - "readable-stream": "^3.6.2", - "safe-buffer": "^5.2.1" + "locate-path": "^5.0.0", + "path-exists": "^4.0.0" }, "engines": { - "node": ">= 4" + "node": ">=8" } }, - "node_modules/browserify-sign/node_modules/bn.js": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", - "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==", - "dev": true - }, - "node_modules/browserify-sign/node_modules/readable-stream": { - "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "node_modules/@istanbuljs/load-nyc-config/node_modules/locate-path": { + "version": "5.0.0", "dev": true, + "license": "MIT", "dependencies": { - "inherits": "^2.0.3", - "string_decoder": "^1.1.1", - "util-deprecate": "^1.0.1" + "p-locate": "^4.1.0" }, "engines": { - "node": ">= 6" + "node": ">=8" } }, - "node_modules/browserify-zlib": { - "version": "0.2.0", + "node_modules/@istanbuljs/load-nyc-config/node_modules/p-limit": { + "version": "2.3.0", "dev": true, "license": "MIT", "dependencies": { - "pako": "~1.0.5" + "p-try": "^2.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/browserslist": { - "version": "4.21.5", + "node_modules/@istanbuljs/load-nyc-config/node_modules/p-locate": { + "version": "4.1.0", "dev": true, - "funding": [ - { - "type": "opencollective", - "url": "https://opencollective.com/browserslist" - }, - { - "type": "tidelift", - "url": "https://tidelift.com/funding/github/npm/browserslist" - } - ], "license": "MIT", "dependencies": { - "caniuse-lite": "^1.0.30001449", - "electron-to-chromium": "^1.4.284", - "node-releases": "^2.0.8", - "update-browserslist-db": "^1.0.10" - }, - "bin": { - "browserslist": "cli.js" + "p-limit": "^2.2.0" }, "engines": { - "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" + "node": ">=8" } }, - "node_modules/buffer": { - "version": "5.2.1", + "node_modules/@istanbuljs/load-nyc-config/node_modules/resolve-from": { + "version": "5.0.0", "dev": true, "license": "MIT", - "dependencies": { - "base64-js": "^1.0.2", - "ieee754": "^1.1.4" + "engines": { + "node": ">=8" } }, - "node_modules/buffer-from": { - "version": "1.1.1", - "dev": true, - "license": "MIT" - }, - "node_modules/buffer-xor": { - "version": "1.0.3", - "dev": true, - "license": "MIT" - }, - "node_modules/builtin-status-codes": { - "version": "3.0.0", - "dev": true, - "license": "MIT" - }, - "node_modules/bytes": { - "version": "3.1.2", + "node_modules/@istanbuljs/schema": { + "version": "0.1.3", "dev": true, "license": "MIT", "engines": { - "node": ">= 0.8" + "node": ">=8" } }, - "node_modules/cached-path-relative": { - "version": "1.1.0", - "dev": true, - "license": "MIT" - }, - "node_modules/caching-transform": { - "version": "4.0.0", + "node_modules/@jest/console": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/console/-/console-30.2.0.tgz", + "integrity": "sha512-+O1ifRjkvYIkBqASKWgLxrpEhQAAE7hY77ALLUufSk5717KfOShg6IbqLmdsLMPdUiFvA2kTs0R7YZy+l0IzZQ==", "dev": true, "license": "MIT", "dependencies": { - "hasha": "^5.0.0", - "make-dir": "^3.0.0", - "package-hash": "^4.0.0", - "write-file-atomic": "^3.0.0" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "jest-message-util": "30.2.0", + "jest-util": "30.2.0", + "slash": "^3.0.0" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/call-bind": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.8.tgz", - "integrity": "sha512-oKlSFMcMwpUg2ednkhQ454wfWiU/ul3CkJe/PEHcTKuiX6RpbehUiFMXu13HalGZxfUwCQzZG747YXBn1im9ww==", + "node_modules/@jest/console/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, "license": "MIT", - "dependencies": { - "call-bind-apply-helpers": "^1.0.0", - "es-define-property": "^1.0.0", - "get-intrinsic": "^1.2.4", - "set-function-length": "^1.2.2" - }, "engines": { - "node": ">= 0.4" + "node": ">=10" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/call-bind-apply-helpers": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.2.tgz", - "integrity": "sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==", + "node_modules/@jest/console/node_modules/jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, "license": "MIT", "dependencies": { - "es-errors": "^1.3.0", - "function-bind": "^1.1.2" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" }, "engines": { - "node": ">= 0.4" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/call-bound": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/call-bound/-/call-bound-1.0.4.tgz", - "integrity": "sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg==", + "node_modules/@jest/console/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", "dependencies": { - "call-bind-apply-helpers": "^1.0.2", - "get-intrinsic": "^1.3.0" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" }, "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/callsites": { - "version": "3.1.0", + "node_modules/@jest/console/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, "license": "MIT", "engines": { - "node": ">=6" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/camelcase": { - "version": "6.3.0", + "node_modules/@jest/console/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, "license": "MIT", - "engines": { - "node": ">=10" + "dependencies": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/caniuse-lite": { - "version": "1.0.30001460", + "node_modules/@jest/core": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/core/-/core-30.2.0.tgz", + "integrity": "sha512-03W6IhuhjqTlpzh/ojut/pDB2LPRygyWX8ExpgHtQA8H/3K7+1vKmcINx5UzeOX1se6YEsBsOHQ1CRzf3fOwTQ==", "dev": true, - "funding": [ - { - "type": "opencollective", - "url": "https://opencollective.com/browserslist" - }, - { - "type": "tidelift", - "url": "https://tidelift.com/funding/github/npm/caniuse-lite" + "license": "MIT", + "dependencies": { + "@jest/console": "30.2.0", + "@jest/pattern": "30.0.1", + "@jest/reporters": "30.2.0", + "@jest/test-result": "30.2.0", + "@jest/transform": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "ansi-escapes": "^4.3.2", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "exit-x": "^0.2.2", + "graceful-fs": "^4.2.11", + "jest-changed-files": "30.2.0", + "jest-config": "30.2.0", + "jest-haste-map": "30.2.0", + "jest-message-util": "30.2.0", + "jest-regex-util": "30.0.1", + "jest-resolve": "30.2.0", + "jest-resolve-dependencies": "30.2.0", + "jest-runner": "30.2.0", + "jest-runtime": "30.2.0", + "jest-snapshot": "30.2.0", + "jest-util": "30.2.0", + "jest-validate": "30.2.0", + "jest-watcher": "30.2.0", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" + }, + "peerDependenciesMeta": { + "node-notifier": { + "optional": true } - ], - "license": "CC-BY-4.0" + } }, - "node_modules/chai": { - "version": "4.3.7", + "node_modules/@jest/core/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, "license": "MIT", - "dependencies": { - "assertion-error": "^1.1.0", - "check-error": "^1.0.2", - "deep-eql": "^4.1.2", - "get-func-name": "^2.0.0", - "loupe": "^2.3.1", - "pathval": "^1.1.1", - "type-detect": "^4.0.5" - }, "engines": { - "node": ">=4" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "node_modules/@jest/core/node_modules/jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, + "license": "MIT", "dependencies": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" }, "engines": { - "node": ">=4" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/check-error": { - "version": "1.0.2", + "node_modules/@jest/core/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, "engines": { - "node": "*" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/chokidar": { - "version": "3.5.3", + "node_modules/@jest/core/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://paulmillr.com/funding/" - } - ], "license": "MIT", - "dependencies": { - "anymatch": "~3.1.2", - "braces": "~3.0.2", - "glob-parent": "~5.1.2", - "is-binary-path": "~2.1.0", - "is-glob": "~4.0.1", - "normalize-path": "~3.0.0", - "readdirp": "~3.6.0" - }, "engines": { - "node": ">= 8.10.0" + "node": ">=12" }, - "optionalDependencies": { - "fsevents": "~2.3.2" + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/cipher-base": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/cipher-base/-/cipher-base-1.0.6.tgz", - "integrity": "sha512-3Ek9H3X6pj5TgenXYtNWdaBon1tgYCaebd+XPg0keyjEbEfkD4KkmAxkQ/i1vYvxdcT5nscLBfq9VJRmCBcFSw==", + "node_modules/@jest/core/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, + "license": "MIT", "dependencies": { - "inherits": "^2.0.4", - "safe-buffer": "^5.2.1" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" }, "engines": { - "node": ">= 0.10" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/clean-stack": { - "version": "2.2.0", + "node_modules/@jest/diff-sequences": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/@jest/diff-sequences/-/diff-sequences-30.0.1.tgz", + "integrity": "sha512-n5H8QLDJ47QqbCNn5SuFjCRDrOLEZ0h8vAHCK5RL9Ls7Xa8AQLa/YxAc9UjFqoEDM48muwtBGjtMY5cr0PLDCw==", "dev": true, "license": "MIT", "engines": { - "node": ">=6" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/cli": { - "version": "1.0.1", + "node_modules/@jest/environment": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-30.2.0.tgz", + "integrity": "sha512-/QPTL7OBJQ5ac09UDRa3EQes4gt1FTEG/8jZ/4v5IVzx+Cv7dLxlVIvfvSVRiiX2drWyXeBjkMSR8hvOWSog5g==", "dev": true, "license": "MIT", "dependencies": { - "exit": "0.1.2", - "glob": "^7.1.1" + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0" }, "engines": { - "node": ">=0.2.5" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/cliui": { - "version": "7.0.4", + "node_modules/@jest/expect": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-30.2.0.tgz", + "integrity": "sha512-V9yxQK5erfzx99Sf+7LbhBwNWEZ9eZay8qQ9+JSC0TrMR1pMDHLMY+BnVPacWU6Jamrh252/IKo4F1Xn/zfiqA==", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.0", - "wrap-ansi": "^7.0.0" + "expect": "30.2.0", + "jest-snapshot": "30.2.0" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "node_modules/@jest/expect-utils": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-29.7.0.tgz", + "integrity": "sha512-GlsNBWiFQFCVi9QVSx7f5AgMeLxe9YCCs5PuP2O2LdjDAA8Jh9eX7lA1Jq/xdXw3Wb3hyvlFNfZIfcRetSzYcA==", "dev": true, + "license": "MIT", "dependencies": { - "color-name": "1.1.3" + "jest-get-type": "^29.6.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", - "dev": true - }, - "node_modules/combine-source-map": { - "version": "0.8.0", + "node_modules/@jest/expect/node_modules/@jest/expect-utils": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-30.2.0.tgz", + "integrity": "sha512-1JnRfhqpD8HGpOmQp180Fo9Zt69zNtC+9lR+kT7NVL05tNXIi+QC8Csz7lfidMoVLPD3FnOtcmp0CEFnxExGEA==", "dev": true, "license": "MIT", "dependencies": { - "convert-source-map": "~1.1.0", - "inline-source-map": "~0.6.0", - "lodash.memoize": "~3.0.3", - "source-map": "~0.5.3" + "@jest/get-type": "30.1.0" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/commondir": { - "version": "1.0.1", - "dev": true, - "license": "MIT" - }, - "node_modules/concat-map": { - "version": "0.0.1", + "node_modules/@jest/expect/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, - "license": "MIT" + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } }, - "node_modules/concat-stream": { - "version": "1.6.2", + "node_modules/@jest/expect/node_modules/expect": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/expect/-/expect-30.2.0.tgz", + "integrity": "sha512-u/feCi0GPsI+988gU2FLcsHyAHTU0MX1Wg68NhAnN7z/+C5wqG+CY8J53N9ioe8RXgaoz0nBR/TYMf3AycUuPw==", "dev": true, - "engines": [ - "node >= 0.8" - ], "license": "MIT", "dependencies": { - "buffer-from": "^1.0.0", - "inherits": "^2.0.3", - "readable-stream": "^2.2.2", - "typedarray": "^0.0.6" + "@jest/expect-utils": "30.2.0", + "@jest/get-type": "30.1.0", + "jest-matcher-utils": "30.2.0", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/connect": { - "version": "3.7.0", + "node_modules/@jest/expect/node_modules/jest-diff": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-30.2.0.tgz", + "integrity": "sha512-dQHFo3Pt4/NLlG5z4PxZ/3yZTZ1C7s9hveiOj+GCN+uT109NC2QgsoVZsVOAvbJ3RgKkvyLGXZV9+piDpWbm6A==", "dev": true, "license": "MIT", "dependencies": { - "debug": "2.6.9", - "finalhandler": "1.1.2", - "parseurl": "~1.3.3", - "utils-merge": "1.0.1" + "@jest/diff-sequences": "30.0.1", + "@jest/get-type": "30.1.0", + "chalk": "^4.1.2", + "pretty-format": "30.2.0" }, "engines": { - "node": ">= 0.10.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/connect/node_modules/debug": { - "version": "2.6.9", + "node_modules/@jest/expect/node_modules/jest-matcher-utils": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-30.2.0.tgz", + "integrity": "sha512-dQ94Nq4dbzmUWkQ0ANAWS9tBRfqCrn0bV9AMYdOi/MHW726xn7eQmMeRTpX2ViC00bpNaWXq+7o4lIQ3AX13Hg==", "dev": true, "license": "MIT", "dependencies": { - "ms": "2.0.0" + "@jest/get-type": "30.1.0", + "chalk": "^4.1.2", + "jest-diff": "30.2.0", + "pretty-format": "30.2.0" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/connect/node_modules/ms": { - "version": "2.0.0", - "dev": true, - "license": "MIT" - }, - "node_modules/console-browserify": { - "version": "1.1.0", + "node_modules/@jest/expect/node_modules/jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, + "license": "MIT", "dependencies": { - "date-now": "^0.1.4" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/constants-browserify": { - "version": "1.0.0", - "dev": true, - "license": "MIT" - }, - "node_modules/content-type": { - "version": "1.0.5", + "node_modules/@jest/expect/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, "engines": { - "node": ">= 0.6" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/convert-source-map": { - "version": "1.1.3", - "dev": true, - "license": "MIT" - }, - "node_modules/cookie": { - "version": "0.7.2", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.7.2.tgz", - "integrity": "sha512-yki5XnKuf750l50uGTllt6kKILY4nQ1eNIQatoXEByZ5dWgnKqbnqmTrBE5B4N7lrMJKQ2ytWMiTO2o0v6Ew/w==", + "node_modules/@jest/expect/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, + "license": "MIT", "engines": { - "node": ">= 0.6" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/core-util-is": { - "version": "1.0.2", - "dev": true, - "license": "MIT" - }, - "node_modules/cors": { - "version": "2.8.5", - "resolved": "https://registry.npmjs.org/cors/-/cors-2.8.5.tgz", - "integrity": "sha512-KIHbLJqu73RGr/hnbrO9uBeixNGuvSQjul/jdFvS/KFSIH1hWVd1ng7zOHx+YrEfInLG7q4n6GHQ9cDtxv/P6g==", + "node_modules/@jest/expect/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, + "license": "MIT", "dependencies": { - "object-assign": "^4", - "vary": "^1" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" }, "engines": { - "node": ">= 0.10" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/create-ecdh": { - "version": "4.0.3", + "node_modules/@jest/fake-timers": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-30.2.0.tgz", + "integrity": "sha512-HI3tRLjRxAbBy0VO8dqqm7Hb2mIa8d5bg/NJkyQcOk7V118ObQML8RC5luTF/Zsg4474a+gDvhce7eTnP4GhYw==", "dev": true, "license": "MIT", "dependencies": { - "bn.js": "^4.1.0", - "elliptic": "^6.0.0" + "@jest/types": "30.2.0", + "@sinonjs/fake-timers": "^13.0.0", + "@types/node": "*", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/create-hash": { - "version": "1.2.0", + "node_modules/@jest/fake-timers/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, "license": "MIT", - "dependencies": { - "cipher-base": "^1.0.1", - "inherits": "^2.0.1", - "md5.js": "^1.3.4", - "ripemd160": "^2.0.1", - "sha.js": "^2.4.0" + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/create-hmac": { - "version": "1.1.7", + "node_modules/@jest/fake-timers/node_modules/jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, "license": "MIT", "dependencies": { - "cipher-base": "^1.0.3", - "create-hash": "^1.1.0", - "inherits": "^2.0.1", - "ripemd160": "^2.0.0", - "safe-buffer": "^5.0.1", - "sha.js": "^2.4.8" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/cross-spawn": { - "version": "7.0.3", + "node_modules/@jest/fake-timers/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", "dependencies": { - "path-key": "^3.1.0", - "shebang-command": "^2.0.0", - "which": "^2.0.1" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" }, "engines": { - "node": ">= 8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/cross-spawn/node_modules/which": { - "version": "2.0.2", + "node_modules/@jest/fake-timers/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, - "license": "ISC", - "dependencies": { - "isexe": "^2.0.0" - }, - "bin": { - "node-which": "bin/node-which" - }, + "license": "MIT", "engines": { - "node": ">= 8" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/crypto-browserify": { - "version": "3.12.0", + "node_modules/@jest/fake-timers/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, "license": "MIT", "dependencies": { - "browserify-cipher": "^1.0.0", - "browserify-sign": "^4.0.0", - "create-ecdh": "^4.0.0", - "create-hash": "^1.1.0", - "create-hmac": "^1.1.0", - "diffie-hellman": "^5.0.0", - "inherits": "^2.0.1", - "pbkdf2": "^3.0.3", - "public-encrypt": "^4.0.0", - "randombytes": "^2.0.0", - "randomfill": "^1.0.3" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" }, "engines": { - "node": "*" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/custom-event": { - "version": "1.0.1", + "node_modules/@jest/get-type": { + "version": "30.1.0", + "resolved": "https://registry.npmjs.org/@jest/get-type/-/get-type-30.1.0.tgz", + "integrity": "sha512-eMbZE2hUnx1WV0pmURZY9XoXPkUYjpc55mb0CrhtdWLtzMQPFvu/rZkTLZFTsdaVQa+Tr4eWAteqcUzoawq/uA==", "dev": true, - "license": "MIT" + "license": "MIT", + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } }, - "node_modules/dash-ast": { - "version": "1.0.0", + "node_modules/@jest/globals": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/globals/-/globals-30.2.0.tgz", + "integrity": "sha512-b63wmnKPaK+6ZZfpYhz9K61oybvbI1aMcIs80++JI1O1rR1vaxHUCNqo3ITu6NU0d4V34yZFoHMn/uoKr/Rwfw==", "dev": true, - "license": "Apache-2.0" + "license": "MIT", + "dependencies": { + "@jest/environment": "30.2.0", + "@jest/expect": "30.2.0", + "@jest/types": "30.2.0", + "jest-mock": "30.2.0" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } }, - "node_modules/date-format": { - "version": "4.0.14", + "node_modules/@jest/pattern": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/@jest/pattern/-/pattern-30.0.1.tgz", + "integrity": "sha512-gWp7NfQW27LaBQz3TITS8L7ZCQ0TLvtmI//4OwlQRx4rnWxcPNIYjxZpDcN4+UlGxgm3jS5QPz8IPTCkb59wZA==", "dev": true, "license": "MIT", + "dependencies": { + "@types/node": "*", + "jest-regex-util": "30.0.1" + }, "engines": { - "node": ">=4.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/date-now": { - "version": "0.1.4", - "dev": true - }, - "node_modules/debug": { - "version": "4.3.4", + "node_modules/@jest/reporters": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/reporters/-/reporters-30.2.0.tgz", + "integrity": "sha512-DRyW6baWPqKMa9CzeiBjHwjd8XeAyco2Vt8XbcLFjiwCOEKOvy82GJ8QQnJE9ofsxCMPjH4MfH8fCWIHHDKpAQ==", "dev": true, "license": "MIT", "dependencies": { - "ms": "2.1.2" + "@bcoe/v8-coverage": "^0.2.3", + "@jest/console": "30.2.0", + "@jest/test-result": "30.2.0", + "@jest/transform": "30.2.0", + "@jest/types": "30.2.0", + "@jridgewell/trace-mapping": "^0.3.25", + "@types/node": "*", + "chalk": "^4.1.2", + "collect-v8-coverage": "^1.0.2", + "exit-x": "^0.2.2", + "glob": "^10.3.10", + "graceful-fs": "^4.2.11", + "istanbul-lib-coverage": "^3.0.0", + "istanbul-lib-instrument": "^6.0.0", + "istanbul-lib-report": "^3.0.0", + "istanbul-lib-source-maps": "^5.0.0", + "istanbul-reports": "^3.1.3", + "jest-message-util": "30.2.0", + "jest-util": "30.2.0", + "jest-worker": "30.2.0", + "slash": "^3.0.0", + "string-length": "^4.0.2", + "v8-to-istanbul": "^9.0.1" }, "engines": { - "node": ">=6.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" }, "peerDependenciesMeta": { - "supports-color": { + "node-notifier": { "optional": true } } }, - "node_modules/decamelize": { - "version": "4.0.0", + "node_modules/@jest/reporters/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, "license": "MIT", "engines": { "node": ">=10" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/deep-eql": { - "version": "4.1.3", + "node_modules/@jest/reporters/node_modules/brace-expansion": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.2.tgz", + "integrity": "sha512-Jt0vHyM+jmUBqojB7E1NIYadt0vI0Qxjxd2TErW94wDz+E2LAm5vKMXXwg6ZZBTHPuUlDgQHKXvjGBdfcF1ZDQ==", "dev": true, "license": "MIT", "dependencies": { - "type-detect": "^4.0.0" - }, - "engines": { - "node": ">=6" + "balanced-match": "^1.0.0" } }, - "node_modules/deep-is": { - "version": "0.1.3", - "dev": true, - "license": "MIT" - }, - "node_modules/default-require-extensions": { - "version": "3.0.1", + "node_modules/@jest/reporters/node_modules/foreground-child": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.3.1.tgz", + "integrity": "sha512-gIXjKqtFuWEgzFRJA9WCQeSJLZDjgJUOMCMzxtvFq/37KojM1BFGufqsCy0r4qSQmYLsZYMeyRqzIWOMup03sw==", "dev": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "strip-bom": "^4.0.0" + "cross-spawn": "^7.0.6", + "signal-exit": "^4.0.1" }, "engines": { - "node": ">=8" + "node": ">=14" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/define-data-property": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz", - "integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==", + "node_modules/@jest/reporters/node_modules/glob": { + "version": "10.5.0", + "resolved": "https://registry.npmjs.org/glob/-/glob-10.5.0.tgz", + "integrity": "sha512-DfXN8DfhJ7NH3Oe7cFmu3NCu1wKbkReJ8TorzSAFbSKrlNaQSKfIzqYqVY8zlbs2NLBbWpRiU52GX2PbaBVNkg==", "dev": true, + "license": "ISC", "dependencies": { - "es-define-property": "^1.0.0", - "es-errors": "^1.3.0", - "gopd": "^1.0.1" + "foreground-child": "^3.1.0", + "jackspeak": "^3.1.2", + "minimatch": "^9.0.4", + "minipass": "^7.1.2", + "package-json-from-dist": "^1.0.0", + "path-scurry": "^1.11.1" }, - "engines": { - "node": ">= 0.4" + "bin": { + "glob": "dist/esm/bin.mjs" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/defined": { - "version": "1.0.0", - "dev": true, - "license": "MIT" - }, - "node_modules/depd": { - "version": "2.0.0", + "node_modules/@jest/reporters/node_modules/istanbul-lib-instrument": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-6.0.3.tgz", + "integrity": "sha512-Vtgk7L/R2JHyyGW07spoFlB8/lpjiOLTjMdms6AFMraYt3BaJauod/NGrfnVG/y4Ix1JEuMRPDPEj2ua+zz1/Q==", "dev": true, - "license": "MIT", + "license": "BSD-3-Clause", + "dependencies": { + "@babel/core": "^7.23.9", + "@babel/parser": "^7.23.9", + "@istanbuljs/schema": "^0.1.3", + "istanbul-lib-coverage": "^3.2.0", + "semver": "^7.5.4" + }, "engines": { - "node": ">= 0.8" + "node": ">=10" } }, - "node_modules/deps-sort": { - "version": "2.0.0", + "node_modules/@jest/reporters/node_modules/istanbul-lib-source-maps": { + "version": "5.0.6", + "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-5.0.6.tgz", + "integrity": "sha512-yg2d+Em4KizZC5niWhQaIomgf5WlL4vOOjZ5xGCmF8SnPE/mDWWXgvRExdcpCgh9lLRRa1/fSYp2ymmbJ1pI+A==", "dev": true, - "license": "MIT", + "license": "BSD-3-Clause", "dependencies": { - "JSONStream": "^1.0.3", - "shasum": "^1.0.0", - "subarg": "^1.0.0", - "through2": "^2.0.0" + "@jridgewell/trace-mapping": "^0.3.23", + "debug": "^4.1.1", + "istanbul-lib-coverage": "^3.0.0" }, - "bin": { - "deps-sort": "bin/cmd.js" + "engines": { + "node": ">=10" } }, - "node_modules/des.js": { - "version": "1.0.0", + "node_modules/@jest/reporters/node_modules/jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, "license": "MIT", "dependencies": { - "inherits": "^2.0.1", - "minimalistic-assert": "^1.0.0" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/destroy": { - "version": "1.2.0", + "node_modules/@jest/reporters/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, "engines": { - "node": ">= 0.8", - "npm": "1.2.8000 || >= 1.4.16" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/detective": { - "version": "5.2.0", + "node_modules/@jest/reporters/node_modules/minimatch": { + "version": "9.0.5", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.5.tgz", + "integrity": "sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==", "dev": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "acorn-node": "^1.6.1", - "defined": "^1.0.0", - "minimist": "^1.1.1" - }, - "bin": { - "detective": "bin/detective.js" + "brace-expansion": "^2.0.1" }, "engines": { - "node": ">=0.8.0" + "node": ">=16 || 14 >=14.17" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/di": { - "version": "0.0.1", - "dev": true, - "license": "MIT" - }, - "node_modules/diff": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/diff/-/diff-5.2.0.tgz", - "integrity": "sha512-uIFDxqpRZGZ6ThOk84hEfqWoHx2devRFvpTZcTHur85vImfaxUbTW9Ryh4CpCuDnToOP1CEtXKIgytHBPVff5A==", + "node_modules/@jest/reporters/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, - "license": "BSD-3-Clause", + "license": "MIT", "engines": { - "node": ">=0.3.1" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/diffie-hellman": { - "version": "5.0.3", + "node_modules/@jest/reporters/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, "license": "MIT", "dependencies": { - "bn.js": "^4.1.0", - "miller-rabin": "^4.0.0", - "randombytes": "^2.0.0" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/doctrine": { - "version": "3.0.0", + "node_modules/@jest/reporters/node_modules/signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", "dev": true, - "license": "Apache-2.0", - "dependencies": { - "esutils": "^2.0.2" - }, + "license": "ISC", "engines": { - "node": ">=6.0.0" + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/dom-serialize": { - "version": "2.2.1", + "node_modules/@jest/reporters/node_modules/string-length": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/string-length/-/string-length-4.0.2.tgz", + "integrity": "sha512-+l6rNN5fYHNhZZy41RXsYptCjA2Igmq4EG7kZAYFQI1E1VTXarr6ZPXBg6eq7Y6eK4FEhY6AJlyuFIb/v/S0VQ==", "dev": true, "license": "MIT", "dependencies": { - "custom-event": "~1.0.0", - "ent": "~2.2.0", - "extend": "^3.0.0", - "void-elements": "^2.0.0" + "char-regex": "^1.0.2", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=10" } }, - "node_modules/dom-serializer": { - "version": "0.2.1", + "node_modules/@jest/schemas": { + "version": "30.0.5", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", + "integrity": "sha512-DmdYgtezMkh3cpU8/1uyXakv3tJRcmcXxBOcO0tbaozPwpmh4YMsnWrQm9ZmZMfa5ocbxzbFk6O4bDPEc/iAnA==", "dev": true, "license": "MIT", "dependencies": { - "domelementtype": "^2.0.1", - "entities": "^2.0.0" + "@sinclair/typebox": "^0.34.0" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/dom-serializer/node_modules/domelementtype": { - "version": "2.0.1", - "dev": true, - "license": "BSD-2-Clause" - }, - "node_modules/dom-serializer/node_modules/entities": { - "version": "2.0.0", - "dev": true, - "license": "BSD-2-Clause" - }, - "node_modules/domain-browser": { - "version": "1.2.0", + "node_modules/@jest/snapshot-utils": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/snapshot-utils/-/snapshot-utils-30.2.0.tgz", + "integrity": "sha512-0aVxM3RH6DaiLcjj/b0KrIBZhSX1373Xci4l3cW5xiUWPctZ59zQ7jj4rqcJQ/Z8JuN/4wX3FpJSa3RssVvCug==", "dev": true, "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "natural-compare": "^1.4.0" + }, "engines": { - "node": ">=0.4", - "npm": ">=1.2" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/domelementtype": { - "version": "1.3.1", - "dev": true, - "license": "BSD-2-Clause" - }, - "node_modules/domhandler": { - "version": "2.3.0", + "node_modules/@jest/source-map": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/@jest/source-map/-/source-map-30.0.1.tgz", + "integrity": "sha512-MIRWMUUR3sdbP36oyNyhbThLHyJ2eEDClPCiHVbrYAe5g3CHRArIVpBw7cdSB5fr+ofSfIb2Tnsw8iEHL0PYQg==", "dev": true, + "license": "MIT", "dependencies": { - "domelementtype": "1" + "@jridgewell/trace-mapping": "^0.3.25", + "callsites": "^3.1.0", + "graceful-fs": "^4.2.11" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/domutils": { - "version": "1.5.1", + "node_modules/@jest/test-result": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/test-result/-/test-result-30.2.0.tgz", + "integrity": "sha512-RF+Z+0CCHkARz5HT9mcQCBulb1wgCP3FBvl9VFokMX27acKphwyQsNuWH3c+ojd1LeWBLoTYoxF0zm6S/66mjg==", "dev": true, + "license": "MIT", "dependencies": { - "dom-serializer": "0", - "domelementtype": "1" + "@jest/console": "30.2.0", + "@jest/types": "30.2.0", + "@types/istanbul-lib-coverage": "^2.0.6", + "collect-v8-coverage": "^1.0.2" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/dunder-proto": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz", - "integrity": "sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==", + "node_modules/@jest/test-sequencer": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/test-sequencer/-/test-sequencer-30.2.0.tgz", + "integrity": "sha512-wXKgU/lk8fKXMu/l5Hog1R61bL4q5GCdT6OJvdAFz1P+QrpoFuLU68eoKuVc4RbrTtNnTL5FByhWdLgOPSph+Q==", "dev": true, "license": "MIT", "dependencies": { - "call-bind-apply-helpers": "^1.0.1", - "es-errors": "^1.3.0", - "gopd": "^1.2.0" + "@jest/test-result": "30.2.0", + "graceful-fs": "^4.2.11", + "jest-haste-map": "30.2.0", + "slash": "^3.0.0" }, "engines": { - "node": ">= 0.4" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/duplexer2": { - "version": "0.1.4", + "node_modules/@jest/transform": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/transform/-/transform-30.2.0.tgz", + "integrity": "sha512-XsauDV82o5qXbhalKxD7p4TZYYdwcaEXC77PPD2HixEFF+6YGppjrAAQurTl2ECWcEomHBMMNS9AH3kcCFx8jA==", "dev": true, - "license": "BSD-3-Clause", + "license": "MIT", "dependencies": { - "readable-stream": "^2.0.2" + "@babel/core": "^7.27.4", + "@jest/types": "30.2.0", + "@jridgewell/trace-mapping": "^0.3.25", + "babel-plugin-istanbul": "^7.0.1", + "chalk": "^4.1.2", + "convert-source-map": "^2.0.0", + "fast-json-stable-stringify": "^2.1.0", + "graceful-fs": "^4.2.11", + "jest-haste-map": "30.2.0", + "jest-regex-util": "30.0.1", + "jest-util": "30.2.0", + "micromatch": "^4.0.8", + "pirates": "^4.0.7", + "slash": "^3.0.0", + "write-file-atomic": "^5.0.1" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/ee-first": { - "version": "1.1.1", + "node_modules/@jest/transform/node_modules/convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", "dev": true, "license": "MIT" }, - "node_modules/electron-to-chromium": { - "version": "1.4.317", - "dev": true, - "license": "ISC" - }, - "node_modules/elliptic": { - "version": "6.6.1", - "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.6.1.tgz", - "integrity": "sha512-RaddvvMatK2LJHqFJ+YA4WysVN5Ita9E35botqIYspQ4TkRAlCicdzKOjlyv/1Za5RyTNn7di//eEV0uTAfe3g==", + "node_modules/@jest/transform/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", "dependencies": { - "bn.js": "^4.11.9", - "brorand": "^1.1.0", - "hash.js": "^1.0.0", - "hmac-drbg": "^1.0.1", - "inherits": "^2.0.4", - "minimalistic-assert": "^1.0.1", - "minimalistic-crypto-utils": "^1.0.1" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/encodeurl": { - "version": "1.0.2", + "node_modules/@jest/transform/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, "license": "MIT", "engines": { - "node": ">= 0.8" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/engine.io": { - "version": "6.6.2", - "resolved": "https://registry.npmjs.org/engine.io/-/engine.io-6.6.2.tgz", - "integrity": "sha512-gmNvsYi9C8iErnZdVcJnvCpSKbWTt1E8+JZo8b+daLninywUWi5NQ5STSHZ9rFjFO7imNcvb8Pc5pe/wMR5xEw==", + "node_modules/@jest/transform/node_modules/signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", "dev": true, - "dependencies": { - "@types/cookie": "^0.4.1", - "@types/cors": "^2.8.12", - "@types/node": ">=10.0.0", - "accepts": "~1.3.4", - "base64id": "2.0.0", - "cookie": "~0.7.2", - "cors": "~2.8.5", - "debug": "~4.3.1", - "engine.io-parser": "~5.2.1", - "ws": "~8.17.1" - }, + "license": "ISC", "engines": { - "node": ">=10.2.0" + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/engine.io-parser": { - "version": "5.2.3", - "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.2.3.tgz", - "integrity": "sha512-HqD3yTBfnBxIrbnM1DoD6Pcq8NECnh8d4As1Qgh0z5Gg3jRRIqijury0CL3ghu/edArpUYiYqQiDUQBIs4np3Q==", + "node_modules/@jest/transform/node_modules/write-file-atomic": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-5.0.1.tgz", + "integrity": "sha512-+QU2zd6OTD8XWIJCbffaiQeH9U73qIqafo1x6V1snCWYGJf6cVE0cDR4D8xRzcEnfI21IFrUPzPGtcPf8AC+Rw==", "dev": true, + "license": "ISC", + "dependencies": { + "imurmurhash": "^0.1.4", + "signal-exit": "^4.0.1" + }, "engines": { - "node": ">=10.0.0" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/engine.io/node_modules/ws": { - "version": "8.17.1", - "resolved": "https://registry.npmjs.org/ws/-/ws-8.17.1.tgz", - "integrity": "sha512-6XQFvXTkbfUOZOKKILFG1PDK2NDQs4azKQl26T0YS5CxqWLgXajbPZ+h4gZekJyRqFU8pvnbAbbs/3TgRPy+GQ==", + "node_modules/@jest/types": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-30.2.0.tgz", + "integrity": "sha512-H9xg1/sfVvyfU7o3zMfBEjQ1gcsdeTMgqHoYdN79tuLqfTtuu7WckRA1R5whDwOzxaZAeMKTYWqP+WCAi0CHsg==", "dev": true, - "engines": { - "node": ">=10.0.0" - }, - "peerDependencies": { - "bufferutil": "^4.0.1", - "utf-8-validate": ">=5.0.2" + "license": "MIT", + "dependencies": { + "@jest/pattern": "30.0.1", + "@jest/schemas": "30.0.5", + "@types/istanbul-lib-coverage": "^2.0.6", + "@types/istanbul-reports": "^3.0.4", + "@types/node": "*", + "@types/yargs": "^17.0.33", + "chalk": "^4.1.2" }, - "peerDependenciesMeta": { - "bufferutil": { - "optional": true - }, - "utf-8-validate": { - "optional": true - } + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/ent": { - "version": "2.2.0", + "node_modules/@jridgewell/gen-mapping": { + "version": "0.3.13", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.13.tgz", + "integrity": "sha512-2kkt/7niJ6MgEPxF0bYdQ6etZaA+fQvDcLKckhy1yIQOzaoKjBBjSj63/aLVjYE3qhRt5dvM+uUyfCg6UKCBbA==", "dev": true, - "license": "MIT" + "license": "MIT", + "dependencies": { + "@jridgewell/sourcemap-codec": "^1.5.0", + "@jridgewell/trace-mapping": "^0.3.24" + } }, - "node_modules/entities": { - "version": "1.0.0", + "node_modules/@jridgewell/remapping": { + "version": "2.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/remapping/-/remapping-2.3.5.tgz", + "integrity": "sha512-LI9u/+laYG4Ds1TDKSJW2YPrIlcVYOwi2fUC6xB43lueCjgxV4lffOCZCtYFiH6TNOX+tQKXx97T4IKHbhyHEQ==", "dev": true, - "license": "BSD-like" + "license": "MIT", + "dependencies": { + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.24" + } }, - "node_modules/es-define-property": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.1.tgz", - "integrity": "sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==", + "node_modules/@jridgewell/resolve-uri": { + "version": "3.1.0", "dev": true, "license": "MIT", "engines": { - "node": ">= 0.4" + "node": ">=6.0.0" } }, - "node_modules/es-errors": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", - "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==", + "node_modules/@jridgewell/sourcemap-codec": { + "version": "1.5.5", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.5.tgz", + "integrity": "sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==", "dev": true, - "engines": { - "node": ">= 0.4" - } + "license": "MIT" }, - "node_modules/es-object-atoms": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.1.1.tgz", - "integrity": "sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA==", + "node_modules/@jridgewell/trace-mapping": { + "version": "0.3.31", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.31.tgz", + "integrity": "sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==", "dev": true, "license": "MIT", "dependencies": { - "es-errors": "^1.3.0" - }, - "engines": { - "node": ">= 0.4" + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" } }, - "node_modules/es6-error": { - "version": "4.1.1", + "node_modules/@napi-rs/wasm-runtime": { + "version": "0.2.12", + "resolved": "https://registry.npmjs.org/@napi-rs/wasm-runtime/-/wasm-runtime-0.2.12.tgz", + "integrity": "sha512-ZVWUcfwY4E/yPitQJl481FjFo3K22D6qF0DuFH6Y/nbnE11GY5uguDxZMGXPQ8WQ0128MXQD7TnfHyK4oWoIJQ==", "dev": true, - "license": "MIT" + "license": "MIT", + "optional": true, + "dependencies": { + "@emnapi/core": "^1.4.3", + "@emnapi/runtime": "^1.4.3", + "@tybys/wasm-util": "^0.10.0" + } }, - "node_modules/escalade": { - "version": "3.1.1", + "node_modules/@nodelib/fs.scandir": { + "version": "2.1.5", "dev": true, "license": "MIT", + "dependencies": { + "@nodelib/fs.stat": "2.0.5", + "run-parallel": "^1.1.9" + }, "engines": { - "node": ">=6" + "node": ">= 8" } }, - "node_modules/escape-html": { - "version": "1.0.3", - "dev": true, - "license": "MIT" - }, - "node_modules/escape-string-regexp": { - "version": "1.0.5", + "node_modules/@nodelib/fs.stat": { + "version": "2.0.5", "dev": true, "license": "MIT", "engines": { - "node": ">=0.8.0" + "node": ">= 8" } }, - "node_modules/eslint": { - "version": "8.35.0", + "node_modules/@nodelib/fs.walk": { + "version": "1.2.8", "dev": true, "license": "MIT", "dependencies": { - "@eslint/eslintrc": "^2.0.0", - "@eslint/js": "8.35.0", - "@humanwhocodes/config-array": "^0.11.8", - "@humanwhocodes/module-importer": "^1.0.1", - "@nodelib/fs.walk": "^1.2.8", - "ajv": "^6.10.0", - "chalk": "^4.0.0", - "cross-spawn": "^7.0.2", - "debug": "^4.3.2", - "doctrine": "^3.0.0", - "escape-string-regexp": "^4.0.0", - "eslint-scope": "^7.1.1", - "eslint-utils": "^3.0.0", - "eslint-visitor-keys": "^3.3.0", - "espree": "^9.4.0", - "esquery": "^1.4.2", - "esutils": "^2.0.2", - "fast-deep-equal": "^3.1.3", - "file-entry-cache": "^6.0.1", - "find-up": "^5.0.0", - "glob-parent": "^6.0.2", - "globals": "^13.19.0", - "grapheme-splitter": "^1.0.4", - "ignore": "^5.2.0", - "import-fresh": "^3.0.0", - "imurmurhash": "^0.1.4", - "is-glob": "^4.0.0", - "is-path-inside": "^3.0.3", - "js-sdsl": "^4.1.4", - "js-yaml": "^4.1.0", - "json-stable-stringify-without-jsonify": "^1.0.1", - "levn": "^0.4.1", - "lodash.merge": "^4.6.2", - "minimatch": "^3.1.2", - "natural-compare": "^1.4.0", - "optionator": "^0.9.1", - "regexpp": "^3.2.0", - "strip-ansi": "^6.0.1", - "strip-json-comments": "^3.1.0", - "text-table": "^0.2.0" - }, - "bin": { - "eslint": "bin/eslint.js" + "@nodelib/fs.scandir": "2.1.5", + "fastq": "^1.6.0" }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" + "node": ">= 8" } }, - "node_modules/eslint-scope": { - "version": "7.1.1", + "node_modules/@pkgjs/parseargs": { + "version": "0.11.0", + "resolved": "https://registry.npmjs.org/@pkgjs/parseargs/-/parseargs-0.11.0.tgz", + "integrity": "sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==", "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "esrecurse": "^4.3.0", - "estraverse": "^5.2.0" - }, + "license": "MIT", + "optional": true, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": ">=14" } }, - "node_modules/eslint-utils": { - "version": "3.0.0", + "node_modules/@pkgr/core": { + "version": "0.2.9", + "resolved": "https://registry.npmjs.org/@pkgr/core/-/core-0.2.9.tgz", + "integrity": "sha512-QNqXyfVS2wm9hweSYD2O7F0G06uurj9kZ96TRQE5Y9hU7+tgdZwIkbAKc5Ocy1HxEY2kuDQa6cQ1WRs/O5LFKA==", "dev": true, "license": "MIT", - "dependencies": { - "eslint-visitor-keys": "^2.0.0" - }, "engines": { - "node": "^10.0.0 || ^12.0.0 || >= 14.0.0" + "node": "^12.20.0 || ^14.18.0 || >=16.0.0" }, "funding": { - "url": "https://github.com/sponsors/mysticatea" - }, - "peerDependencies": { - "eslint": ">=5" + "url": "https://opencollective.com/pkgr" } }, - "node_modules/eslint-utils/node_modules/eslint-visitor-keys": { - "version": "2.1.0", + "node_modules/@sinclair/typebox": { + "version": "0.34.41", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.34.41.tgz", + "integrity": "sha512-6gS8pZzSXdyRHTIqoqSVknxolr1kzfy4/CeDnrzsVz8TTIWUbOBr6gnzOmTYJ3eXQNh4IYHIGi5aIL7sOZ2G/g==", "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=10" + "license": "MIT" + }, + "node_modules/@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "type-detect": "4.0.8" } }, - "node_modules/eslint-visitor-keys": { - "version": "3.3.0", + "node_modules/@sinonjs/fake-timers": { + "version": "13.0.5", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-13.0.5.tgz", + "integrity": "sha512-36/hTbH2uaWuGVERyC6da9YwGWnzUZXuPro/F2LfsdOsLnCojz/iSH8MxUt/FD2S5XBSVPhmArFUXcpCQ2Hkiw==", "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "license": "BSD-3-Clause", + "dependencies": { + "@sinonjs/commons": "^3.0.1" } }, - "node_modules/eslint/node_modules/ansi-styles": { - "version": "4.3.0", + "node_modules/@tybys/wasm-util": { + "version": "0.10.1", + "resolved": "https://registry.npmjs.org/@tybys/wasm-util/-/wasm-util-0.10.1.tgz", + "integrity": "sha512-9tTaPJLSiejZKx+Bmog4uSubteqTvFrVrURwkmHixBo0G4seD0zUxp98E1DzUBJxLQ3NPwXrGKDiVjwx/DpPsg==", "dev": true, "license": "MIT", + "optional": true, "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "tslib": "^2.4.0" } }, - "node_modules/eslint/node_modules/argparse": { - "version": "2.0.1", + "node_modules/@types/babel__core": { + "version": "7.20.5", + "resolved": "https://registry.npmjs.org/@types/babel__core/-/babel__core-7.20.5.tgz", + "integrity": "sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==", "dev": true, - "license": "Python-2.0" + "license": "MIT", + "dependencies": { + "@babel/parser": "^7.20.7", + "@babel/types": "^7.20.7", + "@types/babel__generator": "*", + "@types/babel__template": "*", + "@types/babel__traverse": "*" + } }, - "node_modules/eslint/node_modules/chalk": { - "version": "4.1.2", + "node_modules/@types/babel__generator": { + "version": "7.27.0", + "resolved": "https://registry.npmjs.org/@types/babel__generator/-/babel__generator-7.27.0.tgz", + "integrity": "sha512-ufFd2Xi92OAVPYsy+P4n7/U7e68fex0+Ee8gSG9KX7eo084CWiQ4sdxktvdl0bOPupXtVJPY19zk6EwWqUQ8lg==", "dev": true, "license": "MIT", "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "@babel/types": "^7.0.0" } }, - "node_modules/eslint/node_modules/color-convert": { - "version": "2.0.1", + "node_modules/@types/babel__template": { + "version": "7.4.4", + "resolved": "https://registry.npmjs.org/@types/babel__template/-/babel__template-7.4.4.tgz", + "integrity": "sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A==", "dev": true, "license": "MIT", "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" + "@babel/parser": "^7.1.0", + "@babel/types": "^7.0.0" } }, - "node_modules/eslint/node_modules/color-name": { - "version": "1.1.4", + "node_modules/@types/babel__traverse": { + "version": "7.28.0", + "resolved": "https://registry.npmjs.org/@types/babel__traverse/-/babel__traverse-7.28.0.tgz", + "integrity": "sha512-8PvcXf70gTDZBgt9ptxJ8elBeBjcLOAcOtoO/mPJjtji1+CdGbHgm77om1GrsPxsiE+uXIpNSK64UYaIwQXd4Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/types": "^7.28.2" + } + }, + "node_modules/@types/istanbul-lib-coverage": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", + "integrity": "sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w==", "dev": true, "license": "MIT" }, - "node_modules/eslint/node_modules/escape-string-regexp": { - "version": "4.0.0", + "node_modules/@types/istanbul-lib-report": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-report/-/istanbul-lib-report-3.0.3.tgz", + "integrity": "sha512-NQn7AHQnk/RSLOxrBbGyJM/aVQ+pjj5HCgasFxc0K/KhoATfQ/47AyUl15I2yBUpihjmas+a+VJBOqecrFH+uA==", "dev": true, "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "dependencies": { + "@types/istanbul-lib-coverage": "*" } }, - "node_modules/eslint/node_modules/glob-parent": { - "version": "6.0.2", + "node_modules/@types/istanbul-reports": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz", + "integrity": "sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "is-glob": "^4.0.3" - }, - "engines": { - "node": ">=10.13.0" + "@types/istanbul-lib-report": "*" } }, - "node_modules/eslint/node_modules/has-flag": { - "version": "4.0.0", + "node_modules/@types/jest": { + "version": "29.5.14", + "resolved": "https://registry.npmjs.org/@types/jest/-/jest-29.5.14.tgz", + "integrity": "sha512-ZN+4sdnLUbo8EVvVc2ao0GFW6oVrQRPn4K2lglySj7APvSrgzxHiNNK99us4WDMi57xxA2yggblIAMNhXOotLQ==", "dev": true, "license": "MIT", - "engines": { - "node": ">=8" + "dependencies": { + "expect": "^29.0.0", + "pretty-format": "^29.0.0" } }, - "node_modules/eslint/node_modules/js-yaml": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.1.tgz", - "integrity": "sha512-qQKT4zQxXl8lLwBtHMWwaTcGfFOZviOJet3Oy/xmGk2gZH677CJM9EvtfdSkgWcATZhj/55JZ0rmy3myCT5lsA==", + "node_modules/@types/node": { + "version": "20.19.25", + "resolved": "https://registry.npmjs.org/@types/node/-/node-20.19.25.tgz", + "integrity": "sha512-ZsJzA5thDQMSQO788d7IocwwQbI8B5OPzmqNvpf3NY/+MHDAS759Wo0gd2WQeXYt5AAAQjzcrTVC6SKCuYgoCQ==", "dev": true, + "license": "MIT", "dependencies": { - "argparse": "^2.0.1" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" + "undici-types": "~6.21.0" } }, - "node_modules/eslint/node_modules/levn": { - "version": "0.4.1", + "node_modules/@types/stack-utils": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.3.tgz", + "integrity": "sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/yargs": { + "version": "17.0.35", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.35.tgz", + "integrity": "sha512-qUHkeCyQFxMXg79wQfTtfndEC+N9ZZg76HJftDJp+qH2tV7Gj4OJi7l+PiWwJ+pWtW8GwSmqsDj/oymhrTWXjg==", "dev": true, "license": "MIT", "dependencies": { - "prelude-ls": "^1.2.1", - "type-check": "~0.4.0" + "@types/yargs-parser": "*" + } + }, + "node_modules/@types/yargs-parser": { + "version": "21.0.3", + "resolved": "https://registry.npmjs.org/@types/yargs-parser/-/yargs-parser-21.0.3.tgz", + "integrity": "sha512-I4q9QU9MQv4oEOz4tAHJtNz1cwuLxn2F3xcc2iV5WdqLPpUnj30aUuxt1mAxYTG+oe8CZMV/+6rU4S4gRDzqtQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/@ungap/structured-clone": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/@ungap/structured-clone/-/structured-clone-1.3.0.tgz", + "integrity": "sha512-WmoN8qaIAo7WTYWbAZuG8PYEhn5fkz7dZrqTBZ7dtt//lL2Gwms1IcnQ5yHqjDfX8Ft5j4YzDM23f87zBfDe9g==", + "dev": true, + "license": "ISC" + }, + "node_modules/@unrs/resolver-binding-android-arm-eabi": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-android-arm-eabi/-/resolver-binding-android-arm-eabi-1.11.1.tgz", + "integrity": "sha512-ppLRUgHVaGRWUx0R0Ut06Mjo9gBaBkg3v/8AxusGLhsIotbBLuRk51rAzqLC8gq6NyyAojEXglNjzf6R948DNw==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@unrs/resolver-binding-android-arm64": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-android-arm64/-/resolver-binding-android-arm64-1.11.1.tgz", + "integrity": "sha512-lCxkVtb4wp1v+EoN+HjIG9cIIzPkX5OtM03pQYkG+U5O/wL53LC4QbIeazgiKqluGeVEeBlZahHalCaBvU1a2g==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@unrs/resolver-binding-darwin-arm64": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-darwin-arm64/-/resolver-binding-darwin-arm64-1.11.1.tgz", + "integrity": "sha512-gPVA1UjRu1Y/IsB/dQEsp2V1pm44Of6+LWvbLc9SDk1c2KhhDRDBUkQCYVWe6f26uJb3fOK8saWMgtX8IrMk3g==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@unrs/resolver-binding-darwin-x64": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-darwin-x64/-/resolver-binding-darwin-x64-1.11.1.tgz", + "integrity": "sha512-cFzP7rWKd3lZaCsDze07QX1SC24lO8mPty9vdP+YVa3MGdVgPmFc59317b2ioXtgCMKGiCLxJ4HQs62oz6GfRQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@unrs/resolver-binding-freebsd-x64": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-freebsd-x64/-/resolver-binding-freebsd-x64-1.11.1.tgz", + "integrity": "sha512-fqtGgak3zX4DCB6PFpsH5+Kmt/8CIi4Bry4rb1ho6Av2QHTREM+47y282Uqiu3ZRF5IQioJQ5qWRV6jduA+iGw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ] + }, + "node_modules/@unrs/resolver-binding-linux-arm-gnueabihf": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm-gnueabihf/-/resolver-binding-linux-arm-gnueabihf-1.11.1.tgz", + "integrity": "sha512-u92mvlcYtp9MRKmP+ZvMmtPN34+/3lMHlyMj7wXJDeXxuM0Vgzz0+PPJNsro1m3IZPYChIkn944wW8TYgGKFHw==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@unrs/resolver-binding-linux-arm-musleabihf": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm-musleabihf/-/resolver-binding-linux-arm-musleabihf-1.11.1.tgz", + "integrity": "sha512-cINaoY2z7LVCrfHkIcmvj7osTOtm6VVT16b5oQdS4beibX2SYBwgYLmqhBjA1t51CarSaBuX5YNsWLjsqfW5Cw==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@unrs/resolver-binding-linux-arm64-gnu": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm64-gnu/-/resolver-binding-linux-arm64-gnu-1.11.1.tgz", + "integrity": "sha512-34gw7PjDGB9JgePJEmhEqBhWvCiiWCuXsL9hYphDF7crW7UgI05gyBAi6MF58uGcMOiOqSJ2ybEeCvHcq0BCmQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@unrs/resolver-binding-linux-arm64-musl": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm64-musl/-/resolver-binding-linux-arm64-musl-1.11.1.tgz", + "integrity": "sha512-RyMIx6Uf53hhOtJDIamSbTskA99sPHS96wxVE/bJtePJJtpdKGXO1wY90oRdXuYOGOTuqjT8ACccMc4K6QmT3w==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@unrs/resolver-binding-linux-ppc64-gnu": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-ppc64-gnu/-/resolver-binding-linux-ppc64-gnu-1.11.1.tgz", + "integrity": "sha512-D8Vae74A4/a+mZH0FbOkFJL9DSK2R6TFPC9M+jCWYia/q2einCubX10pecpDiTmkJVUH+y8K3BZClycD8nCShA==", + "cpu": [ + "ppc64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@unrs/resolver-binding-linux-riscv64-gnu": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-riscv64-gnu/-/resolver-binding-linux-riscv64-gnu-1.11.1.tgz", + "integrity": "sha512-frxL4OrzOWVVsOc96+V3aqTIQl1O2TjgExV4EKgRY09AJ9leZpEg8Ak9phadbuX0BA4k8U5qtvMSQQGGmaJqcQ==", + "cpu": [ + "riscv64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@unrs/resolver-binding-linux-riscv64-musl": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-riscv64-musl/-/resolver-binding-linux-riscv64-musl-1.11.1.tgz", + "integrity": "sha512-mJ5vuDaIZ+l/acv01sHoXfpnyrNKOk/3aDoEdLO/Xtn9HuZlDD6jKxHlkN8ZhWyLJsRBxfv9GYM2utQ1SChKew==", + "cpu": [ + "riscv64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@unrs/resolver-binding-linux-s390x-gnu": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-s390x-gnu/-/resolver-binding-linux-s390x-gnu-1.11.1.tgz", + "integrity": "sha512-kELo8ebBVtb9sA7rMe1Cph4QHreByhaZ2QEADd9NzIQsYNQpt9UkM9iqr2lhGr5afh885d/cB5QeTXSbZHTYPg==", + "cpu": [ + "s390x" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@unrs/resolver-binding-linux-x64-gnu": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-x64-gnu/-/resolver-binding-linux-x64-gnu-1.11.1.tgz", + "integrity": "sha512-C3ZAHugKgovV5YvAMsxhq0gtXuwESUKc5MhEtjBpLoHPLYM+iuwSj3lflFwK3DPm68660rZ7G8BMcwSro7hD5w==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@unrs/resolver-binding-linux-x64-musl": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-x64-musl/-/resolver-binding-linux-x64-musl-1.11.1.tgz", + "integrity": "sha512-rV0YSoyhK2nZ4vEswT/QwqzqQXw5I6CjoaYMOX0TqBlWhojUf8P94mvI7nuJTeaCkkds3QE4+zS8Ko+GdXuZtA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@unrs/resolver-binding-wasm32-wasi": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-wasm32-wasi/-/resolver-binding-wasm32-wasi-1.11.1.tgz", + "integrity": "sha512-5u4RkfxJm+Ng7IWgkzi3qrFOvLvQYnPBmjmZQ8+szTK/b31fQCnleNl1GgEt7nIsZRIf5PLhPwT0WM+q45x/UQ==", + "cpu": [ + "wasm32" + ], + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "@napi-rs/wasm-runtime": "^0.2.11" }, "engines": { - "node": ">= 0.8.0" + "node": ">=14.0.0" } }, - "node_modules/eslint/node_modules/minimatch": { - "version": "3.1.2", + "node_modules/@unrs/resolver-binding-win32-arm64-msvc": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-win32-arm64-msvc/-/resolver-binding-win32-arm64-msvc-1.11.1.tgz", + "integrity": "sha512-nRcz5Il4ln0kMhfL8S3hLkxI85BXs3o8EYoattsJNdsX4YUU89iOkVn7g0VHSRxFuVMdM4Q1jEpIId1Ihim/Uw==", + "cpu": [ + "arm64" + ], "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^1.1.7" + "license": "MIT", + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@unrs/resolver-binding-win32-ia32-msvc": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-win32-ia32-msvc/-/resolver-binding-win32-ia32-msvc-1.11.1.tgz", + "integrity": "sha512-DCEI6t5i1NmAZp6pFonpD5m7i6aFrpofcp4LA2i8IIq60Jyo28hamKBxNrZcyOwVOZkgsRp9O2sXWBWP8MnvIQ==", + "cpu": [ + "ia32" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@unrs/resolver-binding-win32-x64-msvc": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-win32-x64-msvc/-/resolver-binding-win32-x64-msvc-1.11.1.tgz", + "integrity": "sha512-lrW200hZdbfRtztbygyaq/6jP6AKE8qQN2KvPcJ+x7wiD038YtnYtZ82IMNJ69GJibV7bwL3y9FgK+5w/pYt6g==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/acorn": { + "version": "7.4.1", + "dev": true, + "license": "MIT", + "peer": true, + "bin": { + "acorn": "bin/acorn" }, "engines": { - "node": "*" + "node": ">=0.4.0" } }, - "node_modules/eslint/node_modules/optionator": { - "version": "0.9.1", + "node_modules/acorn-jsx": { + "version": "5.3.2", + "dev": true, + "license": "MIT", + "peerDependencies": { + "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" + } + }, + "node_modules/ajv": { + "version": "6.12.6", "dev": true, "license": "MIT", "dependencies": { - "deep-is": "^0.1.3", - "fast-levenshtein": "^2.0.6", - "levn": "^0.4.1", - "prelude-ls": "^1.2.1", - "type-check": "^0.4.0", - "word-wrap": "^1.2.3" + "fast-deep-equal": "^3.1.1", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.4.1", + "uri-js": "^4.2.2" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" + } + }, + "node_modules/ansi-escapes": { + "version": "4.3.2", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", + "integrity": "sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "type-fest": "^0.21.3" }, "engines": { - "node": ">= 0.8.0" + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/eslint/node_modules/prelude-ls": { - "version": "1.2.1", + "node_modules/ansi-escapes/node_modules/type-fest": { + "version": "0.21.3", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.21.3.tgz", + "integrity": "sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==", + "dev": true, + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/ansi-regex": { + "version": "5.0.1", "dev": true, "license": "MIT", "engines": { - "node": ">= 0.8.0" + "node": ">=8" } }, - "node_modules/eslint/node_modules/supports-color": { - "version": "7.2.0", + "node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, "license": "MIT", "dependencies": { - "has-flag": "^4.0.0" + "color-convert": "^2.0.1" }, "engines": { "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/eslint/node_modules/type-check": { - "version": "0.4.0", + "node_modules/anymatch": { + "version": "3.1.3", "dev": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "prelude-ls": "^1.2.1" + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" }, "engines": { - "node": ">= 0.8.0" + "node": ">= 8" } }, - "node_modules/espree": { - "version": "9.4.1", + "node_modules/argparse": { + "version": "1.0.10", "dev": true, - "license": "BSD-2-Clause", + "license": "MIT", "dependencies": { - "acorn": "^8.8.0", - "acorn-jsx": "^5.3.2", - "eslint-visitor-keys": "^3.3.0" + "sprintf-js": "~1.0.2" + } + }, + "node_modules/babel-jest": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/babel-jest/-/babel-jest-30.2.0.tgz", + "integrity": "sha512-0YiBEOxWqKkSQWL9nNGGEgndoeL0ZpWrbLMNL5u/Kaxrli3Eaxlt3ZtIDktEvXt4L/R9r3ODr2zKwGM/2BjxVw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/transform": "30.2.0", + "@types/babel__core": "^7.20.5", + "babel-plugin-istanbul": "^7.0.1", + "babel-preset-jest": "30.2.0", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "slash": "^3.0.0" }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" }, - "funding": { - "url": "https://opencollective.com/eslint" + "peerDependencies": { + "@babel/core": "^7.11.0 || ^8.0.0-0" } }, - "node_modules/espree/node_modules/acorn": { - "version": "8.8.2", + "node_modules/babel-plugin-istanbul": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-7.0.1.tgz", + "integrity": "sha512-D8Z6Qm8jCvVXtIRkBnqNHX0zJ37rQcFJ9u8WOS6tkYOsRdHBzypCstaxWiu5ZIlqQtviRYbgnRLSoCEvjqcqbA==", "dev": true, - "license": "MIT", - "bin": { - "acorn": "bin/acorn" + "license": "BSD-3-Clause", + "workspaces": [ + "test/babel-8" + ], + "dependencies": { + "@babel/helper-plugin-utils": "^7.0.0", + "@istanbuljs/load-nyc-config": "^1.0.0", + "@istanbuljs/schema": "^0.1.3", + "istanbul-lib-instrument": "^6.0.2", + "test-exclude": "^6.0.0" }, "engines": { - "node": ">=0.4.0" + "node": ">=12" } }, - "node_modules/esprima": { - "version": "4.0.1", + "node_modules/babel-plugin-istanbul/node_modules/istanbul-lib-instrument": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-6.0.3.tgz", + "integrity": "sha512-Vtgk7L/R2JHyyGW07spoFlB8/lpjiOLTjMdms6AFMraYt3BaJauod/NGrfnVG/y4Ix1JEuMRPDPEj2ua+zz1/Q==", "dev": true, - "license": "BSD-2-Clause", - "bin": { - "esparse": "bin/esparse.js", - "esvalidate": "bin/esvalidate.js" + "license": "BSD-3-Clause", + "dependencies": { + "@babel/core": "^7.23.9", + "@babel/parser": "^7.23.9", + "@istanbuljs/schema": "^0.1.3", + "istanbul-lib-coverage": "^3.2.0", + "semver": "^7.5.4" }, "engines": { - "node": ">=4" + "node": ">=10" } }, - "node_modules/esquery": { - "version": "1.4.2", + "node_modules/babel-plugin-jest-hoist": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-30.2.0.tgz", + "integrity": "sha512-ftzhzSGMUnOzcCXd6WHdBGMyuwy15Wnn0iyyWGKgBDLxf9/s5ABuraCSpBX2uG0jUg4rqJnxsLc5+oYBqoxVaA==", "dev": true, - "license": "BSD-3-Clause", + "license": "MIT", "dependencies": { - "estraverse": "^5.1.0" + "@types/babel__core": "^7.20.5" }, "engines": { - "node": ">=0.10" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/esrecurse": { - "version": "4.3.0", + "node_modules/babel-preset-current-node-syntax": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/babel-preset-current-node-syntax/-/babel-preset-current-node-syntax-1.2.0.tgz", + "integrity": "sha512-E/VlAEzRrsLEb2+dv8yp3bo4scof3l9nR4lrld+Iy5NyVqgVYUJnDAmunkhPMisRI32Qc4iRiz425d8vM++2fg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/plugin-syntax-async-generators": "^7.8.4", + "@babel/plugin-syntax-bigint": "^7.8.3", + "@babel/plugin-syntax-class-properties": "^7.12.13", + "@babel/plugin-syntax-class-static-block": "^7.14.5", + "@babel/plugin-syntax-import-attributes": "^7.24.7", + "@babel/plugin-syntax-import-meta": "^7.10.4", + "@babel/plugin-syntax-json-strings": "^7.8.3", + "@babel/plugin-syntax-logical-assignment-operators": "^7.10.4", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3", + "@babel/plugin-syntax-numeric-separator": "^7.10.4", + "@babel/plugin-syntax-object-rest-spread": "^7.8.3", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.3", + "@babel/plugin-syntax-optional-chaining": "^7.8.3", + "@babel/plugin-syntax-private-property-in-object": "^7.14.5", + "@babel/plugin-syntax-top-level-await": "^7.14.5" + }, + "peerDependencies": { + "@babel/core": "^7.0.0 || ^8.0.0-0" + } + }, + "node_modules/babel-preset-jest": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/babel-preset-jest/-/babel-preset-jest-30.2.0.tgz", + "integrity": "sha512-US4Z3NOieAQumwFnYdUWKvUKh8+YSnS/gB3t6YBiz0bskpu7Pine8pPCheNxlPEW4wnUkma2a94YuW2q3guvCQ==", "dev": true, - "license": "BSD-2-Clause", + "license": "MIT", "dependencies": { - "estraverse": "^5.2.0" + "babel-plugin-jest-hoist": "30.2.0", + "babel-preset-current-node-syntax": "^1.2.0" }, "engines": { - "node": ">=4.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + }, + "peerDependencies": { + "@babel/core": "^7.11.0 || ^8.0.0-beta.1" } }, - "node_modules/estraverse": { - "version": "5.3.0", + "node_modules/balanced-match": { + "version": "1.0.0", "dev": true, - "license": "BSD-2-Clause", + "license": "MIT" + }, + "node_modules/baseline-browser-mapping": { + "version": "2.8.31", + "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.8.31.tgz", + "integrity": "sha512-a28v2eWrrRWPpJSzxc+mKwm0ZtVx/G8SepdQZDArnXYU/XS+IF6mp8aB/4E+hH1tyGCoDo3KlUCdlSxGDsRkAw==", + "dev": true, + "license": "Apache-2.0", + "bin": { + "baseline-browser-mapping": "dist/cli.js" + } + }, + "node_modules/benchmark": { + "version": "2.1.4", + "dev": true, + "license": "MIT", + "dependencies": { + "lodash": "^4.17.4", + "platform": "^1.3.3" + } + }, + "node_modules/brace-expansion": { + "version": "1.1.11", + "dev": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/braces": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", + "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", + "dev": true, + "dependencies": { + "fill-range": "^7.1.1" + }, "engines": { - "node": ">=4.0" + "node": ">=8" } }, - "node_modules/esutils": { - "version": "2.0.3", + "node_modules/browserslist": { + "version": "4.28.0", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.28.0.tgz", + "integrity": "sha512-tbydkR/CxfMwelN0vwdP/pLkDwyAASZ+VfWm4EOwlB6SWhx1sYnWLqo8N5j0rAzPfzfRaxt0mM/4wPU/Su84RQ==", "dev": true, - "license": "BSD-2-Clause", + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "dependencies": { + "baseline-browser-mapping": "^2.8.25", + "caniuse-lite": "^1.0.30001754", + "electron-to-chromium": "^1.5.249", + "node-releases": "^2.0.27", + "update-browserslist-db": "^1.1.4" + }, + "bin": { + "browserslist": "cli.js" + }, "engines": { - "node": ">=0.10.0" + "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" } }, - "node_modules/eventemitter3": { - "version": "4.0.0", + "node_modules/bser": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/bser/-/bser-2.1.1.tgz", + "integrity": "sha512-gQxTNE/GAfIIrmHLUE3oJyp5FO6HRBfhjnw4/wMmA63ZGDJnWBmgY/lyQBpnDUkGmAhbSe39tx2d/iTOAfglwQ==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "node-int64": "^0.4.0" + } + }, + "node_modules/buffer-from": { + "version": "1.1.1", "dev": true, "license": "MIT" }, - "node_modules/events": { - "version": "2.1.0", + "node_modules/callsites": { + "version": "3.1.0", "dev": true, "license": "MIT", "engines": { - "node": ">=0.4.x" + "node": ">=6" } }, - "node_modules/evp_bytestokey": { - "version": "1.0.3", + "node_modules/camelcase": { + "version": "6.3.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/caniuse-lite": { + "version": "1.0.30001757", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001757.tgz", + "integrity": "sha512-r0nnL/I28Zi/yjk1el6ilj27tKcdjLsNqAOZr0yVjWPrSQyHgKI2INaEWw21bAQSv2LXRt1XuCS/GomNpWOxsQ==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/caniuse-lite" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "CC-BY-4.0" + }, + "node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, "license": "MIT", "dependencies": { - "md5.js": "^1.3.4", - "safe-buffer": "^5.1.1" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/exit": { - "version": "0.1.2", + "node_modules/char-regex": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/char-regex/-/char-regex-1.0.2.tgz", + "integrity": "sha512-kWWXztvZ5SBQV+eRgKFeh8q5sLuZY2+8WUIzlxWVTg+oGwY14qylx1KbKzHd8P6ZYkAg0xyIDU9JMHhyJMZ1jw==", "dev": true, + "license": "MIT", "engines": { - "node": ">= 0.8.0" + "node": ">=10" } }, - "node_modules/extend": { - "version": "3.0.2", + "node_modules/ci-info": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", + "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", "dev": true, - "license": "MIT" + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/sibiraj-s" + } + ], + "license": "MIT", + "engines": { + "node": ">=8" + } }, - "node_modules/fast-deep-equal": { - "version": "3.1.3", + "node_modules/cjs-module-lexer": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/cjs-module-lexer/-/cjs-module-lexer-2.1.1.tgz", + "integrity": "sha512-+CmxIZ/L2vNcEfvNtLdU0ZQ6mbq3FZnwAP2PPTiKP+1QOoKwlKlPgb8UKV0Dds7QVaMnHm+FwSft2VB0s/SLjQ==", "dev": true, "license": "MIT" }, - "node_modules/fast-json-stable-stringify": { - "version": "2.1.0", + "node_modules/co": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/co/-/co-4.6.0.tgz", + "integrity": "sha512-QVb0dM5HvG+uaxitm8wONl7jltx8dqhfU33DcqtOZcLSVIKSDDLDi7+0LbAKiyI8hD9u42m2YxXSkMGWThaecQ==", + "dev": true, + "license": "MIT", + "engines": { + "iojs": ">= 1.0.0", + "node": ">= 0.12.0" + } + }, + "node_modules/collect-v8-coverage": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/collect-v8-coverage/-/collect-v8-coverage-1.0.3.tgz", + "integrity": "sha512-1L5aqIkwPfiodaMgQunkF1zRhNqifHBmtbbbxcr6yVxxBnliw4TDOW6NxpO8DJLgJ16OT+Y4ztZqP6p/FtXnAw==", "dev": true, "license": "MIT" }, - "node_modules/fast-levenshtein": { - "version": "2.0.6", + "node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true, "license": "MIT" }, - "node_modules/fastq": { - "version": "1.15.0", + "node_modules/concat-map": { + "version": "0.0.1", "dev": true, - "license": "ISC", - "dependencies": { - "reusify": "^1.0.4" - } + "license": "MIT" }, - "node_modules/file-entry-cache": { - "version": "6.0.1", + "node_modules/cross-spawn": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz", + "integrity": "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==", "dev": true, "license": "MIT", "dependencies": { - "flat-cache": "^3.0.4" + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" }, "engines": { - "node": "^10.12.0 || >=12.0.0" + "node": ">= 8" } }, - "node_modules/fill-range": { - "version": "7.1.1", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", - "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", + "node_modules/cross-spawn/node_modules/which": { + "version": "2.0.2", "dev": true, + "license": "ISC", "dependencies": { - "to-regex-range": "^5.0.1" + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" }, "engines": { - "node": ">=8" + "node": ">= 8" } }, - "node_modules/finalhandler": { - "version": "1.1.2", + "node_modules/debug": { + "version": "4.3.4", "dev": true, "license": "MIT", "dependencies": { - "debug": "2.6.9", - "encodeurl": "~1.0.2", - "escape-html": "~1.0.3", - "on-finished": "~2.3.0", - "parseurl": "~1.3.3", - "statuses": "~1.5.0", - "unpipe": "~1.0.0" + "ms": "2.1.2" }, "engines": { - "node": ">= 0.8" + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } } }, - "node_modules/finalhandler/node_modules/debug": { - "version": "2.6.9", + "node_modules/dedent": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/dedent/-/dedent-1.7.0.tgz", + "integrity": "sha512-HGFtf8yhuhGhqO07SV79tRp+br4MnbdjeVxotpn1QBl30pcLLCQjX5b2295ll0fv8RKDKsmWYrl05usHM9CewQ==", "dev": true, "license": "MIT", - "dependencies": { - "ms": "2.0.0" + "peerDependencies": { + "babel-plugin-macros": "^3.1.0" + }, + "peerDependenciesMeta": { + "babel-plugin-macros": { + "optional": true + } } }, - "node_modules/finalhandler/node_modules/ms": { - "version": "2.0.0", + "node_modules/deep-is": { + "version": "0.1.3", "dev": true, "license": "MIT" }, - "node_modules/find-cache-dir": { - "version": "3.3.2", + "node_modules/deepmerge": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.3.1.tgz", + "integrity": "sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A==", "dev": true, "license": "MIT", - "dependencies": { - "commondir": "^1.0.1", - "make-dir": "^3.0.2", - "pkg-dir": "^4.1.0" - }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/avajs/find-cache-dir?sponsor=1" + "node": ">=0.10.0" } }, - "node_modules/find-up": { - "version": "5.0.0", + "node_modules/detect-newline": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/detect-newline/-/detect-newline-3.1.0.tgz", + "integrity": "sha512-TLz+x/vEXm/Y7P7wn1EJFNLxYpUD4TgMosxY6fAVJUnJMbupHBOncxyWUG9OpTaH9EBD7uFI5LfEgmMOc54DsA==", "dev": true, "license": "MIT", - "dependencies": { - "locate-path": "^6.0.0", - "path-exists": "^4.0.0" - }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "node": ">=8" } }, - "node_modules/flat": { - "version": "5.0.2", + "node_modules/diff-sequences": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/diff-sequences/-/diff-sequences-29.6.3.tgz", + "integrity": "sha512-EjePK1srD3P08o2j4f0ExnylqRs5B9tJjcp9t1krH2qRi8CCdsYfwe9JgSLurFBWwq4uOlipzfk5fHNvwFKr8Q==", "dev": true, - "license": "BSD-3-Clause", - "bin": { - "flat": "cli.js" + "license": "MIT", + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/flat-cache": { - "version": "3.0.4", + "node_modules/doctrine": { + "version": "3.0.0", "dev": true, - "license": "MIT", + "license": "Apache-2.0", "dependencies": { - "flatted": "^3.1.0", - "rimraf": "^3.0.2" + "esutils": "^2.0.2" }, "engines": { - "node": "^10.12.0 || >=12.0.0" + "node": ">=6.0.0" } }, - "node_modules/flatted": { - "version": "3.2.7", + "node_modules/eastasianwidth": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/eastasianwidth/-/eastasianwidth-0.2.0.tgz", + "integrity": "sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==", + "dev": true, + "license": "MIT" + }, + "node_modules/electron-to-chromium": { + "version": "1.5.262", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.262.tgz", + "integrity": "sha512-NlAsMteRHek05jRUxUR0a5jpjYq9ykk6+kO0yRaMi5moe7u0fVIOeQ3Y30A8dIiWFBNUoQGi1ljb1i5VtS9WQQ==", "dev": true, "license": "ISC" }, - "node_modules/follow-redirects": { - "version": "1.15.6", - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.6.tgz", - "integrity": "sha512-wWN62YITEaOpSK584EZXJafH1AGpO8RVgElfkuXbTOrPX4fIfOyEpW/CsiNd8JdYrAoOvafRTOEnvsO++qCqFA==", + "node_modules/emittery": { + "version": "0.13.1", + "resolved": "https://registry.npmjs.org/emittery/-/emittery-0.13.1.tgz", + "integrity": "sha512-DeWwawk6r5yR9jFgnDKYt4sLS0LmHJJi3ZOnb5/JdbYwj3nW+FxQnHIjhBKz8YLC7oRNPVM9NQ47I3CVx34eqQ==", "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://github.com/sponsors/RubenVerborgh" - } - ], + "license": "MIT", "engines": { - "node": ">=4.0" + "node": ">=12" }, - "peerDependenciesMeta": { - "debug": { - "optional": true - } + "funding": { + "url": "https://github.com/sindresorhus/emittery?sponsor=1" } }, - "node_modules/for-each": { - "version": "0.3.5", - "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.5.tgz", - "integrity": "sha512-dKx12eRCVIzqCxFGplyFKJMPvLEWgmNtUrpTiJIR5u97zEhRG8ySrtboPHZXx7daLxQVrl643cTzbab2tkQjxg==", + "node_modules/emoji-regex": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", + "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", + "dev": true, + "license": "MIT" + }, + "node_modules/error-ex": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.4.tgz", + "integrity": "sha512-sqQamAnR14VgCr1A618A3sGrygcpK+HEbenA/HiEAkkUwcZIIB/tgWqHFxWgOyDh4nB4JCRimh79dR5Ywc9MDQ==", "dev": true, "license": "MIT", "dependencies": { - "is-callable": "^1.2.7" + "is-arrayish": "^0.2.1" + } + }, + "node_modules/esbuild": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.27.0.tgz", + "integrity": "sha512-jd0f4NHbD6cALCyGElNpGAOtWxSq46l9X/sWB0Nzd5er4Kz2YTm+Vl0qKFT9KUJvD8+fiO8AvoHhFvEatfVixA==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "bin": { + "esbuild": "bin/esbuild" }, "engines": { - "node": ">= 0.4" + "node": ">=18" }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.27.0", + "@esbuild/android-arm": "0.27.0", + "@esbuild/android-arm64": "0.27.0", + "@esbuild/android-x64": "0.27.0", + "@esbuild/darwin-arm64": "0.27.0", + "@esbuild/darwin-x64": "0.27.0", + "@esbuild/freebsd-arm64": "0.27.0", + "@esbuild/freebsd-x64": "0.27.0", + "@esbuild/linux-arm": "0.27.0", + "@esbuild/linux-arm64": "0.27.0", + "@esbuild/linux-ia32": "0.27.0", + "@esbuild/linux-loong64": "0.27.0", + "@esbuild/linux-mips64el": "0.27.0", + "@esbuild/linux-ppc64": "0.27.0", + "@esbuild/linux-riscv64": "0.27.0", + "@esbuild/linux-s390x": "0.27.0", + "@esbuild/linux-x64": "0.27.0", + "@esbuild/netbsd-arm64": "0.27.0", + "@esbuild/netbsd-x64": "0.27.0", + "@esbuild/openbsd-arm64": "0.27.0", + "@esbuild/openbsd-x64": "0.27.0", + "@esbuild/openharmony-arm64": "0.27.0", + "@esbuild/sunos-x64": "0.27.0", + "@esbuild/win32-arm64": "0.27.0", + "@esbuild/win32-ia32": "0.27.0", + "@esbuild/win32-x64": "0.27.0" } }, - "node_modules/foreground-child": { - "version": "2.0.0", + "node_modules/escalade": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz", + "integrity": "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==", "dev": true, - "license": "ISC", + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/eslint": { + "version": "8.35.0", + "dev": true, + "license": "MIT", "dependencies": { - "cross-spawn": "^7.0.0", - "signal-exit": "^3.0.2" + "@eslint/eslintrc": "^2.0.0", + "@eslint/js": "8.35.0", + "@humanwhocodes/config-array": "^0.11.8", + "@humanwhocodes/module-importer": "^1.0.1", + "@nodelib/fs.walk": "^1.2.8", + "ajv": "^6.10.0", + "chalk": "^4.0.0", + "cross-spawn": "^7.0.2", + "debug": "^4.3.2", + "doctrine": "^3.0.0", + "escape-string-regexp": "^4.0.0", + "eslint-scope": "^7.1.1", + "eslint-utils": "^3.0.0", + "eslint-visitor-keys": "^3.3.0", + "espree": "^9.4.0", + "esquery": "^1.4.2", + "esutils": "^2.0.2", + "fast-deep-equal": "^3.1.3", + "file-entry-cache": "^6.0.1", + "find-up": "^5.0.0", + "glob-parent": "^6.0.2", + "globals": "^13.19.0", + "grapheme-splitter": "^1.0.4", + "ignore": "^5.2.0", + "import-fresh": "^3.0.0", + "imurmurhash": "^0.1.4", + "is-glob": "^4.0.0", + "is-path-inside": "^3.0.3", + "js-sdsl": "^4.1.4", + "js-yaml": "^4.1.0", + "json-stable-stringify-without-jsonify": "^1.0.1", + "levn": "^0.4.1", + "lodash.merge": "^4.6.2", + "minimatch": "^3.1.2", + "natural-compare": "^1.4.0", + "optionator": "^0.9.1", + "regexpp": "^3.2.0", + "strip-ansi": "^6.0.1", + "strip-json-comments": "^3.1.0", + "text-table": "^0.2.0" + }, + "bin": { + "eslint": "bin/eslint.js" }, "engines": { - "node": ">=8.0.0" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" } }, - "node_modules/fromentries": { - "version": "1.3.2", + "node_modules/eslint-scope": { + "version": "7.1.1", "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "MIT" + "license": "BSD-2-Clause", + "dependencies": { + "esrecurse": "^4.3.0", + "estraverse": "^5.2.0" + }, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + } }, - "node_modules/fs-extra": { - "version": "8.1.0", + "node_modules/eslint-utils": { + "version": "3.0.0", "dev": true, "license": "MIT", "dependencies": { - "graceful-fs": "^4.2.0", - "jsonfile": "^4.0.0", - "universalify": "^0.1.0" + "eslint-visitor-keys": "^2.0.0" }, "engines": { - "node": ">=6 <7 || >=8" + "node": "^10.0.0 || ^12.0.0 || >= 14.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/mysticatea" + }, + "peerDependencies": { + "eslint": ">=5" } }, - "node_modules/fs.realpath": { - "version": "1.0.0", + "node_modules/eslint-utils/node_modules/eslint-visitor-keys": { + "version": "2.1.0", "dev": true, - "license": "ISC" + "license": "Apache-2.0", + "engines": { + "node": ">=10" + } }, - "node_modules/fsevents": { - "version": "2.3.2", + "node_modules/eslint-visitor-keys": { + "version": "3.3.0", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], + "license": "Apache-2.0", "engines": { - "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" } }, - "node_modules/function-bind": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", - "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", + "node_modules/eslint/node_modules/argparse": { + "version": "2.0.1", "dev": true, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } + "license": "Python-2.0" }, - "node_modules/gensync": { - "version": "1.0.0-beta.2", + "node_modules/eslint/node_modules/escape-string-regexp": { + "version": "4.0.0", "dev": true, "license": "MIT", "engines": { - "node": ">=6.9.0" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/get-assigned-identifiers": { - "version": "1.2.0", - "dev": true, - "license": "Apache-2.0" - }, - "node_modules/get-caller-file": { - "version": "2.0.5", + "node_modules/eslint/node_modules/glob-parent": { + "version": "6.0.2", "dev": true, "license": "ISC", + "dependencies": { + "is-glob": "^4.0.3" + }, "engines": { - "node": "6.* || 8.* || >= 10.*" + "node": ">=10.13.0" } }, - "node_modules/get-func-name": { - "version": "2.0.0", + "node_modules/eslint/node_modules/js-yaml": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.1.tgz", + "integrity": "sha512-qQKT4zQxXl8lLwBtHMWwaTcGfFOZviOJet3Oy/xmGk2gZH677CJM9EvtfdSkgWcATZhj/55JZ0rmy3myCT5lsA==", "dev": true, - "license": "MIT", - "engines": { - "node": "*" + "dependencies": { + "argparse": "^2.0.1" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" } }, - "node_modules/get-intrinsic": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.3.0.tgz", - "integrity": "sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ==", + "node_modules/eslint/node_modules/levn": { + "version": "0.4.1", "dev": true, "license": "MIT", "dependencies": { - "call-bind-apply-helpers": "^1.0.2", - "es-define-property": "^1.0.1", - "es-errors": "^1.3.0", - "es-object-atoms": "^1.1.1", - "function-bind": "^1.1.2", - "get-proto": "^1.0.1", - "gopd": "^1.2.0", - "has-symbols": "^1.1.0", - "hasown": "^2.0.2", - "math-intrinsics": "^1.1.0" + "prelude-ls": "^1.2.1", + "type-check": "~0.4.0" }, "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": ">= 0.8.0" } }, - "node_modules/get-package-type": { - "version": "0.1.0", + "node_modules/eslint/node_modules/minimatch": { + "version": "3.1.2", "dev": true, - "license": "MIT", + "license": "ISC", + "dependencies": { + "brace-expansion": "^1.1.7" + }, "engines": { - "node": ">=8.0.0" + "node": "*" } }, - "node_modules/get-proto": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/get-proto/-/get-proto-1.0.1.tgz", - "integrity": "sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==", + "node_modules/eslint/node_modules/optionator": { + "version": "0.9.1", "dev": true, "license": "MIT", "dependencies": { - "dunder-proto": "^1.0.1", - "es-object-atoms": "^1.0.0" + "deep-is": "^0.1.3", + "fast-levenshtein": "^2.0.6", + "levn": "^0.4.1", + "prelude-ls": "^1.2.1", + "type-check": "^0.4.0", + "word-wrap": "^1.2.3" }, "engines": { - "node": ">= 0.4" + "node": ">= 0.8.0" } }, - "node_modules/glob": { - "version": "7.2.0", + "node_modules/eslint/node_modules/prelude-ls": { + "version": "1.2.1", "dev": true, - "license": "ISC", - "dependencies": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - }, + "license": "MIT", "engines": { - "node": "*" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" + "node": ">= 0.8.0" } }, - "node_modules/glob-parent": { - "version": "5.1.2", + "node_modules/eslint/node_modules/type-check": { + "version": "0.4.0", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "is-glob": "^4.0.1" + "prelude-ls": "^1.2.1" }, "engines": { - "node": ">= 6" + "node": ">= 0.8.0" } }, - "node_modules/globals": { - "version": "13.20.0", + "node_modules/espree": { + "version": "9.4.1", "dev": true, - "license": "MIT", + "license": "BSD-2-Clause", "dependencies": { - "type-fest": "^0.20.2" + "acorn": "^8.8.0", + "acorn-jsx": "^5.3.2", + "eslint-visitor-keys": "^3.3.0" }, "engines": { - "node": ">=8" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://opencollective.com/eslint" } }, - "node_modules/gopd": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.2.0.tgz", - "integrity": "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==", + "node_modules/espree/node_modules/acorn": { + "version": "8.8.2", "dev": true, "license": "MIT", - "engines": { - "node": ">= 0.4" + "bin": { + "acorn": "bin/acorn" }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "engines": { + "node": ">=0.4.0" } }, - "node_modules/graceful-fs": { - "version": "4.2.10", - "dev": true, - "license": "ISC" - }, - "node_modules/grapheme-splitter": { - "version": "1.0.4", + "node_modules/esprima": { + "version": "4.0.1", "dev": true, - "license": "MIT" + "license": "BSD-2-Clause", + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=4" + } }, - "node_modules/has": { - "version": "1.0.3", + "node_modules/esquery": { + "version": "1.4.2", "dev": true, - "license": "MIT", + "license": "BSD-3-Clause", "dependencies": { - "function-bind": "^1.1.1" + "estraverse": "^5.1.0" }, "engines": { - "node": ">= 0.4.0" + "node": ">=0.10" } }, - "node_modules/has-ansi": { - "version": "2.0.0", + "node_modules/esrecurse": { + "version": "4.3.0", "dev": true, - "license": "MIT", + "license": "BSD-2-Clause", "dependencies": { - "ansi-regex": "^2.0.0" + "estraverse": "^5.2.0" }, "engines": { - "node": ">=0.10.0" + "node": ">=4.0" } }, - "node_modules/has-ansi/node_modules/ansi-regex": { - "version": "2.1.1", + "node_modules/estraverse": { + "version": "5.3.0", "dev": true, - "license": "MIT", + "license": "BSD-2-Clause", "engines": { - "node": ">=0.10.0" + "node": ">=4.0" } }, - "node_modules/has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "node_modules/esutils": { + "version": "2.0.3", "dev": true, + "license": "BSD-2-Clause", "engines": { - "node": ">=4" + "node": ">=0.10.0" } }, - "node_modules/has-property-descriptors": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz", - "integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==", + "node_modules/execa": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", + "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", "dev": true, + "license": "MIT", "dependencies": { - "es-define-property": "^1.0.0" + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" + }, + "engines": { + "node": ">=10" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/sindresorhus/execa?sponsor=1" } }, - "node_modules/has-symbols": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.1.0.tgz", - "integrity": "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==", + "node_modules/exit-x": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/exit-x/-/exit-x-0.2.2.tgz", + "integrity": "sha512-+I6B/IkJc1o/2tiURyz/ivu/O0nKNEArIUB5O7zBrlDVJr22SCLH3xTeEry428LvFhRzIA1g8izguxJ/gbNcVQ==", "dev": true, "license": "MIT", "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": ">= 0.8.0" } }, - "node_modules/has-tostringtag": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.2.tgz", - "integrity": "sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==", + "node_modules/expect": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/expect/-/expect-29.7.0.tgz", + "integrity": "sha512-2Zks0hf1VLFYI1kbh0I5jP3KHHyCHpkfyHBzsSXRFgl/Bg9mWYfMW8oD+PdMPlEwy5HNsR9JutYy6pMeOh61nw==", "dev": true, "license": "MIT", "dependencies": { - "has-symbols": "^1.0.3" + "@jest/expect-utils": "^29.7.0", + "jest-get-type": "^29.6.3", + "jest-matcher-utils": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-util": "^29.7.0" }, "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/hash-base": { - "version": "3.0.4", + "node_modules/fast-deep-equal": { + "version": "3.1.3", + "dev": true, + "license": "MIT" + }, + "node_modules/fast-json-stable-stringify": { + "version": "2.1.0", + "dev": true, + "license": "MIT" + }, + "node_modules/fast-levenshtein": { + "version": "2.0.6", + "dev": true, + "license": "MIT" + }, + "node_modules/fastq": { + "version": "1.15.0", + "dev": true, + "license": "ISC", + "dependencies": { + "reusify": "^1.0.4" + } + }, + "node_modules/fb-watchman": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/fb-watchman/-/fb-watchman-2.0.2.tgz", + "integrity": "sha512-p5161BqbuCaSnB8jIbzQHOlpgsPmK5rJVDfDKO91Axs5NC1uu3HRQm6wt9cd9/+GtQQIO53JdGXXoyDpTAsgYA==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "bser": "2.1.1" + } + }, + "node_modules/file-entry-cache": { + "version": "6.0.1", "dev": true, "license": "MIT", "dependencies": { - "inherits": "^2.0.1", - "safe-buffer": "^5.0.1" + "flat-cache": "^3.0.4" }, "engines": { - "node": ">=4" + "node": "^10.12.0 || >=12.0.0" } }, - "node_modules/hash.js": { - "version": "1.1.7", + "node_modules/fill-range": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", + "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", "dev": true, - "license": "MIT", "dependencies": { - "inherits": "^2.0.3", - "minimalistic-assert": "^1.0.1" + "to-regex-range": "^5.0.1" + }, + "engines": { + "node": ">=8" } }, - "node_modules/hasha": { - "version": "5.2.2", + "node_modules/find-up": { + "version": "5.0.0", "dev": true, "license": "MIT", "dependencies": { - "is-stream": "^2.0.0", - "type-fest": "^0.8.0" + "locate-path": "^6.0.0", + "path-exists": "^4.0.0" }, "engines": { - "node": ">=8" + "node": ">=10" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/hasha/node_modules/type-fest": { - "version": "0.8.1", - "dev": true, - "license": "(MIT OR CC0-1.0)", - "engines": { - "node": ">=8" - } - }, - "node_modules/hasown": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", - "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", + "node_modules/flat-cache": { + "version": "3.0.4", "dev": true, + "license": "MIT", "dependencies": { - "function-bind": "^1.1.2" + "flatted": "^3.1.0", + "rimraf": "^3.0.2" }, "engines": { - "node": ">= 0.4" + "node": "^10.12.0 || >=12.0.0" } }, - "node_modules/he": { - "version": "1.2.0", + "node_modules/flatted": { + "version": "3.2.7", + "dev": true, + "license": "ISC" + }, + "node_modules/fs.realpath": { + "version": "1.0.0", + "dev": true, + "license": "ISC" + }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", "dev": true, + "hasInstallScript": true, "license": "MIT", - "bin": { - "he": "bin/he" + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" } }, - "node_modules/hmac-drbg": { - "version": "1.0.1", + "node_modules/gensync": { + "version": "1.0.0-beta.2", "dev": true, "license": "MIT", - "dependencies": { - "hash.js": "^1.0.3", - "minimalistic-assert": "^1.0.0", - "minimalistic-crypto-utils": "^1.0.1" + "engines": { + "node": ">=6.9.0" } }, - "node_modules/html-escaper": { - "version": "2.0.2", + "node_modules/get-caller-file": { + "version": "2.0.5", "dev": true, - "license": "MIT" + "license": "ISC", + "engines": { + "node": "6.* || 8.* || >= 10.*" + } }, - "node_modules/htmlescape": { - "version": "1.1.1", + "node_modules/get-package-type": { + "version": "0.1.0", "dev": true, "license": "MIT", "engines": { - "node": ">=0.10" + "node": ">=8.0.0" } }, - "node_modules/htmlparser2": { - "version": "3.8.3", + "node_modules/get-stream": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", + "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", "dev": true, "license": "MIT", - "dependencies": { - "domelementtype": "1", - "domhandler": "2.3", - "domutils": "1.5", - "entities": "1.0", - "readable-stream": "1.1" + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/htmlparser2/node_modules/isarray": { - "version": "0.0.1", - "dev": true, - "license": "MIT" - }, - "node_modules/htmlparser2/node_modules/readable-stream": { - "version": "1.1.14", + "node_modules/glob": { + "version": "7.2.0", "dev": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.1", - "isarray": "0.0.1", - "string_decoder": "~0.10.x" + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/htmlparser2/node_modules/string_decoder": { - "version": "0.10.31", - "dev": true, - "license": "MIT" - }, - "node_modules/http-errors": { - "version": "2.0.0", + "node_modules/globals": { + "version": "13.20.0", "dev": true, "license": "MIT", "dependencies": { - "depd": "2.0.0", - "inherits": "2.0.4", - "setprototypeof": "1.2.0", - "statuses": "2.0.1", - "toidentifier": "1.0.1" + "type-fest": "^0.20.2" }, "engines": { - "node": ">= 0.8" + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/http-errors/node_modules/statuses": { - "version": "2.0.1", + "node_modules/graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.8" - } + "license": "ISC" + }, + "node_modules/grapheme-splitter": { + "version": "1.0.4", + "dev": true, + "license": "MIT" }, - "node_modules/http-proxy": { - "version": "1.18.1", + "node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, "license": "MIT", - "dependencies": { - "eventemitter3": "^4.0.0", - "follow-redirects": "^1.0.0", - "requires-port": "^1.0.0" - }, "engines": { - "node": ">=8.0.0" + "node": ">=8" } }, - "node_modules/https-browserify": { - "version": "1.0.0", + "node_modules/html-escaper": { + "version": "2.0.2", "dev": true, "license": "MIT" }, - "node_modules/iconv-lite": { - "version": "0.4.24", + "node_modules/human-signals": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", + "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", "dev": true, - "license": "MIT", - "dependencies": { - "safer-buffer": ">= 2.1.2 < 3" - }, + "license": "Apache-2.0", "engines": { - "node": ">=0.10.0" + "node": ">=10.17.0" } }, - "node_modules/ieee754": { - "version": "1.2.1", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "BSD-3-Clause" - }, "node_modules/ignore": { "version": "5.2.4", "dev": true, @@ -3155,20 +4067,32 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/imurmurhash": { - "version": "0.1.4", + "node_modules/import-local": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/import-local/-/import-local-3.2.0.tgz", + "integrity": "sha512-2SPlun1JUPWoM6t3F0dw0FkCF/jWY8kttcY4f599GLTSjh2OCuuhdTkJQsEcZzBqbXZGKMK2OqW1oZsjtf/gQA==", "dev": true, "license": "MIT", + "dependencies": { + "pkg-dir": "^4.2.0", + "resolve-cwd": "^3.0.0" + }, + "bin": { + "import-local-fixture": "fixtures/cli.js" + }, "engines": { - "node": ">=0.8.19" + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/indent-string": { - "version": "4.0.0", + "node_modules/imurmurhash": { + "version": "0.1.4", "dev": true, "license": "MIT", "engines": { - "node": ">=8" + "node": ">=0.8.19" } }, "node_modules/inflight": { @@ -3185,77 +4109,39 @@ "dev": true, "license": "ISC" }, - "node_modules/inline-source-map": { - "version": "0.6.2", - "dev": true, - "license": "MIT", - "dependencies": { - "source-map": "~0.5.3" - } - }, - "node_modules/insert-module-globals": { - "version": "7.2.0", + "node_modules/is-arrayish": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", + "integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==", "dev": true, - "license": "MIT", - "dependencies": { - "acorn-node": "^1.5.2", - "combine-source-map": "^0.8.0", - "concat-stream": "^1.6.1", - "is-buffer": "^1.1.0", - "JSONStream": "^1.0.3", - "path-is-absolute": "^1.0.1", - "process": "~0.11.0", - "through2": "^2.0.0", - "undeclared-identifiers": "^1.1.2", - "xtend": "^4.0.0" - }, - "bin": { - "insert-module-globals": "bin/cmd.js" - } + "license": "MIT" }, - "node_modules/irregular-plurals": { - "version": "1.4.0", + "node_modules/is-extglob": { + "version": "2.1.1", "dev": true, "license": "MIT", "engines": { "node": ">=0.10.0" } }, - "node_modules/is-binary-path": { - "version": "2.1.0", + "node_modules/is-fullwidth-code-point": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", + "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", "dev": true, "license": "MIT", - "dependencies": { - "binary-extensions": "^2.0.0" - }, "engines": { "node": ">=8" } }, - "node_modules/is-buffer": { - "version": "1.1.6", - "dev": true, - "license": "MIT" - }, - "node_modules/is-callable": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", - "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-extglob": { - "version": "2.1.1", + "node_modules/is-generator-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-generator-fn/-/is-generator-fn-2.1.0.tgz", + "integrity": "sha512-cTIB4yPYL/Grw0EaSzASzg6bBy9gqCofvWN8okThAYIxKJZC+udlRAmGbM0XLeniEJSs8uEgHPGuHSe1XsOLSQ==", "dev": true, "license": "MIT", "engines": { - "node": ">=0.10.0" + "node": ">=6" } }, "node_modules/is-glob": { @@ -3286,14 +4172,6 @@ "node": ">=8" } }, - "node_modules/is-plain-obj": { - "version": "2.1.0", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, "node_modules/is-stream": { "version": "2.0.1", "dev": true, @@ -3305,62 +4183,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/is-typed-array": { - "version": "1.1.15", - "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.15.tgz", - "integrity": "sha512-p3EcsicXjit7SaskXHs1hA91QxgTw46Fv6EFKKGS5DRFLD8yKnohjF3hxoju94b/OcMZoQukzpPpBE9uLVKzgQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "which-typed-array": "^1.1.16" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-typedarray": { - "version": "1.0.0", - "dev": true, - "license": "MIT" - }, - "node_modules/is-unicode-supported": { - "version": "0.1.0", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/is-windows": { - "version": "1.0.2", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/isarray": { - "version": "1.0.0", - "dev": true, - "license": "MIT" - }, - "node_modules/isbinaryfile": { - "version": "4.0.10", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 8.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/gjtorikian/" - } - }, "node_modules/isexe": { "version": "2.0.0", "dev": true, @@ -3374,106 +4196,17 @@ "node": ">=8" } }, - "node_modules/istanbul-lib-hook": { - "version": "3.0.0", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "append-transform": "^2.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/istanbul-lib-instrument": { - "version": "4.0.3", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "@babel/core": "^7.7.5", - "@istanbuljs/schema": "^0.1.2", - "istanbul-lib-coverage": "^3.0.0", - "semver": "^6.3.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/istanbul-lib-instrument/node_modules/semver": { - "version": "6.3.0", - "dev": true, - "license": "ISC", - "bin": { - "semver": "bin/semver.js" - } - }, - "node_modules/istanbul-lib-processinfo": { - "version": "2.0.3", - "dev": true, - "license": "ISC", - "dependencies": { - "archy": "^1.0.0", - "cross-spawn": "^7.0.3", - "istanbul-lib-coverage": "^3.2.0", - "p-map": "^3.0.0", - "rimraf": "^3.0.0", - "uuid": "^8.3.2" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/istanbul-lib-report": { - "version": "3.0.0", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "istanbul-lib-coverage": "^3.0.0", - "make-dir": "^3.0.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/istanbul-lib-report/node_modules/has-flag": { - "version": "4.0.0", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/istanbul-lib-report/node_modules/supports-color": { - "version": "7.2.0", - "dev": true, - "license": "MIT", - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/istanbul-lib-source-maps": { - "version": "4.0.1", + "node_modules/istanbul-lib-report": { + "version": "3.0.0", "dev": true, "license": "BSD-3-Clause", "dependencies": { - "debug": "^4.1.1", "istanbul-lib-coverage": "^3.0.0", - "source-map": "^0.6.1" + "make-dir": "^3.0.0", + "supports-color": "^7.1.0" }, "engines": { - "node": ">=10" - } - }, - "node_modules/istanbul-lib-source-maps/node_modules/source-map": { - "version": "0.6.1", - "dev": true, - "license": "BSD-3-Clause", - "engines": { - "node": ">=0.10.0" + "node": ">=8" } }, "node_modules/istanbul-reports": { @@ -3488,1395 +4221,2035 @@ "node": ">=8" } }, - "node_modules/js-sdsl": { - "version": "4.3.0", + "node_modules/jackspeak": { + "version": "3.4.3", + "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-3.4.3.tgz", + "integrity": "sha512-OGlZQpz2yfahA/Rd1Y8Cd9SIEsqvXkLVoSw/cgwhnhFMDbsQFeZYoJJ7bIZBS9BcamUW96asq/npPWugM+RQBw==", "dev": true, - "license": "MIT", + "license": "BlueOak-1.0.0", + "dependencies": { + "@isaacs/cliui": "^8.0.2" + }, "funding": { - "type": "opencollective", - "url": "https://opencollective.com/js-sdsl" + "url": "https://github.com/sponsors/isaacs" + }, + "optionalDependencies": { + "@pkgjs/parseargs": "^0.11.0" } }, - "node_modules/js-tokens": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", - "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", - "dev": true - }, - "node_modules/js-yaml": { - "version": "3.14.2", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.2.tgz", - "integrity": "sha512-PMSmkqxr106Xa156c2M265Z+FTrPl+oxd/rgOQy2tijQeK5TxQ43psO1ZCwhVOSdnn+RzkzlRz/eY4BgJBYVpg==", + "node_modules/jest": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest/-/jest-30.2.0.tgz", + "integrity": "sha512-F26gjC0yWN8uAA5m5Ss8ZQf5nDHWGlN/xWZIh8S5SRbsEKBovwZhxGd6LJlbZYxBgCYOtreSUyb8hpXyGC5O4A==", "dev": true, + "license": "MIT", "dependencies": { - "argparse": "^1.0.7", - "esprima": "^4.0.0" + "@jest/core": "30.2.0", + "@jest/types": "30.2.0", + "import-local": "^3.2.0", + "jest-cli": "30.2.0" }, "bin": { - "js-yaml": "bin/js-yaml.js" + "jest": "bin/jest.js" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" + }, + "peerDependenciesMeta": { + "node-notifier": { + "optional": true + } } }, - "node_modules/jsesc": { - "version": "2.5.2", + "node_modules/jest-changed-files": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-changed-files/-/jest-changed-files-30.2.0.tgz", + "integrity": "sha512-L8lR1ChrRnSdfeOvTrwZMlnWV8G/LLjQ0nG9MBclwWZidA2N5FviRki0Bvh20WRMOX31/JYvzdqTJrk5oBdydQ==", "dev": true, "license": "MIT", - "bin": { - "jsesc": "bin/jsesc" + "dependencies": { + "execa": "^5.1.1", + "jest-util": "30.2.0", + "p-limit": "^3.1.0" }, "engines": { - "node": ">=4" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jshint": { - "version": "2.13.5", + "node_modules/jest-changed-files/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", "dependencies": { - "cli": "~1.0.0", - "console-browserify": "1.1.x", - "exit": "0.1.x", - "htmlparser2": "3.8.x", - "lodash": "~4.17.21", - "minimatch": "~3.0.2", - "strip-json-comments": "1.0.x" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" }, - "bin": { - "jshint": "bin/jshint" + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jshint-stylish": { - "version": "2.2.1", + "node_modules/jest-changed-files/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, "license": "MIT", - "dependencies": { - "beeper": "^1.1.0", - "chalk": "^1.0.0", - "log-symbols": "^1.0.0", - "plur": "^2.1.0", - "string-length": "^1.0.0", - "text-table": "^0.2.0" - }, "engines": { - "node": ">=0.10.0" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/jshint-stylish/node_modules/ansi-regex": { - "version": "2.1.1", + "node_modules/jest-circus": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-circus/-/jest-circus-30.2.0.tgz", + "integrity": "sha512-Fh0096NC3ZkFx05EP2OXCxJAREVxj1BcW/i6EWqqymcgYKWjyyDpral3fMxVcHXg6oZM7iULer9wGRFvfpl+Tg==", "dev": true, "license": "MIT", + "dependencies": { + "@jest/environment": "30.2.0", + "@jest/expect": "30.2.0", + "@jest/test-result": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "co": "^4.6.0", + "dedent": "^1.6.0", + "is-generator-fn": "^2.1.0", + "jest-each": "30.2.0", + "jest-matcher-utils": "30.2.0", + "jest-message-util": "30.2.0", + "jest-runtime": "30.2.0", + "jest-snapshot": "30.2.0", + "jest-util": "30.2.0", + "p-limit": "^3.1.0", + "pretty-format": "30.2.0", + "pure-rand": "^7.0.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + }, "engines": { - "node": ">=0.10.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jshint-stylish/node_modules/ansi-styles": { - "version": "2.2.1", + "node_modules/jest-circus/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, "license": "MIT", "engines": { - "node": ">=0.10.0" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/jshint-stylish/node_modules/chalk": { - "version": "1.1.3", + "node_modules/jest-circus/node_modules/jest-diff": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-30.2.0.tgz", + "integrity": "sha512-dQHFo3Pt4/NLlG5z4PxZ/3yZTZ1C7s9hveiOj+GCN+uT109NC2QgsoVZsVOAvbJ3RgKkvyLGXZV9+piDpWbm6A==", "dev": true, "license": "MIT", "dependencies": { - "ansi-styles": "^2.2.1", - "escape-string-regexp": "^1.0.2", - "has-ansi": "^2.0.0", - "strip-ansi": "^3.0.0", - "supports-color": "^2.0.0" + "@jest/diff-sequences": "30.0.1", + "@jest/get-type": "30.1.0", + "chalk": "^4.1.2", + "pretty-format": "30.2.0" }, "engines": { - "node": ">=0.10.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jshint-stylish/node_modules/strip-ansi": { - "version": "3.0.1", + "node_modules/jest-circus/node_modules/jest-matcher-utils": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-30.2.0.tgz", + "integrity": "sha512-dQ94Nq4dbzmUWkQ0ANAWS9tBRfqCrn0bV9AMYdOi/MHW726xn7eQmMeRTpX2ViC00bpNaWXq+7o4lIQ3AX13Hg==", "dev": true, "license": "MIT", "dependencies": { - "ansi-regex": "^2.0.0" + "@jest/get-type": "30.1.0", + "chalk": "^4.1.2", + "jest-diff": "30.2.0", + "pretty-format": "30.2.0" }, "engines": { - "node": ">=0.10.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jshint-stylish/node_modules/supports-color": { - "version": "2.0.0", + "node_modules/jest-circus/node_modules/jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + }, "engines": { - "node": ">=0.8.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jshint/node_modules/strip-json-comments": { - "version": "1.0.4", + "node_modules/jest-circus/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", - "bin": { - "strip-json-comments": "cli.js" + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" }, "engines": { - "node": ">=0.8.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/json-schema-traverse": { - "version": "0.4.1", - "dev": true, - "license": "MIT" - }, - "node_modules/json-stable-stringify": { - "version": "0.0.1", + "node_modules/jest-circus/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, "license": "MIT", - "dependencies": { - "jsonify": "~0.0.0" + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/json-stable-stringify-without-jsonify": { - "version": "1.0.1", - "dev": true, - "license": "MIT" - }, - "node_modules/json5": { - "version": "2.2.3", + "node_modules/jest-circus/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, "license": "MIT", - "bin": { - "json5": "lib/cli.js" + "dependencies": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" }, "engines": { - "node": ">=6" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jsonfile": { - "version": "4.0.0", + "node_modules/jest-cli": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-30.2.0.tgz", + "integrity": "sha512-Os9ukIvADX/A9sLt6Zse3+nmHtHaE6hqOsjQtNiugFTbKRHYIYtZXNGNK9NChseXy7djFPjndX1tL0sCTlfpAA==", "dev": true, "license": "MIT", - "optionalDependencies": { - "graceful-fs": "^4.1.6" + "dependencies": { + "@jest/core": "30.2.0", + "@jest/test-result": "30.2.0", + "@jest/types": "30.2.0", + "chalk": "^4.1.2", + "exit-x": "^0.2.2", + "import-local": "^3.2.0", + "jest-config": "30.2.0", + "jest-util": "30.2.0", + "jest-validate": "30.2.0", + "yargs": "^17.7.2" + }, + "bin": { + "jest": "bin/jest.js" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" + }, + "peerDependenciesMeta": { + "node-notifier": { + "optional": true + } } }, - "node_modules/jsonify": { - "version": "0.0.0", - "dev": true, - "license": "Public Domain" - }, - "node_modules/jsonparse": { - "version": "1.3.1", - "dev": true, - "engines": [ - "node >= 0.2.0" - ], - "license": "MIT" - }, - "node_modules/JSONStream": { - "version": "1.3.5", + "node_modules/jest-cli/node_modules/cliui": { + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", + "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", "dev": true, - "license": "(MIT OR Apache-2.0)", + "license": "ISC", "dependencies": { - "jsonparse": "^1.2.0", - "through": ">=2.2.7 <3" - }, - "bin": { - "JSONStream": "bin.js" + "string-width": "^4.2.0", + "strip-ansi": "^6.0.1", + "wrap-ansi": "^7.0.0" }, "engines": { - "node": "*" + "node": ">=12" } }, - "node_modules/karma": { - "version": "6.4.1", + "node_modules/jest-cli/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", "dependencies": { - "@colors/colors": "1.5.0", - "body-parser": "^1.19.0", - "braces": "^3.0.2", - "chokidar": "^3.5.1", - "connect": "^3.7.0", - "di": "^0.0.1", - "dom-serialize": "^2.2.1", - "glob": "^7.1.7", - "graceful-fs": "^4.2.6", - "http-proxy": "^1.18.1", - "isbinaryfile": "^4.0.8", - "lodash": "^4.17.21", - "log4js": "^6.4.1", - "mime": "^2.5.2", - "minimatch": "^3.0.4", - "mkdirp": "^0.5.5", - "qjobs": "^1.2.0", - "range-parser": "^1.2.1", - "rimraf": "^3.0.2", - "socket.io": "^4.4.1", - "source-map": "^0.6.1", - "tmp": "^0.2.1", - "ua-parser-js": "^0.7.30", - "yargs": "^16.1.1" - }, - "bin": { - "karma": "bin/karma" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" }, "engines": { - "node": ">= 10" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/karma-chrome-launcher": { - "version": "3.1.0", + "node_modules/jest-cli/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, "license": "MIT", - "dependencies": { - "which": "^1.2.1" + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/karma-mocha": { - "version": "2.0.1", + "node_modules/jest-cli/node_modules/yargs": { + "version": "17.7.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz", + "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==", "dev": true, "license": "MIT", "dependencies": { - "minimist": "^1.2.3" + "cliui": "^8.0.1", + "escalade": "^3.1.1", + "get-caller-file": "^2.0.5", + "require-directory": "^2.1.1", + "string-width": "^4.2.3", + "y18n": "^5.0.5", + "yargs-parser": "^21.1.1" + }, + "engines": { + "node": ">=12" } }, - "node_modules/karma-requirejs": { - "version": "1.1.0", + "node_modules/jest-cli/node_modules/yargs-parser": { + "version": "21.1.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", + "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", "dev": true, - "license": "MIT", + "license": "ISC", + "engines": { + "node": ">=12" + } + }, + "node_modules/jest-config": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-config/-/jest-config-30.2.0.tgz", + "integrity": "sha512-g4WkyzFQVWHtu6uqGmQR4CQxz/CH3yDSlhzXMWzNjDx843gYjReZnMRanjRCq5XZFuQrGDxgUaiYWE8BRfVckA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/core": "^7.27.4", + "@jest/get-type": "30.1.0", + "@jest/pattern": "30.0.1", + "@jest/test-sequencer": "30.2.0", + "@jest/types": "30.2.0", + "babel-jest": "30.2.0", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "deepmerge": "^4.3.1", + "glob": "^10.3.10", + "graceful-fs": "^4.2.11", + "jest-circus": "30.2.0", + "jest-docblock": "30.2.0", + "jest-environment-node": "30.2.0", + "jest-regex-util": "30.0.1", + "jest-resolve": "30.2.0", + "jest-runner": "30.2.0", + "jest-util": "30.2.0", + "jest-validate": "30.2.0", + "micromatch": "^4.0.8", + "parse-json": "^5.2.0", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "strip-json-comments": "^3.1.1" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + }, "peerDependencies": { - "karma": ">=0.9", - "requirejs": "^2.1.0" + "@types/node": "*", + "esbuild-register": ">=3.4.0", + "ts-node": ">=9.0.0" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "esbuild-register": { + "optional": true + }, + "ts-node": { + "optional": true + } } }, - "node_modules/karma-safari-launcher": { - "version": "1.0.0", + "node_modules/jest-config/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, "license": "MIT", - "peerDependencies": { - "karma": ">=0.9" + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-config/node_modules/brace-expansion": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.2.tgz", + "integrity": "sha512-Jt0vHyM+jmUBqojB7E1NIYadt0vI0Qxjxd2TErW94wDz+E2LAm5vKMXXwg6ZZBTHPuUlDgQHKXvjGBdfcF1ZDQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0" } }, - "node_modules/karma/node_modules/glob": { - "version": "7.2.3", + "node_modules/jest-config/node_modules/foreground-child": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.3.1.tgz", + "integrity": "sha512-gIXjKqtFuWEgzFRJA9WCQeSJLZDjgJUOMCMzxtvFq/37KojM1BFGufqsCy0r4qSQmYLsZYMeyRqzIWOMup03sw==", "dev": true, "license": "ISC", "dependencies": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.1.1", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" + "cross-spawn": "^7.0.6", + "signal-exit": "^4.0.1" }, "engines": { - "node": "*" + "node": ">=14" }, "funding": { "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/karma/node_modules/minimatch": { - "version": "3.1.2", + "node_modules/jest-config/node_modules/glob": { + "version": "10.5.0", + "resolved": "https://registry.npmjs.org/glob/-/glob-10.5.0.tgz", + "integrity": "sha512-DfXN8DfhJ7NH3Oe7cFmu3NCu1wKbkReJ8TorzSAFbSKrlNaQSKfIzqYqVY8zlbs2NLBbWpRiU52GX2PbaBVNkg==", "dev": true, "license": "ISC", "dependencies": { - "brace-expansion": "^1.1.7" + "foreground-child": "^3.1.0", + "jackspeak": "^3.1.2", + "minimatch": "^9.0.4", + "minipass": "^7.1.2", + "package-json-from-dist": "^1.0.0", + "path-scurry": "^1.11.1" }, - "engines": { - "node": "*" - } - }, - "node_modules/karma/node_modules/source-map": { - "version": "0.6.1", - "dev": true, - "license": "BSD-3-Clause", - "engines": { - "node": ">=0.10.0" + "bin": { + "glob": "dist/esm/bin.mjs" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/labeled-stream-splicer": { - "version": "2.0.2", + "node_modules/jest-config/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", "dependencies": { - "inherits": "^2.0.1", - "stream-splicer": "^2.0.0" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/locate-path": { - "version": "6.0.0", + "node_modules/jest-config/node_modules/minimatch": { + "version": "9.0.5", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.5.tgz", + "integrity": "sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==", "dev": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "p-locate": "^5.0.0" + "brace-expansion": "^2.0.1" }, "engines": { - "node": ">=10" + "node": ">=16 || 14 >=14.17" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/lodash": { - "version": "4.17.21", - "dev": true, - "license": "MIT" - }, - "node_modules/lodash.flattendeep": { - "version": "4.4.0", + "node_modules/jest-config/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, - "license": "MIT" + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } }, - "node_modules/lodash.memoize": { - "version": "3.0.4", + "node_modules/jest-config/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, - "license": "MIT" + "license": "MIT", + "dependencies": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } }, - "node_modules/lodash.merge": { - "version": "4.6.2", + "node_modules/jest-config/node_modules/signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", "dev": true, - "license": "MIT" + "license": "ISC", + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } }, - "node_modules/log-symbols": { - "version": "1.0.2", + "node_modules/jest-diff": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-29.7.0.tgz", + "integrity": "sha512-LMIgiIrhigmPrs03JHpxUh2yISK3vLFPkAodPeo0+BuF7wA2FoQbkEg1u8gBYBThncu7e1oEDUfIXVuTqLRUjw==", "dev": true, "license": "MIT", "dependencies": { - "chalk": "^1.0.0" + "chalk": "^4.0.0", + "diff-sequences": "^29.6.3", + "jest-get-type": "^29.6.3", + "pretty-format": "^29.7.0" }, "engines": { - "node": ">=0.10.0" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/log-symbols/node_modules/ansi-regex": { - "version": "2.1.1", + "node_modules/jest-docblock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-docblock/-/jest-docblock-30.2.0.tgz", + "integrity": "sha512-tR/FFgZKS1CXluOQzZvNH3+0z9jXr3ldGSD8bhyuxvlVUwbeLOGynkunvlTMxchC5urrKndYiwCFC0DLVjpOCA==", "dev": true, "license": "MIT", + "dependencies": { + "detect-newline": "^3.1.0" + }, "engines": { - "node": ">=0.10.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/log-symbols/node_modules/ansi-styles": { - "version": "2.2.1", + "node_modules/jest-each": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-each/-/jest-each-30.2.0.tgz", + "integrity": "sha512-lpWlJlM7bCUf1mfmuqTA8+j2lNURW9eNafOy99knBM01i5CQeY5UH1vZjgT9071nDJac1M4XsbyI44oNOdhlDQ==", "dev": true, "license": "MIT", + "dependencies": { + "@jest/get-type": "30.1.0", + "@jest/types": "30.2.0", + "chalk": "^4.1.2", + "jest-util": "30.2.0", + "pretty-format": "30.2.0" + }, "engines": { - "node": ">=0.10.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/log-symbols/node_modules/chalk": { - "version": "1.1.3", + "node_modules/jest-each/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, "license": "MIT", - "dependencies": { - "ansi-styles": "^2.2.1", - "escape-string-regexp": "^1.0.2", - "has-ansi": "^2.0.0", - "strip-ansi": "^3.0.0", - "supports-color": "^2.0.0" - }, "engines": { - "node": ">=0.10.0" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/log-symbols/node_modules/strip-ansi": { - "version": "3.0.1", + "node_modules/jest-each/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", "dependencies": { - "ansi-regex": "^2.0.0" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" }, "engines": { - "node": ">=0.10.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/log-symbols/node_modules/supports-color": { - "version": "2.0.0", + "node_modules/jest-each/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, "license": "MIT", "engines": { - "node": ">=0.8.0" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/log4js": { - "version": "6.8.0", + "node_modules/jest-each/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, - "license": "Apache-2.0", + "license": "MIT", "dependencies": { - "date-format": "^4.0.14", - "debug": "^4.3.4", - "flatted": "^3.2.7", - "rfdc": "^1.3.0", - "streamroller": "^3.1.5" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" }, "engines": { - "node": ">=8.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/loupe": { - "version": "2.3.6", + "node_modules/jest-environment-node": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-environment-node/-/jest-environment-node-30.2.0.tgz", + "integrity": "sha512-ElU8v92QJ9UrYsKrxDIKCxu6PfNj4Hdcktcn0JX12zqNdqWHB0N+hwOnnBBXvjLd2vApZtuLUGs1QSY+MsXoNA==", "dev": true, "license": "MIT", "dependencies": { - "get-func-name": "^2.0.0" + "@jest/environment": "30.2.0", + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0", + "jest-util": "30.2.0", + "jest-validate": "30.2.0" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/lru-cache": { - "version": "5.1.1", + "node_modules/jest-environment-node/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "yallist": "^3.0.2" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/make-dir": { - "version": "3.1.0", + "node_modules/jest-environment-node/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, "license": "MIT", - "dependencies": { - "semver": "^6.0.0" - }, "engines": { - "node": ">=8" + "node": ">=12" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/make-dir/node_modules/semver": { - "version": "6.3.0", + "node_modules/jest-get-type": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/jest-get-type/-/jest-get-type-29.6.3.tgz", + "integrity": "sha512-zrteXnqYxfQh7l5FHyL38jL39di8H8rHoecLH3JNxH3BwOrBsNeabdap5e0I23lD4HHI8W5VFBZqG4Eaq5LNcw==", "dev": true, - "license": "ISC", - "bin": { - "semver": "bin/semver.js" + "license": "MIT", + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/math-intrinsics": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/math-intrinsics/-/math-intrinsics-1.1.0.tgz", - "integrity": "sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==", + "node_modules/jest-haste-map": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-haste-map/-/jest-haste-map-30.2.0.tgz", + "integrity": "sha512-sQA/jCb9kNt+neM0anSj6eZhLZUIhQgwDt7cPGjumgLM4rXsfb9kpnlacmvZz3Q5tb80nS+oG/if+NBKrHC+Xw==", "dev": true, "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "anymatch": "^3.1.3", + "fb-watchman": "^2.0.2", + "graceful-fs": "^4.2.11", + "jest-regex-util": "30.0.1", + "jest-util": "30.2.0", + "jest-worker": "30.2.0", + "micromatch": "^4.0.8", + "walker": "^1.0.8" + }, "engines": { - "node": ">= 0.4" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + }, + "optionalDependencies": { + "fsevents": "^2.3.3" } }, - "node_modules/md5.js": { - "version": "1.3.5", + "node_modules/jest-haste-map/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", "dependencies": { - "hash-base": "^3.0.0", - "inherits": "^2.0.1", - "safe-buffer": "^5.1.2" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/media-typer": { - "version": "0.3.0", + "node_modules/jest-haste-map/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, "license": "MIT", "engines": { - "node": ">= 0.6" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/miller-rabin": { - "version": "4.0.1", + "node_modules/jest-leak-detector": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-leak-detector/-/jest-leak-detector-30.2.0.tgz", + "integrity": "sha512-M6jKAjyzjHG0SrQgwhgZGy9hFazcudwCNovY/9HPIicmNSBuockPSedAP9vlPK6ONFJ1zfyH/M2/YYJxOz5cdQ==", "dev": true, "license": "MIT", "dependencies": { - "bn.js": "^4.0.0", - "brorand": "^1.0.1" + "@jest/get-type": "30.1.0", + "pretty-format": "30.2.0" }, - "bin": { - "miller-rabin": "bin/miller-rabin" + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/mime": { - "version": "2.6.0", + "node_modules/jest-leak-detector/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, "license": "MIT", - "bin": { - "mime": "cli.js" - }, "engines": { - "node": ">=4.0.0" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/mime-db": { - "version": "1.52.0", + "node_modules/jest-leak-detector/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, "license": "MIT", + "dependencies": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + }, "engines": { - "node": ">= 0.6" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/mime-types": { - "version": "2.1.35", + "node_modules/jest-matcher-utils": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-29.7.0.tgz", + "integrity": "sha512-sBkD+Xi9DtcChsI3L3u0+N0opgPYnCRPtGcQYrgXmR+hmt/fYfWAL0xRXYU8eWOdfuLgBe0YCW3AFtnRLagq/g==", "dev": true, "license": "MIT", "dependencies": { - "mime-db": "1.52.0" + "chalk": "^4.0.0", + "jest-diff": "^29.7.0", + "jest-get-type": "^29.6.3", + "pretty-format": "^29.7.0" }, "engines": { - "node": ">= 0.6" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/minimalistic-assert": { - "version": "1.0.1", - "dev": true, - "license": "ISC" - }, - "node_modules/minimalistic-crypto-utils": { - "version": "1.0.1", - "dev": true, - "license": "MIT" - }, - "node_modules/minimatch": { - "version": "3.0.8", + "node_modules/jest-message-util": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-29.7.0.tgz", + "integrity": "sha512-GBEV4GRADeP+qtB2+6u61stea8mGcOT4mCtrYISZwfu9/ISHFJ/5zOMXYbpBE9RsS5+Gb63DW4FgmnKJ79Kf6w==", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "brace-expansion": "^1.1.7" + "@babel/code-frame": "^7.12.13", + "@jest/types": "^29.6.3", + "@types/stack-utils": "^2.0.0", + "chalk": "^4.0.0", + "graceful-fs": "^4.2.9", + "micromatch": "^4.0.4", + "pretty-format": "^29.7.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.3" }, "engines": { - "node": "*" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/minimist": { - "version": "1.2.8", + "node_modules/jest-message-util/node_modules/@jest/schemas": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.3.tgz", + "integrity": "sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==", "dev": true, "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/ljharb" + "dependencies": { + "@sinclair/typebox": "^0.27.8" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/mkdirp": { - "version": "0.5.6", + "node_modules/jest-message-util/node_modules/@jest/types": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.6.3.tgz", + "integrity": "sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw==", "dev": true, "license": "MIT", "dependencies": { - "minimist": "^1.2.6" + "@jest/schemas": "^29.6.3", + "@types/istanbul-lib-coverage": "^2.0.0", + "@types/istanbul-reports": "^3.0.0", + "@types/node": "*", + "@types/yargs": "^17.0.8", + "chalk": "^4.0.0" }, - "bin": { - "mkdirp": "bin/cmd.js" + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/mkdirp-classic": { - "version": "0.5.3", + "node_modules/jest-message-util/node_modules/@sinclair/typebox": { + "version": "0.27.8", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.8.tgz", + "integrity": "sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==", "dev": true, "license": "MIT" }, - "node_modules/mocha": { - "version": "10.8.2", - "resolved": "https://registry.npmjs.org/mocha/-/mocha-10.8.2.tgz", - "integrity": "sha512-VZlYo/WE8t1tstuRmqgeyBgCbJc/lEdopaa+axcKzTBJ+UIdlAB9XnmvTCAH4pwR4ElNInaedhEBmZD8iCSVEg==", + "node_modules/jest-mock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-30.2.0.tgz", + "integrity": "sha512-JNNNl2rj4b5ICpmAcq+WbLH83XswjPbjH4T7yvGzfAGCPh1rw+xVNbtk+FnRslvt9lkCcdn9i1oAoKUuFsOxRw==", "dev": true, "license": "MIT", "dependencies": { - "ansi-colors": "^4.1.3", - "browser-stdout": "^1.3.1", - "chokidar": "^3.5.3", - "debug": "^4.3.5", - "diff": "^5.2.0", - "escape-string-regexp": "^4.0.0", - "find-up": "^5.0.0", - "glob": "^8.1.0", - "he": "^1.2.0", - "js-yaml": "^4.1.0", - "log-symbols": "^4.1.0", - "minimatch": "^5.1.6", - "ms": "^2.1.3", - "serialize-javascript": "^6.0.2", - "strip-json-comments": "^3.1.1", - "supports-color": "^8.1.1", - "workerpool": "^6.5.1", - "yargs": "^16.2.0", - "yargs-parser": "^20.2.9", - "yargs-unparser": "^2.0.0" - }, - "bin": { - "_mocha": "bin/_mocha", - "mocha": "bin/mocha.js" + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-util": "30.2.0" }, "engines": { - "node": ">= 14.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/mocha/node_modules/ansi-styles": { - "version": "4.3.0", + "node_modules/jest-mock/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", "dependencies": { - "color-convert": "^2.0.1" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/jest-mock/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" }, "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/mocha/node_modules/argparse": { - "version": "2.0.1", + "node_modules/jest-pnp-resolver": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/jest-pnp-resolver/-/jest-pnp-resolver-1.2.3.tgz", + "integrity": "sha512-+3NpwQEnRoIBtx4fyhblQDPgJI0H1IEIkX7ShLUjPGA7TtUTvI1oiKi3SR4oBR0hQhQR80l4WAe5RrXBwWMA8w==", "dev": true, - "license": "Python-2.0" + "license": "MIT", + "engines": { + "node": ">=6" + }, + "peerDependencies": { + "jest-resolve": "*" + }, + "peerDependenciesMeta": { + "jest-resolve": { + "optional": true + } + } }, - "node_modules/mocha/node_modules/brace-expansion": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz", - "integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==", + "node_modules/jest-regex-util": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/jest-regex-util/-/jest-regex-util-30.0.1.tgz", + "integrity": "sha512-jHEQgBXAgc+Gh4g0p3bCevgRCVRkB4VB70zhoAE48gxeSr1hfUOsM/C2WoJgVL7Eyg//hudYENbm3Ne+/dRVVA==", "dev": true, "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0" + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/mocha/node_modules/chalk": { - "version": "4.1.2", + "node_modules/jest-resolve": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-resolve/-/jest-resolve-30.2.0.tgz", + "integrity": "sha512-TCrHSxPlx3tBY3hWNtRQKbtgLhsXa1WmbJEqBlTBrGafd5fiQFByy2GNCEoGR+Tns8d15GaL9cxEzKOO3GEb2A==", "dev": true, "license": "MIT", "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "jest-haste-map": "30.2.0", + "jest-pnp-resolver": "^1.2.3", + "jest-util": "30.2.0", + "jest-validate": "30.2.0", + "slash": "^3.0.0", + "unrs-resolver": "^1.7.11" }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/mocha/node_modules/chalk/node_modules/supports-color": { - "version": "7.2.0", + "node_modules/jest-resolve-dependencies": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-resolve-dependencies/-/jest-resolve-dependencies-30.2.0.tgz", + "integrity": "sha512-xTOIGug/0RmIe3mmCqCT95yO0vj6JURrn1TKWlNbhiAefJRWINNPgwVkrVgt/YaerPzY3iItufd80v3lOrFJ2w==", "dev": true, "license": "MIT", "dependencies": { - "has-flag": "^4.0.0" + "jest-regex-util": "30.0.1", + "jest-snapshot": "30.2.0" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/mocha/node_modules/color-convert": { - "version": "2.0.1", + "node_modules/jest-resolve/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", "dependencies": { - "color-name": "~1.1.4" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" }, "engines": { - "node": ">=7.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/mocha/node_modules/color-name": { - "version": "1.1.4", + "node_modules/jest-resolve/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, - "license": "MIT" + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } }, - "node_modules/mocha/node_modules/debug": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.0.tgz", - "integrity": "sha512-6WTZ/IxCY/T6BALoZHaE4ctp9xm+Z5kY/pzYaCHRFeyVhojxlrm+46y68HA6hr0TcwEssoxNiDEUJQjfPZ/RYA==", + "node_modules/jest-runner": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-runner/-/jest-runner-30.2.0.tgz", + "integrity": "sha512-PqvZ2B2XEyPEbclp+gV6KO/F1FIFSbIwewRgmROCMBo/aZ6J1w8Qypoj2pEOcg3G2HzLlaP6VUtvwCI8dM3oqQ==", "dev": true, "license": "MIT", "dependencies": { - "ms": "^2.1.3" + "@jest/console": "30.2.0", + "@jest/environment": "30.2.0", + "@jest/test-result": "30.2.0", + "@jest/transform": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "emittery": "^0.13.1", + "exit-x": "^0.2.2", + "graceful-fs": "^4.2.11", + "jest-docblock": "30.2.0", + "jest-environment-node": "30.2.0", + "jest-haste-map": "30.2.0", + "jest-leak-detector": "30.2.0", + "jest-message-util": "30.2.0", + "jest-resolve": "30.2.0", + "jest-runtime": "30.2.0", + "jest-util": "30.2.0", + "jest-watcher": "30.2.0", + "jest-worker": "30.2.0", + "p-limit": "^3.1.0", + "source-map-support": "0.5.13" }, "engines": { - "node": ">=6.0" - }, - "peerDependenciesMeta": { - "supports-color": { - "optional": true - } + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/mocha/node_modules/escape-string-regexp": { - "version": "4.0.0", + "node_modules/jest-runner/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, "license": "MIT", "engines": { "node": ">=10" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/mocha/node_modules/glob": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/glob/-/glob-8.1.0.tgz", - "integrity": "sha512-r8hpEjiQEYlF2QU0df3dS+nxxSIreXQS1qRhMJM0Q5NDdR386C7jb7Hwwod8Fgiuex+k0GFjgft18yvxm5XoCQ==", - "deprecated": "Glob versions prior to v9 are no longer supported", + "node_modules/jest-runner/node_modules/jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^5.0.1", - "once": "^1.3.0" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" }, "engines": { - "node": ">=12" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/jest-runner/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" }, - "funding": { - "url": "https://github.com/sponsors/isaacs" + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/mocha/node_modules/has-flag": { - "version": "4.0.0", + "node_modules/jest-runner/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, "license": "MIT", "engines": { - "node": ">=8" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/mocha/node_modules/js-yaml": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.1.tgz", - "integrity": "sha512-qQKT4zQxXl8lLwBtHMWwaTcGfFOZviOJet3Oy/xmGk2gZH677CJM9EvtfdSkgWcATZhj/55JZ0rmy3myCT5lsA==", + "node_modules/jest-runner/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, + "license": "MIT", "dependencies": { - "argparse": "^2.0.1" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" }, - "bin": { - "js-yaml": "bin/js-yaml.js" + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/mocha/node_modules/log-symbols": { - "version": "4.1.0", + "node_modules/jest-runtime": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-runtime/-/jest-runtime-30.2.0.tgz", + "integrity": "sha512-p1+GVX/PJqTucvsmERPMgCPvQJpFt4hFbM+VN3n8TMo47decMUcJbt+rgzwrEme0MQUA/R+1de2axftTHkKckg==", "dev": true, "license": "MIT", "dependencies": { - "chalk": "^4.1.0", - "is-unicode-supported": "^0.1.0" + "@jest/environment": "30.2.0", + "@jest/fake-timers": "30.2.0", + "@jest/globals": "30.2.0", + "@jest/source-map": "30.0.1", + "@jest/test-result": "30.2.0", + "@jest/transform": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "cjs-module-lexer": "^2.1.0", + "collect-v8-coverage": "^1.0.2", + "glob": "^10.3.10", + "graceful-fs": "^4.2.11", + "jest-haste-map": "30.2.0", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-regex-util": "30.0.1", + "jest-resolve": "30.2.0", + "jest-snapshot": "30.2.0", + "jest-util": "30.2.0", + "slash": "^3.0.0", + "strip-bom": "^4.0.0" }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/jest-runtime/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true, + "license": "MIT", "engines": { "node": ">=10" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/mocha/node_modules/minimatch": { - "version": "5.1.6", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-5.1.6.tgz", - "integrity": "sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g==", + "node_modules/jest-runtime/node_modules/brace-expansion": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.2.tgz", + "integrity": "sha512-Jt0vHyM+jmUBqojB7E1NIYadt0vI0Qxjxd2TErW94wDz+E2LAm5vKMXXwg6ZZBTHPuUlDgQHKXvjGBdfcF1ZDQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0" + } + }, + "node_modules/jest-runtime/node_modules/foreground-child": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.3.1.tgz", + "integrity": "sha512-gIXjKqtFuWEgzFRJA9WCQeSJLZDjgJUOMCMzxtvFq/37KojM1BFGufqsCy0r4qSQmYLsZYMeyRqzIWOMup03sw==", "dev": true, "license": "ISC", "dependencies": { - "brace-expansion": "^2.0.1" + "cross-spawn": "^7.0.6", + "signal-exit": "^4.0.1" }, "engines": { - "node": ">=10" + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/mocha/node_modules/ms": { - "version": "2.1.3", - "dev": true, - "license": "MIT" - }, - "node_modules/mocha/node_modules/supports-color": { - "version": "8.1.1", + "node_modules/jest-runtime/node_modules/glob": { + "version": "10.5.0", + "resolved": "https://registry.npmjs.org/glob/-/glob-10.5.0.tgz", + "integrity": "sha512-DfXN8DfhJ7NH3Oe7cFmu3NCu1wKbkReJ8TorzSAFbSKrlNaQSKfIzqYqVY8zlbs2NLBbWpRiU52GX2PbaBVNkg==", "dev": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "has-flag": "^4.0.0" + "foreground-child": "^3.1.0", + "jackspeak": "^3.1.2", + "minimatch": "^9.0.4", + "minipass": "^7.1.2", + "package-json-from-dist": "^1.0.0", + "path-scurry": "^1.11.1" }, - "engines": { - "node": ">=10" + "bin": { + "glob": "dist/esm/bin.mjs" }, "funding": { - "url": "https://github.com/chalk/supports-color?sponsor=1" + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/module-deps": { - "version": "6.2.1", + "node_modules/jest-runtime/node_modules/jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, "license": "MIT", "dependencies": { - "browser-resolve": "^1.7.0", - "cached-path-relative": "^1.0.2", - "concat-stream": "~1.6.0", - "defined": "^1.0.0", - "detective": "^5.0.2", - "duplexer2": "^0.1.2", - "inherits": "^2.0.1", - "JSONStream": "^1.0.3", - "parents": "^1.0.0", - "readable-stream": "^2.0.2", - "resolve": "^1.4.0", - "stream-combiner2": "^1.1.1", - "subarg": "^1.0.0", - "through2": "^2.0.0", - "xtend": "^4.0.0" - }, - "bin": { - "module-deps": "bin/cmd.js" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" }, "engines": { - "node": ">= 0.8.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/ms": { - "version": "2.1.2", + "node_modules/jest-runtime/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, - "license": "MIT" + "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } }, - "node_modules/natural-compare": { - "version": "1.4.0", + "node_modules/jest-runtime/node_modules/minimatch": { + "version": "9.0.5", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.5.tgz", + "integrity": "sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==", "dev": true, - "license": "MIT" + "license": "ISC", + "dependencies": { + "brace-expansion": "^2.0.1" + }, + "engines": { + "node": ">=16 || 14 >=14.17" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } }, - "node_modules/negotiator": { - "version": "0.6.3", - "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.3.tgz", - "integrity": "sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg==", + "node_modules/jest-runtime/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, + "license": "MIT", "engines": { - "node": ">= 0.6" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/node-preload": { - "version": "0.2.1", + "node_modules/jest-runtime/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, "license": "MIT", "dependencies": { - "process-on-spawn": "^1.0.0" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/node-releases": { - "version": "2.0.10", + "node_modules/jest-runtime/node_modules/signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", "dev": true, - "license": "MIT" + "license": "ISC", + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } }, - "node_modules/normalize-path": { - "version": "3.0.0", + "node_modules/jest-snapshot": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-snapshot/-/jest-snapshot-30.2.0.tgz", + "integrity": "sha512-5WEtTy2jXPFypadKNpbNkZ72puZCa6UjSr/7djeecHWOu7iYhSXSnHScT8wBz3Rn8Ena5d5RYRcsyKIeqG1IyA==", "dev": true, "license": "MIT", + "dependencies": { + "@babel/core": "^7.27.4", + "@babel/generator": "^7.27.5", + "@babel/plugin-syntax-jsx": "^7.27.1", + "@babel/plugin-syntax-typescript": "^7.27.1", + "@babel/types": "^7.27.3", + "@jest/expect-utils": "30.2.0", + "@jest/get-type": "30.1.0", + "@jest/snapshot-utils": "30.2.0", + "@jest/transform": "30.2.0", + "@jest/types": "30.2.0", + "babel-preset-current-node-syntax": "^1.2.0", + "chalk": "^4.1.2", + "expect": "30.2.0", + "graceful-fs": "^4.2.11", + "jest-diff": "30.2.0", + "jest-matcher-utils": "30.2.0", + "jest-message-util": "30.2.0", + "jest-util": "30.2.0", + "pretty-format": "30.2.0", + "semver": "^7.7.2", + "synckit": "^0.11.8" + }, "engines": { - "node": ">=0.10.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/nyc": { - "version": "15.1.0", + "node_modules/jest-snapshot/node_modules/@jest/expect-utils": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-30.2.0.tgz", + "integrity": "sha512-1JnRfhqpD8HGpOmQp180Fo9Zt69zNtC+9lR+kT7NVL05tNXIi+QC8Csz7lfidMoVLPD3FnOtcmp0CEFnxExGEA==", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "@istanbuljs/load-nyc-config": "^1.0.0", - "@istanbuljs/schema": "^0.1.2", - "caching-transform": "^4.0.0", - "convert-source-map": "^1.7.0", - "decamelize": "^1.2.0", - "find-cache-dir": "^3.2.0", - "find-up": "^4.1.0", - "foreground-child": "^2.0.0", - "get-package-type": "^0.1.0", - "glob": "^7.1.6", - "istanbul-lib-coverage": "^3.0.0", - "istanbul-lib-hook": "^3.0.0", - "istanbul-lib-instrument": "^4.0.0", - "istanbul-lib-processinfo": "^2.0.2", - "istanbul-lib-report": "^3.0.0", - "istanbul-lib-source-maps": "^4.0.0", - "istanbul-reports": "^3.0.2", - "make-dir": "^3.0.0", - "node-preload": "^0.2.1", - "p-map": "^3.0.0", - "process-on-spawn": "^1.0.0", - "resolve-from": "^5.0.0", - "rimraf": "^3.0.0", - "signal-exit": "^3.0.2", - "spawn-wrap": "^2.0.0", - "test-exclude": "^6.0.0", - "yargs": "^15.0.2" - }, - "bin": { - "nyc": "bin/nyc.js" + "@jest/get-type": "30.1.0" }, "engines": { - "node": ">=8.9" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/nyc/node_modules/ansi-styles": { - "version": "4.3.0", + "node_modules/jest-snapshot/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, "license": "MIT", - "dependencies": { - "color-convert": "^2.0.1" - }, "engines": { - "node": ">=8" + "node": ">=10" }, "funding": { "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/nyc/node_modules/camelcase": { - "version": "5.3.1", + "node_modules/jest-snapshot/node_modules/expect": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/expect/-/expect-30.2.0.tgz", + "integrity": "sha512-u/feCi0GPsI+988gU2FLcsHyAHTU0MX1Wg68NhAnN7z/+C5wqG+CY8J53N9ioe8RXgaoz0nBR/TYMf3AycUuPw==", "dev": true, "license": "MIT", + "dependencies": { + "@jest/expect-utils": "30.2.0", + "@jest/get-type": "30.1.0", + "jest-matcher-utils": "30.2.0", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" + }, "engines": { - "node": ">=6" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/nyc/node_modules/cliui": { - "version": "6.0.0", + "node_modules/jest-snapshot/node_modules/jest-diff": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-30.2.0.tgz", + "integrity": "sha512-dQHFo3Pt4/NLlG5z4PxZ/3yZTZ1C7s9hveiOj+GCN+uT109NC2QgsoVZsVOAvbJ3RgKkvyLGXZV9+piDpWbm6A==", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.0", - "wrap-ansi": "^6.2.0" + "@jest/diff-sequences": "30.0.1", + "@jest/get-type": "30.1.0", + "chalk": "^4.1.2", + "pretty-format": "30.2.0" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/nyc/node_modules/color-convert": { - "version": "2.0.1", + "node_modules/jest-snapshot/node_modules/jest-matcher-utils": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-30.2.0.tgz", + "integrity": "sha512-dQ94Nq4dbzmUWkQ0ANAWS9tBRfqCrn0bV9AMYdOi/MHW726xn7eQmMeRTpX2ViC00bpNaWXq+7o4lIQ3AX13Hg==", "dev": true, "license": "MIT", "dependencies": { - "color-name": "~1.1.4" + "@jest/get-type": "30.1.0", + "chalk": "^4.1.2", + "jest-diff": "30.2.0", + "pretty-format": "30.2.0" }, "engines": { - "node": ">=7.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/nyc/node_modules/color-name": { - "version": "1.1.4", + "node_modules/jest-snapshot/node_modules/jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, - "license": "MIT" + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } }, - "node_modules/nyc/node_modules/convert-source-map": { - "version": "1.9.0", + "node_modules/jest-snapshot/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, - "license": "MIT" + "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } }, - "node_modules/nyc/node_modules/decamelize": { - "version": "1.2.0", + "node_modules/jest-snapshot/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, "license": "MIT", "engines": { - "node": ">=0.10.0" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/nyc/node_modules/find-up": { - "version": "4.1.0", + "node_modules/jest-snapshot/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, "license": "MIT", "dependencies": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/nyc/node_modules/locate-path": { - "version": "5.0.0", + "node_modules/jest-snapshot/node_modules/semver": { + "version": "7.7.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.3.tgz", + "integrity": "sha512-SdsKMrI9TdgjdweUSR9MweHA4EJ8YxHn8DFaDisvhVlUOe4BF1tLD7GAj0lIqWVl+dPb/rExr0Btby5loQm20Q==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/jest-util": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-29.7.0.tgz", + "integrity": "sha512-z6EbKajIpqGKU56y5KBUgy1dt1ihhQJgWzUlZHArA/+X2ad7Cb5iF+AK1EWVL/Bo7Rz9uurpqw6SiBCefUbCGA==", "dev": true, "license": "MIT", "dependencies": { - "p-locate": "^4.1.0" + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "ci-info": "^3.2.0", + "graceful-fs": "^4.2.9", + "picomatch": "^2.2.3" }, "engines": { - "node": ">=8" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/nyc/node_modules/p-limit": { - "version": "2.3.0", + "node_modules/jest-util/node_modules/@jest/schemas": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.3.tgz", + "integrity": "sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==", "dev": true, "license": "MIT", "dependencies": { - "p-try": "^2.0.0" + "@sinclair/typebox": "^0.27.8" }, "engines": { - "node": ">=6" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/nyc/node_modules/p-locate": { - "version": "4.1.0", + "node_modules/jest-util/node_modules/@jest/types": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.6.3.tgz", + "integrity": "sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw==", "dev": true, "license": "MIT", "dependencies": { - "p-limit": "^2.2.0" + "@jest/schemas": "^29.6.3", + "@types/istanbul-lib-coverage": "^2.0.0", + "@types/istanbul-reports": "^3.0.0", + "@types/node": "*", + "@types/yargs": "^17.0.8", + "chalk": "^4.0.0" }, "engines": { - "node": ">=8" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/nyc/node_modules/resolve-from": { - "version": "5.0.0", + "node_modules/jest-util/node_modules/@sinclair/typebox": { + "version": "0.27.8", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.8.tgz", + "integrity": "sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==", + "dev": true, + "license": "MIT" + }, + "node_modules/jest-util/node_modules/ci-info": { + "version": "3.9.0", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz", + "integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==", "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/sibiraj-s" + } + ], "license": "MIT", "engines": { "node": ">=8" } }, - "node_modules/nyc/node_modules/wrap-ansi": { - "version": "6.2.0", + "node_modules/jest-validate": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-30.2.0.tgz", + "integrity": "sha512-FBGWi7dP2hpdi8nBoWxSsLvBFewKAg0+uSQwBaof4Y4DPgBabXgpSYC5/lR7VmnIlSpASmCi/ntRWPbv7089Pw==", "dev": true, "license": "MIT", "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" + "@jest/get-type": "30.1.0", + "@jest/types": "30.2.0", + "camelcase": "^6.3.0", + "chalk": "^4.1.2", + "leven": "^3.1.0", + "pretty-format": "30.2.0" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/nyc/node_modules/y18n": { - "version": "4.0.3", + "node_modules/jest-validate/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, - "license": "ISC" + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } }, - "node_modules/nyc/node_modules/yargs": { - "version": "15.4.1", + "node_modules/jest-validate/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, "license": "MIT", "dependencies": { - "cliui": "^6.0.0", - "decamelize": "^1.2.0", - "find-up": "^4.1.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^4.2.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^18.1.2" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/nyc/node_modules/yargs-parser": { - "version": "18.1.3", + "node_modules/jest-watcher": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-30.2.0.tgz", + "integrity": "sha512-PYxa28dxJ9g777pGm/7PrbnMeA0Jr7osHP9bS7eJy9DuAjMgdGtxgf0uKMyoIsTWAkIbUW5hSDdJ3urmgXBqxg==", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" + "@jest/test-result": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "ansi-escapes": "^4.3.2", + "chalk": "^4.1.2", + "emittery": "^0.13.1", + "jest-util": "30.2.0", + "string-length": "^4.0.2" }, "engines": { - "node": ">=6" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/object-assign": { - "version": "4.1.1", + "node_modules/jest-watcher/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, "engines": { - "node": ">=0.10.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/object-inspect": { - "version": "1.13.2", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.2.tgz", - "integrity": "sha512-IRZSRuzJiynemAXPYtPe5BoI/RESNYR7TYm50MC5Mqbd3Jmw5y790sErYw3V6SryFJD64b74qQQs9wn5Bg/k3g==", + "node_modules/jest-watcher/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, + "license": "MIT", "engines": { - "node": ">= 0.4" + "node": ">=12" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/on-finished": { - "version": "2.3.0", + "node_modules/jest-watcher/node_modules/string-length": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/string-length/-/string-length-4.0.2.tgz", + "integrity": "sha512-+l6rNN5fYHNhZZy41RXsYptCjA2Igmq4EG7kZAYFQI1E1VTXarr6ZPXBg6eq7Y6eK4FEhY6AJlyuFIb/v/S0VQ==", "dev": true, "license": "MIT", "dependencies": { - "ee-first": "1.1.1" + "char-regex": "^1.0.2", + "strip-ansi": "^6.0.0" }, "engines": { - "node": ">= 0.8" + "node": ">=10" } }, - "node_modules/once": { - "version": "1.4.0", + "node_modules/jest-worker": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-30.2.0.tgz", + "integrity": "sha512-0Q4Uk8WF7BUwqXHuAjc23vmopWJw5WH7w2tqBoUOZpOjW/ZnR44GXXd1r82RvnmI2GZge3ivrYXk/BE2+VtW2g==", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "wrappy": "1" + "@types/node": "*", + "@ungap/structured-clone": "^1.3.0", + "jest-util": "30.2.0", + "merge-stream": "^2.0.0", + "supports-color": "^8.1.1" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/os-browserify": { - "version": "0.3.0", - "dev": true, - "license": "MIT" - }, - "node_modules/p-limit": { - "version": "3.1.0", + "node_modules/jest-worker/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", "dependencies": { - "yocto-queue": "^0.1.0" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" }, "engines": { - "node": ">=10" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/jest-worker/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/p-locate": { - "version": "5.0.0", + "node_modules/jest-worker/node_modules/supports-color": { + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", + "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", "dev": true, "license": "MIT", "dependencies": { - "p-limit": "^3.0.2" + "has-flag": "^4.0.0" }, "engines": { "node": ">=10" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/chalk/supports-color?sponsor=1" } }, - "node_modules/p-map": { - "version": "3.0.0", + "node_modules/js-sdsl": { + "version": "4.3.0", "dev": true, "license": "MIT", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/js-sdsl" + } + }, + "node_modules/js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/js-yaml": { + "version": "3.14.2", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.2.tgz", + "integrity": "sha512-PMSmkqxr106Xa156c2M265Z+FTrPl+oxd/rgOQy2tijQeK5TxQ43psO1ZCwhVOSdnn+RzkzlRz/eY4BgJBYVpg==", + "dev": true, "dependencies": { - "aggregate-error": "^3.0.0" + "argparse": "^1.0.7", + "esprima": "^4.0.0" }, - "engines": { - "node": ">=8" + "bin": { + "js-yaml": "bin/js-yaml.js" } }, - "node_modules/p-try": { - "version": "2.2.0", + "node_modules/jsesc": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-3.1.0.tgz", + "integrity": "sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA==", "dev": true, "license": "MIT", + "bin": { + "jsesc": "bin/jsesc" + }, "engines": { "node": ">=6" } }, - "node_modules/package-hash": { - "version": "4.0.0", + "node_modules/json-parse-even-better-errors": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", + "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", "dev": true, - "license": "ISC", - "dependencies": { - "graceful-fs": "^4.1.15", - "hasha": "^5.0.0", - "lodash.flattendeep": "^4.4.0", - "release-zalgo": "^1.0.0" - }, - "engines": { - "node": ">=8" - } + "license": "MIT" }, - "node_modules/pako": { - "version": "1.0.10", + "node_modules/json-schema-traverse": { + "version": "0.4.1", "dev": true, - "license": "(MIT AND Zlib)" + "license": "MIT" }, - "node_modules/parent-module": { + "node_modules/json-stable-stringify-without-jsonify": { "version": "1.0.1", "dev": true, + "license": "MIT" + }, + "node_modules/json5": { + "version": "2.2.3", + "dev": true, "license": "MIT", - "dependencies": { - "callsites": "^3.0.0" + "bin": { + "json5": "lib/cli.js" }, "engines": { "node": ">=6" } }, - "node_modules/parents": { - "version": "1.0.1", + "node_modules/leven": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/leven/-/leven-3.1.0.tgz", + "integrity": "sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==", "dev": true, "license": "MIT", - "dependencies": { - "path-platform": "~0.11.15" + "engines": { + "node": ">=6" } }, - "node_modules/parse-asn1": { - "version": "5.1.6", - "resolved": "https://registry.npmjs.org/parse-asn1/-/parse-asn1-5.1.6.tgz", - "integrity": "sha512-RnZRo1EPU6JBnra2vGHj0yhp6ebyjBZpmUCLHWiFhxlzvBCCpAuZ7elsBp1PVAbQN0/04VD/19rfzlBSwLstMw==", + "node_modules/lines-and-columns": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz", + "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==", "dev": true, - "dependencies": { - "asn1.js": "^5.2.0", - "browserify-aes": "^1.0.0", - "evp_bytestokey": "^1.0.0", - "pbkdf2": "^3.0.3", - "safe-buffer": "^5.1.1" - } + "license": "MIT" }, - "node_modules/parseurl": { - "version": "1.3.3", + "node_modules/locate-path": { + "version": "6.0.0", "dev": true, "license": "MIT", + "dependencies": { + "p-locate": "^5.0.0" + }, "engines": { - "node": ">= 0.8" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/path-browserify": { - "version": "0.0.1", + "node_modules/lodash": { + "version": "4.17.21", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.merge": { + "version": "4.6.2", + "dev": true, + "license": "MIT" + }, + "node_modules/lru-cache": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz", + "integrity": "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==", "dev": true, - "license": "MIT" + "license": "ISC", + "dependencies": { + "yallist": "^3.0.2" + } }, - "node_modules/path-exists": { - "version": "4.0.0", + "node_modules/make-dir": { + "version": "3.1.0", "dev": true, "license": "MIT", + "dependencies": { + "semver": "^6.0.0" + }, "engines": { "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/path-is-absolute": { - "version": "1.0.1", + "node_modules/make-dir/node_modules/semver": { + "version": "6.3.0", "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" + "license": "ISC", + "bin": { + "semver": "bin/semver.js" } }, - "node_modules/path-key": { - "version": "3.1.1", + "node_modules/makeerror": { + "version": "1.0.12", + "resolved": "https://registry.npmjs.org/makeerror/-/makeerror-1.0.12.tgz", + "integrity": "sha512-JmqCvUhmt43madlpFzG4BQzG2Z3m6tvQDNKdClZnO3VbIudJYmxsT0FNJMeiB2+JTSlTQTSbU8QdesVmwJcmLg==", "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" + "license": "BSD-3-Clause", + "dependencies": { + "tmpl": "1.0.5" } }, - "node_modules/path-parse": { - "version": "1.0.7", + "node_modules/merge-stream": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", + "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", "dev": true, "license": "MIT" }, - "node_modules/path-platform": { - "version": "0.11.15", + "node_modules/micromatch": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz", + "integrity": "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==", "dev": true, "license": "MIT", + "dependencies": { + "braces": "^3.0.3", + "picomatch": "^2.3.1" + }, "engines": { - "node": ">= 0.8.0" + "node": ">=8.6" } }, - "node_modules/pathval": { - "version": "1.1.1", + "node_modules/mimic-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", + "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", "dev": true, "license": "MIT", "engines": { - "node": "*" + "node": ">=6" } }, - "node_modules/pbkdf2": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/pbkdf2/-/pbkdf2-3.1.3.tgz", - "integrity": "sha512-wfRLBZ0feWRhCIkoMB6ete7czJcnNnqRpcoWQBLqatqXXmelSRqfdDK4F3u9T2s2cXas/hQJcryI/4lAL+XTlA==", + "node_modules/minimatch": { + "version": "3.0.8", "dev": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "create-hash": "~1.1.3", - "create-hmac": "^1.1.7", - "ripemd160": "=2.0.1", - "safe-buffer": "^5.2.1", - "sha.js": "^2.4.11", - "to-buffer": "^1.2.0" + "brace-expansion": "^1.1.7" }, "engines": { - "node": ">=0.12" + "node": "*" } }, - "node_modules/pbkdf2/node_modules/create-hash": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/create-hash/-/create-hash-1.1.3.tgz", - "integrity": "sha512-snRpch/kwQhcdlnZKYanNF1m0RDlrCdSKQaH87w1FCFPVPNCQ/Il9QJKAX2jVBZddRdaHBMC+zXa9Gw9tmkNUA==", + "node_modules/minipass": { + "version": "7.1.2", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.2.tgz", + "integrity": "sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw==", "dev": true, - "license": "MIT", - "dependencies": { - "cipher-base": "^1.0.1", - "inherits": "^2.0.1", - "ripemd160": "^2.0.0", - "sha.js": "^2.4.0" + "license": "ISC", + "engines": { + "node": ">=16 || 14 >=14.17" } }, - "node_modules/pbkdf2/node_modules/hash-base": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/hash-base/-/hash-base-2.0.2.tgz", - "integrity": "sha512-0TROgQ1/SxE6KmxWSvXHvRj90/Xo1JvZShofnYF+f6ZsGtR4eES7WfrQzPalmyagfKZCXpVnitiRebZulWsbiw==", + "node_modules/ms": { + "version": "2.1.2", "dev": true, - "license": "MIT", - "dependencies": { - "inherits": "^2.0.1" - } + "license": "MIT" }, - "node_modules/pbkdf2/node_modules/ripemd160": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/ripemd160/-/ripemd160-2.0.1.tgz", - "integrity": "sha512-J7f4wutN8mdbV08MJnXibYpCOPHR+yzy+iQ/AsjMv2j8cLavQ8VGagDFUwwTAdF8FmRKVeNpbTTEwNHCW1g94w==", + "node_modules/napi-postinstall": { + "version": "0.3.4", + "resolved": "https://registry.npmjs.org/napi-postinstall/-/napi-postinstall-0.3.4.tgz", + "integrity": "sha512-PHI5f1O0EP5xJ9gQmFGMS6IZcrVvTjpXjz7Na41gTE7eE2hK11lg04CECCYEEjdc17EV4DO+fkGEtt7TpTaTiQ==", "dev": true, "license": "MIT", - "dependencies": { - "hash-base": "^2.0.0", - "inherits": "^2.0.1" + "bin": { + "napi-postinstall": "lib/cli.js" + }, + "engines": { + "node": "^12.20.0 || ^14.18.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/napi-postinstall" } }, - "node_modules/picocolors": { - "version": "1.0.0", + "node_modules/natural-compare": { + "version": "1.4.0", "dev": true, - "license": "ISC" + "license": "MIT" }, - "node_modules/picomatch": { - "version": "2.3.1", + "node_modules/node-int64": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz", + "integrity": "sha512-O5lz91xSOeoXP6DulyHfllpq+Eg00MWitZIbtPfoSEvqIHdl5gfcY6hYzDWnj0qD5tz52PI08u9qUvSVeUBeHw==", "dev": true, - "license": "MIT", - "engines": { - "node": ">=8.6" - }, - "funding": { - "url": "https://github.com/sponsors/jonschlinkert" - } + "license": "MIT" }, - "node_modules/pkg-dir": { - "version": "4.2.0", + "node_modules/node-releases": { + "version": "2.0.27", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.27.tgz", + "integrity": "sha512-nmh3lCkYZ3grZvqcCH+fjmQ7X+H0OeZgP40OierEaAptX4XofMh5kwNbWh7lBduUzCcV/8kZ+NDLCwm2iorIlA==", + "dev": true, + "license": "MIT" + }, + "node_modules/normalize-path": { + "version": "3.0.0", "dev": true, "license": "MIT", - "dependencies": { - "find-up": "^4.0.0" - }, "engines": { - "node": ">=8" + "node": ">=0.10.0" } }, - "node_modules/pkg-dir/node_modules/find-up": { - "version": "4.1.0", + "node_modules/npm-run-path": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-4.0.1.tgz", + "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==", "dev": true, "license": "MIT", "dependencies": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" + "path-key": "^3.0.0" }, "engines": { "node": ">=8" } }, - "node_modules/pkg-dir/node_modules/locate-path": { - "version": "5.0.0", + "node_modules/once": { + "version": "1.4.0", "dev": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "p-locate": "^4.1.0" - }, - "engines": { - "node": ">=8" + "wrappy": "1" } }, - "node_modules/pkg-dir/node_modules/p-limit": { - "version": "2.3.0", + "node_modules/onetime": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz", + "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==", "dev": true, "license": "MIT", "dependencies": { - "p-try": "^2.0.0" + "mimic-fn": "^2.1.0" }, "engines": { "node": ">=6" @@ -4885,358 +6258,286 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/pkg-dir/node_modules/p-locate": { - "version": "4.1.0", + "node_modules/p-limit": { + "version": "3.1.0", "dev": true, "license": "MIT", "dependencies": { - "p-limit": "^2.2.0" + "yocto-queue": "^0.1.0" }, "engines": { - "node": ">=8" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/platform": { - "version": "1.3.5", - "dev": true, - "license": "MIT" - }, - "node_modules/plur": { - "version": "2.1.2", + "node_modules/p-locate": { + "version": "5.0.0", "dev": true, "license": "MIT", "dependencies": { - "irregular-plurals": "^1.0.0" + "p-limit": "^3.0.2" }, "engines": { - "node": ">=0.10.0" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/possible-typed-array-names": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/possible-typed-array-names/-/possible-typed-array-names-1.1.0.tgz", - "integrity": "sha512-/+5VFTchJDoVj3bhoqi6UeymcD00DAwb1nJwamzPvHEszJ4FpF6SNNbUbOS8yI56qHzdV8eK0qEfOSiodkTdxg==", + "node_modules/p-try": { + "version": "2.2.0", "dev": true, "license": "MIT", "engines": { - "node": ">= 0.4" + "node": ">=6" } }, - "node_modules/process": { - "version": "0.11.10", + "node_modules/package-json-from-dist": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/package-json-from-dist/-/package-json-from-dist-1.0.1.tgz", + "integrity": "sha512-UEZIS3/by4OC8vL3P2dTXRETpebLI2NiI5vIrjaD/5UtrkFX/tNbwjTSRAGC/+7CAo2pIcBaRgWmcBBHcsaCIw==", + "dev": true, + "license": "BlueOak-1.0.0" + }, + "node_modules/parent-module": { + "version": "1.0.1", "dev": true, "license": "MIT", + "dependencies": { + "callsites": "^3.0.0" + }, "engines": { - "node": ">= 0.6.0" + "node": ">=6" } }, - "node_modules/process-nextick-args": { - "version": "2.0.1", - "dev": true, - "license": "MIT" - }, - "node_modules/process-on-spawn": { - "version": "1.0.0", + "node_modules/parse-json": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz", + "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==", "dev": true, "license": "MIT", "dependencies": { - "fromentries": "^1.2.0" + "@babel/code-frame": "^7.0.0", + "error-ex": "^1.3.1", + "json-parse-even-better-errors": "^2.3.0", + "lines-and-columns": "^1.1.6" }, "engines": { "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/public-encrypt": { - "version": "4.0.3", + "node_modules/path-exists": { + "version": "4.0.0", "dev": true, "license": "MIT", - "dependencies": { - "bn.js": "^4.1.0", - "browserify-rsa": "^4.0.0", - "create-hash": "^1.1.0", - "parse-asn1": "^5.0.0", - "randombytes": "^2.0.1", - "safe-buffer": "^5.1.2" + "engines": { + "node": ">=8" } }, - "node_modules/punycode": { - "version": "1.4.1", + "node_modules/path-is-absolute": { + "version": "1.0.1", "dev": true, - "license": "MIT" + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } }, - "node_modules/qjobs": { - "version": "1.2.0", + "node_modules/path-key": { + "version": "3.1.1", "dev": true, "license": "MIT", "engines": { - "node": ">=0.9" + "node": ">=8" } }, - "node_modules/qs": { - "version": "6.13.0", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.0.tgz", - "integrity": "sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==", + "node_modules/path-scurry": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-1.11.1.tgz", + "integrity": "sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA==", "dev": true, + "license": "BlueOak-1.0.0", "dependencies": { - "side-channel": "^1.0.6" + "lru-cache": "^10.2.0", + "minipass": "^5.0.0 || ^6.0.2 || ^7.0.0" }, "engines": { - "node": ">=0.6" + "node": ">=16 || 14 >=14.18" }, "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/querystring": { - "version": "0.2.0", - "dev": true, - "engines": { - "node": ">=0.4.x" - } - }, - "node_modules/querystring-es3": { - "version": "0.2.1", - "dev": true, - "engines": { - "node": ">=0.4.x" + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/queue-microtask": { - "version": "1.2.3", + "node_modules/path-scurry/node_modules/lru-cache": { + "version": "10.4.3", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.4.3.tgz", + "integrity": "sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==", "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "MIT" + "license": "ISC" }, - "node_modules/randombytes": { - "version": "2.1.0", + "node_modules/picocolors": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", "dev": true, - "license": "MIT", - "dependencies": { - "safe-buffer": "^5.1.0" - } + "license": "ISC" }, - "node_modules/randomfill": { - "version": "1.0.4", + "node_modules/picomatch": { + "version": "2.3.1", "dev": true, "license": "MIT", - "dependencies": { - "randombytes": "^2.0.5", - "safe-buffer": "^5.1.0" + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/range-parser": { - "version": "1.2.1", + "node_modules/pirates": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/pirates/-/pirates-4.0.7.tgz", + "integrity": "sha512-TfySrs/5nm8fQJDcBDuUng3VOUKsd7S+zqvbOTiGXHfxX4wK31ard+hoNuvkicM/2YFzlpDgABOevKSsB4G/FA==", "dev": true, "license": "MIT", "engines": { - "node": ">= 0.6" + "node": ">= 6" } }, - "node_modules/raw-body": { - "version": "2.5.2", + "node_modules/pkg-dir": { + "version": "4.2.0", "dev": true, "license": "MIT", "dependencies": { - "bytes": "3.1.2", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "unpipe": "1.0.0" + "find-up": "^4.0.0" }, "engines": { - "node": ">= 0.8" - } - }, - "node_modules/read-only-stream": { - "version": "2.0.0", - "dev": true, - "license": "MIT", - "dependencies": { - "readable-stream": "^2.0.2" - } - }, - "node_modules/readable-stream": { - "version": "2.3.6", - "dev": true, - "license": "MIT", - "dependencies": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.1.1", - "util-deprecate": "~1.0.1" - } - }, - "node_modules/readable-stream/node_modules/safe-buffer": { - "version": "5.1.2", - "dev": true, - "license": "MIT" - }, - "node_modules/readable-stream/node_modules/string_decoder": { - "version": "1.1.1", - "dev": true, - "license": "MIT", - "dependencies": { - "safe-buffer": "~5.1.0" + "node": ">=8" } }, - "node_modules/readdirp": { - "version": "3.6.0", + "node_modules/pkg-dir/node_modules/find-up": { + "version": "4.1.0", "dev": true, "license": "MIT", "dependencies": { - "picomatch": "^2.2.1" + "locate-path": "^5.0.0", + "path-exists": "^4.0.0" }, "engines": { - "node": ">=8.10.0" + "node": ">=8" } }, - "node_modules/regexpp": { - "version": "3.2.0", + "node_modules/pkg-dir/node_modules/locate-path": { + "version": "5.0.0", "dev": true, "license": "MIT", + "dependencies": { + "p-locate": "^4.1.0" + }, "engines": { "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/mysticatea" } }, - "node_modules/release-zalgo": { - "version": "1.0.0", + "node_modules/pkg-dir/node_modules/p-limit": { + "version": "2.3.0", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "es6-error": "^4.0.1" + "p-try": "^2.0.0" }, "engines": { - "node": ">=4" + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/require-directory": { - "version": "2.1.1", + "node_modules/pkg-dir/node_modules/p-locate": { + "version": "4.1.0", "dev": true, "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/require-main-filename": { - "version": "2.0.0", - "dev": true, - "license": "ISC" - }, - "node_modules/requirejs": { - "version": "2.3.7", - "resolved": "https://registry.npmjs.org/requirejs/-/requirejs-2.3.7.tgz", - "integrity": "sha512-DouTG8T1WanGok6Qjg2SXuCMzszOo0eHeH9hDZ5Y4x8Je+9JB38HdTLT4/VA8OaUhBa0JPVHJ0pyBkM1z+pDsw==", - "dev": true, - "bin": { - "r_js": "bin/r.js", - "r.js": "bin/r.js" + "dependencies": { + "p-limit": "^2.2.0" }, "engines": { - "node": ">=0.4.0" + "node": ">=8" } }, - "node_modules/requires-port": { - "version": "1.0.0", + "node_modules/platform": { + "version": "1.3.5", "dev": true, "license": "MIT" }, - "node_modules/resolve": { - "version": "1.12.0", + "node_modules/pretty-format": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-29.7.0.tgz", + "integrity": "sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ==", "dev": true, "license": "MIT", "dependencies": { - "path-parse": "^1.0.6" - } - }, - "node_modules/resolve-from": { - "version": "4.0.0", - "dev": true, - "license": "MIT", + "@jest/schemas": "^29.6.3", + "ansi-styles": "^5.0.0", + "react-is": "^18.0.0" + }, "engines": { - "node": ">=4" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/reusify": { - "version": "1.0.4", + "node_modules/pretty-format/node_modules/@jest/schemas": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.3.tgz", + "integrity": "sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==", "dev": true, "license": "MIT", + "dependencies": { + "@sinclair/typebox": "^0.27.8" + }, "engines": { - "iojs": ">=1.0.0", - "node": ">=0.10.0" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/rfdc": { - "version": "1.3.0", + "node_modules/pretty-format/node_modules/@sinclair/typebox": { + "version": "0.27.8", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.8.tgz", + "integrity": "sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==", "dev": true, "license": "MIT" }, - "node_modules/rimraf": { - "version": "3.0.2", + "node_modules/pretty-format/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, - "license": "ISC", - "dependencies": { - "glob": "^7.1.3" - }, - "bin": { - "rimraf": "bin.js" + "license": "MIT", + "engines": { + "node": ">=10" }, "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/ripemd160": { - "version": "2.0.2", - "dev": true, - "license": "MIT", - "dependencies": { - "hash-base": "^3.0.0", - "inherits": "^2.0.1" + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/run-parallel": { - "version": "1.2.0", + "node_modules/pure-rand": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/pure-rand/-/pure-rand-7.0.1.tgz", + "integrity": "sha512-oTUZM/NAZS8p7ANR3SHh30kXB+zK2r2BPcEn/awJIbOvq82WoMN4p62AWWp3Hhw50G0xMsw1mhIBLqHw64EcNQ==", "dev": true, "funding": [ { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" + "type": "individual", + "url": "https://github.com/sponsors/dubzzz" }, { - "type": "consulting", - "url": "https://feross.org/support" + "type": "opencollective", + "url": "https://opencollective.com/fast-check" } ], - "license": "MIT", - "dependencies": { - "queue-microtask": "^1.2.2" - } + "license": "MIT" }, - "node_modules/safe-buffer": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", - "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "node_modules/queue-microtask": { + "version": "1.2.3", "dev": true, "funding": [ { @@ -5251,374 +6552,266 @@ "type": "consulting", "url": "https://feross.org/support" } - ] - }, - "node_modules/safer-buffer": { - "version": "2.1.2", - "dev": true, + ], "license": "MIT" }, - "node_modules/seedrandom": { - "version": "3.0.5", + "node_modules/react-is": { + "version": "18.3.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz", + "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==", "dev": true, "license": "MIT" }, - "node_modules/semver": { - "version": "7.5.4", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", - "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "node_modules/regexpp": { + "version": "3.2.0", "dev": true, - "dependencies": { - "lru-cache": "^6.0.0" - }, - "bin": { - "semver": "bin/semver.js" - }, + "license": "MIT", "engines": { - "node": ">=10" - } - }, - "node_modules/semver/node_modules/lru-cache": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", - "dev": true, - "dependencies": { - "yallist": "^4.0.0" + "node": ">=8" }, - "engines": { - "node": ">=10" - } - }, - "node_modules/semver/node_modules/yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true - }, - "node_modules/serialize-javascript": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.2.tgz", - "integrity": "sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "randombytes": "^2.1.0" + "funding": { + "url": "https://github.com/sponsors/mysticatea" } }, - "node_modules/set-blocking": { - "version": "2.0.0", - "dev": true, - "license": "ISC" - }, - "node_modules/set-function-length": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", - "integrity": "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==", + "node_modules/require-directory": { + "version": "2.1.1", "dev": true, - "dependencies": { - "define-data-property": "^1.1.4", - "es-errors": "^1.3.0", - "function-bind": "^1.1.2", - "get-intrinsic": "^1.2.4", - "gopd": "^1.0.1", - "has-property-descriptors": "^1.0.2" - }, + "license": "MIT", "engines": { - "node": ">= 0.4" + "node": ">=0.10.0" } }, - "node_modules/setprototypeof": { - "version": "1.2.0", - "dev": true, - "license": "ISC" - }, - "node_modules/sha.js": { - "version": "2.4.12", - "resolved": "https://registry.npmjs.org/sha.js/-/sha.js-2.4.12.tgz", - "integrity": "sha512-8LzC5+bvI45BjpfXU8V5fdU2mfeKiQe1D1gIMn7XUlF3OTUrpdJpPPH4EMAnF0DsHHdSZqCdSss5qCmJKuiO3w==", + "node_modules/requirejs": { + "version": "2.3.7", + "resolved": "https://registry.npmjs.org/requirejs/-/requirejs-2.3.7.tgz", + "integrity": "sha512-DouTG8T1WanGok6Qjg2SXuCMzszOo0eHeH9hDZ5Y4x8Je+9JB38HdTLT4/VA8OaUhBa0JPVHJ0pyBkM1z+pDsw==", "dev": true, - "dependencies": { - "inherits": "^2.0.4", - "safe-buffer": "^5.2.1", - "to-buffer": "^1.2.0" - }, "bin": { - "sha.js": "bin.js" + "r_js": "bin/r.js", + "r.js": "bin/r.js" }, "engines": { - "node": ">= 0.10" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/shasum": { - "version": "1.0.2", - "dev": true, - "license": "MIT", - "dependencies": { - "json-stable-stringify": "~0.0.0", - "sha.js": "~2.4.4" + "node": ">=0.4.0" } }, - "node_modules/shebang-command": { - "version": "2.0.0", + "node_modules/resolve-cwd": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/resolve-cwd/-/resolve-cwd-3.0.0.tgz", + "integrity": "sha512-OrZaX2Mb+rJCpH/6CpSqt9xFVpN++x01XnN2ie9g6P5/3xelLAkXWVADpdz1IHD/KFfEXyE6V0U01OQ3UO2rEg==", "dev": true, "license": "MIT", "dependencies": { - "shebang-regex": "^3.0.0" + "resolve-from": "^5.0.0" }, "engines": { "node": ">=8" } }, - "node_modules/shebang-regex": { - "version": "3.0.0", + "node_modules/resolve-cwd/node_modules/resolve-from": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", + "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", "dev": true, "license": "MIT", "engines": { "node": ">=8" } }, - "node_modules/shell-quote": { - "version": "1.8.0", + "node_modules/resolve-from": { + "version": "4.0.0", "dev": true, "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/side-channel": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.6.tgz", - "integrity": "sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.7", - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.4", - "object-inspect": "^1.13.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/signal-exit": { - "version": "3.0.7", - "dev": true, - "license": "ISC" - }, - "node_modules/simple-concat": { - "version": "1.0.0", - "dev": true, - "license": "MIT" - }, - "node_modules/socket.io": { - "version": "4.8.0", - "resolved": "https://registry.npmjs.org/socket.io/-/socket.io-4.8.0.tgz", - "integrity": "sha512-8U6BEgGjQOfGz3HHTYaC/L1GaxDCJ/KM0XTkJly0EhZ5U/du9uNEZy4ZgYzEzIqlx2CMm25CrCqr1ck899eLNA==", - "dev": true, - "dependencies": { - "accepts": "~1.3.4", - "base64id": "~2.0.0", - "cors": "~2.8.5", - "debug": "~4.3.2", - "engine.io": "~6.6.0", - "socket.io-adapter": "~2.5.2", - "socket.io-parser": "~4.2.4" - }, "engines": { - "node": ">=10.2.0" + "node": ">=4" } }, - "node_modules/socket.io-adapter": { - "version": "2.5.2", + "node_modules/reusify": { + "version": "1.0.4", "dev": true, "license": "MIT", - "dependencies": { - "ws": "~8.11.0" + "engines": { + "iojs": ">=1.0.0", + "node": ">=0.10.0" } }, - "node_modules/socket.io-parser": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-4.2.4.tgz", - "integrity": "sha512-/GbIKmo8ioc+NIWIhwdecY0ge+qVBSMdgxGygevmdHj24bsfgtCmcUUcQ5ZzcylGFHsN3k4HB4Cgkl96KVnuew==", + "node_modules/rimraf": { + "version": "3.0.2", "dev": true, + "license": "ISC", "dependencies": { - "@socket.io/component-emitter": "~3.1.0", - "debug": "~4.3.1" + "glob": "^7.1.3" }, - "engines": { - "node": ">=10.0.0" - } - }, - "node_modules/source-map": { - "version": "0.5.7", - "dev": true, - "license": "BSD-3-Clause", - "engines": { - "node": ">=0.10.0" + "bin": { + "rimraf": "bin.js" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/spawn-wrap": { - "version": "2.0.0", + "node_modules/run-parallel": { + "version": "1.2.0", "dev": true, - "license": "ISC", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", "dependencies": { - "foreground-child": "^2.0.0", - "is-windows": "^1.0.2", - "make-dir": "^3.0.0", - "rimraf": "^3.0.0", - "signal-exit": "^3.0.2", - "which": "^2.0.1" - }, - "engines": { - "node": ">=8" + "queue-microtask": "^1.2.2" } }, - "node_modules/spawn-wrap/node_modules/which": { - "version": "2.0.2", + "node_modules/semver": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", "dev": true, - "license": "ISC", "dependencies": { - "isexe": "^2.0.0" + "lru-cache": "^6.0.0" }, "bin": { - "node-which": "bin/node-which" + "semver": "bin/semver.js" }, "engines": { - "node": ">= 8" + "node": ">=10" } }, - "node_modules/sprintf": { - "version": "0.1.5", + "node_modules/semver/node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", "dev": true, - "license": "BSD-3-Clause", + "dependencies": { + "yallist": "^4.0.0" + }, "engines": { - "node": ">=0.2.4" + "node": ">=10" } }, - "node_modules/sprintf-js": { - "version": "1.0.3", - "dev": true, - "license": "BSD-3-Clause" + "node_modules/semver/node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", + "dev": true }, - "node_modules/statuses": { - "version": "1.5.0", + "node_modules/shebang-command": { + "version": "2.0.0", "dev": true, "license": "MIT", + "dependencies": { + "shebang-regex": "^3.0.0" + }, "engines": { - "node": ">= 0.6" + "node": ">=8" } }, - "node_modules/stream-browserify": { - "version": "2.0.2", + "node_modules/shebang-regex": { + "version": "3.0.0", "dev": true, "license": "MIT", - "dependencies": { - "inherits": "~2.0.1", - "readable-stream": "^2.0.2" + "engines": { + "node": ">=8" } }, - "node_modules/stream-combiner2": { - "version": "1.1.1", + "node_modules/signal-exit": { + "version": "3.0.7", "dev": true, - "license": "MIT", - "dependencies": { - "duplexer2": "~0.1.0", - "readable-stream": "^2.0.2" - } + "license": "ISC" }, - "node_modules/stream-http": { - "version": "3.1.0", + "node_modules/slash": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", + "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", "dev": true, "license": "MIT", - "dependencies": { - "builtin-status-codes": "^3.0.0", - "inherits": "^2.0.1", - "readable-stream": "^3.0.6", - "xtend": "^4.0.0" + "engines": { + "node": ">=8" } }, - "node_modules/stream-http/node_modules/readable-stream": { - "version": "3.4.0", + "node_modules/source-map-support": { + "version": "0.5.13", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.13.tgz", + "integrity": "sha512-SHSKFHadjVA5oR4PPqhtAVdcBWwRYVd6g6cAXnIbRiIwc2EhPrTuKUBdSLvlEKyIP3GCf89fltvcZiP9MMFA1w==", "dev": true, "license": "MIT", "dependencies": { - "inherits": "^2.0.3", - "string_decoder": "^1.1.1", - "util-deprecate": "^1.0.1" - }, - "engines": { - "node": ">= 6" + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" } }, - "node_modules/stream-splicer": { - "version": "2.0.1", + "node_modules/source-map-support/node_modules/source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", "dev": true, - "license": "MIT", - "dependencies": { - "inherits": "^2.0.1", - "readable-stream": "^2.0.2" + "license": "BSD-3-Clause", + "engines": { + "node": ">=0.10.0" } }, - "node_modules/streamroller": { - "version": "3.1.5", + "node_modules/sprintf": { + "version": "0.1.5", "dev": true, - "license": "MIT", - "dependencies": { - "date-format": "^4.0.14", - "debug": "^4.3.4", - "fs-extra": "^8.1.0" - }, + "license": "BSD-3-Clause", "engines": { - "node": ">=8.0" + "node": ">=0.2.4" } }, - "node_modules/string_decoder": { - "version": "1.3.0", + "node_modules/sprintf-js": { + "version": "1.0.3", "dev": true, - "license": "MIT", - "dependencies": { - "safe-buffer": "~5.2.0" - } + "license": "BSD-3-Clause" }, - "node_modules/string-length": { - "version": "1.0.1", + "node_modules/stack-utils": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/stack-utils/-/stack-utils-2.0.6.tgz", + "integrity": "sha512-XlkWvfIm6RmsWtNJx+uqtKLS8eqFbxUg0ZzLXqY0caEy9l7hruX8IpiDnjsLavoBgqCCR71TqWO8MaXYheJ3RQ==", "dev": true, "license": "MIT", "dependencies": { - "strip-ansi": "^3.0.0" + "escape-string-regexp": "^2.0.0" }, "engines": { - "node": ">=0.10.0" + "node": ">=10" } }, - "node_modules/string-length/node_modules/ansi-regex": { - "version": "2.1.1", + "node_modules/stack-utils/node_modules/escape-string-regexp": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz", + "integrity": "sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w==", "dev": true, "license": "MIT", "engines": { - "node": ">=0.10.0" + "node": ">=8" } }, - "node_modules/string-length/node_modules/strip-ansi": { - "version": "3.0.1", + "node_modules/string-width": { + "version": "4.2.3", "dev": true, "license": "MIT", "dependencies": { - "ansi-regex": "^2.0.0" + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" }, "engines": { - "node": ">=0.10.0" + "node": ">=8" } }, - "node_modules/string-width": { + "node_modules/string-width-cjs": { + "name": "string-width", "version": "4.2.3", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", "dev": true, "license": "MIT", "dependencies": { @@ -5630,21 +6823,22 @@ "node": ">=8" } }, - "node_modules/string-width/node_modules/emoji-regex": { - "version": "8.0.0", - "dev": true, - "license": "MIT" - }, - "node_modules/string-width/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", + "node_modules/strip-ansi": { + "version": "6.0.1", "dev": true, "license": "MIT", + "dependencies": { + "ansi-regex": "^5.0.1" + }, "engines": { "node": ">=8" } }, - "node_modules/strip-ansi": { + "node_modules/strip-ansi-cjs": { + "name": "strip-ansi", "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", "dev": true, "license": "MIT", "dependencies": { @@ -5662,6 +6856,16 @@ "node": ">=8" } }, + "node_modules/strip-final-newline": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-2.0.0.tgz", + "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, "node_modules/strip-json-comments": { "version": "3.1.1", "dev": true, @@ -5673,32 +6877,33 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/subarg": { - "version": "1.0.0", - "dev": true, - "license": "MIT", - "dependencies": { - "minimist": "^1.1.0" - } - }, "node_modules/supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { - "has-flag": "^3.0.0" + "has-flag": "^4.0.0" }, "engines": { - "node": ">=4" + "node": ">=8" } }, - "node_modules/syntax-error": { - "version": "1.4.0", + "node_modules/synckit": { + "version": "0.11.11", + "resolved": "https://registry.npmjs.org/synckit/-/synckit-0.11.11.tgz", + "integrity": "sha512-MeQTA1r0litLUf0Rp/iisCaL8761lKAZHaimlbGK4j0HysC4PLfqygQj9srcs0m2RdtDYnF8UuYyKpbjHYp7Jw==", "dev": true, "license": "MIT", "dependencies": { - "acorn-node": "^1.2.0" + "@pkgr/core": "^0.2.9" + }, + "engines": { + "node": "^14.18.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/synckit" } }, "node_modules/test-exclude": { @@ -5719,68 +6924,12 @@ "dev": true, "license": "MIT" }, - "node_modules/through": { - "version": "2.3.8", - "dev": true, - "license": "MIT" - }, - "node_modules/through2": { - "version": "2.0.5", - "dev": true, - "license": "MIT", - "dependencies": { - "readable-stream": "~2.3.6", - "xtend": "~4.0.1" - } - }, - "node_modules/timers-browserify": { - "version": "1.4.2", - "dev": true, - "dependencies": { - "process": "~0.11.0" - }, - "engines": { - "node": ">=0.6.0" - } - }, - "node_modules/tmp": { - "version": "0.2.4", - "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.2.4.tgz", - "integrity": "sha512-UdiSoX6ypifLmrfQ/XfiawN6hkjSBpCjhKxxZcWlUUmoXLaCKQU0bx4HF/tdDK2uzRuchf1txGvrWBzYREssoQ==", - "dev": true, - "engines": { - "node": ">=14.14" - } - }, - "node_modules/to-buffer": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/to-buffer/-/to-buffer-1.2.1.tgz", - "integrity": "sha512-tB82LpAIWjhLYbqjx3X4zEeHN6M8CiuOEy2JY8SEQVdYRe3CCHOFaqrBW1doLDrfpWhplcW7BL+bO3/6S3pcDQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "isarray": "^2.0.5", - "safe-buffer": "^5.2.1", - "typed-array-buffer": "^1.0.3" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/to-buffer/node_modules/isarray": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", - "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", - "dev": true, - "license": "MIT" - }, - "node_modules/to-fast-properties": { - "version": "2.0.0", + "node_modules/tmpl": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.5.tgz", + "integrity": "sha512-3f0uOEAQwIqGuWW2MVzYg8fV/QNnc/IpuJNG837rLuczAaLVHslWHZQj4IGiEl5Hs3kkbhwL9Ab7Hrsmuj+Smw==", "dev": true, - "license": "MIT", - "engines": { - "node": ">=4" - } + "license": "BSD-3-Clause" }, "node_modules/to-regex-range": { "version": "5.0.1", @@ -5794,18 +6943,13 @@ "node": ">=8.0" } }, - "node_modules/toidentifier": { - "version": "1.0.1", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.6" - } - }, - "node_modules/tty-browserify": { - "version": "0.0.1", + "node_modules/tslib": { + "version": "2.8.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz", + "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==", "dev": true, - "license": "MIT" + "license": "0BSD", + "optional": true }, "node_modules/type-detect": { "version": "4.0.8", @@ -5826,64 +6970,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/type-is": { - "version": "1.6.18", - "dev": true, - "license": "MIT", - "dependencies": { - "media-typer": "0.3.0", - "mime-types": "~2.1.24" - }, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/typed-array-buffer": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.3.tgz", - "integrity": "sha512-nAYYwfY3qnzX30IkA6AQZjVbtK6duGontcQm1WSG1MD94YLqK0515GNApXkoxKOWMusVssAHWLh9SeaoefYFGw==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.3", - "es-errors": "^1.3.0", - "is-typed-array": "^1.1.14" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/typedarray": { - "version": "0.0.6", - "dev": true, - "license": "MIT" - }, - "node_modules/typedarray-to-buffer": { - "version": "3.1.5", - "dev": true, - "license": "MIT", - "dependencies": { - "is-typedarray": "^1.0.0" - } - }, - "node_modules/ua-parser-js": { - "version": "0.7.33", - "dev": true, - "funding": [ - { - "type": "opencollective", - "url": "https://opencollective.com/ua-parser-js" - }, - { - "type": "paypal", - "url": "https://paypal.me/faisalman" - } - ], - "license": "MIT", - "engines": { - "node": "*" - } - }, "node_modules/uglify-js": { "version": "3.17.4", "dev": true, @@ -5895,53 +6981,52 @@ "node": ">=0.8.0" } }, - "node_modules/umd": { - "version": "3.0.3", - "dev": true, - "license": "MIT", - "bin": { - "umd": "bin/cli.js" - } - }, - "node_modules/undeclared-identifiers": { - "version": "1.1.3", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "acorn-node": "^1.3.0", - "dash-ast": "^1.0.0", - "get-assigned-identifiers": "^1.2.0", - "simple-concat": "^1.0.0", - "xtend": "^4.0.1" - }, - "bin": { - "undeclared-identifiers": "bin.js" - } - }, "node_modules/undici-types": { - "version": "6.19.8", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.19.8.tgz", - "integrity": "sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==", - "dev": true - }, - "node_modules/universalify": { - "version": "0.1.2", + "version": "6.21.0", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", + "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==", "dev": true, - "license": "MIT", - "engines": { - "node": ">= 4.0.0" - } + "license": "MIT" }, - "node_modules/unpipe": { - "version": "1.0.0", + "node_modules/unrs-resolver": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/unrs-resolver/-/unrs-resolver-1.11.1.tgz", + "integrity": "sha512-bSjt9pjaEBnNiGgc9rUiHGKv5l4/TGzDmYw3RhnkJGtLhbnnA/5qJj7x3dNDCRx/PJxu774LlH8lCOlB4hEfKg==", "dev": true, + "hasInstallScript": true, "license": "MIT", - "engines": { - "node": ">= 0.8" + "dependencies": { + "napi-postinstall": "^0.3.0" + }, + "funding": { + "url": "https://opencollective.com/unrs-resolver" + }, + "optionalDependencies": { + "@unrs/resolver-binding-android-arm-eabi": "1.11.1", + "@unrs/resolver-binding-android-arm64": "1.11.1", + "@unrs/resolver-binding-darwin-arm64": "1.11.1", + "@unrs/resolver-binding-darwin-x64": "1.11.1", + "@unrs/resolver-binding-freebsd-x64": "1.11.1", + "@unrs/resolver-binding-linux-arm-gnueabihf": "1.11.1", + "@unrs/resolver-binding-linux-arm-musleabihf": "1.11.1", + "@unrs/resolver-binding-linux-arm64-gnu": "1.11.1", + "@unrs/resolver-binding-linux-arm64-musl": "1.11.1", + "@unrs/resolver-binding-linux-ppc64-gnu": "1.11.1", + "@unrs/resolver-binding-linux-riscv64-gnu": "1.11.1", + "@unrs/resolver-binding-linux-riscv64-musl": "1.11.1", + "@unrs/resolver-binding-linux-s390x-gnu": "1.11.1", + "@unrs/resolver-binding-linux-x64-gnu": "1.11.1", + "@unrs/resolver-binding-linux-x64-musl": "1.11.1", + "@unrs/resolver-binding-wasm32-wasi": "1.11.1", + "@unrs/resolver-binding-win32-arm64-msvc": "1.11.1", + "@unrs/resolver-binding-win32-ia32-msvc": "1.11.1", + "@unrs/resolver-binding-win32-x64-msvc": "1.11.1" } }, "node_modules/update-browserslist-db": { - "version": "1.0.10", + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.1.4.tgz", + "integrity": "sha512-q0SPT4xyU84saUX+tomz1WLkxUbuaJnR1xWt17M7fJtEJigJeWUNGUqrauFXsHnqev9y9JTRGwk13tFBuKby4A==", "dev": true, "funding": [ { @@ -5951,15 +7036,19 @@ { "type": "tidelift", "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" } ], "license": "MIT", "dependencies": { - "escalade": "^3.1.1", - "picocolors": "^1.0.0" + "escalade": "^3.2.0", + "picocolors": "^1.1.1" }, "bin": { - "browserslist-lint": "cli.js" + "update-browserslist-db": "cli.js" }, "peerDependencies": { "browserslist": ">= 4.21.0" @@ -5981,112 +7070,36 @@ "node": ">=6" } }, - "node_modules/url": { - "version": "0.11.0", - "dev": true, - "license": "MIT", - "dependencies": { - "punycode": "1.3.2", - "querystring": "0.2.0" - } - }, - "node_modules/url/node_modules/punycode": { - "version": "1.3.2", - "dev": true, - "license": "MIT" - }, - "node_modules/util": { - "version": "0.10.4", - "dev": true, - "license": "MIT", - "dependencies": { - "inherits": "2.0.3" - } - }, - "node_modules/util-deprecate": { - "version": "1.0.2", - "dev": true, - "license": "MIT" - }, - "node_modules/util/node_modules/inherits": { - "version": "2.0.3", - "dev": true, - "license": "ISC" - }, - "node_modules/utils-merge": { - "version": "1.0.1", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4.0" - } - }, - "node_modules/uuid": { - "version": "8.3.2", - "dev": true, - "license": "MIT", - "bin": { - "uuid": "dist/bin/uuid" - } - }, - "node_modules/vary": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", - "integrity": "sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==", - "dev": true, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/vm-browserify": { - "version": "1.1.0", - "dev": true, - "license": "MIT" - }, - "node_modules/void-elements": { - "version": "2.0.1", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/which": { - "version": "1.3.1", + "node_modules/v8-to-istanbul": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/v8-to-istanbul/-/v8-to-istanbul-9.3.0.tgz", + "integrity": "sha512-kiGUalWN+rgBJ/1OHZsBtU4rXZOfj/7rKQxULKlIzwzQSvMJUUNgPwJEEh7gU6xEVxC0ahoOBvN2YI8GH6FNgA==", "dev": true, "license": "ISC", "dependencies": { - "isexe": "^2.0.0" + "@jridgewell/trace-mapping": "^0.3.12", + "@types/istanbul-lib-coverage": "^2.0.1", + "convert-source-map": "^2.0.0" }, - "bin": { - "which": "bin/which" + "engines": { + "node": ">=10.12.0" } }, - "node_modules/which-module": { + "node_modules/v8-to-istanbul/node_modules/convert-source-map": { "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", "dev": true, - "license": "ISC" + "license": "MIT" }, - "node_modules/which-typed-array": { - "version": "1.1.19", - "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.19.tgz", - "integrity": "sha512-rEvr90Bck4WZt9HHFC4DJMsjvu7x+r6bImz0/BrbWb7A2djJ8hnZMrWnHo9F8ssv0OMErasDhftrfROTyqSDrw==", + "node_modules/walker": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/walker/-/walker-1.0.8.tgz", + "integrity": "sha512-ts/8E8l5b7kY0vlWLewOkDXMmPdLcVV4GmOQLyxuSswIJsweeFZtAsMF7k1Nszz+TYBQrlYRmzOnr398y1JemQ==", "dev": true, - "license": "MIT", + "license": "Apache-2.0", "dependencies": { - "available-typed-arrays": "^1.0.7", - "call-bind": "^1.0.8", - "call-bound": "^1.0.4", - "for-each": "^0.3.5", - "get-proto": "^1.0.1", - "gopd": "^1.2.0", - "has-tostringtag": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "makeerror": "1.0.12" } }, "node_modules/word-wrap": { @@ -6098,13 +7111,6 @@ "node": ">=0.10.0" } }, - "node_modules/workerpool": { - "version": "6.5.1", - "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.5.1.tgz", - "integrity": "sha512-Fs4dNYcsdpYSAfVxhnl1L5zTksjvOJxtC5hzMNl+1t9B8hTJTdKDyZ5ju7ztgPy+ft9tBFXoOlDNiOT9WUXZlA==", - "dev": true, - "license": "Apache-2.0" - }, "node_modules/wrap-ansi": { "version": "7.0.0", "dev": true, @@ -6121,80 +7127,30 @@ "url": "https://github.com/chalk/wrap-ansi?sponsor=1" } }, - "node_modules/wrap-ansi/node_modules/ansi-styles": { - "version": "4.3.0", + "node_modules/wrap-ansi-cjs": { + "name": "wrap-ansi", + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", + "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", "dev": true, "license": "MIT", "dependencies": { - "color-convert": "^2.0.1" + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" }, "engines": { - "node": ">=8" + "node": ">=10" }, "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/wrap-ansi/node_modules/color-convert": { - "version": "2.0.1", - "dev": true, - "license": "MIT", - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" } }, - "node_modules/wrap-ansi/node_modules/color-name": { - "version": "1.1.4", - "dev": true, - "license": "MIT" - }, "node_modules/wrappy": { "version": "1.0.2", "dev": true, "license": "ISC" }, - "node_modules/write-file-atomic": { - "version": "3.0.3", - "dev": true, - "license": "ISC", - "dependencies": { - "imurmurhash": "^0.1.4", - "is-typedarray": "^1.0.0", - "signal-exit": "^3.0.2", - "typedarray-to-buffer": "^3.1.5" - } - }, - "node_modules/ws": { - "version": "8.11.0", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10.0.0" - }, - "peerDependencies": { - "bufferutil": "^4.0.1", - "utf-8-validate": "^5.0.2" - }, - "peerDependenciesMeta": { - "bufferutil": { - "optional": true - }, - "utf-8-validate": { - "optional": true - } - } - }, - "node_modules/xtend": { - "version": "4.0.2", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.4" - } - }, "node_modules/y18n": { "version": "5.0.8", "dev": true, @@ -6205,50 +7161,11 @@ }, "node_modules/yallist": { "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", + "integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==", "dev": true, "license": "ISC" }, - "node_modules/yargs": { - "version": "16.2.0", - "dev": true, - "license": "MIT", - "dependencies": { - "cliui": "^7.0.2", - "escalade": "^3.1.1", - "get-caller-file": "^2.0.5", - "require-directory": "^2.1.1", - "string-width": "^4.2.0", - "y18n": "^5.0.5", - "yargs-parser": "^20.2.2" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/yargs-parser": { - "version": "20.2.9", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.9.tgz", - "integrity": "sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">=10" - } - }, - "node_modules/yargs-unparser": { - "version": "2.0.0", - "dev": true, - "license": "MIT", - "dependencies": { - "camelcase": "^6.0.0", - "decamelize": "^4.0.0", - "flat": "^5.0.2", - "is-plain-obj": "^2.1.0" - }, - "engines": { - "node": ">=10" - } - }, "node_modules/yocto-queue": { "version": "0.1.0", "dev": true, @@ -6262,252 +7179,571 @@ } }, "dependencies": { - "@ampproject/remapping": { - "version": "2.2.0", - "dev": true, - "requires": { - "@jridgewell/gen-mapping": "^0.1.0", - "@jridgewell/trace-mapping": "^0.3.9" - } - }, "@babel/code-frame": { - "version": "7.22.13", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.22.13.tgz", - "integrity": "sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w==", + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.27.1.tgz", + "integrity": "sha512-cjQ7ZlQ0Mv3b47hABuTevyTuYN4i+loJKGeV9flcCgIK37cCXRh+L1bd3iBHlynerhQ7BhCkn2BPbQUL+rGqFg==", "dev": true, "requires": { - "@babel/highlight": "^7.22.13", - "chalk": "^2.4.2" + "@babel/helper-validator-identifier": "^7.27.1", + "js-tokens": "^4.0.0", + "picocolors": "^1.1.1" } }, "@babel/compat-data": { - "version": "7.21.0", + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.28.5.tgz", + "integrity": "sha512-6uFXyCayocRbqhZOB+6XcuZbkMNimwfVGFji8CTZnCzOHVGvDqzvitu1re2AU5LROliz7eQPhB8CpAMvnx9EjA==", "dev": true }, "@babel/core": { - "version": "7.21.0", - "dev": true, - "requires": { - "@ampproject/remapping": "^2.2.0", - "@babel/code-frame": "^7.18.6", - "@babel/generator": "^7.21.0", - "@babel/helper-compilation-targets": "^7.20.7", - "@babel/helper-module-transforms": "^7.21.0", - "@babel/helpers": "^7.21.0", - "@babel/parser": "^7.21.0", - "@babel/template": "^7.20.7", - "@babel/traverse": "^7.21.0", - "@babel/types": "^7.21.0", - "convert-source-map": "^1.7.0", + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.28.5.tgz", + "integrity": "sha512-e7jT4DxYvIDLk1ZHmU/m/mB19rex9sv0c2ftBtjSBv+kVM/902eh0fINUzD7UwLLNR+jU585GxUJ8/EBfAM5fw==", + "dev": true, + "requires": { + "@babel/code-frame": "^7.27.1", + "@babel/generator": "^7.28.5", + "@babel/helper-compilation-targets": "^7.27.2", + "@babel/helper-module-transforms": "^7.28.3", + "@babel/helpers": "^7.28.4", + "@babel/parser": "^7.28.5", + "@babel/template": "^7.27.2", + "@babel/traverse": "^7.28.5", + "@babel/types": "^7.28.5", + "@jridgewell/remapping": "^2.3.5", + "convert-source-map": "^2.0.0", "debug": "^4.1.0", "gensync": "^1.0.0-beta.2", - "json5": "^2.2.2", - "semver": "^6.3.0" + "json5": "^2.2.3", + "semver": "^6.3.1" }, "dependencies": { "convert-source-map": { - "version": "1.9.0", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", "dev": true }, "semver": { - "version": "6.3.0", + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", + "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", "dev": true } } }, "@babel/generator": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.23.0.tgz", - "integrity": "sha512-lN85QRR+5IbYrMWM6Y4pE/noaQtg4pNiqeNGX60eqOfo6gtEj6uw/JagelB8vVztSd7R6M5n1+PQkDbHbBRU4g==", + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.28.5.tgz", + "integrity": "sha512-3EwLFhZ38J4VyIP6WNtt2kUdW9dokXA9Cr4IVIFHuCpZ3H8/YFOl5JjZHisrn1fATPBmKKqXzDFvh9fUwHz6CQ==", "dev": true, "requires": { - "@babel/types": "^7.23.0", - "@jridgewell/gen-mapping": "^0.3.2", - "@jridgewell/trace-mapping": "^0.3.17", - "jsesc": "^2.5.1" - }, - "dependencies": { - "@jridgewell/gen-mapping": { - "version": "0.3.2", - "dev": true, - "requires": { - "@jridgewell/set-array": "^1.0.1", - "@jridgewell/sourcemap-codec": "^1.4.10", - "@jridgewell/trace-mapping": "^0.3.9" - } - } + "@babel/parser": "^7.28.5", + "@babel/types": "^7.28.5", + "@jridgewell/gen-mapping": "^0.3.12", + "@jridgewell/trace-mapping": "^0.3.28", + "jsesc": "^3.0.2" } }, "@babel/helper-compilation-targets": { - "version": "7.20.7", + "version": "7.27.2", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.27.2.tgz", + "integrity": "sha512-2+1thGUUWWjLTYTHZWK1n8Yga0ijBz1XAhUXcKy81rd5g6yh7hGqMp45v7cadSbEHc9G3OTv45SyneRN3ps4DQ==", "dev": true, "requires": { - "@babel/compat-data": "^7.20.5", - "@babel/helper-validator-option": "^7.18.6", - "browserslist": "^4.21.3", + "@babel/compat-data": "^7.27.2", + "@babel/helper-validator-option": "^7.27.1", + "browserslist": "^4.24.0", "lru-cache": "^5.1.1", - "semver": "^6.3.0" + "semver": "^6.3.1" }, "dependencies": { "semver": { - "version": "6.3.0", + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", + "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", "dev": true } } }, - "@babel/helper-environment-visitor": { - "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.22.20.tgz", - "integrity": "sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA==", + "@babel/helper-globals": { + "version": "7.28.0", + "resolved": "https://registry.npmjs.org/@babel/helper-globals/-/helper-globals-7.28.0.tgz", + "integrity": "sha512-+W6cISkXFa1jXsDEdYA8HeevQT/FULhxzR99pxphltZcVaugps53THCeiWA8SguxxpSp3gKPiuYfSWopkLQ4hw==", + "dev": true + }, + "@babel/helper-module-imports": { + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.27.1.tgz", + "integrity": "sha512-0gSFWUPNXNopqtIPQvlD5WgXYI5GY2kP2cCvoT8kczjbfcfuIljTbcWrulD1CIPIX2gt1wghbDy08yE1p+/r3w==", + "dev": true, + "requires": { + "@babel/traverse": "^7.27.1", + "@babel/types": "^7.27.1" + } + }, + "@babel/helper-module-transforms": { + "version": "7.28.3", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.28.3.tgz", + "integrity": "sha512-gytXUbs8k2sXS9PnQptz5o0QnpLL51SwASIORY6XaBKF88nsOT0Zw9szLqlSGQDP/4TljBAD5y98p2U1fqkdsw==", + "dev": true, + "requires": { + "@babel/helper-module-imports": "^7.27.1", + "@babel/helper-validator-identifier": "^7.27.1", + "@babel/traverse": "^7.28.3" + } + }, + "@babel/helper-plugin-utils": { + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.27.1.tgz", + "integrity": "sha512-1gn1Up5YXka3YYAHGKpbideQ5Yjf1tDa9qYcgysz+cNCXukyLl6DjPXhD3VRwSb8c0J9tA4b2+rHEZtc6R0tlw==", + "dev": true + }, + "@babel/helper-string-parser": { + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.27.1.tgz", + "integrity": "sha512-qMlSxKbpRlAridDExk92nSobyDdpPijUq2DW6oDnUqd0iOGxmQjyqhMIihI9+zv4LPyZdRje2cavWPbCbWm3eA==", + "dev": true + }, + "@babel/helper-validator-identifier": { + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.28.5.tgz", + "integrity": "sha512-qSs4ifwzKJSV39ucNjsvc6WVHs6b7S03sOh2OcHF9UHfVPqWWALUsNUVzhSBiItjRZoLHx7nIarVjqKVusUZ1Q==", + "dev": true + }, + "@babel/helper-validator-option": { + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.27.1.tgz", + "integrity": "sha512-YvjJow9FxbhFFKDSuFnVCe2WxXk1zWc22fFePVNEaWJEu8IrZVlda6N0uHwzZrUM1il7NC9Mlp4MaJYbYd9JSg==", "dev": true }, - "@babel/helper-function-name": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.23.0.tgz", - "integrity": "sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==", + "@babel/helpers": { + "version": "7.28.4", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.28.4.tgz", + "integrity": "sha512-HFN59MmQXGHVyYadKLVumYsA9dBFun/ldYxipEjzA4196jpLZd8UjEEBLkbEkvfYreDqJhZxYAWFPtrfhNpj4w==", + "dev": true, + "requires": { + "@babel/template": "^7.27.2", + "@babel/types": "^7.28.4" + } + }, + "@babel/parser": { + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.28.5.tgz", + "integrity": "sha512-KKBU1VGYR7ORr3At5HAtUQ+TV3SzRCXmA/8OdDZiLDBIZxVyzXuztPjfLd3BV1PRAQGCMWWSHYhL0F8d5uHBDQ==", + "dev": true, + "requires": { + "@babel/types": "^7.28.5" + } + }, + "@babel/plugin-syntax-async-generators": { + "version": "7.8.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz", + "integrity": "sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-bigint": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-bigint/-/plugin-syntax-bigint-7.8.3.tgz", + "integrity": "sha512-wnTnFlG+YxQm3vDxpGE57Pj0srRU4sHE/mDkt1qv2YJJSeUAec2ma4WLUnUPeKjyrfntVwe/N6dCXpU+zL3Npg==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-class-properties": { + "version": "7.12.13", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz", + "integrity": "sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.12.13" + } + }, + "@babel/plugin-syntax-class-static-block": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-static-block/-/plugin-syntax-class-static-block-7.14.5.tgz", + "integrity": "sha512-b+YyPmr6ldyNnM6sqYeMWE+bgJcJpO6yS4QD7ymxgH34GBPNDM/THBh8iunyvKIZztiwLH4CJZ0RxTk9emgpjw==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-syntax-import-attributes": { + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-attributes/-/plugin-syntax-import-attributes-7.27.1.tgz", + "integrity": "sha512-oFT0FrKHgF53f4vOsZGi2Hh3I35PfSmVs4IBFLFj4dnafP+hIWDLg3VyKmUHfLoLHlyxY4C7DGtmHuJgn+IGww==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.27.1" + } + }, + "@babel/plugin-syntax-import-meta": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-meta/-/plugin-syntax-import-meta-7.10.4.tgz", + "integrity": "sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-syntax-json-strings": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz", + "integrity": "sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-jsx": { + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.27.1.tgz", + "integrity": "sha512-y8YTNIeKoyhGd9O0Jiyzyyqk8gdjnumGTQPsz0xOZOQ2RmkVJeZ1vmmfIvFEKqucBG6axJGBZDE/7iI5suUI/w==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.27.1" + } + }, + "@babel/plugin-syntax-logical-assignment-operators": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz", + "integrity": "sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-syntax-nullish-coalescing-operator": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz", + "integrity": "sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-numeric-separator": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz", + "integrity": "sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-syntax-object-rest-spread": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz", + "integrity": "sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-optional-catch-binding": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz", + "integrity": "sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-optional-chaining": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz", + "integrity": "sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-private-property-in-object": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-private-property-in-object/-/plugin-syntax-private-property-in-object-7.14.5.tgz", + "integrity": "sha512-0wVnp9dxJ72ZUJDV27ZfbSj6iHLoytYZmh3rFcxNnvsJF3ktkzLDZPy/mA17HGsaQT3/DQsWYX1f1QGWkCoVUg==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-syntax-top-level-await": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.14.5.tgz", + "integrity": "sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.14.5" + } + }, + "@babel/plugin-syntax-typescript": { + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.27.1.tgz", + "integrity": "sha512-xfYCBMxveHrRMnAWl1ZlPXOZjzkN82THFvLhQhFXFt81Z5HnN+EtUkZhv/zcKpmT3fzmWZB0ywiBrbC3vogbwQ==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.27.1" + } + }, + "@babel/template": { + "version": "7.27.2", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.27.2.tgz", + "integrity": "sha512-LPDZ85aEJyYSd18/DkjNh4/y1ntkE5KwUHWTiqgRxruuZL2F1yuHligVHLvcHY2vMHXttKFpJn6LwfI7cw7ODw==", "dev": true, "requires": { - "@babel/template": "^7.22.15", - "@babel/types": "^7.23.0" + "@babel/code-frame": "^7.27.1", + "@babel/parser": "^7.27.2", + "@babel/types": "^7.27.1" } }, - "@babel/helper-hoist-variables": { - "version": "7.22.5", - "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.22.5.tgz", - "integrity": "sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==", + "@babel/traverse": { + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.28.5.tgz", + "integrity": "sha512-TCCj4t55U90khlYkVV/0TfkJkAkUg3jZFA3Neb7unZT8CPok7iiRfaX0F+WnqWqt7OxhOn0uBKXCw4lbL8W0aQ==", "dev": true, "requires": { - "@babel/types": "^7.22.5" + "@babel/code-frame": "^7.27.1", + "@babel/generator": "^7.28.5", + "@babel/helper-globals": "^7.28.0", + "@babel/parser": "^7.28.5", + "@babel/template": "^7.27.2", + "@babel/types": "^7.28.5", + "debug": "^4.3.1" } }, - "@babel/helper-module-imports": { - "version": "7.18.6", + "@babel/types": { + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.28.5.tgz", + "integrity": "sha512-qQ5m48eI/MFLQ5PxQj4PFaprjyCTLI37ElWMmNs0K8Lk3dVeOdNpB3ks8jc7yM5CDmVC73eMVk/trk3fgmrUpA==", "dev": true, "requires": { - "@babel/types": "^7.18.6" + "@babel/helper-string-parser": "^7.27.1", + "@babel/helper-validator-identifier": "^7.28.5" } }, - "@babel/helper-module-transforms": { - "version": "7.21.2", + "@bcoe/v8-coverage": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz", + "integrity": "sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==", + "dev": true + }, + "@emnapi/core": { + "version": "1.7.1", + "resolved": "https://registry.npmjs.org/@emnapi/core/-/core-1.7.1.tgz", + "integrity": "sha512-o1uhUASyo921r2XtHYOHy7gdkGLge8ghBEQHMWmyJFoXlpU58kIrhhN3w26lpQb6dspetweapMn2CSNwQ8I4wg==", "dev": true, + "optional": true, "requires": { - "@babel/helper-environment-visitor": "^7.18.9", - "@babel/helper-module-imports": "^7.18.6", - "@babel/helper-simple-access": "^7.20.2", - "@babel/helper-split-export-declaration": "^7.18.6", - "@babel/helper-validator-identifier": "^7.19.1", - "@babel/template": "^7.20.7", - "@babel/traverse": "^7.21.2", - "@babel/types": "^7.21.2" + "@emnapi/wasi-threads": "1.1.0", + "tslib": "^2.4.0" } }, - "@babel/helper-simple-access": { - "version": "7.20.2", + "@emnapi/runtime": { + "version": "1.7.1", + "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.7.1.tgz", + "integrity": "sha512-PVtJr5CmLwYAU9PZDMITZoR5iAOShYREoR45EyyLrbntV50mdePTgUn4AmOw90Ifcj+x2kRjdzr1HP3RrNiHGA==", "dev": true, + "optional": true, "requires": { - "@babel/types": "^7.20.2" + "tslib": "^2.4.0" } }, - "@babel/helper-split-export-declaration": { - "version": "7.22.6", - "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.22.6.tgz", - "integrity": "sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==", + "@emnapi/wasi-threads": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@emnapi/wasi-threads/-/wasi-threads-1.1.0.tgz", + "integrity": "sha512-WI0DdZ8xFSbgMjR1sFsKABJ/C5OnRrjT06JXbZKexJGrDuPTzZdDYfFlsgcCXCyf+suG5QU2e/y1Wo2V/OapLQ==", "dev": true, + "optional": true, "requires": { - "@babel/types": "^7.22.5" + "tslib": "^2.4.0" } }, - "@babel/helper-string-parser": { - "version": "7.22.5", - "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.22.5.tgz", - "integrity": "sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw==", - "dev": true + "@esbuild/aix-ppc64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.27.0.tgz", + "integrity": "sha512-KuZrd2hRjz01y5JK9mEBSD3Vj3mbCvemhT466rSuJYeE/hjuBrHfjjcjMdTm/sz7au+++sdbJZJmuBwQLuw68A==", + "dev": true, + "optional": true }, - "@babel/helper-validator-identifier": { - "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.20.tgz", - "integrity": "sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==", - "dev": true + "@esbuild/android-arm": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.27.0.tgz", + "integrity": "sha512-j67aezrPNYWJEOHUNLPj9maeJte7uSMM6gMoxfPC9hOg8N02JuQi/T7ewumf4tNvJadFkvLZMlAq73b9uwdMyQ==", + "dev": true, + "optional": true }, - "@babel/helper-validator-option": { - "version": "7.21.0", - "dev": true + "@esbuild/android-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.27.0.tgz", + "integrity": "sha512-CC3vt4+1xZrs97/PKDkl0yN7w8edvU2vZvAFGD16n9F0Cvniy5qvzRXjfO1l94efczkkQE6g1x0i73Qf5uthOQ==", + "dev": true, + "optional": true }, - "@babel/helpers": { - "version": "7.21.0", + "@esbuild/android-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.27.0.tgz", + "integrity": "sha512-wurMkF1nmQajBO1+0CJmcN17U4BP6GqNSROP8t0X/Jiw2ltYGLHpEksp9MpoBqkrFR3kv2/te6Sha26k3+yZ9Q==", "dev": true, - "requires": { - "@babel/template": "^7.20.7", - "@babel/traverse": "^7.21.0", - "@babel/types": "^7.21.0" - } + "optional": true }, - "@babel/highlight": { - "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.22.20.tgz", - "integrity": "sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg==", + "@esbuild/darwin-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.27.0.tgz", + "integrity": "sha512-uJOQKYCcHhg07DL7i8MzjvS2LaP7W7Pn/7uA0B5S1EnqAirJtbyw4yC5jQ5qcFjHK9l6o/MX9QisBg12kNkdHg==", "dev": true, - "requires": { - "@babel/helper-validator-identifier": "^7.22.20", - "chalk": "^2.4.2", - "js-tokens": "^4.0.0" - } + "optional": true }, - "@babel/parser": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.23.0.tgz", - "integrity": "sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw==", - "dev": true + "@esbuild/darwin-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.27.0.tgz", + "integrity": "sha512-8mG6arH3yB/4ZXiEnXof5MK72dE6zM9cDvUcPtxhUZsDjESl9JipZYW60C3JGreKCEP+p8P/72r69m4AZGJd5g==", + "dev": true, + "optional": true }, - "@babel/template": { - "version": "7.22.15", - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.22.15.tgz", - "integrity": "sha512-QPErUVm4uyJa60rkI73qneDacvdvzxshT3kksGqlGWYdOTIUOwJ7RDUL8sGqslY1uXWSL6xMFKEXDS3ox2uF0w==", + "@esbuild/freebsd-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.27.0.tgz", + "integrity": "sha512-9FHtyO988CwNMMOE3YIeci+UV+x5Zy8fI2qHNpsEtSF83YPBmE8UWmfYAQg6Ux7Gsmd4FejZqnEUZCMGaNQHQw==", "dev": true, - "requires": { - "@babel/code-frame": "^7.22.13", - "@babel/parser": "^7.22.15", - "@babel/types": "^7.22.15" - } + "optional": true }, - "@babel/traverse": { - "version": "7.23.2", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.23.2.tgz", - "integrity": "sha512-azpe59SQ48qG6nu2CzcMLbxUudtN+dOM9kDbUqGq3HXUJRlo7i8fvPoxQUzYgLZ4cMVmuZgm8vvBpNeRhd6XSw==", - "dev": true, - "requires": { - "@babel/code-frame": "^7.22.13", - "@babel/generator": "^7.23.0", - "@babel/helper-environment-visitor": "^7.22.20", - "@babel/helper-function-name": "^7.23.0", - "@babel/helper-hoist-variables": "^7.22.5", - "@babel/helper-split-export-declaration": "^7.22.6", - "@babel/parser": "^7.23.0", - "@babel/types": "^7.23.0", - "debug": "^4.1.0", - "globals": "^11.1.0" - }, - "dependencies": { - "globals": { - "version": "11.12.0", - "dev": true - } - } + "@esbuild/freebsd-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.27.0.tgz", + "integrity": "sha512-zCMeMXI4HS/tXvJz8vWGexpZj2YVtRAihHLk1imZj4efx1BQzN76YFeKqlDr3bUWI26wHwLWPd3rwh6pe4EV7g==", + "dev": true, + "optional": true }, - "@babel/types": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.23.0.tgz", - "integrity": "sha512-0oIyUfKoI3mSqMvsxBdclDwxXKXAUA8v/apZbc+iSyARYou1o8ZGDxbUYyLFoW2arqS2jDGqJuZvv1d/io1axg==", + "@esbuild/linux-arm": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.27.0.tgz", + "integrity": "sha512-t76XLQDpxgmq2cNXKTVEB7O7YMb42atj2Re2Haf45HkaUpjM2J0UuJZDuaGbPbamzZ7bawyGFUkodL+zcE+jvQ==", "dev": true, - "requires": { - "@babel/helper-string-parser": "^7.22.5", - "@babel/helper-validator-identifier": "^7.22.20", - "to-fast-properties": "^2.0.0" - } + "optional": true }, - "@colors/colors": { - "version": "1.5.0", - "dev": true + "@esbuild/linux-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.27.0.tgz", + "integrity": "sha512-AS18v0V+vZiLJyi/4LphvBE+OIX682Pu7ZYNsdUHyUKSoRwdnOsMf6FDekwoAFKej14WAkOef3zAORJgAtXnlQ==", + "dev": true, + "optional": true + }, + "@esbuild/linux-ia32": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.27.0.tgz", + "integrity": "sha512-Mz1jxqm/kfgKkc/KLHC5qIujMvnnarD9ra1cEcrs7qshTUSksPihGrWHVG5+osAIQ68577Zpww7SGapmzSt4Nw==", + "dev": true, + "optional": true + }, + "@esbuild/linux-loong64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.27.0.tgz", + "integrity": "sha512-QbEREjdJeIreIAbdG2hLU1yXm1uu+LTdzoq1KCo4G4pFOLlvIspBm36QrQOar9LFduavoWX2msNFAAAY9j4BDg==", + "dev": true, + "optional": true + }, + "@esbuild/linux-mips64el": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.27.0.tgz", + "integrity": "sha512-sJz3zRNe4tO2wxvDpH/HYJilb6+2YJxo/ZNbVdtFiKDufzWq4JmKAiHy9iGoLjAV7r/W32VgaHGkk35cUXlNOg==", + "dev": true, + "optional": true + }, + "@esbuild/linux-ppc64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.27.0.tgz", + "integrity": "sha512-z9N10FBD0DCS2dmSABDBb5TLAyF1/ydVb+N4pi88T45efQ/w4ohr/F/QYCkxDPnkhkp6AIpIcQKQ8F0ANoA2JA==", + "dev": true, + "optional": true + }, + "@esbuild/linux-riscv64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.27.0.tgz", + "integrity": "sha512-pQdyAIZ0BWIC5GyvVFn5awDiO14TkT/19FTmFcPdDec94KJ1uZcmFs21Fo8auMXzD4Tt+diXu1LW1gHus9fhFQ==", + "dev": true, + "optional": true + }, + "@esbuild/linux-s390x": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.27.0.tgz", + "integrity": "sha512-hPlRWR4eIDDEci953RI1BLZitgi5uqcsjKMxwYfmi4LcwyWo2IcRP+lThVnKjNtk90pLS8nKdroXYOqW+QQH+w==", + "dev": true, + "optional": true + }, + "@esbuild/linux-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.27.0.tgz", + "integrity": "sha512-1hBWx4OUJE2cab++aVZ7pObD6s+DK4mPGpemtnAORBvb5l/g5xFGk0vc0PjSkrDs0XaXj9yyob3d14XqvnQ4gw==", + "dev": true, + "optional": true + }, + "@esbuild/netbsd-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.27.0.tgz", + "integrity": "sha512-6m0sfQfxfQfy1qRuecMkJlf1cIzTOgyaeXaiVaaki8/v+WB+U4hc6ik15ZW6TAllRlg/WuQXxWj1jx6C+dfy3w==", + "dev": true, + "optional": true + }, + "@esbuild/netbsd-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.27.0.tgz", + "integrity": "sha512-xbbOdfn06FtcJ9d0ShxxvSn2iUsGd/lgPIO2V3VZIPDbEaIj1/3nBBe1AwuEZKXVXkMmpr6LUAgMkLD/4D2PPA==", + "dev": true, + "optional": true + }, + "@esbuild/openbsd-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.27.0.tgz", + "integrity": "sha512-fWgqR8uNbCQ/GGv0yhzttj6sU/9Z5/Sv/VGU3F5OuXK6J6SlriONKrQ7tNlwBrJZXRYk5jUhuWvF7GYzGguBZQ==", + "dev": true, + "optional": true + }, + "@esbuild/openbsd-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.27.0.tgz", + "integrity": "sha512-aCwlRdSNMNxkGGqQajMUza6uXzR/U0dIl1QmLjPtRbLOx3Gy3otfFu/VjATy4yQzo9yFDGTxYDo1FfAD9oRD2A==", + "dev": true, + "optional": true + }, + "@esbuild/openharmony-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.27.0.tgz", + "integrity": "sha512-nyvsBccxNAsNYz2jVFYwEGuRRomqZ149A39SHWk4hV0jWxKM0hjBPm3AmdxcbHiFLbBSwG6SbpIcUbXjgyECfA==", + "dev": true, + "optional": true + }, + "@esbuild/sunos-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.27.0.tgz", + "integrity": "sha512-Q1KY1iJafM+UX6CFEL+F4HRTgygmEW568YMqDA5UV97AuZSm21b7SXIrRJDwXWPzr8MGr75fUZPV67FdtMHlHA==", + "dev": true, + "optional": true + }, + "@esbuild/win32-arm64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.27.0.tgz", + "integrity": "sha512-W1eyGNi6d+8kOmZIwi/EDjrL9nxQIQ0MiGqe/AWc6+IaHloxHSGoeRgDRKHFISThLmsewZ5nHFvGFWdBYlgKPg==", + "dev": true, + "optional": true + }, + "@esbuild/win32-ia32": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.27.0.tgz", + "integrity": "sha512-30z1aKL9h22kQhilnYkORFYt+3wp7yZsHWus+wSKAJR8JtdfI76LJ4SBdMsCopTR3z/ORqVu5L1vtnHZWVj4cQ==", + "dev": true, + "optional": true + }, + "@esbuild/win32-x64": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.27.0.tgz", + "integrity": "sha512-aIitBcjQeyOhMTImhLZmtxfdOcuNRpwlPNmlFKPcHQYPhEssw75Cl1TSXJXpMkzaua9FUetx/4OQKq7eJul5Cg==", + "dev": true, + "optional": true }, "@eslint/eslintrc": { "version": "2.0.0", @@ -6576,6 +7812,71 @@ "version": "1.2.1", "dev": true }, + "@isaacs/cliui": { + "version": "8.0.2", + "resolved": "https://registry.npmjs.org/@isaacs/cliui/-/cliui-8.0.2.tgz", + "integrity": "sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA==", + "dev": true, + "requires": { + "string-width": "^5.1.2", + "string-width-cjs": "npm:string-width@^4.2.0", + "strip-ansi": "^7.0.1", + "strip-ansi-cjs": "npm:strip-ansi@^6.0.1", + "wrap-ansi": "^8.1.0", + "wrap-ansi-cjs": "npm:wrap-ansi@^7.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "6.2.2", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-6.2.2.tgz", + "integrity": "sha512-Bq3SmSpyFHaWjPk8If9yc6svM8c56dB5BAtW4Qbw5jHTwwXXcTLoRMkpDJp6VL0XzlWaCHTXrkFURMYmD0sLqg==", + "dev": true + }, + "ansi-styles": { + "version": "6.2.3", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-6.2.3.tgz", + "integrity": "sha512-4Dj6M28JB+oAH8kFkTLUo+a2jwOFkuqb3yucU0CANcRRUbxS0cP0nZYCGjcc3BNXwRIsUVmDGgzawme7zvJHvg==", + "dev": true + }, + "emoji-regex": { + "version": "9.2.2", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-9.2.2.tgz", + "integrity": "sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==", + "dev": true + }, + "string-width": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-5.1.2.tgz", + "integrity": "sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==", + "dev": true, + "requires": { + "eastasianwidth": "^0.2.0", + "emoji-regex": "^9.2.2", + "strip-ansi": "^7.0.1" + } + }, + "strip-ansi": { + "version": "7.1.2", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-7.1.2.tgz", + "integrity": "sha512-gmBGslpoQJtgnMAvOVqGZpEz9dyoKTCzy2nfz/n8aIFhN/jCE/rCmcxabB6jOOHV+0WNnylOxaxBQPSvcWklhA==", + "dev": true, + "requires": { + "ansi-regex": "^6.0.1" + } + }, + "wrap-ansi": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-8.1.0.tgz", + "integrity": "sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==", + "dev": true, + "requires": { + "ansi-styles": "^6.1.0", + "string-width": "^5.0.1", + "strip-ansi": "^7.0.1" + } + } + } + }, "@istanbuljs/load-nyc-config": { "version": "1.1.0", "dev": true, @@ -6630,1124 +7931,1497 @@ "version": "0.1.3", "dev": true }, - "@jridgewell/gen-mapping": { - "version": "0.1.1", - "dev": true, - "requires": { - "@jridgewell/set-array": "^1.0.0", - "@jridgewell/sourcemap-codec": "^1.4.10" - } - }, - "@jridgewell/resolve-uri": { - "version": "3.1.0", - "dev": true - }, - "@jridgewell/set-array": { - "version": "1.1.2", - "dev": true - }, - "@jridgewell/sourcemap-codec": { - "version": "1.4.14", - "dev": true - }, - "@jridgewell/trace-mapping": { - "version": "0.3.17", - "dev": true, - "requires": { - "@jridgewell/resolve-uri": "3.1.0", - "@jridgewell/sourcemap-codec": "1.4.14" - } - }, - "@nodelib/fs.scandir": { - "version": "2.1.5", - "dev": true, - "requires": { - "@nodelib/fs.stat": "2.0.5", - "run-parallel": "^1.1.9" - } - }, - "@nodelib/fs.stat": { - "version": "2.0.5", - "dev": true - }, - "@nodelib/fs.walk": { - "version": "1.2.8", - "dev": true, - "requires": { - "@nodelib/fs.scandir": "2.1.5", - "fastq": "^1.6.0" - } - }, - "@socket.io/component-emitter": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.2.tgz", - "integrity": "sha512-9BCxFwvbGg/RsZK9tjXd8s4UcwR0MWeFQ1XEKIQVVvAGJyINdrqKMcTRyLoK8Rse1GjzLV9cwjWV1olXRWEXVA==", - "dev": true - }, - "@types/cookie": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/@types/cookie/-/cookie-0.4.1.tgz", - "integrity": "sha512-XW/Aa8APYr6jSVVA1y/DEIZX0/GMKLEVekNG727R8cs56ahETkRAy/3DR7+fJyh7oUgGwNQaRfXCun0+KbWY7Q==", - "dev": true - }, - "@types/cors": { - "version": "2.8.17", - "resolved": "https://registry.npmjs.org/@types/cors/-/cors-2.8.17.tgz", - "integrity": "sha512-8CGDvrBj1zgo2qE+oS3pOCyYNqCPryMWY2bGfwA0dcfopWGgxs+78df0Rs3rc9THP4JkOhLsAa+15VdpAqkcUA==", - "dev": true, - "requires": { - "@types/node": "*" - } - }, - "@types/node": { - "version": "22.7.5", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.7.5.tgz", - "integrity": "sha512-jML7s2NAzMWc//QSJ1a3prpk78cOPchGvXJsC3C6R6PSMoooztvRVQEz89gmBTBY1SPMaqo5teB4uNHPdetShQ==", - "dev": true, - "requires": { - "undici-types": "~6.19.2" - } - }, - "accepts": { - "version": "1.3.8", - "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.8.tgz", - "integrity": "sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw==", - "dev": true, - "requires": { - "mime-types": "~2.1.34", - "negotiator": "0.6.3" - } - }, - "acorn": { - "version": "7.4.1", - "dev": true - }, - "acorn-jsx": { - "version": "5.3.2", - "dev": true, - "requires": {} - }, - "acorn-node": { - "version": "1.8.2", - "dev": true, - "requires": { - "acorn": "^7.0.0", - "acorn-walk": "^7.0.0", - "xtend": "^4.0.2" - } - }, - "acorn-walk": { - "version": "7.0.0", - "dev": true - }, - "aggregate-error": { - "version": "3.1.0", - "dev": true, - "requires": { - "clean-stack": "^2.0.0", - "indent-string": "^4.0.0" - } - }, - "ajv": { - "version": "6.12.6", - "dev": true, - "requires": { - "fast-deep-equal": "^3.1.1", - "fast-json-stable-stringify": "^2.0.0", - "json-schema-traverse": "^0.4.1", - "uri-js": "^4.2.2" - } - }, - "ansi-colors": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.3.tgz", - "integrity": "sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==", - "dev": true - }, - "ansi-regex": { - "version": "5.0.1", - "dev": true - }, - "ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", - "dev": true, - "requires": { - "color-convert": "^1.9.0" - } - }, - "anymatch": { - "version": "3.1.3", + "@jest/console": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/console/-/console-30.2.0.tgz", + "integrity": "sha512-+O1ifRjkvYIkBqASKWgLxrpEhQAAE7hY77ALLUufSk5717KfOShg6IbqLmdsLMPdUiFvA2kTs0R7YZy+l0IzZQ==", "dev": true, "requires": { - "normalize-path": "^3.0.0", - "picomatch": "^2.0.4" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "jest-message-util": "30.2.0", + "jest-util": "30.2.0", + "slash": "^3.0.0" + }, + "dependencies": { + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true + }, + "jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", + "dev": true, + "requires": { + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + } + }, + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + }, + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "requires": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + } + } } }, - "append-transform": { - "version": "2.0.0", - "dev": true, - "requires": { - "default-require-extensions": "^3.0.0" + "@jest/core": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/core/-/core-30.2.0.tgz", + "integrity": "sha512-03W6IhuhjqTlpzh/ojut/pDB2LPRygyWX8ExpgHtQA8H/3K7+1vKmcINx5UzeOX1se6YEsBsOHQ1CRzf3fOwTQ==", + "dev": true, + "requires": { + "@jest/console": "30.2.0", + "@jest/pattern": "30.0.1", + "@jest/reporters": "30.2.0", + "@jest/test-result": "30.2.0", + "@jest/transform": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "ansi-escapes": "^4.3.2", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "exit-x": "^0.2.2", + "graceful-fs": "^4.2.11", + "jest-changed-files": "30.2.0", + "jest-config": "30.2.0", + "jest-haste-map": "30.2.0", + "jest-message-util": "30.2.0", + "jest-regex-util": "30.0.1", + "jest-resolve": "30.2.0", + "jest-resolve-dependencies": "30.2.0", + "jest-runner": "30.2.0", + "jest-runtime": "30.2.0", + "jest-snapshot": "30.2.0", + "jest-util": "30.2.0", + "jest-validate": "30.2.0", + "jest-watcher": "30.2.0", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0" + }, + "dependencies": { + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true + }, + "jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", + "dev": true, + "requires": { + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + } + }, + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + }, + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "requires": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + } + } } }, - "archy": { - "version": "1.0.0", + "@jest/diff-sequences": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/@jest/diff-sequences/-/diff-sequences-30.0.1.tgz", + "integrity": "sha512-n5H8QLDJ47QqbCNn5SuFjCRDrOLEZ0h8vAHCK5RL9Ls7Xa8AQLa/YxAc9UjFqoEDM48muwtBGjtMY5cr0PLDCw==", "dev": true }, - "argparse": { - "version": "1.0.10", - "dev": true, - "requires": { - "sprintf-js": "~1.0.2" - } - }, - "asn1.js": { - "version": "5.4.1", - "resolved": "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz", - "integrity": "sha512-+I//4cYPccV8LdmBLiX8CYvf9Sp3vQsrqu2QNXRcrbiWvcx/UdlFiqUJJzxRQxgsZmvhXhn4cSKeSmoFjVdupA==", + "@jest/environment": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-30.2.0.tgz", + "integrity": "sha512-/QPTL7OBJQ5ac09UDRa3EQes4gt1FTEG/8jZ/4v5IVzx+Cv7dLxlVIvfvSVRiiX2drWyXeBjkMSR8hvOWSog5g==", "dev": true, "requires": { - "bn.js": "^4.0.0", - "inherits": "^2.0.1", - "minimalistic-assert": "^1.0.0", - "safer-buffer": "^2.1.0" + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0" } }, - "assert": { - "version": "1.5.0", + "@jest/expect": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-30.2.0.tgz", + "integrity": "sha512-V9yxQK5erfzx99Sf+7LbhBwNWEZ9eZay8qQ9+JSC0TrMR1pMDHLMY+BnVPacWU6Jamrh252/IKo4F1Xn/zfiqA==", "dev": true, "requires": { - "object-assign": "^4.1.1", - "util": "0.10.3" + "expect": "30.2.0", + "jest-snapshot": "30.2.0" }, "dependencies": { - "inherits": { - "version": "2.0.1", + "@jest/expect-utils": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-30.2.0.tgz", + "integrity": "sha512-1JnRfhqpD8HGpOmQp180Fo9Zt69zNtC+9lR+kT7NVL05tNXIi+QC8Csz7lfidMoVLPD3FnOtcmp0CEFnxExGEA==", + "dev": true, + "requires": { + "@jest/get-type": "30.1.0" + } + }, + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true + }, + "expect": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/expect/-/expect-30.2.0.tgz", + "integrity": "sha512-u/feCi0GPsI+988gU2FLcsHyAHTU0MX1Wg68NhAnN7z/+C5wqG+CY8J53N9ioe8RXgaoz0nBR/TYMf3AycUuPw==", + "dev": true, + "requires": { + "@jest/expect-utils": "30.2.0", + "@jest/get-type": "30.1.0", + "jest-matcher-utils": "30.2.0", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" + } + }, + "jest-diff": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-30.2.0.tgz", + "integrity": "sha512-dQHFo3Pt4/NLlG5z4PxZ/3yZTZ1C7s9hveiOj+GCN+uT109NC2QgsoVZsVOAvbJ3RgKkvyLGXZV9+piDpWbm6A==", + "dev": true, + "requires": { + "@jest/diff-sequences": "30.0.1", + "@jest/get-type": "30.1.0", + "chalk": "^4.1.2", + "pretty-format": "30.2.0" + } + }, + "jest-matcher-utils": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-30.2.0.tgz", + "integrity": "sha512-dQ94Nq4dbzmUWkQ0ANAWS9tBRfqCrn0bV9AMYdOi/MHW726xn7eQmMeRTpX2ViC00bpNaWXq+7o4lIQ3AX13Hg==", + "dev": true, + "requires": { + "@jest/get-type": "30.1.0", + "chalk": "^4.1.2", + "jest-diff": "30.2.0", + "pretty-format": "30.2.0" + } + }, + "jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", + "dev": true, + "requires": { + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + } + }, + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true }, - "util": { - "version": "0.10.3", + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, "requires": { - "inherits": "2.0.1" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" } } } }, - "assertion-error": { - "version": "1.1.0", - "dev": true - }, - "available-typed-arrays": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.7.tgz", - "integrity": "sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==", - "dev": true, - "requires": { - "possible-typed-array-names": "^1.0.0" - } - }, - "balanced-match": { - "version": "1.0.0", - "dev": true - }, - "base64-js": { - "version": "1.5.1", - "dev": true - }, - "base64id": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/base64id/-/base64id-2.0.0.tgz", - "integrity": "sha512-lGe34o6EHj9y3Kts9R4ZYs/Gr+6N7MCaMlIFA3F1R2O5/m7K06AxfSeO5530PEERE6/WyEg3lsuyw4GHlPZHog==", - "dev": true - }, - "beeper": { - "version": "1.1.1", - "dev": true - }, - "benchmark": { - "version": "2.1.4", + "@jest/expect-utils": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-29.7.0.tgz", + "integrity": "sha512-GlsNBWiFQFCVi9QVSx7f5AgMeLxe9YCCs5PuP2O2LdjDAA8Jh9eX7lA1Jq/xdXw3Wb3hyvlFNfZIfcRetSzYcA==", "dev": true, "requires": { - "lodash": "^4.17.4", - "platform": "^1.3.3" + "jest-get-type": "^29.6.3" } }, - "binary-extensions": { - "version": "2.2.0", - "dev": true - }, - "bn.js": { - "version": "4.12.0", - "dev": true - }, - "body-parser": { - "version": "1.20.3", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", - "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", + "@jest/fake-timers": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-30.2.0.tgz", + "integrity": "sha512-HI3tRLjRxAbBy0VO8dqqm7Hb2mIa8d5bg/NJkyQcOk7V118ObQML8RC5luTF/Zsg4474a+gDvhce7eTnP4GhYw==", "dev": true, "requires": { - "bytes": "3.1.2", - "content-type": "~1.0.5", - "debug": "2.6.9", - "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.13.0", - "raw-body": "2.5.2", - "type-is": "~1.6.18", - "unpipe": "1.0.0" + "@jest/types": "30.2.0", + "@sinonjs/fake-timers": "^13.0.0", + "@types/node": "*", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" }, "dependencies": { - "debug": { - "version": "2.6.9", + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true + }, + "jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, "requires": { - "ms": "2.0.0" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" } }, - "ms": { - "version": "2.0.0", + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true }, - "on-finished": { - "version": "2.4.1", + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, "requires": { - "ee-first": "1.1.1" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" } } } }, - "brace-expansion": { - "version": "1.1.11", - "dev": true, - "requires": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } + "@jest/get-type": { + "version": "30.1.0", + "resolved": "https://registry.npmjs.org/@jest/get-type/-/get-type-30.1.0.tgz", + "integrity": "sha512-eMbZE2hUnx1WV0pmURZY9XoXPkUYjpc55mb0CrhtdWLtzMQPFvu/rZkTLZFTsdaVQa+Tr4eWAteqcUzoawq/uA==", + "dev": true }, - "braces": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", - "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", + "@jest/globals": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/globals/-/globals-30.2.0.tgz", + "integrity": "sha512-b63wmnKPaK+6ZZfpYhz9K61oybvbI1aMcIs80++JI1O1rR1vaxHUCNqo3ITu6NU0d4V34yZFoHMn/uoKr/Rwfw==", "dev": true, "requires": { - "fill-range": "^7.1.1" + "@jest/environment": "30.2.0", + "@jest/expect": "30.2.0", + "@jest/types": "30.2.0", + "jest-mock": "30.2.0" } }, - "brorand": { - "version": "1.1.0", - "dev": true - }, - "browser-pack": { - "version": "6.1.0", + "@jest/pattern": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/@jest/pattern/-/pattern-30.0.1.tgz", + "integrity": "sha512-gWp7NfQW27LaBQz3TITS8L7ZCQ0TLvtmI//4OwlQRx4rnWxcPNIYjxZpDcN4+UlGxgm3jS5QPz8IPTCkb59wZA==", "dev": true, "requires": { - "combine-source-map": "~0.8.0", - "defined": "^1.0.0", - "JSONStream": "^1.0.3", - "safe-buffer": "^5.1.1", - "through2": "^2.0.0", - "umd": "^3.0.0" + "@types/node": "*", + "jest-regex-util": "30.0.1" } }, - "browser-resolve": { - "version": "1.11.3", + "@jest/reporters": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/reporters/-/reporters-30.2.0.tgz", + "integrity": "sha512-DRyW6baWPqKMa9CzeiBjHwjd8XeAyco2Vt8XbcLFjiwCOEKOvy82GJ8QQnJE9ofsxCMPjH4MfH8fCWIHHDKpAQ==", "dev": true, "requires": { - "resolve": "1.1.7" + "@bcoe/v8-coverage": "^0.2.3", + "@jest/console": "30.2.0", + "@jest/test-result": "30.2.0", + "@jest/transform": "30.2.0", + "@jest/types": "30.2.0", + "@jridgewell/trace-mapping": "^0.3.25", + "@types/node": "*", + "chalk": "^4.1.2", + "collect-v8-coverage": "^1.0.2", + "exit-x": "^0.2.2", + "glob": "^10.3.10", + "graceful-fs": "^4.2.11", + "istanbul-lib-coverage": "^3.0.0", + "istanbul-lib-instrument": "^6.0.0", + "istanbul-lib-report": "^3.0.0", + "istanbul-lib-source-maps": "^5.0.0", + "istanbul-reports": "^3.1.3", + "jest-message-util": "30.2.0", + "jest-util": "30.2.0", + "jest-worker": "30.2.0", + "slash": "^3.0.0", + "string-length": "^4.0.2", + "v8-to-istanbul": "^9.0.1" }, "dependencies": { - "resolve": { - "version": "1.1.7", + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true + }, + "brace-expansion": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.2.tgz", + "integrity": "sha512-Jt0vHyM+jmUBqojB7E1NIYadt0vI0Qxjxd2TErW94wDz+E2LAm5vKMXXwg6ZZBTHPuUlDgQHKXvjGBdfcF1ZDQ==", + "dev": true, + "requires": { + "balanced-match": "^1.0.0" + } + }, + "foreground-child": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.3.1.tgz", + "integrity": "sha512-gIXjKqtFuWEgzFRJA9WCQeSJLZDjgJUOMCMzxtvFq/37KojM1BFGufqsCy0r4qSQmYLsZYMeyRqzIWOMup03sw==", + "dev": true, + "requires": { + "cross-spawn": "^7.0.6", + "signal-exit": "^4.0.1" + } + }, + "glob": { + "version": "10.5.0", + "resolved": "https://registry.npmjs.org/glob/-/glob-10.5.0.tgz", + "integrity": "sha512-DfXN8DfhJ7NH3Oe7cFmu3NCu1wKbkReJ8TorzSAFbSKrlNaQSKfIzqYqVY8zlbs2NLBbWpRiU52GX2PbaBVNkg==", + "dev": true, + "requires": { + "foreground-child": "^3.1.0", + "jackspeak": "^3.1.2", + "minimatch": "^9.0.4", + "minipass": "^7.1.2", + "package-json-from-dist": "^1.0.0", + "path-scurry": "^1.11.1" + } + }, + "istanbul-lib-instrument": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-6.0.3.tgz", + "integrity": "sha512-Vtgk7L/R2JHyyGW07spoFlB8/lpjiOLTjMdms6AFMraYt3BaJauod/NGrfnVG/y4Ix1JEuMRPDPEj2ua+zz1/Q==", + "dev": true, + "requires": { + "@babel/core": "^7.23.9", + "@babel/parser": "^7.23.9", + "@istanbuljs/schema": "^0.1.3", + "istanbul-lib-coverage": "^3.2.0", + "semver": "^7.5.4" + } + }, + "istanbul-lib-source-maps": { + "version": "5.0.6", + "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-5.0.6.tgz", + "integrity": "sha512-yg2d+Em4KizZC5niWhQaIomgf5WlL4vOOjZ5xGCmF8SnPE/mDWWXgvRExdcpCgh9lLRRa1/fSYp2ymmbJ1pI+A==", + "dev": true, + "requires": { + "@jridgewell/trace-mapping": "^0.3.23", + "debug": "^4.1.1", + "istanbul-lib-coverage": "^3.0.0" + } + }, + "jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", + "dev": true, + "requires": { + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + } + }, + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "minimatch": { + "version": "9.0.5", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.5.tgz", + "integrity": "sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==", + "dev": true, + "requires": { + "brace-expansion": "^2.0.1" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + }, + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "requires": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + } + }, + "signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", "dev": true + }, + "string-length": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/string-length/-/string-length-4.0.2.tgz", + "integrity": "sha512-+l6rNN5fYHNhZZy41RXsYptCjA2Igmq4EG7kZAYFQI1E1VTXarr6ZPXBg6eq7Y6eK4FEhY6AJlyuFIb/v/S0VQ==", + "dev": true, + "requires": { + "char-regex": "^1.0.2", + "strip-ansi": "^6.0.0" + } } } }, - "browser-stdout": { - "version": "1.3.1", - "dev": true - }, - "browserify": { - "version": "16.5.1", - "dev": true, - "requires": { - "assert": "^1.4.0", - "browser-pack": "^6.0.1", - "browser-resolve": "^1.11.0", - "browserify-zlib": "~0.2.0", - "buffer": "~5.2.1", - "cached-path-relative": "^1.0.0", - "concat-stream": "^1.6.0", - "console-browserify": "^1.1.0", - "constants-browserify": "~1.0.0", - "crypto-browserify": "^3.0.0", - "defined": "^1.0.0", - "deps-sort": "^2.0.0", - "domain-browser": "^1.2.0", - "duplexer2": "~0.1.2", - "events": "^2.0.0", - "glob": "^7.1.0", - "has": "^1.0.0", - "htmlescape": "^1.1.0", - "https-browserify": "^1.0.0", - "inherits": "~2.0.1", - "insert-module-globals": "^7.0.0", - "JSONStream": "^1.0.3", - "labeled-stream-splicer": "^2.0.0", - "mkdirp-classic": "^0.5.2", - "module-deps": "^6.0.0", - "os-browserify": "~0.3.0", - "parents": "^1.0.1", - "path-browserify": "~0.0.0", - "process": "~0.11.0", - "punycode": "^1.3.2", - "querystring-es3": "~0.2.0", - "read-only-stream": "^2.0.0", - "readable-stream": "^2.0.2", - "resolve": "^1.1.4", - "shasum": "^1.0.0", - "shell-quote": "^1.6.1", - "stream-browserify": "^2.0.0", - "stream-http": "^3.0.0", - "string_decoder": "^1.1.1", - "subarg": "^1.0.0", - "syntax-error": "^1.1.1", - "through2": "^2.0.0", - "timers-browserify": "^1.0.1", - "tty-browserify": "0.0.1", - "url": "~0.11.0", - "util": "~0.10.1", - "vm-browserify": "^1.0.0", - "xtend": "^4.0.0" - } - }, - "browserify-aes": { - "version": "1.2.0", + "@jest/schemas": { + "version": "30.0.5", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", + "integrity": "sha512-DmdYgtezMkh3cpU8/1uyXakv3tJRcmcXxBOcO0tbaozPwpmh4YMsnWrQm9ZmZMfa5ocbxzbFk6O4bDPEc/iAnA==", "dev": true, "requires": { - "buffer-xor": "^1.0.3", - "cipher-base": "^1.0.0", - "create-hash": "^1.1.0", - "evp_bytestokey": "^1.0.3", - "inherits": "^2.0.1", - "safe-buffer": "^5.0.1" + "@sinclair/typebox": "^0.34.0" } }, - "browserify-cipher": { - "version": "1.0.1", + "@jest/snapshot-utils": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/snapshot-utils/-/snapshot-utils-30.2.0.tgz", + "integrity": "sha512-0aVxM3RH6DaiLcjj/b0KrIBZhSX1373Xci4l3cW5xiUWPctZ59zQ7jj4rqcJQ/Z8JuN/4wX3FpJSa3RssVvCug==", "dev": true, "requires": { - "browserify-aes": "^1.0.4", - "browserify-des": "^1.0.0", - "evp_bytestokey": "^1.0.0" + "@jest/types": "30.2.0", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "natural-compare": "^1.4.0" } }, - "browserify-des": { - "version": "1.0.2", + "@jest/source-map": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/@jest/source-map/-/source-map-30.0.1.tgz", + "integrity": "sha512-MIRWMUUR3sdbP36oyNyhbThLHyJ2eEDClPCiHVbrYAe5g3CHRArIVpBw7cdSB5fr+ofSfIb2Tnsw8iEHL0PYQg==", "dev": true, "requires": { - "cipher-base": "^1.0.1", - "des.js": "^1.0.0", - "inherits": "^2.0.1", - "safe-buffer": "^5.1.2" + "@jridgewell/trace-mapping": "^0.3.25", + "callsites": "^3.1.0", + "graceful-fs": "^4.2.11" } }, - "browserify-rsa": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/browserify-rsa/-/browserify-rsa-4.1.0.tgz", - "integrity": "sha512-AdEER0Hkspgno2aR97SAf6vi0y0k8NuOpGnVH3O99rcA5Q6sh8QxcngtHuJ6uXwnfAXNM4Gn1Gb7/MV1+Ymbog==", + "@jest/test-result": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/test-result/-/test-result-30.2.0.tgz", + "integrity": "sha512-RF+Z+0CCHkARz5HT9mcQCBulb1wgCP3FBvl9VFokMX27acKphwyQsNuWH3c+ojd1LeWBLoTYoxF0zm6S/66mjg==", "dev": true, "requires": { - "bn.js": "^5.0.0", - "randombytes": "^2.0.1" - }, - "dependencies": { - "bn.js": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", - "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==", - "dev": true - } + "@jest/console": "30.2.0", + "@jest/types": "30.2.0", + "@types/istanbul-lib-coverage": "^2.0.6", + "collect-v8-coverage": "^1.0.2" + } + }, + "@jest/test-sequencer": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/test-sequencer/-/test-sequencer-30.2.0.tgz", + "integrity": "sha512-wXKgU/lk8fKXMu/l5Hog1R61bL4q5GCdT6OJvdAFz1P+QrpoFuLU68eoKuVc4RbrTtNnTL5FByhWdLgOPSph+Q==", + "dev": true, + "requires": { + "@jest/test-result": "30.2.0", + "graceful-fs": "^4.2.11", + "jest-haste-map": "30.2.0", + "slash": "^3.0.0" } }, - "browserify-sign": { - "version": "4.2.2", - "resolved": "https://registry.npmjs.org/browserify-sign/-/browserify-sign-4.2.2.tgz", - "integrity": "sha512-1rudGyeYY42Dk6texmv7c4VcQ0EsvVbLwZkA+AQB7SxvXxmcD93jcHie8bzecJ+ChDlmAm2Qyu0+Ccg5uhZXCg==", + "@jest/transform": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/transform/-/transform-30.2.0.tgz", + "integrity": "sha512-XsauDV82o5qXbhalKxD7p4TZYYdwcaEXC77PPD2HixEFF+6YGppjrAAQurTl2ECWcEomHBMMNS9AH3kcCFx8jA==", "dev": true, "requires": { - "bn.js": "^5.2.1", - "browserify-rsa": "^4.1.0", - "create-hash": "^1.2.0", - "create-hmac": "^1.1.7", - "elliptic": "^6.5.4", - "inherits": "^2.0.4", - "parse-asn1": "^5.1.6", - "readable-stream": "^3.6.2", - "safe-buffer": "^5.2.1" + "@babel/core": "^7.27.4", + "@jest/types": "30.2.0", + "@jridgewell/trace-mapping": "^0.3.25", + "babel-plugin-istanbul": "^7.0.1", + "chalk": "^4.1.2", + "convert-source-map": "^2.0.0", + "fast-json-stable-stringify": "^2.1.0", + "graceful-fs": "^4.2.11", + "jest-haste-map": "30.2.0", + "jest-regex-util": "30.0.1", + "jest-util": "30.2.0", + "micromatch": "^4.0.8", + "pirates": "^4.0.7", + "slash": "^3.0.0", + "write-file-atomic": "^5.0.1" }, "dependencies": { - "bn.js": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", - "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==", + "convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", + "dev": true + }, + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true }, - "readable-stream": { - "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", + "dev": true + }, + "write-file-atomic": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-5.0.1.tgz", + "integrity": "sha512-+QU2zd6OTD8XWIJCbffaiQeH9U73qIqafo1x6V1snCWYGJf6cVE0cDR4D8xRzcEnfI21IFrUPzPGtcPf8AC+Rw==", "dev": true, "requires": { - "inherits": "^2.0.3", - "string_decoder": "^1.1.1", - "util-deprecate": "^1.0.1" + "imurmurhash": "^0.1.4", + "signal-exit": "^4.0.1" } } } }, - "browserify-zlib": { - "version": "0.2.0", + "@jest/types": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-30.2.0.tgz", + "integrity": "sha512-H9xg1/sfVvyfU7o3zMfBEjQ1gcsdeTMgqHoYdN79tuLqfTtuu7WckRA1R5whDwOzxaZAeMKTYWqP+WCAi0CHsg==", "dev": true, "requires": { - "pako": "~1.0.5" + "@jest/pattern": "30.0.1", + "@jest/schemas": "30.0.5", + "@types/istanbul-lib-coverage": "^2.0.6", + "@types/istanbul-reports": "^3.0.4", + "@types/node": "*", + "@types/yargs": "^17.0.33", + "chalk": "^4.1.2" } }, - "browserslist": { - "version": "4.21.5", + "@jridgewell/gen-mapping": { + "version": "0.3.13", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.13.tgz", + "integrity": "sha512-2kkt/7niJ6MgEPxF0bYdQ6etZaA+fQvDcLKckhy1yIQOzaoKjBBjSj63/aLVjYE3qhRt5dvM+uUyfCg6UKCBbA==", "dev": true, "requires": { - "caniuse-lite": "^1.0.30001449", - "electron-to-chromium": "^1.4.284", - "node-releases": "^2.0.8", - "update-browserslist-db": "^1.0.10" + "@jridgewell/sourcemap-codec": "^1.5.0", + "@jridgewell/trace-mapping": "^0.3.24" } }, - "buffer": { - "version": "5.2.1", + "@jridgewell/remapping": { + "version": "2.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/remapping/-/remapping-2.3.5.tgz", + "integrity": "sha512-LI9u/+laYG4Ds1TDKSJW2YPrIlcVYOwi2fUC6xB43lueCjgxV4lffOCZCtYFiH6TNOX+tQKXx97T4IKHbhyHEQ==", "dev": true, "requires": { - "base64-js": "^1.0.2", - "ieee754": "^1.1.4" + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.24" } }, - "buffer-from": { - "version": "1.1.1", - "dev": true - }, - "buffer-xor": { - "version": "1.0.3", - "dev": true - }, - "builtin-status-codes": { - "version": "3.0.0", - "dev": true - }, - "bytes": { - "version": "3.1.2", + "@jridgewell/resolve-uri": { + "version": "3.1.0", "dev": true }, - "cached-path-relative": { - "version": "1.1.0", + "@jridgewell/sourcemap-codec": { + "version": "1.5.5", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.5.tgz", + "integrity": "sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==", "dev": true }, - "caching-transform": { - "version": "4.0.0", + "@jridgewell/trace-mapping": { + "version": "0.3.31", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.31.tgz", + "integrity": "sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==", "dev": true, "requires": { - "hasha": "^5.0.0", - "make-dir": "^3.0.0", - "package-hash": "^4.0.0", - "write-file-atomic": "^3.0.0" + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" } }, - "call-bind": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.8.tgz", - "integrity": "sha512-oKlSFMcMwpUg2ednkhQ454wfWiU/ul3CkJe/PEHcTKuiX6RpbehUiFMXu13HalGZxfUwCQzZG747YXBn1im9ww==", + "@napi-rs/wasm-runtime": { + "version": "0.2.12", + "resolved": "https://registry.npmjs.org/@napi-rs/wasm-runtime/-/wasm-runtime-0.2.12.tgz", + "integrity": "sha512-ZVWUcfwY4E/yPitQJl481FjFo3K22D6qF0DuFH6Y/nbnE11GY5uguDxZMGXPQ8WQ0128MXQD7TnfHyK4oWoIJQ==", "dev": true, + "optional": true, "requires": { - "call-bind-apply-helpers": "^1.0.0", - "es-define-property": "^1.0.0", - "get-intrinsic": "^1.2.4", - "set-function-length": "^1.2.2" + "@emnapi/core": "^1.4.3", + "@emnapi/runtime": "^1.4.3", + "@tybys/wasm-util": "^0.10.0" } }, - "call-bind-apply-helpers": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.2.tgz", - "integrity": "sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==", + "@nodelib/fs.scandir": { + "version": "2.1.5", "dev": true, "requires": { - "es-errors": "^1.3.0", - "function-bind": "^1.1.2" + "@nodelib/fs.stat": "2.0.5", + "run-parallel": "^1.1.9" } }, - "call-bound": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/call-bound/-/call-bound-1.0.4.tgz", - "integrity": "sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg==", + "@nodelib/fs.stat": { + "version": "2.0.5", + "dev": true + }, + "@nodelib/fs.walk": { + "version": "1.2.8", "dev": true, "requires": { - "call-bind-apply-helpers": "^1.0.2", - "get-intrinsic": "^1.3.0" + "@nodelib/fs.scandir": "2.1.5", + "fastq": "^1.6.0" } }, - "callsites": { - "version": "3.1.0", - "dev": true + "@pkgjs/parseargs": { + "version": "0.11.0", + "resolved": "https://registry.npmjs.org/@pkgjs/parseargs/-/parseargs-0.11.0.tgz", + "integrity": "sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==", + "dev": true, + "optional": true }, - "camelcase": { - "version": "6.3.0", + "@pkgr/core": { + "version": "0.2.9", + "resolved": "https://registry.npmjs.org/@pkgr/core/-/core-0.2.9.tgz", + "integrity": "sha512-QNqXyfVS2wm9hweSYD2O7F0G06uurj9kZ96TRQE5Y9hU7+tgdZwIkbAKc5Ocy1HxEY2kuDQa6cQ1WRs/O5LFKA==", "dev": true }, - "caniuse-lite": { - "version": "1.0.30001460", + "@sinclair/typebox": { + "version": "0.34.41", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.34.41.tgz", + "integrity": "sha512-6gS8pZzSXdyRHTIqoqSVknxolr1kzfy4/CeDnrzsVz8TTIWUbOBr6gnzOmTYJ3eXQNh4IYHIGi5aIL7sOZ2G/g==", "dev": true }, - "chai": { - "version": "4.3.7", - "dev": true, - "requires": { - "assertion-error": "^1.1.0", - "check-error": "^1.0.2", - "deep-eql": "^4.1.2", - "get-func-name": "^2.0.0", - "loupe": "^2.3.1", - "pathval": "^1.1.1", - "type-detect": "^4.0.5" - } - }, - "chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", "dev": true, "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" + "type-detect": "4.0.8" } }, - "check-error": { - "version": "1.0.2", - "dev": true - }, - "chokidar": { - "version": "3.5.3", + "@sinonjs/fake-timers": { + "version": "13.0.5", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-13.0.5.tgz", + "integrity": "sha512-36/hTbH2uaWuGVERyC6da9YwGWnzUZXuPro/F2LfsdOsLnCojz/iSH8MxUt/FD2S5XBSVPhmArFUXcpCQ2Hkiw==", "dev": true, "requires": { - "anymatch": "~3.1.2", - "braces": "~3.0.2", - "fsevents": "~2.3.2", - "glob-parent": "~5.1.2", - "is-binary-path": "~2.1.0", - "is-glob": "~4.0.1", - "normalize-path": "~3.0.0", - "readdirp": "~3.6.0" + "@sinonjs/commons": "^3.0.1" } }, - "cipher-base": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/cipher-base/-/cipher-base-1.0.6.tgz", - "integrity": "sha512-3Ek9H3X6pj5TgenXYtNWdaBon1tgYCaebd+XPg0keyjEbEfkD4KkmAxkQ/i1vYvxdcT5nscLBfq9VJRmCBcFSw==", + "@tybys/wasm-util": { + "version": "0.10.1", + "resolved": "https://registry.npmjs.org/@tybys/wasm-util/-/wasm-util-0.10.1.tgz", + "integrity": "sha512-9tTaPJLSiejZKx+Bmog4uSubteqTvFrVrURwkmHixBo0G4seD0zUxp98E1DzUBJxLQ3NPwXrGKDiVjwx/DpPsg==", "dev": true, + "optional": true, "requires": { - "inherits": "^2.0.4", - "safe-buffer": "^5.2.1" + "tslib": "^2.4.0" } }, - "clean-stack": { - "version": "2.2.0", - "dev": true - }, - "cli": { - "version": "1.0.1", + "@types/babel__core": { + "version": "7.20.5", + "resolved": "https://registry.npmjs.org/@types/babel__core/-/babel__core-7.20.5.tgz", + "integrity": "sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==", "dev": true, "requires": { - "exit": "0.1.2", - "glob": "^7.1.1" + "@babel/parser": "^7.20.7", + "@babel/types": "^7.20.7", + "@types/babel__generator": "*", + "@types/babel__template": "*", + "@types/babel__traverse": "*" } }, - "cliui": { - "version": "7.0.4", + "@types/babel__generator": { + "version": "7.27.0", + "resolved": "https://registry.npmjs.org/@types/babel__generator/-/babel__generator-7.27.0.tgz", + "integrity": "sha512-ufFd2Xi92OAVPYsy+P4n7/U7e68fex0+Ee8gSG9KX7eo084CWiQ4sdxktvdl0bOPupXtVJPY19zk6EwWqUQ8lg==", "dev": true, "requires": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.0", - "wrap-ansi": "^7.0.0" + "@babel/types": "^7.0.0" } }, - "color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "@types/babel__template": { + "version": "7.4.4", + "resolved": "https://registry.npmjs.org/@types/babel__template/-/babel__template-7.4.4.tgz", + "integrity": "sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A==", "dev": true, "requires": { - "color-name": "1.1.3" + "@babel/parser": "^7.1.0", + "@babel/types": "^7.0.0" } }, - "color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", - "dev": true - }, - "combine-source-map": { - "version": "0.8.0", + "@types/babel__traverse": { + "version": "7.28.0", + "resolved": "https://registry.npmjs.org/@types/babel__traverse/-/babel__traverse-7.28.0.tgz", + "integrity": "sha512-8PvcXf70gTDZBgt9ptxJ8elBeBjcLOAcOtoO/mPJjtji1+CdGbHgm77om1GrsPxsiE+uXIpNSK64UYaIwQXd4Q==", "dev": true, "requires": { - "convert-source-map": "~1.1.0", - "inline-source-map": "~0.6.0", - "lodash.memoize": "~3.0.3", - "source-map": "~0.5.3" + "@babel/types": "^7.28.2" } }, - "commondir": { - "version": "1.0.1", + "@types/istanbul-lib-coverage": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", + "integrity": "sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w==", "dev": true }, - "concat-map": { - "version": "0.0.1", - "dev": true + "@types/istanbul-lib-report": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-report/-/istanbul-lib-report-3.0.3.tgz", + "integrity": "sha512-NQn7AHQnk/RSLOxrBbGyJM/aVQ+pjj5HCgasFxc0K/KhoATfQ/47AyUl15I2yBUpihjmas+a+VJBOqecrFH+uA==", + "dev": true, + "requires": { + "@types/istanbul-lib-coverage": "*" + } }, - "concat-stream": { - "version": "1.6.2", + "@types/istanbul-reports": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz", + "integrity": "sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==", "dev": true, "requires": { - "buffer-from": "^1.0.0", - "inherits": "^2.0.3", - "readable-stream": "^2.2.2", - "typedarray": "^0.0.6" + "@types/istanbul-lib-report": "*" } }, - "connect": { - "version": "3.7.0", + "@types/jest": { + "version": "29.5.14", + "resolved": "https://registry.npmjs.org/@types/jest/-/jest-29.5.14.tgz", + "integrity": "sha512-ZN+4sdnLUbo8EVvVc2ao0GFW6oVrQRPn4K2lglySj7APvSrgzxHiNNK99us4WDMi57xxA2yggblIAMNhXOotLQ==", "dev": true, "requires": { - "debug": "2.6.9", - "finalhandler": "1.1.2", - "parseurl": "~1.3.3", - "utils-merge": "1.0.1" - }, - "dependencies": { - "debug": { - "version": "2.6.9", - "dev": true, - "requires": { - "ms": "2.0.0" - } - }, - "ms": { - "version": "2.0.0", - "dev": true - } + "expect": "^29.0.0", + "pretty-format": "^29.0.0" } }, - "console-browserify": { - "version": "1.1.0", + "@types/node": { + "version": "20.19.25", + "resolved": "https://registry.npmjs.org/@types/node/-/node-20.19.25.tgz", + "integrity": "sha512-ZsJzA5thDQMSQO788d7IocwwQbI8B5OPzmqNvpf3NY/+MHDAS759Wo0gd2WQeXYt5AAAQjzcrTVC6SKCuYgoCQ==", "dev": true, "requires": { - "date-now": "^0.1.4" + "undici-types": "~6.21.0" } }, - "constants-browserify": { - "version": "1.0.0", + "@types/stack-utils": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.3.tgz", + "integrity": "sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw==", "dev": true }, - "content-type": { - "version": "1.0.5", - "dev": true + "@types/yargs": { + "version": "17.0.35", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.35.tgz", + "integrity": "sha512-qUHkeCyQFxMXg79wQfTtfndEC+N9ZZg76HJftDJp+qH2tV7Gj4OJi7l+PiWwJ+pWtW8GwSmqsDj/oymhrTWXjg==", + "dev": true, + "requires": { + "@types/yargs-parser": "*" + } }, - "convert-source-map": { - "version": "1.1.3", + "@types/yargs-parser": { + "version": "21.0.3", + "resolved": "https://registry.npmjs.org/@types/yargs-parser/-/yargs-parser-21.0.3.tgz", + "integrity": "sha512-I4q9QU9MQv4oEOz4tAHJtNz1cwuLxn2F3xcc2iV5WdqLPpUnj30aUuxt1mAxYTG+oe8CZMV/+6rU4S4gRDzqtQ==", "dev": true }, - "cookie": { - "version": "0.7.2", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.7.2.tgz", - "integrity": "sha512-yki5XnKuf750l50uGTllt6kKILY4nQ1eNIQatoXEByZ5dWgnKqbnqmTrBE5B4N7lrMJKQ2ytWMiTO2o0v6Ew/w==", + "@ungap/structured-clone": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/@ungap/structured-clone/-/structured-clone-1.3.0.tgz", + "integrity": "sha512-WmoN8qaIAo7WTYWbAZuG8PYEhn5fkz7dZrqTBZ7dtt//lL2Gwms1IcnQ5yHqjDfX8Ft5j4YzDM23f87zBfDe9g==", "dev": true }, - "core-util-is": { - "version": "1.0.2", - "dev": true + "@unrs/resolver-binding-android-arm-eabi": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-android-arm-eabi/-/resolver-binding-android-arm-eabi-1.11.1.tgz", + "integrity": "sha512-ppLRUgHVaGRWUx0R0Ut06Mjo9gBaBkg3v/8AxusGLhsIotbBLuRk51rAzqLC8gq6NyyAojEXglNjzf6R948DNw==", + "dev": true, + "optional": true }, - "cors": { - "version": "2.8.5", - "resolved": "https://registry.npmjs.org/cors/-/cors-2.8.5.tgz", - "integrity": "sha512-KIHbLJqu73RGr/hnbrO9uBeixNGuvSQjul/jdFvS/KFSIH1hWVd1ng7zOHx+YrEfInLG7q4n6GHQ9cDtxv/P6g==", + "@unrs/resolver-binding-android-arm64": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-android-arm64/-/resolver-binding-android-arm64-1.11.1.tgz", + "integrity": "sha512-lCxkVtb4wp1v+EoN+HjIG9cIIzPkX5OtM03pQYkG+U5O/wL53LC4QbIeazgiKqluGeVEeBlZahHalCaBvU1a2g==", "dev": true, - "requires": { - "object-assign": "^4", - "vary": "^1" - } + "optional": true }, - "create-ecdh": { - "version": "4.0.3", + "@unrs/resolver-binding-darwin-arm64": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-darwin-arm64/-/resolver-binding-darwin-arm64-1.11.1.tgz", + "integrity": "sha512-gPVA1UjRu1Y/IsB/dQEsp2V1pm44Of6+LWvbLc9SDk1c2KhhDRDBUkQCYVWe6f26uJb3fOK8saWMgtX8IrMk3g==", "dev": true, - "requires": { - "bn.js": "^4.1.0", - "elliptic": "^6.0.0" - } + "optional": true }, - "create-hash": { - "version": "1.2.0", + "@unrs/resolver-binding-darwin-x64": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-darwin-x64/-/resolver-binding-darwin-x64-1.11.1.tgz", + "integrity": "sha512-cFzP7rWKd3lZaCsDze07QX1SC24lO8mPty9vdP+YVa3MGdVgPmFc59317b2ioXtgCMKGiCLxJ4HQs62oz6GfRQ==", "dev": true, - "requires": { - "cipher-base": "^1.0.1", - "inherits": "^2.0.1", - "md5.js": "^1.3.4", - "ripemd160": "^2.0.1", - "sha.js": "^2.4.0" - } + "optional": true }, - "create-hmac": { - "version": "1.1.7", + "@unrs/resolver-binding-freebsd-x64": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-freebsd-x64/-/resolver-binding-freebsd-x64-1.11.1.tgz", + "integrity": "sha512-fqtGgak3zX4DCB6PFpsH5+Kmt/8CIi4Bry4rb1ho6Av2QHTREM+47y282Uqiu3ZRF5IQioJQ5qWRV6jduA+iGw==", "dev": true, - "requires": { - "cipher-base": "^1.0.3", - "create-hash": "^1.1.0", - "inherits": "^2.0.1", - "ripemd160": "^2.0.0", - "safe-buffer": "^5.0.1", - "sha.js": "^2.4.8" - } + "optional": true }, - "cross-spawn": { - "version": "7.0.3", + "@unrs/resolver-binding-linux-arm-gnueabihf": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm-gnueabihf/-/resolver-binding-linux-arm-gnueabihf-1.11.1.tgz", + "integrity": "sha512-u92mvlcYtp9MRKmP+ZvMmtPN34+/3lMHlyMj7wXJDeXxuM0Vgzz0+PPJNsro1m3IZPYChIkn944wW8TYgGKFHw==", "dev": true, - "requires": { - "path-key": "^3.1.0", - "shebang-command": "^2.0.0", - "which": "^2.0.1" - }, - "dependencies": { - "which": { - "version": "2.0.2", - "dev": true, - "requires": { - "isexe": "^2.0.0" - } - } - } + "optional": true }, - "crypto-browserify": { - "version": "3.12.0", + "@unrs/resolver-binding-linux-arm-musleabihf": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm-musleabihf/-/resolver-binding-linux-arm-musleabihf-1.11.1.tgz", + "integrity": "sha512-cINaoY2z7LVCrfHkIcmvj7osTOtm6VVT16b5oQdS4beibX2SYBwgYLmqhBjA1t51CarSaBuX5YNsWLjsqfW5Cw==", "dev": true, - "requires": { - "browserify-cipher": "^1.0.0", - "browserify-sign": "^4.0.0", - "create-ecdh": "^4.0.0", - "create-hash": "^1.1.0", - "create-hmac": "^1.1.0", - "diffie-hellman": "^5.0.0", - "inherits": "^2.0.1", - "pbkdf2": "^3.0.3", - "public-encrypt": "^4.0.0", - "randombytes": "^2.0.0", - "randomfill": "^1.0.3" - } + "optional": true }, - "custom-event": { - "version": "1.0.1", - "dev": true + "@unrs/resolver-binding-linux-arm64-gnu": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm64-gnu/-/resolver-binding-linux-arm64-gnu-1.11.1.tgz", + "integrity": "sha512-34gw7PjDGB9JgePJEmhEqBhWvCiiWCuXsL9hYphDF7crW7UgI05gyBAi6MF58uGcMOiOqSJ2ybEeCvHcq0BCmQ==", + "dev": true, + "optional": true }, - "dash-ast": { - "version": "1.0.0", - "dev": true + "@unrs/resolver-binding-linux-arm64-musl": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm64-musl/-/resolver-binding-linux-arm64-musl-1.11.1.tgz", + "integrity": "sha512-RyMIx6Uf53hhOtJDIamSbTskA99sPHS96wxVE/bJtePJJtpdKGXO1wY90oRdXuYOGOTuqjT8ACccMc4K6QmT3w==", + "dev": true, + "optional": true }, - "date-format": { - "version": "4.0.14", - "dev": true + "@unrs/resolver-binding-linux-ppc64-gnu": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-ppc64-gnu/-/resolver-binding-linux-ppc64-gnu-1.11.1.tgz", + "integrity": "sha512-D8Vae74A4/a+mZH0FbOkFJL9DSK2R6TFPC9M+jCWYia/q2einCubX10pecpDiTmkJVUH+y8K3BZClycD8nCShA==", + "dev": true, + "optional": true }, - "date-now": { - "version": "0.1.4", - "dev": true + "@unrs/resolver-binding-linux-riscv64-gnu": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-riscv64-gnu/-/resolver-binding-linux-riscv64-gnu-1.11.1.tgz", + "integrity": "sha512-frxL4OrzOWVVsOc96+V3aqTIQl1O2TjgExV4EKgRY09AJ9leZpEg8Ak9phadbuX0BA4k8U5qtvMSQQGGmaJqcQ==", + "dev": true, + "optional": true }, - "debug": { - "version": "4.3.4", + "@unrs/resolver-binding-linux-riscv64-musl": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-riscv64-musl/-/resolver-binding-linux-riscv64-musl-1.11.1.tgz", + "integrity": "sha512-mJ5vuDaIZ+l/acv01sHoXfpnyrNKOk/3aDoEdLO/Xtn9HuZlDD6jKxHlkN8ZhWyLJsRBxfv9GYM2utQ1SChKew==", "dev": true, - "requires": { - "ms": "2.1.2" - } + "optional": true }, - "decamelize": { - "version": "4.0.0", - "dev": true + "@unrs/resolver-binding-linux-s390x-gnu": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-s390x-gnu/-/resolver-binding-linux-s390x-gnu-1.11.1.tgz", + "integrity": "sha512-kELo8ebBVtb9sA7rMe1Cph4QHreByhaZ2QEADd9NzIQsYNQpt9UkM9iqr2lhGr5afh885d/cB5QeTXSbZHTYPg==", + "dev": true, + "optional": true }, - "deep-eql": { - "version": "4.1.3", + "@unrs/resolver-binding-linux-x64-gnu": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-x64-gnu/-/resolver-binding-linux-x64-gnu-1.11.1.tgz", + "integrity": "sha512-C3ZAHugKgovV5YvAMsxhq0gtXuwESUKc5MhEtjBpLoHPLYM+iuwSj3lflFwK3DPm68660rZ7G8BMcwSro7hD5w==", "dev": true, - "requires": { - "type-detect": "^4.0.0" - } + "optional": true }, - "deep-is": { - "version": "0.1.3", - "dev": true + "@unrs/resolver-binding-linux-x64-musl": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-x64-musl/-/resolver-binding-linux-x64-musl-1.11.1.tgz", + "integrity": "sha512-rV0YSoyhK2nZ4vEswT/QwqzqQXw5I6CjoaYMOX0TqBlWhojUf8P94mvI7nuJTeaCkkds3QE4+zS8Ko+GdXuZtA==", + "dev": true, + "optional": true }, - "default-require-extensions": { - "version": "3.0.1", + "@unrs/resolver-binding-wasm32-wasi": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-wasm32-wasi/-/resolver-binding-wasm32-wasi-1.11.1.tgz", + "integrity": "sha512-5u4RkfxJm+Ng7IWgkzi3qrFOvLvQYnPBmjmZQ8+szTK/b31fQCnleNl1GgEt7nIsZRIf5PLhPwT0WM+q45x/UQ==", "dev": true, + "optional": true, "requires": { - "strip-bom": "^4.0.0" + "@napi-rs/wasm-runtime": "^0.2.11" } }, - "define-data-property": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz", - "integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==", + "@unrs/resolver-binding-win32-arm64-msvc": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-win32-arm64-msvc/-/resolver-binding-win32-arm64-msvc-1.11.1.tgz", + "integrity": "sha512-nRcz5Il4ln0kMhfL8S3hLkxI85BXs3o8EYoattsJNdsX4YUU89iOkVn7g0VHSRxFuVMdM4Q1jEpIId1Ihim/Uw==", "dev": true, - "requires": { - "es-define-property": "^1.0.0", - "es-errors": "^1.3.0", - "gopd": "^1.0.1" - } + "optional": true }, - "defined": { - "version": "1.0.0", - "dev": true + "@unrs/resolver-binding-win32-ia32-msvc": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-win32-ia32-msvc/-/resolver-binding-win32-ia32-msvc-1.11.1.tgz", + "integrity": "sha512-DCEI6t5i1NmAZp6pFonpD5m7i6aFrpofcp4LA2i8IIq60Jyo28hamKBxNrZcyOwVOZkgsRp9O2sXWBWP8MnvIQ==", + "dev": true, + "optional": true }, - "depd": { - "version": "2.0.0", - "dev": true + "@unrs/resolver-binding-win32-x64-msvc": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-win32-x64-msvc/-/resolver-binding-win32-x64-msvc-1.11.1.tgz", + "integrity": "sha512-lrW200hZdbfRtztbygyaq/6jP6AKE8qQN2KvPcJ+x7wiD038YtnYtZ82IMNJ69GJibV7bwL3y9FgK+5w/pYt6g==", + "dev": true, + "optional": true }, - "deps-sort": { - "version": "2.0.0", + "acorn": { + "version": "7.4.1", + "dev": true, + "peer": true + }, + "acorn-jsx": { + "version": "5.3.2", + "dev": true, + "requires": {} + }, + "ajv": { + "version": "6.12.6", "dev": true, "requires": { - "JSONStream": "^1.0.3", - "shasum": "^1.0.0", - "subarg": "^1.0.0", - "through2": "^2.0.0" + "fast-deep-equal": "^3.1.1", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.4.1", + "uri-js": "^4.2.2" } }, - "des.js": { - "version": "1.0.0", + "ansi-escapes": { + "version": "4.3.2", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", + "integrity": "sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==", "dev": true, "requires": { - "inherits": "^2.0.1", - "minimalistic-assert": "^1.0.0" + "type-fest": "^0.21.3" + }, + "dependencies": { + "type-fest": { + "version": "0.21.3", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.21.3.tgz", + "integrity": "sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==", + "dev": true + } } }, - "destroy": { - "version": "1.2.0", + "ansi-regex": { + "version": "5.0.1", "dev": true }, - "detective": { - "version": "5.2.0", + "ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, "requires": { - "acorn-node": "^1.6.1", - "defined": "^1.0.0", - "minimist": "^1.1.1" + "color-convert": "^2.0.1" } }, - "di": { - "version": "0.0.1", - "dev": true - }, - "diff": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/diff/-/diff-5.2.0.tgz", - "integrity": "sha512-uIFDxqpRZGZ6ThOk84hEfqWoHx2devRFvpTZcTHur85vImfaxUbTW9Ryh4CpCuDnToOP1CEtXKIgytHBPVff5A==", - "dev": true - }, - "diffie-hellman": { - "version": "5.0.3", + "anymatch": { + "version": "3.1.3", "dev": true, "requires": { - "bn.js": "^4.1.0", - "miller-rabin": "^4.0.0", - "randombytes": "^2.0.0" + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" } }, - "doctrine": { - "version": "3.0.0", + "argparse": { + "version": "1.0.10", "dev": true, "requires": { - "esutils": "^2.0.2" + "sprintf-js": "~1.0.2" } }, - "dom-serialize": { - "version": "2.2.1", + "babel-jest": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/babel-jest/-/babel-jest-30.2.0.tgz", + "integrity": "sha512-0YiBEOxWqKkSQWL9nNGGEgndoeL0ZpWrbLMNL5u/Kaxrli3Eaxlt3ZtIDktEvXt4L/R9r3ODr2zKwGM/2BjxVw==", "dev": true, "requires": { - "custom-event": "~1.0.0", - "ent": "~2.2.0", - "extend": "^3.0.0", - "void-elements": "^2.0.0" + "@jest/transform": "30.2.0", + "@types/babel__core": "^7.20.5", + "babel-plugin-istanbul": "^7.0.1", + "babel-preset-jest": "30.2.0", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "slash": "^3.0.0" } }, - "dom-serializer": { - "version": "0.2.1", + "babel-plugin-istanbul": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-7.0.1.tgz", + "integrity": "sha512-D8Z6Qm8jCvVXtIRkBnqNHX0zJ37rQcFJ9u8WOS6tkYOsRdHBzypCstaxWiu5ZIlqQtviRYbgnRLSoCEvjqcqbA==", "dev": true, "requires": { - "domelementtype": "^2.0.1", - "entities": "^2.0.0" + "@babel/helper-plugin-utils": "^7.0.0", + "@istanbuljs/load-nyc-config": "^1.0.0", + "@istanbuljs/schema": "^0.1.3", + "istanbul-lib-instrument": "^6.0.2", + "test-exclude": "^6.0.0" }, "dependencies": { - "domelementtype": { - "version": "2.0.1", - "dev": true - }, - "entities": { - "version": "2.0.0", - "dev": true + "istanbul-lib-instrument": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-6.0.3.tgz", + "integrity": "sha512-Vtgk7L/R2JHyyGW07spoFlB8/lpjiOLTjMdms6AFMraYt3BaJauod/NGrfnVG/y4Ix1JEuMRPDPEj2ua+zz1/Q==", + "dev": true, + "requires": { + "@babel/core": "^7.23.9", + "@babel/parser": "^7.23.9", + "@istanbuljs/schema": "^0.1.3", + "istanbul-lib-coverage": "^3.2.0", + "semver": "^7.5.4" + } } } }, - "domain-browser": { + "babel-plugin-jest-hoist": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-30.2.0.tgz", + "integrity": "sha512-ftzhzSGMUnOzcCXd6WHdBGMyuwy15Wnn0iyyWGKgBDLxf9/s5ABuraCSpBX2uG0jUg4rqJnxsLc5+oYBqoxVaA==", + "dev": true, + "requires": { + "@types/babel__core": "^7.20.5" + } + }, + "babel-preset-current-node-syntax": { "version": "1.2.0", + "resolved": "https://registry.npmjs.org/babel-preset-current-node-syntax/-/babel-preset-current-node-syntax-1.2.0.tgz", + "integrity": "sha512-E/VlAEzRrsLEb2+dv8yp3bo4scof3l9nR4lrld+Iy5NyVqgVYUJnDAmunkhPMisRI32Qc4iRiz425d8vM++2fg==", + "dev": true, + "requires": { + "@babel/plugin-syntax-async-generators": "^7.8.4", + "@babel/plugin-syntax-bigint": "^7.8.3", + "@babel/plugin-syntax-class-properties": "^7.12.13", + "@babel/plugin-syntax-class-static-block": "^7.14.5", + "@babel/plugin-syntax-import-attributes": "^7.24.7", + "@babel/plugin-syntax-import-meta": "^7.10.4", + "@babel/plugin-syntax-json-strings": "^7.8.3", + "@babel/plugin-syntax-logical-assignment-operators": "^7.10.4", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3", + "@babel/plugin-syntax-numeric-separator": "^7.10.4", + "@babel/plugin-syntax-object-rest-spread": "^7.8.3", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.3", + "@babel/plugin-syntax-optional-chaining": "^7.8.3", + "@babel/plugin-syntax-private-property-in-object": "^7.14.5", + "@babel/plugin-syntax-top-level-await": "^7.14.5" + } + }, + "babel-preset-jest": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/babel-preset-jest/-/babel-preset-jest-30.2.0.tgz", + "integrity": "sha512-US4Z3NOieAQumwFnYdUWKvUKh8+YSnS/gB3t6YBiz0bskpu7Pine8pPCheNxlPEW4wnUkma2a94YuW2q3guvCQ==", + "dev": true, + "requires": { + "babel-plugin-jest-hoist": "30.2.0", + "babel-preset-current-node-syntax": "^1.2.0" + } + }, + "balanced-match": { + "version": "1.0.0", "dev": true }, - "domelementtype": { - "version": "1.3.1", + "baseline-browser-mapping": { + "version": "2.8.31", + "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.8.31.tgz", + "integrity": "sha512-a28v2eWrrRWPpJSzxc+mKwm0ZtVx/G8SepdQZDArnXYU/XS+IF6mp8aB/4E+hH1tyGCoDo3KlUCdlSxGDsRkAw==", "dev": true }, - "domhandler": { - "version": "2.3.0", + "benchmark": { + "version": "2.1.4", "dev": true, "requires": { - "domelementtype": "1" + "lodash": "^4.17.4", + "platform": "^1.3.3" } }, - "domutils": { - "version": "1.5.1", + "brace-expansion": { + "version": "1.1.11", "dev": true, "requires": { - "dom-serializer": "0", - "domelementtype": "1" + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" } }, - "dunder-proto": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz", - "integrity": "sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==", + "braces": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", + "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", "dev": true, "requires": { - "call-bind-apply-helpers": "^1.0.1", - "es-errors": "^1.3.0", - "gopd": "^1.2.0" + "fill-range": "^7.1.1" } }, - "duplexer2": { - "version": "0.1.4", + "browserslist": { + "version": "4.28.0", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.28.0.tgz", + "integrity": "sha512-tbydkR/CxfMwelN0vwdP/pLkDwyAASZ+VfWm4EOwlB6SWhx1sYnWLqo8N5j0rAzPfzfRaxt0mM/4wPU/Su84RQ==", + "dev": true, + "requires": { + "baseline-browser-mapping": "^2.8.25", + "caniuse-lite": "^1.0.30001754", + "electron-to-chromium": "^1.5.249", + "node-releases": "^2.0.27", + "update-browserslist-db": "^1.1.4" + } + }, + "bser": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/bser/-/bser-2.1.1.tgz", + "integrity": "sha512-gQxTNE/GAfIIrmHLUE3oJyp5FO6HRBfhjnw4/wMmA63ZGDJnWBmgY/lyQBpnDUkGmAhbSe39tx2d/iTOAfglwQ==", "dev": true, "requires": { - "readable-stream": "^2.0.2" + "node-int64": "^0.4.0" } }, - "ee-first": { + "buffer-from": { "version": "1.1.1", "dev": true }, - "electron-to-chromium": { - "version": "1.4.317", + "callsites": { + "version": "3.1.0", "dev": true }, - "elliptic": { - "version": "6.6.1", - "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.6.1.tgz", - "integrity": "sha512-RaddvvMatK2LJHqFJ+YA4WysVN5Ita9E35botqIYspQ4TkRAlCicdzKOjlyv/1Za5RyTNn7di//eEV0uTAfe3g==", + "camelcase": { + "version": "6.3.0", + "dev": true + }, + "caniuse-lite": { + "version": "1.0.30001757", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001757.tgz", + "integrity": "sha512-r0nnL/I28Zi/yjk1el6ilj27tKcdjLsNqAOZr0yVjWPrSQyHgKI2INaEWw21bAQSv2LXRt1XuCS/GomNpWOxsQ==", + "dev": true + }, + "chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, "requires": { - "bn.js": "^4.11.9", - "brorand": "^1.1.0", - "hash.js": "^1.0.0", - "hmac-drbg": "^1.0.1", - "inherits": "^2.0.4", - "minimalistic-assert": "^1.0.1", - "minimalistic-crypto-utils": "^1.0.1" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" } }, - "encodeurl": { + "char-regex": { "version": "1.0.2", + "resolved": "https://registry.npmjs.org/char-regex/-/char-regex-1.0.2.tgz", + "integrity": "sha512-kWWXztvZ5SBQV+eRgKFeh8q5sLuZY2+8WUIzlxWVTg+oGwY14qylx1KbKzHd8P6ZYkAg0xyIDU9JMHhyJMZ1jw==", + "dev": true + }, + "ci-info": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", + "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", + "dev": true + }, + "cjs-module-lexer": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/cjs-module-lexer/-/cjs-module-lexer-2.1.1.tgz", + "integrity": "sha512-+CmxIZ/L2vNcEfvNtLdU0ZQ6mbq3FZnwAP2PPTiKP+1QOoKwlKlPgb8UKV0Dds7QVaMnHm+FwSft2VB0s/SLjQ==", + "dev": true + }, + "co": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/co/-/co-4.6.0.tgz", + "integrity": "sha512-QVb0dM5HvG+uaxitm8wONl7jltx8dqhfU33DcqtOZcLSVIKSDDLDi7+0LbAKiyI8hD9u42m2YxXSkMGWThaecQ==", + "dev": true + }, + "collect-v8-coverage": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/collect-v8-coverage/-/collect-v8-coverage-1.0.3.tgz", + "integrity": "sha512-1L5aqIkwPfiodaMgQunkF1zRhNqifHBmtbbbxcr6yVxxBnliw4TDOW6NxpO8DJLgJ16OT+Y4ztZqP6p/FtXnAw==", + "dev": true + }, + "color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "requires": { + "color-name": "~1.1.4" + } + }, + "color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true }, - "engine.io": { - "version": "6.6.2", - "resolved": "https://registry.npmjs.org/engine.io/-/engine.io-6.6.2.tgz", - "integrity": "sha512-gmNvsYi9C8iErnZdVcJnvCpSKbWTt1E8+JZo8b+daLninywUWi5NQ5STSHZ9rFjFO7imNcvb8Pc5pe/wMR5xEw==", + "concat-map": { + "version": "0.0.1", + "dev": true + }, + "cross-spawn": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz", + "integrity": "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==", "dev": true, "requires": { - "@types/cookie": "^0.4.1", - "@types/cors": "^2.8.12", - "@types/node": ">=10.0.0", - "accepts": "~1.3.4", - "base64id": "2.0.0", - "cookie": "~0.7.2", - "cors": "~2.8.5", - "debug": "~4.3.1", - "engine.io-parser": "~5.2.1", - "ws": "~8.17.1" + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" }, "dependencies": { - "ws": { - "version": "8.17.1", - "resolved": "https://registry.npmjs.org/ws/-/ws-8.17.1.tgz", - "integrity": "sha512-6XQFvXTkbfUOZOKKILFG1PDK2NDQs4azKQl26T0YS5CxqWLgXajbPZ+h4gZekJyRqFU8pvnbAbbs/3TgRPy+GQ==", + "which": { + "version": "2.0.2", "dev": true, - "requires": {} + "requires": { + "isexe": "^2.0.0" + } } } }, - "engine.io-parser": { - "version": "5.2.3", - "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.2.3.tgz", - "integrity": "sha512-HqD3yTBfnBxIrbnM1DoD6Pcq8NECnh8d4As1Qgh0z5Gg3jRRIqijury0CL3ghu/edArpUYiYqQiDUQBIs4np3Q==", - "dev": true + "debug": { + "version": "4.3.4", + "dev": true, + "requires": { + "ms": "2.1.2" + } }, - "ent": { - "version": "2.2.0", + "dedent": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/dedent/-/dedent-1.7.0.tgz", + "integrity": "sha512-HGFtf8yhuhGhqO07SV79tRp+br4MnbdjeVxotpn1QBl30pcLLCQjX5b2295ll0fv8RKDKsmWYrl05usHM9CewQ==", + "dev": true, + "requires": {} + }, + "deep-is": { + "version": "0.1.3", "dev": true }, - "entities": { - "version": "1.0.0", + "deepmerge": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.3.1.tgz", + "integrity": "sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A==", "dev": true }, - "es-define-property": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.1.tgz", - "integrity": "sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==", + "detect-newline": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/detect-newline/-/detect-newline-3.1.0.tgz", + "integrity": "sha512-TLz+x/vEXm/Y7P7wn1EJFNLxYpUD4TgMosxY6fAVJUnJMbupHBOncxyWUG9OpTaH9EBD7uFI5LfEgmMOc54DsA==", "dev": true }, - "es-errors": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", - "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==", + "diff-sequences": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/diff-sequences/-/diff-sequences-29.6.3.tgz", + "integrity": "sha512-EjePK1srD3P08o2j4f0ExnylqRs5B9tJjcp9t1krH2qRi8CCdsYfwe9JgSLurFBWwq4uOlipzfk5fHNvwFKr8Q==", "dev": true }, - "es-object-atoms": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.1.1.tgz", - "integrity": "sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA==", + "doctrine": { + "version": "3.0.0", "dev": true, "requires": { - "es-errors": "^1.3.0" + "esutils": "^2.0.2" } }, - "es6-error": { - "version": "4.1.1", + "eastasianwidth": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/eastasianwidth/-/eastasianwidth-0.2.0.tgz", + "integrity": "sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==", "dev": true }, - "escalade": { - "version": "3.1.1", + "electron-to-chromium": { + "version": "1.5.262", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.262.tgz", + "integrity": "sha512-NlAsMteRHek05jRUxUR0a5jpjYq9ykk6+kO0yRaMi5moe7u0fVIOeQ3Y30A8dIiWFBNUoQGi1ljb1i5VtS9WQQ==", "dev": true }, - "escape-html": { - "version": "1.0.3", + "emittery": { + "version": "0.13.1", + "resolved": "https://registry.npmjs.org/emittery/-/emittery-0.13.1.tgz", + "integrity": "sha512-DeWwawk6r5yR9jFgnDKYt4sLS0LmHJJi3ZOnb5/JdbYwj3nW+FxQnHIjhBKz8YLC7oRNPVM9NQ47I3CVx34eqQ==", "dev": true }, - "escape-string-regexp": { - "version": "1.0.5", + "emoji-regex": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", + "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", + "dev": true + }, + "error-ex": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.4.tgz", + "integrity": "sha512-sqQamAnR14VgCr1A618A3sGrygcpK+HEbenA/HiEAkkUwcZIIB/tgWqHFxWgOyDh4nB4JCRimh79dR5Ywc9MDQ==", + "dev": true, + "requires": { + "is-arrayish": "^0.2.1" + } + }, + "esbuild": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.27.0.tgz", + "integrity": "sha512-jd0f4NHbD6cALCyGElNpGAOtWxSq46l9X/sWB0Nzd5er4Kz2YTm+Vl0qKFT9KUJvD8+fiO8AvoHhFvEatfVixA==", + "dev": true, + "requires": { + "@esbuild/aix-ppc64": "0.27.0", + "@esbuild/android-arm": "0.27.0", + "@esbuild/android-arm64": "0.27.0", + "@esbuild/android-x64": "0.27.0", + "@esbuild/darwin-arm64": "0.27.0", + "@esbuild/darwin-x64": "0.27.0", + "@esbuild/freebsd-arm64": "0.27.0", + "@esbuild/freebsd-x64": "0.27.0", + "@esbuild/linux-arm": "0.27.0", + "@esbuild/linux-arm64": "0.27.0", + "@esbuild/linux-ia32": "0.27.0", + "@esbuild/linux-loong64": "0.27.0", + "@esbuild/linux-mips64el": "0.27.0", + "@esbuild/linux-ppc64": "0.27.0", + "@esbuild/linux-riscv64": "0.27.0", + "@esbuild/linux-s390x": "0.27.0", + "@esbuild/linux-x64": "0.27.0", + "@esbuild/netbsd-arm64": "0.27.0", + "@esbuild/netbsd-x64": "0.27.0", + "@esbuild/openbsd-arm64": "0.27.0", + "@esbuild/openbsd-x64": "0.27.0", + "@esbuild/openharmony-arm64": "0.27.0", + "@esbuild/sunos-x64": "0.27.0", + "@esbuild/win32-arm64": "0.27.0", + "@esbuild/win32-ia32": "0.27.0", + "@esbuild/win32-x64": "0.27.0" + } + }, + "escalade": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz", + "integrity": "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==", "dev": true }, "eslint": { @@ -7796,36 +9470,10 @@ "text-table": "^0.2.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, "argparse": { "version": "2.0.1", "dev": true }, - "chalk": { - "version": "4.1.2", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "dev": true - }, "escape-string-regexp": { "version": "4.0.0", "dev": true @@ -7837,10 +9485,6 @@ "is-glob": "^4.0.3" } }, - "has-flag": { - "version": "4.0.0", - "dev": true - }, "js-yaml": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.1.tgz", @@ -7881,13 +9525,6 @@ "version": "1.2.1", "dev": true }, - "supports-color": { - "version": "7.2.0", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - }, "type-check": { "version": "0.4.0", "dev": true, @@ -7963,29 +9600,41 @@ "version": "2.0.3", "dev": true }, - "eventemitter3": { - "version": "4.0.0", - "dev": true - }, - "events": { - "version": "2.1.0", - "dev": true - }, - "evp_bytestokey": { - "version": "1.0.3", + "execa": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", + "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", "dev": true, "requires": { - "md5.js": "^1.3.4", - "safe-buffer": "^5.1.1" + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" } }, - "exit": { - "version": "0.1.2", + "exit-x": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/exit-x/-/exit-x-0.2.2.tgz", + "integrity": "sha512-+I6B/IkJc1o/2tiURyz/ivu/O0nKNEArIUB5O7zBrlDVJr22SCLH3xTeEry428LvFhRzIA1g8izguxJ/gbNcVQ==", "dev": true }, - "extend": { - "version": "3.0.2", - "dev": true + "expect": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/expect/-/expect-29.7.0.tgz", + "integrity": "sha512-2Zks0hf1VLFYI1kbh0I5jP3KHHyCHpkfyHBzsSXRFgl/Bg9mWYfMW8oD+PdMPlEwy5HNsR9JutYy6pMeOh61nw==", + "dev": true, + "requires": { + "@jest/expect-utils": "^29.7.0", + "jest-get-type": "^29.6.3", + "jest-matcher-utils": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-util": "^29.7.0" + } }, "fast-deep-equal": { "version": "3.1.3", @@ -8006,6 +9655,15 @@ "reusify": "^1.0.4" } }, + "fb-watchman": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/fb-watchman/-/fb-watchman-2.0.2.tgz", + "integrity": "sha512-p5161BqbuCaSnB8jIbzQHOlpgsPmK5rJVDfDKO91Axs5NC1uu3HRQm6wt9cd9/+GtQQIO53JdGXXoyDpTAsgYA==", + "dev": true, + "requires": { + "bser": "2.1.1" + } + }, "file-entry-cache": { "version": "6.0.1", "dev": true, @@ -8022,41 +9680,6 @@ "to-regex-range": "^5.0.1" } }, - "finalhandler": { - "version": "1.1.2", - "dev": true, - "requires": { - "debug": "2.6.9", - "encodeurl": "~1.0.2", - "escape-html": "~1.0.3", - "on-finished": "~2.3.0", - "parseurl": "~1.3.3", - "statuses": "~1.5.0", - "unpipe": "~1.0.0" - }, - "dependencies": { - "debug": { - "version": "2.6.9", - "dev": true, - "requires": { - "ms": "2.0.0" - } - }, - "ms": { - "version": "2.0.0", - "dev": true - } - } - }, - "find-cache-dir": { - "version": "3.3.2", - "dev": true, - "requires": { - "commondir": "^1.0.1", - "make-dir": "^3.0.2", - "pkg-dir": "^4.1.0" - } - }, "find-up": { "version": "5.0.0", "dev": true, @@ -8065,10 +9688,6 @@ "path-exists": "^4.0.0" } }, - "flat": { - "version": "5.0.2", - "dev": true - }, "flat-cache": { "version": "3.0.4", "dev": true, @@ -8081,325 +9700,78 @@ "version": "3.2.7", "dev": true }, - "follow-redirects": { - "version": "1.15.6", - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.6.tgz", - "integrity": "sha512-wWN62YITEaOpSK584EZXJafH1AGpO8RVgElfkuXbTOrPX4fIfOyEpW/CsiNd8JdYrAoOvafRTOEnvsO++qCqFA==", - "dev": true - }, - "for-each": { - "version": "0.3.5", - "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.5.tgz", - "integrity": "sha512-dKx12eRCVIzqCxFGplyFKJMPvLEWgmNtUrpTiJIR5u97zEhRG8ySrtboPHZXx7daLxQVrl643cTzbab2tkQjxg==", - "dev": true, - "requires": { - "is-callable": "^1.2.7" - } - }, - "foreground-child": { - "version": "2.0.0", - "dev": true, - "requires": { - "cross-spawn": "^7.0.0", - "signal-exit": "^3.0.2" - } - }, - "fromentries": { - "version": "1.3.2", - "dev": true - }, - "fs-extra": { - "version": "8.1.0", - "dev": true, - "requires": { - "graceful-fs": "^4.2.0", - "jsonfile": "^4.0.0", - "universalify": "^0.1.0" - } - }, "fs.realpath": { "version": "1.0.0", "dev": true }, "fsevents": { - "version": "2.3.2", + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", "dev": true, "optional": true }, - "function-bind": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", - "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", - "dev": true - }, "gensync": { "version": "1.0.0-beta.2", "dev": true }, - "get-assigned-identifiers": { - "version": "1.2.0", - "dev": true - }, "get-caller-file": { "version": "2.0.5", "dev": true }, - "get-func-name": { - "version": "2.0.0", - "dev": true - }, - "get-intrinsic": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.3.0.tgz", - "integrity": "sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ==", - "dev": true, - "requires": { - "call-bind-apply-helpers": "^1.0.2", - "es-define-property": "^1.0.1", - "es-errors": "^1.3.0", - "es-object-atoms": "^1.1.1", - "function-bind": "^1.1.2", - "get-proto": "^1.0.1", - "gopd": "^1.2.0", - "has-symbols": "^1.1.0", - "hasown": "^2.0.2", - "math-intrinsics": "^1.1.0" - } - }, "get-package-type": { "version": "0.1.0", "dev": true }, - "get-proto": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/get-proto/-/get-proto-1.0.1.tgz", - "integrity": "sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==", - "dev": true, - "requires": { - "dunder-proto": "^1.0.1", - "es-object-atoms": "^1.0.0" - } - }, - "glob": { - "version": "7.2.0", - "dev": true, - "requires": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - } - }, - "glob-parent": { - "version": "5.1.2", - "dev": true, - "requires": { - "is-glob": "^4.0.1" - } - }, - "globals": { - "version": "13.20.0", - "dev": true, - "requires": { - "type-fest": "^0.20.2" - } - }, - "gopd": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.2.0.tgz", - "integrity": "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==", - "dev": true - }, - "graceful-fs": { - "version": "4.2.10", - "dev": true - }, - "grapheme-splitter": { - "version": "1.0.4", - "dev": true - }, - "has": { - "version": "1.0.3", - "dev": true, - "requires": { - "function-bind": "^1.1.1" - } - }, - "has-ansi": { - "version": "2.0.0", - "dev": true, - "requires": { - "ansi-regex": "^2.0.0" - }, - "dependencies": { - "ansi-regex": { - "version": "2.1.1", - "dev": true - } - } - }, - "has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", - "dev": true - }, - "has-property-descriptors": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz", - "integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==", - "dev": true, - "requires": { - "es-define-property": "^1.0.0" - } - }, - "has-symbols": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.1.0.tgz", - "integrity": "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==", - "dev": true - }, - "has-tostringtag": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.2.tgz", - "integrity": "sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==", - "dev": true, - "requires": { - "has-symbols": "^1.0.3" - } - }, - "hash-base": { - "version": "3.0.4", - "dev": true, - "requires": { - "inherits": "^2.0.1", - "safe-buffer": "^5.0.1" - } - }, - "hash.js": { - "version": "1.1.7", - "dev": true, - "requires": { - "inherits": "^2.0.3", - "minimalistic-assert": "^1.0.1" - } - }, - "hasha": { - "version": "5.2.2", - "dev": true, - "requires": { - "is-stream": "^2.0.0", - "type-fest": "^0.8.0" - }, - "dependencies": { - "type-fest": { - "version": "0.8.1", - "dev": true - } - } - }, - "hasown": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", - "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", - "dev": true, - "requires": { - "function-bind": "^1.1.2" - } - }, - "he": { - "version": "1.2.0", - "dev": true - }, - "hmac-drbg": { - "version": "1.0.1", - "dev": true, - "requires": { - "hash.js": "^1.0.3", - "minimalistic-assert": "^1.0.0", - "minimalistic-crypto-utils": "^1.0.1" - } - }, - "html-escaper": { - "version": "2.0.2", - "dev": true - }, - "htmlescape": { - "version": "1.1.1", - "dev": true - }, - "htmlparser2": { - "version": "3.8.3", - "dev": true, - "requires": { - "domelementtype": "1", - "domhandler": "2.3", - "domutils": "1.5", - "entities": "1.0", - "readable-stream": "1.1" - }, - "dependencies": { - "isarray": { - "version": "0.0.1", - "dev": true - }, - "readable-stream": { - "version": "1.1.14", - "dev": true, - "requires": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.1", - "isarray": "0.0.1", - "string_decoder": "~0.10.x" - } - }, - "string_decoder": { - "version": "0.10.31", - "dev": true - } - } + "get-stream": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", + "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", + "dev": true }, - "http-errors": { - "version": "2.0.0", + "glob": { + "version": "7.2.0", "dev": true, "requires": { - "depd": "2.0.0", - "inherits": "2.0.4", - "setprototypeof": "1.2.0", - "statuses": "2.0.1", - "toidentifier": "1.0.1" - }, - "dependencies": { - "statuses": { - "version": "2.0.1", - "dev": true - } + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" } }, - "http-proxy": { - "version": "1.18.1", + "globals": { + "version": "13.20.0", "dev": true, "requires": { - "eventemitter3": "^4.0.0", - "follow-redirects": "^1.0.0", - "requires-port": "^1.0.0" + "type-fest": "^0.20.2" } }, - "https-browserify": { - "version": "1.0.0", + "graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", "dev": true }, - "iconv-lite": { - "version": "0.4.24", - "dev": true, - "requires": { - "safer-buffer": ">= 2.1.2 < 3" - } + "grapheme-splitter": { + "version": "1.0.4", + "dev": true }, - "ieee754": { - "version": "1.2.1", + "has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true + }, + "html-escaper": { + "version": "2.0.2", + "dev": true + }, + "human-signals": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", + "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", "dev": true }, "ignore": { @@ -8414,14 +9786,20 @@ "resolve-from": "^4.0.0" } }, + "import-local": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/import-local/-/import-local-3.2.0.tgz", + "integrity": "sha512-2SPlun1JUPWoM6t3F0dw0FkCF/jWY8kttcY4f599GLTSjh2OCuuhdTkJQsEcZzBqbXZGKMK2OqW1oZsjtf/gQA==", + "dev": true, + "requires": { + "pkg-dir": "^4.2.0", + "resolve-cwd": "^3.0.0" + } + }, "imurmurhash": { "version": "0.1.4", "dev": true }, - "indent-string": { - "version": "4.0.0", - "dev": true - }, "inflight": { "version": "1.0.6", "dev": true, @@ -8434,52 +9812,26 @@ "version": "2.0.4", "dev": true }, - "inline-source-map": { - "version": "0.6.2", - "dev": true, - "requires": { - "source-map": "~0.5.3" - } - }, - "insert-module-globals": { - "version": "7.2.0", - "dev": true, - "requires": { - "acorn-node": "^1.5.2", - "combine-source-map": "^0.8.0", - "concat-stream": "^1.6.1", - "is-buffer": "^1.1.0", - "JSONStream": "^1.0.3", - "path-is-absolute": "^1.0.1", - "process": "~0.11.0", - "through2": "^2.0.0", - "undeclared-identifiers": "^1.1.2", - "xtend": "^4.0.0" - } - }, - "irregular-plurals": { - "version": "1.4.0", + "is-arrayish": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", + "integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==", "dev": true }, - "is-binary-path": { - "version": "2.1.0", - "dev": true, - "requires": { - "binary-extensions": "^2.0.0" - } - }, - "is-buffer": { - "version": "1.1.6", + "is-extglob": { + "version": "2.1.1", "dev": true }, - "is-callable": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", - "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==", + "is-fullwidth-code-point": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", + "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", "dev": true }, - "is-extglob": { - "version": "2.1.1", + "is-generator-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-generator-fn/-/is-generator-fn-2.1.0.tgz", + "integrity": "sha512-cTIB4yPYL/Grw0EaSzASzg6bBy9gqCofvWN8okThAYIxKJZC+udlRAmGbM0XLeniEJSs8uEgHPGuHSe1XsOLSQ==", "dev": true }, "is-glob": { @@ -8499,43 +9851,10 @@ "version": "3.0.3", "dev": true }, - "is-plain-obj": { - "version": "2.1.0", - "dev": true - }, "is-stream": { "version": "2.0.1", "dev": true }, - "is-typed-array": { - "version": "1.1.15", - "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.15.tgz", - "integrity": "sha512-p3EcsicXjit7SaskXHs1hA91QxgTw46Fv6EFKKGS5DRFLD8yKnohjF3hxoju94b/OcMZoQukzpPpBE9uLVKzgQ==", - "dev": true, - "requires": { - "which-typed-array": "^1.1.16" - } - }, - "is-typedarray": { - "version": "1.0.0", - "dev": true - }, - "is-unicode-supported": { - "version": "0.1.0", - "dev": true - }, - "is-windows": { - "version": "1.0.2", - "dev": true - }, - "isarray": { - "version": "1.0.0", - "dev": true - }, - "isbinaryfile": { - "version": "4.0.10", - "dev": true - }, "isexe": { "version": "2.0.0", "dev": true @@ -8544,41 +9863,6 @@ "version": "3.2.0", "dev": true }, - "istanbul-lib-hook": { - "version": "3.0.0", - "dev": true, - "requires": { - "append-transform": "^2.0.0" - } - }, - "istanbul-lib-instrument": { - "version": "4.0.3", - "dev": true, - "requires": { - "@babel/core": "^7.7.5", - "@istanbuljs/schema": "^0.1.2", - "istanbul-lib-coverage": "^3.0.0", - "semver": "^6.3.0" - }, - "dependencies": { - "semver": { - "version": "6.3.0", - "dev": true - } - } - }, - "istanbul-lib-processinfo": { - "version": "2.0.3", - "dev": true, - "requires": { - "archy": "^1.0.0", - "cross-spawn": "^7.0.3", - "istanbul-lib-coverage": "^3.2.0", - "p-map": "^3.0.0", - "rimraf": "^3.0.0", - "uuid": "^8.3.2" - } - }, "istanbul-lib-report": { "version": "3.0.0", "dev": true, @@ -8586,34 +9870,6 @@ "istanbul-lib-coverage": "^3.0.0", "make-dir": "^3.0.0", "supports-color": "^7.1.0" - }, - "dependencies": { - "has-flag": { - "version": "4.0.0", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } - } - }, - "istanbul-lib-source-maps": { - "version": "4.0.1", - "dev": true, - "requires": { - "debug": "^4.1.1", - "istanbul-lib-coverage": "^3.0.0", - "source-map": "^0.6.1" - }, - "dependencies": { - "source-map": { - "version": "0.6.1", - "dev": true - } } }, "istanbul-reports": { @@ -8624,1437 +9880,1747 @@ "istanbul-lib-report": "^3.0.0" } }, - "js-sdsl": { - "version": "4.3.0", - "dev": true - }, - "js-tokens": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", - "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", - "dev": true - }, - "js-yaml": { - "version": "3.14.2", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.2.tgz", - "integrity": "sha512-PMSmkqxr106Xa156c2M265Z+FTrPl+oxd/rgOQy2tijQeK5TxQ43psO1ZCwhVOSdnn+RzkzlRz/eY4BgJBYVpg==", + "jackspeak": { + "version": "3.4.3", + "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-3.4.3.tgz", + "integrity": "sha512-OGlZQpz2yfahA/Rd1Y8Cd9SIEsqvXkLVoSw/cgwhnhFMDbsQFeZYoJJ7bIZBS9BcamUW96asq/npPWugM+RQBw==", "dev": true, "requires": { - "argparse": "^1.0.7", - "esprima": "^4.0.0" + "@isaacs/cliui": "^8.0.2", + "@pkgjs/parseargs": "^0.11.0" } }, - "jsesc": { - "version": "2.5.2", - "dev": true + "jest": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest/-/jest-30.2.0.tgz", + "integrity": "sha512-F26gjC0yWN8uAA5m5Ss8ZQf5nDHWGlN/xWZIh8S5SRbsEKBovwZhxGd6LJlbZYxBgCYOtreSUyb8hpXyGC5O4A==", + "dev": true, + "requires": { + "@jest/core": "30.2.0", + "@jest/types": "30.2.0", + "import-local": "^3.2.0", + "jest-cli": "30.2.0" + } }, - "jshint": { - "version": "2.13.5", + "jest-changed-files": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-changed-files/-/jest-changed-files-30.2.0.tgz", + "integrity": "sha512-L8lR1ChrRnSdfeOvTrwZMlnWV8G/LLjQ0nG9MBclwWZidA2N5FviRki0Bvh20WRMOX31/JYvzdqTJrk5oBdydQ==", "dev": true, "requires": { - "cli": "~1.0.0", - "console-browserify": "1.1.x", - "exit": "0.1.x", - "htmlparser2": "3.8.x", - "lodash": "~4.17.21", - "minimatch": "~3.0.2", - "strip-json-comments": "1.0.x" + "execa": "^5.1.1", + "jest-util": "30.2.0", + "p-limit": "^3.1.0" }, "dependencies": { - "strip-json-comments": { - "version": "1.0.4", + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true } } }, - "jshint-stylish": { - "version": "2.2.1", - "dev": true, - "requires": { - "beeper": "^1.1.0", - "chalk": "^1.0.0", - "log-symbols": "^1.0.0", - "plur": "^2.1.0", - "string-length": "^1.0.0", - "text-table": "^0.2.0" + "jest-circus": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-circus/-/jest-circus-30.2.0.tgz", + "integrity": "sha512-Fh0096NC3ZkFx05EP2OXCxJAREVxj1BcW/i6EWqqymcgYKWjyyDpral3fMxVcHXg6oZM7iULer9wGRFvfpl+Tg==", + "dev": true, + "requires": { + "@jest/environment": "30.2.0", + "@jest/expect": "30.2.0", + "@jest/test-result": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "co": "^4.6.0", + "dedent": "^1.6.0", + "is-generator-fn": "^2.1.0", + "jest-each": "30.2.0", + "jest-matcher-utils": "30.2.0", + "jest-message-util": "30.2.0", + "jest-runtime": "30.2.0", + "jest-snapshot": "30.2.0", + "jest-util": "30.2.0", + "p-limit": "^3.1.0", + "pretty-format": "30.2.0", + "pure-rand": "^7.0.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" }, "dependencies": { - "ansi-regex": { - "version": "2.1.1", - "dev": true - }, "ansi-styles": { - "version": "2.2.1", + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true }, - "chalk": { - "version": "1.1.3", + "jest-diff": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-30.2.0.tgz", + "integrity": "sha512-dQHFo3Pt4/NLlG5z4PxZ/3yZTZ1C7s9hveiOj+GCN+uT109NC2QgsoVZsVOAvbJ3RgKkvyLGXZV9+piDpWbm6A==", "dev": true, "requires": { - "ansi-styles": "^2.2.1", - "escape-string-regexp": "^1.0.2", - "has-ansi": "^2.0.0", - "strip-ansi": "^3.0.0", - "supports-color": "^2.0.0" + "@jest/diff-sequences": "30.0.1", + "@jest/get-type": "30.1.0", + "chalk": "^4.1.2", + "pretty-format": "30.2.0" } }, - "strip-ansi": { - "version": "3.0.1", + "jest-matcher-utils": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-30.2.0.tgz", + "integrity": "sha512-dQ94Nq4dbzmUWkQ0ANAWS9tBRfqCrn0bV9AMYdOi/MHW726xn7eQmMeRTpX2ViC00bpNaWXq+7o4lIQ3AX13Hg==", "dev": true, "requires": { - "ansi-regex": "^2.0.0" + "@jest/get-type": "30.1.0", + "chalk": "^4.1.2", + "jest-diff": "30.2.0", + "pretty-format": "30.2.0" } }, - "supports-color": { - "version": "2.0.0", + "jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", + "dev": true, + "requires": { + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + } + }, + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true + }, + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "requires": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + } } } }, - "json-schema-traverse": { - "version": "0.4.1", - "dev": true - }, - "json-stable-stringify": { - "version": "0.0.1", - "dev": true, - "requires": { - "jsonify": "~0.0.0" - } - }, - "json-stable-stringify-without-jsonify": { - "version": "1.0.1", - "dev": true - }, - "json5": { - "version": "2.2.3", - "dev": true - }, - "jsonfile": { - "version": "4.0.0", - "dev": true, - "requires": { - "graceful-fs": "^4.1.6" - } - }, - "jsonify": { - "version": "0.0.0", - "dev": true - }, - "jsonparse": { - "version": "1.3.1", - "dev": true - }, - "JSONStream": { - "version": "1.3.5", + "jest-cli": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-30.2.0.tgz", + "integrity": "sha512-Os9ukIvADX/A9sLt6Zse3+nmHtHaE6hqOsjQtNiugFTbKRHYIYtZXNGNK9NChseXy7djFPjndX1tL0sCTlfpAA==", "dev": true, "requires": { - "jsonparse": "^1.2.0", - "through": ">=2.2.7 <3" + "@jest/core": "30.2.0", + "@jest/test-result": "30.2.0", + "@jest/types": "30.2.0", + "chalk": "^4.1.2", + "exit-x": "^0.2.2", + "import-local": "^3.2.0", + "jest-config": "30.2.0", + "jest-util": "30.2.0", + "jest-validate": "30.2.0", + "yargs": "^17.7.2" + }, + "dependencies": { + "cliui": { + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", + "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", + "dev": true, + "requires": { + "string-width": "^4.2.0", + "strip-ansi": "^6.0.1", + "wrap-ansi": "^7.0.0" + } + }, + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + }, + "yargs": { + "version": "17.7.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz", + "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==", + "dev": true, + "requires": { + "cliui": "^8.0.1", + "escalade": "^3.1.1", + "get-caller-file": "^2.0.5", + "require-directory": "^2.1.1", + "string-width": "^4.2.3", + "y18n": "^5.0.5", + "yargs-parser": "^21.1.1" + } + }, + "yargs-parser": { + "version": "21.1.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", + "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", + "dev": true + } } }, - "karma": { - "version": "6.4.1", - "dev": true, - "requires": { - "@colors/colors": "1.5.0", - "body-parser": "^1.19.0", - "braces": "^3.0.2", - "chokidar": "^3.5.1", - "connect": "^3.7.0", - "di": "^0.0.1", - "dom-serialize": "^2.2.1", - "glob": "^7.1.7", - "graceful-fs": "^4.2.6", - "http-proxy": "^1.18.1", - "isbinaryfile": "^4.0.8", - "lodash": "^4.17.21", - "log4js": "^6.4.1", - "mime": "^2.5.2", - "minimatch": "^3.0.4", - "mkdirp": "^0.5.5", - "qjobs": "^1.2.0", - "range-parser": "^1.2.1", - "rimraf": "^3.0.2", - "socket.io": "^4.4.1", - "source-map": "^0.6.1", - "tmp": "^0.2.1", - "ua-parser-js": "^0.7.30", - "yargs": "^16.1.1" + "jest-config": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-config/-/jest-config-30.2.0.tgz", + "integrity": "sha512-g4WkyzFQVWHtu6uqGmQR4CQxz/CH3yDSlhzXMWzNjDx843gYjReZnMRanjRCq5XZFuQrGDxgUaiYWE8BRfVckA==", + "dev": true, + "requires": { + "@babel/core": "^7.27.4", + "@jest/get-type": "30.1.0", + "@jest/pattern": "30.0.1", + "@jest/test-sequencer": "30.2.0", + "@jest/types": "30.2.0", + "babel-jest": "30.2.0", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "deepmerge": "^4.3.1", + "glob": "^10.3.10", + "graceful-fs": "^4.2.11", + "jest-circus": "30.2.0", + "jest-docblock": "30.2.0", + "jest-environment-node": "30.2.0", + "jest-regex-util": "30.0.1", + "jest-resolve": "30.2.0", + "jest-runner": "30.2.0", + "jest-util": "30.2.0", + "jest-validate": "30.2.0", + "micromatch": "^4.0.8", + "parse-json": "^5.2.0", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "strip-json-comments": "^3.1.1" }, "dependencies": { + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true + }, + "brace-expansion": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.2.tgz", + "integrity": "sha512-Jt0vHyM+jmUBqojB7E1NIYadt0vI0Qxjxd2TErW94wDz+E2LAm5vKMXXwg6ZZBTHPuUlDgQHKXvjGBdfcF1ZDQ==", + "dev": true, + "requires": { + "balanced-match": "^1.0.0" + } + }, + "foreground-child": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.3.1.tgz", + "integrity": "sha512-gIXjKqtFuWEgzFRJA9WCQeSJLZDjgJUOMCMzxtvFq/37KojM1BFGufqsCy0r4qSQmYLsZYMeyRqzIWOMup03sw==", + "dev": true, + "requires": { + "cross-spawn": "^7.0.6", + "signal-exit": "^4.0.1" + } + }, "glob": { - "version": "7.2.3", + "version": "10.5.0", + "resolved": "https://registry.npmjs.org/glob/-/glob-10.5.0.tgz", + "integrity": "sha512-DfXN8DfhJ7NH3Oe7cFmu3NCu1wKbkReJ8TorzSAFbSKrlNaQSKfIzqYqVY8zlbs2NLBbWpRiU52GX2PbaBVNkg==", + "dev": true, + "requires": { + "foreground-child": "^3.1.0", + "jackspeak": "^3.1.2", + "minimatch": "^9.0.4", + "minipass": "^7.1.2", + "package-json-from-dist": "^1.0.0", + "path-scurry": "^1.11.1" + } + }, + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "requires": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.1.1", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" } }, "minimatch": { - "version": "3.1.2", + "version": "9.0.5", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.5.tgz", + "integrity": "sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==", "dev": true, "requires": { - "brace-expansion": "^1.1.7" + "brace-expansion": "^2.0.1" } }, - "source-map": { - "version": "0.6.1", + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + }, + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "requires": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + } + }, + "signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", "dev": true } } }, - "karma-chrome-launcher": { - "version": "3.1.0", - "dev": true, - "requires": { - "which": "^1.2.1" - } - }, - "karma-mocha": { - "version": "2.0.1", - "dev": true, - "requires": { - "minimist": "^1.2.3" - } - }, - "karma-requirejs": { - "version": "1.1.0", - "dev": true, - "requires": {} - }, - "karma-safari-launcher": { - "version": "1.0.0", - "dev": true, - "requires": {} - }, - "labeled-stream-splicer": { - "version": "2.0.2", + "jest-diff": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-29.7.0.tgz", + "integrity": "sha512-LMIgiIrhigmPrs03JHpxUh2yISK3vLFPkAodPeo0+BuF7wA2FoQbkEg1u8gBYBThncu7e1oEDUfIXVuTqLRUjw==", "dev": true, "requires": { - "inherits": "^2.0.1", - "stream-splicer": "^2.0.0" + "chalk": "^4.0.0", + "diff-sequences": "^29.6.3", + "jest-get-type": "^29.6.3", + "pretty-format": "^29.7.0" } }, - "locate-path": { - "version": "6.0.0", + "jest-docblock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-docblock/-/jest-docblock-30.2.0.tgz", + "integrity": "sha512-tR/FFgZKS1CXluOQzZvNH3+0z9jXr3ldGSD8bhyuxvlVUwbeLOGynkunvlTMxchC5urrKndYiwCFC0DLVjpOCA==", "dev": true, "requires": { - "p-locate": "^5.0.0" + "detect-newline": "^3.1.0" } }, - "lodash": { - "version": "4.17.21", - "dev": true - }, - "lodash.flattendeep": { - "version": "4.4.0", - "dev": true - }, - "lodash.memoize": { - "version": "3.0.4", - "dev": true - }, - "lodash.merge": { - "version": "4.6.2", - "dev": true - }, - "log-symbols": { - "version": "1.0.2", + "jest-each": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-each/-/jest-each-30.2.0.tgz", + "integrity": "sha512-lpWlJlM7bCUf1mfmuqTA8+j2lNURW9eNafOy99knBM01i5CQeY5UH1vZjgT9071nDJac1M4XsbyI44oNOdhlDQ==", "dev": true, "requires": { - "chalk": "^1.0.0" + "@jest/get-type": "30.1.0", + "@jest/types": "30.2.0", + "chalk": "^4.1.2", + "jest-util": "30.2.0", + "pretty-format": "30.2.0" }, "dependencies": { - "ansi-regex": { - "version": "2.1.1", - "dev": true - }, "ansi-styles": { - "version": "2.2.1", + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true }, - "chalk": { - "version": "1.1.3", + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "requires": { - "ansi-styles": "^2.2.1", - "escape-string-regexp": "^1.0.2", - "has-ansi": "^2.0.0", - "strip-ansi": "^3.0.0", - "supports-color": "^2.0.0" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" } }, - "strip-ansi": { - "version": "3.0.1", + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + }, + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, "requires": { - "ansi-regex": "^2.0.0" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" } - }, - "supports-color": { - "version": "2.0.0", - "dev": true } } }, - "log4js": { - "version": "6.8.0", + "jest-environment-node": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-environment-node/-/jest-environment-node-30.2.0.tgz", + "integrity": "sha512-ElU8v92QJ9UrYsKrxDIKCxu6PfNj4Hdcktcn0JX12zqNdqWHB0N+hwOnnBBXvjLd2vApZtuLUGs1QSY+MsXoNA==", "dev": true, "requires": { - "date-format": "^4.0.14", - "debug": "^4.3.4", - "flatted": "^3.2.7", - "rfdc": "^1.3.0", - "streamroller": "^3.1.5" + "@jest/environment": "30.2.0", + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0", + "jest-util": "30.2.0", + "jest-validate": "30.2.0" + }, + "dependencies": { + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + } } }, - "loupe": { - "version": "2.3.6", - "dev": true, - "requires": { - "get-func-name": "^2.0.0" - } + "jest-get-type": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/jest-get-type/-/jest-get-type-29.6.3.tgz", + "integrity": "sha512-zrteXnqYxfQh7l5FHyL38jL39di8H8rHoecLH3JNxH3BwOrBsNeabdap5e0I23lD4HHI8W5VFBZqG4Eaq5LNcw==", + "dev": true }, - "lru-cache": { - "version": "5.1.1", + "jest-haste-map": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-haste-map/-/jest-haste-map-30.2.0.tgz", + "integrity": "sha512-sQA/jCb9kNt+neM0anSj6eZhLZUIhQgwDt7cPGjumgLM4rXsfb9kpnlacmvZz3Q5tb80nS+oG/if+NBKrHC+Xw==", "dev": true, "requires": { - "yallist": "^3.0.2" + "@jest/types": "30.2.0", + "@types/node": "*", + "anymatch": "^3.1.3", + "fb-watchman": "^2.0.2", + "fsevents": "^2.3.3", + "graceful-fs": "^4.2.11", + "jest-regex-util": "30.0.1", + "jest-util": "30.2.0", + "jest-worker": "30.2.0", + "micromatch": "^4.0.8", + "walker": "^1.0.8" + }, + "dependencies": { + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + } } }, - "make-dir": { - "version": "3.1.0", + "jest-leak-detector": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-leak-detector/-/jest-leak-detector-30.2.0.tgz", + "integrity": "sha512-M6jKAjyzjHG0SrQgwhgZGy9hFazcudwCNovY/9HPIicmNSBuockPSedAP9vlPK6ONFJ1zfyH/M2/YYJxOz5cdQ==", "dev": true, "requires": { - "semver": "^6.0.0" + "@jest/get-type": "30.1.0", + "pretty-format": "30.2.0" }, "dependencies": { - "semver": { - "version": "6.3.0", + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true + }, + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "requires": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + } } } }, - "math-intrinsics": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/math-intrinsics/-/math-intrinsics-1.1.0.tgz", - "integrity": "sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==", - "dev": true - }, - "md5.js": { - "version": "1.3.5", + "jest-matcher-utils": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-29.7.0.tgz", + "integrity": "sha512-sBkD+Xi9DtcChsI3L3u0+N0opgPYnCRPtGcQYrgXmR+hmt/fYfWAL0xRXYU8eWOdfuLgBe0YCW3AFtnRLagq/g==", "dev": true, "requires": { - "hash-base": "^3.0.0", - "inherits": "^2.0.1", - "safe-buffer": "^5.1.2" + "chalk": "^4.0.0", + "jest-diff": "^29.7.0", + "jest-get-type": "^29.6.3", + "pretty-format": "^29.7.0" } }, - "media-typer": { - "version": "0.3.0", - "dev": true - }, - "miller-rabin": { - "version": "4.0.1", + "jest-message-util": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-29.7.0.tgz", + "integrity": "sha512-GBEV4GRADeP+qtB2+6u61stea8mGcOT4mCtrYISZwfu9/ISHFJ/5zOMXYbpBE9RsS5+Gb63DW4FgmnKJ79Kf6w==", "dev": true, "requires": { - "bn.js": "^4.0.0", - "brorand": "^1.0.1" + "@babel/code-frame": "^7.12.13", + "@jest/types": "^29.6.3", + "@types/stack-utils": "^2.0.0", + "chalk": "^4.0.0", + "graceful-fs": "^4.2.9", + "micromatch": "^4.0.4", + "pretty-format": "^29.7.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.3" + }, + "dependencies": { + "@jest/schemas": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.3.tgz", + "integrity": "sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==", + "dev": true, + "requires": { + "@sinclair/typebox": "^0.27.8" + } + }, + "@jest/types": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.6.3.tgz", + "integrity": "sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw==", + "dev": true, + "requires": { + "@jest/schemas": "^29.6.3", + "@types/istanbul-lib-coverage": "^2.0.0", + "@types/istanbul-reports": "^3.0.0", + "@types/node": "*", + "@types/yargs": "^17.0.8", + "chalk": "^4.0.0" + } + }, + "@sinclair/typebox": { + "version": "0.27.8", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.8.tgz", + "integrity": "sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==", + "dev": true + } } }, - "mime": { - "version": "2.6.0", - "dev": true - }, - "mime-db": { - "version": "1.52.0", - "dev": true - }, - "mime-types": { - "version": "2.1.35", + "jest-mock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-30.2.0.tgz", + "integrity": "sha512-JNNNl2rj4b5ICpmAcq+WbLH83XswjPbjH4T7yvGzfAGCPh1rw+xVNbtk+FnRslvt9lkCcdn9i1oAoKUuFsOxRw==", "dev": true, "requires": { - "mime-db": "1.52.0" + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-util": "30.2.0" + }, + "dependencies": { + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + } } }, - "minimalistic-assert": { - "version": "1.0.1", - "dev": true + "jest-pnp-resolver": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/jest-pnp-resolver/-/jest-pnp-resolver-1.2.3.tgz", + "integrity": "sha512-+3NpwQEnRoIBtx4fyhblQDPgJI0H1IEIkX7ShLUjPGA7TtUTvI1oiKi3SR4oBR0hQhQR80l4WAe5RrXBwWMA8w==", + "dev": true, + "requires": {} }, - "minimalistic-crypto-utils": { - "version": "1.0.1", + "jest-regex-util": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/jest-regex-util/-/jest-regex-util-30.0.1.tgz", + "integrity": "sha512-jHEQgBXAgc+Gh4g0p3bCevgRCVRkB4VB70zhoAE48gxeSr1hfUOsM/C2WoJgVL7Eyg//hudYENbm3Ne+/dRVVA==", "dev": true }, - "minimatch": { - "version": "3.0.8", + "jest-resolve": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-resolve/-/jest-resolve-30.2.0.tgz", + "integrity": "sha512-TCrHSxPlx3tBY3hWNtRQKbtgLhsXa1WmbJEqBlTBrGafd5fiQFByy2GNCEoGR+Tns8d15GaL9cxEzKOO3GEb2A==", "dev": true, "requires": { - "brace-expansion": "^1.1.7" + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "jest-haste-map": "30.2.0", + "jest-pnp-resolver": "^1.2.3", + "jest-util": "30.2.0", + "jest-validate": "30.2.0", + "slash": "^3.0.0", + "unrs-resolver": "^1.7.11" + }, + "dependencies": { + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + } } }, - "minimist": { - "version": "1.2.8", - "dev": true - }, - "mkdirp": { - "version": "0.5.6", + "jest-resolve-dependencies": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-resolve-dependencies/-/jest-resolve-dependencies-30.2.0.tgz", + "integrity": "sha512-xTOIGug/0RmIe3mmCqCT95yO0vj6JURrn1TKWlNbhiAefJRWINNPgwVkrVgt/YaerPzY3iItufd80v3lOrFJ2w==", "dev": true, "requires": { - "minimist": "^1.2.6" + "jest-regex-util": "30.0.1", + "jest-snapshot": "30.2.0" } }, - "mkdirp-classic": { - "version": "0.5.3", - "dev": true - }, - "mocha": { - "version": "10.8.2", - "resolved": "https://registry.npmjs.org/mocha/-/mocha-10.8.2.tgz", - "integrity": "sha512-VZlYo/WE8t1tstuRmqgeyBgCbJc/lEdopaa+axcKzTBJ+UIdlAB9XnmvTCAH4pwR4ElNInaedhEBmZD8iCSVEg==", + "jest-runner": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-runner/-/jest-runner-30.2.0.tgz", + "integrity": "sha512-PqvZ2B2XEyPEbclp+gV6KO/F1FIFSbIwewRgmROCMBo/aZ6J1w8Qypoj2pEOcg3G2HzLlaP6VUtvwCI8dM3oqQ==", "dev": true, "requires": { - "ansi-colors": "^4.1.3", - "browser-stdout": "^1.3.1", - "chokidar": "^3.5.3", - "debug": "^4.3.5", - "diff": "^5.2.0", - "escape-string-regexp": "^4.0.0", - "find-up": "^5.0.0", - "glob": "^8.1.0", - "he": "^1.2.0", - "js-yaml": "^4.1.0", - "log-symbols": "^4.1.0", - "minimatch": "^5.1.6", - "ms": "^2.1.3", - "serialize-javascript": "^6.0.2", - "strip-json-comments": "^3.1.1", - "supports-color": "^8.1.1", - "workerpool": "^6.5.1", - "yargs": "^16.2.0", - "yargs-parser": "^20.2.9", - "yargs-unparser": "^2.0.0" + "@jest/console": "30.2.0", + "@jest/environment": "30.2.0", + "@jest/test-result": "30.2.0", + "@jest/transform": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "emittery": "^0.13.1", + "exit-x": "^0.2.2", + "graceful-fs": "^4.2.11", + "jest-docblock": "30.2.0", + "jest-environment-node": "30.2.0", + "jest-haste-map": "30.2.0", + "jest-leak-detector": "30.2.0", + "jest-message-util": "30.2.0", + "jest-resolve": "30.2.0", + "jest-runtime": "30.2.0", + "jest-util": "30.2.0", + "jest-watcher": "30.2.0", + "jest-worker": "30.2.0", + "p-limit": "^3.1.0", + "source-map-support": "0.5.13" }, "dependencies": { "ansi-styles": { - "version": "4.3.0", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "argparse": { - "version": "2.0.1", - "dev": true - }, - "brace-expansion": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz", - "integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==", - "dev": true, - "requires": { - "balanced-match": "^1.0.0" - } - }, - "chalk": { - "version": "4.1.2", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "dependencies": { - "supports-color": { - "version": "7.2.0", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } - } - }, - "color-convert": { - "version": "2.0.1", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "dev": true - }, - "debug": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.0.tgz", - "integrity": "sha512-6WTZ/IxCY/T6BALoZHaE4ctp9xm+Z5kY/pzYaCHRFeyVhojxlrm+46y68HA6hr0TcwEssoxNiDEUJQjfPZ/RYA==", - "dev": true, - "requires": { - "ms": "^2.1.3" - } - }, - "escape-string-regexp": { - "version": "4.0.0", - "dev": true - }, - "glob": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/glob/-/glob-8.1.0.tgz", - "integrity": "sha512-r8hpEjiQEYlF2QU0df3dS+nxxSIreXQS1qRhMJM0Q5NDdR386C7jb7Hwwod8Fgiuex+k0GFjgft18yvxm5XoCQ==", - "dev": true, - "requires": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^5.0.1", - "once": "^1.3.0" - } - }, - "has-flag": { - "version": "4.0.0", + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true }, - "js-yaml": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.1.tgz", - "integrity": "sha512-qQKT4zQxXl8lLwBtHMWwaTcGfFOZviOJet3Oy/xmGk2gZH677CJM9EvtfdSkgWcATZhj/55JZ0rmy3myCT5lsA==", - "dev": true, - "requires": { - "argparse": "^2.0.1" - } - }, - "log-symbols": { - "version": "4.1.0", + "jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, "requires": { - "chalk": "^4.1.0", - "is-unicode-supported": "^0.1.0" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" } }, - "minimatch": { - "version": "5.1.6", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-5.1.6.tgz", - "integrity": "sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g==", + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "requires": { - "brace-expansion": "^2.0.1" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" } }, - "ms": { - "version": "2.1.3", + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true }, - "supports-color": { - "version": "8.1.1", + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, "requires": { - "has-flag": "^4.0.0" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" } } } }, - "module-deps": { - "version": "6.2.1", - "dev": true, - "requires": { - "browser-resolve": "^1.7.0", - "cached-path-relative": "^1.0.2", - "concat-stream": "~1.6.0", - "defined": "^1.0.0", - "detective": "^5.0.2", - "duplexer2": "^0.1.2", - "inherits": "^2.0.1", - "JSONStream": "^1.0.3", - "parents": "^1.0.0", - "readable-stream": "^2.0.2", - "resolve": "^1.4.0", - "stream-combiner2": "^1.1.1", - "subarg": "^1.0.0", - "through2": "^2.0.0", - "xtend": "^4.0.0" - } - }, - "ms": { - "version": "2.1.2", - "dev": true - }, - "natural-compare": { - "version": "1.4.0", - "dev": true - }, - "negotiator": { - "version": "0.6.3", - "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.3.tgz", - "integrity": "sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg==", - "dev": true - }, - "node-preload": { - "version": "0.2.1", - "dev": true, - "requires": { - "process-on-spawn": "^1.0.0" - } - }, - "node-releases": { - "version": "2.0.10", - "dev": true - }, - "normalize-path": { - "version": "3.0.0", - "dev": true - }, - "nyc": { - "version": "15.1.0", - "dev": true, - "requires": { - "@istanbuljs/load-nyc-config": "^1.0.0", - "@istanbuljs/schema": "^0.1.2", - "caching-transform": "^4.0.0", - "convert-source-map": "^1.7.0", - "decamelize": "^1.2.0", - "find-cache-dir": "^3.2.0", - "find-up": "^4.1.0", - "foreground-child": "^2.0.0", - "get-package-type": "^0.1.0", - "glob": "^7.1.6", - "istanbul-lib-coverage": "^3.0.0", - "istanbul-lib-hook": "^3.0.0", - "istanbul-lib-instrument": "^4.0.0", - "istanbul-lib-processinfo": "^2.0.2", - "istanbul-lib-report": "^3.0.0", - "istanbul-lib-source-maps": "^4.0.0", - "istanbul-reports": "^3.0.2", - "make-dir": "^3.0.0", - "node-preload": "^0.2.1", - "p-map": "^3.0.0", - "process-on-spawn": "^1.0.0", - "resolve-from": "^5.0.0", - "rimraf": "^3.0.0", - "signal-exit": "^3.0.2", - "spawn-wrap": "^2.0.0", - "test-exclude": "^6.0.0", - "yargs": "^15.0.2" + "jest-runtime": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-runtime/-/jest-runtime-30.2.0.tgz", + "integrity": "sha512-p1+GVX/PJqTucvsmERPMgCPvQJpFt4hFbM+VN3n8TMo47decMUcJbt+rgzwrEme0MQUA/R+1de2axftTHkKckg==", + "dev": true, + "requires": { + "@jest/environment": "30.2.0", + "@jest/fake-timers": "30.2.0", + "@jest/globals": "30.2.0", + "@jest/source-map": "30.0.1", + "@jest/test-result": "30.2.0", + "@jest/transform": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "cjs-module-lexer": "^2.1.0", + "collect-v8-coverage": "^1.0.2", + "glob": "^10.3.10", + "graceful-fs": "^4.2.11", + "jest-haste-map": "30.2.0", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-regex-util": "30.0.1", + "jest-resolve": "30.2.0", + "jest-snapshot": "30.2.0", + "jest-util": "30.2.0", + "slash": "^3.0.0", + "strip-bom": "^4.0.0" }, "dependencies": { "ansi-styles": { - "version": "4.3.0", + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true + }, + "brace-expansion": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.2.tgz", + "integrity": "sha512-Jt0vHyM+jmUBqojB7E1NIYadt0vI0Qxjxd2TErW94wDz+E2LAm5vKMXXwg6ZZBTHPuUlDgQHKXvjGBdfcF1ZDQ==", + "dev": true, + "requires": { + "balanced-match": "^1.0.0" + } + }, + "foreground-child": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.3.1.tgz", + "integrity": "sha512-gIXjKqtFuWEgzFRJA9WCQeSJLZDjgJUOMCMzxtvFq/37KojM1BFGufqsCy0r4qSQmYLsZYMeyRqzIWOMup03sw==", "dev": true, "requires": { - "color-convert": "^2.0.1" + "cross-spawn": "^7.0.6", + "signal-exit": "^4.0.1" } }, - "camelcase": { - "version": "5.3.1", - "dev": true + "glob": { + "version": "10.5.0", + "resolved": "https://registry.npmjs.org/glob/-/glob-10.5.0.tgz", + "integrity": "sha512-DfXN8DfhJ7NH3Oe7cFmu3NCu1wKbkReJ8TorzSAFbSKrlNaQSKfIzqYqVY8zlbs2NLBbWpRiU52GX2PbaBVNkg==", + "dev": true, + "requires": { + "foreground-child": "^3.1.0", + "jackspeak": "^3.1.2", + "minimatch": "^9.0.4", + "minipass": "^7.1.2", + "package-json-from-dist": "^1.0.0", + "path-scurry": "^1.11.1" + } }, - "cliui": { - "version": "6.0.0", + "jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, "requires": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.0", - "wrap-ansi": "^6.2.0" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" } }, - "color-convert": { - "version": "2.0.1", + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "requires": { - "color-name": "~1.1.4" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" } }, - "color-name": { - "version": "1.1.4", - "dev": true + "minimatch": { + "version": "9.0.5", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.5.tgz", + "integrity": "sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==", + "dev": true, + "requires": { + "brace-expansion": "^2.0.1" + } }, - "convert-source-map": { - "version": "1.9.0", + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true }, - "decamelize": { - "version": "1.2.0", - "dev": true + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "requires": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + } }, - "find-up": { + "signal-exit": { "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", + "dev": true + } + } + }, + "jest-snapshot": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-snapshot/-/jest-snapshot-30.2.0.tgz", + "integrity": "sha512-5WEtTy2jXPFypadKNpbNkZ72puZCa6UjSr/7djeecHWOu7iYhSXSnHScT8wBz3Rn8Ena5d5RYRcsyKIeqG1IyA==", + "dev": true, + "requires": { + "@babel/core": "^7.27.4", + "@babel/generator": "^7.27.5", + "@babel/plugin-syntax-jsx": "^7.27.1", + "@babel/plugin-syntax-typescript": "^7.27.1", + "@babel/types": "^7.27.3", + "@jest/expect-utils": "30.2.0", + "@jest/get-type": "30.1.0", + "@jest/snapshot-utils": "30.2.0", + "@jest/transform": "30.2.0", + "@jest/types": "30.2.0", + "babel-preset-current-node-syntax": "^1.2.0", + "chalk": "^4.1.2", + "expect": "30.2.0", + "graceful-fs": "^4.2.11", + "jest-diff": "30.2.0", + "jest-matcher-utils": "30.2.0", + "jest-message-util": "30.2.0", + "jest-util": "30.2.0", + "pretty-format": "30.2.0", + "semver": "^7.7.2", + "synckit": "^0.11.8" + }, + "dependencies": { + "@jest/expect-utils": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-30.2.0.tgz", + "integrity": "sha512-1JnRfhqpD8HGpOmQp180Fo9Zt69zNtC+9lR+kT7NVL05tNXIi+QC8Csz7lfidMoVLPD3FnOtcmp0CEFnxExGEA==", "dev": true, "requires": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" + "@jest/get-type": "30.1.0" } }, - "locate-path": { - "version": "5.0.0", + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true + }, + "expect": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/expect/-/expect-30.2.0.tgz", + "integrity": "sha512-u/feCi0GPsI+988gU2FLcsHyAHTU0MX1Wg68NhAnN7z/+C5wqG+CY8J53N9ioe8RXgaoz0nBR/TYMf3AycUuPw==", "dev": true, "requires": { - "p-locate": "^4.1.0" + "@jest/expect-utils": "30.2.0", + "@jest/get-type": "30.1.0", + "jest-matcher-utils": "30.2.0", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" } }, - "p-limit": { - "version": "2.3.0", + "jest-diff": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-30.2.0.tgz", + "integrity": "sha512-dQHFo3Pt4/NLlG5z4PxZ/3yZTZ1C7s9hveiOj+GCN+uT109NC2QgsoVZsVOAvbJ3RgKkvyLGXZV9+piDpWbm6A==", "dev": true, "requires": { - "p-try": "^2.0.0" + "@jest/diff-sequences": "30.0.1", + "@jest/get-type": "30.1.0", + "chalk": "^4.1.2", + "pretty-format": "30.2.0" } }, - "p-locate": { - "version": "4.1.0", + "jest-matcher-utils": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-30.2.0.tgz", + "integrity": "sha512-dQ94Nq4dbzmUWkQ0ANAWS9tBRfqCrn0bV9AMYdOi/MHW726xn7eQmMeRTpX2ViC00bpNaWXq+7o4lIQ3AX13Hg==", "dev": true, "requires": { - "p-limit": "^2.2.0" + "@jest/get-type": "30.1.0", + "chalk": "^4.1.2", + "jest-diff": "30.2.0", + "pretty-format": "30.2.0" } }, - "resolve-from": { - "version": "5.0.0", - "dev": true + "jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", + "dev": true, + "requires": { + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + } }, - "wrap-ansi": { - "version": "6.2.0", + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "requires": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" } }, - "y18n": { + "picomatch": { "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true }, - "yargs": { - "version": "15.4.1", + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, "requires": { - "cliui": "^6.0.0", - "decamelize": "^1.2.0", - "find-up": "^4.1.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^4.2.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^18.1.2" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" } }, - "yargs-parser": { - "version": "18.1.3", - "dev": true, - "requires": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" - } + "semver": { + "version": "7.7.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.3.tgz", + "integrity": "sha512-SdsKMrI9TdgjdweUSR9MweHA4EJ8YxHn8DFaDisvhVlUOe4BF1tLD7GAj0lIqWVl+dPb/rExr0Btby5loQm20Q==", + "dev": true } } }, - "object-assign": { - "version": "4.1.1", - "dev": true - }, - "object-inspect": { - "version": "1.13.2", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.2.tgz", - "integrity": "sha512-IRZSRuzJiynemAXPYtPe5BoI/RESNYR7TYm50MC5Mqbd3Jmw5y790sErYw3V6SryFJD64b74qQQs9wn5Bg/k3g==", - "dev": true - }, - "on-finished": { - "version": "2.3.0", - "dev": true, - "requires": { - "ee-first": "1.1.1" - } - }, - "once": { - "version": "1.4.0", - "dev": true, - "requires": { - "wrappy": "1" - } - }, - "os-browserify": { - "version": "0.3.0", - "dev": true - }, - "p-limit": { - "version": "3.1.0", - "dev": true, - "requires": { - "yocto-queue": "^0.1.0" - } - }, - "p-locate": { - "version": "5.0.0", - "dev": true, - "requires": { - "p-limit": "^3.0.2" - } - }, - "p-map": { - "version": "3.0.0", - "dev": true, - "requires": { - "aggregate-error": "^3.0.0" - } - }, - "p-try": { - "version": "2.2.0", - "dev": true - }, - "package-hash": { - "version": "4.0.0", - "dev": true, - "requires": { - "graceful-fs": "^4.1.15", - "hasha": "^5.0.0", - "lodash.flattendeep": "^4.4.0", - "release-zalgo": "^1.0.0" - } - }, - "pako": { - "version": "1.0.10", - "dev": true - }, - "parent-module": { - "version": "1.0.1", - "dev": true, - "requires": { - "callsites": "^3.0.0" - } - }, - "parents": { - "version": "1.0.1", - "dev": true, - "requires": { - "path-platform": "~0.11.15" - } - }, - "parse-asn1": { - "version": "5.1.6", - "resolved": "https://registry.npmjs.org/parse-asn1/-/parse-asn1-5.1.6.tgz", - "integrity": "sha512-RnZRo1EPU6JBnra2vGHj0yhp6ebyjBZpmUCLHWiFhxlzvBCCpAuZ7elsBp1PVAbQN0/04VD/19rfzlBSwLstMw==", - "dev": true, - "requires": { - "asn1.js": "^5.2.0", - "browserify-aes": "^1.0.0", - "evp_bytestokey": "^1.0.0", - "pbkdf2": "^3.0.3", - "safe-buffer": "^5.1.1" - } - }, - "parseurl": { - "version": "1.3.3", - "dev": true - }, - "path-browserify": { - "version": "0.0.1", - "dev": true - }, - "path-exists": { - "version": "4.0.0", - "dev": true - }, - "path-is-absolute": { - "version": "1.0.1", - "dev": true - }, - "path-key": { - "version": "3.1.1", - "dev": true - }, - "path-parse": { - "version": "1.0.7", - "dev": true - }, - "path-platform": { - "version": "0.11.15", - "dev": true - }, - "pathval": { - "version": "1.1.1", - "dev": true - }, - "pbkdf2": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/pbkdf2/-/pbkdf2-3.1.3.tgz", - "integrity": "sha512-wfRLBZ0feWRhCIkoMB6ete7czJcnNnqRpcoWQBLqatqXXmelSRqfdDK4F3u9T2s2cXas/hQJcryI/4lAL+XTlA==", + "jest-util": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-29.7.0.tgz", + "integrity": "sha512-z6EbKajIpqGKU56y5KBUgy1dt1ihhQJgWzUlZHArA/+X2ad7Cb5iF+AK1EWVL/Bo7Rz9uurpqw6SiBCefUbCGA==", "dev": true, "requires": { - "create-hash": "~1.1.3", - "create-hmac": "^1.1.7", - "ripemd160": "=2.0.1", - "safe-buffer": "^5.2.1", - "sha.js": "^2.4.11", - "to-buffer": "^1.2.0" + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "ci-info": "^3.2.0", + "graceful-fs": "^4.2.9", + "picomatch": "^2.2.3" }, "dependencies": { - "create-hash": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/create-hash/-/create-hash-1.1.3.tgz", - "integrity": "sha512-snRpch/kwQhcdlnZKYanNF1m0RDlrCdSKQaH87w1FCFPVPNCQ/Il9QJKAX2jVBZddRdaHBMC+zXa9Gw9tmkNUA==", + "@jest/schemas": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.3.tgz", + "integrity": "sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==", "dev": true, "requires": { - "cipher-base": "^1.0.1", - "inherits": "^2.0.1", - "ripemd160": "^2.0.0", - "sha.js": "^2.4.0" + "@sinclair/typebox": "^0.27.8" } }, - "hash-base": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/hash-base/-/hash-base-2.0.2.tgz", - "integrity": "sha512-0TROgQ1/SxE6KmxWSvXHvRj90/Xo1JvZShofnYF+f6ZsGtR4eES7WfrQzPalmyagfKZCXpVnitiRebZulWsbiw==", + "@jest/types": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.6.3.tgz", + "integrity": "sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw==", "dev": true, "requires": { - "inherits": "^2.0.1" + "@jest/schemas": "^29.6.3", + "@types/istanbul-lib-coverage": "^2.0.0", + "@types/istanbul-reports": "^3.0.0", + "@types/node": "*", + "@types/yargs": "^17.0.8", + "chalk": "^4.0.0" } }, - "ripemd160": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/ripemd160/-/ripemd160-2.0.1.tgz", - "integrity": "sha512-J7f4wutN8mdbV08MJnXibYpCOPHR+yzy+iQ/AsjMv2j8cLavQ8VGagDFUwwTAdF8FmRKVeNpbTTEwNHCW1g94w==", + "@sinclair/typebox": { + "version": "0.27.8", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.8.tgz", + "integrity": "sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==", + "dev": true + }, + "ci-info": { + "version": "3.9.0", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz", + "integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==", + "dev": true + } + } + }, + "jest-validate": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-30.2.0.tgz", + "integrity": "sha512-FBGWi7dP2hpdi8nBoWxSsLvBFewKAg0+uSQwBaof4Y4DPgBabXgpSYC5/lR7VmnIlSpASmCi/ntRWPbv7089Pw==", + "dev": true, + "requires": { + "@jest/get-type": "30.1.0", + "@jest/types": "30.2.0", + "camelcase": "^6.3.0", + "chalk": "^4.1.2", + "leven": "^3.1.0", + "pretty-format": "30.2.0" + }, + "dependencies": { + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true + }, + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, "requires": { - "hash-base": "^2.0.0", - "inherits": "^2.0.1" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" } } } }, - "picocolors": { - "version": "1.0.0", - "dev": true - }, - "picomatch": { - "version": "2.3.1", - "dev": true - }, - "pkg-dir": { - "version": "4.2.0", + "jest-watcher": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-30.2.0.tgz", + "integrity": "sha512-PYxa28dxJ9g777pGm/7PrbnMeA0Jr7osHP9bS7eJy9DuAjMgdGtxgf0uKMyoIsTWAkIbUW5hSDdJ3urmgXBqxg==", "dev": true, "requires": { - "find-up": "^4.0.0" + "@jest/test-result": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "ansi-escapes": "^4.3.2", + "chalk": "^4.1.2", + "emittery": "^0.13.1", + "jest-util": "30.2.0", + "string-length": "^4.0.2" }, "dependencies": { - "find-up": { - "version": "4.1.0", + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "requires": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" } }, - "locate-path": { - "version": "5.0.0", + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + }, + "string-length": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/string-length/-/string-length-4.0.2.tgz", + "integrity": "sha512-+l6rNN5fYHNhZZy41RXsYptCjA2Igmq4EG7kZAYFQI1E1VTXarr6ZPXBg6eq7Y6eK4FEhY6AJlyuFIb/v/S0VQ==", "dev": true, "requires": { - "p-locate": "^4.1.0" + "char-regex": "^1.0.2", + "strip-ansi": "^6.0.0" } - }, - "p-limit": { - "version": "2.3.0", + } + } + }, + "jest-worker": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-30.2.0.tgz", + "integrity": "sha512-0Q4Uk8WF7BUwqXHuAjc23vmopWJw5WH7w2tqBoUOZpOjW/ZnR44GXXd1r82RvnmI2GZge3ivrYXk/BE2+VtW2g==", + "dev": true, + "requires": { + "@types/node": "*", + "@ungap/structured-clone": "^1.3.0", + "jest-util": "30.2.0", + "merge-stream": "^2.0.0", + "supports-color": "^8.1.1" + }, + "dependencies": { + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "requires": { - "p-try": "^2.0.0" + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" } }, - "p-locate": { - "version": "4.1.0", + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + }, + "supports-color": { + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", + "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", "dev": true, "requires": { - "p-limit": "^2.2.0" + "has-flag": "^4.0.0" } } } }, - "platform": { - "version": "1.3.5", - "dev": true - }, - "plur": { - "version": "2.1.2", - "dev": true, - "requires": { - "irregular-plurals": "^1.0.0" - } - }, - "possible-typed-array-names": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/possible-typed-array-names/-/possible-typed-array-names-1.1.0.tgz", - "integrity": "sha512-/+5VFTchJDoVj3bhoqi6UeymcD00DAwb1nJwamzPvHEszJ4FpF6SNNbUbOS8yI56qHzdV8eK0qEfOSiodkTdxg==", - "dev": true - }, - "process": { - "version": "0.11.10", + "js-sdsl": { + "version": "4.3.0", "dev": true }, - "process-nextick-args": { - "version": "2.0.1", + "js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", "dev": true }, - "process-on-spawn": { - "version": "1.0.0", - "dev": true, - "requires": { - "fromentries": "^1.2.0" - } - }, - "public-encrypt": { - "version": "4.0.3", + "js-yaml": { + "version": "3.14.2", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.2.tgz", + "integrity": "sha512-PMSmkqxr106Xa156c2M265Z+FTrPl+oxd/rgOQy2tijQeK5TxQ43psO1ZCwhVOSdnn+RzkzlRz/eY4BgJBYVpg==", "dev": true, "requires": { - "bn.js": "^4.1.0", - "browserify-rsa": "^4.0.0", - "create-hash": "^1.1.0", - "parse-asn1": "^5.0.0", - "randombytes": "^2.0.1", - "safe-buffer": "^5.1.2" + "argparse": "^1.0.7", + "esprima": "^4.0.0" } }, - "punycode": { - "version": "1.4.1", + "jsesc": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-3.1.0.tgz", + "integrity": "sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA==", "dev": true }, - "qjobs": { - "version": "1.2.0", + "json-parse-even-better-errors": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", + "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", "dev": true }, - "qs": { - "version": "6.13.0", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.0.tgz", - "integrity": "sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==", - "dev": true, - "requires": { - "side-channel": "^1.0.6" - } + "json-schema-traverse": { + "version": "0.4.1", + "dev": true }, - "querystring": { - "version": "0.2.0", + "json-stable-stringify-without-jsonify": { + "version": "1.0.1", "dev": true }, - "querystring-es3": { - "version": "0.2.1", + "json5": { + "version": "2.2.3", "dev": true }, - "queue-microtask": { - "version": "1.2.3", + "leven": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/leven/-/leven-3.1.0.tgz", + "integrity": "sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==", "dev": true }, - "randombytes": { - "version": "2.1.0", - "dev": true, - "requires": { - "safe-buffer": "^5.1.0" - } + "lines-and-columns": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz", + "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==", + "dev": true }, - "randomfill": { - "version": "1.0.4", + "locate-path": { + "version": "6.0.0", "dev": true, "requires": { - "randombytes": "^2.0.5", - "safe-buffer": "^5.1.0" + "p-locate": "^5.0.0" } }, - "range-parser": { - "version": "1.2.1", + "lodash": { + "version": "4.17.21", "dev": true }, - "raw-body": { - "version": "2.5.2", - "dev": true, - "requires": { - "bytes": "3.1.2", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "unpipe": "1.0.0" - } + "lodash.merge": { + "version": "4.6.2", + "dev": true }, - "read-only-stream": { - "version": "2.0.0", + "lru-cache": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz", + "integrity": "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==", "dev": true, "requires": { - "readable-stream": "^2.0.2" + "yallist": "^3.0.2" } }, - "readable-stream": { - "version": "2.3.6", + "make-dir": { + "version": "3.1.0", "dev": true, "requires": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.1.1", - "util-deprecate": "~1.0.1" + "semver": "^6.0.0" }, "dependencies": { - "safe-buffer": { - "version": "5.1.2", + "semver": { + "version": "6.3.0", "dev": true - }, - "string_decoder": { - "version": "1.1.1", - "dev": true, - "requires": { - "safe-buffer": "~5.1.0" - } } } }, - "readdirp": { - "version": "3.6.0", + "makeerror": { + "version": "1.0.12", + "resolved": "https://registry.npmjs.org/makeerror/-/makeerror-1.0.12.tgz", + "integrity": "sha512-JmqCvUhmt43madlpFzG4BQzG2Z3m6tvQDNKdClZnO3VbIudJYmxsT0FNJMeiB2+JTSlTQTSbU8QdesVmwJcmLg==", "dev": true, "requires": { - "picomatch": "^2.2.1" + "tmpl": "1.0.5" } }, - "regexpp": { - "version": "3.2.0", + "merge-stream": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", + "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", "dev": true }, - "release-zalgo": { - "version": "1.0.0", + "micromatch": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz", + "integrity": "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==", "dev": true, "requires": { - "es6-error": "^4.0.1" + "braces": "^3.0.3", + "picomatch": "^2.3.1" } }, - "require-directory": { - "version": "2.1.1", + "mimic-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", + "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", "dev": true }, - "require-main-filename": { - "version": "2.0.0", + "minimatch": { + "version": "3.0.8", + "dev": true, + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "minipass": { + "version": "7.1.2", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.2.tgz", + "integrity": "sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw==", "dev": true }, - "requirejs": { - "version": "2.3.7", - "resolved": "https://registry.npmjs.org/requirejs/-/requirejs-2.3.7.tgz", - "integrity": "sha512-DouTG8T1WanGok6Qjg2SXuCMzszOo0eHeH9hDZ5Y4x8Je+9JB38HdTLT4/VA8OaUhBa0JPVHJ0pyBkM1z+pDsw==", + "ms": { + "version": "2.1.2", "dev": true }, - "requires-port": { - "version": "1.0.0", + "napi-postinstall": { + "version": "0.3.4", + "resolved": "https://registry.npmjs.org/napi-postinstall/-/napi-postinstall-0.3.4.tgz", + "integrity": "sha512-PHI5f1O0EP5xJ9gQmFGMS6IZcrVvTjpXjz7Na41gTE7eE2hK11lg04CECCYEEjdc17EV4DO+fkGEtt7TpTaTiQ==", "dev": true }, - "resolve": { - "version": "1.12.0", - "dev": true, - "requires": { - "path-parse": "^1.0.6" - } + "natural-compare": { + "version": "1.4.0", + "dev": true }, - "resolve-from": { - "version": "4.0.0", + "node-int64": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz", + "integrity": "sha512-O5lz91xSOeoXP6DulyHfllpq+Eg00MWitZIbtPfoSEvqIHdl5gfcY6hYzDWnj0qD5tz52PI08u9qUvSVeUBeHw==", "dev": true }, - "reusify": { - "version": "1.0.4", + "node-releases": { + "version": "2.0.27", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.27.tgz", + "integrity": "sha512-nmh3lCkYZ3grZvqcCH+fjmQ7X+H0OeZgP40OierEaAptX4XofMh5kwNbWh7lBduUzCcV/8kZ+NDLCwm2iorIlA==", "dev": true }, - "rfdc": { - "version": "1.3.0", + "normalize-path": { + "version": "3.0.0", "dev": true }, - "rimraf": { - "version": "3.0.2", + "npm-run-path": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-4.0.1.tgz", + "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==", "dev": true, "requires": { - "glob": "^7.1.3" + "path-key": "^3.0.0" } }, - "ripemd160": { - "version": "2.0.2", + "once": { + "version": "1.4.0", "dev": true, "requires": { - "hash-base": "^3.0.0", - "inherits": "^2.0.1" + "wrappy": "1" } }, - "run-parallel": { - "version": "1.2.0", + "onetime": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz", + "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==", "dev": true, "requires": { - "queue-microtask": "^1.2.2" + "mimic-fn": "^2.1.0" } }, - "safe-buffer": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", - "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", - "dev": true - }, - "safer-buffer": { - "version": "2.1.2", - "dev": true - }, - "seedrandom": { - "version": "3.0.5", - "dev": true - }, - "semver": { - "version": "7.5.4", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", - "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "p-limit": { + "version": "3.1.0", "dev": true, "requires": { - "lru-cache": "^6.0.0" - }, - "dependencies": { - "lru-cache": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", - "dev": true, - "requires": { - "yallist": "^4.0.0" - } - }, - "yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true - } + "yocto-queue": "^0.1.0" } }, - "serialize-javascript": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.2.tgz", - "integrity": "sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==", + "p-locate": { + "version": "5.0.0", "dev": true, "requires": { - "randombytes": "^2.1.0" + "p-limit": "^3.0.2" } }, - "set-blocking": { - "version": "2.0.0", + "p-try": { + "version": "2.2.0", "dev": true }, - "set-function-length": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", - "integrity": "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==", - "dev": true, - "requires": { - "define-data-property": "^1.1.4", - "es-errors": "^1.3.0", - "function-bind": "^1.1.2", - "get-intrinsic": "^1.2.4", - "gopd": "^1.0.1", - "has-property-descriptors": "^1.0.2" - } - }, - "setprototypeof": { - "version": "1.2.0", + "package-json-from-dist": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/package-json-from-dist/-/package-json-from-dist-1.0.1.tgz", + "integrity": "sha512-UEZIS3/by4OC8vL3P2dTXRETpebLI2NiI5vIrjaD/5UtrkFX/tNbwjTSRAGC/+7CAo2pIcBaRgWmcBBHcsaCIw==", "dev": true }, - "sha.js": { - "version": "2.4.12", - "resolved": "https://registry.npmjs.org/sha.js/-/sha.js-2.4.12.tgz", - "integrity": "sha512-8LzC5+bvI45BjpfXU8V5fdU2mfeKiQe1D1gIMn7XUlF3OTUrpdJpPPH4EMAnF0DsHHdSZqCdSss5qCmJKuiO3w==", + "parent-module": { + "version": "1.0.1", "dev": true, "requires": { - "inherits": "^2.0.4", - "safe-buffer": "^5.2.1", - "to-buffer": "^1.2.0" + "callsites": "^3.0.0" } }, - "shasum": { - "version": "1.0.2", + "parse-json": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz", + "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==", "dev": true, "requires": { - "json-stable-stringify": "~0.0.0", - "sha.js": "~2.4.4" + "@babel/code-frame": "^7.0.0", + "error-ex": "^1.3.1", + "json-parse-even-better-errors": "^2.3.0", + "lines-and-columns": "^1.1.6" } }, - "shebang-command": { - "version": "2.0.0", - "dev": true, - "requires": { - "shebang-regex": "^3.0.0" - } + "path-exists": { + "version": "4.0.0", + "dev": true }, - "shebang-regex": { - "version": "3.0.0", + "path-is-absolute": { + "version": "1.0.1", "dev": true }, - "shell-quote": { - "version": "1.8.0", + "path-key": { + "version": "3.1.1", "dev": true }, - "side-channel": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.6.tgz", - "integrity": "sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==", + "path-scurry": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-1.11.1.tgz", + "integrity": "sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA==", "dev": true, "requires": { - "call-bind": "^1.0.7", - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.4", - "object-inspect": "^1.13.1" + "lru-cache": "^10.2.0", + "minipass": "^5.0.0 || ^6.0.2 || ^7.0.0" + }, + "dependencies": { + "lru-cache": { + "version": "10.4.3", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.4.3.tgz", + "integrity": "sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==", + "dev": true + } } }, - "signal-exit": { - "version": "3.0.7", + "picocolors": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", "dev": true }, - "simple-concat": { - "version": "1.0.0", + "picomatch": { + "version": "2.3.1", "dev": true }, - "socket.io": { - "version": "4.8.0", - "resolved": "https://registry.npmjs.org/socket.io/-/socket.io-4.8.0.tgz", - "integrity": "sha512-8U6BEgGjQOfGz3HHTYaC/L1GaxDCJ/KM0XTkJly0EhZ5U/du9uNEZy4ZgYzEzIqlx2CMm25CrCqr1ck899eLNA==", - "dev": true, - "requires": { - "accepts": "~1.3.4", - "base64id": "~2.0.0", - "cors": "~2.8.5", - "debug": "~4.3.2", - "engine.io": "~6.6.0", - "socket.io-adapter": "~2.5.2", - "socket.io-parser": "~4.2.4" - } - }, - "socket.io-adapter": { - "version": "2.5.2", - "dev": true, - "requires": { - "ws": "~8.11.0" - } + "pirates": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/pirates/-/pirates-4.0.7.tgz", + "integrity": "sha512-TfySrs/5nm8fQJDcBDuUng3VOUKsd7S+zqvbOTiGXHfxX4wK31ard+hoNuvkicM/2YFzlpDgABOevKSsB4G/FA==", + "dev": true }, - "socket.io-parser": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-4.2.4.tgz", - "integrity": "sha512-/GbIKmo8ioc+NIWIhwdecY0ge+qVBSMdgxGygevmdHj24bsfgtCmcUUcQ5ZzcylGFHsN3k4HB4Cgkl96KVnuew==", + "pkg-dir": { + "version": "4.2.0", "dev": true, "requires": { - "@socket.io/component-emitter": "~3.1.0", - "debug": "~4.3.1" + "find-up": "^4.0.0" + }, + "dependencies": { + "find-up": { + "version": "4.1.0", + "dev": true, + "requires": { + "locate-path": "^5.0.0", + "path-exists": "^4.0.0" + } + }, + "locate-path": { + "version": "5.0.0", + "dev": true, + "requires": { + "p-locate": "^4.1.0" + } + }, + "p-limit": { + "version": "2.3.0", + "dev": true, + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "4.1.0", + "dev": true, + "requires": { + "p-limit": "^2.2.0" + } + } } }, - "source-map": { - "version": "0.5.7", + "platform": { + "version": "1.3.5", "dev": true }, - "spawn-wrap": { - "version": "2.0.0", + "pretty-format": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-29.7.0.tgz", + "integrity": "sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ==", "dev": true, "requires": { - "foreground-child": "^2.0.0", - "is-windows": "^1.0.2", - "make-dir": "^3.0.0", - "rimraf": "^3.0.0", - "signal-exit": "^3.0.2", - "which": "^2.0.1" + "@jest/schemas": "^29.6.3", + "ansi-styles": "^5.0.0", + "react-is": "^18.0.0" }, "dependencies": { - "which": { - "version": "2.0.2", + "@jest/schemas": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.3.tgz", + "integrity": "sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==", "dev": true, "requires": { - "isexe": "^2.0.0" + "@sinclair/typebox": "^0.27.8" } + }, + "@sinclair/typebox": { + "version": "0.27.8", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.8.tgz", + "integrity": "sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==", + "dev": true + }, + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true } } }, - "sprintf": { - "version": "0.1.5", + "pure-rand": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/pure-rand/-/pure-rand-7.0.1.tgz", + "integrity": "sha512-oTUZM/NAZS8p7ANR3SHh30kXB+zK2r2BPcEn/awJIbOvq82WoMN4p62AWWp3Hhw50G0xMsw1mhIBLqHw64EcNQ==", "dev": true }, - "sprintf-js": { - "version": "1.0.3", + "queue-microtask": { + "version": "1.2.3", + "dev": true + }, + "react-is": { + "version": "18.3.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz", + "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==", + "dev": true + }, + "regexpp": { + "version": "3.2.0", + "dev": true + }, + "require-directory": { + "version": "2.1.1", + "dev": true + }, + "requirejs": { + "version": "2.3.7", + "resolved": "https://registry.npmjs.org/requirejs/-/requirejs-2.3.7.tgz", + "integrity": "sha512-DouTG8T1WanGok6Qjg2SXuCMzszOo0eHeH9hDZ5Y4x8Je+9JB38HdTLT4/VA8OaUhBa0JPVHJ0pyBkM1z+pDsw==", + "dev": true + }, + "resolve-cwd": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/resolve-cwd/-/resolve-cwd-3.0.0.tgz", + "integrity": "sha512-OrZaX2Mb+rJCpH/6CpSqt9xFVpN++x01XnN2ie9g6P5/3xelLAkXWVADpdz1IHD/KFfEXyE6V0U01OQ3UO2rEg==", + "dev": true, + "requires": { + "resolve-from": "^5.0.0" + }, + "dependencies": { + "resolve-from": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", + "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", + "dev": true + } + } + }, + "resolve-from": { + "version": "4.0.0", "dev": true }, - "statuses": { - "version": "1.5.0", + "reusify": { + "version": "1.0.4", "dev": true }, - "stream-browserify": { - "version": "2.0.2", + "rimraf": { + "version": "3.0.2", "dev": true, "requires": { - "inherits": "~2.0.1", - "readable-stream": "^2.0.2" + "glob": "^7.1.3" } }, - "stream-combiner2": { - "version": "1.1.1", + "run-parallel": { + "version": "1.2.0", "dev": true, "requires": { - "duplexer2": "~0.1.0", - "readable-stream": "^2.0.2" + "queue-microtask": "^1.2.2" } }, - "stream-http": { - "version": "3.1.0", + "semver": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", "dev": true, "requires": { - "builtin-status-codes": "^3.0.0", - "inherits": "^2.0.1", - "readable-stream": "^3.0.6", - "xtend": "^4.0.0" + "lru-cache": "^6.0.0" }, "dependencies": { - "readable-stream": { - "version": "3.4.0", + "lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", "dev": true, "requires": { - "inherits": "^2.0.3", - "string_decoder": "^1.1.1", - "util-deprecate": "^1.0.1" + "yallist": "^4.0.0" } + }, + "yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", + "dev": true } } }, - "stream-splicer": { - "version": "2.0.1", + "shebang-command": { + "version": "2.0.0", "dev": true, "requires": { - "inherits": "^2.0.1", - "readable-stream": "^2.0.2" + "shebang-regex": "^3.0.0" } }, - "streamroller": { - "version": "3.1.5", - "dev": true, - "requires": { - "date-format": "^4.0.14", - "debug": "^4.3.4", - "fs-extra": "^8.1.0" - } + "shebang-regex": { + "version": "3.0.0", + "dev": true }, - "string_decoder": { - "version": "1.3.0", + "signal-exit": { + "version": "3.0.7", + "dev": true + }, + "slash": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", + "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", + "dev": true + }, + "source-map-support": { + "version": "0.5.13", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.13.tgz", + "integrity": "sha512-SHSKFHadjVA5oR4PPqhtAVdcBWwRYVd6g6cAXnIbRiIwc2EhPrTuKUBdSLvlEKyIP3GCf89fltvcZiP9MMFA1w==", "dev": true, "requires": { - "safe-buffer": "~5.2.0" + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" + }, + "dependencies": { + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true + } } }, - "string-length": { - "version": "1.0.1", + "sprintf": { + "version": "0.1.5", + "dev": true + }, + "sprintf-js": { + "version": "1.0.3", + "dev": true + }, + "stack-utils": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/stack-utils/-/stack-utils-2.0.6.tgz", + "integrity": "sha512-XlkWvfIm6RmsWtNJx+uqtKLS8eqFbxUg0ZzLXqY0caEy9l7hruX8IpiDnjsLavoBgqCCR71TqWO8MaXYheJ3RQ==", "dev": true, "requires": { - "strip-ansi": "^3.0.0" + "escape-string-regexp": "^2.0.0" }, "dependencies": { - "ansi-regex": { - "version": "2.1.1", + "escape-string-regexp": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz", + "integrity": "sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w==", "dev": true - }, - "strip-ansi": { - "version": "3.0.1", - "dev": true, - "requires": { - "ansi-regex": "^2.0.0" - } } } }, @@ -10065,16 +11631,17 @@ "emoji-regex": "^8.0.0", "is-fullwidth-code-point": "^3.0.0", "strip-ansi": "^6.0.1" - }, - "dependencies": { - "emoji-regex": { - "version": "8.0.0", - "dev": true - }, - "is-fullwidth-code-point": { - "version": "3.0.0", - "dev": true - } + } + }, + "string-width-cjs": { + "version": "npm:string-width@4.2.3", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", + "dev": true, + "requires": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" } }, "strip-ansi": { @@ -10084,35 +11651,45 @@ "ansi-regex": "^5.0.1" } }, + "strip-ansi-cjs": { + "version": "npm:strip-ansi@6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dev": true, + "requires": { + "ansi-regex": "^5.0.1" + } + }, "strip-bom": { "version": "4.0.0", "dev": true }, + "strip-final-newline": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-2.0.0.tgz", + "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==", + "dev": true + }, "strip-json-comments": { "version": "3.1.1", "dev": true }, - "subarg": { - "version": "1.0.0", - "dev": true, - "requires": { - "minimist": "^1.1.0" - } - }, "supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, "requires": { - "has-flag": "^3.0.0" + "has-flag": "^4.0.0" } }, - "syntax-error": { - "version": "1.4.0", + "synckit": { + "version": "0.11.11", + "resolved": "https://registry.npmjs.org/synckit/-/synckit-0.11.11.tgz", + "integrity": "sha512-MeQTA1r0litLUf0Rp/iisCaL8761lKAZHaimlbGK4j0HysC4PLfqygQj9srcs0m2RdtDYnF8UuYyKpbjHYp7Jw==", "dev": true, "requires": { - "acorn-node": "^1.2.0" + "@pkgr/core": "^0.2.9" } }, "test-exclude": { @@ -10128,52 +11705,10 @@ "version": "0.2.0", "dev": true }, - "through": { - "version": "2.3.8", - "dev": true - }, - "through2": { - "version": "2.0.5", - "dev": true, - "requires": { - "readable-stream": "~2.3.6", - "xtend": "~4.0.1" - } - }, - "timers-browserify": { - "version": "1.4.2", - "dev": true, - "requires": { - "process": "~0.11.0" - } - }, - "tmp": { - "version": "0.2.4", - "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.2.4.tgz", - "integrity": "sha512-UdiSoX6ypifLmrfQ/XfiawN6hkjSBpCjhKxxZcWlUUmoXLaCKQU0bx4HF/tdDK2uzRuchf1txGvrWBzYREssoQ==", - "dev": true - }, - "to-buffer": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/to-buffer/-/to-buffer-1.2.1.tgz", - "integrity": "sha512-tB82LpAIWjhLYbqjx3X4zEeHN6M8CiuOEy2JY8SEQVdYRe3CCHOFaqrBW1doLDrfpWhplcW7BL+bO3/6S3pcDQ==", - "dev": true, - "requires": { - "isarray": "^2.0.5", - "safe-buffer": "^5.2.1", - "typed-array-buffer": "^1.0.3" - }, - "dependencies": { - "isarray": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", - "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", - "dev": true - } - } - }, - "to-fast-properties": { - "version": "2.0.0", + "tmpl": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.5.tgz", + "integrity": "sha512-3f0uOEAQwIqGuWW2MVzYg8fV/QNnc/IpuJNG837rLuczAaLVHslWHZQj4IGiEl5Hs3kkbhwL9Ab7Hrsmuj+Smw==", "dev": true }, "to-regex-range": { @@ -10185,13 +11720,12 @@ "is-number": "^7.0.0" } }, - "toidentifier": { - "version": "1.0.1", - "dev": true - }, - "tty-browserify": { - "version": "0.0.1", - "dev": true + "tslib": { + "version": "2.8.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz", + "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==", + "dev": true, + "optional": true }, "type-detect": { "version": "4.0.8", @@ -10201,79 +11735,52 @@ "version": "0.20.2", "dev": true }, - "type-is": { - "version": "1.6.18", - "dev": true, - "requires": { - "media-typer": "0.3.0", - "mime-types": "~2.1.24" - } - }, - "typed-array-buffer": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.3.tgz", - "integrity": "sha512-nAYYwfY3qnzX30IkA6AQZjVbtK6duGontcQm1WSG1MD94YLqK0515GNApXkoxKOWMusVssAHWLh9SeaoefYFGw==", - "dev": true, - "requires": { - "call-bound": "^1.0.3", - "es-errors": "^1.3.0", - "is-typed-array": "^1.1.14" - } - }, - "typedarray": { - "version": "0.0.6", - "dev": true - }, - "typedarray-to-buffer": { - "version": "3.1.5", - "dev": true, - "requires": { - "is-typedarray": "^1.0.0" - } - }, - "ua-parser-js": { - "version": "0.7.33", - "dev": true - }, "uglify-js": { "version": "3.17.4", "dev": true }, - "umd": { - "version": "3.0.3", - "dev": true - }, - "undeclared-identifiers": { - "version": "1.1.3", - "dev": true, - "requires": { - "acorn-node": "^1.3.0", - "dash-ast": "^1.0.0", - "get-assigned-identifiers": "^1.2.0", - "simple-concat": "^1.0.0", - "xtend": "^4.0.1" - } - }, "undici-types": { - "version": "6.19.8", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.19.8.tgz", - "integrity": "sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==", - "dev": true - }, - "universalify": { - "version": "0.1.2", - "dev": true - }, - "unpipe": { - "version": "1.0.0", - "dev": true + "version": "6.21.0", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", + "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==", + "dev": true + }, + "unrs-resolver": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/unrs-resolver/-/unrs-resolver-1.11.1.tgz", + "integrity": "sha512-bSjt9pjaEBnNiGgc9rUiHGKv5l4/TGzDmYw3RhnkJGtLhbnnA/5qJj7x3dNDCRx/PJxu774LlH8lCOlB4hEfKg==", + "dev": true, + "requires": { + "@unrs/resolver-binding-android-arm-eabi": "1.11.1", + "@unrs/resolver-binding-android-arm64": "1.11.1", + "@unrs/resolver-binding-darwin-arm64": "1.11.1", + "@unrs/resolver-binding-darwin-x64": "1.11.1", + "@unrs/resolver-binding-freebsd-x64": "1.11.1", + "@unrs/resolver-binding-linux-arm-gnueabihf": "1.11.1", + "@unrs/resolver-binding-linux-arm-musleabihf": "1.11.1", + "@unrs/resolver-binding-linux-arm64-gnu": "1.11.1", + "@unrs/resolver-binding-linux-arm64-musl": "1.11.1", + "@unrs/resolver-binding-linux-ppc64-gnu": "1.11.1", + "@unrs/resolver-binding-linux-riscv64-gnu": "1.11.1", + "@unrs/resolver-binding-linux-riscv64-musl": "1.11.1", + "@unrs/resolver-binding-linux-s390x-gnu": "1.11.1", + "@unrs/resolver-binding-linux-x64-gnu": "1.11.1", + "@unrs/resolver-binding-linux-x64-musl": "1.11.1", + "@unrs/resolver-binding-wasm32-wasi": "1.11.1", + "@unrs/resolver-binding-win32-arm64-msvc": "1.11.1", + "@unrs/resolver-binding-win32-ia32-msvc": "1.11.1", + "@unrs/resolver-binding-win32-x64-msvc": "1.11.1", + "napi-postinstall": "^0.3.0" + } }, "update-browserslist-db": { - "version": "1.0.10", + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.1.4.tgz", + "integrity": "sha512-q0SPT4xyU84saUX+tomz1WLkxUbuaJnR1xWt17M7fJtEJigJeWUNGUqrauFXsHnqev9y9JTRGwk13tFBuKby4A==", "dev": true, "requires": { - "escalade": "^3.1.1", - "picocolors": "^1.0.0" + "escalade": "^3.2.0", + "picocolors": "^1.1.1" } }, "uri-js": { @@ -10289,83 +11796,32 @@ } } }, - "url": { - "version": "0.11.0", - "dev": true, - "requires": { - "punycode": "1.3.2", - "querystring": "0.2.0" - }, - "dependencies": { - "punycode": { - "version": "1.3.2", - "dev": true - } - } - }, - "util": { - "version": "0.10.4", + "v8-to-istanbul": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/v8-to-istanbul/-/v8-to-istanbul-9.3.0.tgz", + "integrity": "sha512-kiGUalWN+rgBJ/1OHZsBtU4rXZOfj/7rKQxULKlIzwzQSvMJUUNgPwJEEh7gU6xEVxC0ahoOBvN2YI8GH6FNgA==", "dev": true, "requires": { - "inherits": "2.0.3" + "@jridgewell/trace-mapping": "^0.3.12", + "@types/istanbul-lib-coverage": "^2.0.1", + "convert-source-map": "^2.0.0" }, "dependencies": { - "inherits": { - "version": "2.0.3", + "convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", "dev": true } } }, - "util-deprecate": { - "version": "1.0.2", - "dev": true - }, - "utils-merge": { - "version": "1.0.1", - "dev": true - }, - "uuid": { - "version": "8.3.2", - "dev": true - }, - "vary": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", - "integrity": "sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==", - "dev": true - }, - "vm-browserify": { - "version": "1.1.0", - "dev": true - }, - "void-elements": { - "version": "2.0.1", - "dev": true - }, - "which": { - "version": "1.3.1", - "dev": true, - "requires": { - "isexe": "^2.0.0" - } - }, - "which-module": { - "version": "2.0.0", - "dev": true - }, - "which-typed-array": { - "version": "1.1.19", - "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.19.tgz", - "integrity": "sha512-rEvr90Bck4WZt9HHFC4DJMsjvu7x+r6bImz0/BrbWb7A2djJ8hnZMrWnHo9F8ssv0OMErasDhftrfROTyqSDrw==", + "walker": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/walker/-/walker-1.0.8.tgz", + "integrity": "sha512-ts/8E8l5b7kY0vlWLewOkDXMmPdLcVV4GmOQLyxuSswIJsweeFZtAsMF7k1Nszz+TYBQrlYRmzOnr398y1JemQ==", "dev": true, "requires": { - "available-typed-arrays": "^1.0.7", - "call-bind": "^1.0.8", - "call-bound": "^1.0.4", - "for-each": "^0.3.5", - "get-proto": "^1.0.1", - "gopd": "^1.2.0", - "has-tostringtag": "^1.0.2" + "makeerror": "1.0.12" } }, "word-wrap": { @@ -10374,12 +11830,6 @@ "integrity": "sha512-2V81OA4ugVo5pRo46hAoD2ivUJx8jXmWXfUkY4KFNw0hEptvN0QfH3K4nHiwzGeKl5rFKedV48QVoqYavy4YpA==", "dev": true }, - "workerpool": { - "version": "6.5.1", - "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.5.1.tgz", - "integrity": "sha512-Fs4dNYcsdpYSAfVxhnl1L5zTksjvOJxtC5hzMNl+1t9B8hTJTdKDyZ5ju7ztgPy+ft9tBFXoOlDNiOT9WUXZlA==", - "dev": true - }, "wrap-ansi": { "version": "7.0.0", "dev": true, @@ -10387,49 +11837,21 @@ "ansi-styles": "^4.0.0", "string-width": "^4.1.0", "strip-ansi": "^6.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "color-convert": { - "version": "2.0.1", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "dev": true - } } }, - "wrappy": { - "version": "1.0.2", - "dev": true - }, - "write-file-atomic": { - "version": "3.0.3", + "wrap-ansi-cjs": { + "version": "npm:wrap-ansi@7.0.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", + "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", "dev": true, "requires": { - "imurmurhash": "^0.1.4", - "is-typedarray": "^1.0.0", - "signal-exit": "^3.0.2", - "typedarray-to-buffer": "^3.1.5" + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" } }, - "ws": { - "version": "8.11.0", - "dev": true, - "requires": {} - }, - "xtend": { - "version": "4.0.2", + "wrappy": { + "version": "1.0.2", "dev": true }, "y18n": { @@ -10438,37 +11860,10 @@ }, "yallist": { "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", + "integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==", "dev": true }, - "yargs": { - "version": "16.2.0", - "dev": true, - "requires": { - "cliui": "^7.0.2", - "escalade": "^3.1.1", - "get-caller-file": "^2.0.5", - "require-directory": "^2.1.1", - "string-width": "^4.2.0", - "y18n": "^5.0.5", - "yargs-parser": "^20.2.2" - } - }, - "yargs-parser": { - "version": "20.2.9", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.9.tgz", - "integrity": "sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==", - "dev": true - }, - "yargs-unparser": { - "version": "2.0.0", - "dev": true, - "requires": { - "camelcase": "^6.0.0", - "decamelize": "^4.0.0", - "flat": "^5.0.2", - "is-plain-obj": "^2.1.0" - } - }, "yocto-queue": { "version": "0.1.0", "dev": true diff --git a/package.json b/package.json index 8e536426..e20f6eeb 100644 --- a/package.json +++ b/package.json @@ -3,42 +3,41 @@ "version": "2.2.5-pre", "description": "A directed and undirected multi-graph library", "author": "Chris Pettitt ", + "contributors": [ + "David Newell" + ], "license": "MIT", - "main": "index.js", + "main": "dist/graphlib.cjs.js", + "module": "dist/graphlib.esm.js", "scripts": { - "lint": "make lint", - "test": "make test" + "build": "node build.js", + "test": "jest", + "lint": "eslint . --ext .js,.ts" }, "files": [ - "index.js", - "index.d.ts", - "dist/", - "lib/" + "dist/" ], - "engines": { - "node": ">17.0.0" + "exports": { + ".": { + "types": "./dist/dagre.d.ts", + "import": "./dist/dagre.esm.js", + "require": "./dist/dagre.cjs.js" + }, + "./package.json": "./package.json" }, - "types": "index.d.ts", + "types": "./dist/dagre.d.ts", "keywords": [ "graph", "algorithms" ], "devDependencies": { + "@types/jest": "^29.5.12", + "@types/node": "^20.14.9", "benchmark": "2.1.4", - "browserify": "16.5.1", - "chai": "^4.3.6", + "esbuild": "^0.27.0", "eslint": "8.35.0", - "jshint": "2.13.5", - "jshint-stylish": "2.2.1", - "karma": "6.4.1", - "karma-chrome-launcher": "3.1.0", - "karma-mocha": "2.0.1", - "karma-requirejs": "1.1.0", - "karma-safari-launcher": "1.0.0", - "mocha": "10.8.2", - "nyc": "^15.1.0", + "jest": "^30.2.0", "requirejs": "2.3.7", - "seedrandom": "3.0.5", "semver": "7.5.4", "sprintf": "0.1.5", "uglify-js": "3.17.4" @@ -47,4 +46,4 @@ "type": "git", "url": "https://github.com/dagrejs/graphlib.git" } -} \ No newline at end of file +} diff --git a/src/bench.js b/src/bench.js index 096b6255..1ffdba47 100755 --- a/src/bench.js +++ b/src/bench.js @@ -1,8 +1,8 @@ #!/usr/bin/env node var Benchmark = require("benchmark"), - seedrandom = require("seedrandom"), - sprintf = require("sprintf").sprintf; + seedrandom = require("seedrandom"), + sprintf = require("sprintf").sprintf; var seed = process.env.SEED; seedrandom(seed, { global: true }); @@ -11,34 +11,34 @@ if (seed) { } var Graph = require("..").Graph, - alg = require("..").alg; + alg = require("..").alg; var NODE_SIZES = [100], - EDGE_DENSITY = 0.2, - KEY_SIZE = 10; + EDGE_DENSITY = 0.2, + KEY_SIZE = 10; function runBenchmark(name, fn) { var options = {}; - options.onComplete = function(bench) { + options.onComplete = function (bench) { var target = bench.target, - hz = target.hz, - stats = target.stats, - rme = stats.rme, - samples = stats.sample.length, - msg = sprintf(" %25s: %13s ops/sec \xb1 %s%% (%3d run(s) sampled)", - target.name, - Benchmark.formatNumber(hz.toFixed(2)), - rme.toFixed(2), - samples); + hz = target.hz, + stats = target.stats, + rme = stats.rme, + samples = stats.sample.length, + msg = sprintf(" %25s: %13s ops/sec \xb1 %s%% (%3d run(s) sampled)", + target.name, + Benchmark.formatNumber(hz.toFixed(2)), + rme.toFixed(2), + samples); console.log(msg); }; - options.onError = function(bench) { + options.onError = function (bench) { console.error(" " + bench.target.error); }; - options.setup = function() { + options.setup = function () { this.count = Math.random() * 1000; - this.nextInt = function(range) { - return Math.floor(this.count++ % range ); + this.nextInt = function (range) { + return Math.floor(this.count++ % range); }; }; new Benchmark(name, fn, options).run(); @@ -46,7 +46,7 @@ function runBenchmark(name, fn) { function keys(count) { var ks = [], - k; + k; for (var i = 0; i < count; ++i) { k = ""; for (var j = 0; j < KEY_SIZE; ++j) { @@ -59,10 +59,10 @@ function keys(count) { function buildGraph(numNodes, edgeDensity) { var g = new Graph(), - numEdges = numNodes * numNodes * edgeDensity, - ks = keys(numNodes); + numEdges = numNodes * numNodes * edgeDensity, + ks = keys(numNodes); - ks.forEach(function(k) { g.setNode(k); }); + ks.forEach(function (k) { g.setNode(k); }); for (var i = 0; i < numEdges; ++i) { var v, w; @@ -75,96 +75,96 @@ function buildGraph(numNodes, edgeDensity) { return g; } -NODE_SIZES.forEach(function(size) { +NODE_SIZES.forEach(function (size) { var g = buildGraph(size, EDGE_DENSITY), - nodes = g.nodes(), - edges = g.edges(), - nameSuffix = "(" + size + "," + EDGE_DENSITY + ")"; + nodes = g.nodes(), + edges = g.edges(), + nameSuffix = "(" + size + "," + EDGE_DENSITY + ")"; - runBenchmark("nodes" + nameSuffix, function() { + runBenchmark("nodes" + nameSuffix, function () { g.nodes(); }); - runBenchmark("sources" + nameSuffix, function() { + runBenchmark("sources" + nameSuffix, function () { g.sources(); }); - runBenchmark("sinks" + nameSuffix, function() { + runBenchmark("sinks" + nameSuffix, function () { g.sinks(); }); - runBenchmark("filterNodes all" + nameSuffix, function() { - g.filterNodes(function() { return true; }); + runBenchmark("filterNodes all" + nameSuffix, function () { + g.filterNodes(function () { return true; }); }); - runBenchmark("filterNodes none" + nameSuffix, function() { - g.filterNodes(function() { return false; }); + runBenchmark("filterNodes none" + nameSuffix, function () { + g.filterNodes(function () { return false; }); }); - runBenchmark("setNode" + nameSuffix, function() { + runBenchmark("setNode" + nameSuffix, function () { g.setNode("key", "label"); }); - runBenchmark("node" + nameSuffix, function() { + runBenchmark("node" + nameSuffix, function () { g.node(nodes[this.nextInt(nodes.length)]); }); - runBenchmark("set + removeNode" + nameSuffix, function() { + runBenchmark("set + removeNode" + nameSuffix, function () { g.setNode("key"); g.removeNode("key"); }); - runBenchmark("predecessors" + nameSuffix, function() { + runBenchmark("predecessors" + nameSuffix, function () { g.predecessors(nodes[this.nextInt(nodes.length)]); }); - runBenchmark("successors" + nameSuffix, function() { + runBenchmark("successors" + nameSuffix, function () { g.successors(nodes[this.nextInt(nodes.length)]); }); - runBenchmark("neighbors" + nameSuffix, function() { + runBenchmark("neighbors" + nameSuffix, function () { g.neighbors(nodes[this.nextInt(nodes.length)]); }); - runBenchmark("edges" + nameSuffix, function() { + runBenchmark("edges" + nameSuffix, function () { g.edges(); }); - runBenchmark("setPath" + nameSuffix, function() { + runBenchmark("setPath" + nameSuffix, function () { g.setPath(["a", "b", "c", "d", "e"]); }); - runBenchmark("setEdge" + nameSuffix, function() { + runBenchmark("setEdge" + nameSuffix, function () { g.setEdge("from", "to", "label"); }); - runBenchmark("edge" + nameSuffix, function() { + runBenchmark("edge" + nameSuffix, function () { var edge = edges[this.nextInt(edges.length)]; g.edge(edge); }); - runBenchmark("set + removeEdge" + nameSuffix, function() { + runBenchmark("set + removeEdge" + nameSuffix, function () { g.setEdge("from", "to"); g.removeEdge("from", "to"); }); - runBenchmark("inEdges" + nameSuffix, function() { + runBenchmark("inEdges" + nameSuffix, function () { g.inEdges(nodes[this.nextInt(nodes.length)]); }); - runBenchmark("outEdges" + nameSuffix, function() { + runBenchmark("outEdges" + nameSuffix, function () { g.outEdges(nodes[this.nextInt(nodes.length)]); }); - runBenchmark("nodeEdges" + nameSuffix, function() { + runBenchmark("nodeEdges" + nameSuffix, function () { g.nodeEdges(nodes[this.nextInt(nodes.length)]); }); - runBenchmark("components" + nameSuffix, function() { + runBenchmark("components" + nameSuffix, function () { alg.components(g); }); - runBenchmark("dijkstraAll" + nameSuffix, function() { + runBenchmark("dijkstraAll" + nameSuffix, function () { alg.dijkstraAll(g); }); }); diff --git a/src/release/bump-version.js b/src/release/bump-version.js index 80f7b3d6..1c723119 100755 --- a/src/release/bump-version.js +++ b/src/release/bump-version.js @@ -5,7 +5,7 @@ */ var fs = require("fs"), - semver = require("semver"); + semver = require("semver"); var packageFile = fs.readFileSync("package.json"); var packageJson = JSON.parse(packageFile); @@ -21,6 +21,6 @@ fs.writeFileSync("package.json", JSON.stringify(packageJson, undefined, 2)); // Write an error message to stderr and then exit immediately with an error. function bail(msg) { - stderr.write(msg + "\n"); + console.error(msg + "\n"); process.exit(1); } diff --git a/src/release/check-version.js b/src/release/check-version.js index 18901586..7127bd51 100755 --- a/src/release/check-version.js +++ b/src/release/check-version.js @@ -7,7 +7,7 @@ */ var fs = require("fs"), - semver = require("semver"); + semver = require("semver"); var packageFile = fs.readFileSync("package.json"); var packageJson = JSON.parse(packageFile); @@ -17,7 +17,7 @@ if (!("version" in packageJson)) { } var ver = semver.parse(packageJson.version), - preRelease = process.env.PRE_RELEASE; + preRelease = process.env.PRE_RELEASE; if (ver.prerelease.length > 0 && !preRelease) { bail("ERROR: version is a pre-release: " + ver); diff --git a/src/release/make-version.js b/src/release/make-version.js index 39f2642b..a8d4fa4f 100755 --- a/src/release/make-version.js +++ b/src/release/make-version.js @@ -1,4 +1,4 @@ #!/usr/bin/env node -var package = require('../../package.json'); -console.log('module.exports = \'' + package.version + '\';'); +var packagejson = require('../../package.json'); +console.log('module.exports = \'' + packagejson.version + '\';'); diff --git a/test/alg/components-test.js b/test/alg/components-test.js index 0b4a26a8..af4d00dd 100644 --- a/test/alg/components-test.js +++ b/test/alg/components-test.js @@ -1,10 +1,9 @@ -var expect = require("../chai").expect; var Graph = require("../..").Graph; var components = require("../..").alg.components; describe("alg.components", function() { it("returns an empty list for an empty graph", function() { - expect(components(new Graph({ directed: false }))).to.be.empty; + expect(components(new Graph({ directed: false }))).toHaveLength(0); }); it("returns singleton lists for unconnected nodes", function() { @@ -13,7 +12,7 @@ describe("alg.components", function() { g.setNode("b"); var result = components(g).sort((a, b) => a[0].localeCompare(b[0])); - expect(result).to.eql([["a"], ["b"]]); + expect(result).toEqual([["a"], ["b"]]); }); it("returns a list of nodes in a component", function() { @@ -22,7 +21,7 @@ describe("alg.components", function() { g.setEdge("b", "c"); var result = components(g).map(xs => xs.sort()); - expect(result).to.eql([["a", "b", "c"]]); + expect(result).toEqual([["a", "b", "c"]]); }); it("returns nodes connected by a neighbor relationship in a digraph", function() { @@ -32,6 +31,6 @@ describe("alg.components", function() { g.setEdge("e", "f"); var result = components(g).map(xs => xs.sort()).sort((a, b) => a[0].localeCompare(b[0])); - expect(result).to.eql([["a", "b", "c", "d"], ["e", "f"]]); + expect(result).toEqual([["a", "b", "c", "d"], ["e", "f"]]); }); }); diff --git a/test/alg/dijkstra-all-test.js b/test/alg/dijkstra-all-test.js index b7de355e..a13dbbf5 100644 --- a/test/alg/dijkstra-all-test.js +++ b/test/alg/dijkstra-all-test.js @@ -1,7 +1,6 @@ -var expect = require("../chai").expect; var Graph = require("../..").Graph; var dijkstraAll = require("../..").alg.dijkstraAll; -var allShortestPathsTest = require("./all-shortest-paths-test"); +var allShortestPathsTest = require("./utils/all-shortest-paths-test"); describe("alg.dijkstraAll", function() { allShortestPathsTest.tests(dijkstraAll); @@ -13,7 +12,7 @@ describe("alg.dijkstraAll", function() { g.setEdge("b", "d", 3); g.setEdge("c", "d", 3); - expect(function() { dijkstraAll(g, weight(g)); }).to.throw(); + expect(function() { dijkstraAll(g, weight(g)); }).toThrow(); }); }); diff --git a/test/alg/dijkstra-test.js b/test/alg/dijkstra-test.js index bfb77737..8112d7e6 100644 --- a/test/alg/dijkstra-test.js +++ b/test/alg/dijkstra-test.js @@ -1,4 +1,3 @@ -var expect = require("../chai").expect; var Graph = require("../..").Graph; var dijkstra = require("../..").alg.dijkstra; @@ -7,14 +6,14 @@ describe("alg.dijkstra", function() { it("assigns distance 0 for the source node", function() { var g = new Graph(); g.setNode("source"); - expect(dijkstra(g, "source")).to.eql({ source: { distance: 0 } }); + expect(dijkstra(g, "source")).toEqual({ source: { distance: 0 } }); }); it("returns Number.POSITIVE_INFINITY for unconnected nodes", function() { var g = new Graph(); g.setNode("a"); g.setNode("b"); - expect(dijkstra(g, "a")).to.eql({ + expect(dijkstra(g, "a")).toEqual({ a: { distance: 0 }, b: { distance: Number.POSITIVE_INFINITY } }); @@ -24,7 +23,7 @@ describe("alg.dijkstra", function() { var g = new Graph(); g.setPath(["a", "b", "c"]); g.setEdge("b", "d"); - expect(dijkstra(g, "a")).to.eql({ + expect(dijkstra(g, "a")).toEqual({ a: { distance: 0 }, b: { distance: 1, predecessor: "a" }, c: { distance: 2, predecessor: "b" }, @@ -36,7 +35,7 @@ describe("alg.dijkstra", function() { var g = new Graph({ directed: false }); g.setPath(["a", "b", "c"]); g.setEdge("b", "d"); - expect(dijkstra(g, "a")).to.eql({ + expect(dijkstra(g, "a")).toEqual({ a: { distance: 0 }, b: { distance: 1, predecessor: "a" }, c: { distance: 2, predecessor: "b" }, @@ -51,7 +50,7 @@ describe("alg.dijkstra", function() { g.setEdge("b", "d", 3); g.setEdge("c", "d", 3); - expect(dijkstra(g, "a", weightFn(g))).to.eql({ + expect(dijkstra(g, "a", weightFn(g))).toEqual({ a: { distance: 0 }, b: { distance: 1, predecessor: "a" }, c: { distance: 2, predecessor: "a" }, @@ -64,7 +63,7 @@ describe("alg.dijkstra", function() { g.setPath(["a", "c", "d"]); g.setEdge("b", "c"); - expect(dijkstra(g, "d", undefined, function(e) { return g.inEdges(e); })).to.eql({ + expect(dijkstra(g, "d", undefined, function(e) { return g.inEdges(e); })).toEqual({ a: { distance: 2, predecessor: "c" }, b: { distance: 2, predecessor: "c" }, c: { distance: 1, predecessor: "d" }, @@ -79,7 +78,7 @@ describe("alg.dijkstra", function() { g.setEdge("b", "d", 3); g.setEdge("c", "d", 3); - expect(function() { dijkstra(g, "a", weightFn(g)); }).to.throw(); + expect(function() { dijkstra(g, "a", weightFn(g)); }).toThrow(); }); }); diff --git a/test/alg/find-cycles-test.js b/test/alg/find-cycles-test.js index 20f991d2..5776457a 100644 --- a/test/alg/find-cycles-test.js +++ b/test/alg/find-cycles-test.js @@ -1,34 +1,33 @@ -var expect = require("../chai").expect; var Graph = require("../..").Graph; var findCycles = require("../..").alg.findCycles; describe("alg.findCycles", function() { it("returns an empty array for an empty graph", function() { - expect(findCycles(new Graph())).to.eql([]); + expect(findCycles(new Graph())).toEqual([]); }); it("returns an empty array if the graph has no cycles", function() { var g = new Graph(); g.setPath(["a", "b", "c"]); - expect(findCycles(g)).to.eql([]); + expect(findCycles(g)).toEqual([]); }); it("returns a single entry for a cycle of 1 node", function() { var g = new Graph(); g.setPath(["a", "a"]); - expect(sort(findCycles(g))).to.eql([["a"]]); + expect(sort(findCycles(g))).toEqual([["a"]]); }); it("returns a single entry for a cycle of 2 nodes", function() { var g = new Graph(); g.setPath(["a", "b", "a"]); - expect(sort(findCycles(g))).to.eql([["a", "b"]]); + expect(sort(findCycles(g))).toEqual([["a", "b"]]); }); it("returns a single entry for a triangle", function() { var g = new Graph(); g.setPath(["a", "b", "c", "a"]); - expect(sort(findCycles(g))).to.eql([["a", "b", "c"]]); + expect(sort(findCycles(g))).toEqual([["a", "b", "c"]]); }); it("returns multiple entries for multiple cycles", function() { @@ -37,7 +36,7 @@ describe("alg.findCycles", function() { g.setPath(["c", "d", "e", "c"]); g.setPath(["f", "g", "g"]); g.setNode("h"); - expect(sort(findCycles(g))).to.eql([["a", "b"], ["c", "d", "e"], ["g"]]); + expect(sort(findCycles(g))).toEqual([["a", "b"], ["c", "d", "e"], ["g"]]); }); }); diff --git a/test/alg/floyd-warshall-test.js b/test/alg/floyd-warshall-test.js index 700c0ccb..497b4344 100644 --- a/test/alg/floyd-warshall-test.js +++ b/test/alg/floyd-warshall-test.js @@ -1,7 +1,6 @@ -var expect = require("../chai").expect; var Graph = require("../..").Graph; var floydWarshall = require("../..").alg.floydWarshall; -var allShortestPathsTest = require("./all-shortest-paths-test"); +var allShortestPathsTest = require("./utils/all-shortest-paths-test"); describe("alg.floydWarshall", function() { allShortestPathsTest.tests(floydWarshall); @@ -13,7 +12,7 @@ describe("alg.floydWarshall", function() { g.setEdge("b", "d", 3); g.setEdge("c", "d", 3); - expect(floydWarshall(g, weightFn(g))).to.eql({ + expect(floydWarshall(g, weightFn(g))).toEqual({ a: { a: { distance: 0 }, b: { distance: 1, predecessor: "a" }, @@ -47,7 +46,7 @@ describe("alg.floydWarshall", function() { // In the case of a negative cycle the distance is not well-defined beyond // having a negative value along the diagonal. - expect(floydWarshall(g, weightFn(g))).to.eql({ + expect(floydWarshall(g, weightFn(g))).toEqual({ a: { a: { distance: -2, predecessor: "a" } } diff --git a/test/alg/is-acyclic-test.js b/test/alg/is-acyclic-test.js index 03c8f8d1..77e778fb 100644 --- a/test/alg/is-acyclic-test.js +++ b/test/alg/is-acyclic-test.js @@ -1,4 +1,3 @@ -var expect = require("../chai").expect; var Graph = require("../..").Graph; var isAcyclic = require("../..").alg.isAcyclic; @@ -6,22 +5,22 @@ describe("alg.isAcyclic", function() { it("returns true if the graph has no cycles", function() { var g = new Graph(); g.setPath(["a", "b", "c"]); - expect(isAcyclic(g)).to.be.true; + expect(isAcyclic(g)).toBe(true); }); it("returns false if the graph has at least one cycle", function() { var g = new Graph(); g.setPath(["a", "b", "c", "a"]); - expect(isAcyclic(g)).to.be.false; + expect(isAcyclic(g)).toBe(false); }); it("returns false if the graph has a cycle of 1 node", function() { var g = new Graph(); g.setPath(["a", "a"]); - expect(isAcyclic(g)).to.be.false; + expect(isAcyclic(g)).toBe(false); }); it("rethrows non-CycleException errors", function() { - expect(function() { isAcyclic(undefined); }).to.throw(); + expect(function() { isAcyclic(undefined); }).toThrow(); }); }); diff --git a/test/alg/postorder-test.js b/test/alg/postorder-test.js index 68530d91..0c81bcc3 100644 --- a/test/alg/postorder-test.js +++ b/test/alg/postorder-test.js @@ -1,4 +1,3 @@ -var expect = require("../chai").expect; var Graph = require("../..").Graph; var postorder = require("../..").alg.postorder; @@ -6,7 +5,7 @@ describe("alg.postorder", function() { it("returns the root for a singleton graph", function() { var g = new Graph(); g.setNode("a"); - expect(postorder(g, "a")).to.eql(["a"]); + expect(postorder(g, "a")).toEqual(["a"]); }); it("visits each node in the graph once", function() { @@ -15,7 +14,7 @@ describe("alg.postorder", function() { g.setPath(["a", "c", "d", "e"]); var nodes = postorder(g, "a"); - expect(nodes.sort()).to.eql(["a", "b", "c", "d", "e"]); + expect(nodes.sort()).toEqual(["a", "b", "c", "d", "e"]); }); it("works for a tree", function() { @@ -25,11 +24,11 @@ describe("alg.postorder", function() { g.setEdge("c", "e"); var nodes = postorder(g, "a"); - expect(nodes.indexOf("b")).to.be.lt(nodes.indexOf("a")); - expect(nodes.indexOf("c")).to.be.lt(nodes.indexOf("a")); - expect(nodes.indexOf("d")).to.be.lt(nodes.indexOf("c")); - expect(nodes.indexOf("e")).to.be.lt(nodes.indexOf("c")); - expect(nodes.sort()).to.eql(["a", "b", "c", "d", "e"]); + expect(nodes.indexOf("b")).toBeLessThan(nodes.indexOf("a")); + expect(nodes.indexOf("c")).toBeLessThan(nodes.indexOf("a")); + expect(nodes.indexOf("d")).toBeLessThan(nodes.indexOf("c")); + expect(nodes.indexOf("e")).toBeLessThan(nodes.indexOf("c")); + expect(nodes.sort()).toEqual(["a", "b", "c", "d", "e"]); }); it("works for an array of roots", function() { @@ -40,9 +39,9 @@ describe("alg.postorder", function() { g.setNode("f"); var nodes = postorder(g, ["a", "b", "c", "e"]); - expect(nodes.indexOf("b")).to.be.lt(nodes.indexOf("a")); - expect(nodes.indexOf("d")).to.be.lt(nodes.indexOf("c")); - expect(nodes.sort()).to.eql(["a", "b", "c", "d", "e"]); + expect(nodes.indexOf("b")).toBeLessThan(nodes.indexOf("a")); + expect(nodes.indexOf("d")).toBeLessThan(nodes.indexOf("c")); + expect(nodes.sort()).toEqual(["a", "b", "c", "d", "e"]); }); it("works for multiple connected roots", function() { @@ -52,15 +51,15 @@ describe("alg.postorder", function() { g.setEdge("d", "c"); var nodes = postorder(g, ["a", "d"]); - expect(nodes.indexOf("b")).to.be.lt(nodes.indexOf("a")); - expect(nodes.indexOf("c")).to.be.lt(nodes.indexOf("a")); - expect(nodes.indexOf("c")).to.be.lt(nodes.indexOf("d")); - expect(nodes.sort()).to.eql(["a", "b", "c", "d"]); + expect(nodes.indexOf("b")).toBeLessThan(nodes.indexOf("a")); + expect(nodes.indexOf("c")).toBeLessThan(nodes.indexOf("a")); + expect(nodes.indexOf("c")).toBeLessThan(nodes.indexOf("d")); + expect(nodes.sort()).toEqual(["a", "b", "c", "d"]); }); it("fails if root is not in the graph", function() { var g = new Graph(); g.setNode("a"); - expect(function() { postorder(g, "b"); }).to.throw(); + expect(function() { postorder(g, "b"); }).toThrow(); }); }); diff --git a/test/alg/preorder-test.js b/test/alg/preorder-test.js index ddf575a0..c73a0d44 100644 --- a/test/alg/preorder-test.js +++ b/test/alg/preorder-test.js @@ -1,4 +1,3 @@ -var expect = require("../chai").expect; var Graph = require("../..").Graph; var preorder = require("../..").alg.preorder; @@ -6,7 +5,7 @@ describe("alg.preorder", function() { it("returns the root for a singleton graph", function() { var g = new Graph(); g.setNode("a"); - expect(preorder(g, "a")).to.eql(["a"]); + expect(preorder(g, "a")).toEqual(["a"]); }); it("visits each node in the graph once", function() { @@ -15,7 +14,7 @@ describe("alg.preorder", function() { g.setPath(["a", "c", "d", "e"]); var nodes = preorder(g, "a"); - expect(nodes.sort()).to.eql(["a", "b", "c", "d", "e"]); + expect(nodes.sort()).toEqual(["a", "b", "c", "d", "e"]); }); it("works for a tree", function() { @@ -25,11 +24,11 @@ describe("alg.preorder", function() { g.setEdge("c", "e"); var nodes = preorder(g, "a"); - expect(nodes.sort()).to.eql(["a", "b", "c", "d", "e"]); - expect(nodes.indexOf("b")).to.be.gt(nodes.indexOf("a")); - expect(nodes.indexOf("c")).to.be.gt(nodes.indexOf("a")); - expect(nodes.indexOf("d")).to.be.gt(nodes.indexOf("c")); - expect(nodes.indexOf("e")).to.be.gt(nodes.indexOf("c")); + expect(nodes.sort()).toEqual(["a", "b", "c", "d", "e"]); + expect(nodes.indexOf("b")).toBeGreaterThan(nodes.indexOf("a")); + expect(nodes.indexOf("c")).toBeGreaterThan(nodes.indexOf("a")); + expect(nodes.indexOf("d")).toBeGreaterThan(nodes.indexOf("c")); + expect(nodes.indexOf("e")).toBeGreaterThan(nodes.indexOf("c")); }); it("works for an array of roots", function() { @@ -40,14 +39,14 @@ describe("alg.preorder", function() { g.setNode("f"); var nodes = preorder(g, ["a", "c", "e"]); - expect(nodes.sort()).to.eql(["a", "b", "c", "d", "e"]); - expect(nodes.indexOf("b")).to.be.gt(nodes.indexOf("a")); - expect(nodes.indexOf("d")).to.be.gt(nodes.indexOf("c")); + expect(nodes.sort()).toEqual(["a", "b", "c", "d", "e"]); + expect(nodes.indexOf("b")).toBeGreaterThan(nodes.indexOf("a")); + expect(nodes.indexOf("d")).toBeGreaterThan(nodes.indexOf("c")); }); it("fails if root is not in the graph", function() { var g = new Graph(); g.setNode("a"); - expect(function() { preorder(g, "b"); }).to.throw(); + expect(function() { preorder(g, "b"); }).toThrow(); }); }); diff --git a/test/alg/prim-test.js b/test/alg/prim-test.js index 88876d80..f8069252 100644 --- a/test/alg/prim-test.js +++ b/test/alg/prim-test.js @@ -1,4 +1,3 @@ -var expect = require("../chai").expect; var Graph = require("../..").Graph; var prim = require("../..").alg.prim; @@ -7,8 +6,8 @@ describe("alg.prim", function() { var source = new Graph(); var g = prim(source, weightFn(source)); - expect(g.nodeCount()).to.equal(0); - expect(g.edgeCount()).to.equal(0); + expect(g.nodeCount()).toBe(0); + expect(g.edgeCount()).toBe(0); }); it("returns a single node graph for a graph with a single node", function() { @@ -16,8 +15,8 @@ describe("alg.prim", function() { source.setNode("a"); var g = prim(source, weightFn(source)); - expect(g.nodes()).to.eql(["a"]); - expect(g.edgeCount()).to.equal(0); + expect(g.nodes()).toEqual(["a"]); + expect(g.edgeCount()).toBe(0); }); it("returns a deterministic result given an optimal solution", function() { @@ -32,11 +31,11 @@ describe("alg.prim", function() { source.setEdge("d", "e", 1); var g = prim(source, weightFn(source)); - expect(g.neighbors("a").sort()).to.eql(["b"]); - expect(g.neighbors("b").sort()).to.eql(["a", "c", "d"]); - expect(g.neighbors("c").sort()).to.eql(["b"]); - expect(g.neighbors("d").sort()).to.eql(["b", "e"]); - expect(g.neighbors("e").sort()).to.eql(["d"]); + expect(g.neighbors("a").sort()).toEqual(["b"]); + expect(g.neighbors("b").sort()).toEqual(["a", "c", "d"]); + expect(g.neighbors("c").sort()).toEqual(["b"]); + expect(g.neighbors("d").sort()).toEqual(["b", "e"]); + expect(g.neighbors("e").sort()).toEqual(["d"]); }); it("throws an Error for unconnected graphs", function() { @@ -44,7 +43,7 @@ describe("alg.prim", function() { source.setNode("a"); source.setNode("b"); - expect(function() { prim(source, weightFn(source)); }).to.throw(); + expect(function() { prim(source, weightFn(source)); }).toThrow(); }); }); diff --git a/test/alg/tarjan-test.js b/test/alg/tarjan-test.js index d779d01e..3ab6f319 100644 --- a/test/alg/tarjan-test.js +++ b/test/alg/tarjan-test.js @@ -1,29 +1,28 @@ -var expect = require("../chai").expect; var Graph = require("../..").Graph; var tarjan = require("../..").alg.tarjan; describe("alg.tarjan", function() { it("returns an empty array for an empty graph", function() { - expect(tarjan(new Graph())).to.eql([]); + expect(tarjan(new Graph())).toEqual([]); }); it("returns singletons for nodes not in a strongly connected component", function() { var g = new Graph(); g.setPath(["a", "b", "c"]); g.setEdge("d", "c"); - expect(sort(tarjan(g))).to.eql([["a"], ["b"], ["c"], ["d"]]); + expect(sort(tarjan(g))).toEqual([["a"], ["b"], ["c"], ["d"]]); }); it("returns a single component for a cycle of 1 edge", function() { var g = new Graph(); g.setPath(["a", "b", "a"]); - expect(sort(tarjan(g))).to.eql([["a", "b"]]); + expect(sort(tarjan(g))).toEqual([["a", "b"]]); }); it("returns a single component for a triangle", function() { var g = new Graph(); g.setPath(["a", "b", "c", "a"]); - expect(sort(tarjan(g))).to.eql([["a", "b", "c"]]); + expect(sort(tarjan(g))).toEqual([["a", "b", "c"]]); }); it("can find multiple components", function() { @@ -31,7 +30,7 @@ describe("alg.tarjan", function() { g.setPath(["a", "b", "a"]); g.setPath(["c", "d", "e", "c"]); g.setNode("f"); - expect(sort(tarjan(g))).to.eql([["a", "b"], ["c", "d", "e"], ["f"]]); + expect(sort(tarjan(g))).toEqual([["a", "b"], ["c", "d", "e"], ["f"]]); }); }); diff --git a/test/alg/topsort-test.js b/test/alg/topsort-test.js index 5a417772..c545ea20 100644 --- a/test/alg/topsort-test.js +++ b/test/alg/topsort-test.js @@ -1,16 +1,15 @@ -var expect = require("../chai").expect; var Graph = require("../..").Graph; var topsort = require("../..").alg.topsort; describe("alg.topsort", function() { it("returns an empty array for an empty graph", function() { - expect(topsort(new Graph())).to.be.empty; + expect(topsort(new Graph())).toHaveLength(0); }); it("sorts nodes such that earlier nodes have directed edges to later nodes", function() { var g = new Graph(); g.setPath(["b", "c", "a"]); - expect(topsort(g)).to.eql(["b", "c", "a"]); + expect(topsort(g)).toEqual(["b", "c", "a"]); }); it("works for a diamond", function() { @@ -19,29 +18,29 @@ describe("alg.topsort", function() { g.setPath(["a", "c", "d"]); var result = topsort(g); - expect(result.indexOf("a")).to.equal(0); - expect(result.indexOf("b")).to.be.lt(result.indexOf("d")); - expect(result.indexOf("c")).to.be.lt(result.indexOf("d")); - expect(result.indexOf("d")).to.equal(3); + expect(result.indexOf("a")).toBe(0); + expect(result.indexOf("b")).toBeLessThan(result.indexOf("d")); + expect(result.indexOf("c")).toBeLessThan(result.indexOf("d")); + expect(result.indexOf("d")).toBe(3); }); it("throws CycleException if there is a cycle #1", function() { var g = new Graph(); g.setPath(["b", "c", "a", "b"]); - expect(function() { topsort(g); }).to.throw(topsort.CycleException); + expect(function() { topsort(g); }).toThrow(topsort.CycleException); }); it("throws CycleException if there is a cycle #2", function() { var g = new Graph(); g.setPath(["b", "c", "a", "b"]); g.setEdge("b", "d"); - expect(function() { topsort(g); }).to.throw(topsort.CycleException); + expect(function() { topsort(g); }).toThrow(topsort.CycleException); }); it("throws CycleException if there is a cycle #3", function() { var g = new Graph(); g.setPath(["b", "c", "a", "b"]); g.setNode("d"); - expect(function() { topsort(g); }).to.throw(topsort.CycleException); + expect(function() { topsort(g); }).toThrow(topsort.CycleException); }); }); diff --git a/test/alg/all-shortest-paths-test.js b/test/alg/utils/all-shortest-paths-test.js similarity index 92% rename from test/alg/all-shortest-paths-test.js rename to test/alg/utils/all-shortest-paths-test.js index 956a9326..bf04d359 100644 --- a/test/alg/all-shortest-paths-test.js +++ b/test/alg/utils/all-shortest-paths-test.js @@ -1,5 +1,4 @@ -var expect = require("../chai").expect; -var Graph = require("../..").Graph; +var Graph = require("../../..").Graph; exports.tests = tests; @@ -8,14 +7,14 @@ function tests(sp) { it("returns 0 for the node itself", function() { var g = new Graph(); g.setNode("a"); - expect(sp(g)).to.eql({ a: { a: { distance: 0 } }}); + expect(sp(g)).toEqual({ a: { a: { distance: 0 } }}); }); it("returns the distance and path from all nodes to other nodes", function() { var g = new Graph(); g.setEdge("a", "b"); g.setEdge("b", "c"); - expect(sp(g)).to.eql({ + expect(sp(g)).toEqual({ a: { a: { distance: 0 }, b: { distance: 1, predecessor: "a" }, @@ -39,7 +38,7 @@ function tests(sp) { g.setEdge("a", "b", 2); g.setEdge("b", "c", 3); - expect(sp(g, weightFn(g))).to.eql({ + expect(sp(g, weightFn(g))).toEqual({ a: { a: { distance: 0 }, b: { distance: 2, predecessor: "a" }, @@ -63,7 +62,7 @@ function tests(sp) { g.setEdge("a", "b"); g.setEdge("b", "c"); - expect(sp(g, undefined, function(v) { return g.inEdges(v); })).to.eql({ + expect(sp(g, undefined, function(v) { return g.inEdges(v); })).toEqual({ a: { a: { distance: 0 }, b: { distance: Number.POSITIVE_INFINITY }, @@ -89,7 +88,7 @@ function tests(sp) { g.setEdge("c", "a", 4); g.setEdge("b", "d", 6); - expect(sp(g, weightFn(g), g.nodeEdges.bind(g))).to.eql({ + expect(sp(g, weightFn(g), g.nodeEdges.bind(g))).toEqual({ a: { a: { distance: 0 }, b: { distance: 1, predecessor: "a" }, diff --git a/test/bundle-test.js b/test/bundle-test.js index d9e3aa89..57617548 100644 --- a/test/bundle-test.js +++ b/test/bundle-test.js @@ -1,17 +1,15 @@ -/* global chai, graphlib */ +const graphlib = require(".."); // These are smoke tests to make sure the bundles look like they are working // correctly. -var expect = chai.expect; - describe("bundle", function() { it("exports graphlib", function() { - expect(graphlib).to.be.an("object"); - expect(graphlib.Graph).to.be.a("function"); - expect(graphlib.json).to.be.a("object"); - expect(graphlib.alg).to.be.a("object"); - expect(graphlib.version).to.be.a("string"); + expect(graphlib).toBeInstanceOf(Object); + expect(graphlib.Graph).toBeInstanceOf(Function); + expect(graphlib.json).toBeInstanceOf(Object); + expect(graphlib.alg).toBeInstanceOf(Object); + expect(typeof graphlib.version).toBe("string"); }); it("can do simple graph operations", function() { @@ -19,9 +17,9 @@ describe("bundle", function() { g.setNode("a"); g.setNode("b"); g.setEdge("a", "b"); - expect(g.hasNode("a")).to.be.true; - expect(g.hasNode("b")).to.be.true; - expect(g.hasEdge("a", "b")).to.be.true; + expect(g.hasNode("a")).toBe(true); + expect(g.hasNode("b")).toBe(true); + expect(g.hasEdge("a", "b")).toBe(true); }); it("can serialize to json and back", function() { @@ -32,8 +30,8 @@ describe("bundle", function() { var json = graphlib.json.write(g); var g2 = graphlib.json.read(json); - expect(g2.hasNode("a")).to.be.true; - expect(g2.hasNode("b")).to.be.true; - expect(g2.hasEdge("a", "b")).to.be.true; + expect(g2.hasNode("a")).toBe(true); + expect(g2.hasNode("b")).toBe(true); + expect(g2.hasEdge("a", "b")).toBe(true); }); }); diff --git a/test/chai.js b/test/chai.js deleted file mode 100644 index ba88ca65..00000000 --- a/test/chai.js +++ /dev/null @@ -1,5 +0,0 @@ -var chai = require("chai"); - -module.exports = chai; - -chai.config.includeStack = true; diff --git a/test/data/priority-queue-test.js b/test/data/priority-queue-test.js index b7193441..5345a21b 100644 --- a/test/data/priority-queue-test.js +++ b/test/data/priority-queue-test.js @@ -1,4 +1,3 @@ -var expect = require("../chai").expect; var PriorityQueue = require("../../lib/data/priority-queue"); describe("data.PriorityQueue", function() { @@ -10,14 +9,14 @@ describe("data.PriorityQueue", function() { describe("size", function() { it("returns 0 for an empty queue", function() { - expect(pq.size()).to.equal(0); + expect(pq.size()).toBe(0); }); it("returns the number of elements in the queue", function() { pq.add("a", 1); - expect(pq.size()).to.equal(1); + expect(pq.size()).toBe(1); pq.add("b", 2); - expect(pq.size()).to.equal(2); + expect(pq.size()).toBe(2); }); }); @@ -28,19 +27,18 @@ describe("data.PriorityQueue", function() { pq.add(false, 3); pq.add(undefined, 4); pq.add(null, 5); - expect(pq.keys().sort()).to.eql( - ["a", "1", "false", "undefined", "null"].sort()); + expect(pq.keys().sort()).toEqual(["a", "1", "false", "undefined", "null"].sort()); }); }); describe("has", function() { it("returns true if the key is in the queue", function() { pq.add("a", 1); - expect(pq.has("a")).to.be.true; + expect(pq.has("a")).toBe(true); }); it("returns false if the key is not in the queue", function() { - expect(pq.has("a")).to.be.false; + expect(pq.has("a")).toBe(false); }); }); @@ -48,47 +46,47 @@ describe("data.PriorityQueue", function() { it("returns the current priority for the key", function() { pq.add("a", 1); pq.add("b", 2); - expect(pq.priority("a")).to.equal(1); - expect(pq.priority("b")).to.equal(2); + expect(pq.priority("a")).toBe(1); + expect(pq.priority("b")).toBe(2); }); it("returns undefined if the key is not in the queue", function() { - expect(pq.priority("foo")).to.be.undefined; + expect(pq.priority("foo")).toBeUndefined(); }); }); describe("min", function() { it("throws an error if there is no element in the queue", function() { - expect(function() { pq.min(); }).to.throw(); + expect(function() { pq.min(); }).toThrow(); }); it("returns the smallest element", function() { pq.add("b", 2); pq.add("a", 1); - expect(pq.min()).to.equal("a"); + expect(pq.min()).toBe("a"); }); it("does not remove the minimum element from the queue", function() { pq.add("b", 2); pq.add("a", 1); pq.min(); - expect(pq.size()).to.equal(2); + expect(pq.size()).toBe(2); }); }); describe("add", function() { it("adds the key to the queue", function() { pq.add("a", 1); - expect(pq.keys()).to.eql(["a"]); + expect(pq.keys()).toEqual(["a"]); }); it("returns true if the key was added", function() { - expect(pq.add("a", 1)).to.be.true; + expect(pq.add("a", 1)).toBe(true); }); it("returns false if the key already exists in the queue", function() { pq.add("a", 1); - expect(pq.add("a", 1)).to.be.false; + expect(pq.add("a", 1)).toBe(false); }); }); @@ -99,15 +97,15 @@ describe("data.PriorityQueue", function() { pq.add("c", 3); pq.add("e", 5); pq.add("d", 4); - expect(pq.removeMin()).to.equal("a"); - expect(pq.removeMin()).to.equal("b"); - expect(pq.removeMin()).to.equal("c"); - expect(pq.removeMin()).to.equal("d"); - expect(pq.removeMin()).to.equal("e"); + expect(pq.removeMin()).toBe("a"); + expect(pq.removeMin()).toBe("b"); + expect(pq.removeMin()).toBe("c"); + expect(pq.removeMin()).toBe("d"); + expect(pq.removeMin()).toBe("e"); }); it("throws an error if there is no element in the queue", function() { - expect(function() { pq.removeMin(); }).to.throw(); + expect(function() { pq.removeMin(); }).toThrow(); }); }); @@ -115,16 +113,16 @@ describe("data.PriorityQueue", function() { it("decreases the priority of a key", function() { pq.add("a", 1); pq.decrease("a", -1); - expect(pq.priority("a")).to.equal(-1); + expect(pq.priority("a")).toBe(-1); }); it("raises an error if the key is not in the queue", function() { - expect(function() { pq.decrease("a", -1); }).to.throw(); + expect(function() { pq.decrease("a", -1); }).toThrow(); }); it("raises an error if the new priority is greater than current", function() { pq.add("a", 1); - expect(function() { pq.decrease("a", 2); }).to.throw(); + expect(function() { pq.decrease("a", 2); }).toThrow(); }); }); }); diff --git a/test/graph-test.js b/test/graph-test.js index bdd163a9..0aec215e 100644 --- a/test/graph-test.js +++ b/test/graph-test.js @@ -1,4 +1,3 @@ -var expect = require("./chai").expect; var Graph = require("..").Graph; describe("Graph", function() { @@ -10,65 +9,65 @@ describe("Graph", function() { describe("initial state", function() { it("has no nodes", function() { - expect(g.nodeCount()).to.equal(0); + expect(g.nodeCount()).toBe(0); }); it("has no edges", function() { - expect(g.edgeCount()).to.equal(0); + expect(g.edgeCount()).toBe(0); }); it("has no attributes", function() { - expect(g.graph()).to.be.undefined; + expect(g.graph()).toBeUndefined(); }); it("defaults to a simple directed graph", function() { - expect(g.isDirected()).to.be.true; - expect(g.isCompound()).to.be.false; - expect(g.isMultigraph()).to.be.false; + expect(g.isDirected()).toBe(true); + expect(g.isCompound()).toBe(false); + expect(g.isMultigraph()).toBe(false); }); it("can be set to undirected", function() { var g = new Graph({ directed: false }); - expect(g.isDirected()).to.be.false; - expect(g.isCompound()).to.be.false; - expect(g.isMultigraph()).to.be.false; + expect(g.isDirected()).toBe(false); + expect(g.isCompound()).toBe(false); + expect(g.isMultigraph()).toBe(false); }); it("can be set to a compound graph", function() { var g = new Graph({ compound: true }); - expect(g.isDirected()).to.be.true; - expect(g.isCompound()).to.be.true; - expect(g.isMultigraph()).to.be.false; + expect(g.isDirected()).toBe(true); + expect(g.isCompound()).toBe(true); + expect(g.isMultigraph()).toBe(false); }); it("can be set to a mulitgraph", function() { var g = new Graph({ multigraph: true }); - expect(g.isDirected()).to.be.true; - expect(g.isCompound()).to.be.false; - expect(g.isMultigraph()).to.be.true; + expect(g.isDirected()).toBe(true); + expect(g.isCompound()).toBe(false); + expect(g.isMultigraph()).toBe(true); }); }); describe("setGraph", function() { it("can be used to get and set properties for the graph", function() { g.setGraph("foo"); - expect(g.graph()).to.equal("foo"); + expect(g.graph()).toBe("foo"); }); it("is chainable", function() { - expect(g.setGraph("foo")).to.equal(g); + expect(g.setGraph("foo")).toBe(g); }); }); describe("nodes", function() { it("is empty if there are no nodes in the graph", function() { - expect(g.nodes()).to.eql([]); + expect(g.nodes()).toEqual([]); }); it("returns the ids of nodes in the graph", function() { g.setNode("a"); g.setNode("b"); - expect(g.nodes().sort()).to.eql(["a", "b"]); + expect(g.nodes().sort()).toEqual(["a", "b"]); }); }); @@ -76,7 +75,7 @@ describe("Graph", function() { it("returns nodes in the graph that have no in-edges", function() { g.setPath(["a", "b", "c"]); g.setNode("d"); - expect(g.sources().sort()).to.eql(["a", "d"]); + expect(g.sources().sort()).toEqual(["a", "d"]); }); }); @@ -84,7 +83,7 @@ describe("Graph", function() { it("returns nodes in the graph that have no out-edges", function() { g.setPath(["a", "b", "c"]); g.setNode("d"); - expect(g.sinks().sort()).to.eql(["c", "d"]); + expect(g.sinks().sort()).toEqual(["c", "d"]); }); }); @@ -95,56 +94,56 @@ describe("Graph", function() { g.setPath(["a", "b", "c"]); g.setEdge("a", "c", 456); var g2 = g.filterNodes(function() { return true; }); - expect(g2.nodes().sort()).eqls(["a", "b", "c"]); - expect(g2.successors("a").sort()).eqls(["b", "c"]); - expect(g2.successors("b").sort()).eqls(["c"]); - expect(g2.node("a")).eqls(123); - expect(g2.edge("a", "c")).eqls(456); - expect(g2.graph()).eqls("graph label"); + expect(g2.nodes().sort()).toEqual(["a", "b", "c"]); + expect(g2.successors("a").sort()).toEqual(["b", "c"]); + expect(g2.successors("b").sort()).toEqual(["c"]); + expect(g2.node("a")).toEqual(123); + expect(g2.edge("a", "c")).toEqual(456); + expect(g2.graph()).toEqual("graph label"); }); it("returns an empty graph when the filter selects nothing", function() { g.setPath(["a", "b", "c"]); var g2 = g.filterNodes(function() { return false; }); - expect(g2.nodes()).eqls([]); - expect(g2.edges()).eqls([]); + expect(g2.nodes()).toEqual([]); + expect(g2.edges()).toEqual([]); }); it("only includes nodes for which the filter returns true", function() { g.setNodes(["a", "b"]); var g2 = g.filterNodes(function(v) { return v === "a"; }); - expect(g2.nodes()).eqls(["a"]); + expect(g2.nodes()).toEqual(["a"]); }); it("removes edges that are connected to removed nodes", function() { g.setEdge("a", "b"); var g2 = g.filterNodes(function(v) { return v === "a"; }); - expect(g2.nodes().sort()).eqls(["a"]); - expect(g2.edges()).eqls([]); + expect(g2.nodes().sort()).toEqual(["a"]); + expect(g2.edges()).toEqual([]); }); it("preserves the directed option", function() { g = new Graph({ directed: true }); - expect(g.filterNodes(function() { return true; }).isDirected()).to.be.true; + expect(g.filterNodes(function() { return true; }).isDirected()).toBe(true); g = new Graph({ directed: false }); - expect(g.filterNodes(function() { return true; }).isDirected()).to.be.false; + expect(g.filterNodes(function() { return true; }).isDirected()).toBe(false); }); it("preserves the multigraph option", function() { g = new Graph({ multigraph: true }); - expect(g.filterNodes(function() { return true; }).isMultigraph()).to.be.true; + expect(g.filterNodes(function() { return true; }).isMultigraph()).toBe(true); g = new Graph({ multigraph: false }); - expect(g.filterNodes(function() { return true; }).isMultigraph()).to.be.false; + expect(g.filterNodes(function() { return true; }).isMultigraph()).toBe(false); }); it("preserves the compound option", function() { g = new Graph({ compound: true }); - expect(g.filterNodes(function() { return true; }).isCompound()).to.be.true; + expect(g.filterNodes(function() { return true; }).isCompound()).toBe(true); g = new Graph({ compound: false }); - expect(g.filterNodes(function() { return true; }).isCompound()).to.be.false; + expect(g.filterNodes(function() { return true; }).isCompound()).toBe(false); }); it("includes subgraphs", function() { @@ -152,7 +151,7 @@ describe("Graph", function() { g.setParent("a", "parent"); var g2 = g.filterNodes(function() { return true; }); - expect(g2.parent("a")).eqls("parent"); + expect(g2.parent("a")).toEqual("parent"); }); it("includes multi-level subgraphs", function() { @@ -161,8 +160,8 @@ describe("Graph", function() { g.setParent("parent", "root"); var g2 = g.filterNodes(function() { return true; }); - expect(g2.parent("a")).eqls("parent"); - expect(g2.parent("parent")).eqls("root"); + expect(g2.parent("a")).toEqual("parent"); + expect(g2.parent("parent")).toEqual("root"); }); it("promotes a node to a higher subgraph if its parent is not included", function() { @@ -171,70 +170,70 @@ describe("Graph", function() { g.setParent("parent", "root"); var g2 = g.filterNodes(function(v) { return v !== "parent"; }); - expect(g2.parent("a")).eqls("root"); + expect(g2.parent("a")).toEqual("root"); }); }); describe("setNodes", function() { it("creates multiple nodes", function() { g.setNodes(["a", "b", "c"]); - expect(g.hasNode("a")).to.be.true; - expect(g.hasNode("b")).to.be.true; - expect(g.hasNode("c")).to.be.true; + expect(g.hasNode("a")).toBe(true); + expect(g.hasNode("b")).toBe(true); + expect(g.hasNode("c")).toBe(true); }); it("can set a value for all of the nodes", function() { g.setNodes(["a", "b", "c"], "foo"); - expect(g.node("a")).to.equal("foo"); - expect(g.node("b")).to.equal("foo"); - expect(g.node("c")).to.equal("foo"); + expect(g.node("a")).toBe("foo"); + expect(g.node("b")).toBe("foo"); + expect(g.node("c")).toBe("foo"); }); it("is chainable", function() { - expect(g.setNodes(["a", "b", "c"])).to.equal(g); + expect(g.setNodes(["a", "b", "c"])).toBe(g); }); }); describe("setNode", function() { it("creates the node if it isn't part of the graph", function() { g.setNode("a"); - expect(g.hasNode("a")).to.be.true; - expect(g.node("a")).to.be.undefined; - expect(g.nodeCount()).to.equal(1); + expect(g.hasNode("a")).toBe(true); + expect(g.node("a")).toBeUndefined(); + expect(g.nodeCount()).toBe(1); }); it("can set a value for the node", function() { g.setNode("a", "foo"); - expect(g.node("a")).to.equal("foo"); + expect(g.node("a")).toBe("foo"); }); it("does not change the node's value with a 1-arg invocation", function() { g.setNode("a", "foo"); g.setNode("a"); - expect(g.node("a")).to.equal("foo"); + expect(g.node("a")).toBe("foo"); }); it("can remove the node's value by passing undefined", function() { g.setNode("a", undefined); - expect(g.node("a")).to.be.undefined; + expect(g.node("a")).toBeUndefined(); }); it("is idempotent", function() { g.setNode("a", "foo"); g.setNode("a", "foo"); - expect(g.node("a")).to.equal("foo"); - expect(g.nodeCount()).to.equal(1); + expect(g.node("a")).toBe("foo"); + expect(g.nodeCount()).toBe(1); }); it("uses the stringified form of the id", function() { g.setNode(1); - expect(g.hasNode(1)).to.be.true; - expect(g.hasNode("1")).to.be.true; - expect(g.nodes()).eqls(["1"]); + expect(g.hasNode(1)).toBe(true); + expect(g.hasNode("1")).toBe(true); + expect(g.nodes()).toEqual(["1"]); }); it("is chainable", function() { - expect(g.setNode("a")).to.equal(g); + expect(g.setNode("a")).toBe(g); }); }); @@ -242,77 +241,77 @@ describe("Graph", function() { it("sets a default label for new nodes", function() { g.setDefaultNodeLabel("foo"); g.setNode("a"); - expect(g.node("a")).to.equal("foo"); + expect(g.node("a")).toBe("foo"); }); it("does not change existing nodes", function() { g.setNode("a"); g.setDefaultNodeLabel("foo"); - expect(g.node("a")).to.be.undefined; + expect(g.node("a")).toBeUndefined(); }); it("is not used if an explicit value is set", function() { g.setDefaultNodeLabel("foo"); g.setNode("a", "bar"); - expect(g.node("a")).to.equal("bar"); + expect(g.node("a")).toBe("bar"); }); it("can take a function", function() { g.setDefaultNodeLabel(function() { return "foo"; }); g.setNode("a"); - expect(g.node("a")).to.equal("foo"); + expect(g.node("a")).toBe("foo"); }); it("can take a function that takes the node's name", function() { g.setDefaultNodeLabel(function(v) { return v + "-foo"; }); g.setNode("a"); - expect(g.node("a")).to.equal("a-foo"); + expect(g.node("a")).toBe("a-foo"); }); it("is chainable", function() { - expect(g.setDefaultNodeLabel("foo")).to.equal(g); + expect(g.setDefaultNodeLabel("foo")).toBe(g); }); }); describe("node", function() { it("returns undefined if the node isn't part of the graph", function() { - expect(g.node("a")).to.be.undefined; + expect(g.node("a")).toBeUndefined(); }); it("returns the value of the node if it is part of the graph", function() { g.setNode("a", "foo"); - expect(g.node("a")).to.equal("foo"); + expect(g.node("a")).toBe("foo"); }); }); describe("removeNode", function() { it("does nothing if the node is not in the graph", function() { - expect(g.nodeCount()).to.equal(0); + expect(g.nodeCount()).toBe(0); g.removeNode("a"); - expect(g.hasNode("a")).to.be.false; - expect(g.nodeCount()).to.equal(0); + expect(g.hasNode("a")).toBe(false); + expect(g.nodeCount()).toBe(0); }); it("removes the node if it is in the graph", function() { g.setNode("a"); g.removeNode("a"); - expect(g.hasNode("a")).to.be.false; - expect(g.nodeCount()).to.equal(0); + expect(g.hasNode("a")).toBe(false); + expect(g.nodeCount()).toBe(0); }); it("is idempotent", function() { g.setNode("a"); g.removeNode("a"); g.removeNode("a"); - expect(g.hasNode("a")).to.be.false; - expect(g.nodeCount()).to.equal(0); + expect(g.hasNode("a")).toBe(false); + expect(g.nodeCount()).toBe(0); }); it("removes edges incident on the node", function() { g.setEdge("a", "b"); g.setEdge("b", "c"); g.removeNode("b"); - expect(g.edgeCount()).to.equal(0); + expect(g.edgeCount()).toBe(0); }); it("removes parent / child relationships for the node", function() { @@ -320,14 +319,14 @@ describe("Graph", function() { g.setParent("c", "b"); g.setParent("b", "a"); g.removeNode("b"); - expect(g.parent("b")).to.be.undefined; - expect(g.children("b")).to.be.undefined; - expect(g.children("a")).to.not.include("b"); - expect(g.parent("c")).to.be.undefined; + expect(g.parent("b")).toBeUndefined(); + expect(g.children("b")).toBeUndefined(); + expect(g.children("a")).not.toContain("b"); + expect(g.parent("c")).toBeUndefined(); }); it("is chainable", function() { - expect(g.removeNode("a")).to.equal(g); + expect(g.removeNode("a")).toBe(g); }); }); @@ -337,74 +336,74 @@ describe("Graph", function() { }); it("throws if the graph is not compound", function() { - expect(function() { new Graph().setParent("a", "parent"); }).to.throw(); + expect(function() { new Graph().setParent("a", "parent"); }).toThrow(); }); it("creates the parent if it does not exist", function() { g.setNode("a"); g.setParent("a", "parent"); - expect(g.hasNode("parent")).to.be.true; - expect(g.parent("a")).to.equal("parent"); + expect(g.hasNode("parent")).toBe(true); + expect(g.parent("a")).toBe("parent"); }); it("creates the child if it does not exist", function() { g.setNode("parent"); g.setParent("a", "parent"); - expect(g.hasNode("a")).to.be.true; - expect(g.parent("a")).to.equal("parent"); + expect(g.hasNode("a")).toBe(true); + expect(g.parent("a")).toBe("parent"); }); it("has the parent as undefined if it has never been invoked", function() { g.setNode("a"); - expect(g.parent("a")).to.be.undefined; + expect(g.parent("a")).toBeUndefined(); }); it("moves the node from the previous parent", function() { g.setParent("a", "parent"); g.setParent("a", "parent2"); - expect(g.parent("a")).to.equal("parent2"); - expect(g.children("parent")).to.eql([]); - expect(g.children("parent2")).to.eql(["a"]); + expect(g.parent("a")).toBe("parent2"); + expect(g.children("parent")).toEqual([]); + expect(g.children("parent2")).toEqual(["a"]); }); it("removes the parent if the parent is undefined", function() { g.setParent("a", "parent"); g.setParent("a", undefined); - expect(g.parent("a")).to.be.undefined; - expect(g.children().sort()).to.eql(["a", "parent"]); + expect(g.parent("a")).toBeUndefined(); + expect(g.children().sort()).toEqual(["a", "parent"]); }); it("removes the parent if no parent was specified", function() { g.setParent("a", "parent"); g.setParent("a"); - expect(g.parent("a")).to.be.undefined; - expect(g.children().sort()).to.eql(["a", "parent"]); + expect(g.parent("a")).toBeUndefined(); + expect(g.children().sort()).toEqual(["a", "parent"]); }); it("is idempotent to remove a parent", function() { g.setParent("a", "parent"); g.setParent("a"); g.setParent("a"); - expect(g.parent("a")).to.be.undefined; - expect(g.children().sort()).to.eql(["a", "parent"]); + expect(g.parent("a")).toBeUndefined(); + expect(g.children().sort()).toEqual(["a", "parent"]); }); it("uses the stringified form of the id", function() { g.setParent(2, 1); g.setParent(3, 2); - expect(g.parent(2)).equals("1"); - expect(g.parent("2")).equals("1"); - expect(g.parent(3)).equals("2"); + expect(g.parent(2)).toBe("1"); + expect(g.parent("2")).toBe("1"); + expect(g.parent(3)).toBe("2"); }); it("preserves the tree invariant", function() { g.setParent("c", "b"); g.setParent("b", "a"); - expect(function() { g.setParent("a", "c"); }).to.throw(); + expect(function() { g.setParent("a", "c"); }).toThrow(); }); it("is chainable", function() { - expect(g.setParent("a", "parent")).to.equal(g); + expect(g.setParent("a", "parent")).toBe(g); }); }); @@ -414,23 +413,23 @@ describe("Graph", function() { }); it("returns undefined if the graph is not compound", function() { - expect(new Graph({ compound: false }).parent("a")).to.be.undefined; + expect(new Graph({ compound: false }).parent("a")).toBeUndefined(); }); it("returns undefined if the node is not in the graph", function() { - expect(g.parent("a")).to.be.undefined; + expect(g.parent("a")).toBeUndefined(); }); it("defaults to undefined for new nodes", function() { g.setNode("a"); - expect(g.parent("a")).to.be.undefined; + expect(g.parent("a")).toBeUndefined(); }); it("returns the current parent assignment", function() { g.setNode("a"); g.setNode("parent"); g.setParent("a", "parent"); - expect(g.parent("a")).to.equal("parent"); + expect(g.parent("a")).toBe("parent"); }); }); @@ -440,36 +439,36 @@ describe("Graph", function() { }); it("returns undefined if the node is not in the graph", function() { - expect(g.children("a")).to.be.undefined; + expect(g.children("a")).toBeUndefined(); }); it("defaults to en empty list for new nodes", function() { g.setNode("a"); - expect(g.children("a")).to.eql([]); + expect(g.children("a")).toEqual([]); }); it("returns undefined for a non-compound graph without the node", function() { var g = new Graph(); - expect(g.children("a")).to.be.undefined; + expect(g.children("a")).toBeUndefined(); }); it("returns an empty list for a non-compound graph with the node", function() { var g = new Graph(); g.setNode("a"); - expect(g.children("a")).eqls([]); + expect(g.children("a")).toEqual([]); }); it ("returns all nodes for the root of a non-compound graph", function() { var g = new Graph(); g.setNode("a"); g.setNode("b"); - expect(g.children().sort()).eqls(["a", "b"]); + expect(g.children().sort()).toEqual(["a", "b"]); }); it("returns children for the node", function() { g.setParent("a", "parent"); g.setParent("b", "parent"); - expect(g.children("parent").sort()).to.eql(["a", "b"]); + expect(g.children("parent").sort()).toEqual(["a", "b"]); }); it("returns all nodes without a parent when the parent is not set", function() { @@ -478,53 +477,53 @@ describe("Graph", function() { g.setNode("c"); g.setNode("parent"); g.setParent("a", "parent"); - expect(g.children().sort()).to.eql(["b", "c", "parent"]); - expect(g.children(undefined).sort()).to.eql(["b", "c", "parent"]); + expect(g.children().sort()).toEqual(["b", "c", "parent"]); + expect(g.children(undefined).sort()).toEqual(["b", "c", "parent"]); }); }); describe("predecessors", function() { it("returns undefined for a node that is not in the graph", function() { - expect(g.predecessors("a")).to.be.undefined; + expect(g.predecessors("a")).toBeUndefined(); }); it("returns the predecessors of a node", function() { g.setEdge("a", "b"); g.setEdge("b", "c"); g.setEdge("a", "a"); - expect(g.predecessors("a").sort()).to.eql(["a"]); - expect(g.predecessors("b").sort()).to.eql(["a"]); - expect(g.predecessors("c").sort()).to.eql(["b"]); + expect(g.predecessors("a").sort()).toEqual(["a"]); + expect(g.predecessors("b").sort()).toEqual(["a"]); + expect(g.predecessors("c").sort()).toEqual(["b"]); }); }); describe("successors", function() { it("returns undefined for a node that is not in the graph", function() { - expect(g.successors("a")).to.be.undefined; + expect(g.successors("a")).toBeUndefined(); }); it("returns the successors of a node", function() { g.setEdge("a", "b"); g.setEdge("b", "c"); g.setEdge("a", "a"); - expect(g.successors("a").sort()).to.eql(["a", "b"]); - expect(g.successors("b").sort()).to.eql(["c"]); - expect(g.successors("c").sort()).to.eql([]); + expect(g.successors("a").sort()).toEqual(["a", "b"]); + expect(g.successors("b").sort()).toEqual(["c"]); + expect(g.successors("c").sort()).toEqual([]); }); }); describe("neighbors", function() { it("returns undefined for a node that is not in the graph", function() { - expect(g.neighbors("a")).to.be.undefined; + expect(g.neighbors("a")).toBeUndefined(); }); it("returns the neighbors of a node", function() { g.setEdge("a", "b"); g.setEdge("b", "c"); g.setEdge("a", "a"); - expect(g.neighbors("a").sort()).to.eql(["a", "b"]); - expect(g.neighbors("b").sort()).to.eql(["a", "c"]); - expect(g.neighbors("c").sort()).to.eql(["b"]); + expect(g.neighbors("a").sort()).toEqual(["a", "b"]); + expect(g.neighbors("b").sort()).toEqual(["a", "c"]); + expect(g.neighbors("c").sort()).toEqual(["b"]); }); }); @@ -534,40 +533,40 @@ describe("Graph", function() { g.setNode("a"); g.setNode("b"); g.setEdge("a", "b"); - expect(g.isLeaf("b")).to.be.false; + expect(g.isLeaf("b")).toBe(false); }); it("returns true for an unconnected node in undirected graph", function() { g = new Graph({directed: false}); g.setNode("a"); - expect(g.isLeaf("a")).to.be.true; + expect(g.isLeaf("a")).toBe(true); }); it("returns true for unconnected node in directed graph", function() { g.setNode("a"); - expect(g.isLeaf("a")).to.be.true; + expect(g.isLeaf("a")).toBe(true); }); it("returns false for predecessor node in directed graph", function() { g.setNode("a"); g.setNode("b"); g.setEdge("a", "b"); - expect(g.isLeaf("a")).to.be.false; + expect(g.isLeaf("a")).toBe(false); }); it("returns true for successor node in directed graph", function() { g.setNode("a"); g.setNode("b"); g.setEdge("a", "b"); - expect(g.isLeaf("b")).to.be.true; + expect(g.isLeaf("b")).toBe(true); }); }); describe("edges", function() { it("is empty if there are no edges in the graph", function() { - expect(g.edges()).to.eql([]); + expect(g.edges()).toEqual([]); }); it("returns the keys for edges in the graph", function() { g.setEdge("a", "b"); g.setEdge("b", "c"); - expect(g.edges().sort(sortEdges)).to.eql([ + expect(g.edges().sort(sortEdges)).toEqual([ { v: "a", w: "b" }, { v: "b", w: "c" } ]); @@ -577,18 +576,18 @@ describe("Graph", function() { describe("setPath", function() { it("creates a path of mutiple edges", function() { g.setPath(["a", "b", "c"]); - expect(g.hasEdge("a", "b")).to.be.true; - expect(g.hasEdge("b", "c")).to.be.true; + expect(g.hasEdge("a", "b")).toBe(true); + expect(g.hasEdge("b", "c")).toBe(true); }); it("can set a value for all of the edges", function() { g.setPath(["a", "b", "c"], "foo"); - expect(g.edge("a", "b")).to.equal("foo"); - expect(g.edge("b", "c")).to.equal("foo"); + expect(g.edge("a", "b")).toBe("foo"); + expect(g.edge("b", "c")).toBe("foo"); }); it("is chainable", function() { - expect(g.setPath(["a", "b", "c"])).to.equal(g); + expect(g.setPath(["a", "b", "c"])).toBe(g); }); }); @@ -597,114 +596,114 @@ describe("Graph", function() { g.setNode("a"); g.setNode("b"); g.setEdge("a", "b"); - expect(g.edge("a", "b")).to.be.undefined; - expect(g.hasEdge("a", "b")).to.be.true; - expect(g.hasEdge({ v: "a", w: "b" })).to.be.true; - expect(g.edgeCount()).to.equal(1); + expect(g.edge("a", "b")).toBeUndefined(); + expect(g.hasEdge("a", "b")).toBe(true); + expect(g.hasEdge({ v: "a", w: "b" })).toBe(true); + expect(g.edgeCount()).toBe(1); }); it("creates the nodes for the edge if they are not part of the graph", function() { g.setEdge("a", "b"); - expect(g.hasNode("a")).to.be.true; - expect(g.hasNode("b")).to.be.true; - expect(g.nodeCount()).to.equal(2); + expect(g.hasNode("a")).toBe(true); + expect(g.hasNode("b")).toBe(true); + expect(g.nodeCount()).toBe(2); }); it("creates a multi-edge if if it isn't part of the graph", function() { var g = new Graph({ multigraph: true }); g.setEdge("a", "b", undefined, "name"); - expect(g.hasEdge("a", "b")).to.be.false; - expect(g.hasEdge("a", "b", "name")).to.be.true; + expect(g.hasEdge("a", "b")).toBe(false); + expect(g.hasEdge("a", "b", "name")).toBe(true); }); it("throws if a multi-edge is used with a non-multigraph", function() { - expect(function() { g.setEdge("a", "b", undefined, "name"); }).to.throw(); + expect(function() { g.setEdge("a", "b", undefined, "name"); }).toThrow(); }); it("changes the value for an edge if it is already in the graph", function() { g.setEdge("a", "b", "foo"); g.setEdge("a", "b", "bar"); - expect(g.edge("a", "b")).to.equal("bar"); + expect(g.edge("a", "b")).toBe("bar"); }); it ("deletes the value for the edge if the value arg is undefined", function() { g.setEdge("a", "b", "foo"); g.setEdge("a", "b", undefined); - expect(g.edge("a", "b")).to.be.undefined; - expect(g.hasEdge("a", "b")).to.be.true; + expect(g.edge("a", "b")).toBeUndefined(); + expect(g.hasEdge("a", "b")).toBe(true); }); it("changes the value for a multi-edge if it is already in the graph", function() { var g = new Graph({ multigraph: true }); g.setEdge("a", "b", "value", "name"); g.setEdge("a", "b", undefined, "name"); - expect(g.edge("a", "b", "name")).to.be.undefined; - expect(g.hasEdge("a", "b", "name")).to.be.true; + expect(g.edge("a", "b", "name")).toBeUndefined(); + expect(g.hasEdge("a", "b", "name")).toBe(true); }); it("can take an edge object as the first parameter", function() { g.setEdge({ v: "a", w: "b" }, "value"); - expect(g.edge("a", "b")).to.equal("value"); + expect(g.edge("a", "b")).toBe("value"); }); it("can take an multi-edge object as the first parameter", function() { var g = new Graph({ multigraph: true }); g.setEdge({ v: "a", w: "b", name: "name" }, "value"); - expect(g.edge("a", "b", "name")).to.equal("value"); + expect(g.edge("a", "b", "name")).toBe("value"); }); it("uses the stringified form of the id #1", function() { g.setEdge(1, 2, "foo"); - expect(g.edges()).eqls([{ v: "1", w: "2" }]); - expect(g.edge("1", "2")).to.equal("foo"); - expect(g.edge(1, 2)).to.equal("foo"); - expect(g.edgeAsObj(1, 2)).to.eql({label: "foo"}); + expect(g.edges()).toEqual([{ v: "1", w: "2" }]); + expect(g.edge("1", "2")).toBe("foo"); + expect(g.edge(1, 2)).toBe("foo"); + expect(g.edgeAsObj(1, 2)).toEqual({label: "foo"}); }); it("uses the stringified form of the id #2", function() { g = new Graph({ multigraph: true }); g.setEdge(1, 2, "foo", undefined); - expect(g.edges()).eqls([{ v: "1", w: "2" }]); - expect(g.edge("1", "2")).to.equal("foo"); - expect(g.edge(1, 2)).to.equal("foo"); - expect(g.edgeAsObj(1, 2)).to.eql({label: "foo"}); + expect(g.edges()).toEqual([{ v: "1", w: "2" }]); + expect(g.edge("1", "2")).toBe("foo"); + expect(g.edge(1, 2)).toBe("foo"); + expect(g.edgeAsObj(1, 2)).toEqual({label: "foo"}); }); it("uses the stringified form of the id with a name", function() { g = new Graph({ multigraph: true }); g.setEdge(1, 2, "foo", 3); - expect(g.edge("1", "2", "3")).to.equal("foo"); - expect(g.edge(1, 2, 3)).to.equal("foo"); - expect(g.edgeAsObj(1, 2, 3)).to.eql({label: "foo"}); - expect(g.edges()).eqls([{ v: "1", w: "2", name: "3" }]); + expect(g.edge("1", "2", "3")).toBe("foo"); + expect(g.edge(1, 2, 3)).toBe("foo"); + expect(g.edgeAsObj(1, 2, 3)).toEqual({label: "foo"}); + expect(g.edges()).toEqual([{ v: "1", w: "2", name: "3" }]); }); it("treats edges in opposite directions as distinct in a digraph", function() { g.setEdge("a", "b"); - expect(g.hasEdge("a", "b")).to.be.true; - expect(g.hasEdge("b", "a")).to.be.false; + expect(g.hasEdge("a", "b")).toBe(true); + expect(g.hasEdge("b", "a")).toBe(false); }); it("handles undirected graph edges", function() { var g = new Graph({ directed: false }); g.setEdge("a", "b", "foo"); - expect(g.edge("a", "b")).to.equal("foo"); - expect(g.edge("b", "a")).to.equal("foo"); + expect(g.edge("a", "b")).toBe("foo"); + expect(g.edge("b", "a")).toBe("foo"); }); it("handles undirected edges where id has different order than Stringified id", function() { var g = new Graph({ directed: false }); g.setEdge(9, 10, "foo"); - expect(g.hasEdge("9", "10")).to.be.true; - expect(g.hasEdge(9, 10)).to.be.true; - expect(g.hasEdge("10", "9")).to.be.true; - expect(g.hasEdge(10, 9)).to.be.true; - expect(g.edge("9", "10")).eqls("foo"); - expect(g.edge(9, 10)).eqls("foo"); + expect(g.hasEdge("9", "10")).toBe(true); + expect(g.hasEdge(9, 10)).toBe(true); + expect(g.hasEdge("10", "9")).toBe(true); + expect(g.hasEdge(10, 9)).toBe(true); + expect(g.edge("9", "10")).toEqual("foo"); + expect(g.edge(9, 10)).toEqual("foo"); }); it("is chainable", function() { - expect(g.setEdge("a", "b")).to.equal(g); + expect(g.setEdge("a", "b")).toBe(g); }); }); @@ -712,25 +711,25 @@ describe("Graph", function() { it("sets a default label for new edges", function() { g.setDefaultEdgeLabel("foo"); g.setEdge("a", "b"); - expect(g.edge("a", "b")).to.equal("foo"); + expect(g.edge("a", "b")).toBe("foo"); }); it("does not change existing edges", function() { g.setEdge("a", "b"); g.setDefaultEdgeLabel("foo"); - expect(g.edge("a", "b")).to.be.undefined; + expect(g.edge("a", "b")).toBeUndefined(); }); it("is not used if an explicit value is set", function() { g.setDefaultEdgeLabel("foo"); g.setEdge("a", "b", "bar"); - expect(g.edge("a", "b")).to.equal("bar"); + expect(g.edge("a", "b")).toBe("bar"); }); it("can take a function", function() { g.setDefaultEdgeLabel(function() { return "foo"; }); g.setEdge("a", "b"); - expect(g.edge("a", "b")).to.equal("foo"); + expect(g.edge("a", "b")).toBe("foo"); }); it("can take a function that takes the edge's endpoints and name", function() { @@ -739,7 +738,7 @@ describe("Graph", function() { return v + "-" + w + "-" + name + "-foo"; }); g.setEdge({ v: "a", w: "b", name: "name"}); - expect(g.edge("a", "b", "name")).to.equal("a-b-name-foo"); + expect(g.edge("a", "b", "name")).toBe("a-b-name-foo"); }); it("does not set a default value for a multi-edge that already exists", function() { @@ -747,80 +746,80 @@ describe("Graph", function() { g.setEdge("a", "b", "old", "name"); g.setDefaultEdgeLabel(function() { return "should not set this"; }); g.setEdge({ v: "a", w: "b", name: "name"}); - expect(g.edge("a", "b", "name")).to.equal("old"); + expect(g.edge("a", "b", "name")).toBe("old"); }); it("is chainable", function() { - expect(g.setDefaultEdgeLabel("foo")).to.equal(g); + expect(g.setDefaultEdgeLabel("foo")).toBe(g); }); }); describe("edge", function() { it("returns undefined if the edge isn't part of the graph", function() { - expect(g.edge("a", "b")).to.be.undefined; - expect(g.edge({ v: "a", w: "b" })).to.be.undefined; - expect(g.edge("a", "b", "foo")).to.be.undefined; + expect(g.edge("a", "b")).toBeUndefined(); + expect(g.edge({ v: "a", w: "b" })).toBeUndefined(); + expect(g.edge("a", "b", "foo")).toBeUndefined(); }); it("returns the value of the edge if it is part of the graph", function() { g.setEdge("a", "b", { foo: "bar" }); - expect(g.edge("a", "b")).to.eql({ foo: "bar" }); - expect(g.edgeAsObj("a", "b")).to.eql({ foo: "bar" }); - expect(g.edge({ v: "a", w: "b" })).to.eql({ foo: "bar" }); - expect(g.edgeAsObj({ v: "a", w: "b" })).to.eql({ foo: "bar" }); - expect(g.edge("b", "a")).to.be.undefined; - expect(g.edgeAsObj("b", "a")).to.eql({label: undefined }); + expect(g.edge("a", "b")).toEqual({ foo: "bar" }); + expect(g.edgeAsObj("a", "b")).toEqual({ foo: "bar" }); + expect(g.edge({ v: "a", w: "b" })).toEqual({ foo: "bar" }); + expect(g.edgeAsObj({ v: "a", w: "b" })).toEqual({ foo: "bar" }); + expect(g.edge("b", "a")).toBeUndefined(); + expect(g.edgeAsObj("b", "a")).toEqual({label: undefined }); }); it("returns the value of a multi-edge if it is part of the graph", function() { var g = new Graph({ multigraph: true }); g.setEdge("a", "b", { bar: "baz" }, "foo"); - expect(g.edge("a", "b", "foo")).to.eql({ bar: "baz" }); - expect(g.edgeAsObj("a", "b", "foo")).to.eql({ bar: "baz" }); - expect(g.edge("a", "b")).to.be.undefined; - expect(g.edgeAsObj("a", "b")).to.eql({label: undefined}); + expect(g.edge("a", "b", "foo")).toEqual({ bar: "baz" }); + expect(g.edgeAsObj("a", "b", "foo")).toEqual({ bar: "baz" }); + expect(g.edge("a", "b")).toBeUndefined(); + expect(g.edgeAsObj("a", "b")).toEqual({label: undefined}); }); it("returns an edge in either direction in an undirected graph", function() { var g = new Graph({ directed: false }); g.setEdge("a", "b", { foo: "bar" }); - expect(g.edge("a", "b")).to.eql({ foo: "bar" }); - expect(g.edgeAsObj("a", "b")).to.eql({ foo: "bar" }); - expect(g.edge("b", "a")).to.eql({ foo: "bar" }); - expect(g.edgeAsObj("b", "a")).to.eql({ foo: "bar" }); + expect(g.edge("a", "b")).toEqual({ foo: "bar" }); + expect(g.edgeAsObj("a", "b")).toEqual({ foo: "bar" }); + expect(g.edge("b", "a")).toEqual({ foo: "bar" }); + expect(g.edgeAsObj("b", "a")).toEqual({ foo: "bar" }); }); }); describe("removeEdge", function() { it("has no effect if the edge is not in the graph", function() { g.removeEdge("a", "b"); - expect(g.hasEdge("a", "b")).to.be.false; - expect(g.edgeCount()).to.equal(0); + expect(g.hasEdge("a", "b")).toBe(false); + expect(g.edgeCount()).toBe(0); }); it("can remove an edge by edgeObj", function() { var g = new Graph({ multigraph: true }); g.setEdge({ v: "a", w: "b", name: "foo" }); g.removeEdge({ v: "a", w: "b", name: "foo" }); - expect(g.hasEdge("a", "b", "foo")).to.be.false; - expect(g.edgeCount()).to.equal(0); + expect(g.hasEdge("a", "b", "foo")).toBe(false); + expect(g.edgeCount()).toBe(0); }); it("can remove an edge by separate ids", function() { var g = new Graph({ multigraph: true }); g.setEdge({ v: "a", w: "b", name: "foo" }); g.removeEdge("a", "b", "foo"); - expect(g.hasEdge("a", "b", "foo")).to.be.false; - expect(g.edgeCount()).to.equal(0); + expect(g.hasEdge("a", "b", "foo")).toBe(false); + expect(g.edgeCount()).toBe(0); }); it("correctly removes neighbors", function() { g.setEdge("a", "b"); g.removeEdge("a", "b"); - expect(g.successors("a")).to.eql([]); - expect(g.neighbors("a")).to.eql([]); - expect(g.predecessors("b")).to.eql([]); - expect(g.neighbors("b")).to.eql([]); + expect(g.successors("a")).toEqual([]); + expect(g.neighbors("a")).toEqual([]); + expect(g.predecessors("b")).toEqual([]); + expect(g.neighbors("b")).toEqual([]); }); it("correctly decrements neighbor counts", function() { @@ -829,37 +828,37 @@ describe("Graph", function() { g.setEdge({ v: "a", w: "b", name: "foo" }); g.removeEdge("a", "b"); expect(g.hasEdge("a", "b", "foo")); - expect(g.successors("a")).to.eql(["b"]); - expect(g.neighbors("a")).to.eql(["b"]); - expect(g.predecessors("b")).to.eql(["a"]); - expect(g.neighbors("b")).to.eql(["a"]); + expect(g.successors("a")).toEqual(["b"]); + expect(g.neighbors("a")).toEqual(["b"]); + expect(g.predecessors("b")).toEqual(["a"]); + expect(g.neighbors("b")).toEqual(["a"]); }); it("works with undirected graphs", function() { var g = new Graph({ directed: false }); g.setEdge("h", "g"); g.removeEdge("g", "h"); - expect(g.neighbors("g")).to.eql([]); - expect(g.neighbors("h")).to.eql([]); + expect(g.neighbors("g")).toEqual([]); + expect(g.neighbors("h")).toEqual([]); }); it("is chainable", function() { g.setEdge("a", "b"); - expect(g.removeEdge("a", "b")).to.equal(g); + expect(g.removeEdge("a", "b")).toBe(g); }); }); describe("inEdges", function() { it("returns undefined for a node that is not in the graph", function() { - expect(g.inEdges("a")).to.be.undefined; + expect(g.inEdges("a")).toBeUndefined(); }); it("returns the edges that point at the specified node", function() { g.setEdge("a", "b"); g.setEdge("b", "c"); - expect(g.inEdges("a")).to.eql([]); - expect(g.inEdges("b")).to.eql([{ v: "a", w: "b" }]); - expect(g.inEdges("c")).to.eql([{ v: "b", w: "c" }]); + expect(g.inEdges("a")).toEqual([]); + expect(g.inEdges("b")).toEqual([{ v: "a", w: "b" }]); + expect(g.inEdges("c")).toEqual([{ v: "b", w: "c" }]); }); it("works for multigraphs", function() { @@ -867,8 +866,8 @@ describe("Graph", function() { g.setEdge("a", "b"); g.setEdge("a", "b", undefined, "bar"); g.setEdge("a", "b", undefined, "foo"); - expect(g.inEdges("a")).to.eql([]); - expect(g.inEdges("b").sort(sortEdges)).to.eql([ + expect(g.inEdges("a")).toEqual([]); + expect(g.inEdges("b").sort(sortEdges)).toEqual([ { v: "a", w: "b", name: "bar" }, { v: "a", w: "b", name: "foo" }, { v: "a", w: "b" } @@ -883,8 +882,8 @@ describe("Graph", function() { g.setEdge("b", "c"); g.setEdge("z", "a"); g.setEdge("z", "b"); - expect(g.inEdges("a", "b")).to.eql([]); - expect(g.inEdges("b", "a").sort(sortEdges)).to.eql([ + expect(g.inEdges("a", "b")).toEqual([]); + expect(g.inEdges("b", "a").sort(sortEdges)).toEqual([ { v: "a", w: "b", name: "foo" }, { v: "a", w: "b" } ]); @@ -893,15 +892,15 @@ describe("Graph", function() { describe("outEdges", function() { it("returns undefined for a node that is not in the graph", function() { - expect(g.outEdges("a")).to.be.undefined; + expect(g.outEdges("a")).toBeUndefined(); }); it("returns all edges that this node points at", function() { g.setEdge("a", "b"); g.setEdge("b", "c"); - expect(g.outEdges("a")).to.eql([{ v: "a", w: "b" }]); - expect(g.outEdges("b")).to.eql([{ v: "b", w: "c" }]); - expect(g.outEdges("c")).to.eql([]); + expect(g.outEdges("a")).toEqual([{ v: "a", w: "b" }]); + expect(g.outEdges("b")).toEqual([{ v: "b", w: "c" }]); + expect(g.outEdges("c")).toEqual([]); }); it("works for multigraphs", function() { @@ -909,12 +908,12 @@ describe("Graph", function() { g.setEdge("a", "b"); g.setEdge("a", "b", undefined, "bar"); g.setEdge("a", "b", undefined, "foo"); - expect(g.outEdges("a").sort(sortEdges)).to.eql([ + expect(g.outEdges("a").sort(sortEdges)).toEqual([ { v: "a", w: "b", name: "bar" }, { v: "a", w: "b", name: "foo" }, { v: "a", w: "b" } ]); - expect(g.outEdges("b")).to.eql([]); + expect(g.outEdges("b")).toEqual([]); }); it("can return only edges to a specified node", function() { @@ -925,26 +924,25 @@ describe("Graph", function() { g.setEdge("b", "c"); g.setEdge("z", "a"); g.setEdge("z", "b"); - expect(g.outEdges("a", "b").sort(sortEdges)).to.eql([ + expect(g.outEdges("a", "b").sort(sortEdges)).toEqual([ { v: "a", w: "b", name: "foo" }, { v: "a", w: "b" } ]); - expect(g.outEdges("b", "a")).to.eql([]); + expect(g.outEdges("b", "a")).toEqual([]); }); }); describe("nodeEdges", function() { it("returns undefined for a node that is not in the graph", function() { - expect(g.nodeEdges("a")).to.be.undefined; + expect(g.nodeEdges("a")).toBeUndefined(); }); it("returns all edges that this node points at", function() { g.setEdge("a", "b"); g.setEdge("b", "c"); - expect(g.nodeEdges("a")).to.eql([{ v: "a", w: "b" }]); - expect(g.nodeEdges("b").sort(sortEdges)) - .to.eql([{ v: "a", w: "b" }, { v: "b", w: "c" }]); - expect(g.nodeEdges("c")).to.eql([{ v: "b", w: "c" }]); + expect(g.nodeEdges("a")).toEqual([{ v: "a", w: "b" }]); + expect(g.nodeEdges("b").sort(sortEdges)).toEqual([{ v: "a", w: "b" }, { v: "b", w: "c" }]); + expect(g.nodeEdges("c")).toEqual([{ v: "b", w: "c" }]); }); it("works for multigraphs", function() { @@ -952,12 +950,12 @@ describe("Graph", function() { g.setEdge("a", "b"); g.setEdge({ v: "a", w: "b", name: "bar" }); g.setEdge({ v: "a", w: "b", name: "foo" }); - expect(g.nodeEdges("a").sort(sortEdges)).to.eql([ + expect(g.nodeEdges("a").sort(sortEdges)).toEqual([ { v: "a", w: "b", name: "bar" }, { v: "a", w: "b", name: "foo" }, { v: "a", w: "b" } ]); - expect(g.nodeEdges("b").sort(sortEdges)).to.eql([ + expect(g.nodeEdges("b").sort(sortEdges)).toEqual([ { v: "a", w: "b", name: "bar" }, { v: "a", w: "b", name: "foo" }, { v: "a", w: "b" } @@ -972,11 +970,11 @@ describe("Graph", function() { g.setEdge("b", "c"); g.setEdge("z", "a"); g.setEdge("z", "b"); - expect(g.nodeEdges("a", "b").sort(sortEdges)).to.eql([ + expect(g.nodeEdges("a", "b").sort(sortEdges)).toEqual([ { v: "a", w: "b", name: "foo" }, { v: "a", w: "b" } ]); - expect(g.nodeEdges("b", "a").sort(sortEdges)).to.eql([ + expect(g.nodeEdges("b", "a").sort(sortEdges)).toEqual([ { v: "a", w: "b", name: "foo" }, { v: "a", w: "b" } ]); diff --git a/test/json-test.js b/test/json-test.js index c1fc71d1..128c4dcd 100644 --- a/test/json-test.js +++ b/test/json-test.js @@ -1,61 +1,56 @@ -var expect = require("./chai").expect; var Graph = require("..").Graph; var read = require("..").json.read; var write = require("..").json.write; describe("json", function() { it("preserves the graph options", function() { - expect(rw(new Graph({ directed: true })).isDirected()).to.be.true; - expect(rw(new Graph({ directed: false })).isDirected()).to.be.false; - expect(rw(new Graph({ multigraph: true })).isMultigraph()).to.be.true; - expect(rw(new Graph({ multigraph: false })).isMultigraph()).to.be.false; - expect(rw(new Graph({ compound: true })).isCompound()).to.be.true; - expect(rw(new Graph({ compound: false })).isCompound()).to.be.false; + expect(rw(new Graph({ directed: true })).isDirected()).toBe(true); + expect(rw(new Graph({ directed: false })).isDirected()).toBe(false); + expect(rw(new Graph({ multigraph: true })).isMultigraph()).toBe(true); + expect(rw(new Graph({ multigraph: false })).isMultigraph()).toBe(false); + expect(rw(new Graph({ compound: true })).isCompound()).toBe(true); + expect(rw(new Graph({ compound: false })).isCompound()).toBe(false); }); it("preserves the graph value, if any", function() { - expect(rw(new Graph().setGraph(1)).graph()).equals(1); - expect(rw(new Graph().setGraph({ foo: "bar" })).graph()).eqls({ foo: "bar" }); - expect(rw(new Graph()).graph()).to.be.undefined; + expect(rw(new Graph().setGraph(1)).graph()).toBe(1); + expect(rw(new Graph().setGraph({ foo: "bar" })).graph()).toEqual({ foo: "bar" }); + expect(rw(new Graph()).graph()).toBeUndefined(); }); it("preserves nodes", function() { - expect(rw(new Graph().setNode("a")).hasNode("a")).to.be.true; - expect(rw(new Graph().setNode("a")).node("a")).to.be.undefined; - expect(rw(new Graph().setNode("a", 1)).node("a")).equals(1); - expect(rw(new Graph().setNode("a", { foo: "bar" })).node("a")) - .eqls({ foo: "bar" }); + expect(rw(new Graph().setNode("a")).hasNode("a")).toBe(true); + expect(rw(new Graph().setNode("a")).node("a")).toBeUndefined(); + expect(rw(new Graph().setNode("a", 1)).node("a")).toBe(1); + expect(rw(new Graph().setNode("a", { foo: "bar" })).node("a")).toEqual({ foo: "bar" }); }); it("preserves simple edges", function() { - expect(rw(new Graph().setEdge("a", "b")).hasEdge("a", "b")).to.be.true; - expect(rw(new Graph().setEdge("a", "b")).edge("a", "b")).to.be.undefined; - expect(rw(new Graph().setEdge("a", "b", 1)).edge("a", "b")).equals(1); - expect(rw(new Graph().setEdge("a", "b", { foo: "bar" })).edge("a", "b")) - .eqls({ foo: "bar" }); + expect(rw(new Graph().setEdge("a", "b")).hasEdge("a", "b")).toBe(true); + expect(rw(new Graph().setEdge("a", "b")).edge("a", "b")).toBeUndefined(); + expect(rw(new Graph().setEdge("a", "b", 1)).edge("a", "b")).toBe(1); + expect(rw(new Graph().setEdge("a", "b", { foo: "bar" })).edge("a", "b")).toEqual({ foo: "bar" }); }); it("preserves multi-edges", function() { var g = new Graph({ multigraph: true }); g.setEdge({ v: "a", w: "b", name: "foo" }); - expect(rw(g).hasEdge("a", "b", "foo")).to.be.true; + expect(rw(g).hasEdge("a", "b", "foo")).toBe(true); g.setEdge({ v: "a", w: "b", name: "foo" }); - expect(rw(g).edge("a", "b", "foo")).to.be.undefined; + expect(rw(g).edge("a", "b", "foo")).toBeUndefined(); g.setEdge({ v: "a", w: "b", name: "foo" }, 1); - expect(rw(g).edge("a", "b", "foo")).equals(1); + expect(rw(g).edge("a", "b", "foo")).toBe(1); g.setEdge({ v: "a", w: "b", name: "foo" }, { foo: "bar" }); - expect(rw(g).edge("a", "b", "foo")).eqls({ foo: "bar" }); + expect(rw(g).edge("a", "b", "foo")).toEqual({ foo: "bar" }); }); it("preserves parent / child relationships", function() { - expect(rw(new Graph({ compound: true }).setNode("a")).parent("a")) - .to.be.undefined; - expect(rw(new Graph({ compound: true }).setParent("a", "parent")).parent("a")) - .to.equal("parent"); + expect(rw(new Graph({ compound: true }).setNode("a")).parent("a")).toBeUndefined(); + expect(rw(new Graph({ compound: true }).setParent("a", "parent")).parent("a")).toBe("parent"); }); }); diff --git a/test/test-main.js b/test/test-main.js deleted file mode 100644 index ecfa6d9b..00000000 --- a/test/test-main.js +++ /dev/null @@ -1,39 +0,0 @@ -/* global require */ - -var allTestFiles = []; -var TEST_REGEXP = /(spec|test)\.js$/i; - -// Get a list of all the test files to include -Object.keys(this.__karma__.files).forEach(function(file) { - if (TEST_REGEXP.test(file)) { - // Normalize paths to RequireJS module names. - // If you require sub-dependencies of test files to be loaded as-is (requiring file extension) - // then do not normalize the paths - var normalizedTestModule = file.replace(/^\/base\/|\.js$/g, ''); - allTestFiles.push(normalizedTestModule); - } -}); - -require.config({ - // Karma serves files under /base, which is the basePath from your config file - baseUrl: '/base', - - paths:{ - chai: 'node_modules/chai/chai', - graphlib: 'build/graphlib', - 'graphlib.core': 'build/graphlib.core' - }, - - shim: { - 'graphlib.core': { - deps: [], - exports: 'graphlib.core' //any even not existing var could be defined here. - } - }, - - // dynamically load all test files - deps: allTestFiles, - - // we have to kickoff jasmine, as it is asynchronous - callback: this.__karma__.start -}); diff --git a/test/version-test.js b/test/version-test.js index e8b2d205..0a9bc724 100644 --- a/test/version-test.js +++ b/test/version-test.js @@ -1,8 +1,6 @@ -var expect = require('./chai').expect; - describe('version', function() { it('should match the version from package.json', function() { var packageVersion = require('../package').version; - expect(require('../lib/version')).to.equal(packageVersion); + expect(require('../lib/version')).toBe(packageVersion); }); }); From ab1caec16eca6ae2afbd7ca7e27288e17b280fe6 Mon Sep 17 00:00:00 2001 From: David Newell Date: Fri, 28 Nov 2025 11:05:44 +0100 Subject: [PATCH 2/3] Reverting the dist names back to graphlib --- build.js | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/build.js b/build.js index 3d7b0cda..e8563e8d 100644 --- a/build.js +++ b/build.js @@ -12,16 +12,14 @@ const sharedConfig = { sourcemap: true, target: 'es2018', legalComments: 'linked', - external: external.concat([ - '@dagrejs/graphlib' - ]), + external: external.concat([]), }; async function build() { // 1. CommonJS (CJS) - For Node.js `require()` await esbuild.build({ ...sharedConfig, - outfile: 'dist/dagre.cjs.js', + outfile: 'dist/graphlib.cjs.js', format: 'cjs', platform: 'node', }); @@ -29,7 +27,7 @@ async function build() { // 2. ES Module (ESM) - For modern bundlers/native ES imports await esbuild.build({ ...sharedConfig, - outfile: 'dist/dagre.esm.js', + outfile: 'dist/graphlib.esm.js', format: 'esm', platform: 'neutral', }); @@ -37,24 +35,24 @@ async function build() { const iifeConfig = { ...sharedConfig, format: 'iife', - globalName: 'dagre', + globalName: 'graphlib', platform: 'browser', }; // 3. IIFE/UMD - For direct browser script tag await esbuild.build({ ...iifeConfig, - outfile: 'dist/dagre.min.js', + outfile: 'dist/graphlib.min.js', }); // 4. IIFE/UMD - For direct browser script tag, unminified await esbuild.build({ ...iifeConfig, - outfile: 'dist/dagre.js', + outfile: 'dist/graphlib.js', minify: false, }); - fs.copyFileSync('index.d.ts', 'dist/dagre.d.ts'); + fs.copyFileSync('index.d.ts', 'dist/graphlib.d.ts'); console.log('Build complete! 🚀'); } From 6ae42caf9ab874f65e3652ad979f26c6f92392c8 Mon Sep 17 00:00:00 2001 From: David Newell Date: Fri, 28 Nov 2025 11:07:25 +0100 Subject: [PATCH 3/3] Reverting the dist names back to graphlib --- dist/dagre.min.js | 2 -- dist/{dagre.cjs.js => graphlib.cjs.js} | 2 +- dist/{dagre.cjs.js.map => graphlib.cjs.js.map} | 0 dist/{dagre.d.ts => graphlib.d.ts} | 0 dist/{dagre.esm.js => graphlib.esm.js} | 2 +- dist/{dagre.esm.js.map => graphlib.esm.js.map} | 0 dist/{dagre.js => graphlib.js} | 4 ++-- dist/{dagre.js.map => graphlib.js.map} | 0 dist/graphlib.min.js | 2 ++ dist/{dagre.min.js.map => graphlib.min.js.map} | 2 +- 10 files changed, 7 insertions(+), 7 deletions(-) delete mode 100644 dist/dagre.min.js rename dist/{dagre.cjs.js => graphlib.cjs.js} (99%) rename dist/{dagre.cjs.js.map => graphlib.cjs.js.map} (100%) rename dist/{dagre.d.ts => graphlib.d.ts} (100%) rename dist/{dagre.esm.js => graphlib.esm.js} (99%) rename dist/{dagre.esm.js.map => graphlib.esm.js.map} (100%) rename dist/{dagre.js => graphlib.js} (99%) rename dist/{dagre.js.map => graphlib.js.map} (100%) create mode 100644 dist/graphlib.min.js rename dist/{dagre.min.js.map => graphlib.min.js.map} (99%) diff --git a/dist/dagre.min.js b/dist/dagre.min.js deleted file mode 100644 index bee96600..00000000 --- a/dist/dagre.min.js +++ /dev/null @@ -1,2 +0,0 @@ -var dagre=(()=>{var fe=Object.defineProperty;var le=(n,e,r)=>e in n?fe(n,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):n[e]=r;var c=(n,e)=>()=>(e||n((e={exports:{}}).exports,e),e.exports);var d=(n,e,r)=>le(n,typeof e!="symbol"?e+"":e,r);var b=c((Re,D)=>{"use strict";var _e="\0",p="\0",C="",m=class{constructor(e){d(this,"_isDirected",!0);d(this,"_isMultigraph",!1);d(this,"_isCompound",!1);d(this,"_label");d(this,"_defaultNodeLabelFn",()=>{});d(this,"_defaultEdgeLabelFn",()=>{});d(this,"_nodes",{});d(this,"_in",{});d(this,"_preds",{});d(this,"_out",{});d(this,"_sucs",{});d(this,"_edgeObjs",{});d(this,"_edgeLabels",{});d(this,"_nodeCount",0);d(this,"_edgeCount",0);d(this,"_parent");d(this,"_children");e&&(this._isDirected=Object.hasOwn(e,"directed")?e.directed:!0,this._isMultigraph=Object.hasOwn(e,"multigraph")?e.multigraph:!1,this._isCompound=Object.hasOwn(e,"compound")?e.compound:!1),this._isCompound&&(this._parent={},this._children={},this._children[p]={})}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return this._defaultNodeLabelFn=e,typeof e!="function"&&(this._defaultNodeLabelFn=()=>e),this}nodeCount(){return this._nodeCount}nodes(){return Object.keys(this._nodes)}sources(){var e=this;return this.nodes().filter(r=>Object.keys(e._in[r]).length===0)}sinks(){var e=this;return this.nodes().filter(r=>Object.keys(e._out[r]).length===0)}setNodes(e,r){var t=arguments,s=this;return e.forEach(function(i){t.length>1?s.setNode(i,r):s.setNode(i)}),this}setNode(e,r){return Object.hasOwn(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=r),this):(this._nodes[e]=arguments.length>1?r:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=p,this._children[e]={},this._children[p][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.hasOwn(this._nodes,e)}removeNode(e){var r=this;if(Object.hasOwn(this._nodes,e)){var t=s=>r.removeEdge(r._edgeObjs[s]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],this.children(e).forEach(function(s){r.setParent(s)}),delete this._children[e]),Object.keys(this._in[e]).forEach(t),delete this._in[e],delete this._preds[e],Object.keys(this._out[e]).forEach(t),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,r){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(r===void 0)r=p;else{r+="";for(var t=r;t!==void 0;t=this.parent(t))if(t===e)throw new Error("Setting "+r+" as parent of "+e+" would create a cycle");this.setNode(r)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=r,this._children[r][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var r=this._parent[e];if(r!==p)return r}}children(e=p){if(this._isCompound){var r=this._children[e];if(r)return Object.keys(r)}else{if(e===p)return this.nodes();if(this.hasNode(e))return[]}}predecessors(e){var r=this._preds[e];if(r)return Object.keys(r)}successors(e){var r=this._sucs[e];if(r)return Object.keys(r)}neighbors(e){var r=this.predecessors(e);if(r){let s=new Set(r);for(var t of this.successors(e))s.add(t);return Array.from(s.values())}}isLeaf(e){var r;return this.isDirected()?r=this.successors(e):r=this.neighbors(e),r.length===0}filterNodes(e){var r=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});r.setGraph(this.graph());var t=this;Object.entries(this._nodes).forEach(function([a,o]){e(a)&&r.setNode(a,o)}),Object.values(this._edgeObjs).forEach(function(a){r.hasNode(a.v)&&r.hasNode(a.w)&&r.setEdge(a,t.edge(a))});var s={};function i(a){var o=t.parent(a);return o===void 0||r.hasNode(o)?(s[a]=o,o):o in s?s[o]:i(o)}return this._isCompound&&r.nodes().forEach(a=>r.setParent(a,i(a))),r}setDefaultEdgeLabel(e){return this._defaultEdgeLabelFn=e,typeof e!="function"&&(this._defaultEdgeLabelFn=()=>e),this}edgeCount(){return this._edgeCount}edges(){return Object.values(this._edgeObjs)}setPath(e,r){var t=this,s=arguments;return e.reduce(function(i,a){return s.length>1?t.setEdge(i,a,r):t.setEdge(i,a),a}),this}setEdge(){var e,r,t,s,i=!1,a=arguments[0];typeof a=="object"&&a!==null&&"v"in a?(e=a.v,r=a.w,t=a.name,arguments.length===2&&(s=arguments[1],i=!0)):(e=a,r=arguments[1],t=arguments[3],arguments.length>2&&(s=arguments[2],i=!0)),e=""+e,r=""+r,t!==void 0&&(t=""+t);var o=g(this._isDirected,e,r,t);if(Object.hasOwn(this._edgeLabels,o))return i&&(this._edgeLabels[o]=s),this;if(t!==void 0&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(r),this._edgeLabels[o]=i?s:this._defaultEdgeLabelFn(e,r,t);var u=pe(this._isDirected,e,r,t);return e=u.v,r=u.w,Object.freeze(u),this._edgeObjs[o]=u,q(this._preds[r],e),q(this._sucs[e],r),this._in[r][o]=u,this._out[e][o]=u,this._edgeCount++,this}edge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t);return this._edgeLabels[s]}edgeAsObj(){let e=this.edge(...arguments);return typeof e!="object"?{label:e}:e}hasEdge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t);return Object.hasOwn(this._edgeLabels,s)}removeEdge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t),i=this._edgeObjs[s];return i&&(e=i.v,r=i.w,delete this._edgeLabels[s],delete this._edgeObjs[s],x(this._preds[r],e),x(this._sucs[e],r),delete this._in[r][s],delete this._out[e][s],this._edgeCount--),this}inEdges(e,r){var t=this._in[e];if(t){var s=Object.values(t);return r?s.filter(i=>i.v===r):s}}outEdges(e,r){var t=this._out[e];if(t){var s=Object.values(t);return r?s.filter(i=>i.w===r):s}}nodeEdges(e,r){var t=this.inEdges(e,r);if(t)return t.concat(this.outEdges(e,r))}};function q(n,e){n[e]?n[e]++:n[e]=1}function x(n,e){--n[e]||delete n[e]}function g(n,e,r,t){var s=""+e,i=""+r;if(!n&&s>i){var a=s;s=i,i=a}return s+C+i+C+(t===void 0?_e:t)}function pe(n,e,r,t){var s=""+e,i=""+r;if(!n&&s>i){var a=s;s=i,i=a}var o={v:s,w:i};return t&&(o.name=t),o}function w(n,e){return g(n,e.v,e.w,e.name)}D.exports=m});var F=c((Be,L)=>{L.exports="2.2.5-pre"});var T=c((Je,A)=>{A.exports={Graph:b(),version:F()}});var P=c((Xe,M)=>{var ve=b();M.exports={write:ge,read:we};function ge(n){var e={options:{directed:n.isDirected(),multigraph:n.isMultigraph(),compound:n.isCompound()},nodes:Ee(n),edges:be(n)};return n.graph()!==void 0&&(e.value=structuredClone(n.graph())),e}function Ee(n){return n.nodes().map(function(e){var r=n.node(e),t=n.parent(e),s={v:e};return r!==void 0&&(s.value=r),t!==void 0&&(s.parent=t),s})}function be(n){return n.edges().map(function(e){var r=n.edge(e),t={v:e.v,w:e.w};return e.name!==void 0&&(t.name=e.name),r!==void 0&&(t.value=r),t})}function we(n){var e=new ve(n.options).setGraph(n.value);return n.nodes.forEach(function(r){e.setNode(r.v,r.value),r.parent&&e.setParent(r.v,r.parent)}),n.edges.forEach(function(r){e.setEdge({v:r.v,w:r.w,name:r.name},r.value)}),e}});var S=c((Ze,G)=>{G.exports=me;function me(n){var e={},r=[],t;function s(i){Object.hasOwn(e,i)||(e[i]=!0,t.push(i),n.successors(i).forEach(s),n.predecessors(i).forEach(s))}return n.nodes().forEach(function(i){t=[],s(i),t.length&&r.push(t)}),r}});var j=c(($e,V)=>{var O=class{constructor(){d(this,"_arr",[]);d(this,"_keyIndices",{})}size(){return this._arr.length}keys(){return this._arr.map(function(e){return e.key})}has(e){return Object.hasOwn(this._keyIndices,e)}priority(e){var r=this._keyIndices[e];if(r!==void 0)return this._arr[r].priority}min(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key}add(e,r){var t=this._keyIndices;if(e=String(e),!Object.hasOwn(t,e)){var s=this._arr,i=s.length;return t[e]=i,s.push({key:e,priority:r}),this._decrease(i),!0}return!1}removeMin(){this._swap(0,this._arr.length-1);var e=this._arr.pop();return delete this._keyIndices[e.key],this._heapify(0),e.key}decrease(e,r){var t=this._keyIndices[e];if(r>this._arr[t].priority)throw new Error("New priority is greater than current priority. Key: "+e+" Old: "+this._arr[t].priority+" New: "+r);this._arr[t].priority=r,this._decrease(t)}_heapify(e){var r=this._arr,t=2*e,s=t+1,i=e;t>1,!(r[s].priority{var Oe=j();z.exports=ye;var je=()=>1;function ye(n,e,r,t){return Ne(n,String(e),r||je,t||function(s){return n.outEdges(s)})}function Ne(n,e,r,t){var s={},i=new Oe,a,o,u=function(h){var f=h.v!==a?h.v:h.w,l=s[f],_=r(h),v=o.distance+_;if(_<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+h+" Weight: "+_);v0&&(a=i.removeMin(),o=s[a],o.distance!==Number.POSITIVE_INFINITY);)t(a).forEach(u);return s}});var W=c((tr,U)=>{var ke=y();U.exports=Ie;function Ie(n,e,r){return n.nodes().reduce(function(t,s){return t[s]=ke(n,s,e,r),t},{})}});var N=c((sr,Y)=>{Y.exports=Ce;function Ce(n){var e=0,r=[],t={},s=[];function i(a){var o=t[a]={onStack:!0,lowlink:e,index:e++};if(r.push(a),n.successors(a).forEach(function(f){Object.hasOwn(t,f)?t[f].onStack&&(o.lowlink=Math.min(o.lowlink,t[f].index)):(i(f),o.lowlink=Math.min(o.lowlink,t[f].lowlink))}),o.lowlink===o.index){var u=[],h;do h=r.pop(),t[h].onStack=!1,u.push(h);while(a!==h);s.push(u)}}return n.nodes().forEach(function(a){Object.hasOwn(t,a)||i(a)}),s}});var K=c((ir,H)=>{var qe=N();H.exports=xe;function xe(n){return qe(n).filter(function(e){return e.length>1||e.length===1&&n.hasEdge(e[0],e[0])})}});var Q=c((nr,R)=>{R.exports=Le;var De=()=>1;function Le(n,e,r){return Fe(n,e||De,r||function(t){return n.outEdges(t)})}function Fe(n,e,r){var t={},s=n.nodes();return s.forEach(function(i){t[i]={},t[i][i]={distance:0},s.forEach(function(a){i!==a&&(t[i][a]={distance:Number.POSITIVE_INFINITY})}),r(i).forEach(function(a){var o=a.v===i?a.w:a.v,u=e(a);t[i][o]={distance:u,predecessor:i}})}),s.forEach(function(i){var a=t[i];s.forEach(function(o){var u=t[o];s.forEach(function(h){var f=u[i],l=a[h],_=u[h],v=f.distance+l.distance;v<_.distance&&(_.distance=v,_.predecessor=l.predecessor)})})}),t}});var k=c((ar,J)=>{function B(n){var e={},r={},t=[];function s(i){if(Object.hasOwn(r,i))throw new E;Object.hasOwn(e,i)||(r[i]=!0,e[i]=!0,n.predecessors(i).forEach(s),delete r[i],t.push(i))}if(n.sinks().forEach(s),Object.keys(e).length!==n.nodeCount())throw new E;return t}var E=class extends Error{constructor(){super(...arguments)}};J.exports=B;B.CycleException=E});var $=c((or,Z)=>{var X=k();Z.exports=Ae;function Ae(n){try{X(n)}catch(e){if(e instanceof X.CycleException)return!1;throw e}return!0}});var I=c((ur,re)=>{re.exports=Te;function Te(n,e,r){Array.isArray(e)||(e=[e]);var t=n.isDirected()?o=>n.successors(o):o=>n.neighbors(o),s=r==="post"?Me:Pe,i=[],a={};return e.forEach(o=>{if(!n.hasNode(o))throw new Error("Graph does not have node: "+o);s(o,t,a,i)}),i}function Me(n,e,r,t){for(var s=[[n,!1]];s.length>0;){var i=s.pop();i[1]?t.push(i[0]):Object.hasOwn(r,i[0])||(r[i[0]]=!0,s.push([i[0],!0]),ee(e(i[0]),a=>s.push([a,!1])))}}function Pe(n,e,r,t){for(var s=[n];s.length>0;){var i=s.pop();Object.hasOwn(r,i)||(r[i]=!0,t.push(i),ee(e(i),a=>s.push(a)))}}function ee(n,e){for(var r=n.length;r--;)e(n[r],r,n);return n}});var se=c((hr,te)=>{var Ge=I();te.exports=Se;function Se(n,e){return Ge(n,e,"post")}});var ne=c((dr,ie)=>{var Ve=I();ie.exports=ze;function ze(n,e){return Ve(n,e,"pre")}});var oe=c((cr,ae)=>{var Ue=b(),We=j();ae.exports=Ye;function Ye(n,e){var r=new Ue,t={},s=new We,i;function a(u){var h=u.v===i?u.w:u.v,f=s.priority(h);if(f!==void 0){var l=e(u);l0;){if(i=s.removeMin(),Object.hasOwn(t,i))r.setEdge(i,t[i]);else{if(o)throw new Error("Input graph is not connected: "+n);o=!0}n.nodeEdges(i).forEach(a)}return r}});var he=c((fr,ue)=>{ue.exports={components:S(),dijkstra:y(),dijkstraAll:W(),findCycles:K(),floydWarshall:Q(),isAcyclic:$(),postorder:se(),preorder:ne(),prim:oe(),tarjan:N(),topsort:k()}});var He=c((lr,ce)=>{var de=T();ce.exports={Graph:de.Graph,json:P(),alg:he(),version:de.version}});return He();})(); -//# sourceMappingURL=dagre.min.js.map diff --git a/dist/dagre.cjs.js b/dist/graphlib.cjs.js similarity index 99% rename from dist/dagre.cjs.js rename to dist/graphlib.cjs.js index cee90e92..d225c7f7 100644 --- a/dist/dagre.cjs.js +++ b/dist/graphlib.cjs.js @@ -1,2 +1,2 @@ var ce=Object.defineProperty;var fe=(n,e,r)=>e in n?ce(n,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):n[e]=r;var c=(n,e)=>()=>(e||n((e={exports:{}}).exports,e),e.exports);var d=(n,e,r)=>fe(n,typeof e!="symbol"?e+"":e,r);var b=c((He,D)=>{"use strict";var le="\0",p="\0",C="",m=class{constructor(e){d(this,"_isDirected",!0);d(this,"_isMultigraph",!1);d(this,"_isCompound",!1);d(this,"_label");d(this,"_defaultNodeLabelFn",()=>{});d(this,"_defaultEdgeLabelFn",()=>{});d(this,"_nodes",{});d(this,"_in",{});d(this,"_preds",{});d(this,"_out",{});d(this,"_sucs",{});d(this,"_edgeObjs",{});d(this,"_edgeLabels",{});d(this,"_nodeCount",0);d(this,"_edgeCount",0);d(this,"_parent");d(this,"_children");e&&(this._isDirected=Object.hasOwn(e,"directed")?e.directed:!0,this._isMultigraph=Object.hasOwn(e,"multigraph")?e.multigraph:!1,this._isCompound=Object.hasOwn(e,"compound")?e.compound:!1),this._isCompound&&(this._parent={},this._children={},this._children[p]={})}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return this._defaultNodeLabelFn=e,typeof e!="function"&&(this._defaultNodeLabelFn=()=>e),this}nodeCount(){return this._nodeCount}nodes(){return Object.keys(this._nodes)}sources(){var e=this;return this.nodes().filter(r=>Object.keys(e._in[r]).length===0)}sinks(){var e=this;return this.nodes().filter(r=>Object.keys(e._out[r]).length===0)}setNodes(e,r){var t=arguments,s=this;return e.forEach(function(i){t.length>1?s.setNode(i,r):s.setNode(i)}),this}setNode(e,r){return Object.hasOwn(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=r),this):(this._nodes[e]=arguments.length>1?r:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=p,this._children[e]={},this._children[p][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.hasOwn(this._nodes,e)}removeNode(e){var r=this;if(Object.hasOwn(this._nodes,e)){var t=s=>r.removeEdge(r._edgeObjs[s]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],this.children(e).forEach(function(s){r.setParent(s)}),delete this._children[e]),Object.keys(this._in[e]).forEach(t),delete this._in[e],delete this._preds[e],Object.keys(this._out[e]).forEach(t),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,r){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(r===void 0)r=p;else{r+="";for(var t=r;t!==void 0;t=this.parent(t))if(t===e)throw new Error("Setting "+r+" as parent of "+e+" would create a cycle");this.setNode(r)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=r,this._children[r][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var r=this._parent[e];if(r!==p)return r}}children(e=p){if(this._isCompound){var r=this._children[e];if(r)return Object.keys(r)}else{if(e===p)return this.nodes();if(this.hasNode(e))return[]}}predecessors(e){var r=this._preds[e];if(r)return Object.keys(r)}successors(e){var r=this._sucs[e];if(r)return Object.keys(r)}neighbors(e){var r=this.predecessors(e);if(r){let s=new Set(r);for(var t of this.successors(e))s.add(t);return Array.from(s.values())}}isLeaf(e){var r;return this.isDirected()?r=this.successors(e):r=this.neighbors(e),r.length===0}filterNodes(e){var r=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});r.setGraph(this.graph());var t=this;Object.entries(this._nodes).forEach(function([a,o]){e(a)&&r.setNode(a,o)}),Object.values(this._edgeObjs).forEach(function(a){r.hasNode(a.v)&&r.hasNode(a.w)&&r.setEdge(a,t.edge(a))});var s={};function i(a){var o=t.parent(a);return o===void 0||r.hasNode(o)?(s[a]=o,o):o in s?s[o]:i(o)}return this._isCompound&&r.nodes().forEach(a=>r.setParent(a,i(a))),r}setDefaultEdgeLabel(e){return this._defaultEdgeLabelFn=e,typeof e!="function"&&(this._defaultEdgeLabelFn=()=>e),this}edgeCount(){return this._edgeCount}edges(){return Object.values(this._edgeObjs)}setPath(e,r){var t=this,s=arguments;return e.reduce(function(i,a){return s.length>1?t.setEdge(i,a,r):t.setEdge(i,a),a}),this}setEdge(){var e,r,t,s,i=!1,a=arguments[0];typeof a=="object"&&a!==null&&"v"in a?(e=a.v,r=a.w,t=a.name,arguments.length===2&&(s=arguments[1],i=!0)):(e=a,r=arguments[1],t=arguments[3],arguments.length>2&&(s=arguments[2],i=!0)),e=""+e,r=""+r,t!==void 0&&(t=""+t);var o=g(this._isDirected,e,r,t);if(Object.hasOwn(this._edgeLabels,o))return i&&(this._edgeLabels[o]=s),this;if(t!==void 0&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(r),this._edgeLabels[o]=i?s:this._defaultEdgeLabelFn(e,r,t);var u=_e(this._isDirected,e,r,t);return e=u.v,r=u.w,Object.freeze(u),this._edgeObjs[o]=u,q(this._preds[r],e),q(this._sucs[e],r),this._in[r][o]=u,this._out[e][o]=u,this._edgeCount++,this}edge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t);return this._edgeLabels[s]}edgeAsObj(){let e=this.edge(...arguments);return typeof e!="object"?{label:e}:e}hasEdge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t);return Object.hasOwn(this._edgeLabels,s)}removeEdge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t),i=this._edgeObjs[s];return i&&(e=i.v,r=i.w,delete this._edgeLabels[s],delete this._edgeObjs[s],x(this._preds[r],e),x(this._sucs[e],r),delete this._in[r][s],delete this._out[e][s],this._edgeCount--),this}inEdges(e,r){var t=this._in[e];if(t){var s=Object.values(t);return r?s.filter(i=>i.v===r):s}}outEdges(e,r){var t=this._out[e];if(t){var s=Object.values(t);return r?s.filter(i=>i.w===r):s}}nodeEdges(e,r){var t=this.inEdges(e,r);if(t)return t.concat(this.outEdges(e,r))}};function q(n,e){n[e]?n[e]++:n[e]=1}function x(n,e){--n[e]||delete n[e]}function g(n,e,r,t){var s=""+e,i=""+r;if(!n&&s>i){var a=s;s=i,i=a}return s+C+i+C+(t===void 0?le:t)}function _e(n,e,r,t){var s=""+e,i=""+r;if(!n&&s>i){var a=s;s=i,i=a}var o={v:s,w:i};return t&&(o.name=t),o}function w(n,e){return g(n,e.v,e.w,e.name)}D.exports=m});var F=c((Re,L)=>{L.exports="2.2.5-pre"});var T=c((Qe,A)=>{A.exports={Graph:b(),version:F()}});var P=c((Be,M)=>{var pe=b();M.exports={write:ve,read:be};function ve(n){var e={options:{directed:n.isDirected(),multigraph:n.isMultigraph(),compound:n.isCompound()},nodes:ge(n),edges:Ee(n)};return n.graph()!==void 0&&(e.value=structuredClone(n.graph())),e}function ge(n){return n.nodes().map(function(e){var r=n.node(e),t=n.parent(e),s={v:e};return r!==void 0&&(s.value=r),t!==void 0&&(s.parent=t),s})}function Ee(n){return n.edges().map(function(e){var r=n.edge(e),t={v:e.v,w:e.w};return e.name!==void 0&&(t.name=e.name),r!==void 0&&(t.value=r),t})}function be(n){var e=new pe(n.options).setGraph(n.value);return n.nodes.forEach(function(r){e.setNode(r.v,r.value),r.parent&&e.setParent(r.v,r.parent)}),n.edges.forEach(function(r){e.setEdge({v:r.v,w:r.w,name:r.name},r.value)}),e}});var S=c((Je,G)=>{G.exports=we;function we(n){var e={},r=[],t;function s(i){Object.hasOwn(e,i)||(e[i]=!0,t.push(i),n.successors(i).forEach(s),n.predecessors(i).forEach(s))}return n.nodes().forEach(function(i){t=[],s(i),t.length&&r.push(t)}),r}});var j=c((Xe,V)=>{var O=class{constructor(){d(this,"_arr",[]);d(this,"_keyIndices",{})}size(){return this._arr.length}keys(){return this._arr.map(function(e){return e.key})}has(e){return Object.hasOwn(this._keyIndices,e)}priority(e){var r=this._keyIndices[e];if(r!==void 0)return this._arr[r].priority}min(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key}add(e,r){var t=this._keyIndices;if(e=String(e),!Object.hasOwn(t,e)){var s=this._arr,i=s.length;return t[e]=i,s.push({key:e,priority:r}),this._decrease(i),!0}return!1}removeMin(){this._swap(0,this._arr.length-1);var e=this._arr.pop();return delete this._keyIndices[e.key],this._heapify(0),e.key}decrease(e,r){var t=this._keyIndices[e];if(r>this._arr[t].priority)throw new Error("New priority is greater than current priority. Key: "+e+" Old: "+this._arr[t].priority+" New: "+r);this._arr[t].priority=r,this._decrease(t)}_heapify(e){var r=this._arr,t=2*e,s=t+1,i=e;t>1,!(r[s].priority{var me=j();z.exports=je;var Oe=()=>1;function je(n,e,r,t){return ye(n,String(e),r||Oe,t||function(s){return n.outEdges(s)})}function ye(n,e,r,t){var s={},i=new me,a,o,u=function(h){var f=h.v!==a?h.v:h.w,l=s[f],_=r(h),v=o.distance+_;if(_<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+h+" Weight: "+_);v0&&(a=i.removeMin(),o=s[a],o.distance!==Number.POSITIVE_INFINITY);)t(a).forEach(u);return s}});var W=c((er,U)=>{var Ne=y();U.exports=ke;function ke(n,e,r){return n.nodes().reduce(function(t,s){return t[s]=Ne(n,s,e,r),t},{})}});var N=c((rr,Y)=>{Y.exports=Ie;function Ie(n){var e=0,r=[],t={},s=[];function i(a){var o=t[a]={onStack:!0,lowlink:e,index:e++};if(r.push(a),n.successors(a).forEach(function(f){Object.hasOwn(t,f)?t[f].onStack&&(o.lowlink=Math.min(o.lowlink,t[f].index)):(i(f),o.lowlink=Math.min(o.lowlink,t[f].lowlink))}),o.lowlink===o.index){var u=[],h;do h=r.pop(),t[h].onStack=!1,u.push(h);while(a!==h);s.push(u)}}return n.nodes().forEach(function(a){Object.hasOwn(t,a)||i(a)}),s}});var K=c((tr,H)=>{var Ce=N();H.exports=qe;function qe(n){return Ce(n).filter(function(e){return e.length>1||e.length===1&&n.hasEdge(e[0],e[0])})}});var Q=c((sr,R)=>{R.exports=De;var xe=()=>1;function De(n,e,r){return Le(n,e||xe,r||function(t){return n.outEdges(t)})}function Le(n,e,r){var t={},s=n.nodes();return s.forEach(function(i){t[i]={},t[i][i]={distance:0},s.forEach(function(a){i!==a&&(t[i][a]={distance:Number.POSITIVE_INFINITY})}),r(i).forEach(function(a){var o=a.v===i?a.w:a.v,u=e(a);t[i][o]={distance:u,predecessor:i}})}),s.forEach(function(i){var a=t[i];s.forEach(function(o){var u=t[o];s.forEach(function(h){var f=u[i],l=a[h],_=u[h],v=f.distance+l.distance;v<_.distance&&(_.distance=v,_.predecessor=l.predecessor)})})}),t}});var k=c((ir,J)=>{function B(n){var e={},r={},t=[];function s(i){if(Object.hasOwn(r,i))throw new E;Object.hasOwn(e,i)||(r[i]=!0,e[i]=!0,n.predecessors(i).forEach(s),delete r[i],t.push(i))}if(n.sinks().forEach(s),Object.keys(e).length!==n.nodeCount())throw new E;return t}var E=class extends Error{constructor(){super(...arguments)}};J.exports=B;B.CycleException=E});var $=c((nr,Z)=>{var X=k();Z.exports=Fe;function Fe(n){try{X(n)}catch(e){if(e instanceof X.CycleException)return!1;throw e}return!0}});var I=c((ar,re)=>{re.exports=Ae;function Ae(n,e,r){Array.isArray(e)||(e=[e]);var t=n.isDirected()?o=>n.successors(o):o=>n.neighbors(o),s=r==="post"?Te:Me,i=[],a={};return e.forEach(o=>{if(!n.hasNode(o))throw new Error("Graph does not have node: "+o);s(o,t,a,i)}),i}function Te(n,e,r,t){for(var s=[[n,!1]];s.length>0;){var i=s.pop();i[1]?t.push(i[0]):Object.hasOwn(r,i[0])||(r[i[0]]=!0,s.push([i[0],!0]),ee(e(i[0]),a=>s.push([a,!1])))}}function Me(n,e,r,t){for(var s=[n];s.length>0;){var i=s.pop();Object.hasOwn(r,i)||(r[i]=!0,t.push(i),ee(e(i),a=>s.push(a)))}}function ee(n,e){for(var r=n.length;r--;)e(n[r],r,n);return n}});var se=c((or,te)=>{var Pe=I();te.exports=Ge;function Ge(n,e){return Pe(n,e,"post")}});var ne=c((ur,ie)=>{var Se=I();ie.exports=Ve;function Ve(n,e){return Se(n,e,"pre")}});var oe=c((hr,ae)=>{var ze=b(),Ue=j();ae.exports=We;function We(n,e){var r=new ze,t={},s=new Ue,i;function a(u){var h=u.v===i?u.w:u.v,f=s.priority(h);if(f!==void 0){var l=e(u);l0;){if(i=s.removeMin(),Object.hasOwn(t,i))r.setEdge(i,t[i]);else{if(o)throw new Error("Input graph is not connected: "+n);o=!0}n.nodeEdges(i).forEach(a)}return r}});var he=c((dr,ue)=>{ue.exports={components:S(),dijkstra:y(),dijkstraAll:W(),findCycles:K(),floydWarshall:Q(),isAcyclic:$(),postorder:se(),preorder:ne(),prim:oe(),tarjan:N(),topsort:k()}});var de=T();module.exports={Graph:de.Graph,json:P(),alg:he(),version:de.version}; -//# sourceMappingURL=dagre.cjs.js.map +//# sourceMappingURL=graphlib.cjs.js.map diff --git a/dist/dagre.cjs.js.map b/dist/graphlib.cjs.js.map similarity index 100% rename from dist/dagre.cjs.js.map rename to dist/graphlib.cjs.js.map diff --git a/dist/dagre.d.ts b/dist/graphlib.d.ts similarity index 100% rename from dist/dagre.d.ts rename to dist/graphlib.d.ts diff --git a/dist/dagre.esm.js b/dist/graphlib.esm.js similarity index 99% rename from dist/dagre.esm.js rename to dist/graphlib.esm.js index 66b4cf4c..24281755 100644 --- a/dist/dagre.esm.js +++ b/dist/graphlib.esm.js @@ -1,2 +1,2 @@ var fe=Object.defineProperty;var le=(n,e,r)=>e in n?fe(n,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):n[e]=r;var c=(n,e)=>()=>(e||n((e={exports:{}}).exports,e),e.exports);var d=(n,e,r)=>le(n,typeof e!="symbol"?e+"":e,r);var b=c((Re,D)=>{"use strict";var _e="\0",p="\0",C="",m=class{constructor(e){d(this,"_isDirected",!0);d(this,"_isMultigraph",!1);d(this,"_isCompound",!1);d(this,"_label");d(this,"_defaultNodeLabelFn",()=>{});d(this,"_defaultEdgeLabelFn",()=>{});d(this,"_nodes",{});d(this,"_in",{});d(this,"_preds",{});d(this,"_out",{});d(this,"_sucs",{});d(this,"_edgeObjs",{});d(this,"_edgeLabels",{});d(this,"_nodeCount",0);d(this,"_edgeCount",0);d(this,"_parent");d(this,"_children");e&&(this._isDirected=Object.hasOwn(e,"directed")?e.directed:!0,this._isMultigraph=Object.hasOwn(e,"multigraph")?e.multigraph:!1,this._isCompound=Object.hasOwn(e,"compound")?e.compound:!1),this._isCompound&&(this._parent={},this._children={},this._children[p]={})}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return this._defaultNodeLabelFn=e,typeof e!="function"&&(this._defaultNodeLabelFn=()=>e),this}nodeCount(){return this._nodeCount}nodes(){return Object.keys(this._nodes)}sources(){var e=this;return this.nodes().filter(r=>Object.keys(e._in[r]).length===0)}sinks(){var e=this;return this.nodes().filter(r=>Object.keys(e._out[r]).length===0)}setNodes(e,r){var t=arguments,s=this;return e.forEach(function(i){t.length>1?s.setNode(i,r):s.setNode(i)}),this}setNode(e,r){return Object.hasOwn(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=r),this):(this._nodes[e]=arguments.length>1?r:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=p,this._children[e]={},this._children[p][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.hasOwn(this._nodes,e)}removeNode(e){var r=this;if(Object.hasOwn(this._nodes,e)){var t=s=>r.removeEdge(r._edgeObjs[s]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],this.children(e).forEach(function(s){r.setParent(s)}),delete this._children[e]),Object.keys(this._in[e]).forEach(t),delete this._in[e],delete this._preds[e],Object.keys(this._out[e]).forEach(t),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,r){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(r===void 0)r=p;else{r+="";for(var t=r;t!==void 0;t=this.parent(t))if(t===e)throw new Error("Setting "+r+" as parent of "+e+" would create a cycle");this.setNode(r)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=r,this._children[r][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var r=this._parent[e];if(r!==p)return r}}children(e=p){if(this._isCompound){var r=this._children[e];if(r)return Object.keys(r)}else{if(e===p)return this.nodes();if(this.hasNode(e))return[]}}predecessors(e){var r=this._preds[e];if(r)return Object.keys(r)}successors(e){var r=this._sucs[e];if(r)return Object.keys(r)}neighbors(e){var r=this.predecessors(e);if(r){let s=new Set(r);for(var t of this.successors(e))s.add(t);return Array.from(s.values())}}isLeaf(e){var r;return this.isDirected()?r=this.successors(e):r=this.neighbors(e),r.length===0}filterNodes(e){var r=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});r.setGraph(this.graph());var t=this;Object.entries(this._nodes).forEach(function([a,o]){e(a)&&r.setNode(a,o)}),Object.values(this._edgeObjs).forEach(function(a){r.hasNode(a.v)&&r.hasNode(a.w)&&r.setEdge(a,t.edge(a))});var s={};function i(a){var o=t.parent(a);return o===void 0||r.hasNode(o)?(s[a]=o,o):o in s?s[o]:i(o)}return this._isCompound&&r.nodes().forEach(a=>r.setParent(a,i(a))),r}setDefaultEdgeLabel(e){return this._defaultEdgeLabelFn=e,typeof e!="function"&&(this._defaultEdgeLabelFn=()=>e),this}edgeCount(){return this._edgeCount}edges(){return Object.values(this._edgeObjs)}setPath(e,r){var t=this,s=arguments;return e.reduce(function(i,a){return s.length>1?t.setEdge(i,a,r):t.setEdge(i,a),a}),this}setEdge(){var e,r,t,s,i=!1,a=arguments[0];typeof a=="object"&&a!==null&&"v"in a?(e=a.v,r=a.w,t=a.name,arguments.length===2&&(s=arguments[1],i=!0)):(e=a,r=arguments[1],t=arguments[3],arguments.length>2&&(s=arguments[2],i=!0)),e=""+e,r=""+r,t!==void 0&&(t=""+t);var o=g(this._isDirected,e,r,t);if(Object.hasOwn(this._edgeLabels,o))return i&&(this._edgeLabels[o]=s),this;if(t!==void 0&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(r),this._edgeLabels[o]=i?s:this._defaultEdgeLabelFn(e,r,t);var u=pe(this._isDirected,e,r,t);return e=u.v,r=u.w,Object.freeze(u),this._edgeObjs[o]=u,q(this._preds[r],e),q(this._sucs[e],r),this._in[r][o]=u,this._out[e][o]=u,this._edgeCount++,this}edge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t);return this._edgeLabels[s]}edgeAsObj(){let e=this.edge(...arguments);return typeof e!="object"?{label:e}:e}hasEdge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t);return Object.hasOwn(this._edgeLabels,s)}removeEdge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t),i=this._edgeObjs[s];return i&&(e=i.v,r=i.w,delete this._edgeLabels[s],delete this._edgeObjs[s],x(this._preds[r],e),x(this._sucs[e],r),delete this._in[r][s],delete this._out[e][s],this._edgeCount--),this}inEdges(e,r){var t=this._in[e];if(t){var s=Object.values(t);return r?s.filter(i=>i.v===r):s}}outEdges(e,r){var t=this._out[e];if(t){var s=Object.values(t);return r?s.filter(i=>i.w===r):s}}nodeEdges(e,r){var t=this.inEdges(e,r);if(t)return t.concat(this.outEdges(e,r))}};function q(n,e){n[e]?n[e]++:n[e]=1}function x(n,e){--n[e]||delete n[e]}function g(n,e,r,t){var s=""+e,i=""+r;if(!n&&s>i){var a=s;s=i,i=a}return s+C+i+C+(t===void 0?_e:t)}function pe(n,e,r,t){var s=""+e,i=""+r;if(!n&&s>i){var a=s;s=i,i=a}var o={v:s,w:i};return t&&(o.name=t),o}function w(n,e){return g(n,e.v,e.w,e.name)}D.exports=m});var F=c((Be,L)=>{L.exports="2.2.5-pre"});var T=c((Je,A)=>{A.exports={Graph:b(),version:F()}});var P=c((Xe,M)=>{var ve=b();M.exports={write:ge,read:we};function ge(n){var e={options:{directed:n.isDirected(),multigraph:n.isMultigraph(),compound:n.isCompound()},nodes:Ee(n),edges:be(n)};return n.graph()!==void 0&&(e.value=structuredClone(n.graph())),e}function Ee(n){return n.nodes().map(function(e){var r=n.node(e),t=n.parent(e),s={v:e};return r!==void 0&&(s.value=r),t!==void 0&&(s.parent=t),s})}function be(n){return n.edges().map(function(e){var r=n.edge(e),t={v:e.v,w:e.w};return e.name!==void 0&&(t.name=e.name),r!==void 0&&(t.value=r),t})}function we(n){var e=new ve(n.options).setGraph(n.value);return n.nodes.forEach(function(r){e.setNode(r.v,r.value),r.parent&&e.setParent(r.v,r.parent)}),n.edges.forEach(function(r){e.setEdge({v:r.v,w:r.w,name:r.name},r.value)}),e}});var S=c((Ze,G)=>{G.exports=me;function me(n){var e={},r=[],t;function s(i){Object.hasOwn(e,i)||(e[i]=!0,t.push(i),n.successors(i).forEach(s),n.predecessors(i).forEach(s))}return n.nodes().forEach(function(i){t=[],s(i),t.length&&r.push(t)}),r}});var j=c(($e,V)=>{var O=class{constructor(){d(this,"_arr",[]);d(this,"_keyIndices",{})}size(){return this._arr.length}keys(){return this._arr.map(function(e){return e.key})}has(e){return Object.hasOwn(this._keyIndices,e)}priority(e){var r=this._keyIndices[e];if(r!==void 0)return this._arr[r].priority}min(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key}add(e,r){var t=this._keyIndices;if(e=String(e),!Object.hasOwn(t,e)){var s=this._arr,i=s.length;return t[e]=i,s.push({key:e,priority:r}),this._decrease(i),!0}return!1}removeMin(){this._swap(0,this._arr.length-1);var e=this._arr.pop();return delete this._keyIndices[e.key],this._heapify(0),e.key}decrease(e,r){var t=this._keyIndices[e];if(r>this._arr[t].priority)throw new Error("New priority is greater than current priority. Key: "+e+" Old: "+this._arr[t].priority+" New: "+r);this._arr[t].priority=r,this._decrease(t)}_heapify(e){var r=this._arr,t=2*e,s=t+1,i=e;t>1,!(r[s].priority{var Oe=j();z.exports=ye;var je=()=>1;function ye(n,e,r,t){return Ne(n,String(e),r||je,t||function(s){return n.outEdges(s)})}function Ne(n,e,r,t){var s={},i=new Oe,a,o,u=function(h){var f=h.v!==a?h.v:h.w,l=s[f],_=r(h),v=o.distance+_;if(_<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+h+" Weight: "+_);v0&&(a=i.removeMin(),o=s[a],o.distance!==Number.POSITIVE_INFINITY);)t(a).forEach(u);return s}});var W=c((tr,U)=>{var ke=y();U.exports=Ie;function Ie(n,e,r){return n.nodes().reduce(function(t,s){return t[s]=ke(n,s,e,r),t},{})}});var N=c((sr,Y)=>{Y.exports=Ce;function Ce(n){var e=0,r=[],t={},s=[];function i(a){var o=t[a]={onStack:!0,lowlink:e,index:e++};if(r.push(a),n.successors(a).forEach(function(f){Object.hasOwn(t,f)?t[f].onStack&&(o.lowlink=Math.min(o.lowlink,t[f].index)):(i(f),o.lowlink=Math.min(o.lowlink,t[f].lowlink))}),o.lowlink===o.index){var u=[],h;do h=r.pop(),t[h].onStack=!1,u.push(h);while(a!==h);s.push(u)}}return n.nodes().forEach(function(a){Object.hasOwn(t,a)||i(a)}),s}});var K=c((ir,H)=>{var qe=N();H.exports=xe;function xe(n){return qe(n).filter(function(e){return e.length>1||e.length===1&&n.hasEdge(e[0],e[0])})}});var Q=c((nr,R)=>{R.exports=Le;var De=()=>1;function Le(n,e,r){return Fe(n,e||De,r||function(t){return n.outEdges(t)})}function Fe(n,e,r){var t={},s=n.nodes();return s.forEach(function(i){t[i]={},t[i][i]={distance:0},s.forEach(function(a){i!==a&&(t[i][a]={distance:Number.POSITIVE_INFINITY})}),r(i).forEach(function(a){var o=a.v===i?a.w:a.v,u=e(a);t[i][o]={distance:u,predecessor:i}})}),s.forEach(function(i){var a=t[i];s.forEach(function(o){var u=t[o];s.forEach(function(h){var f=u[i],l=a[h],_=u[h],v=f.distance+l.distance;v<_.distance&&(_.distance=v,_.predecessor=l.predecessor)})})}),t}});var k=c((ar,J)=>{function B(n){var e={},r={},t=[];function s(i){if(Object.hasOwn(r,i))throw new E;Object.hasOwn(e,i)||(r[i]=!0,e[i]=!0,n.predecessors(i).forEach(s),delete r[i],t.push(i))}if(n.sinks().forEach(s),Object.keys(e).length!==n.nodeCount())throw new E;return t}var E=class extends Error{constructor(){super(...arguments)}};J.exports=B;B.CycleException=E});var $=c((or,Z)=>{var X=k();Z.exports=Ae;function Ae(n){try{X(n)}catch(e){if(e instanceof X.CycleException)return!1;throw e}return!0}});var I=c((ur,re)=>{re.exports=Te;function Te(n,e,r){Array.isArray(e)||(e=[e]);var t=n.isDirected()?o=>n.successors(o):o=>n.neighbors(o),s=r==="post"?Me:Pe,i=[],a={};return e.forEach(o=>{if(!n.hasNode(o))throw new Error("Graph does not have node: "+o);s(o,t,a,i)}),i}function Me(n,e,r,t){for(var s=[[n,!1]];s.length>0;){var i=s.pop();i[1]?t.push(i[0]):Object.hasOwn(r,i[0])||(r[i[0]]=!0,s.push([i[0],!0]),ee(e(i[0]),a=>s.push([a,!1])))}}function Pe(n,e,r,t){for(var s=[n];s.length>0;){var i=s.pop();Object.hasOwn(r,i)||(r[i]=!0,t.push(i),ee(e(i),a=>s.push(a)))}}function ee(n,e){for(var r=n.length;r--;)e(n[r],r,n);return n}});var se=c((hr,te)=>{var Ge=I();te.exports=Se;function Se(n,e){return Ge(n,e,"post")}});var ne=c((dr,ie)=>{var Ve=I();ie.exports=ze;function ze(n,e){return Ve(n,e,"pre")}});var oe=c((cr,ae)=>{var Ue=b(),We=j();ae.exports=Ye;function Ye(n,e){var r=new Ue,t={},s=new We,i;function a(u){var h=u.v===i?u.w:u.v,f=s.priority(h);if(f!==void 0){var l=e(u);l0;){if(i=s.removeMin(),Object.hasOwn(t,i))r.setEdge(i,t[i]);else{if(o)throw new Error("Input graph is not connected: "+n);o=!0}n.nodeEdges(i).forEach(a)}return r}});var he=c((fr,ue)=>{ue.exports={components:S(),dijkstra:y(),dijkstraAll:W(),findCycles:K(),floydWarshall:Q(),isAcyclic:$(),postorder:se(),preorder:ne(),prim:oe(),tarjan:N(),topsort:k()}});var He=c((lr,ce)=>{var de=T();ce.exports={Graph:de.Graph,json:P(),alg:he(),version:de.version}});export default He(); -//# sourceMappingURL=dagre.esm.js.map +//# sourceMappingURL=graphlib.esm.js.map diff --git a/dist/dagre.esm.js.map b/dist/graphlib.esm.js.map similarity index 100% rename from dist/dagre.esm.js.map rename to dist/graphlib.esm.js.map diff --git a/dist/dagre.js b/dist/graphlib.js similarity index 99% rename from dist/dagre.js rename to dist/graphlib.js index 509dc0d1..a57072ba 100644 --- a/dist/dagre.js +++ b/dist/graphlib.js @@ -1,4 +1,4 @@ -var dagre = (() => { +var graphlib = (() => { var __defProp = Object.defineProperty; var __getOwnPropNames = Object.getOwnPropertyNames; var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value; @@ -1238,4 +1238,4 @@ var dagre = (() => { }); return require_index(); })(); -//# sourceMappingURL=dagre.js.map +//# sourceMappingURL=graphlib.js.map diff --git a/dist/dagre.js.map b/dist/graphlib.js.map similarity index 100% rename from dist/dagre.js.map rename to dist/graphlib.js.map diff --git a/dist/graphlib.min.js b/dist/graphlib.min.js new file mode 100644 index 00000000..2c26a72b --- /dev/null +++ b/dist/graphlib.min.js @@ -0,0 +1,2 @@ +var graphlib=(()=>{var fe=Object.defineProperty;var le=(n,e,r)=>e in n?fe(n,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):n[e]=r;var c=(n,e)=>()=>(e||n((e={exports:{}}).exports,e),e.exports);var d=(n,e,r)=>le(n,typeof e!="symbol"?e+"":e,r);var b=c((Re,D)=>{"use strict";var _e="\0",p="\0",C="",m=class{constructor(e){d(this,"_isDirected",!0);d(this,"_isMultigraph",!1);d(this,"_isCompound",!1);d(this,"_label");d(this,"_defaultNodeLabelFn",()=>{});d(this,"_defaultEdgeLabelFn",()=>{});d(this,"_nodes",{});d(this,"_in",{});d(this,"_preds",{});d(this,"_out",{});d(this,"_sucs",{});d(this,"_edgeObjs",{});d(this,"_edgeLabels",{});d(this,"_nodeCount",0);d(this,"_edgeCount",0);d(this,"_parent");d(this,"_children");e&&(this._isDirected=Object.hasOwn(e,"directed")?e.directed:!0,this._isMultigraph=Object.hasOwn(e,"multigraph")?e.multigraph:!1,this._isCompound=Object.hasOwn(e,"compound")?e.compound:!1),this._isCompound&&(this._parent={},this._children={},this._children[p]={})}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return this._defaultNodeLabelFn=e,typeof e!="function"&&(this._defaultNodeLabelFn=()=>e),this}nodeCount(){return this._nodeCount}nodes(){return Object.keys(this._nodes)}sources(){var e=this;return this.nodes().filter(r=>Object.keys(e._in[r]).length===0)}sinks(){var e=this;return this.nodes().filter(r=>Object.keys(e._out[r]).length===0)}setNodes(e,r){var t=arguments,s=this;return e.forEach(function(i){t.length>1?s.setNode(i,r):s.setNode(i)}),this}setNode(e,r){return Object.hasOwn(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=r),this):(this._nodes[e]=arguments.length>1?r:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=p,this._children[e]={},this._children[p][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.hasOwn(this._nodes,e)}removeNode(e){var r=this;if(Object.hasOwn(this._nodes,e)){var t=s=>r.removeEdge(r._edgeObjs[s]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],this.children(e).forEach(function(s){r.setParent(s)}),delete this._children[e]),Object.keys(this._in[e]).forEach(t),delete this._in[e],delete this._preds[e],Object.keys(this._out[e]).forEach(t),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,r){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(r===void 0)r=p;else{r+="";for(var t=r;t!==void 0;t=this.parent(t))if(t===e)throw new Error("Setting "+r+" as parent of "+e+" would create a cycle");this.setNode(r)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=r,this._children[r][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var r=this._parent[e];if(r!==p)return r}}children(e=p){if(this._isCompound){var r=this._children[e];if(r)return Object.keys(r)}else{if(e===p)return this.nodes();if(this.hasNode(e))return[]}}predecessors(e){var r=this._preds[e];if(r)return Object.keys(r)}successors(e){var r=this._sucs[e];if(r)return Object.keys(r)}neighbors(e){var r=this.predecessors(e);if(r){let s=new Set(r);for(var t of this.successors(e))s.add(t);return Array.from(s.values())}}isLeaf(e){var r;return this.isDirected()?r=this.successors(e):r=this.neighbors(e),r.length===0}filterNodes(e){var r=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});r.setGraph(this.graph());var t=this;Object.entries(this._nodes).forEach(function([a,o]){e(a)&&r.setNode(a,o)}),Object.values(this._edgeObjs).forEach(function(a){r.hasNode(a.v)&&r.hasNode(a.w)&&r.setEdge(a,t.edge(a))});var s={};function i(a){var o=t.parent(a);return o===void 0||r.hasNode(o)?(s[a]=o,o):o in s?s[o]:i(o)}return this._isCompound&&r.nodes().forEach(a=>r.setParent(a,i(a))),r}setDefaultEdgeLabel(e){return this._defaultEdgeLabelFn=e,typeof e!="function"&&(this._defaultEdgeLabelFn=()=>e),this}edgeCount(){return this._edgeCount}edges(){return Object.values(this._edgeObjs)}setPath(e,r){var t=this,s=arguments;return e.reduce(function(i,a){return s.length>1?t.setEdge(i,a,r):t.setEdge(i,a),a}),this}setEdge(){var e,r,t,s,i=!1,a=arguments[0];typeof a=="object"&&a!==null&&"v"in a?(e=a.v,r=a.w,t=a.name,arguments.length===2&&(s=arguments[1],i=!0)):(e=a,r=arguments[1],t=arguments[3],arguments.length>2&&(s=arguments[2],i=!0)),e=""+e,r=""+r,t!==void 0&&(t=""+t);var o=g(this._isDirected,e,r,t);if(Object.hasOwn(this._edgeLabels,o))return i&&(this._edgeLabels[o]=s),this;if(t!==void 0&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(r),this._edgeLabels[o]=i?s:this._defaultEdgeLabelFn(e,r,t);var u=pe(this._isDirected,e,r,t);return e=u.v,r=u.w,Object.freeze(u),this._edgeObjs[o]=u,q(this._preds[r],e),q(this._sucs[e],r),this._in[r][o]=u,this._out[e][o]=u,this._edgeCount++,this}edge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t);return this._edgeLabels[s]}edgeAsObj(){let e=this.edge(...arguments);return typeof e!="object"?{label:e}:e}hasEdge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t);return Object.hasOwn(this._edgeLabels,s)}removeEdge(e,r,t){var s=arguments.length===1?w(this._isDirected,arguments[0]):g(this._isDirected,e,r,t),i=this._edgeObjs[s];return i&&(e=i.v,r=i.w,delete this._edgeLabels[s],delete this._edgeObjs[s],x(this._preds[r],e),x(this._sucs[e],r),delete this._in[r][s],delete this._out[e][s],this._edgeCount--),this}inEdges(e,r){var t=this._in[e];if(t){var s=Object.values(t);return r?s.filter(i=>i.v===r):s}}outEdges(e,r){var t=this._out[e];if(t){var s=Object.values(t);return r?s.filter(i=>i.w===r):s}}nodeEdges(e,r){var t=this.inEdges(e,r);if(t)return t.concat(this.outEdges(e,r))}};function q(n,e){n[e]?n[e]++:n[e]=1}function x(n,e){--n[e]||delete n[e]}function g(n,e,r,t){var s=""+e,i=""+r;if(!n&&s>i){var a=s;s=i,i=a}return s+C+i+C+(t===void 0?_e:t)}function pe(n,e,r,t){var s=""+e,i=""+r;if(!n&&s>i){var a=s;s=i,i=a}var o={v:s,w:i};return t&&(o.name=t),o}function w(n,e){return g(n,e.v,e.w,e.name)}D.exports=m});var F=c((Be,L)=>{L.exports="2.2.5-pre"});var T=c((Je,A)=>{A.exports={Graph:b(),version:F()}});var P=c((Xe,M)=>{var ve=b();M.exports={write:ge,read:we};function ge(n){var e={options:{directed:n.isDirected(),multigraph:n.isMultigraph(),compound:n.isCompound()},nodes:Ee(n),edges:be(n)};return n.graph()!==void 0&&(e.value=structuredClone(n.graph())),e}function Ee(n){return n.nodes().map(function(e){var r=n.node(e),t=n.parent(e),s={v:e};return r!==void 0&&(s.value=r),t!==void 0&&(s.parent=t),s})}function be(n){return n.edges().map(function(e){var r=n.edge(e),t={v:e.v,w:e.w};return e.name!==void 0&&(t.name=e.name),r!==void 0&&(t.value=r),t})}function we(n){var e=new ve(n.options).setGraph(n.value);return n.nodes.forEach(function(r){e.setNode(r.v,r.value),r.parent&&e.setParent(r.v,r.parent)}),n.edges.forEach(function(r){e.setEdge({v:r.v,w:r.w,name:r.name},r.value)}),e}});var S=c((Ze,G)=>{G.exports=me;function me(n){var e={},r=[],t;function s(i){Object.hasOwn(e,i)||(e[i]=!0,t.push(i),n.successors(i).forEach(s),n.predecessors(i).forEach(s))}return n.nodes().forEach(function(i){t=[],s(i),t.length&&r.push(t)}),r}});var j=c(($e,V)=>{var O=class{constructor(){d(this,"_arr",[]);d(this,"_keyIndices",{})}size(){return this._arr.length}keys(){return this._arr.map(function(e){return e.key})}has(e){return Object.hasOwn(this._keyIndices,e)}priority(e){var r=this._keyIndices[e];if(r!==void 0)return this._arr[r].priority}min(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key}add(e,r){var t=this._keyIndices;if(e=String(e),!Object.hasOwn(t,e)){var s=this._arr,i=s.length;return t[e]=i,s.push({key:e,priority:r}),this._decrease(i),!0}return!1}removeMin(){this._swap(0,this._arr.length-1);var e=this._arr.pop();return delete this._keyIndices[e.key],this._heapify(0),e.key}decrease(e,r){var t=this._keyIndices[e];if(r>this._arr[t].priority)throw new Error("New priority is greater than current priority. Key: "+e+" Old: "+this._arr[t].priority+" New: "+r);this._arr[t].priority=r,this._decrease(t)}_heapify(e){var r=this._arr,t=2*e,s=t+1,i=e;t>1,!(r[s].priority{var Oe=j();z.exports=ye;var je=()=>1;function ye(n,e,r,t){return Ne(n,String(e),r||je,t||function(s){return n.outEdges(s)})}function Ne(n,e,r,t){var s={},i=new Oe,a,o,u=function(h){var f=h.v!==a?h.v:h.w,l=s[f],_=r(h),v=o.distance+_;if(_<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+h+" Weight: "+_);v0&&(a=i.removeMin(),o=s[a],o.distance!==Number.POSITIVE_INFINITY);)t(a).forEach(u);return s}});var W=c((tr,U)=>{var ke=y();U.exports=Ie;function Ie(n,e,r){return n.nodes().reduce(function(t,s){return t[s]=ke(n,s,e,r),t},{})}});var N=c((sr,Y)=>{Y.exports=Ce;function Ce(n){var e=0,r=[],t={},s=[];function i(a){var o=t[a]={onStack:!0,lowlink:e,index:e++};if(r.push(a),n.successors(a).forEach(function(f){Object.hasOwn(t,f)?t[f].onStack&&(o.lowlink=Math.min(o.lowlink,t[f].index)):(i(f),o.lowlink=Math.min(o.lowlink,t[f].lowlink))}),o.lowlink===o.index){var u=[],h;do h=r.pop(),t[h].onStack=!1,u.push(h);while(a!==h);s.push(u)}}return n.nodes().forEach(function(a){Object.hasOwn(t,a)||i(a)}),s}});var K=c((ir,H)=>{var qe=N();H.exports=xe;function xe(n){return qe(n).filter(function(e){return e.length>1||e.length===1&&n.hasEdge(e[0],e[0])})}});var Q=c((nr,R)=>{R.exports=Le;var De=()=>1;function Le(n,e,r){return Fe(n,e||De,r||function(t){return n.outEdges(t)})}function Fe(n,e,r){var t={},s=n.nodes();return s.forEach(function(i){t[i]={},t[i][i]={distance:0},s.forEach(function(a){i!==a&&(t[i][a]={distance:Number.POSITIVE_INFINITY})}),r(i).forEach(function(a){var o=a.v===i?a.w:a.v,u=e(a);t[i][o]={distance:u,predecessor:i}})}),s.forEach(function(i){var a=t[i];s.forEach(function(o){var u=t[o];s.forEach(function(h){var f=u[i],l=a[h],_=u[h],v=f.distance+l.distance;v<_.distance&&(_.distance=v,_.predecessor=l.predecessor)})})}),t}});var k=c((ar,J)=>{function B(n){var e={},r={},t=[];function s(i){if(Object.hasOwn(r,i))throw new E;Object.hasOwn(e,i)||(r[i]=!0,e[i]=!0,n.predecessors(i).forEach(s),delete r[i],t.push(i))}if(n.sinks().forEach(s),Object.keys(e).length!==n.nodeCount())throw new E;return t}var E=class extends Error{constructor(){super(...arguments)}};J.exports=B;B.CycleException=E});var $=c((or,Z)=>{var X=k();Z.exports=Ae;function Ae(n){try{X(n)}catch(e){if(e instanceof X.CycleException)return!1;throw e}return!0}});var I=c((ur,re)=>{re.exports=Te;function Te(n,e,r){Array.isArray(e)||(e=[e]);var t=n.isDirected()?o=>n.successors(o):o=>n.neighbors(o),s=r==="post"?Me:Pe,i=[],a={};return e.forEach(o=>{if(!n.hasNode(o))throw new Error("Graph does not have node: "+o);s(o,t,a,i)}),i}function Me(n,e,r,t){for(var s=[[n,!1]];s.length>0;){var i=s.pop();i[1]?t.push(i[0]):Object.hasOwn(r,i[0])||(r[i[0]]=!0,s.push([i[0],!0]),ee(e(i[0]),a=>s.push([a,!1])))}}function Pe(n,e,r,t){for(var s=[n];s.length>0;){var i=s.pop();Object.hasOwn(r,i)||(r[i]=!0,t.push(i),ee(e(i),a=>s.push(a)))}}function ee(n,e){for(var r=n.length;r--;)e(n[r],r,n);return n}});var se=c((hr,te)=>{var Ge=I();te.exports=Se;function Se(n,e){return Ge(n,e,"post")}});var ne=c((dr,ie)=>{var Ve=I();ie.exports=ze;function ze(n,e){return Ve(n,e,"pre")}});var oe=c((cr,ae)=>{var Ue=b(),We=j();ae.exports=Ye;function Ye(n,e){var r=new Ue,t={},s=new We,i;function a(u){var h=u.v===i?u.w:u.v,f=s.priority(h);if(f!==void 0){var l=e(u);l0;){if(i=s.removeMin(),Object.hasOwn(t,i))r.setEdge(i,t[i]);else{if(o)throw new Error("Input graph is not connected: "+n);o=!0}n.nodeEdges(i).forEach(a)}return r}});var he=c((fr,ue)=>{ue.exports={components:S(),dijkstra:y(),dijkstraAll:W(),findCycles:K(),floydWarshall:Q(),isAcyclic:$(),postorder:se(),preorder:ne(),prim:oe(),tarjan:N(),topsort:k()}});var He=c((lr,ce)=>{var de=T();ce.exports={Graph:de.Graph,json:P(),alg:he(),version:de.version}});return He();})(); +//# sourceMappingURL=graphlib.min.js.map diff --git a/dist/dagre.min.js.map b/dist/graphlib.min.js.map similarity index 99% rename from dist/dagre.min.js.map rename to dist/graphlib.min.js.map index db0d2d00..481bd9d2 100644 --- a/dist/dagre.min.js.map +++ b/dist/graphlib.min.js.map @@ -2,6 +2,6 @@ "version": 3, "sources": ["../lib/graph.js", "../lib/version.js", "../lib/index.js", "../lib/json.js", "../lib/alg/components.js", "../lib/data/priority-queue.js", "../lib/alg/dijkstra.js", "../lib/alg/dijkstra-all.js", "../lib/alg/tarjan.js", "../lib/alg/find-cycles.js", "../lib/alg/floyd-warshall.js", "../lib/alg/topsort.js", "../lib/alg/is-acyclic.js", "../lib/alg/dfs.js", "../lib/alg/postorder.js", "../lib/alg/preorder.js", "../lib/alg/prim.js", "../lib/alg/index.js", "../index.js"], "sourcesContent": ["\"use strict\";\n\nvar DEFAULT_EDGE_NAME = \"\\x00\";\nvar GRAPH_NODE = \"\\x00\";\nvar EDGE_KEY_DELIM = \"\\x01\";\n\n// Implementation notes:\n//\n// * Node id query functions should return string ids for the nodes\n// * Edge id query functions should return an \"edgeObj\", edge object, that is\n// composed of enough information to uniquely identify an edge: {v, w, name}.\n// * Internally we use an \"edgeId\", a stringified form of the edgeObj, to\n// reference edges. This is because we need a performant way to look these\n// edges up and, object properties, which have string keys, are the closest\n// we're going to get to a performant hashtable in JavaScript.\n\nclass Graph {\n _isDirected = true;\n _isMultigraph = false;\n _isCompound = false;\n\n // Label for the graph itself\n _label;\n\n // Defaults to be set when creating a new node\n _defaultNodeLabelFn = () => undefined;\n\n // Defaults to be set when creating a new edge\n _defaultEdgeLabelFn = () => undefined;\n\n // v -> label\n _nodes = {};\n\n // v -> edgeObj\n _in = {};\n\n // u -> v -> Number\n _preds = {};\n\n // v -> edgeObj\n _out = {};\n\n // v -> w -> Number\n _sucs = {};\n\n // e -> edgeObj\n _edgeObjs = {};\n\n // e -> label\n _edgeLabels = {};\n\n /* Number of nodes in the graph. Should only be changed by the implementation. */\n _nodeCount = 0;\n\n /* Number of edges in the graph. Should only be changed by the implementation. */\n _edgeCount = 0;\n\n _parent;\n\n _children;\n\n constructor(opts) {\n if (opts) {\n this._isDirected = Object.hasOwn(opts, \"directed\") ? opts.directed : true;\n this._isMultigraph = Object.hasOwn(opts, \"multigraph\") ? opts.multigraph : false;\n this._isCompound = Object.hasOwn(opts, \"compound\") ? opts.compound : false;\n }\n\n if (this._isCompound) {\n // v -> parent\n this._parent = {};\n\n // v -> children\n this._children = {};\n this._children[GRAPH_NODE] = {};\n }\n }\n\n /* === Graph functions ========= */\n\n /**\n * Whether graph was created with 'directed' flag set to true or not.\n */\n isDirected() {\n return this._isDirected;\n }\n\n /**\n * Whether graph was created with 'multigraph' flag set to true or not.\n */\n isMultigraph() {\n return this._isMultigraph;\n }\n\n /**\n * Whether graph was created with 'compound' flag set to true or not.\n */\n isCompound() {\n return this._isCompound;\n }\n\n /**\n * Sets the label of the graph.\n */\n setGraph(label) {\n this._label = label;\n return this;\n }\n\n /**\n * Gets the graph label.\n */\n graph() {\n return this._label;\n }\n\n\n /* === Node functions ========== */\n\n /**\n * Sets the default node label. If newDefault is a function, it will be\n * invoked ach time when setting a label for a node. Otherwise, this label\n * will be assigned as default label in case if no label was specified while\n * setting a node.\n * Complexity: O(1).\n */\n setDefaultNodeLabel(newDefault) {\n this._defaultNodeLabelFn = newDefault;\n if (typeof newDefault !== 'function') {\n this._defaultNodeLabelFn = () => newDefault;\n }\n\n return this;\n }\n\n /**\n * Gets the number of nodes in the graph.\n * Complexity: O(1).\n */\n nodeCount() {\n return this._nodeCount;\n }\n\n /**\n * Gets all nodes of the graph. Note, the in case of compound graph subnodes are\n * not included in list.\n * Complexity: O(1).\n */\n nodes() {\n return Object.keys(this._nodes);\n }\n\n /**\n * Gets list of nodes without in-edges.\n * Complexity: O(|V|).\n */\n sources() {\n var self = this;\n return this.nodes().filter(v => Object.keys(self._in[v]).length === 0);\n }\n\n /**\n * Gets list of nodes without out-edges.\n * Complexity: O(|V|).\n */\n sinks() {\n var self = this;\n return this.nodes().filter(v => Object.keys(self._out[v]).length === 0);\n }\n\n /**\n * Invokes setNode method for each node in names list.\n * Complexity: O(|names|).\n */\n setNodes(vs, value) {\n var args = arguments;\n var self = this;\n vs.forEach(function(v) {\n if (args.length > 1) {\n self.setNode(v, value);\n } else {\n self.setNode(v);\n }\n });\n return this;\n }\n\n /**\n * Creates or updates the value for the node v in the graph. If label is supplied\n * it is set as the value for the node. If label is not supplied and the node was\n * created by this call then the default node label will be assigned.\n * Complexity: O(1).\n */\n setNode(v, value) {\n if (Object.hasOwn(this._nodes, v)) {\n if (arguments.length > 1) {\n this._nodes[v] = value;\n }\n return this;\n }\n\n this._nodes[v] = arguments.length > 1 ? value : this._defaultNodeLabelFn(v);\n if (this._isCompound) {\n this._parent[v] = GRAPH_NODE;\n this._children[v] = {};\n this._children[GRAPH_NODE][v] = true;\n }\n this._in[v] = {};\n this._preds[v] = {};\n this._out[v] = {};\n this._sucs[v] = {};\n ++this._nodeCount;\n return this;\n }\n\n /**\n * Gets the label of node with specified name.\n * Complexity: O(|V|).\n */\n node(v) {\n return this._nodes[v];\n }\n\n /**\n * Detects whether graph has a node with specified name or not.\n */\n hasNode(v) {\n return Object.hasOwn(this._nodes, v);\n }\n\n /**\n * Remove the node with the name from the graph or do nothing if the node is not in\n * the graph. If the node was removed this function also removes any incident\n * edges.\n * Complexity: O(1).\n */\n removeNode(v) {\n var self = this;\n if (Object.hasOwn(this._nodes, v)) {\n var removeEdge = e => self.removeEdge(self._edgeObjs[e]);\n delete this._nodes[v];\n if (this._isCompound) {\n this._removeFromParentsChildList(v);\n delete this._parent[v];\n this.children(v).forEach(function(child) {\n self.setParent(child);\n });\n delete this._children[v];\n }\n Object.keys(this._in[v]).forEach(removeEdge);\n delete this._in[v];\n delete this._preds[v];\n Object.keys(this._out[v]).forEach(removeEdge);\n delete this._out[v];\n delete this._sucs[v];\n --this._nodeCount;\n }\n return this;\n }\n\n /**\n * Sets node p as a parent for node v if it is defined, or removes the\n * parent for v if p is undefined. Method throws an exception in case of\n * invoking it in context of noncompound graph.\n * Average-case complexity: O(1).\n */\n setParent(v, parent) {\n if (!this._isCompound) {\n throw new Error(\"Cannot set parent in a non-compound graph\");\n }\n\n if (parent === undefined) {\n parent = GRAPH_NODE;\n } else {\n // Coerce parent to string\n parent += \"\";\n for (var ancestor = parent; ancestor !== undefined; ancestor = this.parent(ancestor)) {\n if (ancestor === v) {\n throw new Error(\"Setting \" + parent+ \" as parent of \" + v +\n \" would create a cycle\");\n }\n }\n\n this.setNode(parent);\n }\n\n this.setNode(v);\n this._removeFromParentsChildList(v);\n this._parent[v] = parent;\n this._children[parent][v] = true;\n return this;\n }\n\n _removeFromParentsChildList(v) {\n delete this._children[this._parent[v]][v];\n }\n\n /**\n * Gets parent node for node v.\n * Complexity: O(1).\n */\n parent(v) {\n if (this._isCompound) {\n var parent = this._parent[v];\n if (parent !== GRAPH_NODE) {\n return parent;\n }\n }\n }\n\n /**\n * Gets list of direct children of node v.\n * Complexity: O(1).\n */\n children(v = GRAPH_NODE) {\n if (this._isCompound) {\n var children = this._children[v];\n if (children) {\n return Object.keys(children);\n }\n } else if (v === GRAPH_NODE) {\n return this.nodes();\n } else if (this.hasNode(v)) {\n return [];\n }\n }\n\n /**\n * Return all nodes that are predecessors of the specified node or undefined if node v is not in\n * the graph. Behavior is undefined for undirected graphs - use neighbors instead.\n * Complexity: O(|V|).\n */\n predecessors(v) {\n var predsV = this._preds[v];\n if (predsV) {\n return Object.keys(predsV);\n }\n }\n\n /**\n * Return all nodes that are successors of the specified node or undefined if node v is not in\n * the graph. Behavior is undefined for undirected graphs - use neighbors instead.\n * Complexity: O(|V|).\n */\n successors(v) {\n var sucsV = this._sucs[v];\n if (sucsV) {\n return Object.keys(sucsV);\n }\n }\n\n /**\n * Return all nodes that are predecessors or successors of the specified node or undefined if\n * node v is not in the graph.\n * Complexity: O(|V|).\n */\n neighbors(v) {\n var preds = this.predecessors(v);\n if (preds) {\n const union = new Set(preds);\n for (var succ of this.successors(v)) {\n union.add(succ);\n }\n\n return Array.from(union.values());\n }\n }\n\n isLeaf(v) {\n var neighbors;\n if (this.isDirected()) {\n neighbors = this.successors(v);\n } else {\n neighbors = this.neighbors(v);\n }\n return neighbors.length === 0;\n }\n\n /**\n * Creates new graph with nodes filtered via filter. Edges incident to rejected node\n * are also removed. In case of compound graph, if parent is rejected by filter,\n * than all its children are rejected too.\n * Average-case complexity: O(|E|+|V|).\n */\n filterNodes(filter) {\n var copy = new this.constructor({\n directed: this._isDirected,\n multigraph: this._isMultigraph,\n compound: this._isCompound\n });\n\n copy.setGraph(this.graph());\n\n var self = this;\n Object.entries(this._nodes).forEach(function([v, value]) {\n if (filter(v)) {\n copy.setNode(v, value);\n }\n });\n\n Object.values(this._edgeObjs).forEach(function(e) {\n if (copy.hasNode(e.v) && copy.hasNode(e.w)) {\n copy.setEdge(e, self.edge(e));\n }\n });\n\n var parents = {};\n function findParent(v) {\n var parent = self.parent(v);\n if (parent === undefined || copy.hasNode(parent)) {\n parents[v] = parent;\n return parent;\n } else if (parent in parents) {\n return parents[parent];\n } else {\n return findParent(parent);\n }\n }\n\n if (this._isCompound) {\n copy.nodes().forEach(v => copy.setParent(v, findParent(v)));\n }\n\n return copy;\n }\n\n /* === Edge functions ========== */\n\n /**\n * Sets the default edge label or factory function. This label will be\n * assigned as default label in case if no label was specified while setting\n * an edge or this function will be invoked each time when setting an edge\n * with no label specified and returned value * will be used as a label for edge.\n * Complexity: O(1).\n */\n setDefaultEdgeLabel(newDefault) {\n this._defaultEdgeLabelFn = newDefault;\n if (typeof newDefault !== 'function') {\n this._defaultEdgeLabelFn = () => newDefault;\n }\n\n return this;\n }\n\n /**\n * Gets the number of edges in the graph.\n * Complexity: O(1).\n */\n edgeCount() {\n return this._edgeCount;\n }\n\n /**\n * Gets edges of the graph. In case of compound graph subgraphs are not considered.\n * Complexity: O(|E|).\n */\n edges() {\n return Object.values(this._edgeObjs);\n }\n\n /**\n * Establish an edges path over the nodes in nodes list. If some edge is already\n * exists, it will update its label, otherwise it will create an edge between pair\n * of nodes with label provided or default label if no label provided.\n * Complexity: O(|nodes|).\n */\n setPath(vs, value) {\n var self = this;\n var args = arguments;\n vs.reduce(function(v, w) {\n if (args.length > 1) {\n self.setEdge(v, w, value);\n } else {\n self.setEdge(v, w);\n }\n return w;\n });\n return this;\n }\n\n /**\n * Creates or updates the label for the edge (v, w) with the optionally supplied\n * name. If label is supplied it is set as the value for the edge. If label is not\n * supplied and the edge was created by this call then the default edge label will\n * be assigned. The name parameter is only useful with multigraphs.\n */\n setEdge() {\n var v, w, name, value;\n var valueSpecified = false;\n var arg0 = arguments[0];\n\n if (typeof arg0 === \"object\" && arg0 !== null && \"v\" in arg0) {\n v = arg0.v;\n w = arg0.w;\n name = arg0.name;\n if (arguments.length === 2) {\n value = arguments[1];\n valueSpecified = true;\n }\n } else {\n v = arg0;\n w = arguments[1];\n name = arguments[3];\n if (arguments.length > 2) {\n value = arguments[2];\n valueSpecified = true;\n }\n }\n\n v = \"\" + v;\n w = \"\" + w;\n if (name !== undefined) {\n name = \"\" + name;\n }\n\n var e = edgeArgsToId(this._isDirected, v, w, name);\n if (Object.hasOwn(this._edgeLabels, e)) {\n if (valueSpecified) {\n this._edgeLabels[e] = value;\n }\n return this;\n }\n\n if (name !== undefined && !this._isMultigraph) {\n throw new Error(\"Cannot set a named edge when isMultigraph = false\");\n }\n\n // It didn't exist, so we need to create it.\n // First ensure the nodes exist.\n this.setNode(v);\n this.setNode(w);\n\n this._edgeLabels[e] = valueSpecified ? value : this._defaultEdgeLabelFn(v, w, name);\n\n var edgeObj = edgeArgsToObj(this._isDirected, v, w, name);\n // Ensure we add undirected edges in a consistent way.\n v = edgeObj.v;\n w = edgeObj.w;\n\n Object.freeze(edgeObj);\n this._edgeObjs[e] = edgeObj;\n incrementOrInitEntry(this._preds[w], v);\n incrementOrInitEntry(this._sucs[v], w);\n this._in[w][e] = edgeObj;\n this._out[v][e] = edgeObj;\n this._edgeCount++;\n return this;\n }\n\n /**\n * Gets the label for the specified edge.\n * Complexity: O(1).\n */\n edge(v, w, name) {\n var e = (arguments.length === 1\n ? edgeObjToId(this._isDirected, arguments[0])\n : edgeArgsToId(this._isDirected, v, w, name));\n return this._edgeLabels[e];\n }\n\n /**\n * Gets the label for the specified edge and converts it to an object.\n * Complexity: O(1)\n */\n edgeAsObj() {\n const edge = this.edge(...arguments);\n if (typeof edge !== \"object\") {\n return {label: edge};\n }\n\n return edge;\n }\n\n /**\n * Detects whether the graph contains specified edge or not. No subgraphs are considered.\n * Complexity: O(1).\n */\n hasEdge(v, w, name) {\n var e = (arguments.length === 1\n ? edgeObjToId(this._isDirected, arguments[0])\n : edgeArgsToId(this._isDirected, v, w, name));\n return Object.hasOwn(this._edgeLabels, e);\n }\n\n /**\n * Removes the specified edge from the graph. No subgraphs are considered.\n * Complexity: O(1).\n */\n removeEdge(v, w, name) {\n var e = (arguments.length === 1\n ? edgeObjToId(this._isDirected, arguments[0])\n : edgeArgsToId(this._isDirected, v, w, name));\n var edge = this._edgeObjs[e];\n if (edge) {\n v = edge.v;\n w = edge.w;\n delete this._edgeLabels[e];\n delete this._edgeObjs[e];\n decrementOrRemoveEntry(this._preds[w], v);\n decrementOrRemoveEntry(this._sucs[v], w);\n delete this._in[w][e];\n delete this._out[v][e];\n this._edgeCount--;\n }\n return this;\n }\n\n /**\n * Return all edges that point to the node v. Optionally filters those edges down to just those\n * coming from node u. Behavior is undefined for undirected graphs - use nodeEdges instead.\n * Complexity: O(|E|).\n */\n inEdges(v, u) {\n var inV = this._in[v];\n if (inV) {\n var edges = Object.values(inV);\n if (!u) {\n return edges;\n }\n return edges.filter(edge => edge.v === u);\n }\n }\n\n /**\n * Return all edges that are pointed at by node v. Optionally filters those edges down to just\n * those point to w. Behavior is undefined for undirected graphs - use nodeEdges instead.\n * Complexity: O(|E|).\n */\n outEdges(v, w) {\n var outV = this._out[v];\n if (outV) {\n var edges = Object.values(outV);\n if (!w) {\n return edges;\n }\n return edges.filter(edge => edge.w === w);\n }\n }\n\n /**\n * Returns all edges to or from node v regardless of direction. Optionally filters those edges\n * down to just those between nodes v and w regardless of direction.\n * Complexity: O(|E|).\n */\n nodeEdges(v, w) {\n var inEdges = this.inEdges(v, w);\n if (inEdges) {\n return inEdges.concat(this.outEdges(v, w));\n }\n }\n}\n\nfunction incrementOrInitEntry(map, k) {\n if (map[k]) {\n map[k]++;\n } else {\n map[k] = 1;\n }\n}\n\nfunction decrementOrRemoveEntry(map, k) {\n if (!--map[k]) { delete map[k]; }\n}\n\nfunction edgeArgsToId(isDirected, v_, w_, name) {\n var v = \"\" + v_;\n var w = \"\" + w_;\n if (!isDirected && v > w) {\n var tmp = v;\n v = w;\n w = tmp;\n }\n return v + EDGE_KEY_DELIM + w + EDGE_KEY_DELIM +\n (name === undefined ? DEFAULT_EDGE_NAME : name);\n}\n\nfunction edgeArgsToObj(isDirected, v_, w_, name) {\n var v = \"\" + v_;\n var w = \"\" + w_;\n if (!isDirected && v > w) {\n var tmp = v;\n v = w;\n w = tmp;\n }\n var edgeObj = { v: v, w: w };\n if (name) {\n edgeObj.name = name;\n }\n return edgeObj;\n}\n\nfunction edgeObjToId(isDirected, edgeObj) {\n return edgeArgsToId(isDirected, edgeObj.v, edgeObj.w, edgeObj.name);\n}\n\nmodule.exports = Graph;\n", "module.exports = '2.2.5-pre';\n", "// Includes only the \"core\" of graphlib\nmodule.exports = {\n Graph: require(\"./graph\"),\n version: require(\"./version\")\n};\n", "var Graph = require(\"./graph\");\n\nmodule.exports = {\n write: write,\n read: read\n};\n\n/**\n * Creates a JSON representation of the graph that can be serialized to a string with\n * JSON.stringify. The graph can later be restored using json.read.\n */\nfunction write(g) {\n var json = {\n options: {\n directed: g.isDirected(),\n multigraph: g.isMultigraph(),\n compound: g.isCompound()\n },\n nodes: writeNodes(g),\n edges: writeEdges(g)\n };\n\n if (g.graph() !== undefined) {\n json.value = structuredClone(g.graph());\n }\n return json;\n}\n\nfunction writeNodes(g) {\n return g.nodes().map(function(v) {\n var nodeValue = g.node(v);\n var parent = g.parent(v);\n var node = { v: v };\n if (nodeValue !== undefined) {\n node.value = nodeValue;\n }\n if (parent !== undefined) {\n node.parent = parent;\n }\n return node;\n });\n}\n\nfunction writeEdges(g) {\n return g.edges().map(function(e) {\n var edgeValue = g.edge(e);\n var edge = { v: e.v, w: e.w };\n if (e.name !== undefined) {\n edge.name = e.name;\n }\n if (edgeValue !== undefined) {\n edge.value = edgeValue;\n }\n return edge;\n });\n}\n\n/**\n * Takes JSON as input and returns the graph representation.\n *\n * @example\n * var g2 = graphlib.json.read(JSON.parse(str));\n * g2.nodes();\n * // ['a', 'b']\n * g2.edges()\n * // [ { v: 'a', w: 'b' } ]\n */\nfunction read(json) {\n var g = new Graph(json.options).setGraph(json.value);\n json.nodes.forEach(function(entry) {\n g.setNode(entry.v, entry.value);\n if (entry.parent) {\n g.setParent(entry.v, entry.parent);\n }\n });\n json.edges.forEach(function(entry) {\n g.setEdge({ v: entry.v, w: entry.w, name: entry.name }, entry.value);\n });\n return g;\n}\n", "module.exports = components;\n\nfunction components(g) {\n var visited = {};\n var cmpts = [];\n var cmpt;\n\n function dfs(v) {\n if (Object.hasOwn(visited, v)) return;\n visited[v] = true;\n cmpt.push(v);\n g.successors(v).forEach(dfs);\n g.predecessors(v).forEach(dfs);\n }\n\n g.nodes().forEach(function(v) {\n cmpt = [];\n dfs(v);\n if (cmpt.length) {\n cmpts.push(cmpt);\n }\n });\n\n return cmpts;\n}\n", "/**\n * A min-priority queue data structure. This algorithm is derived from Cormen,\n * et al., \"Introduction to Algorithms\". The basic idea of a min-priority\n * queue is that you can efficiently (in O(1) time) get the smallest key in\n * the queue. Adding and removing elements takes O(log n) time. A key can\n * have its priority decreased in O(log n) time.\n */\nclass PriorityQueue {\n _arr = [];\n _keyIndices = {};\n\n /**\n * Returns the number of elements in the queue. Takes `O(1)` time.\n */\n size() {\n return this._arr.length;\n }\n\n /**\n * Returns the keys that are in the queue. Takes `O(n)` time.\n */\n keys() {\n return this._arr.map(function(x) { return x.key; });\n }\n\n /**\n * Returns `true` if **key** is in the queue and `false` if not.\n */\n has(key) {\n return Object.hasOwn(this._keyIndices, key);\n }\n\n /**\n * Returns the priority for **key**. If **key** is not present in the queue\n * then this function returns `undefined`. Takes `O(1)` time.\n *\n * @param {Object} key\n */\n priority(key) {\n var index = this._keyIndices[key];\n if (index !== undefined) {\n return this._arr[index].priority;\n }\n }\n\n /**\n * Returns the key for the minimum element in this queue. If the queue is\n * empty this function throws an Error. Takes `O(1)` time.\n */\n min() {\n if (this.size() === 0) {\n throw new Error(\"Queue underflow\");\n }\n return this._arr[0].key;\n }\n\n /**\n * Inserts a new key into the priority queue. If the key already exists in\n * the queue this function returns `false`; otherwise it will return `true`.\n * Takes `O(n)` time.\n *\n * @param {Object} key the key to add\n * @param {Number} priority the initial priority for the key\n */\n add(key, priority) {\n var keyIndices = this._keyIndices;\n key = String(key);\n if (!Object.hasOwn(keyIndices, key)) {\n var arr = this._arr;\n var index = arr.length;\n keyIndices[key] = index;\n arr.push({key: key, priority: priority});\n this._decrease(index);\n return true;\n }\n return false;\n }\n\n /**\n * Removes and returns the smallest key in the queue. Takes `O(log n)` time.\n */\n removeMin() {\n this._swap(0, this._arr.length - 1);\n var min = this._arr.pop();\n delete this._keyIndices[min.key];\n this._heapify(0);\n return min.key;\n }\n\n /**\n * Decreases the priority for **key** to **priority**. If the new priority is\n * greater than the previous priority, this function will throw an Error.\n *\n * @param {Object} key the key for which to raise priority\n * @param {Number} priority the new priority for the key\n */\n decrease(key, priority) {\n var index = this._keyIndices[key];\n if (priority > this._arr[index].priority) {\n throw new Error(\"New priority is greater than current priority. \" +\n \"Key: \" + key + \" Old: \" + this._arr[index].priority + \" New: \" + priority);\n }\n this._arr[index].priority = priority;\n this._decrease(index);\n }\n\n _heapify(i) {\n var arr = this._arr;\n var l = 2 * i;\n var r = l + 1;\n var largest = i;\n if (l < arr.length) {\n largest = arr[l].priority < arr[largest].priority ? l : largest;\n if (r < arr.length) {\n largest = arr[r].priority < arr[largest].priority ? r : largest;\n }\n if (largest !== i) {\n this._swap(i, largest);\n this._heapify(largest);\n }\n }\n }\n\n _decrease(index) {\n var arr = this._arr;\n var priority = arr[index].priority;\n var parent;\n while (index !== 0) {\n parent = index >> 1;\n if (arr[parent].priority < priority) {\n break;\n }\n this._swap(index, parent);\n index = parent;\n }\n }\n\n _swap(i, j) {\n var arr = this._arr;\n var keyIndices = this._keyIndices;\n var origArrI = arr[i];\n var origArrJ = arr[j];\n arr[i] = origArrJ;\n arr[j] = origArrI;\n keyIndices[origArrJ.key] = i;\n keyIndices[origArrI.key] = j;\n }\n}\n\nmodule.exports = PriorityQueue;\n", "var PriorityQueue = require(\"../data/priority-queue\");\n\nmodule.exports = dijkstra;\n\nvar DEFAULT_WEIGHT_FUNC = () => 1;\n\nfunction dijkstra(g, source, weightFn, edgeFn) {\n return runDijkstra(g, String(source),\n weightFn || DEFAULT_WEIGHT_FUNC,\n edgeFn || function(v) { return g.outEdges(v); });\n}\n\nfunction runDijkstra(g, source, weightFn, edgeFn) {\n var results = {};\n var pq = new PriorityQueue();\n var v, vEntry;\n\n var updateNeighbors = function(edge) {\n var w = edge.v !== v ? edge.v : edge.w;\n var wEntry = results[w];\n var weight = weightFn(edge);\n var distance = vEntry.distance + weight;\n\n if (weight < 0) {\n throw new Error(\"dijkstra does not allow negative edge weights. \" +\n \"Bad edge: \" + edge + \" Weight: \" + weight);\n }\n\n if (distance < wEntry.distance) {\n wEntry.distance = distance;\n wEntry.predecessor = v;\n pq.decrease(w, distance);\n }\n };\n\n g.nodes().forEach(function(v) {\n var distance = v === source ? 0 : Number.POSITIVE_INFINITY;\n results[v] = { distance: distance };\n pq.add(v, distance);\n });\n\n while (pq.size() > 0) {\n v = pq.removeMin();\n vEntry = results[v];\n if (vEntry.distance === Number.POSITIVE_INFINITY) {\n break;\n }\n\n edgeFn(v).forEach(updateNeighbors);\n }\n\n return results;\n}\n", "var dijkstra = require(\"./dijkstra\");\n\nmodule.exports = dijkstraAll;\n\nfunction dijkstraAll(g, weightFunc, edgeFunc) {\n return g.nodes().reduce(function(acc, v) {\n acc[v] = dijkstra(g, v, weightFunc, edgeFunc);\n return acc;\n }, {});\n}\n", "module.exports = tarjan;\n\nfunction tarjan(g) {\n var index = 0;\n var stack = [];\n var visited = {}; // node id -> { onStack, lowlink, index }\n var results = [];\n\n function dfs(v) {\n var entry = visited[v] = {\n onStack: true,\n lowlink: index,\n index: index++\n };\n stack.push(v);\n\n g.successors(v).forEach(function(w) {\n if (!Object.hasOwn(visited, w)) {\n dfs(w);\n entry.lowlink = Math.min(entry.lowlink, visited[w].lowlink);\n } else if (visited[w].onStack) {\n entry.lowlink = Math.min(entry.lowlink, visited[w].index);\n }\n });\n\n if (entry.lowlink === entry.index) {\n var cmpt = [];\n var w;\n do {\n w = stack.pop();\n visited[w].onStack = false;\n cmpt.push(w);\n } while (v !== w);\n results.push(cmpt);\n }\n }\n\n g.nodes().forEach(function(v) {\n if (!Object.hasOwn(visited, v)) {\n dfs(v);\n }\n });\n\n return results;\n}\n", "var tarjan = require(\"./tarjan\");\n\nmodule.exports = findCycles;\n\nfunction findCycles(g) {\n return tarjan(g).filter(function(cmpt) {\n return cmpt.length > 1 || (cmpt.length === 1 && g.hasEdge(cmpt[0], cmpt[0]));\n });\n}\n", "module.exports = floydWarshall;\n\nvar DEFAULT_WEIGHT_FUNC = () => 1;\n\nfunction floydWarshall(g, weightFn, edgeFn) {\n return runFloydWarshall(g,\n weightFn || DEFAULT_WEIGHT_FUNC,\n edgeFn || function(v) { return g.outEdges(v); });\n}\n\nfunction runFloydWarshall(g, weightFn, edgeFn) {\n var results = {};\n var nodes = g.nodes();\n\n nodes.forEach(function(v) {\n results[v] = {};\n results[v][v] = { distance: 0 };\n nodes.forEach(function(w) {\n if (v !== w) {\n results[v][w] = { distance: Number.POSITIVE_INFINITY };\n }\n });\n edgeFn(v).forEach(function(edge) {\n var w = edge.v === v ? edge.w : edge.v;\n var d = weightFn(edge);\n results[v][w] = { distance: d, predecessor: v };\n });\n });\n\n nodes.forEach(function(k) {\n var rowK = results[k];\n nodes.forEach(function(i) {\n var rowI = results[i];\n nodes.forEach(function(j) {\n var ik = rowI[k];\n var kj = rowK[j];\n var ij = rowI[j];\n var altDistance = ik.distance + kj.distance;\n if (altDistance < ij.distance) {\n ij.distance = altDistance;\n ij.predecessor = kj.predecessor;\n }\n });\n });\n });\n\n return results;\n}\n", "function topsort(g) {\n var visited = {};\n var stack = {};\n var results = [];\n\n function visit(node) {\n if (Object.hasOwn(stack, node)) {\n throw new CycleException();\n }\n\n if (!Object.hasOwn(visited, node)) {\n stack[node] = true;\n visited[node] = true;\n g.predecessors(node).forEach(visit);\n delete stack[node];\n results.push(node);\n }\n }\n\n g.sinks().forEach(visit);\n\n if (Object.keys(visited).length !== g.nodeCount()) {\n throw new CycleException();\n }\n\n return results;\n}\n\nclass CycleException extends Error {\n constructor() {\n super(...arguments);\n }\n}\n\nmodule.exports = topsort;\ntopsort.CycleException = CycleException;\n", "var topsort = require(\"./topsort\");\n\nmodule.exports = isAcyclic;\n\nfunction isAcyclic(g) {\n try {\n topsort(g);\n } catch (e) {\n if (e instanceof topsort.CycleException) {\n return false;\n }\n throw e;\n }\n return true;\n}\n", "module.exports = dfs;\n\n/*\n * A helper that preforms a pre- or post-order traversal on the input graph\n * and returns the nodes in the order they were visited. If the graph is\n * undirected then this algorithm will navigate using neighbors. If the graph\n * is directed then this algorithm will navigate using successors.\n *\n * If the order is not \"post\", it will be treated as \"pre\".\n */\nfunction dfs(g, vs, order) {\n if (!Array.isArray(vs)) {\n vs = [vs];\n }\n\n var navigation = g.isDirected() ? v => g.successors(v) : v => g.neighbors(v);\n var orderFunc = order === \"post\" ? postOrderDfs : preOrderDfs;\n\n var acc = [];\n var visited = {};\n vs.forEach(v => {\n if (!g.hasNode(v)) {\n throw new Error(\"Graph does not have node: \" + v);\n }\n\n orderFunc(v, navigation, visited, acc);\n });\n\n return acc;\n}\n\nfunction postOrderDfs(v, navigation, visited, acc) {\n var stack = [[v, false]];\n while (stack.length > 0) {\n var curr = stack.pop();\n if (curr[1]) {\n acc.push(curr[0]);\n } else {\n if (!Object.hasOwn(visited, curr[0])) {\n visited[curr[0]] = true;\n stack.push([curr[0], true]);\n forEachRight(navigation(curr[0]), w => stack.push([w, false]));\n }\n }\n }\n}\n\nfunction preOrderDfs(v, navigation, visited, acc) {\n var stack = [v];\n while (stack.length > 0) {\n var curr = stack.pop();\n if (!Object.hasOwn(visited, curr)) {\n visited[curr] = true;\n acc.push(curr);\n forEachRight(navigation(curr), w => stack.push(w));\n }\n }\n}\n\nfunction forEachRight(array, iteratee) {\n var length = array.length;\n while (length--) {\n iteratee(array[length], length, array);\n }\n\n return array;\n}\n", "var dfs = require(\"./dfs\");\n\nmodule.exports = postorder;\n\nfunction postorder(g, vs) {\n return dfs(g, vs, \"post\");\n}\n", "var dfs = require(\"./dfs\");\n\nmodule.exports = preorder;\n\nfunction preorder(g, vs) {\n return dfs(g, vs, \"pre\");\n}\n", "var Graph = require(\"../graph\");\nvar PriorityQueue = require(\"../data/priority-queue\");\n\nmodule.exports = prim;\n\nfunction prim(g, weightFunc) {\n var result = new Graph();\n var parents = {};\n var pq = new PriorityQueue();\n var v;\n\n function updateNeighbors(edge) {\n var w = edge.v === v ? edge.w : edge.v;\n var pri = pq.priority(w);\n if (pri !== undefined) {\n var edgeWeight = weightFunc(edge);\n if (edgeWeight < pri) {\n parents[w] = v;\n pq.decrease(w, edgeWeight);\n }\n }\n }\n\n if (g.nodeCount() === 0) {\n return result;\n }\n\n g.nodes().forEach(function(v) {\n pq.add(v, Number.POSITIVE_INFINITY);\n result.setNode(v);\n });\n\n // Start from an arbitrary node\n pq.decrease(g.nodes()[0], 0);\n\n var init = false;\n while (pq.size() > 0) {\n v = pq.removeMin();\n if (Object.hasOwn(parents, v)) {\n result.setEdge(v, parents[v]);\n } else if (init) {\n throw new Error(\"Input graph is not connected: \" + g);\n } else {\n init = true;\n }\n\n g.nodeEdges(v).forEach(updateNeighbors);\n }\n\n return result;\n}\n", "module.exports = {\n components: require(\"./components\"),\n dijkstra: require(\"./dijkstra\"),\n dijkstraAll: require(\"./dijkstra-all\"),\n findCycles: require(\"./find-cycles\"),\n floydWarshall: require(\"./floyd-warshall\"),\n isAcyclic: require(\"./is-acyclic\"),\n postorder: require(\"./postorder\"),\n preorder: require(\"./preorder\"),\n prim: require(\"./prim\"),\n tarjan: require(\"./tarjan\"),\n topsort: require(\"./topsort\")\n};\n", "/**\n * Copyright (c) 2014, Chris Pettitt\n * All rights reserved.\n *\n * Redistribution and use in source and binary forms, with or without\n * modification, are permitted provided that the following conditions are met:\n *\n * 1. Redistributions of source code must retain the above copyright notice, this\n * list of conditions and the following disclaimer.\n *\n * 2. Redistributions in binary form must reproduce the above copyright notice,\n * this list of conditions and the following disclaimer in the documentation\n * and/or other materials provided with the distribution.\n *\n * 3. Neither the name of the copyright holder nor the names of its contributors\n * may be used to endorse or promote products derived from this software without\n * specific prior written permission.\n *\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND\n * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED\n * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\n * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE\n * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL\n * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR\n * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER\n * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,\n * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\n * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n */\n\nvar lib = require(\"./lib\");\n\nmodule.exports = {\n Graph: lib.Graph,\n json: require(\"./lib/json\"),\n alg: require(\"./lib/alg\"),\n version: lib.version\n};\n"], - "mappings": "sPAAA,IAAAA,EAAAC,EAAA,CAAAC,GAAAC,IAAA,cAEA,IAAIC,GAAoB,KACpBC,EAAa,KACbC,EAAiB,IAYfC,EAAN,KAAY,CA6CV,YAAYC,EAAM,CA5ClBC,EAAA,mBAAc,IACdA,EAAA,qBAAgB,IAChBA,EAAA,mBAAc,IAGdA,EAAA,eAGAA,EAAA,2BAAsB,IAAG,IAGzBA,EAAA,2BAAsB,IAAG,IAGzBA,EAAA,cAAS,CAAC,GAGVA,EAAA,WAAM,CAAC,GAGPA,EAAA,cAAS,CAAC,GAGVA,EAAA,YAAO,CAAC,GAGRA,EAAA,aAAQ,CAAC,GAGTA,EAAA,iBAAY,CAAC,GAGbA,EAAA,mBAAc,CAAC,GAGfA,EAAA,kBAAa,GAGbA,EAAA,kBAAa,GAEbA,EAAA,gBAEAA,EAAA,kBAGMD,IACF,KAAK,YAAc,OAAO,OAAOA,EAAM,UAAU,EAAIA,EAAK,SAAW,GACrE,KAAK,cAAgB,OAAO,OAAOA,EAAM,YAAY,EAAIA,EAAK,WAAa,GAC3E,KAAK,YAAc,OAAO,OAAOA,EAAM,UAAU,EAAIA,EAAK,SAAW,IAGnE,KAAK,cAEP,KAAK,QAAU,CAAC,EAGhB,KAAK,UAAY,CAAC,EAClB,KAAK,UAAUH,CAAU,EAAI,CA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V,YAAa,IACb,WAAY,IACZ,cAAe,IACf,UAAW,IACX,UAAW,KACX,SAAU,KACV,KAAM,KACN,OAAQ,IACR,QAAS,GACX,ICZA,IAAAC,GAAAC,EAAA,CAAAC,GAAAC,KAAA,CA8BA,IAAIC,GAAM,IAEVD,GAAO,QAAU,CACf,MAAOC,GAAI,MACX,KAAM,IACN,IAAK,KACL,QAASA,GAAI,OACf", "names": ["require_graph", "__commonJSMin", "exports", "module", "DEFAULT_EDGE_NAME", "GRAPH_NODE", "EDGE_KEY_DELIM", "Graph", "opts", "__publicField", "label", "newDefault", "self", "v", "vs", "value", "args", "removeEdge", "e", "child", "parent", "ancestor", "children", "predsV", "sucsV", "preds", "union", "succ", "neighbors", "filter", "copy", "parents", "findParent", "w", "name", "valueSpecified", "arg0", "edgeArgsToId", "edgeObj", "edgeArgsToObj", "incrementOrInitEntry", "edgeObjToId", "edge", "decrementOrRemoveEntry", "u", "inV", "edges", "outV", "inEdges", "map", "k", "isDirected", "v_", "w_", "tmp", "require_version", "__commonJSMin", "exports", "module", "require_lib", "__commonJSMin", "exports", "module", "require_json", "__commonJSMin", "exports", "module", "Graph", "write", "read", "g", "json", "writeNodes", "writeEdges", "v", "nodeValue", "parent", "node", "edgeValue", "edge", "entry", "require_components", "__commonJSMin", "exports", "module", "components", "g", "visited", "cmpts", "cmpt", "dfs", "v", "require_priority_queue", "__commonJSMin", "exports", "module", "PriorityQueue", "__publicField", "x", "key", "index", "priority", "keyIndices", "arr", "min", "i", "l", "r", "largest", "parent", "j", "origArrI", "origArrJ", "require_dijkstra", "__commonJSMin", "exports", "module", "PriorityQueue", "dijkstra", "DEFAULT_WEIGHT_FUNC", "g", "source", "weightFn", "edgeFn", "runDijkstra", "v", "results", "pq", "vEntry", "updateNeighbors", "edge", "w", "wEntry", "weight", "distance", "require_dijkstra_all", "__commonJSMin", "exports", "module", "dijkstra", "dijkstraAll", "g", "weightFunc", "edgeFunc", "acc", "v", "require_tarjan", "__commonJSMin", "exports", "module", "tarjan", "g", "index", "stack", "visited", "results", "dfs", "v", "entry", "w", "cmpt", "require_find_cycles", "__commonJSMin", "exports", "module", "tarjan", "findCycles", "g", "cmpt", "require_floyd_warshall", "__commonJSMin", "exports", "module", "floydWarshall", "DEFAULT_WEIGHT_FUNC", "g", "weightFn", "edgeFn", "runFloydWarshall", "v", "results", "nodes", "w", "edge", "d", "k", "rowK", "i", "rowI", "j", "ik", "kj", "ij", "altDistance", "require_topsort", "__commonJSMin", "exports", "module", "topsort", "g", "visited", "stack", "results", "visit", "node", "CycleException", "require_is_acyclic", "__commonJSMin", "exports", "module", "topsort", "isAcyclic", "g", "require_dfs", "__commonJSMin", "exports", "module", "dfs", "g", "vs", "order", "navigation", "v", "orderFunc", "postOrderDfs", "preOrderDfs", "acc", "visited", "stack", "curr", "forEachRight", "w", "array", "iteratee", "length", "require_postorder", "__commonJSMin", "exports", "module", "dfs", "postorder", "g", "vs", "require_preorder", "__commonJSMin", "exports", "module", "dfs", "preorder", "g", "vs", "require_prim", "__commonJSMin", "exports", "module", "Graph", "PriorityQueue", "prim", "g", "weightFunc", "result", "parents", "pq", "v", "updateNeighbors", "edge", "w", "pri", "edgeWeight", "init", "require_alg", "__commonJSMin", "exports", "module", "require_index", "__commonJSMin", "exports", "module", "lib"] }