diff --git a/package.json b/package.json index 7126930..b74bfd2 100644 --- a/package.json +++ b/package.json @@ -19,9 +19,9 @@ "author": "", "license": "ISC", "peerDependencies": { + "next": "^12", "react": ">=17", - "react-dom": ">=17", - "next": "^12" + "react-dom": ">=17" }, "dependencies": { "debug": "^4.3.4", @@ -29,22 +29,23 @@ "graphql": "^16.6.0", "jose": "^4.9.2", "node-fetch": "^2.6.7", + "raw-body": "^2.5.1", "retes": "^0.33.0", "uuid": "^8.3.2" }, "devDependencies": { - "@vitest/coverage-c8": "^0.23.2", - "node-mocks-http": "^1.11.0", - "next": "^12.3.0", "@testing-library/dom": "^8.17.1", "@testing-library/react": "^13.4.0", "@types/debug": "^4.1.7", "@types/node": "^18.7.15", "@types/node-fetch": "^2.6.2", + "@types/react": "18.0.21", + "@types/react-dom": "^18.0.5", "@types/uuid": "^8.3.4", "@typescript-eslint/eslint-plugin": "^5.36.1", "@typescript-eslint/parser": "^5.36.1", "@vitejs/plugin-react": "^2.1.0", + "@vitest/coverage-c8": "^0.23.2", "clean-publish": "^4.0.1", "eslint": "8.23.0", "eslint-config-airbnb": "^19.0.4", @@ -57,18 +58,17 @@ "eslint-plugin-simple-import-sort": "^8.0.0", "husky": "^8.0.1", "jsdom": "^20.0.0", + "next": "^12.3.0", + "node-mocks-http": "^1.11.0", "prettier": "2.7.1", + "react": "^18.2.0", + "react-dom": "18.2.0", "release-it": "^15.4.1", "tsm": "^2.2.2", "tsup": "^6.2.3", "typescript": "^4.8.2", "vite": "^3.1.0", - "vitest": "^0.23.1", - "watchlist": "^0.3.1", - "react": "^18.2.0", - "react-dom": "18.2.0", - "@types/react": "18.0.21", - "@types/react-dom": "^18.0.5" + "vitest": "^0.23.1" }, "lint-staged": { "*.{js,ts,tsx}": "eslint --cache --fix", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index f2672cc..deb266a 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -33,6 +33,7 @@ specifiers: node-fetch: ^2.6.7 node-mocks-http: ^1.11.0 prettier: 2.7.1 + raw-body: ^2.5.1 react: ^18.2.0 react-dom: 18.2.0 release-it: ^15.4.1 @@ -43,14 +44,14 @@ specifiers: uuid: ^8.3.2 vite: ^3.1.0 vitest: ^0.23.1 - watchlist: ^0.3.1 dependencies: debug: 4.3.4 fast-glob: 3.2.11 graphql: 16.6.0 jose: 4.9.2 - node-fetch: registry.npmjs.org/node-fetch/2.6.7 + node-fetch: 2.6.7 + raw-body: 2.5.1 retes: 0.33.0 uuid: 8.3.2 @@ -59,7 +60,7 @@ devDependencies: '@testing-library/react': 13.4.0_biqbaboplfbrettd7655fr4n2y '@types/debug': 4.1.7 '@types/node': 18.7.15 - '@types/node-fetch': registry.npmjs.org/@types/node-fetch/2.6.2 + '@types/node-fetch': 2.6.2 '@types/react': 18.0.21 '@types/react-dom': 18.0.6 '@types/uuid': 8.3.4 @@ -79,7 +80,7 @@ devDependencies: eslint-plugin-simple-import-sort: 8.0.0_eslint@8.23.0 husky: 8.0.1 jsdom: 20.0.0 - next: 12.3.0_rlaikcoslzwwtqyk7brpdzej5y + next: 12.3.0_biqbaboplfbrettd7655fr4n2y node-mocks-http: 1.11.0 prettier: 2.7.1 react: 18.2.0 @@ -90,7 +91,6 @@ devDependencies: typescript: 4.8.2 vite: 3.1.0 vitest: 0.23.1_jsdom@20.0.0 - watchlist: 0.3.1 packages: @@ -380,6 +380,24 @@ packages: resolution: {integrity: sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==} dev: true + /@esbuild/linux-loong64/0.14.54: + resolution: {integrity: sha512-bZBrLAIX1kpWelV0XemxBZllyRmM6vgFQQG2GdNb+r3Fkp0FOh1NJSvekXDs7jq70k4euu1cryLMfU+mTXlEpw==} + engines: {node: '>=12'} + cpu: [loong64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@esbuild/linux-loong64/0.15.7: + resolution: {integrity: sha512-IKznSJOsVUuyt7cDzzSZyqBEcZe+7WlBqTVXiF1OXP/4Nm387ToaXZ0fyLwI1iBlI/bzpxVq411QE2/Bt2XWWw==} + engines: {node: '>=12'} + cpu: [loong64] + os: [linux] + requiresBuild: true + dev: true + optional: true + /@eslint/eslintrc/1.3.1: resolution: {integrity: sha512-OhSY22oQQdw3zgPOOwdoj01l/Dzl1Z+xyUP33tkSN+aqyEhymJCcPHyXt+ylW8FSe0TfRC2VG+ROQOapD0aZSQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} @@ -472,6 +490,123 @@ packages: resolution: {integrity: sha512-PTJpjAFVbzBQ9xXpzMTroShvD5YDIIy46jQ7d4LrWpY+/5a8H90Tm8hE3Hvkc5RBRspVo7kvEOnqQms0A+2Q6w==} dev: true + /@next/swc-android-arm-eabi/12.3.0: + resolution: {integrity: sha512-/PuirPnAKsYBw93w/7Q9hqy+KGOU9mjYprZ/faxMUJh/dc6v3rYLxkZKNG9nFPIW4QKNTCnhP40xF9hLnxO+xg==} + engines: {node: '>= 10'} + cpu: [arm] + os: [android] + requiresBuild: true + dev: true + optional: true + + /@next/swc-android-arm64/12.3.0: + resolution: {integrity: sha512-OaI+FhAM6P9B6Ybwbn0Zl8YwWido0lLwhDBi9WiYCh4RQmIXAyVIoIJPHo4fP05+mXaJ/k1trvDvuURvHOq2qw==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [android] + requiresBuild: true + dev: true + optional: true + + /@next/swc-darwin-arm64/12.3.0: + resolution: {integrity: sha512-9s4d3Mhii+WFce8o8Jok7WC3Bawkr9wEUU++SJRptjU1L5tsfYJMrSYCACHLhZujziNDLyExe4Hwwsccps1sfg==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [darwin] + requiresBuild: true + dev: true + optional: true + + /@next/swc-darwin-x64/12.3.0: + resolution: {integrity: sha512-2scC4MqUTwGwok+wpVxP+zWp7WcCAVOtutki2E1n99rBOTnUOX6qXkgxSy083yBN6GqwuC/dzHeN7hIKjavfRA==} + engines: {node: '>= 10'} + cpu: [x64] + os: [darwin] + requiresBuild: true + dev: true + optional: true + + /@next/swc-freebsd-x64/12.3.0: + resolution: {integrity: sha512-xAlruUREij/bFa+qsE1tmsP28t7vz02N4ZDHt2lh3uJUniE0Ne9idyIDLc1Ed0IF2RjfgOp4ZVunuS3OM0sngw==} + engines: {node: '>= 10'} + cpu: [x64] + os: [freebsd] + requiresBuild: true + dev: true + optional: true + + /@next/swc-linux-arm-gnueabihf/12.3.0: + resolution: {integrity: sha512-jin2S4VT/cugc2dSZEUIabhYDJNgrUh7fufbdsaAezgcQzqfdfJqfxl4E9GuafzB4cbRPTaqA0V5uqbp0IyGkQ==} + engines: {node: '>= 10'} + cpu: [arm] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@next/swc-linux-arm64-gnu/12.3.0: + resolution: {integrity: sha512-RqJHDKe0WImeUrdR0kayTkRWgp4vD/MS7g0r6Xuf8+ellOFH7JAAJffDW3ayuVZeMYOa7RvgNFcOoWnrTUl9Nw==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@next/swc-linux-arm64-musl/12.3.0: + resolution: {integrity: sha512-nvNWoUieMjvDjpYJ/4SQe9lQs2xMj6ZRs8N+bmTrVu9leY2Fg3WD6W9p/1uU9hGO8u+OdF13wc4iRShu/WYIHg==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@next/swc-linux-x64-gnu/12.3.0: + resolution: {integrity: sha512-4ajhIuVU9PeQCMMhdDgZTLrHmjbOUFuIyg6J19hZqwEwDTSqQyrSLkbJs2Nd7IRiM6Ul/XyrtEFCpk4k+xD2+w==} + engines: {node: '>= 10'} + cpu: [x64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@next/swc-linux-x64-musl/12.3.0: + resolution: {integrity: sha512-U092RBYbaGxoMAwpauePJEu2PuZSEoUCGJBvsptQr2/2XIMwAJDYM4c/M5NfYEsBr+yjvsYNsOpYfeQ88D82Yg==} + engines: {node: '>= 10'} + cpu: [x64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@next/swc-win32-arm64-msvc/12.3.0: + resolution: {integrity: sha512-pzSzaxjDEJe67bUok9Nxf9rykbJfHXW0owICFsPBsqHyc+cr8vpF7g9e2APTCddtVhvjkga9ILoZJ9NxWS7Yiw==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [win32] + requiresBuild: true + dev: true + optional: true + + /@next/swc-win32-ia32-msvc/12.3.0: + resolution: {integrity: sha512-MQGUpMbYhQmTZ06a9e0hPQJnxFMwETo2WtyAotY3GEzbNCQVbCGhsvqEKcl+ZEHgShlHXUWvSffq1ZscY6gK7A==} + engines: {node: '>= 10'} + cpu: [ia32] + os: [win32] + requiresBuild: true + dev: true + optional: true + + /@next/swc-win32-x64-msvc/12.3.0: + resolution: {integrity: sha512-C/nw6OgQpEULWqs+wgMHXGvlJLguPRFFGqR2TAqWBerQ8J+Sg3z1ZTqwelkSi4FoqStGuZ2UdFHIDN1ySmR1xA==} + engines: {node: '>= 10'} + cpu: [x64] + os: [win32] + requiresBuild: true + dev: true + optional: true + /@nodelib/fs.scandir/2.1.5: resolution: {integrity: sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==} engines: {node: '>= 8'} @@ -582,7 +717,7 @@ packages: '@octokit/request-error': 3.0.1 '@octokit/types': 7.2.0 is-plain-object: 5.0.0 - node-fetch: registry.npmjs.org/node-fetch/2.6.7 + node-fetch: 2.6.7 universal-user-agent: 6.0.0 transitivePeerDependencies: - encoding @@ -698,7 +833,7 @@ packages: dependencies: '@types/http-cache-semantics': 4.0.1 '@types/keyv': 3.1.4 - '@types/node': registry.npmjs.org/@types/node/18.7.15 + '@types/node': 18.7.15 '@types/responselike': 1.0.0 dev: true @@ -737,13 +872,20 @@ packages: /@types/keyv/3.1.4: resolution: {integrity: sha512-BQ5aZNSCpj7D6K2ksrRCTmKRLEpnPvWDiLPfoGyhZ++8YtiK9d/3DBKPJgry359X/P1PfruyYwvnvwFjuEiEIg==} dependencies: - '@types/node': registry.npmjs.org/@types/node/18.7.15 + '@types/node': 18.7.15 dev: true /@types/ms/0.7.31: resolution: {integrity: sha512-iiUgKzV9AuaEkZqkOLDIvlQiL6ltuZd9tGcW3gwpnX8JbuiuhFlEGmmFXEXkN50Cvq7Os88IY2v0dkDqXYWVgA==} dev: true + /@types/node-fetch/2.6.2: + resolution: {integrity: sha512-DHqhlq5jeESLy19TYhLakJ07kNumXWjcDdxXsLUMJZ6ue8VZJj4kLPQVE/2mdHh3xZziNF1xppu5lwmS53HR+A==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.com/@types/node-fetch/-/node-fetch-2.6.2.tgz} + dependencies: + '@types/node': 18.7.15 + form-data: 3.0.1 + dev: true + /@types/node/18.7.15: resolution: {integrity: sha512-XnjpaI8Bgc3eBag2Aw4t2Uj/49lLBSStHWfqKvIuXD7FIrZyMLWp8KuAFHAqxMZYTF9l08N1ctUn9YNybZJVmQ==} dev: true @@ -773,7 +915,7 @@ packages: /@types/responselike/1.0.0: resolution: {integrity: sha512-85Y2BjiufFzaMIlvJDvTTB8Fxl2xfLo4HgmHzVBz08w4wDePCTjYw66PdrolO0kzli3yam/YCgRufyo1DdQVTA==} dependencies: - '@types/node': registry.npmjs.org/@types/node/18.7.15 + '@types/node': 18.7.15 dev: true /@types/scheduler/0.16.2: @@ -1159,7 +1301,7 @@ packages: dev: true /asynckit/0.4.0: - resolution: {integrity: sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==} + resolution: {integrity: sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==, registry: https://registry.npmjs.com/} dev: true /axe-core/4.4.3: @@ -1265,7 +1407,6 @@ packages: /bytes/3.1.2: resolution: {integrity: sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==} engines: {node: '>= 0.8'} - dev: true /c8/7.12.0: resolution: {integrity: sha512-CtgQrHOkyxr5koX1wEUmN/5cfDa2ckbHRA4Gy5LAL0zaCFtVWJS5++n+w4/sr2GWGerBxgTjpKeDclk/Qk6W/A==} @@ -1385,7 +1526,7 @@ packages: normalize-path: 3.0.0 readdirp: 3.6.0 optionalDependencies: - fsevents: registry.npmjs.org/fsevents/2.3.2 + fsevents: 2.3.2 dev: true /ci-info/3.3.2: @@ -1466,7 +1607,7 @@ packages: dev: true /combined-stream/1.0.8: - resolution: {integrity: sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==} + resolution: {integrity: sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==, registry: https://registry.npmjs.com/} engines: {node: '>= 0.8'} dependencies: delayed-stream: 1.0.0 @@ -1591,7 +1732,7 @@ packages: dependencies: abab: 2.0.6 whatwg-mimetype: 3.0.0 - whatwg-url: registry.npmjs.org/whatwg-url/11.0.0 + whatwg-url: 11.0.0 dev: true /debug/2.6.9: @@ -1689,7 +1830,7 @@ packages: dev: true /delayed-stream/1.0.0: - resolution: {integrity: sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==} + resolution: {integrity: sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==, registry: https://registry.npmjs.com/} engines: {node: '>=0.4.0'} dev: true @@ -1701,7 +1842,6 @@ packages: /depd/2.0.0: resolution: {integrity: sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==} engines: {node: '>= 0.8'} - dev: true /deprecation/2.3.1: resolution: {integrity: sha512-xmHIy4F3scKVwMsQ4WnVaS8bHOx0DmVwRywosKhaILI0ywMDWPtBSku2HNxRvF7jtwDRsoEwYQSfbxj8b7RlJQ==} @@ -1848,33 +1988,393 @@ packages: is-symbol: 1.0.4 dev: true + /esbuild-android-64/0.14.54: + resolution: {integrity: sha512-Tz2++Aqqz0rJ7kYBfz+iqyE3QMycD4vk7LBRyWaAVFgFtQ/O8EJOnVmTOiDWYZ/uYzB4kvP+bqejYdVKzE5lAQ==} + engines: {node: '>=12'} + cpu: [x64] + os: [android] + requiresBuild: true + dev: true + optional: true + + /esbuild-android-64/0.15.7: + resolution: {integrity: sha512-p7rCvdsldhxQr3YHxptf1Jcd86dlhvc3EQmQJaZzzuAxefO9PvcI0GLOa5nCWem1AJ8iMRu9w0r5TG8pHmbi9w==} + engines: {node: '>=12'} + cpu: [x64] + os: [android] + requiresBuild: true + dev: true + optional: true + + /esbuild-android-arm64/0.14.54: + resolution: {integrity: sha512-F9E+/QDi9sSkLaClO8SOV6etqPd+5DgJje1F9lOWoNncDdOBL2YF59IhsWATSt0TLZbYCf3pNlTHvVV5VfHdvg==} + engines: {node: '>=12'} + cpu: [arm64] + os: [android] + requiresBuild: true + dev: true + optional: true + + /esbuild-android-arm64/0.15.7: + resolution: {integrity: sha512-L775l9ynJT7rVqRM5vo+9w5g2ysbOCfsdLV4CWanTZ1k/9Jb3IYlQ06VCI1edhcosTYJRECQFJa3eAvkx72eyQ==} + engines: {node: '>=12'} + cpu: [arm64] + os: [android] + requiresBuild: true + dev: true + optional: true + + /esbuild-darwin-64/0.14.54: + resolution: {integrity: sha512-jtdKWV3nBviOd5v4hOpkVmpxsBy90CGzebpbO9beiqUYVMBtSc0AL9zGftFuBon7PNDcdvNCEuQqw2x0wP9yug==} + engines: {node: '>=12'} + cpu: [x64] + os: [darwin] + requiresBuild: true + dev: true + optional: true + + /esbuild-darwin-64/0.15.7: + resolution: {integrity: sha512-KGPt3r1c9ww009t2xLB6Vk0YyNOXh7hbjZ3EecHoVDxgtbUlYstMPDaReimKe6eOEfyY4hBEEeTvKwPsiH5WZg==} + engines: {node: '>=12'} + cpu: [x64] + os: [darwin] + requiresBuild: true + dev: true + optional: true + + /esbuild-darwin-arm64/0.14.54: + resolution: {integrity: sha512-OPafJHD2oUPyvJMrsCvDGkRrVCar5aVyHfWGQzY1dWnzErjrDuSETxwA2HSsyg2jORLY8yBfzc1MIpUkXlctmw==} + engines: {node: '>=12'} + cpu: [arm64] + os: [darwin] + requiresBuild: true + dev: true + optional: true + + /esbuild-darwin-arm64/0.15.7: + resolution: {integrity: sha512-kBIHvtVqbSGajN88lYMnR3aIleH3ABZLLFLxwL2stiuIGAjGlQW741NxVTpUHQXUmPzxi6POqc9npkXa8AcSZQ==} + engines: {node: '>=12'} + cpu: [arm64] + os: [darwin] + requiresBuild: true + dev: true + optional: true + + /esbuild-freebsd-64/0.14.54: + resolution: {integrity: sha512-OKwd4gmwHqOTp4mOGZKe/XUlbDJ4Q9TjX0hMPIDBUWWu/kwhBAudJdBoxnjNf9ocIB6GN6CPowYpR/hRCbSYAg==} + engines: {node: '>=12'} + cpu: [x64] + os: [freebsd] + requiresBuild: true + dev: true + optional: true + + /esbuild-freebsd-64/0.15.7: + resolution: {integrity: sha512-hESZB91qDLV5MEwNxzMxPfbjAhOmtfsr9Wnuci7pY6TtEh4UDuevmGmkUIjX/b+e/k4tcNBMf7SRQ2mdNuK/HQ==} + engines: {node: '>=12'} + cpu: [x64] + os: [freebsd] + requiresBuild: true + dev: true + optional: true + + /esbuild-freebsd-arm64/0.14.54: + resolution: {integrity: sha512-sFwueGr7OvIFiQT6WeG0jRLjkjdqWWSrfbVwZp8iMP+8UHEHRBvlaxL6IuKNDwAozNUmbb8nIMXa7oAOARGs1Q==} + engines: {node: '>=12'} + cpu: [arm64] + os: [freebsd] + requiresBuild: true + dev: true + optional: true + + /esbuild-freebsd-arm64/0.15.7: + resolution: {integrity: sha512-dLFR0ChH5t+b3J8w0fVKGvtwSLWCv7GYT2Y2jFGulF1L5HftQLzVGN+6pi1SivuiVSmTh28FwUhi9PwQicXI6Q==} + engines: {node: '>=12'} + cpu: [arm64] + os: [freebsd] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-32/0.14.54: + resolution: {integrity: sha512-1ZuY+JDI//WmklKlBgJnglpUL1owm2OX+8E1syCD6UAxcMM/XoWd76OHSjl/0MR0LisSAXDqgjT3uJqT67O3qw==} + engines: {node: '>=12'} + cpu: [ia32] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-32/0.15.7: + resolution: {integrity: sha512-v3gT/LsONGUZcjbt2swrMjwxo32NJzk+7sAgtxhGx1+ZmOFaTRXBAi1PPfgpeo/J//Un2jIKm/I+qqeo4caJvg==} + engines: {node: '>=12'} + cpu: [ia32] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-64/0.14.54: + resolution: {integrity: sha512-EgjAgH5HwTbtNsTqQOXWApBaPVdDn7XcK+/PtJwZLT1UmpLoznPd8c5CxqsH2dQK3j05YsB3L17T8vE7cp4cCg==} + engines: {node: '>=12'} + cpu: [x64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-64/0.15.7: + resolution: {integrity: sha512-LxXEfLAKwOVmm1yecpMmWERBshl+Kv5YJ/1KnyAr6HRHFW8cxOEsEfisD3sVl/RvHyW//lhYUVSuy9jGEfIRAQ==} + engines: {node: '>=12'} + cpu: [x64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-arm/0.14.54: + resolution: {integrity: sha512-qqz/SjemQhVMTnvcLGoLOdFpCYbz4v4fUo+TfsWG+1aOu70/80RV6bgNpR2JCrppV2moUQkww+6bWxXRL9YMGw==} + engines: {node: '>=12'} + cpu: [arm] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-arm/0.15.7: + resolution: {integrity: sha512-JKgAHtMR5f75wJTeuNQbyznZZa+pjiUHV7sRZp42UNdyXC6TiUYMW/8z8yIBAr2Fpad8hM1royZKQisqPABPvQ==} + engines: {node: '>=12'} + cpu: [arm] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-arm64/0.14.54: + resolution: {integrity: sha512-WL71L+0Rwv+Gv/HTmxTEmpv0UgmxYa5ftZILVi2QmZBgX3q7+tDeOQNqGtdXSdsL8TQi1vIaVFHUPDe0O0kdig==} + engines: {node: '>=12'} + cpu: [arm64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-arm64/0.15.7: + resolution: {integrity: sha512-P3cfhudpzWDkglutWgXcT2S7Ft7o2e3YDMrP1n0z2dlbUZghUkKCyaWw0zhp4KxEEzt/E7lmrtRu/pGWnwb9vw==} + engines: {node: '>=12'} + cpu: [arm64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-mips64le/0.14.54: + resolution: {integrity: sha512-qTHGQB8D1etd0u1+sB6p0ikLKRVuCWhYQhAHRPkO+OF3I/iSlTKNNS0Lh2Oc0g0UFGguaFZZiPJdJey3AGpAlw==} + engines: {node: '>=12'} + cpu: [mips64el] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-mips64le/0.15.7: + resolution: {integrity: sha512-T7XKuxl0VpeFLCJXub6U+iybiqh0kM/bWOTb4qcPyDDwNVhLUiPcGdG2/0S7F93czUZOKP57YiLV8YQewgLHKw==} + engines: {node: '>=12'} + cpu: [mips64el] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-ppc64le/0.14.54: + resolution: {integrity: sha512-j3OMlzHiqwZBDPRCDFKcx595XVfOfOnv68Ax3U4UKZ3MTYQB5Yz3X1mn5GnodEVYzhtZgxEBidLWeIs8FDSfrQ==} + engines: {node: '>=12'} + cpu: [ppc64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-ppc64le/0.15.7: + resolution: {integrity: sha512-6mGuC19WpFN7NYbecMIJjeQgvDb5aMuvyk0PDYBJrqAEMkTwg3Z98kEKuCm6THHRnrgsdr7bp4SruSAxEM4eJw==} + engines: {node: '>=12'} + cpu: [ppc64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-riscv64/0.14.54: + resolution: {integrity: sha512-y7Vt7Wl9dkOGZjxQZnDAqqn+XOqFD7IMWiewY5SPlNlzMX39ocPQlOaoxvT4FllA5viyV26/QzHtvTjVNOxHZg==} + engines: {node: '>=12'} + cpu: [riscv64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-riscv64/0.15.7: + resolution: {integrity: sha512-uUJsezbswAYo/X7OU/P+PuL/EI9WzxsEQXDekfwpQ23uGiooxqoLFAPmXPcRAt941vjlY9jtITEEikWMBr+F/g==} + engines: {node: '>=12'} + cpu: [riscv64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-s390x/0.14.54: + resolution: {integrity: sha512-zaHpW9dziAsi7lRcyV4r8dhfG1qBidQWUXweUjnw+lliChJqQr+6XD71K41oEIC3Mx1KStovEmlzm+MkGZHnHA==} + engines: {node: '>=12'} + cpu: [s390x] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-linux-s390x/0.15.7: + resolution: {integrity: sha512-+tO+xOyTNMc34rXlSxK7aCwJgvQyffqEM5MMdNDEeMU3ss0S6wKvbBOQfgd5jRPblfwJ6b+bKiz0g5nABpY0QQ==} + engines: {node: '>=12'} + cpu: [s390x] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /esbuild-netbsd-64/0.14.54: + resolution: {integrity: sha512-PR01lmIMnfJTgeU9VJTDY9ZerDWVFIUzAtJuDHwwceppW7cQWjBBqP48NdeRtoP04/AtO9a7w3viI+PIDr6d+w==} + engines: {node: '>=12'} + cpu: [x64] + os: [netbsd] + requiresBuild: true + dev: true + optional: true + + /esbuild-netbsd-64/0.15.7: + resolution: {integrity: sha512-yVc4Wz+Pu3cP5hzm5kIygNPrjar/v5WCSoRmIjCPWfBVJkZNb5brEGKUlf+0Y759D48BCWa0WHrWXaNy0DULTQ==} + engines: {node: '>=12'} + cpu: [x64] + os: [netbsd] + requiresBuild: true + dev: true + optional: true + + /esbuild-openbsd-64/0.14.54: + resolution: {integrity: sha512-Qyk7ikT2o7Wu76UsvvDS5q0amJvmRzDyVlL0qf5VLsLchjCa1+IAvd8kTBgUxD7VBUUVgItLkk609ZHUc1oCaw==} + engines: {node: '>=12'} + cpu: [x64] + os: [openbsd] + requiresBuild: true + dev: true + optional: true + + /esbuild-openbsd-64/0.15.7: + resolution: {integrity: sha512-GsimbwC4FSR4lN3wf8XmTQ+r8/0YSQo21rWDL0XFFhLHKlzEA4SsT1Tl8bPYu00IU6UWSJ+b3fG/8SB69rcuEQ==} + engines: {node: '>=12'} + cpu: [x64] + os: [openbsd] + requiresBuild: true + dev: true + optional: true + + /esbuild-sunos-64/0.14.54: + resolution: {integrity: sha512-28GZ24KmMSeKi5ueWzMcco6EBHStL3B6ubM7M51RmPwXQGLe0teBGJocmWhgwccA1GeFXqxzILIxXpHbl9Q/Kw==} + engines: {node: '>=12'} + cpu: [x64] + os: [sunos] + requiresBuild: true + dev: true + optional: true + + /esbuild-sunos-64/0.15.7: + resolution: {integrity: sha512-8CDI1aL/ts0mDGbWzjEOGKXnU7p3rDzggHSBtVryQzkSOsjCHRVe0iFYUuhczlxU1R3LN/E7HgUO4NXzGGP/Ag==} + engines: {node: '>=12'} + cpu: [x64] + os: [sunos] + requiresBuild: true + dev: true + optional: true + + /esbuild-windows-32/0.14.54: + resolution: {integrity: sha512-T+rdZW19ql9MjS7pixmZYVObd9G7kcaZo+sETqNH4RCkuuYSuv9AGHUVnPoP9hhuE1WM1ZimHz1CIBHBboLU7w==} + engines: {node: '>=12'} + cpu: [ia32] + os: [win32] + requiresBuild: true + dev: true + optional: true + + /esbuild-windows-32/0.15.7: + resolution: {integrity: sha512-cOnKXUEPS8EGCzRSFa1x6NQjGhGsFlVgjhqGEbLTPsA7x4RRYiy2RKoArNUU4iR2vHmzqS5Gr84MEumO/wxYKA==} + engines: {node: '>=12'} + cpu: [ia32] + os: [win32] + requiresBuild: true + dev: true + optional: true + + /esbuild-windows-64/0.14.54: + resolution: {integrity: sha512-AoHTRBUuYwXtZhjXZbA1pGfTo8cJo3vZIcWGLiUcTNgHpJJMC1rVA44ZereBHMJtotyN71S8Qw0npiCIkW96cQ==} + engines: {node: '>=12'} + cpu: [x64] + os: [win32] + requiresBuild: true + dev: true + optional: true + + /esbuild-windows-64/0.15.7: + resolution: {integrity: sha512-7MI08Ec2sTIDv+zH6StNBKO+2hGUYIT42GmFyW6MBBWWtJhTcQLinKS6ldIN1d52MXIbiJ6nXyCJ+LpL4jBm3Q==} + engines: {node: '>=12'} + cpu: [x64] + os: [win32] + requiresBuild: true + dev: true + optional: true + + /esbuild-windows-arm64/0.14.54: + resolution: {integrity: sha512-M0kuUvXhot1zOISQGXwWn6YtS+Y/1RT9WrVIOywZnJHo3jCDyewAc79aKNQWFCQm+xNHVTq9h8dZKvygoXQQRg==} + engines: {node: '>=12'} + cpu: [arm64] + os: [win32] + requiresBuild: true + dev: true + optional: true + + /esbuild-windows-arm64/0.15.7: + resolution: {integrity: sha512-R06nmqBlWjKHddhRJYlqDd3Fabx9LFdKcjoOy08YLimwmsswlFBJV4rXzZCxz/b7ZJXvrZgj8DDv1ewE9+StMw==} + engines: {node: '>=12'} + cpu: [arm64] + os: [win32] + requiresBuild: true + dev: true + optional: true + /esbuild/0.14.54: resolution: {integrity: sha512-Cy9llcy8DvET5uznocPyqL3BFRrFXSVqbgpMJ9Wz8oVjZlh/zUSNbPRbov0VX7VxN2JH1Oa0uNxZ7eLRb62pJA==} engines: {node: '>=12'} hasBin: true requiresBuild: true optionalDependencies: - '@esbuild/linux-loong64': registry.npmjs.org/@esbuild/linux-loong64/0.14.54 - esbuild-android-64: registry.npmjs.org/esbuild-android-64/0.14.54 - esbuild-android-arm64: registry.npmjs.org/esbuild-android-arm64/0.14.54 - esbuild-darwin-64: registry.npmjs.org/esbuild-darwin-64/0.14.54 - esbuild-darwin-arm64: registry.npmjs.org/esbuild-darwin-arm64/0.14.54 - esbuild-freebsd-64: registry.npmjs.org/esbuild-freebsd-64/0.14.54 - esbuild-freebsd-arm64: registry.npmjs.org/esbuild-freebsd-arm64/0.14.54 - esbuild-linux-32: registry.npmjs.org/esbuild-linux-32/0.14.54 - esbuild-linux-64: registry.npmjs.org/esbuild-linux-64/0.14.54 - esbuild-linux-arm: registry.npmjs.org/esbuild-linux-arm/0.14.54 - esbuild-linux-arm64: registry.npmjs.org/esbuild-linux-arm64/0.14.54 - esbuild-linux-mips64le: registry.npmjs.org/esbuild-linux-mips64le/0.14.54 - esbuild-linux-ppc64le: registry.npmjs.org/esbuild-linux-ppc64le/0.14.54 - esbuild-linux-riscv64: registry.npmjs.org/esbuild-linux-riscv64/0.14.54 - esbuild-linux-s390x: registry.npmjs.org/esbuild-linux-s390x/0.14.54 - esbuild-netbsd-64: registry.npmjs.org/esbuild-netbsd-64/0.14.54 - esbuild-openbsd-64: registry.npmjs.org/esbuild-openbsd-64/0.14.54 - esbuild-sunos-64: registry.npmjs.org/esbuild-sunos-64/0.14.54 - esbuild-windows-32: registry.npmjs.org/esbuild-windows-32/0.14.54 - esbuild-windows-64: registry.npmjs.org/esbuild-windows-64/0.14.54 - esbuild-windows-arm64: registry.npmjs.org/esbuild-windows-arm64/0.14.54 + '@esbuild/linux-loong64': 0.14.54 + esbuild-android-64: 0.14.54 + esbuild-android-arm64: 0.14.54 + esbuild-darwin-64: 0.14.54 + esbuild-darwin-arm64: 0.14.54 + esbuild-freebsd-64: 0.14.54 + esbuild-freebsd-arm64: 0.14.54 + esbuild-linux-32: 0.14.54 + esbuild-linux-64: 0.14.54 + esbuild-linux-arm: 0.14.54 + esbuild-linux-arm64: 0.14.54 + esbuild-linux-mips64le: 0.14.54 + esbuild-linux-ppc64le: 0.14.54 + esbuild-linux-riscv64: 0.14.54 + esbuild-linux-s390x: 0.14.54 + esbuild-netbsd-64: 0.14.54 + esbuild-openbsd-64: 0.14.54 + esbuild-sunos-64: 0.14.54 + esbuild-windows-32: 0.14.54 + esbuild-windows-64: 0.14.54 + esbuild-windows-arm64: 0.14.54 dev: true /esbuild/0.15.7: @@ -1883,27 +2383,27 @@ packages: hasBin: true requiresBuild: true optionalDependencies: - '@esbuild/linux-loong64': registry.npmjs.org/@esbuild/linux-loong64/0.15.7 - esbuild-android-64: registry.npmjs.org/esbuild-android-64/0.15.7 - esbuild-android-arm64: registry.npmjs.org/esbuild-android-arm64/0.15.7 - esbuild-darwin-64: registry.npmjs.org/esbuild-darwin-64/0.15.7 - esbuild-darwin-arm64: registry.npmjs.org/esbuild-darwin-arm64/0.15.7 - esbuild-freebsd-64: registry.npmjs.org/esbuild-freebsd-64/0.15.7 - esbuild-freebsd-arm64: registry.npmjs.org/esbuild-freebsd-arm64/0.15.7 - esbuild-linux-32: registry.npmjs.org/esbuild-linux-32/0.15.7 - esbuild-linux-64: registry.npmjs.org/esbuild-linux-64/0.15.7 - esbuild-linux-arm: registry.npmjs.org/esbuild-linux-arm/0.15.7 - esbuild-linux-arm64: registry.npmjs.org/esbuild-linux-arm64/0.15.7 - esbuild-linux-mips64le: registry.npmjs.org/esbuild-linux-mips64le/0.15.7 - esbuild-linux-ppc64le: registry.npmjs.org/esbuild-linux-ppc64le/0.15.7 - esbuild-linux-riscv64: registry.npmjs.org/esbuild-linux-riscv64/0.15.7 - esbuild-linux-s390x: registry.npmjs.org/esbuild-linux-s390x/0.15.7 - esbuild-netbsd-64: registry.npmjs.org/esbuild-netbsd-64/0.15.7 - esbuild-openbsd-64: registry.npmjs.org/esbuild-openbsd-64/0.15.7 - esbuild-sunos-64: registry.npmjs.org/esbuild-sunos-64/0.15.7 - esbuild-windows-32: registry.npmjs.org/esbuild-windows-32/0.15.7 - esbuild-windows-64: registry.npmjs.org/esbuild-windows-64/0.15.7 - esbuild-windows-arm64: registry.npmjs.org/esbuild-windows-arm64/0.15.7 + '@esbuild/linux-loong64': 0.15.7 + esbuild-android-64: 0.15.7 + esbuild-android-arm64: 0.15.7 + esbuild-darwin-64: 0.15.7 + esbuild-darwin-arm64: 0.15.7 + esbuild-freebsd-64: 0.15.7 + esbuild-freebsd-arm64: 0.15.7 + esbuild-linux-32: 0.15.7 + esbuild-linux-64: 0.15.7 + esbuild-linux-arm: 0.15.7 + esbuild-linux-arm64: 0.15.7 + esbuild-linux-mips64le: 0.15.7 + esbuild-linux-ppc64le: 0.15.7 + esbuild-linux-riscv64: 0.15.7 + esbuild-linux-s390x: 0.15.7 + esbuild-netbsd-64: 0.15.7 + esbuild-openbsd-64: 0.15.7 + esbuild-sunos-64: 0.15.7 + esbuild-windows-32: 0.15.7 + esbuild-windows-64: 0.15.7 + esbuild-windows-arm64: 0.15.7 dev: true /escalade/3.1.1: @@ -1941,7 +2441,7 @@ packages: esutils: 2.0.3 optionator: 0.8.3 optionalDependencies: - source-map: registry.npmjs.org/source-map/0.6.1 + source-map: 0.6.1 dev: true /escodegen/2.0.0: @@ -1954,7 +2454,7 @@ packages: esutils: 2.0.3 optionator: 0.8.3 optionalDependencies: - source-map: registry.npmjs.org/source-map/0.6.1 + source-map: 0.6.1 dev: true /eslint-config-airbnb-base/15.0.0_faomjyrlgqmwswvqymymzkxcqi: @@ -2414,6 +2914,15 @@ packages: engines: {node: '>= 14.17'} dev: true + /form-data/3.0.1: + resolution: {integrity: sha512-RHkBKtLWUVwd7SqRIvCZMEvAMoGUp0XU+seQiZejj0COz3RI3hWP4sCv3gZWWLjJTd7rGwcsF5eKZGii0r/hbg==, registry: https://registry.npmjs.com/} + engines: {node: '>= 6'} + dependencies: + asynckit: 0.4.0 + combined-stream: 1.0.8 + mime-types: 2.1.35 + dev: true + /form-data/4.0.0: resolution: {integrity: sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==} engines: {node: '>= 6'} @@ -2448,6 +2957,14 @@ packages: resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} dev: true + /fsevents/2.3.2: + resolution: {integrity: sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==} + engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} + os: [darwin] + requiresBuild: true + dev: true + optional: true + /ftp/0.3.10: resolution: {integrity: sha512-faFVML1aBx2UoDStmLwv2Wptt4vw5x03xxX172nhA5Y5HBshW5JweqQ2W4xL4dezQTG8inJsuYcpPHHU3X5OTQ==} engines: {node: '>=0.8.0'} @@ -2736,7 +3253,6 @@ packages: setprototypeof: 1.2.0 statuses: 2.0.1 toidentifier: 1.0.1 - dev: true /http-proxy-agent/4.0.1: resolution: {integrity: sha512-k0zdNgqWTGA6aeIRVpvfVob4fL52dTfaehylg0Y4UvSySvOq/Y+BOyPrgpUrA7HylqvU8vIZGsRuXmspskV0Tg==} @@ -2799,7 +3315,6 @@ packages: engines: {node: '>=0.10.0'} dependencies: safer-buffer: 2.1.2 - dev: true /iconv-lite/0.6.3: resolution: {integrity: sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==} @@ -2844,7 +3359,6 @@ packages: /inherits/2.0.4: resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==} - dev: true /ini/1.3.8: resolution: {integrity: sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==} @@ -3254,7 +3768,7 @@ packages: /jsonfile/4.0.0: resolution: {integrity: sha512-m6F1R3z8jjlf2imQHS2Qez5sjKWQzbuuhuJ/FKYFRZvPE3PuHcSMVZzfsLhGVOkfd20obL5SWEBew5ShlquNxg==} optionalDependencies: - graceful-fs: registry.npmjs.org/graceful-fs/4.2.10 + graceful-fs: 4.2.10 dev: true /jsx-ast-utils/3.3.3: @@ -3487,11 +4001,6 @@ packages: resolution: {integrity: sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==} dev: true - /mri/1.2.0: - resolution: {integrity: sha512-tzzskb3bG8LvYGFF/mDTpq3jpI6Q9wc3LEmBaghu+DdCssd1FakN7Bc0hVNmEyGq1bq3RgfkCb3cmQLpNPOroA==} - engines: {node: '>=4'} - dev: true - /ms/2.0.0: resolution: {integrity: sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==} dev: true @@ -3542,7 +4051,7 @@ packages: type-fest: 2.19.0 dev: true - /next/12.3.0_rlaikcoslzwwtqyk7brpdzej5y: + /next/12.3.0_biqbaboplfbrettd7655fr4n2y: resolution: {integrity: sha512-GpzI6me9V1+XYtfK0Ae9WD0mKqHyzQlGq1xH1rzNIYMASo4Tkl4rTe9jSqtBpXFhOS33KohXs9ZY38Akkhdciw==} engines: {node: '>=12.22.0'} hasBin: true @@ -3566,22 +4075,22 @@ packages: postcss: 8.4.14 react: 18.2.0 react-dom: 18.2.0_react@18.2.0 - styled-jsx: 5.0.6_ucuhn75irpsvlf3yq3xnib3jky + styled-jsx: 5.0.6_react@18.2.0 use-sync-external-store: 1.2.0_react@18.2.0 optionalDependencies: - '@next/swc-android-arm-eabi': registry.npmjs.org/@next/swc-android-arm-eabi/12.3.0 - '@next/swc-android-arm64': registry.npmjs.org/@next/swc-android-arm64/12.3.0 - '@next/swc-darwin-arm64': registry.npmjs.org/@next/swc-darwin-arm64/12.3.0 - '@next/swc-darwin-x64': registry.npmjs.org/@next/swc-darwin-x64/12.3.0 - '@next/swc-freebsd-x64': registry.npmjs.org/@next/swc-freebsd-x64/12.3.0 - '@next/swc-linux-arm-gnueabihf': registry.npmjs.org/@next/swc-linux-arm-gnueabihf/12.3.0 - '@next/swc-linux-arm64-gnu': registry.npmjs.org/@next/swc-linux-arm64-gnu/12.3.0 - '@next/swc-linux-arm64-musl': registry.npmjs.org/@next/swc-linux-arm64-musl/12.3.0 - '@next/swc-linux-x64-gnu': registry.npmjs.org/@next/swc-linux-x64-gnu/12.3.0 - '@next/swc-linux-x64-musl': registry.npmjs.org/@next/swc-linux-x64-musl/12.3.0 - '@next/swc-win32-arm64-msvc': registry.npmjs.org/@next/swc-win32-arm64-msvc/12.3.0 - '@next/swc-win32-ia32-msvc': registry.npmjs.org/@next/swc-win32-ia32-msvc/12.3.0 - '@next/swc-win32-x64-msvc': registry.npmjs.org/@next/swc-win32-x64-msvc/12.3.0 + '@next/swc-android-arm-eabi': 12.3.0 + '@next/swc-android-arm64': 12.3.0 + '@next/swc-darwin-arm64': 12.3.0 + '@next/swc-darwin-x64': 12.3.0 + '@next/swc-freebsd-x64': 12.3.0 + '@next/swc-linux-arm-gnueabihf': 12.3.0 + '@next/swc-linux-arm64-gnu': 12.3.0 + '@next/swc-linux-arm64-musl': 12.3.0 + '@next/swc-linux-x64-gnu': 12.3.0 + '@next/swc-linux-x64-musl': 12.3.0 + '@next/swc-win32-arm64-msvc': 12.3.0 + '@next/swc-win32-ia32-msvc': 12.3.0 + '@next/swc-win32-x64-msvc': 12.3.0 transitivePeerDependencies: - '@babel/core' - babel-plugin-macros @@ -3592,6 +4101,26 @@ packages: engines: {node: '>=10.5.0'} dev: true + /node-fetch/2.6.7: + resolution: {integrity: sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.com/node-fetch/-/node-fetch-2.6.7.tgz} + engines: {node: 4.x || >=6.0.0} + peerDependencies: + encoding: ^0.1.0 + peerDependenciesMeta: + encoding: + optional: true + dependencies: + whatwg-url: 5.0.0 + + /node-fetch/3.2.10: + resolution: {integrity: sha512-MhuzNwdURnZ1Cp4XTazr69K0BTizsBroX7Zx3UgDSVcZYKF/6p0CBe4EUb/hLqmzVhl0UpYfgRljQ4yxE+iCxA==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.com/node-fetch/-/node-fetch-3.2.10.tgz} + engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} + dependencies: + data-uri-to-buffer: 4.0.0 + fetch-blob: 3.2.0 + formdata-polyfill: 4.0.10 + dev: true + /node-mocks-http/1.11.0: resolution: {integrity: sha512-jS/WzSOcKbOeGrcgKbenZeNhxUNnP36Yw11+hL4TTxQXErGfqYZ+MaYNNvhaTiGIJlzNSqgQkk9j8dSu1YWSuw==} engines: {node: '>=0.6'} @@ -4075,7 +4604,6 @@ packages: http-errors: 2.0.0 iconv-lite: 0.4.24 unpipe: 1.0.0 - dev: true /rc/1.2.8: resolution: {integrity: sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==} @@ -4201,7 +4729,7 @@ packages: lodash: 4.17.21 mime-types: 2.1.35 new-github-release-url: 2.0.0 - node-fetch: registry.npmjs.org/node-fetch/3.2.10 + node-fetch: 3.2.10 open: 8.4.0 ora: 6.1.2 os-name: 5.0.1 @@ -4301,7 +4829,7 @@ packages: engines: {node: '>=10.0.0'} hasBin: true optionalDependencies: - fsevents: registry.npmjs.org/fsevents/2.3.2 + fsevents: 2.3.2 dev: true /rollup/2.79.0: @@ -4309,7 +4837,7 @@ packages: engines: {node: '>=10.0.0'} hasBin: true optionalDependencies: - fsevents: registry.npmjs.org/fsevents/2.3.2 + fsevents: 2.3.2 dev: true /run-async/2.4.1: @@ -4338,7 +4866,6 @@ packages: /safer-buffer/2.1.2: resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} - dev: true /saxes/6.0.0: resolution: {integrity: sha512-xAg7SOnEhrm5zI3puOOKyy1OMcMlIJZYNJY7xLBwSze0UjhPLnWfj2GF2EpT0jmzaJKIWKHLsaSSajf35bcYnA==} @@ -4375,7 +4902,6 @@ packages: /setprototypeof/1.2.0: resolution: {integrity: sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==} - dev: true /shebang-command/2.0.0: resolution: {integrity: sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==} @@ -4450,11 +4976,18 @@ packages: engines: {node: '>=0.10.0'} dev: true + /source-map/0.6.1: + resolution: {integrity: sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==} + engines: {node: '>=0.10.0'} + requiresBuild: true + dev: true + optional: true + /source-map/0.8.0-beta.0: resolution: {integrity: sha512-2ymg6oRBpebeZi9UUNsgQ89bhx01TcTkmNTGnNO88imTmbSgy4nfujrgVEFKWpMTEGA11EDkTt7mqObTPdigIA==} engines: {node: '>= 8'} dependencies: - whatwg-url: registry.npmjs.org/whatwg-url/7.1.0 + whatwg-url: 7.1.0 dev: true /sourcemap-codec/1.4.8: @@ -4464,7 +4997,6 @@ packages: /statuses/2.0.1: resolution: {integrity: sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ==} engines: {node: '>= 0.8'} - dev: true /streamsearch/1.1.0: resolution: {integrity: sha512-Mcc5wHehp9aXz1ax6bZUyY5afg9u2rv5cqQI3mRrYkGC8rW2hM02jWuwjtL++LS5qinSyhj2QfLyNsuc+VsExg==} @@ -4573,7 +5105,7 @@ packages: acorn: 8.8.0 dev: true - /styled-jsx/5.0.6_ucuhn75irpsvlf3yq3xnib3jky: + /styled-jsx/5.0.6_react@18.2.0: resolution: {integrity: sha512-xOeROtkK5MGMDimBQ3J6iPId8q0t/BDoG5XN6oKkZClVz9ISF/hihN8OCn2LggMU6N32aXnrXBdn3auSqNS9fA==} engines: {node: '>= 12.0.0'} peerDependencies: @@ -4586,7 +5118,6 @@ packages: babel-plugin-macros: optional: true dependencies: - '@babel/core': 7.18.13 react: 18.2.0 dev: true @@ -4721,7 +5252,6 @@ packages: /toidentifier/1.0.1: resolution: {integrity: sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==} engines: {node: '>=0.6'} - dev: true /tough-cookie/4.1.2: resolution: {integrity: sha512-G9fqXWoYFZgTc2z8Q5zaHy/vJMjm+WV0AkAeHxVCQiEB1b+dGvWzFW6QV07cY5jQ5gRkeid2qIkzkxUnmoQZUQ==} @@ -4733,6 +5263,15 @@ packages: url-parse: 1.5.10 dev: true + /tr46/0.0.3: + resolution: {integrity: sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==, registry: https://registry.npmjs.com/} + + /tr46/1.0.1: + resolution: {integrity: sha512-dTpowEjclQ7Kgx5SdBkqRzVhERQXov8/l9Ft9dVM9fmg0W0KQSVaXX9T4i6twCPNtYiZM53lpSSUAwJbFPOHxA==, registry: https://registry.npmjs.com/} + dependencies: + punycode: 2.1.1 + dev: true + /tr46/3.0.0: resolution: {integrity: sha512-l7FvfAHlcmulp8kr+flpQZmVwtu7nfRV7NZujtN0OqES8EL4O4e0qqzL0DC5gAvx/ZC/9lk6rhcUwYvkBnBnYA==} engines: {node: '>=12'} @@ -4907,7 +5446,6 @@ packages: /unpipe/1.0.0: resolution: {integrity: sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==} engines: {node: '>= 0.8'} - dev: true /update-browserslist-db/1.0.7_browserslist@4.21.3: resolution: {integrity: sha512-iN/XYesmZ2RmmWAiI4Z5rq0YqSiv0brj9Ce9CfhNE4xIW2h+MFxcgkxIzZ+ShkFPUkjU3gQ+3oypadD3RAMtrg==} @@ -5008,7 +5546,7 @@ packages: resolve: 1.22.1 rollup: 2.78.1 optionalDependencies: - fsevents: registry.npmjs.org/fsevents/2.3.2 + fsevents: 2.3.2 dev: true /vitest/0.23.1_jsdom@20.0.0: @@ -5117,14 +5655,6 @@ packages: xml-name-validator: 4.0.0 dev: true - /watchlist/0.3.1: - resolution: {integrity: sha512-m5r4bzxJ9eg07TT/O0Q49imFPD45ZTuQ3kaHwSpUJj1QwVd3pzit4UYOmySdmAP5Egkz6mB6hcAPuPfhIbNo0g==} - engines: {node: '>=8'} - hasBin: true - dependencies: - mri: 1.2.0 - dev: true - /wcwidth/1.0.1: resolution: {integrity: sha512-XHPEwS0q6TaxcvG85+8EYkbiCux2XtWG2mkc47Ng2A77BQu9+DqIOJldST4HgPkuea7dvKSj5VgX3P1d4rW8Tg==} dependencies: @@ -5136,6 +5666,13 @@ packages: engines: {node: '>= 8'} dev: true + /webidl-conversions/3.0.1: + resolution: {integrity: sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==, registry: https://registry.npmjs.com/} + + /webidl-conversions/4.0.2: + resolution: {integrity: sha512-YQ+BmxuTgd6UXZW3+ICGfyqRyHXVlD5GtQr5+qjiNW7bF0cqrzX500HVXPBOvgXb5YnzDd+h0zqyv61KUD7+Sg==, registry: https://registry.npmjs.com/} + dev: true + /webidl-conversions/7.0.0: resolution: {integrity: sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g==} engines: {node: '>=12'} @@ -5161,6 +5698,20 @@ packages: webidl-conversions: 7.0.0 dev: true + /whatwg-url/5.0.0: + resolution: {integrity: sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.com/whatwg-url/-/whatwg-url-5.0.0.tgz} + dependencies: + tr46: 0.0.3 + webidl-conversions: 3.0.1 + + /whatwg-url/7.1.0: + resolution: {integrity: sha512-WUu7Rg1DroM7oQvGWfOiAK21n74Gg+T4elXEQYkOhtyLeWiJFoOGLXPKI/9gzIie9CtwVLm8wtw6YJdKyxSjeg==, registry: https://registry.npmjs.com/} + dependencies: + lodash.sortby: 4.7.0 + tr46: 1.0.1 + webidl-conversions: 4.0.2 + dev: true + /which-boxed-primitive/1.0.2: resolution: {integrity: sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==} dependencies: @@ -5314,775 +5865,4 @@ packages: resolution: {integrity: sha512-LYjZsEDhCdYET9ikFu6dVPGp2YH9DegXjdJToSzD9rO6fy4qiRYFoyEYwps88OseJlPyl2NOe2iJuhEhL7IpEA==} dev: false - registry.npmjs.org/@esbuild/linux-loong64/0.14.54: - resolution: {integrity: sha512-bZBrLAIX1kpWelV0XemxBZllyRmM6vgFQQG2GdNb+r3Fkp0FOh1NJSvekXDs7jq70k4euu1cryLMfU+mTXlEpw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.14.54.tgz} - name: '@esbuild/linux-loong64' - version: 0.14.54 - engines: {node: '>=12'} - cpu: [loong64] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/@esbuild/linux-loong64/0.15.7: - resolution: {integrity: sha512-IKznSJOsVUuyt7cDzzSZyqBEcZe+7WlBqTVXiF1OXP/4Nm387ToaXZ0fyLwI1iBlI/bzpxVq411QE2/Bt2XWWw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.15.7.tgz} - name: '@esbuild/linux-loong64' - version: 0.15.7 - engines: {node: '>=12'} - cpu: [loong64] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/@next/swc-android-arm-eabi/12.3.0: - resolution: {integrity: sha512-/PuirPnAKsYBw93w/7Q9hqy+KGOU9mjYprZ/faxMUJh/dc6v3rYLxkZKNG9nFPIW4QKNTCnhP40xF9hLnxO+xg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@next/swc-android-arm-eabi/-/swc-android-arm-eabi-12.3.0.tgz} - name: '@next/swc-android-arm-eabi' - version: 12.3.0 - engines: {node: '>= 10'} - cpu: [arm] - os: [android] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/@next/swc-android-arm64/12.3.0: - resolution: {integrity: sha512-OaI+FhAM6P9B6Ybwbn0Zl8YwWido0lLwhDBi9WiYCh4RQmIXAyVIoIJPHo4fP05+mXaJ/k1trvDvuURvHOq2qw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@next/swc-android-arm64/-/swc-android-arm64-12.3.0.tgz} - name: '@next/swc-android-arm64' - version: 12.3.0 - engines: {node: '>= 10'} - cpu: [arm64] - os: [android] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/@next/swc-darwin-arm64/12.3.0: - resolution: {integrity: sha512-9s4d3Mhii+WFce8o8Jok7WC3Bawkr9wEUU++SJRptjU1L5tsfYJMrSYCACHLhZujziNDLyExe4Hwwsccps1sfg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-12.3.0.tgz} - name: '@next/swc-darwin-arm64' - version: 12.3.0 - engines: {node: '>= 10'} - cpu: [arm64] - os: [darwin] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/@next/swc-darwin-x64/12.3.0: - resolution: {integrity: sha512-2scC4MqUTwGwok+wpVxP+zWp7WcCAVOtutki2E1n99rBOTnUOX6qXkgxSy083yBN6GqwuC/dzHeN7hIKjavfRA==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-12.3.0.tgz} - name: '@next/swc-darwin-x64' - version: 12.3.0 - engines: {node: '>= 10'} - cpu: [x64] - os: [darwin] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/@next/swc-freebsd-x64/12.3.0: - resolution: {integrity: sha512-xAlruUREij/bFa+qsE1tmsP28t7vz02N4ZDHt2lh3uJUniE0Ne9idyIDLc1Ed0IF2RjfgOp4ZVunuS3OM0sngw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@next/swc-freebsd-x64/-/swc-freebsd-x64-12.3.0.tgz} - name: '@next/swc-freebsd-x64' - version: 12.3.0 - engines: {node: '>= 10'} - cpu: [x64] - os: [freebsd] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/@next/swc-linux-arm-gnueabihf/12.3.0: - resolution: {integrity: sha512-jin2S4VT/cugc2dSZEUIabhYDJNgrUh7fufbdsaAezgcQzqfdfJqfxl4E9GuafzB4cbRPTaqA0V5uqbp0IyGkQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@next/swc-linux-arm-gnueabihf/-/swc-linux-arm-gnueabihf-12.3.0.tgz} - name: '@next/swc-linux-arm-gnueabihf' - version: 12.3.0 - engines: {node: '>= 10'} - cpu: [arm] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/@next/swc-linux-arm64-gnu/12.3.0: - resolution: {integrity: sha512-RqJHDKe0WImeUrdR0kayTkRWgp4vD/MS7g0r6Xuf8+ellOFH7JAAJffDW3ayuVZeMYOa7RvgNFcOoWnrTUl9Nw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-12.3.0.tgz} - name: '@next/swc-linux-arm64-gnu' - version: 12.3.0 - engines: {node: '>= 10'} - cpu: [arm64] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/@next/swc-linux-arm64-musl/12.3.0: - resolution: {integrity: sha512-nvNWoUieMjvDjpYJ/4SQe9lQs2xMj6ZRs8N+bmTrVu9leY2Fg3WD6W9p/1uU9hGO8u+OdF13wc4iRShu/WYIHg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-12.3.0.tgz} - name: '@next/swc-linux-arm64-musl' - version: 12.3.0 - engines: {node: '>= 10'} - cpu: [arm64] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/@next/swc-linux-x64-gnu/12.3.0: - resolution: {integrity: sha512-4ajhIuVU9PeQCMMhdDgZTLrHmjbOUFuIyg6J19hZqwEwDTSqQyrSLkbJs2Nd7IRiM6Ul/XyrtEFCpk4k+xD2+w==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-12.3.0.tgz} - name: '@next/swc-linux-x64-gnu' - version: 12.3.0 - engines: {node: '>= 10'} - cpu: [x64] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/@next/swc-linux-x64-musl/12.3.0: - resolution: {integrity: sha512-U092RBYbaGxoMAwpauePJEu2PuZSEoUCGJBvsptQr2/2XIMwAJDYM4c/M5NfYEsBr+yjvsYNsOpYfeQ88D82Yg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-12.3.0.tgz} - name: '@next/swc-linux-x64-musl' - version: 12.3.0 - engines: {node: '>= 10'} - cpu: [x64] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/@next/swc-win32-arm64-msvc/12.3.0: - resolution: {integrity: sha512-pzSzaxjDEJe67bUok9Nxf9rykbJfHXW0owICFsPBsqHyc+cr8vpF7g9e2APTCddtVhvjkga9ILoZJ9NxWS7Yiw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-12.3.0.tgz} - name: '@next/swc-win32-arm64-msvc' - version: 12.3.0 - engines: {node: '>= 10'} - cpu: [arm64] - os: [win32] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/@next/swc-win32-ia32-msvc/12.3.0: - resolution: {integrity: sha512-MQGUpMbYhQmTZ06a9e0hPQJnxFMwETo2WtyAotY3GEzbNCQVbCGhsvqEKcl+ZEHgShlHXUWvSffq1ZscY6gK7A==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-12.3.0.tgz} - name: '@next/swc-win32-ia32-msvc' - version: 12.3.0 - engines: {node: '>= 10'} - cpu: [ia32] - os: [win32] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/@next/swc-win32-x64-msvc/12.3.0: - resolution: {integrity: sha512-C/nw6OgQpEULWqs+wgMHXGvlJLguPRFFGqR2TAqWBerQ8J+Sg3z1ZTqwelkSi4FoqStGuZ2UdFHIDN1ySmR1xA==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-12.3.0.tgz} - name: '@next/swc-win32-x64-msvc' - version: 12.3.0 - engines: {node: '>= 10'} - cpu: [x64] - os: [win32] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/@types/node-fetch/2.6.2: - resolution: {integrity: sha512-DHqhlq5jeESLy19TYhLakJ07kNumXWjcDdxXsLUMJZ6ue8VZJj4kLPQVE/2mdHh3xZziNF1xppu5lwmS53HR+A==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@types/node-fetch/-/node-fetch-2.6.2.tgz} - name: '@types/node-fetch' - version: 2.6.2 - dependencies: - '@types/node': registry.npmjs.org/@types/node/18.7.15 - form-data: registry.npmjs.org/form-data/3.0.1 - dev: true - - registry.npmjs.org/@types/node/18.7.15: - resolution: {integrity: sha512-XnjpaI8Bgc3eBag2Aw4t2Uj/49lLBSStHWfqKvIuXD7FIrZyMLWp8KuAFHAqxMZYTF9l08N1ctUn9YNybZJVmQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/@types/node/-/node-18.7.15.tgz} - name: '@types/node' - version: 18.7.15 - dev: true - - registry.npmjs.org/asynckit/0.4.0: - resolution: {integrity: sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz} - name: asynckit - version: 0.4.0 - dev: true - - registry.npmjs.org/combined-stream/1.0.8: - resolution: {integrity: sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz} - name: combined-stream - version: 1.0.8 - engines: {node: '>= 0.8'} - dependencies: - delayed-stream: registry.npmjs.org/delayed-stream/1.0.0 - dev: true - - registry.npmjs.org/delayed-stream/1.0.0: - resolution: {integrity: sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz} - name: delayed-stream - version: 1.0.0 - engines: {node: '>=0.4.0'} - dev: true - - registry.npmjs.org/esbuild-android-64/0.14.54: - resolution: {integrity: sha512-Tz2++Aqqz0rJ7kYBfz+iqyE3QMycD4vk7LBRyWaAVFgFtQ/O8EJOnVmTOiDWYZ/uYzB4kvP+bqejYdVKzE5lAQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-android-64/-/esbuild-android-64-0.14.54.tgz} - name: esbuild-android-64 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [x64] - os: [android] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-android-64/0.15.7: - resolution: {integrity: sha512-p7rCvdsldhxQr3YHxptf1Jcd86dlhvc3EQmQJaZzzuAxefO9PvcI0GLOa5nCWem1AJ8iMRu9w0r5TG8pHmbi9w==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-android-64/-/esbuild-android-64-0.15.7.tgz} - name: esbuild-android-64 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [x64] - os: [android] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-android-arm64/0.14.54: - resolution: {integrity: sha512-F9E+/QDi9sSkLaClO8SOV6etqPd+5DgJje1F9lOWoNncDdOBL2YF59IhsWATSt0TLZbYCf3pNlTHvVV5VfHdvg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-android-arm64/-/esbuild-android-arm64-0.14.54.tgz} - name: esbuild-android-arm64 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [arm64] - os: [android] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-android-arm64/0.15.7: - resolution: {integrity: sha512-L775l9ynJT7rVqRM5vo+9w5g2ysbOCfsdLV4CWanTZ1k/9Jb3IYlQ06VCI1edhcosTYJRECQFJa3eAvkx72eyQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-android-arm64/-/esbuild-android-arm64-0.15.7.tgz} - name: esbuild-android-arm64 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [arm64] - os: [android] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-darwin-64/0.14.54: - resolution: {integrity: sha512-jtdKWV3nBviOd5v4hOpkVmpxsBy90CGzebpbO9beiqUYVMBtSc0AL9zGftFuBon7PNDcdvNCEuQqw2x0wP9yug==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-darwin-64/-/esbuild-darwin-64-0.14.54.tgz} - name: esbuild-darwin-64 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [x64] - os: [darwin] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-darwin-64/0.15.7: - resolution: {integrity: sha512-KGPt3r1c9ww009t2xLB6Vk0YyNOXh7hbjZ3EecHoVDxgtbUlYstMPDaReimKe6eOEfyY4hBEEeTvKwPsiH5WZg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-darwin-64/-/esbuild-darwin-64-0.15.7.tgz} - name: esbuild-darwin-64 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [x64] - os: [darwin] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-darwin-arm64/0.14.54: - resolution: {integrity: sha512-OPafJHD2oUPyvJMrsCvDGkRrVCar5aVyHfWGQzY1dWnzErjrDuSETxwA2HSsyg2jORLY8yBfzc1MIpUkXlctmw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.14.54.tgz} - name: esbuild-darwin-arm64 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [arm64] - os: [darwin] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-darwin-arm64/0.15.7: - resolution: {integrity: sha512-kBIHvtVqbSGajN88lYMnR3aIleH3ABZLLFLxwL2stiuIGAjGlQW741NxVTpUHQXUmPzxi6POqc9npkXa8AcSZQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.15.7.tgz} - name: esbuild-darwin-arm64 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [arm64] - os: [darwin] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-freebsd-64/0.14.54: - resolution: {integrity: sha512-OKwd4gmwHqOTp4mOGZKe/XUlbDJ4Q9TjX0hMPIDBUWWu/kwhBAudJdBoxnjNf9ocIB6GN6CPowYpR/hRCbSYAg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-freebsd-64/-/esbuild-freebsd-64-0.14.54.tgz} - name: esbuild-freebsd-64 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [x64] - os: [freebsd] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-freebsd-64/0.15.7: - resolution: {integrity: sha512-hESZB91qDLV5MEwNxzMxPfbjAhOmtfsr9Wnuci7pY6TtEh4UDuevmGmkUIjX/b+e/k4tcNBMf7SRQ2mdNuK/HQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-freebsd-64/-/esbuild-freebsd-64-0.15.7.tgz} - name: esbuild-freebsd-64 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [x64] - os: [freebsd] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-freebsd-arm64/0.14.54: - resolution: {integrity: sha512-sFwueGr7OvIFiQT6WeG0jRLjkjdqWWSrfbVwZp8iMP+8UHEHRBvlaxL6IuKNDwAozNUmbb8nIMXa7oAOARGs1Q==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.14.54.tgz} - name: esbuild-freebsd-arm64 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [arm64] - os: [freebsd] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-freebsd-arm64/0.15.7: - resolution: {integrity: sha512-dLFR0ChH5t+b3J8w0fVKGvtwSLWCv7GYT2Y2jFGulF1L5HftQLzVGN+6pi1SivuiVSmTh28FwUhi9PwQicXI6Q==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.15.7.tgz} - name: esbuild-freebsd-arm64 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [arm64] - os: [freebsd] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-32/0.14.54: - resolution: {integrity: sha512-1ZuY+JDI//WmklKlBgJnglpUL1owm2OX+8E1syCD6UAxcMM/XoWd76OHSjl/0MR0LisSAXDqgjT3uJqT67O3qw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-32/-/esbuild-linux-32-0.14.54.tgz} - name: esbuild-linux-32 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [ia32] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-32/0.15.7: - resolution: {integrity: sha512-v3gT/LsONGUZcjbt2swrMjwxo32NJzk+7sAgtxhGx1+ZmOFaTRXBAi1PPfgpeo/J//Un2jIKm/I+qqeo4caJvg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-32/-/esbuild-linux-32-0.15.7.tgz} - name: esbuild-linux-32 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [ia32] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-64/0.14.54: - resolution: {integrity: sha512-EgjAgH5HwTbtNsTqQOXWApBaPVdDn7XcK+/PtJwZLT1UmpLoznPd8c5CxqsH2dQK3j05YsB3L17T8vE7cp4cCg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-64/-/esbuild-linux-64-0.14.54.tgz} - name: esbuild-linux-64 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [x64] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-64/0.15.7: - resolution: {integrity: sha512-LxXEfLAKwOVmm1yecpMmWERBshl+Kv5YJ/1KnyAr6HRHFW8cxOEsEfisD3sVl/RvHyW//lhYUVSuy9jGEfIRAQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-64/-/esbuild-linux-64-0.15.7.tgz} - name: esbuild-linux-64 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [x64] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-arm/0.14.54: - resolution: {integrity: sha512-qqz/SjemQhVMTnvcLGoLOdFpCYbz4v4fUo+TfsWG+1aOu70/80RV6bgNpR2JCrppV2moUQkww+6bWxXRL9YMGw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-arm/-/esbuild-linux-arm-0.14.54.tgz} - name: esbuild-linux-arm - version: 0.14.54 - engines: {node: '>=12'} - cpu: [arm] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-arm/0.15.7: - resolution: {integrity: sha512-JKgAHtMR5f75wJTeuNQbyznZZa+pjiUHV7sRZp42UNdyXC6TiUYMW/8z8yIBAr2Fpad8hM1royZKQisqPABPvQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-arm/-/esbuild-linux-arm-0.15.7.tgz} - name: esbuild-linux-arm - version: 0.15.7 - engines: {node: '>=12'} - cpu: [arm] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-arm64/0.14.54: - resolution: {integrity: sha512-WL71L+0Rwv+Gv/HTmxTEmpv0UgmxYa5ftZILVi2QmZBgX3q7+tDeOQNqGtdXSdsL8TQi1vIaVFHUPDe0O0kdig==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-arm64/-/esbuild-linux-arm64-0.14.54.tgz} - name: esbuild-linux-arm64 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [arm64] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-arm64/0.15.7: - resolution: {integrity: sha512-P3cfhudpzWDkglutWgXcT2S7Ft7o2e3YDMrP1n0z2dlbUZghUkKCyaWw0zhp4KxEEzt/E7lmrtRu/pGWnwb9vw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-arm64/-/esbuild-linux-arm64-0.15.7.tgz} - name: esbuild-linux-arm64 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [arm64] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-mips64le/0.14.54: - resolution: {integrity: sha512-qTHGQB8D1etd0u1+sB6p0ikLKRVuCWhYQhAHRPkO+OF3I/iSlTKNNS0Lh2Oc0g0UFGguaFZZiPJdJey3AGpAlw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.14.54.tgz} - name: esbuild-linux-mips64le - version: 0.14.54 - engines: {node: '>=12'} - cpu: [mips64el] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-mips64le/0.15.7: - resolution: {integrity: sha512-T7XKuxl0VpeFLCJXub6U+iybiqh0kM/bWOTb4qcPyDDwNVhLUiPcGdG2/0S7F93czUZOKP57YiLV8YQewgLHKw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.15.7.tgz} - name: esbuild-linux-mips64le - version: 0.15.7 - engines: {node: '>=12'} - cpu: [mips64el] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-ppc64le/0.14.54: - resolution: {integrity: sha512-j3OMlzHiqwZBDPRCDFKcx595XVfOfOnv68Ax3U4UKZ3MTYQB5Yz3X1mn5GnodEVYzhtZgxEBidLWeIs8FDSfrQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.14.54.tgz} - name: esbuild-linux-ppc64le - version: 0.14.54 - engines: {node: '>=12'} - cpu: [ppc64] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-ppc64le/0.15.7: - resolution: {integrity: sha512-6mGuC19WpFN7NYbecMIJjeQgvDb5aMuvyk0PDYBJrqAEMkTwg3Z98kEKuCm6THHRnrgsdr7bp4SruSAxEM4eJw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.15.7.tgz} - name: esbuild-linux-ppc64le - version: 0.15.7 - engines: {node: '>=12'} - cpu: [ppc64] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-riscv64/0.14.54: - resolution: {integrity: sha512-y7Vt7Wl9dkOGZjxQZnDAqqn+XOqFD7IMWiewY5SPlNlzMX39ocPQlOaoxvT4FllA5viyV26/QzHtvTjVNOxHZg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-riscv64/-/esbuild-linux-riscv64-0.14.54.tgz} - name: esbuild-linux-riscv64 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [riscv64] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-riscv64/0.15.7: - resolution: {integrity: sha512-uUJsezbswAYo/X7OU/P+PuL/EI9WzxsEQXDekfwpQ23uGiooxqoLFAPmXPcRAt941vjlY9jtITEEikWMBr+F/g==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-riscv64/-/esbuild-linux-riscv64-0.15.7.tgz} - name: esbuild-linux-riscv64 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [riscv64] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-s390x/0.14.54: - resolution: {integrity: sha512-zaHpW9dziAsi7lRcyV4r8dhfG1qBidQWUXweUjnw+lliChJqQr+6XD71K41oEIC3Mx1KStovEmlzm+MkGZHnHA==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-s390x/-/esbuild-linux-s390x-0.14.54.tgz} - name: esbuild-linux-s390x - version: 0.14.54 - engines: {node: '>=12'} - cpu: [s390x] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-linux-s390x/0.15.7: - resolution: {integrity: sha512-+tO+xOyTNMc34rXlSxK7aCwJgvQyffqEM5MMdNDEeMU3ss0S6wKvbBOQfgd5jRPblfwJ6b+bKiz0g5nABpY0QQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-linux-s390x/-/esbuild-linux-s390x-0.15.7.tgz} - name: esbuild-linux-s390x - version: 0.15.7 - engines: {node: '>=12'} - cpu: [s390x] - os: [linux] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-netbsd-64/0.14.54: - resolution: {integrity: sha512-PR01lmIMnfJTgeU9VJTDY9ZerDWVFIUzAtJuDHwwceppW7cQWjBBqP48NdeRtoP04/AtO9a7w3viI+PIDr6d+w==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-netbsd-64/-/esbuild-netbsd-64-0.14.54.tgz} - name: esbuild-netbsd-64 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [x64] - os: [netbsd] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-netbsd-64/0.15.7: - resolution: {integrity: sha512-yVc4Wz+Pu3cP5hzm5kIygNPrjar/v5WCSoRmIjCPWfBVJkZNb5brEGKUlf+0Y759D48BCWa0WHrWXaNy0DULTQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-netbsd-64/-/esbuild-netbsd-64-0.15.7.tgz} - name: esbuild-netbsd-64 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [x64] - os: [netbsd] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-openbsd-64/0.14.54: - resolution: {integrity: sha512-Qyk7ikT2o7Wu76UsvvDS5q0amJvmRzDyVlL0qf5VLsLchjCa1+IAvd8kTBgUxD7VBUUVgItLkk609ZHUc1oCaw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-openbsd-64/-/esbuild-openbsd-64-0.14.54.tgz} - name: esbuild-openbsd-64 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [x64] - os: [openbsd] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-openbsd-64/0.15.7: - resolution: {integrity: sha512-GsimbwC4FSR4lN3wf8XmTQ+r8/0YSQo21rWDL0XFFhLHKlzEA4SsT1Tl8bPYu00IU6UWSJ+b3fG/8SB69rcuEQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-openbsd-64/-/esbuild-openbsd-64-0.15.7.tgz} - name: esbuild-openbsd-64 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [x64] - os: [openbsd] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-sunos-64/0.14.54: - resolution: {integrity: sha512-28GZ24KmMSeKi5ueWzMcco6EBHStL3B6ubM7M51RmPwXQGLe0teBGJocmWhgwccA1GeFXqxzILIxXpHbl9Q/Kw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-sunos-64/-/esbuild-sunos-64-0.14.54.tgz} - name: esbuild-sunos-64 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [x64] - os: [sunos] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-sunos-64/0.15.7: - resolution: {integrity: sha512-8CDI1aL/ts0mDGbWzjEOGKXnU7p3rDzggHSBtVryQzkSOsjCHRVe0iFYUuhczlxU1R3LN/E7HgUO4NXzGGP/Ag==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-sunos-64/-/esbuild-sunos-64-0.15.7.tgz} - name: esbuild-sunos-64 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [x64] - os: [sunos] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-windows-32/0.14.54: - resolution: {integrity: sha512-T+rdZW19ql9MjS7pixmZYVObd9G7kcaZo+sETqNH4RCkuuYSuv9AGHUVnPoP9hhuE1WM1ZimHz1CIBHBboLU7w==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-windows-32/-/esbuild-windows-32-0.14.54.tgz} - name: esbuild-windows-32 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [ia32] - os: [win32] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-windows-32/0.15.7: - resolution: {integrity: sha512-cOnKXUEPS8EGCzRSFa1x6NQjGhGsFlVgjhqGEbLTPsA7x4RRYiy2RKoArNUU4iR2vHmzqS5Gr84MEumO/wxYKA==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-windows-32/-/esbuild-windows-32-0.15.7.tgz} - name: esbuild-windows-32 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [ia32] - os: [win32] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-windows-64/0.14.54: - resolution: {integrity: sha512-AoHTRBUuYwXtZhjXZbA1pGfTo8cJo3vZIcWGLiUcTNgHpJJMC1rVA44ZereBHMJtotyN71S8Qw0npiCIkW96cQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-windows-64/-/esbuild-windows-64-0.14.54.tgz} - name: esbuild-windows-64 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [x64] - os: [win32] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-windows-64/0.15.7: - resolution: {integrity: sha512-7MI08Ec2sTIDv+zH6StNBKO+2hGUYIT42GmFyW6MBBWWtJhTcQLinKS6ldIN1d52MXIbiJ6nXyCJ+LpL4jBm3Q==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-windows-64/-/esbuild-windows-64-0.15.7.tgz} - name: esbuild-windows-64 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [x64] - os: [win32] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-windows-arm64/0.14.54: - resolution: {integrity: sha512-M0kuUvXhot1zOISQGXwWn6YtS+Y/1RT9WrVIOywZnJHo3jCDyewAc79aKNQWFCQm+xNHVTq9h8dZKvygoXQQRg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-windows-arm64/-/esbuild-windows-arm64-0.14.54.tgz} - name: esbuild-windows-arm64 - version: 0.14.54 - engines: {node: '>=12'} - cpu: [arm64] - os: [win32] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/esbuild-windows-arm64/0.15.7: - resolution: {integrity: sha512-R06nmqBlWjKHddhRJYlqDd3Fabx9LFdKcjoOy08YLimwmsswlFBJV4rXzZCxz/b7ZJXvrZgj8DDv1ewE9+StMw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/esbuild-windows-arm64/-/esbuild-windows-arm64-0.15.7.tgz} - name: esbuild-windows-arm64 - version: 0.15.7 - engines: {node: '>=12'} - cpu: [arm64] - os: [win32] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/form-data/3.0.1: - resolution: {integrity: sha512-RHkBKtLWUVwd7SqRIvCZMEvAMoGUp0XU+seQiZejj0COz3RI3hWP4sCv3gZWWLjJTd7rGwcsF5eKZGii0r/hbg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/form-data/-/form-data-3.0.1.tgz} - name: form-data - version: 3.0.1 - engines: {node: '>= 6'} - dependencies: - asynckit: registry.npmjs.org/asynckit/0.4.0 - combined-stream: registry.npmjs.org/combined-stream/1.0.8 - mime-types: registry.npmjs.org/mime-types/2.1.35 - dev: true - - registry.npmjs.org/fsevents/2.3.2: - resolution: {integrity: sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz} - name: fsevents - version: 2.3.2 - engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} - os: [darwin] - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/graceful-fs/4.2.10: - resolution: {integrity: sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz} - name: graceful-fs - version: 4.2.10 - dev: true - optional: true - - registry.npmjs.org/mime-db/1.52.0: - resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz} - name: mime-db - version: 1.52.0 - engines: {node: '>= 0.6'} - dev: true - - registry.npmjs.org/mime-types/2.1.35: - resolution: {integrity: sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz} - name: mime-types - version: 2.1.35 - engines: {node: '>= 0.6'} - dependencies: - mime-db: registry.npmjs.org/mime-db/1.52.0 - dev: true - - registry.npmjs.org/node-fetch/2.6.7: - resolution: {integrity: sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.7.tgz} - name: node-fetch - version: 2.6.7 - engines: {node: 4.x || >=6.0.0} - peerDependencies: - encoding: ^0.1.0 - peerDependenciesMeta: - encoding: - optional: true - dependencies: - whatwg-url: registry.npmjs.org/whatwg-url/5.0.0 - - registry.npmjs.org/node-fetch/3.2.10: - resolution: {integrity: sha512-MhuzNwdURnZ1Cp4XTazr69K0BTizsBroX7Zx3UgDSVcZYKF/6p0CBe4EUb/hLqmzVhl0UpYfgRljQ4yxE+iCxA==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/node-fetch/-/node-fetch-3.2.10.tgz} - name: node-fetch - version: 3.2.10 - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - dependencies: - data-uri-to-buffer: 4.0.0 - fetch-blob: 3.2.0 - formdata-polyfill: 4.0.10 - dev: true - - registry.npmjs.org/source-map/0.6.1: - resolution: {integrity: sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz} - name: source-map - version: 0.6.1 - engines: {node: '>=0.10.0'} - requiresBuild: true - dev: true - optional: true - - registry.npmjs.org/tr46/0.0.3: - resolution: {integrity: sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz} - name: tr46 - version: 0.0.3 - - registry.npmjs.org/tr46/1.0.1: - resolution: {integrity: sha512-dTpowEjclQ7Kgx5SdBkqRzVhERQXov8/l9Ft9dVM9fmg0W0KQSVaXX9T4i6twCPNtYiZM53lpSSUAwJbFPOHxA==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/tr46/-/tr46-1.0.1.tgz} - name: tr46 - version: 1.0.1 - dependencies: - punycode: 2.1.1 - dev: true - - registry.npmjs.org/webidl-conversions/3.0.1: - resolution: {integrity: sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz} - name: webidl-conversions - version: 3.0.1 - - registry.npmjs.org/webidl-conversions/4.0.2: - resolution: {integrity: sha512-YQ+BmxuTgd6UXZW3+ICGfyqRyHXVlD5GtQr5+qjiNW7bF0cqrzX500HVXPBOvgXb5YnzDd+h0zqyv61KUD7+Sg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-4.0.2.tgz} - name: webidl-conversions - version: 4.0.2 - dev: true - - registry.npmjs.org/whatwg-url/11.0.0: - resolution: {integrity: sha512-RKT8HExMpoYx4igMiVMY83lN6UeITKJlBQ+vR/8ZJ8OCdSiN3RwCq+9gH0+Xzj0+5IrM6i4j/6LuvzbZIQgEcQ==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/whatwg-url/-/whatwg-url-11.0.0.tgz} - name: whatwg-url - version: 11.0.0 - engines: {node: '>=12'} - dependencies: - tr46: 3.0.0 - webidl-conversions: 7.0.0 - dev: true - - registry.npmjs.org/whatwg-url/5.0.0: - resolution: {integrity: sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz} - name: whatwg-url - version: 5.0.0 - dependencies: - tr46: registry.npmjs.org/tr46/0.0.3 - webidl-conversions: registry.npmjs.org/webidl-conversions/3.0.1 - - registry.npmjs.org/whatwg-url/7.1.0: - resolution: {integrity: sha512-WUu7Rg1DroM7oQvGWfOiAK21n74Gg+T4elXEQYkOhtyLeWiJFoOGLXPKI/9gzIie9CtwVLm8wtw6YJdKyxSjeg==, registry: https://registry.npmjs.com/, tarball: https://registry.npmjs.org/whatwg-url/-/whatwg-url-7.1.0.tgz} - name: whatwg-url - version: 7.1.0 - dependencies: - lodash.sortby: 4.7.0 - tr46: registry.npmjs.org/tr46/1.0.1 - webidl-conversions: registry.npmjs.org/webidl-conversions/4.0.2 - dev: true - publishDirectory: dist diff --git a/src/gql-ast-to-string.ts b/src/gql-ast-to-string.ts new file mode 100644 index 0000000..efac56e --- /dev/null +++ b/src/gql-ast-to-string.ts @@ -0,0 +1,7 @@ +import { ASTNode, print } from "graphql"; + +export const gqlAstToString = (ast: ASTNode) => + print(ast) // convert AST to string + .replaceAll(/\n*/g, "") // remove new lines + .replaceAll(/\s{2,}/g, " ") // remove unnecessary multiple spaces + .trim(); // remove whitespace from beginning and end diff --git a/src/handlers/next/index.ts b/src/handlers/next/index.ts index 9edd583..ba57aa6 100644 --- a/src/handlers/next/index.ts +++ b/src/handlers/next/index.ts @@ -1,2 +1,3 @@ export * from "./create-app-register-handler"; export * from "./create-manifest-handler"; +export * from "./saleor-async-webhook"; diff --git a/src/handlers/next/process-async-saleor-webhook.test.ts b/src/handlers/next/process-async-saleor-webhook.test.ts new file mode 100644 index 0000000..30e9628 --- /dev/null +++ b/src/handlers/next/process-async-saleor-webhook.test.ts @@ -0,0 +1,147 @@ +import { NextApiRequest } from "next/types"; +import { createMocks } from "node-mocks-http"; +import rawBody from "raw-body"; +import { beforeEach, describe, expect, it, vi } from "vitest"; + +import { APL } from "../../APL"; +import { processAsyncSaleorWebhook } from "./process-async-saleor-webhook"; + +vi.mock("./../../verify-signature", () => ({ + // eslint-disable-next-line @typescript-eslint/no-unused-vars + verifySignature: vi.fn((domain, signature) => { + if (signature !== "mocked_signature") { + throw new Error("Wrong signature"); + } + }), +})); + +vi.mock("raw-body", () => ({ + default: vi.fn().mockResolvedValue("{}"), +})); +describe("processAsyncSaleorWebhook", () => { + let mockRequest: NextApiRequest; + + const mockAPL: APL = { + get: async (domain: string) => + domain === "example.com" + ? { + domain: "example.com", + token: "mock-token", + } + : undefined, + set: vi.fn(), + delete: vi.fn(), + getAll: vi.fn(), + isReady: vi.fn(), + isConfigured: vi.fn(), + }; + + beforeEach(() => { + // Create request method which passes all the tests + const { req } = createMocks({ + headers: { + host: "some-saleor-host.cloud", + "x-forwarded-proto": "https", + "saleor-domain": "example.com", + "saleor-event": "product_updated", + "saleor-signature": "mocked_signature", + "content-length": "0", // is ignored by mocked raw-body + }, + method: "POST", + // body can be skipped because we mock it with raw-body + }); + mockRequest = req; + }); + + it("Process valid request", async () => { + await processAsyncSaleorWebhook({ + req: mockRequest, + apl: mockAPL, + allowedEvent: "PRODUCT_UPDATED", + }); + }); + + it("Throw error on non-POST request method", async () => { + mockRequest.method = "GET"; + + await expect( + processAsyncSaleorWebhook({ req: mockRequest, apl: mockAPL, allowedEvent: "PRODUCT_UPDATED" }) + ).rejects.toThrow("Wrong request method"); + }); + + it("Throw error on missing domain header", async () => { + delete mockRequest.headers["saleor-domain"]; + + await expect( + processAsyncSaleorWebhook({ req: mockRequest, apl: mockAPL, allowedEvent: "PRODUCT_UPDATED" }) + ).rejects.toThrow("Missing saleor-domain header"); + }); + + it("Throw error on missing event header", async () => { + delete mockRequest.headers["saleor-event"]; + + await expect( + processAsyncSaleorWebhook({ + req: mockRequest, + apl: mockAPL, + allowedEvent: "PRODUCT_UPDATED", + }) + ).rejects.toThrow("Missing saleor-event header"); + }); + + it("Throw error on mismatched event header", async () => { + mockRequest.headers["saleor-event"] = "different_event"; + await expect( + processAsyncSaleorWebhook({ req: mockRequest, apl: mockAPL, allowedEvent: "PRODUCT_UPDATED" }) + ).rejects.toThrow("Wrong incoming request event: different_event. Expected: product_updated"); + }); + + it("Throw error on missing signature header", async () => { + delete mockRequest.headers["saleor-signature"]; + await expect( + processAsyncSaleorWebhook({ + req: mockRequest, + apl: mockAPL, + allowedEvent: "PRODUCT_UPDATED", + }) + ).rejects.toThrow("Missing saleor-signature header"); + }); + + it("Throw error on missing request body", async () => { + vi.mocked(rawBody).mockImplementationOnce(async () => { + throw new Error("Missing request body"); + }); + + await expect( + processAsyncSaleorWebhook({ + req: mockRequest, + apl: mockAPL, + allowedEvent: "PRODUCT_UPDATED", + }) + ).rejects.toThrow("Missing request body"); + }); + + it("Throw error on not registered app", async () => { + mockRequest.headers["saleor-domain"] = "not-registered.example.com"; + await expect( + processAsyncSaleorWebhook({ + req: mockRequest, + apl: mockAPL, + allowedEvent: "PRODUCT_UPDATED", + }) + ).rejects.toThrow( + "Can't find auth data for domain not-registered.example.com. Please register the application" + ); + }); + + it("Throw error on wrong signature", async () => { + mockRequest.headers["saleor-signature"] = "wrong_signature"; + await expect( + processAsyncSaleorWebhook({ + req: mockRequest, + apl: mockAPL, + allowedEvent: "PRODUCT_UPDATED", + }) + ).rejects.toThrow("Request signature check failed"); + }); +}); diff --git a/src/handlers/next/process-async-saleor-webhook.ts b/src/handlers/next/process-async-saleor-webhook.ts new file mode 100644 index 0000000..6d90232 --- /dev/null +++ b/src/handlers/next/process-async-saleor-webhook.ts @@ -0,0 +1,148 @@ +import { NextApiRequest } from "next"; +import getRawBody from "raw-body"; + +import { APL } from "../../APL"; +import { AuthData } from "../../APL/apl"; +import { createDebug } from "../../debug"; +import { getBaseUrl, getSaleorHeaders } from "../../headers"; +import { verifySignature } from "../../verify-signature"; + +const debug = createDebug("processAsyncWebhook"); + +export type SaleorWebhookError = + | "OTHER" + | "MISSING_HOST_HEADER" + | "MISSING_DOMAIN_HEADER" + | "MISSING_EVENT_HEADER" + | "MISSING_PAYLOAD_HEADER" + | "MISSING_SIGNATURE_HEADER" + | "MISSING_REQUEST_BODY" + | "WRONG_EVENT" + | "NOT_REGISTERED" + | "SIGNATURE_VERIFICATION_FAILED" + | "WRONG_METHOD" + | "CANT_BE_PARSED"; + +export class WebhookError extends Error { + errorType: SaleorWebhookError = "OTHER"; + + constructor(message: string, errorType: SaleorWebhookError) { + super(message); + if (errorType) { + this.errorType = errorType; + } + Object.setPrototypeOf(this, WebhookError.prototype); + } +} + +export type WebhookContext = { + baseUrl: string; + event: string; + payload: T; + authData: AuthData; +}; + +interface ProcessSaleorWebhookArgs { + req: NextApiRequest; + apl: APL; + allowedEvent: string; +} + +type ProcessAsyncSaleorWebhook = ( + props: ProcessSaleorWebhookArgs +) => Promise>; + +/** + * Perform security checks on given request and return WebhookContext object. + * In case of validation issues, instance of the WebhookError will be thrown. + * + * @returns WebhookContext + */ +export const processAsyncSaleorWebhook: ProcessAsyncSaleorWebhook = async ({ + req, + apl, + allowedEvent, +}: ProcessSaleorWebhookArgs): Promise> => { + debug("Request processing started"); + if (req.method !== "POST") { + debug("Wrong HTTP method"); + throw new WebhookError("Wrong request method, only POST allowed", "WRONG_METHOD"); + } + const { event, domain, signature } = getSaleorHeaders(req.headers); + const baseUrl = getBaseUrl(req.headers); + + if (!baseUrl) { + debug("Missing host header"); + throw new WebhookError("Missing host header", "MISSING_HOST_HEADER"); + } + + if (!domain) { + debug("Missing saleor-domain header"); + throw new WebhookError("Missing saleor-domain header", "MISSING_DOMAIN_HEADER"); + } + + if (!event) { + debug("Missing saleor-event header"); + throw new WebhookError("Missing saleor-event header", "MISSING_EVENT_HEADER"); + } + + const expected = allowedEvent.toLowerCase(); + if (event !== expected) { + debug(`Wrong incoming request event: ${event}. Expected: ${expected}`); + throw new WebhookError( + `Wrong incoming request event: ${event}. Expected: ${expected}`, + "WRONG_EVENT" + ); + } + + if (!signature) { + debug("No signature"); + throw new WebhookError("Missing saleor-signature header", "MISSING_SIGNATURE_HEADER"); + } + + const rawBody = ( + await getRawBody(req, { + length: req.headers["content-length"], + limit: "1mb", + }) + ).toString(); + if (!rawBody) { + debug("Missing request body"); + throw new WebhookError("Missing request body", "MISSING_REQUEST_BODY"); + } + + let parsedBody: unknown; + try { + parsedBody = JSON.parse(rawBody); + } catch { + debug("Request body cannot be parsed"); + throw new WebhookError("Request body cant be parsed", "CANT_BE_PARSED"); + } + + // Check if domain is installed in the app + const authData = await apl.get(domain); + + if (!authData) { + debug("APL didn't found auth data for domain %s", domain); + throw new WebhookError( + `Can't find auth data for domain ${domain}. Please register the application`, + "NOT_REGISTERED" + ); + } + + // Payload signature check + // TODO: Since it require additional request, can we cache it's response? + try { + await verifySignature(domain, signature, rawBody); + } catch { + debug("Request signature check failed"); + throw new WebhookError("Request signature check failed", "SIGNATURE_VERIFICATION_FAILED"); + } + + return { + baseUrl, + event, + payload: parsedBody as T, + authData, + }; +}; diff --git a/src/handlers/next/saleor-async-webhook.test.ts b/src/handlers/next/saleor-async-webhook.test.ts new file mode 100644 index 0000000..0e4f315 --- /dev/null +++ b/src/handlers/next/saleor-async-webhook.test.ts @@ -0,0 +1,75 @@ +import { createMocks } from "node-mocks-http"; +import { describe, expect, it, vi } from "vitest"; + +import { APL } from "../../APL"; +import { NextWebhookApiHandler, SaleorAsyncWebhook } from "./saleor-async-webhook"; + +const webhookPath = "api/webhooks/product-updated"; +const baseUrl = "http://example.com"; + +describe("SaleorAsyncWebhook", () => { + const mockAPL: APL = { + get: async (domain: string) => + domain === "example.com" + ? { + domain: "example.com", + token: "mock-token", + } + : undefined, + set: vi.fn(), + delete: vi.fn(), + getAll: vi.fn(), + isReady: vi.fn(), + isConfigured: vi.fn(), + }; + + const saleorAsyncWebhook = new SaleorAsyncWebhook({ + apl: mockAPL, + asyncEvent: "PRODUCT_UPDATED", + webhookPath, + }); + + it("targetUrl should return full path to the webhook route based on given baseUrl", async () => { + expect(saleorAsyncWebhook.getTargetUrl(baseUrl)).toBe(`${baseUrl}/${webhookPath}`); + }); + + it("getWebhookManifest should return a valid manifest", async () => { + expect(saleorAsyncWebhook.getWebhookManifest(baseUrl)).toStrictEqual({ + asyncEvents: ["PRODUCT_UPDATED"], + isActive: true, + name: "PRODUCT_UPDATED webhook", + targetUrl: "http://example.com/api/webhooks/product-updated", + }); + }); + + it("Test createHandler which return success", async () => { + // prepare mocked context returned by mocked process function + vi.mock("./process-async-saleor-webhook", () => ({ + processAsyncSaleorWebhook: vi.fn().mockResolvedValue({ + baseUrl: "example.com", + event: "product_updated", + payload: { data: "test_payload" }, + authData: { domain: "example.com", token: "token" }, + }), + })); + + // Test handler - will throw error if mocked context is not passed to it + // eslint-disable-next-line @typescript-eslint/no-unused-vars + const testHandler: NextWebhookApiHandler = vi.fn().mockImplementation((req, res, context) => { + if (context.payload.data === "test_payload") { + res.status(200).end(); + return; + } + throw new Error("Test payload has not been passed to handler function"); + }); + + // We are mocking validation method, so empty mock requests will pass + const { req, res } = createMocks(); + const wrappedHandler = saleorAsyncWebhook.createHandler(testHandler); + await wrappedHandler(req, res); + expect(res.statusCode).toBe(200); + + // Check if test handler was used by the wrapper + expect(testHandler).toBeCalledTimes(1); + }); +}); diff --git a/src/handlers/next/saleor-async-webhook.ts b/src/handlers/next/saleor-async-webhook.ts new file mode 100644 index 0000000..a0994a3 --- /dev/null +++ b/src/handlers/next/saleor-async-webhook.ts @@ -0,0 +1,140 @@ +import { ASTNode } from "graphql"; +import { NextApiHandler, NextApiRequest, NextApiResponse } from "next"; + +import { WebhookManifest } from "../.."; +import { APL } from "../../APL"; +import { createDebug } from "../../debug"; +import { gqlAstToString } from "../../gql-ast-to-string"; +import { WebhookEvent } from "../../types"; +import { + processAsyncSaleorWebhook, + SaleorWebhookError, + WebhookContext, + WebhookError, +} from "./process-async-saleor-webhook"; + +const debug = createDebug("SaleorAsyncWebhook"); + +export interface WebhookManifestConfiguration { + name?: string; + webhookPath: string; + subscriptionQueryAst?: ASTNode; + query?: string; + asyncEvent: WebhookEvent; + isActive?: boolean; + apl: APL; +} + +export const ErrorCodeMap: Record = { + OTHER: 500, + MISSING_HOST_HEADER: 400, + MISSING_DOMAIN_HEADER: 400, + MISSING_EVENT_HEADER: 400, + MISSING_PAYLOAD_HEADER: 400, + MISSING_SIGNATURE_HEADER: 400, + MISSING_REQUEST_BODY: 400, + WRONG_EVENT: 400, + NOT_REGISTERED: 401, + SIGNATURE_VERIFICATION_FAILED: 401, + WRONG_METHOD: 405, + CANT_BE_PARSED: 400, +}; + +export type NextWebhookApiHandler = ( + req: NextApiRequest, + res: NextApiResponse, + ctx: WebhookContext +) => unknown | Promise; + +export class SaleorAsyncWebhook { + name: string; + + webhookPath: string; + + subscriptionQueryAst?: ASTNode; + + query?: string; + + asyncEvent: WebhookEvent; + + isActive?: boolean; + + apl: APL; + + constructor({ + name, + webhookPath, + subscriptionQueryAst, + query, + asyncEvent, + apl, + isActive = true, + }: WebhookManifestConfiguration) { + this.name = name || `${asyncEvent} webhook`; + this.subscriptionQueryAst = subscriptionQueryAst; + this.query = query; + this.webhookPath = webhookPath; + this.asyncEvent = asyncEvent; + this.isActive = isActive; + this.apl = apl; + } + + /** + * Returns full URL to the webhook, based on provided baseUrl. + * + * @param baseUrl Base URL used by your application + */ + getTargetUrl(baseUrl: string) { + return new URL(this.webhookPath, baseUrl).href; + } + + /** + * Returns synchronous event manifest for this webhook. + * + * @param baseUrl Base URL used by your application + * @returns WebhookManifest + */ + getWebhookManifest(baseUrl: string): WebhookManifest { + return { + name: this.name, + targetUrl: this.getTargetUrl(baseUrl), + asyncEvents: [this.asyncEvent], + isActive: this.isActive, + // Query can be provided as plaintext.. + ...(this.query && { query: this.query }), + // ...GQL AST which has to be stringified.. + ...(this.subscriptionQueryAst && { query: gqlAstToString(this.subscriptionQueryAst) }), + // or no query at all. In such case default webhook payload will be sent + }; + } + + /** + * Wraps provided function, to ensure incoming request comes from registered Saleor instance. + * Also provides additional `context` object containing typed payload and request properties. + * + * @param handlerFn NextApiHandler function which takes additional `context` argument + * @returns NextApiHandler + */ + createHandler(handlerFn: NextWebhookApiHandler): NextApiHandler { + return async (req, res) => { + await processAsyncSaleorWebhook({ + req, + apl: this.apl, + allowedEvent: this.asyncEvent, + }) + .then(async (context) => { + debug("Call handlerFn"); + return handlerFn(req, res, context); + }) + .catch((e) => { + if (e instanceof WebhookError) { + debug(e.message); + res.status(ErrorCodeMap[e.errorType] || 400).end(); + return; + } + debug("Unexpected error during processing the webhook %O", e); + res.status(500).end(); + }); + }; + } +} diff --git a/src/headers.ts b/src/headers.ts index 068f9cc..a321690 100644 --- a/src/headers.ts +++ b/src/headers.ts @@ -16,3 +16,8 @@ export const getSaleorHeaders = (headers: { signature: toStringOrUndefined(headers[SALEOR_SIGNATURE_HEADER]), event: toStringOrUndefined(headers[SALEOR_EVENT_HEADER]), }); + +export const getBaseUrl = (headers: { [name: string]: string | string[] | undefined }): string => { + const { host, "x-forwarded-proto": protocol = "http" } = headers; + return `${protocol}://${host}`; +}; diff --git a/src/index.ts b/src/index.ts index c396b5a..592d1d0 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,6 +1,9 @@ +import { AppWebhook as WebhookManifest } from "./types"; + export * from "./const"; export * from "./headers"; export * from "./infer-webhooks"; export * from "./saleor-app"; export * from "./types"; export * from "./urls"; +export { WebhookManifest }; diff --git a/src/middleware/with-base-url.ts b/src/middleware/with-base-url.ts index d4d804f..93f93d7 100644 --- a/src/middleware/with-base-url.ts +++ b/src/middleware/with-base-url.ts @@ -1,5 +1,6 @@ import { Middleware } from "retes"; +import { getBaseUrl } from "../headers"; import { createMiddlewareDebug } from "./middleware-debug"; const debug = createMiddlewareDebug("withBaseURL"); @@ -7,10 +8,10 @@ const debug = createMiddlewareDebug("withBaseURL"); export const withBaseURL: Middleware = (handler) => async (request) => { const { host, "x-forwarded-proto": protocol = "http" } = request.headers; - debug("Middleware called with host: %s, protocol %s", host, request.headers["x-forwarded-proto"]); + debug("Middleware called with host: %s, protocol %s", host, protocol); request.context ??= {}; - request.context.baseURL = `${protocol}://${host}`; + request.context.baseURL = getBaseUrl(request.headers); debug("context.baseURL resolved to be: \"%s\"", request.context.baseURL); diff --git a/src/middleware/with-webhook-signature-verified.ts b/src/middleware/with-webhook-signature-verified.ts index 1fb4a56..4be9197 100644 --- a/src/middleware/with-webhook-signature-verified.ts +++ b/src/middleware/with-webhook-signature-verified.ts @@ -1,11 +1,10 @@ import crypto from "crypto"; -import * as jose from "jose"; import { Middleware } from "retes"; import { Response } from "retes/response"; import { SALEOR_DOMAIN_HEADER, SALEOR_SIGNATURE_HEADER } from "../const"; import { getSaleorHeaders } from "../headers"; -import { getJwksUrl } from "../urls"; +import { verifySignature } from "../verify-signature"; import { createMiddlewareDebug } from "./middleware-debug"; const debug = createMiddlewareDebug("withWebhookSignatureVerified"); @@ -62,26 +61,11 @@ export const withWebhookSignatureVerified = }); } } else { - const [header, , signature] = payloadSignature.split("."); - const jws = { - protected: header, - payload: request.rawBody, - signature, - }; - - const remoteJwks = jose.createRemoteJWKSet( - new URL(getJwksUrl(saleorDomain)) - ) as jose.FlattenedVerifyGetKey; - - debug("Created remote JWKS"); - try { - await jose.flattenedVerify(jws, remoteJwks); - + await verifySignature(saleorDomain, payloadSignature, request.rawBody); debug("JWKS verified"); } catch { debug("JWKS verification failed"); - return Response.BadRequest({ success: false, message: `${ERROR_MESSAGE} Verification using public key has failed.`, diff --git a/src/types.ts b/src/types.ts index 1e7c789..89197be 100644 --- a/src/types.ts +++ b/src/types.ts @@ -59,7 +59,9 @@ export interface AppWebhook { name: string; asyncEvents?: WebhookEvent[]; syncEvents?: WebhookEvent[]; - query: string; + /** If query is not provided, the default webhook payload will be used */ + query?: string; + /** The full URL of the endpoint where request will be sent */ targetUrl: string; isActive?: boolean; } diff --git a/src/verify-signature.ts b/src/verify-signature.ts new file mode 100644 index 0000000..5f8b0b5 --- /dev/null +++ b/src/verify-signature.ts @@ -0,0 +1,33 @@ +import * as jose from "jose"; + +import { createDebug } from "./debug"; +import { getJwksUrl } from "./urls"; + +const debug = createDebug("verify-signature"); + +/** + * Verify payload signature with public key of given `domain` + * https://docs.saleor.io/docs/3.x/developer/extending/apps/asynchronous-webhooks#payload-signature + */ +export const verifySignature = async (domain: string, signature: string, rawBody: string) => { + const [header, , jwsSignature] = signature.split("."); + const jws: jose.FlattenedJWSInput = { + protected: header, + payload: rawBody, + signature: jwsSignature, + }; + + const remoteJwks = jose.createRemoteJWKSet( + new URL(getJwksUrl(domain)) + ) as jose.FlattenedVerifyGetKey; + + debug("Created remote JWKS"); + + try { + await jose.flattenedVerify(jws, remoteJwks); + debug("JWKS verified"); + } catch { + debug("JWKS verification failed"); + throw new Error("JWKS verification failed"); + } +};