bump electron 21 (#5173)

* bump electron 20

* bump to 21

* use node 16.16

* remove and bump deps

* package.lock

* fix package lock

* try 21.0.0

* oops

* remove ts-node

* package locks

* fix redirect and eror handling

* remove console.log

* remove react 18 override

* fix import

* update react-virtual api

* bump node-libcurl and electron

* bump node-libcurl to 2.3.5-6

Co-authored-by: Filipe Freire <livrofubia@gmail.com>
This commit is contained in:
Jack Kavanagh 2022-10-21 15:41:00 +01:00 committed by GitHub
parent 043a6991ea
commit 4f9027ad94
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
21 changed files with 3409 additions and 1725 deletions

2
.nvmrc
View File

@ -1 +1 @@
16.14.2
16.16.0

View File

@ -13,8 +13,8 @@
"ajv": "^8.6.2"
},
"devDependencies": {
"esbuild-runner": "2.2.1",
"jest": "^28.1.0",
"ts-node": "^10.2.1",
"typescript": "^4.5.5",
"typescript-json-schema": "^0.50.1"
}
@ -582,6 +582,8 @@
"resolved": "https://registry.npmjs.org/@cspotcode/source-map-consumer/-/source-map-consumer-0.8.0.tgz",
"integrity": "sha512-41qniHzTU8yAGbCp04ohlmSrZf8bkf/iJsl3V0dRGsQN/5GFfx+LbCSsCpp2gqrqjTVg/K6O8ycoV35JIwAzAg==",
"dev": true,
"optional": true,
"peer": true,
"engines": {
"node": ">= 12"
}
@ -591,6 +593,8 @@
"resolved": "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.6.1.tgz",
"integrity": "sha512-DX3Z+T5dt1ockmPdobJS/FAsQPW4V4SrWEhD2iYQT2Cb2tQsiMnYxrcUH9By/Z3B+v0S5LMBkQtV/XOBbpLEOg==",
"dev": true,
"optional": true,
"peer": true,
"dependencies": {
"@cspotcode/source-map-consumer": "0.8.0"
},
@ -598,6 +602,40 @@
"node": ">=12"
}
},
"node_modules/@esbuild/android-arm": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.15.12.tgz",
"integrity": "sha512-IC7TqIqiyE0MmvAhWkl/8AEzpOtbhRNDo7aph47We1NbE5w2bt/Q+giAhe0YYeVpYnIhGMcuZY92qDK6dQauvA==",
"cpu": [
"arm"
],
"dev": true,
"optional": true,
"os": [
"android"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/@esbuild/linux-loong64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.15.12.tgz",
"integrity": "sha512-tZEowDjvU7O7I04GYvWQOS4yyP9E/7YlsB0jjw1Ycukgr2ycEzKyIk5tms5WnLBymaewc6VmRKnn5IJWgK4eFw==",
"cpu": [
"loong64"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/@istanbuljs/load-nyc-config": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/@istanbuljs/load-nyc-config/-/load-nyc-config-1.1.0.tgz",
@ -976,25 +1014,33 @@
"version": "1.0.8",
"resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.8.tgz",
"integrity": "sha512-6XFfSQmMgq0CFLY1MslA/CPUfhIL919M1rMsa5lP2P097N2Wd1sSX0tx1u4olM16fLNhtHZpRhedZJphNJqmZg==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"node_modules/@tsconfig/node12": {
"version": "1.0.9",
"resolved": "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.9.tgz",
"integrity": "sha512-/yBMcem+fbvhSREH+s14YJi18sp7J9jpuhYByADT2rypfajMZZN4WQ6zBGgBKp53NKmqI36wFYDb3yaMPurITw==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"node_modules/@tsconfig/node14": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.1.tgz",
"integrity": "sha512-509r2+yARFfHHE7T6Puu2jjkoycftovhXRqW328PDXTVGKihlb1P8Z9mMZH04ebyajfRY7dedfGynlrFHJUQCg==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"node_modules/@tsconfig/node16": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.2.tgz",
"integrity": "sha512-eZxlbI8GZscaGS7kkc/trHTT5xgrjH3/1n2JDwusC9iahPKWMRvRjJSAN5mCXviuTGQ/lHnhvv8Q1YTpnfz9gA==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"node_modules/@types/babel__core": {
"version": "7.1.19",
@ -1114,6 +1160,8 @@
"resolved": "https://registry.npmjs.org/acorn/-/acorn-8.5.0.tgz",
"integrity": "sha512-yXbYeFy+jUuYd3/CDcg2NkIYE991XYX/bje7LmjJigUciaeO1JR4XxXgCIV1/Zc/dRuFEyw1L0pbA+qynJkW5Q==",
"dev": true,
"optional": true,
"peer": true,
"bin": {
"acorn": "bin/acorn"
},
@ -1609,6 +1657,410 @@
"is-arrayish": "^0.2.1"
}
},
"node_modules/esbuild": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.15.12.tgz",
"integrity": "sha512-PcT+/wyDqJQsRVhaE9uX/Oq4XLrFh0ce/bs2TJh4CSaw9xuvI+xFrH2nAYOADbhQjUgAhNWC5LKoUsakm4dxng==",
"dev": true,
"hasInstallScript": true,
"peer": true,
"bin": {
"esbuild": "bin/esbuild"
},
"engines": {
"node": ">=12"
},
"optionalDependencies": {
"@esbuild/android-arm": "0.15.12",
"@esbuild/linux-loong64": "0.15.12",
"esbuild-android-64": "0.15.12",
"esbuild-android-arm64": "0.15.12",
"esbuild-darwin-64": "0.15.12",
"esbuild-darwin-arm64": "0.15.12",
"esbuild-freebsd-64": "0.15.12",
"esbuild-freebsd-arm64": "0.15.12",
"esbuild-linux-32": "0.15.12",
"esbuild-linux-64": "0.15.12",
"esbuild-linux-arm": "0.15.12",
"esbuild-linux-arm64": "0.15.12",
"esbuild-linux-mips64le": "0.15.12",
"esbuild-linux-ppc64le": "0.15.12",
"esbuild-linux-riscv64": "0.15.12",
"esbuild-linux-s390x": "0.15.12",
"esbuild-netbsd-64": "0.15.12",
"esbuild-openbsd-64": "0.15.12",
"esbuild-sunos-64": "0.15.12",
"esbuild-windows-32": "0.15.12",
"esbuild-windows-64": "0.15.12",
"esbuild-windows-arm64": "0.15.12"
}
},
"node_modules/esbuild-android-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-android-64/-/esbuild-android-64-0.15.12.tgz",
"integrity": "sha512-MJKXwvPY9g0rGps0+U65HlTsM1wUs9lbjt5CU19RESqycGFDRijMDQsh68MtbzkqWSRdEtiKS1mtPzKneaAI0Q==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"android"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-android-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-android-arm64/-/esbuild-android-arm64-0.15.12.tgz",
"integrity": "sha512-Hc9SEcZbIMhhLcvhr1DH+lrrec9SFTiRzfJ7EGSBZiiw994gfkVV6vG0sLWqQQ6DD7V4+OggB+Hn0IRUdDUqvA==",
"cpu": [
"arm64"
],
"dev": true,
"optional": true,
"os": [
"android"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-darwin-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-darwin-64/-/esbuild-darwin-64-0.15.12.tgz",
"integrity": "sha512-qkmqrTVYPFiePt5qFjP8w/S+GIUMbt6k8qmiPraECUWfPptaPJUGkCKrWEfYFRWB7bY23FV95rhvPyh/KARP8Q==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"darwin"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-darwin-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.15.12.tgz",
"integrity": "sha512-z4zPX02tQ41kcXMyN3c/GfZpIjKoI/BzHrdKUwhC/Ki5BAhWv59A9M8H+iqaRbwpzYrYidTybBwiZAIWCLJAkw==",
"cpu": [
"arm64"
],
"dev": true,
"optional": true,
"os": [
"darwin"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-freebsd-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-freebsd-64/-/esbuild-freebsd-64-0.15.12.tgz",
"integrity": "sha512-XFL7gKMCKXLDiAiBjhLG0XECliXaRLTZh6hsyzqUqPUf/PY4C6EJDTKIeqqPKXaVJ8+fzNek88285krSz1QECw==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"freebsd"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-freebsd-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.15.12.tgz",
"integrity": "sha512-jwEIu5UCUk6TjiG1X+KQnCGISI+ILnXzIzt9yDVrhjug2fkYzlLbl0K43q96Q3KB66v6N1UFF0r5Ks4Xo7i72g==",
"cpu": [
"arm64"
],
"dev": true,
"optional": true,
"os": [
"freebsd"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-32": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-32/-/esbuild-linux-32-0.15.12.tgz",
"integrity": "sha512-uSQuSEyF1kVzGzuIr4XM+v7TPKxHjBnLcwv2yPyCz8riV8VUCnO/C4BF3w5dHiVpCd5Z1cebBtZJNlC4anWpwA==",
"cpu": [
"ia32"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-64/-/esbuild-linux-64-0.15.12.tgz",
"integrity": "sha512-QcgCKb7zfJxqT9o5z9ZUeGH1k8N6iX1Y7VNsEi5F9+HzN1OIx7ESxtQXDN9jbeUSPiRH1n9cw6gFT3H4qbdvcA==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-arm": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-arm/-/esbuild-linux-arm-0.15.12.tgz",
"integrity": "sha512-Wf7T0aNylGcLu7hBnzMvsTfEXdEdJY/hY3u36Vla21aY66xR0MS5I1Hw8nVquXjTN0A6fk/vnr32tkC/C2lb0A==",
"cpu": [
"arm"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-arm64/-/esbuild-linux-arm64-0.15.12.tgz",
"integrity": "sha512-HtNq5xm8fUpZKwWKS2/YGwSfTF+339L4aIA8yphNKYJckd5hVdhfdl6GM2P3HwLSCORS++++7++//ApEwXEuAQ==",
"cpu": [
"arm64"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-mips64le": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.15.12.tgz",
"integrity": "sha512-Qol3+AvivngUZkTVFgLpb0H6DT+N5/zM3V1YgTkryPYFeUvuT5JFNDR3ZiS6LxhyF8EE+fiNtzwlPqMDqVcc6A==",
"cpu": [
"mips64el"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-ppc64le": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.15.12.tgz",
"integrity": "sha512-4D8qUCo+CFKaR0cGXtGyVsOI7w7k93Qxb3KFXWr75An0DHamYzq8lt7TNZKoOq/Gh8c40/aKaxvcZnTgQ0TJNg==",
"cpu": [
"ppc64"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-riscv64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-riscv64/-/esbuild-linux-riscv64-0.15.12.tgz",
"integrity": "sha512-G9w6NcuuCI6TUUxe6ka0enjZHDnSVK8bO+1qDhMOCtl7Tr78CcZilJj8SGLN00zO5iIlwNRZKHjdMpfFgNn1VA==",
"cpu": [
"riscv64"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-s390x": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-s390x/-/esbuild-linux-s390x-0.15.12.tgz",
"integrity": "sha512-Lt6BDnuXbXeqSlVuuUM5z18GkJAZf3ERskGZbAWjrQoi9xbEIsj/hEzVnSAFLtkfLuy2DE4RwTcX02tZFunXww==",
"cpu": [
"s390x"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-netbsd-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-netbsd-64/-/esbuild-netbsd-64-0.15.12.tgz",
"integrity": "sha512-jlUxCiHO1dsqoURZDQts+HK100o0hXfi4t54MNRMCAqKGAV33JCVvMplLAa2FwviSojT/5ZG5HUfG3gstwAG8w==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"netbsd"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-openbsd-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-openbsd-64/-/esbuild-openbsd-64-0.15.12.tgz",
"integrity": "sha512-1o1uAfRTMIWNOmpf8v7iudND0L6zRBYSH45sofCZywrcf7NcZA+c7aFsS1YryU+yN7aRppTqdUK1PgbZVaB1Dw==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"openbsd"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-runner": {
"version": "2.2.1",
"resolved": "https://registry.npmjs.org/esbuild-runner/-/esbuild-runner-2.2.1.tgz",
"integrity": "sha512-VP0VfJJZiZ3cKzdOH59ZceDxx/GzBKra7tiGM8MfFMLv6CR1/cpsvtQ3IsJI3pz7HyeYxtbPyecj3fHwR+3XcQ==",
"dev": true,
"dependencies": {
"source-map-support": "0.5.19",
"tslib": "2.3.1"
},
"bin": {
"esr": "bin/esr.js"
},
"peerDependencies": {
"esbuild": "*"
}
},
"node_modules/esbuild-runner/node_modules/source-map-support": {
"version": "0.5.19",
"resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.19.tgz",
"integrity": "sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==",
"dev": true,
"dependencies": {
"buffer-from": "^1.0.0",
"source-map": "^0.6.0"
}
},
"node_modules/esbuild-sunos-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-sunos-64/-/esbuild-sunos-64-0.15.12.tgz",
"integrity": "sha512-nkl251DpoWoBO9Eq9aFdoIt2yYmp4I3kvQjba3jFKlMXuqQ9A4q+JaqdkCouG3DHgAGnzshzaGu6xofGcXyPXg==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"sunos"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-windows-32": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-windows-32/-/esbuild-windows-32-0.15.12.tgz",
"integrity": "sha512-WlGeBZHgPC00O08luIp5B2SP4cNCp/PcS+3Pcg31kdcJPopHxLkdCXtadLU9J82LCfw4TVls21A6lilQ9mzHrw==",
"cpu": [
"ia32"
],
"dev": true,
"optional": true,
"os": [
"win32"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-windows-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-windows-64/-/esbuild-windows-64-0.15.12.tgz",
"integrity": "sha512-VActO3WnWZSN//xjSfbiGOSyC+wkZtI8I4KlgrTo5oHJM6z3MZZBCuFaZHd8hzf/W9KPhF0lY8OqlmWC9HO5AA==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"win32"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-windows-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-windows-arm64/-/esbuild-windows-arm64-0.15.12.tgz",
"integrity": "sha512-Of3MIacva1OK/m4zCNIvBfz8VVROBmQT+gRX6pFTLPngFYcj6TFH/12VveAqq1k9VB2l28EoVMNMUCcmsfwyuA==",
"cpu": [
"arm64"
],
"dev": true,
"optional": true,
"os": [
"win32"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/escalade": {
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz",
@ -3446,6 +3898,8 @@
"resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.2.1.tgz",
"integrity": "sha512-hCnyOyuGmD5wHleOQX6NIjJtYVIO8bPP8F2acWkB4W06wdlkgyvJtubO/I9NkI88hCFECbsEgoLc0VNkYmcSfw==",
"dev": true,
"optional": true,
"peer": true,
"dependencies": {
"@cspotcode/source-map-support": "0.6.1",
"@tsconfig/node10": "^1.0.7",
@ -3490,10 +3944,18 @@
"resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz",
"integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==",
"dev": true,
"optional": true,
"peer": true,
"engines": {
"node": ">=0.4.0"
}
},
"node_modules/tslib": {
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/tslib/-/tslib-2.3.1.tgz",
"integrity": "sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw==",
"dev": true
},
"node_modules/type-detect": {
"version": "4.0.8",
"resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz",
@ -4142,17 +4604,37 @@
"version": "0.8.0",
"resolved": "https://registry.npmjs.org/@cspotcode/source-map-consumer/-/source-map-consumer-0.8.0.tgz",
"integrity": "sha512-41qniHzTU8yAGbCp04ohlmSrZf8bkf/iJsl3V0dRGsQN/5GFfx+LbCSsCpp2gqrqjTVg/K6O8ycoV35JIwAzAg==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"@cspotcode/source-map-support": {
"version": "0.6.1",
"resolved": "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.6.1.tgz",
"integrity": "sha512-DX3Z+T5dt1ockmPdobJS/FAsQPW4V4SrWEhD2iYQT2Cb2tQsiMnYxrcUH9By/Z3B+v0S5LMBkQtV/XOBbpLEOg==",
"dev": true,
"optional": true,
"peer": true,
"requires": {
"@cspotcode/source-map-consumer": "0.8.0"
}
},
"@esbuild/android-arm": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.15.12.tgz",
"integrity": "sha512-IC7TqIqiyE0MmvAhWkl/8AEzpOtbhRNDo7aph47We1NbE5w2bt/Q+giAhe0YYeVpYnIhGMcuZY92qDK6dQauvA==",
"dev": true,
"optional": true,
"peer": true
},
"@esbuild/linux-loong64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.15.12.tgz",
"integrity": "sha512-tZEowDjvU7O7I04GYvWQOS4yyP9E/7YlsB0jjw1Ycukgr2ycEzKyIk5tms5WnLBymaewc6VmRKnn5IJWgK4eFw==",
"dev": true,
"optional": true,
"peer": true
},
"@istanbuljs/load-nyc-config": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/@istanbuljs/load-nyc-config/-/load-nyc-config-1.1.0.tgz",
@ -4458,25 +4940,33 @@
"version": "1.0.8",
"resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.8.tgz",
"integrity": "sha512-6XFfSQmMgq0CFLY1MslA/CPUfhIL919M1rMsa5lP2P097N2Wd1sSX0tx1u4olM16fLNhtHZpRhedZJphNJqmZg==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"@tsconfig/node12": {
"version": "1.0.9",
"resolved": "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.9.tgz",
"integrity": "sha512-/yBMcem+fbvhSREH+s14YJi18sp7J9jpuhYByADT2rypfajMZZN4WQ6zBGgBKp53NKmqI36wFYDb3yaMPurITw==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"@tsconfig/node14": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.1.tgz",
"integrity": "sha512-509r2+yARFfHHE7T6Puu2jjkoycftovhXRqW328PDXTVGKihlb1P8Z9mMZH04ebyajfRY7dedfGynlrFHJUQCg==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"@tsconfig/node16": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.2.tgz",
"integrity": "sha512-eZxlbI8GZscaGS7kkc/trHTT5xgrjH3/1n2JDwusC9iahPKWMRvRjJSAN5mCXviuTGQ/lHnhvv8Q1YTpnfz9gA==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"@types/babel__core": {
"version": "7.1.19",
@ -4595,7 +5085,9 @@
"version": "8.5.0",
"resolved": "https://registry.npmjs.org/acorn/-/acorn-8.5.0.tgz",
"integrity": "sha512-yXbYeFy+jUuYd3/CDcg2NkIYE991XYX/bje7LmjJigUciaeO1JR4XxXgCIV1/Zc/dRuFEyw1L0pbA+qynJkW5Q==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"ajv": {
"version": "8.6.2",
@ -4962,6 +5454,219 @@
"is-arrayish": "^0.2.1"
}
},
"esbuild": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.15.12.tgz",
"integrity": "sha512-PcT+/wyDqJQsRVhaE9uX/Oq4XLrFh0ce/bs2TJh4CSaw9xuvI+xFrH2nAYOADbhQjUgAhNWC5LKoUsakm4dxng==",
"dev": true,
"peer": true,
"requires": {
"@esbuild/android-arm": "0.15.12",
"@esbuild/linux-loong64": "0.15.12",
"esbuild-android-64": "0.15.12",
"esbuild-android-arm64": "0.15.12",
"esbuild-darwin-64": "0.15.12",
"esbuild-darwin-arm64": "0.15.12",
"esbuild-freebsd-64": "0.15.12",
"esbuild-freebsd-arm64": "0.15.12",
"esbuild-linux-32": "0.15.12",
"esbuild-linux-64": "0.15.12",
"esbuild-linux-arm": "0.15.12",
"esbuild-linux-arm64": "0.15.12",
"esbuild-linux-mips64le": "0.15.12",
"esbuild-linux-ppc64le": "0.15.12",
"esbuild-linux-riscv64": "0.15.12",
"esbuild-linux-s390x": "0.15.12",
"esbuild-netbsd-64": "0.15.12",
"esbuild-openbsd-64": "0.15.12",
"esbuild-sunos-64": "0.15.12",
"esbuild-windows-32": "0.15.12",
"esbuild-windows-64": "0.15.12",
"esbuild-windows-arm64": "0.15.12"
}
},
"esbuild-android-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-android-64/-/esbuild-android-64-0.15.12.tgz",
"integrity": "sha512-MJKXwvPY9g0rGps0+U65HlTsM1wUs9lbjt5CU19RESqycGFDRijMDQsh68MtbzkqWSRdEtiKS1mtPzKneaAI0Q==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-android-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-android-arm64/-/esbuild-android-arm64-0.15.12.tgz",
"integrity": "sha512-Hc9SEcZbIMhhLcvhr1DH+lrrec9SFTiRzfJ7EGSBZiiw994gfkVV6vG0sLWqQQ6DD7V4+OggB+Hn0IRUdDUqvA==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-darwin-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-darwin-64/-/esbuild-darwin-64-0.15.12.tgz",
"integrity": "sha512-qkmqrTVYPFiePt5qFjP8w/S+GIUMbt6k8qmiPraECUWfPptaPJUGkCKrWEfYFRWB7bY23FV95rhvPyh/KARP8Q==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-darwin-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.15.12.tgz",
"integrity": "sha512-z4zPX02tQ41kcXMyN3c/GfZpIjKoI/BzHrdKUwhC/Ki5BAhWv59A9M8H+iqaRbwpzYrYidTybBwiZAIWCLJAkw==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-freebsd-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-freebsd-64/-/esbuild-freebsd-64-0.15.12.tgz",
"integrity": "sha512-XFL7gKMCKXLDiAiBjhLG0XECliXaRLTZh6hsyzqUqPUf/PY4C6EJDTKIeqqPKXaVJ8+fzNek88285krSz1QECw==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-freebsd-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.15.12.tgz",
"integrity": "sha512-jwEIu5UCUk6TjiG1X+KQnCGISI+ILnXzIzt9yDVrhjug2fkYzlLbl0K43q96Q3KB66v6N1UFF0r5Ks4Xo7i72g==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-32": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-32/-/esbuild-linux-32-0.15.12.tgz",
"integrity": "sha512-uSQuSEyF1kVzGzuIr4XM+v7TPKxHjBnLcwv2yPyCz8riV8VUCnO/C4BF3w5dHiVpCd5Z1cebBtZJNlC4anWpwA==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-64/-/esbuild-linux-64-0.15.12.tgz",
"integrity": "sha512-QcgCKb7zfJxqT9o5z9ZUeGH1k8N6iX1Y7VNsEi5F9+HzN1OIx7ESxtQXDN9jbeUSPiRH1n9cw6gFT3H4qbdvcA==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-arm": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-arm/-/esbuild-linux-arm-0.15.12.tgz",
"integrity": "sha512-Wf7T0aNylGcLu7hBnzMvsTfEXdEdJY/hY3u36Vla21aY66xR0MS5I1Hw8nVquXjTN0A6fk/vnr32tkC/C2lb0A==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-arm64/-/esbuild-linux-arm64-0.15.12.tgz",
"integrity": "sha512-HtNq5xm8fUpZKwWKS2/YGwSfTF+339L4aIA8yphNKYJckd5hVdhfdl6GM2P3HwLSCORS++++7++//ApEwXEuAQ==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-mips64le": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.15.12.tgz",
"integrity": "sha512-Qol3+AvivngUZkTVFgLpb0H6DT+N5/zM3V1YgTkryPYFeUvuT5JFNDR3ZiS6LxhyF8EE+fiNtzwlPqMDqVcc6A==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-ppc64le": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.15.12.tgz",
"integrity": "sha512-4D8qUCo+CFKaR0cGXtGyVsOI7w7k93Qxb3KFXWr75An0DHamYzq8lt7TNZKoOq/Gh8c40/aKaxvcZnTgQ0TJNg==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-riscv64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-riscv64/-/esbuild-linux-riscv64-0.15.12.tgz",
"integrity": "sha512-G9w6NcuuCI6TUUxe6ka0enjZHDnSVK8bO+1qDhMOCtl7Tr78CcZilJj8SGLN00zO5iIlwNRZKHjdMpfFgNn1VA==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-s390x": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-s390x/-/esbuild-linux-s390x-0.15.12.tgz",
"integrity": "sha512-Lt6BDnuXbXeqSlVuuUM5z18GkJAZf3ERskGZbAWjrQoi9xbEIsj/hEzVnSAFLtkfLuy2DE4RwTcX02tZFunXww==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-netbsd-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-netbsd-64/-/esbuild-netbsd-64-0.15.12.tgz",
"integrity": "sha512-jlUxCiHO1dsqoURZDQts+HK100o0hXfi4t54MNRMCAqKGAV33JCVvMplLAa2FwviSojT/5ZG5HUfG3gstwAG8w==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-openbsd-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-openbsd-64/-/esbuild-openbsd-64-0.15.12.tgz",
"integrity": "sha512-1o1uAfRTMIWNOmpf8v7iudND0L6zRBYSH45sofCZywrcf7NcZA+c7aFsS1YryU+yN7aRppTqdUK1PgbZVaB1Dw==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-runner": {
"version": "2.2.1",
"resolved": "https://registry.npmjs.org/esbuild-runner/-/esbuild-runner-2.2.1.tgz",
"integrity": "sha512-VP0VfJJZiZ3cKzdOH59ZceDxx/GzBKra7tiGM8MfFMLv6CR1/cpsvtQ3IsJI3pz7HyeYxtbPyecj3fHwR+3XcQ==",
"dev": true,
"requires": {
"source-map-support": "0.5.19",
"tslib": "2.3.1"
},
"dependencies": {
"source-map-support": {
"version": "0.5.19",
"resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.19.tgz",
"integrity": "sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==",
"dev": true,
"requires": {
"buffer-from": "^1.0.0",
"source-map": "^0.6.0"
}
}
}
},
"esbuild-sunos-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-sunos-64/-/esbuild-sunos-64-0.15.12.tgz",
"integrity": "sha512-nkl251DpoWoBO9Eq9aFdoIt2yYmp4I3kvQjba3jFKlMXuqQ9A4q+JaqdkCouG3DHgAGnzshzaGu6xofGcXyPXg==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-windows-32": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-windows-32/-/esbuild-windows-32-0.15.12.tgz",
"integrity": "sha512-WlGeBZHgPC00O08luIp5B2SP4cNCp/PcS+3Pcg31kdcJPopHxLkdCXtadLU9J82LCfw4TVls21A6lilQ9mzHrw==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-windows-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-windows-64/-/esbuild-windows-64-0.15.12.tgz",
"integrity": "sha512-VActO3WnWZSN//xjSfbiGOSyC+wkZtI8I4KlgrTo5oHJM6z3MZZBCuFaZHd8hzf/W9KPhF0lY8OqlmWC9HO5AA==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-windows-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-windows-arm64/-/esbuild-windows-arm64-0.15.12.tgz",
"integrity": "sha512-Of3MIacva1OK/m4zCNIvBfz8VVROBmQT+gRX6pFTLPngFYcj6TFH/12VveAqq1k9VB2l28EoVMNMUCcmsfwyuA==",
"dev": true,
"optional": true,
"peer": true
},
"escalade": {
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz",
@ -6343,6 +7048,8 @@
"resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.2.1.tgz",
"integrity": "sha512-hCnyOyuGmD5wHleOQX6NIjJtYVIO8bPP8F2acWkB4W06wdlkgyvJtubO/I9NkI88hCFECbsEgoLc0VNkYmcSfw==",
"dev": true,
"optional": true,
"peer": true,
"requires": {
"@cspotcode/source-map-support": "0.6.1",
"@tsconfig/node10": "^1.0.7",
@ -6362,10 +7069,18 @@
"version": "8.2.0",
"resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz",
"integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==",
"dev": true
"dev": true,
"optional": true,
"peer": true
}
}
},
"tslib": {
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/tslib/-/tslib-2.3.1.tgz",
"integrity": "sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw==",
"dev": true
},
"type-detect": {
"version": "4.0.8",
"resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz",

View File

@ -22,7 +22,7 @@
"lint:fix": "npm run lint -- --fix",
"test": "jest",
"pregenerate": "npm run build",
"generate": "ts-node ./src/generated/generate.ts",
"generate": "esr ./src/generated/generate.ts",
"clean": "tsc --build tsconfig.build.json --clean",
"prebuild": "npm run clean",
"build": "tsc --build tsconfig.build.json"
@ -34,7 +34,7 @@
},
"devDependencies": {
"jest": "^28.1.0",
"ts-node": "^10.2.1",
"esbuild-runner": "2.2.1",
"typescript": "^4.5.5",
"typescript-json-schema": "^0.50.1"
}

View File

@ -45,8 +45,7 @@
"jest": "^28.1.0",
"jest-mock": "^28.0.2",
"pkg": "^5.3.2",
"rimraf": "^3.0.2",
"ts-node": "^9.1.1"
"rimraf": "^3.0.2"
}
},
"node_modules/@ampproject/remapping": {
@ -2007,7 +2006,9 @@
"version": "4.1.3",
"resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz",
"integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"node_modules/argparse": {
"version": "1.0.10",
@ -2605,7 +2606,9 @@
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz",
"integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"node_modules/cross-env": {
"version": "7.0.3",
@ -4917,7 +4920,9 @@
"version": "1.3.6",
"resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz",
"integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"node_modules/makeerror": {
"version": "1.0.12",
@ -6452,6 +6457,8 @@
"resolved": "https://registry.npmjs.org/ts-node/-/ts-node-9.1.1.tgz",
"integrity": "sha512-hPlt7ZACERQGf03M253ytLY3dHbGNGrAq9qIHWUY9XHYl1z7wYngSr3OQ5xmui8o2AaxsONxIzjafLUiWBo1Fg==",
"dev": true,
"optional": true,
"peer": true,
"dependencies": {
"arg": "^4.1.0",
"create-require": "^1.1.0",
@ -6478,6 +6485,8 @@
"resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz",
"integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==",
"dev": true,
"optional": true,
"peer": true,
"engines": {
"node": ">=0.3.1"
}
@ -6536,6 +6545,21 @@
"node": ">=8"
}
},
"node_modules/typescript": {
"version": "4.8.4",
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.8.4.tgz",
"integrity": "sha512-QCh+85mCy+h0IGff8r5XWzOVSbBO+KfeYrMQh7NJ58QujwcE22u+NUSmUxqF+un70P9GXKxa2HCNiTTMJknyjQ==",
"dev": true,
"optional": true,
"peer": true,
"bin": {
"tsc": "bin/tsc",
"tsserver": "bin/tsserver"
},
"engines": {
"node": ">=4.2.0"
}
},
"node_modules/underscore": {
"version": "1.4.4",
"resolved": "https://registry.npmjs.org/underscore/-/underscore-1.4.4.tgz",
@ -6846,6 +6870,8 @@
"resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz",
"integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==",
"dev": true,
"optional": true,
"peer": true,
"engines": {
"node": ">=6"
}
@ -8432,7 +8458,9 @@
"version": "4.1.3",
"resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz",
"integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"argparse": {
"version": "1.0.10",
@ -8888,7 +8916,9 @@
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz",
"integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"cross-env": {
"version": "7.0.3",
@ -10535,7 +10565,9 @@
"version": "1.3.6",
"resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz",
"integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"makeerror": {
"version": "1.0.12",
@ -11690,6 +11722,8 @@
"resolved": "https://registry.npmjs.org/ts-node/-/ts-node-9.1.1.tgz",
"integrity": "sha512-hPlt7ZACERQGf03M253ytLY3dHbGNGrAq9qIHWUY9XHYl1z7wYngSr3OQ5xmui8o2AaxsONxIzjafLUiWBo1Fg==",
"dev": true,
"optional": true,
"peer": true,
"requires": {
"arg": "^4.1.0",
"create-require": "^1.1.0",
@ -11703,7 +11737,9 @@
"version": "4.0.2",
"resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz",
"integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==",
"dev": true
"dev": true,
"optional": true,
"peer": true
}
}
},
@ -11749,6 +11785,14 @@
"integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==",
"dev": true
},
"typescript": {
"version": "4.8.4",
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.8.4.tgz",
"integrity": "sha512-QCh+85mCy+h0IGff8r5XWzOVSbBO+KfeYrMQh7NJ58QujwcE22u+NUSmUxqF+un70P9GXKxa2HCNiTTMJknyjQ==",
"dev": true,
"optional": true,
"peer": true
},
"underscore": {
"version": "1.4.4",
"resolved": "https://registry.npmjs.org/underscore/-/underscore-1.4.4.tgz",
@ -11999,7 +12043,9 @@
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz",
"integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"yocto-queue": {
"version": "0.1.0",

View File

@ -35,10 +35,10 @@
"build:production": "cross-env NODE_ENV=production npm run build",
"start": "concurrently --names source,types \"ESBUILD_WATCH=true npm run build:source\" \"npm run build:types -- --watch\"",
"prepackage": "npm run build:production",
"package": "ts-node src/scripts/pkg.ts",
"package": "esr src/scripts/pkg.ts",
"pkg": "pkg .",
"postpackage": "ts-node src/scripts/verify-pkg.ts",
"artifacts": "ts-node src/scripts/artifacts.ts",
"postpackage": "esr src/scripts/verify-pkg.ts",
"artifacts": "esr src/scripts/artifacts.ts",
"prepublishOnly": "npm run build:production"
},
"devDependencies": {
@ -59,8 +59,7 @@
"jest": "^28.1.0",
"jest-mock": "^28.0.2",
"pkg": "^5.3.2",
"rimraf": "^3.0.2",
"ts-node": "^9.1.1"
"rimraf": "^3.0.2"
},
"dependencies": {
"@stoplight/spectral-core": "^1.12.2",

File diff suppressed because it is too large Load Diff

View File

@ -7,7 +7,7 @@
"main": "dist/index.js",
"types": "dist/send-request/index.d.ts",
"dependencies": {
"@getinsomnia/node-libcurl": "2.3.5-2",
"@getinsomnia/node-libcurl": "2.3.5-6",
"@stoplight/spectral-core": "^1.12.2",
"@stoplight/spectral-formats": "^1.2.0",
"@stoplight/spectral-rulesets": "^1.9.0",

View File

@ -4,7 +4,6 @@ import fs from 'fs';
import { getBinPathSync } from 'get-bin-path';
import path from 'path';
import { flatten } from 'ramda';
import { compact } from 'ramda-adjunct';
const binariesDirectory = '../insomnia-inso/binaries';
const npmPackageBinPath = getBinPathSync({ cwd: '../insomnia-inso' });
@ -24,7 +23,7 @@ describe('should find binaries', () => {
const srcInsoNedb = ['--src', 'fixtures/inso-nedb'];
describe.each(compact([npmPackageBinPath, ...binaries]))('inso with %s', binPath => {
describe.each([npmPackageBinPath, ...binaries].filter(x => x))('inso with %s', binPath => {
const inso = (...args: NestedArray<string>) => execa.sync(binPath, flatten(args));
describe('run test', () => {

View File

@ -25,6 +25,7 @@
"@types/ws": "^8.5.3",
"concurrently": "^7.0.0",
"cross-env": "^7.0.3",
"esbuild-runner": "2.2.1",
"execa": "^5.0.0",
"express": "^4.17.1",
"express-basic-auth": "^1.2.0",
@ -37,7 +38,6 @@
"oidc-provider": "^7.10.6",
"ramda": "^0.27.1",
"ramda-adjunct": "^2.34.0",
"ts-node": "^9.1.1",
"uuid": "^8.3.2",
"ws": "^8.8.1",
"xvfb-maybe": "^0.2.1"
@ -574,6 +574,40 @@
"integrity": "sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==",
"dev": true
},
"node_modules/@esbuild/android-arm": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.15.12.tgz",
"integrity": "sha512-IC7TqIqiyE0MmvAhWkl/8AEzpOtbhRNDo7aph47We1NbE5w2bt/Q+giAhe0YYeVpYnIhGMcuZY92qDK6dQauvA==",
"cpu": [
"arm"
],
"dev": true,
"optional": true,
"os": [
"android"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/@esbuild/linux-loong64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.15.12.tgz",
"integrity": "sha512-tZEowDjvU7O7I04GYvWQOS4yyP9E/7YlsB0jjw1Ycukgr2ycEzKyIk5tms5WnLBymaewc6VmRKnn5IJWgK4eFw==",
"cpu": [
"loong64"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/@grpc/grpc-js": {
"version": "1.6.7",
"resolved": "https://registry.npmjs.org/@grpc/grpc-js/-/grpc-js-1.6.7.tgz",
@ -1561,7 +1595,9 @@
"version": "4.1.3",
"resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz",
"integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"node_modules/argparse": {
"version": "1.0.10",
@ -2124,7 +2160,9 @@
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz",
"integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"node_modules/cross-env": {
"version": "7.0.3",
@ -2295,6 +2333,8 @@
"resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz",
"integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==",
"dev": true,
"optional": true,
"peer": true,
"engines": {
"node": ">=0.3.1"
}
@ -2380,6 +2420,406 @@
"is-arrayish": "^0.2.1"
}
},
"node_modules/esbuild": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.15.12.tgz",
"integrity": "sha512-PcT+/wyDqJQsRVhaE9uX/Oq4XLrFh0ce/bs2TJh4CSaw9xuvI+xFrH2nAYOADbhQjUgAhNWC5LKoUsakm4dxng==",
"dev": true,
"hasInstallScript": true,
"peer": true,
"bin": {
"esbuild": "bin/esbuild"
},
"engines": {
"node": ">=12"
},
"optionalDependencies": {
"@esbuild/android-arm": "0.15.12",
"@esbuild/linux-loong64": "0.15.12",
"esbuild-android-64": "0.15.12",
"esbuild-android-arm64": "0.15.12",
"esbuild-darwin-64": "0.15.12",
"esbuild-darwin-arm64": "0.15.12",
"esbuild-freebsd-64": "0.15.12",
"esbuild-freebsd-arm64": "0.15.12",
"esbuild-linux-32": "0.15.12",
"esbuild-linux-64": "0.15.12",
"esbuild-linux-arm": "0.15.12",
"esbuild-linux-arm64": "0.15.12",
"esbuild-linux-mips64le": "0.15.12",
"esbuild-linux-ppc64le": "0.15.12",
"esbuild-linux-riscv64": "0.15.12",
"esbuild-linux-s390x": "0.15.12",
"esbuild-netbsd-64": "0.15.12",
"esbuild-openbsd-64": "0.15.12",
"esbuild-sunos-64": "0.15.12",
"esbuild-windows-32": "0.15.12",
"esbuild-windows-64": "0.15.12",
"esbuild-windows-arm64": "0.15.12"
}
},
"node_modules/esbuild-android-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-android-64/-/esbuild-android-64-0.15.12.tgz",
"integrity": "sha512-MJKXwvPY9g0rGps0+U65HlTsM1wUs9lbjt5CU19RESqycGFDRijMDQsh68MtbzkqWSRdEtiKS1mtPzKneaAI0Q==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"android"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-android-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-android-arm64/-/esbuild-android-arm64-0.15.12.tgz",
"integrity": "sha512-Hc9SEcZbIMhhLcvhr1DH+lrrec9SFTiRzfJ7EGSBZiiw994gfkVV6vG0sLWqQQ6DD7V4+OggB+Hn0IRUdDUqvA==",
"cpu": [
"arm64"
],
"dev": true,
"optional": true,
"os": [
"android"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-darwin-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-darwin-64/-/esbuild-darwin-64-0.15.12.tgz",
"integrity": "sha512-qkmqrTVYPFiePt5qFjP8w/S+GIUMbt6k8qmiPraECUWfPptaPJUGkCKrWEfYFRWB7bY23FV95rhvPyh/KARP8Q==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"darwin"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-darwin-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.15.12.tgz",
"integrity": "sha512-z4zPX02tQ41kcXMyN3c/GfZpIjKoI/BzHrdKUwhC/Ki5BAhWv59A9M8H+iqaRbwpzYrYidTybBwiZAIWCLJAkw==",
"cpu": [
"arm64"
],
"dev": true,
"optional": true,
"os": [
"darwin"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-freebsd-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-freebsd-64/-/esbuild-freebsd-64-0.15.12.tgz",
"integrity": "sha512-XFL7gKMCKXLDiAiBjhLG0XECliXaRLTZh6hsyzqUqPUf/PY4C6EJDTKIeqqPKXaVJ8+fzNek88285krSz1QECw==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"freebsd"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-freebsd-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.15.12.tgz",
"integrity": "sha512-jwEIu5UCUk6TjiG1X+KQnCGISI+ILnXzIzt9yDVrhjug2fkYzlLbl0K43q96Q3KB66v6N1UFF0r5Ks4Xo7i72g==",
"cpu": [
"arm64"
],
"dev": true,
"optional": true,
"os": [
"freebsd"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-32": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-32/-/esbuild-linux-32-0.15.12.tgz",
"integrity": "sha512-uSQuSEyF1kVzGzuIr4XM+v7TPKxHjBnLcwv2yPyCz8riV8VUCnO/C4BF3w5dHiVpCd5Z1cebBtZJNlC4anWpwA==",
"cpu": [
"ia32"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-64/-/esbuild-linux-64-0.15.12.tgz",
"integrity": "sha512-QcgCKb7zfJxqT9o5z9ZUeGH1k8N6iX1Y7VNsEi5F9+HzN1OIx7ESxtQXDN9jbeUSPiRH1n9cw6gFT3H4qbdvcA==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-arm": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-arm/-/esbuild-linux-arm-0.15.12.tgz",
"integrity": "sha512-Wf7T0aNylGcLu7hBnzMvsTfEXdEdJY/hY3u36Vla21aY66xR0MS5I1Hw8nVquXjTN0A6fk/vnr32tkC/C2lb0A==",
"cpu": [
"arm"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-arm64/-/esbuild-linux-arm64-0.15.12.tgz",
"integrity": "sha512-HtNq5xm8fUpZKwWKS2/YGwSfTF+339L4aIA8yphNKYJckd5hVdhfdl6GM2P3HwLSCORS++++7++//ApEwXEuAQ==",
"cpu": [
"arm64"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-mips64le": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.15.12.tgz",
"integrity": "sha512-Qol3+AvivngUZkTVFgLpb0H6DT+N5/zM3V1YgTkryPYFeUvuT5JFNDR3ZiS6LxhyF8EE+fiNtzwlPqMDqVcc6A==",
"cpu": [
"mips64el"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-ppc64le": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.15.12.tgz",
"integrity": "sha512-4D8qUCo+CFKaR0cGXtGyVsOI7w7k93Qxb3KFXWr75An0DHamYzq8lt7TNZKoOq/Gh8c40/aKaxvcZnTgQ0TJNg==",
"cpu": [
"ppc64"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-riscv64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-riscv64/-/esbuild-linux-riscv64-0.15.12.tgz",
"integrity": "sha512-G9w6NcuuCI6TUUxe6ka0enjZHDnSVK8bO+1qDhMOCtl7Tr78CcZilJj8SGLN00zO5iIlwNRZKHjdMpfFgNn1VA==",
"cpu": [
"riscv64"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-linux-s390x": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-s390x/-/esbuild-linux-s390x-0.15.12.tgz",
"integrity": "sha512-Lt6BDnuXbXeqSlVuuUM5z18GkJAZf3ERskGZbAWjrQoi9xbEIsj/hEzVnSAFLtkfLuy2DE4RwTcX02tZFunXww==",
"cpu": [
"s390x"
],
"dev": true,
"optional": true,
"os": [
"linux"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-netbsd-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-netbsd-64/-/esbuild-netbsd-64-0.15.12.tgz",
"integrity": "sha512-jlUxCiHO1dsqoURZDQts+HK100o0hXfi4t54MNRMCAqKGAV33JCVvMplLAa2FwviSojT/5ZG5HUfG3gstwAG8w==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"netbsd"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-openbsd-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-openbsd-64/-/esbuild-openbsd-64-0.15.12.tgz",
"integrity": "sha512-1o1uAfRTMIWNOmpf8v7iudND0L6zRBYSH45sofCZywrcf7NcZA+c7aFsS1YryU+yN7aRppTqdUK1PgbZVaB1Dw==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"openbsd"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-runner": {
"version": "2.2.1",
"resolved": "https://registry.npmjs.org/esbuild-runner/-/esbuild-runner-2.2.1.tgz",
"integrity": "sha512-VP0VfJJZiZ3cKzdOH59ZceDxx/GzBKra7tiGM8MfFMLv6CR1/cpsvtQ3IsJI3pz7HyeYxtbPyecj3fHwR+3XcQ==",
"dev": true,
"dependencies": {
"source-map-support": "0.5.19",
"tslib": "2.3.1"
},
"bin": {
"esr": "bin/esr.js"
},
"peerDependencies": {
"esbuild": "*"
}
},
"node_modules/esbuild-runner/node_modules/tslib": {
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/tslib/-/tslib-2.3.1.tgz",
"integrity": "sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw==",
"dev": true
},
"node_modules/esbuild-sunos-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-sunos-64/-/esbuild-sunos-64-0.15.12.tgz",
"integrity": "sha512-nkl251DpoWoBO9Eq9aFdoIt2yYmp4I3kvQjba3jFKlMXuqQ9A4q+JaqdkCouG3DHgAGnzshzaGu6xofGcXyPXg==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"sunos"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-windows-32": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-windows-32/-/esbuild-windows-32-0.15.12.tgz",
"integrity": "sha512-WlGeBZHgPC00O08luIp5B2SP4cNCp/PcS+3Pcg31kdcJPopHxLkdCXtadLU9J82LCfw4TVls21A6lilQ9mzHrw==",
"cpu": [
"ia32"
],
"dev": true,
"optional": true,
"os": [
"win32"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-windows-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-windows-64/-/esbuild-windows-64-0.15.12.tgz",
"integrity": "sha512-VActO3WnWZSN//xjSfbiGOSyC+wkZtI8I4KlgrTo5oHJM6z3MZZBCuFaZHd8hzf/W9KPhF0lY8OqlmWC9HO5AA==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"win32"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/esbuild-windows-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-windows-arm64/-/esbuild-windows-arm64-0.15.12.tgz",
"integrity": "sha512-Of3MIacva1OK/m4zCNIvBfz8VVROBmQT+gRX6pFTLPngFYcj6TFH/12VveAqq1k9VB2l28EoVMNMUCcmsfwyuA==",
"cpu": [
"arm64"
],
"dev": true,
"optional": true,
"os": [
"win32"
],
"peer": true,
"engines": {
"node": ">=12"
}
},
"node_modules/escalade": {
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz",
@ -4204,7 +4644,9 @@
"version": "1.3.6",
"resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz",
"integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"node_modules/makeerror": {
"version": "1.0.12",
@ -5465,6 +5907,8 @@
"resolved": "https://registry.npmjs.org/ts-node/-/ts-node-9.1.1.tgz",
"integrity": "sha512-hPlt7ZACERQGf03M253ytLY3dHbGNGrAq9qIHWUY9XHYl1z7wYngSr3OQ5xmui8o2AaxsONxIzjafLUiWBo1Fg==",
"dev": true,
"optional": true,
"peer": true,
"dependencies": {
"arg": "^4.1.0",
"create-require": "^1.1.0",
@ -5538,6 +5982,21 @@
"node": ">= 0.6"
}
},
"node_modules/typescript": {
"version": "4.8.4",
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.8.4.tgz",
"integrity": "sha512-QCh+85mCy+h0IGff8r5XWzOVSbBO+KfeYrMQh7NJ58QujwcE22u+NUSmUxqF+un70P9GXKxa2HCNiTTMJknyjQ==",
"dev": true,
"optional": true,
"peer": true,
"bin": {
"tsc": "bin/tsc",
"tsserver": "bin/tsserver"
},
"engines": {
"node": ">=4.2.0"
}
},
"node_modules/unpipe": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz",
@ -5760,6 +6219,8 @@
"resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz",
"integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==",
"dev": true,
"optional": true,
"peer": true,
"engines": {
"node": ">=6"
}
@ -6208,6 +6669,22 @@
"integrity": "sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==",
"dev": true
},
"@esbuild/android-arm": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.15.12.tgz",
"integrity": "sha512-IC7TqIqiyE0MmvAhWkl/8AEzpOtbhRNDo7aph47We1NbE5w2bt/Q+giAhe0YYeVpYnIhGMcuZY92qDK6dQauvA==",
"dev": true,
"optional": true,
"peer": true
},
"@esbuild/linux-loong64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.15.12.tgz",
"integrity": "sha512-tZEowDjvU7O7I04GYvWQOS4yyP9E/7YlsB0jjw1Ycukgr2ycEzKyIk5tms5WnLBymaewc6VmRKnn5IJWgK4eFw==",
"dev": true,
"optional": true,
"peer": true
},
"@grpc/grpc-js": {
"version": "1.6.7",
"resolved": "https://registry.npmjs.org/@grpc/grpc-js/-/grpc-js-1.6.7.tgz",
@ -7070,7 +7547,9 @@
"version": "4.1.3",
"resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz",
"integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"argparse": {
"version": "1.0.10",
@ -7525,7 +8004,9 @@
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz",
"integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"cross-env": {
"version": "7.0.3",
@ -7642,7 +8123,9 @@
"version": "4.0.2",
"resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz",
"integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"diff-sequences": {
"version": "28.0.2",
@ -7707,6 +8190,215 @@
"is-arrayish": "^0.2.1"
}
},
"esbuild": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.15.12.tgz",
"integrity": "sha512-PcT+/wyDqJQsRVhaE9uX/Oq4XLrFh0ce/bs2TJh4CSaw9xuvI+xFrH2nAYOADbhQjUgAhNWC5LKoUsakm4dxng==",
"dev": true,
"peer": true,
"requires": {
"@esbuild/android-arm": "0.15.12",
"@esbuild/linux-loong64": "0.15.12",
"esbuild-android-64": "0.15.12",
"esbuild-android-arm64": "0.15.12",
"esbuild-darwin-64": "0.15.12",
"esbuild-darwin-arm64": "0.15.12",
"esbuild-freebsd-64": "0.15.12",
"esbuild-freebsd-arm64": "0.15.12",
"esbuild-linux-32": "0.15.12",
"esbuild-linux-64": "0.15.12",
"esbuild-linux-arm": "0.15.12",
"esbuild-linux-arm64": "0.15.12",
"esbuild-linux-mips64le": "0.15.12",
"esbuild-linux-ppc64le": "0.15.12",
"esbuild-linux-riscv64": "0.15.12",
"esbuild-linux-s390x": "0.15.12",
"esbuild-netbsd-64": "0.15.12",
"esbuild-openbsd-64": "0.15.12",
"esbuild-sunos-64": "0.15.12",
"esbuild-windows-32": "0.15.12",
"esbuild-windows-64": "0.15.12",
"esbuild-windows-arm64": "0.15.12"
}
},
"esbuild-android-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-android-64/-/esbuild-android-64-0.15.12.tgz",
"integrity": "sha512-MJKXwvPY9g0rGps0+U65HlTsM1wUs9lbjt5CU19RESqycGFDRijMDQsh68MtbzkqWSRdEtiKS1mtPzKneaAI0Q==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-android-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-android-arm64/-/esbuild-android-arm64-0.15.12.tgz",
"integrity": "sha512-Hc9SEcZbIMhhLcvhr1DH+lrrec9SFTiRzfJ7EGSBZiiw994gfkVV6vG0sLWqQQ6DD7V4+OggB+Hn0IRUdDUqvA==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-darwin-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-darwin-64/-/esbuild-darwin-64-0.15.12.tgz",
"integrity": "sha512-qkmqrTVYPFiePt5qFjP8w/S+GIUMbt6k8qmiPraECUWfPptaPJUGkCKrWEfYFRWB7bY23FV95rhvPyh/KARP8Q==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-darwin-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.15.12.tgz",
"integrity": "sha512-z4zPX02tQ41kcXMyN3c/GfZpIjKoI/BzHrdKUwhC/Ki5BAhWv59A9M8H+iqaRbwpzYrYidTybBwiZAIWCLJAkw==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-freebsd-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-freebsd-64/-/esbuild-freebsd-64-0.15.12.tgz",
"integrity": "sha512-XFL7gKMCKXLDiAiBjhLG0XECliXaRLTZh6hsyzqUqPUf/PY4C6EJDTKIeqqPKXaVJ8+fzNek88285krSz1QECw==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-freebsd-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.15.12.tgz",
"integrity": "sha512-jwEIu5UCUk6TjiG1X+KQnCGISI+ILnXzIzt9yDVrhjug2fkYzlLbl0K43q96Q3KB66v6N1UFF0r5Ks4Xo7i72g==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-32": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-32/-/esbuild-linux-32-0.15.12.tgz",
"integrity": "sha512-uSQuSEyF1kVzGzuIr4XM+v7TPKxHjBnLcwv2yPyCz8riV8VUCnO/C4BF3w5dHiVpCd5Z1cebBtZJNlC4anWpwA==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-64/-/esbuild-linux-64-0.15.12.tgz",
"integrity": "sha512-QcgCKb7zfJxqT9o5z9ZUeGH1k8N6iX1Y7VNsEi5F9+HzN1OIx7ESxtQXDN9jbeUSPiRH1n9cw6gFT3H4qbdvcA==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-arm": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-arm/-/esbuild-linux-arm-0.15.12.tgz",
"integrity": "sha512-Wf7T0aNylGcLu7hBnzMvsTfEXdEdJY/hY3u36Vla21aY66xR0MS5I1Hw8nVquXjTN0A6fk/vnr32tkC/C2lb0A==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-arm64/-/esbuild-linux-arm64-0.15.12.tgz",
"integrity": "sha512-HtNq5xm8fUpZKwWKS2/YGwSfTF+339L4aIA8yphNKYJckd5hVdhfdl6GM2P3HwLSCORS++++7++//ApEwXEuAQ==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-mips64le": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.15.12.tgz",
"integrity": "sha512-Qol3+AvivngUZkTVFgLpb0H6DT+N5/zM3V1YgTkryPYFeUvuT5JFNDR3ZiS6LxhyF8EE+fiNtzwlPqMDqVcc6A==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-ppc64le": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.15.12.tgz",
"integrity": "sha512-4D8qUCo+CFKaR0cGXtGyVsOI7w7k93Qxb3KFXWr75An0DHamYzq8lt7TNZKoOq/Gh8c40/aKaxvcZnTgQ0TJNg==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-riscv64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-riscv64/-/esbuild-linux-riscv64-0.15.12.tgz",
"integrity": "sha512-G9w6NcuuCI6TUUxe6ka0enjZHDnSVK8bO+1qDhMOCtl7Tr78CcZilJj8SGLN00zO5iIlwNRZKHjdMpfFgNn1VA==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-linux-s390x": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-linux-s390x/-/esbuild-linux-s390x-0.15.12.tgz",
"integrity": "sha512-Lt6BDnuXbXeqSlVuuUM5z18GkJAZf3ERskGZbAWjrQoi9xbEIsj/hEzVnSAFLtkfLuy2DE4RwTcX02tZFunXww==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-netbsd-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-netbsd-64/-/esbuild-netbsd-64-0.15.12.tgz",
"integrity": "sha512-jlUxCiHO1dsqoURZDQts+HK100o0hXfi4t54MNRMCAqKGAV33JCVvMplLAa2FwviSojT/5ZG5HUfG3gstwAG8w==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-openbsd-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-openbsd-64/-/esbuild-openbsd-64-0.15.12.tgz",
"integrity": "sha512-1o1uAfRTMIWNOmpf8v7iudND0L6zRBYSH45sofCZywrcf7NcZA+c7aFsS1YryU+yN7aRppTqdUK1PgbZVaB1Dw==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-runner": {
"version": "2.2.1",
"resolved": "https://registry.npmjs.org/esbuild-runner/-/esbuild-runner-2.2.1.tgz",
"integrity": "sha512-VP0VfJJZiZ3cKzdOH59ZceDxx/GzBKra7tiGM8MfFMLv6CR1/cpsvtQ3IsJI3pz7HyeYxtbPyecj3fHwR+3XcQ==",
"dev": true,
"requires": {
"source-map-support": "0.5.19",
"tslib": "2.3.1"
},
"dependencies": {
"tslib": {
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/tslib/-/tslib-2.3.1.tgz",
"integrity": "sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw==",
"dev": true
}
}
},
"esbuild-sunos-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-sunos-64/-/esbuild-sunos-64-0.15.12.tgz",
"integrity": "sha512-nkl251DpoWoBO9Eq9aFdoIt2yYmp4I3kvQjba3jFKlMXuqQ9A4q+JaqdkCouG3DHgAGnzshzaGu6xofGcXyPXg==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-windows-32": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-windows-32/-/esbuild-windows-32-0.15.12.tgz",
"integrity": "sha512-WlGeBZHgPC00O08luIp5B2SP4cNCp/PcS+3Pcg31kdcJPopHxLkdCXtadLU9J82LCfw4TVls21A6lilQ9mzHrw==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-windows-64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-windows-64/-/esbuild-windows-64-0.15.12.tgz",
"integrity": "sha512-VActO3WnWZSN//xjSfbiGOSyC+wkZtI8I4KlgrTo5oHJM6z3MZZBCuFaZHd8hzf/W9KPhF0lY8OqlmWC9HO5AA==",
"dev": true,
"optional": true,
"peer": true
},
"esbuild-windows-arm64": {
"version": "0.15.12",
"resolved": "https://registry.npmjs.org/esbuild-windows-arm64/-/esbuild-windows-arm64-0.15.12.tgz",
"integrity": "sha512-Of3MIacva1OK/m4zCNIvBfz8VVROBmQT+gRX6pFTLPngFYcj6TFH/12VveAqq1k9VB2l28EoVMNMUCcmsfwyuA==",
"dev": true,
"optional": true,
"peer": true
},
"escalade": {
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz",
@ -9134,7 +9826,9 @@
"version": "1.3.6",
"resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz",
"integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==",
"dev": true
"dev": true,
"optional": true,
"peer": true
},
"makeerror": {
"version": "1.0.12",
@ -10094,6 +10788,8 @@
"resolved": "https://registry.npmjs.org/ts-node/-/ts-node-9.1.1.tgz",
"integrity": "sha512-hPlt7ZACERQGf03M253ytLY3dHbGNGrAq9qIHWUY9XHYl1z7wYngSr3OQ5xmui8o2AaxsONxIzjafLUiWBo1Fg==",
"dev": true,
"optional": true,
"peer": true,
"requires": {
"arg": "^4.1.0",
"create-require": "^1.1.0",
@ -10143,6 +10839,14 @@
"mime-types": "~2.1.24"
}
},
"typescript": {
"version": "4.8.4",
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.8.4.tgz",
"integrity": "sha512-QCh+85mCy+h0IGff8r5XWzOVSbBO+KfeYrMQh7NJ58QujwcE22u+NUSmUxqF+un70P9GXKxa2HCNiTTMJknyjQ==",
"dev": true,
"optional": true,
"peer": true
},
"unpipe": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz",
@ -10310,7 +11014,9 @@
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz",
"integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==",
"dev": true
"dev": true,
"optional": true,
"peer": true
}
}
}

View File

@ -24,8 +24,8 @@
"test:build": "xvfb-maybe cross-env BUNDLE=build playwright test",
"test:package": "xvfb-maybe cross-env BUNDLE=package playwright test",
"cli": "jest --detectOpenHandles --testPathPattern cli",
"serve": "ts-node server/index.ts",
"test:cli": "concurrently --names server,cli --success first --kill-others \"ts-node server/index.ts\" \"npm run cli\""
"serve": "esr server/index.ts",
"test:cli": "concurrently --names server,cli --success first --kill-others \"esr server/index.ts\" \"npm run cli\""
},
"devDependencies": {
"@grpc/grpc-js": "^1.6.7",
@ -44,6 +44,7 @@
"@types/ws": "^8.5.3",
"concurrently": "^7.0.0",
"cross-env": "^7.0.3",
"esbuild-runner": "2.2.1",
"execa": "^5.0.0",
"express": "^4.17.1",
"express-basic-auth": "^1.2.0",
@ -56,7 +57,6 @@
"oidc-provider": "^7.10.6",
"ramda": "^0.27.1",
"ramda-adjunct": "^2.34.0",
"ts-node": "^9.1.1",
"uuid": "^8.3.2",
"ws": "^8.8.1",
"xvfb-maybe": "^0.2.1"

View File

@ -41,10 +41,7 @@ const handleConnection = (ws: WebSocket, req: IncomingMessage) => {
});
};
const redirectOnSuccess = (socket: Socket) => {
socket.end(`HTTP/1.1 302 Found
Location: ws://localhost:4010
`);
socket.end('HTTP/1.1 302 Found\r\nLocation: ws://localhost:4010/\r\n\r\n');
return;
};
const return401withBody = (socket: Socket) => {

View File

@ -1,3 +1,3 @@
runtime = electron
target = 19.0.3
target = 21.2.0
disturl = https://electronjs.org/headers

File diff suppressed because it is too large Load Diff

View File

@ -41,7 +41,7 @@
"convert-svg": "npm_config_yes=true npx @svgr/cli@6.4.0 --no-index --config-file svgr.config.js --out-dir src/ui/components/assets/svgr src/ui/components/assets/"
},
"dependencies": {
"@getinsomnia/node-libcurl": "2.3.5-2",
"@getinsomnia/node-libcurl": "2.3.5-6",
"@grpc/grpc-js": "^1.1.8",
"@grpc/proto-loader": "^0.5.5",
"@jest/globals": "^28.1.0",
@ -116,6 +116,7 @@
"@babel/plugin-proposal-decorators": "^7.4.0",
"@develohpanda/fluent-builder": "^2.1.2",
"@getinsomnia/api-client": "0.0.4",
"@tanstack/react-virtual": "3.0.0-beta.18",
"@testing-library/dom": "^8.13.0",
"@testing-library/jest-dom": "^5.16.4",
"@testing-library/react": "^13.4.0",
@ -145,7 +146,7 @@
"@types/react": "^18.0.21",
"@types/react-dom": "^18.0.6",
"@types/react-redux": "^7.1.22",
"@types/react-tabs": "^2.3.4",
"@types/react-tabs": "^5.0.5",
"@types/redux-mock-store": "^1.0.2",
"@types/rimraf": "^3.0.2",
"@types/styled-components": "^5.1.23",
@ -165,7 +166,7 @@
"cross-env": "^7.0.3",
"date-fns": "^2.28.0",
"deep-equal": "^1.0.1",
"electron": "19.0.3",
"electron": "21.2.0",
"electron-builder": "23.0.7",
"electron-builder-squirrel-windows": "23.0.7",
"electron-devtools-installer": "^3.2.0",
@ -191,20 +192,18 @@
"react-dnd": "^7.4.5",
"react-dnd-html5-backend": "^7.4.4",
"react-dom": "^18.2.0",
"react-hook-form": "^7.12.1",
"react-redux": "^7.2.6",
"react-router-dom": "^6.4.2",
"react-stately": "^3.17.0",
"react-tabs": "^3.2.3",
"react-use": "^17.2.4",
"react-virtual": "2.10.4",
"react-tabs": "^5.1.0",
"react-use": "^17.4.0",
"redux": "^4.1.2",
"redux-mock-store": "^1.5.4",
"redux-thunk": "^2.4.1",
"reselect": "^4.1.5",
"srp-js": "^0.2.1",
"styled-components": "^5.3.3",
"swagger-ui-react": "4.5.1",
"swagger-ui-react": "4.14.3",
"tinykeys": "^1.4.0",
"type-fest": "^2.12.0",
"typescript": "^4.5.5",
@ -213,6 +212,13 @@
"vkbeautify": "^0.99.1",
"ws": "^8.8.1"
},
"overrides": {
"swagger-ui-react": {
"react-debounce-input": "3.3.0",
"react-inspector": "6.0.1",
"react-copy-to-clipboard": "5.1.0"
}
},
"dev": {
"dev-server-port": 3334
}

View File

@ -319,7 +319,7 @@ const openWebSocketConnection = async (
});
ws.addEventListener('error', async ({ error, message }: ErrorEvent) => {
console.error(error);
console.error('Error from remote:', error.code, error);
const errorEvent: WebSocketErrorEvent = {
_id: uuidV4(),
@ -332,7 +332,7 @@ const openWebSocketConnection = async (
deleteRequestMaps(request._id, message, errorEvent);
event.sender.send(readyStateChannel, ws.readyState);
if (error.code === 'ENOTFOUND') {
if (error.code) {
createErrorResponse(responseId, request._id, responseEnvironmentId, timelinePath, message || 'Something went wrong');
}
});

View File

@ -406,7 +406,6 @@ export const GraphQLEditor: FC<Props> = ({
// Find op if there isn't one yet
if (!body.operationName) {
const newOperationName = getCurrentOperation();
console.log('newOperationName', newOperationName);
if (newOperationName) {
body.operationName = newOperationName;

View File

@ -1,6 +1,5 @@
import { autoBindMethodsForReact } from 'class-autobind-decorator';
import classnames from 'classnames';
import { noop } from 'ramda-adjunct';
import React, { PureComponent } from 'react';
import { AUTOBIND_CFG, DEBOUNCE_MILLIS } from '../../../common/constants';
@ -507,8 +506,8 @@ export class KeyValueEditor extends PureComponent<Props, State> {
noDropZone
forceInput
index={-1}
onChange={noop}
onDelete={noop}
onChange={() => {}}
onDelete={() => {}}
renderLeftIcon={() => (
<Dropdown>
<DropdownButton>

View File

@ -1,6 +1,4 @@
import React, { FC, forwardRef, useImperativeHandle, useRef, useState } from 'react';
import { useCallback } from 'react';
import { useForm } from 'react-hook-form';
import React, { forwardRef, useImperativeHandle, useRef, useState } from 'react';
import { useDispatch, useSelector } from 'react-redux';
import { getWorkspaceLabel } from '../../../common/get-workspace-label';
@ -8,32 +6,17 @@ import { strings } from '../../../common/strings';
import * as models from '../../../models';
import { ApiSpec } from '../../../models/api-spec';
import * as workspaceOperations from '../../../models/helpers/workspace-operations';
import { isDefaultProject, isLocalProject, isRemoteProject, Project } from '../../../models/project';
import { isDefaultProject, isLocalProject, isRemoteProject } from '../../../models/project';
import { isDesign, Workspace } from '../../../models/workspace';
import { initializeLocalBackendProjectAndMarkForSync } from '../../../sync/vcs/initialize-backend-project';
import { VCS } from '../../../sync/vcs/vcs';
import { useVCS } from '../../hooks/use-vcs';
import { activateWorkspace } from '../../redux/modules/workspace';
import { selectActiveProject, selectIsLoggedIn, selectProjects } from '../../redux/selectors';
import { selectIsLoggedIn, selectProjects } from '../../redux/selectors';
import { type ModalHandle, Modal, ModalProps } from '../base/modal';
import { ModalBody } from '../base/modal-body';
import { ModalFooter } from '../base/modal-footer';
import { ModalHeader } from '../base/modal-header';
interface FormFields {
newName: string;
projectId: string;
}
const ProjectOption: FC<Project> = project => (
<option key={project._id} value={project._id}>
{project.name} ({isDefaultProject(project) ? strings.defaultProject.singular : isLocalProject(project) ? strings.localProject.singular : strings.remoteProject.singular})
</option>
);
type Props = ModalProps & {
vcs?: VCS;
};
interface ErrorModalOptions {
workspace?: Workspace;
apiSpec?: ApiSpec;
@ -43,8 +26,9 @@ export interface WorkspaceDuplicateModalHandle {
show: (options: ErrorModalOptions) => void;
hide: () => void;
}
export const WorkspaceDuplicateModal = forwardRef<WorkspaceDuplicateModalHandle, Props>(({ vcs }, ref) => {
export const WorkspaceDuplicateModal = forwardRef<WorkspaceDuplicateModalHandle, ModalProps>((_, ref) => {
const modalRef = useRef<ModalHandle>(null);
const [state, setState] = useState<ErrorModalOptions>({});
useImperativeHandle(ref, () => ({
hide: () => {
@ -56,68 +40,68 @@ export const WorkspaceDuplicateModal = forwardRef<WorkspaceDuplicateModalHandle,
},
}), []);
const activeProject = useSelector(selectActiveProject);
const {
register,
handleSubmit,
reset,
formState: { errors } } = useForm<FormFields>({
defaultValues: {
newName: state.workspace ? isDesign(state.workspace) ? (state.apiSpec?.fileName || '') : state.workspace.name : '',
projectId: activeProject._id,
},
});
const dispatch = useDispatch();
const projects = useSelector(selectProjects);
const isLoggedIn = useSelector(selectIsLoggedIn);
const onSubmit = useCallback(async ({ projectId, newName }: FormFields) => {
const duplicateToProject = projects.find(project => project._id === projectId);
if (!duplicateToProject) {
throw new Error('Project could not be found');
}
if (!state.workspace) {
throw new Error('Workspace could not be found');
}
const newWorkspace = await workspaceOperations.duplicate(state.workspace, { name: newName, parentId: projectId });
await models.workspace.ensureChildren(newWorkspace);
// Mark for sync if logged in and in the expected project
if (isLoggedIn && vcs && isRemoteProject(duplicateToProject)) {
await initializeLocalBackendProjectAndMarkForSync({ vcs: vcs.newInstance(), workspace: newWorkspace });
}
dispatch(activateWorkspace({ workspace: newWorkspace }));
modalRef.current?.hide();
state?.onDone?.();
}, [dispatch, isLoggedIn, projects, vcs, state]);
const dispatch = useDispatch();
const vcs = useVCS({ workspaceId: state.workspace?._id });
return (
<Modal ref={modalRef} onShow={reset}>
<Modal ref={modalRef}>
<ModalHeader>{`Duplicate ${state.workspace && getWorkspaceLabel(state.workspace).singular}`}</ModalHeader>
<ModalBody className="wide">
<form className="wide pad" onSubmit={handleSubmit(onSubmit)}>
<form
onSubmit={async e => {
e.preventDefault();
const data = new FormData(e.currentTarget);
const newName = data.get('name') as string;
const projectId = data.get('projectId') as string;
const duplicateToProject = projects.find(project => project._id === projectId);
if (!duplicateToProject) {
throw new Error('Project could not be found');
}
if (!state.workspace) {
throw new Error('Workspace could not be found');
}
const newWorkspace = await workspaceOperations.duplicate(state.workspace, { name: newName, parentId: projectId });
await models.workspace.ensureChildren(newWorkspace);
// Mark for sync if logged in and in the expected project
if (isLoggedIn && vcs && isRemoteProject(duplicateToProject)) {
await initializeLocalBackendProjectAndMarkForSync({ vcs: vcs.newInstance(), workspace: newWorkspace });
}
dispatch(activateWorkspace({ workspace: newWorkspace }));
modalRef.current?.hide();
state?.onDone?.();
}}
method='post'
id="workspace-duplicate-form"
className="wide pad"
>
<div className="form-control form-control--wide form-control--outlined">
<label>
New Name
<input {...register('newName', { validate: v => Boolean(v.trim()) || 'Should not be blank' })} />
{errors.newName && <div className="font-error space-top">{errors.newName.message}</div>}
<input name="name" defaultValue={state.workspace ? isDesign(state.workspace) ? (state.apiSpec?.fileName || '') : state.workspace.name : ''} />
</label>
</div>
<div className="form-control form-control--outlined">
<label>
{strings.project.singular} to duplicate into
<select {...register('projectId')}>
{projects.map(ProjectOption)}
<select defaultValue={state.workspace?.parentId} name="projectId">
{projects.map(project => (
<option key={project._id} value={project._id}>
{project.name} ({isDefaultProject(project) ? strings.defaultProject.singular : isLocalProject(project) ? strings.localProject.singular : strings.remoteProject.singular})
</option>
))}
</select>
</label>
</div>
</form>
</ModalBody>
<ModalFooter>
<button className="btn" onClick={handleSubmit(onSubmit)}>
<button type="submit" form="workspace-duplicate-form" className="btn">
Duplicate
</button>
</ModalFooter>
</Modal>
);
});
WorkspaceDuplicateModal.displayName = 'WorkspaceDuplicateModal';

View File

@ -1,7 +1,7 @@
import { useVirtualizer } from '@tanstack/react-virtual';
import { format } from 'date-fns';
import React, { FC, useRef } from 'react';
import { useMeasure } from 'react-use';
import { useVirtual } from 'react-virtual';
import styled from 'styled-components';
import { WebSocketEvent } from '../../../main/network/websocket';
@ -138,12 +138,12 @@ const EventTimestampCell = styled('div')({
export const EventLogView: FC<Props> = ({ events, onSelect, selectionId }) => {
const parentRef = useRef<HTMLDivElement>(null);
const virtualizer = useVirtual({
parentRef,
size: events.length,
const virtualizer = useVirtualizer({
getScrollElement: () => parentRef.current,
count: events.length,
estimateSize: React.useCallback(() => 30, []),
overscan: 30,
keyExtractor: index => events[index]._id,
getItemKey: index => events[index]._id,
});
const [autoSizeRef, { height }] = useMeasure<HTMLDivElement>();
@ -163,10 +163,10 @@ export const EventLogView: FC<Props> = ({ events, onSelect, selectionId }) => {
<Scrollable style={{ height }} ref={parentRef}>
<List
style={{
height: `${virtualizer.totalSize}px`,
height: `${virtualizer.getTotalSize()}px`,
}}
>
{virtualizer.virtualItems.map(item => {
{virtualizer.getVirtualItems().map(item => {
const event = events[item.index];
return (

View File

@ -172,7 +172,7 @@ const App = () => {
<RequestRenderErrorModal ref={instance => registerModal(instance, 'RequestRenderErrorModal')} />
<GenerateConfigModal ref={instance => registerModal(instance, 'GenerateConfigModal')} />
<ProjectSettingsModal ref={instance => registerModal(instance, 'ProjectSettingsModal')} />
<WorkspaceDuplicateModal ref={instance => registerModal(instance, 'WorkspaceDuplicateModal')} vcs={vcs || undefined} />
<WorkspaceDuplicateModal ref={instance => registerModal(instance, 'WorkspaceDuplicateModal')} />
<CodePromptModal ref={instance => registerModal(instance, 'CodePromptModal')} />
<RequestSettingsModal ref={instance => registerModal(instance, 'RequestSettingsModal')} />
<RequestGroupSettingsModal ref={instance => registerModal(instance, 'RequestGroupSettingsModal')} />

View File

@ -1,4 +1,4 @@
// TODO(TSCONVERSION) convert to TypeScript and update package.json to use ts-node
// TODO(TSCONVERSION) convert to TypeScript?
const fs = require('fs');
const GREEN_FG = '\x1b[32m';