From 0eee9a84480629fa1779c89bbeef5d482f6ca376 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Przemys=C5=82aw=20Ro=C5=BCnawski?= Date: Thu, 23 May 2024 10:06:11 +0200 Subject: [PATCH 01/23] Mute tracks --- e2e/app/src/App.tsx | 3 + e2e/app/src/ReplaceTrackWithDummyStream.tsx | 230 ++++++++++++++++++++ src/webrtc/webRTCEndpoint.ts | 35 ++- 3 files changed, 266 insertions(+), 2 deletions(-) create mode 100644 e2e/app/src/ReplaceTrackWithDummyStream.tsx diff --git a/e2e/app/src/App.tsx b/e2e/app/src/App.tsx index 7136c65d..8cdebeaa 100644 --- a/e2e/app/src/App.tsx +++ b/e2e/app/src/App.tsx @@ -13,6 +13,8 @@ import { PeerMessage } from "./protos/fishjam/peer_notifications"; import { useEffect, useState, useSyncExternalStore } from "react"; import { MockComponent } from "./MockComponent.tsx"; import { VideoPlayerWithDetector } from "./VideoPlayerWithDetector.tsx"; +import { ReplaceTrackWithDummyStream } from "./ReplaceTrackWithDummyStream.tsx"; + /* eslint-disable no-console */ @@ -232,6 +234,7 @@ export function App() {
{connected ? "true" : "false"}

+
{Object.values(remoteTracks).map( ({ stream, trackId, endpoint, metadata, rawMetadata, metadataParsingError }) => ( diff --git a/e2e/app/src/ReplaceTrackWithDummyStream.tsx b/e2e/app/src/ReplaceTrackWithDummyStream.tsx new file mode 100644 index 00000000..4af4be83 --- /dev/null +++ b/e2e/app/src/ReplaceTrackWithDummyStream.tsx @@ -0,0 +1,230 @@ +import { VideoPlayer } from "./VideoPlayer.tsx"; +import { useRef, useState } from "react"; +import { WebRTCEndpoint } from "@fishjam-dev/ts-client"; + +/* + * Looks like Jellyfish handles track without simulcast properly + * + * Case oszczędzania bandwithu + * - użytkownik ma słaby upload, wyłącza kamerę żeby mieć więcej seici na mikrofon + * - poprzednio zaobserwowaliśmy, że jest dużo padding pakietów albo czarnych ramek + * https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpSender/setParameters + * - jak tworzymy tracka to z sendera można pobrać tracki i ich settingsy i potem + * na parametrach konkretne encodingi ustawić, trzeba sprawdzić, czy da sie zrobić takie encodingsy + * dla canvasa jak są dla kamerki czyli 3 warstwy encodingóws + */ + +export const VIDEO_TRACK_CONSTRAINTS: MediaTrackConstraints = { + width: { + max: 1280, + ideal: 1280, + min: 640, + }, + height: { + max: 720, + ideal: 720, + min: 320, + }, + frameRate: { + max: 30, + ideal: 24, + }, +}; + +type Props = { + webrtc: WebRTCEndpoint; +}; + +const createDummyStream = ( + width: number = 1280, + height: number = 720, +): { + stream: MediaStream; + track: MediaStreamTrack; +} => { + const canvas = document.createElement("canvas"); + canvas.height = height; + canvas.width = width; + const context = canvas.getContext("2d"); + + if (!context) throw Error("Canvas context is null"); + + context.fillRect(0, 0, width, height); + + const stream = canvas.captureStream(); + + const track = stream.getVideoTracks()[0]; + + if (!track) throw Error("Canvas track is null"); + + track.enabled = false; + + return { stream, track }; +}; + +export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { + const [videoStream, setVideoStream] = useState(null); + const videoStreamIdRef = useRef(null); + const [simulcastCheckbox, setSimulcastCheckbox] = useState(true); + + const startAndAddCamera = async () => { + const mediaStream = await navigator.mediaDevices.getUserMedia({ video: VIDEO_TRACK_CONSTRAINTS, audio: false }); + console.log({ + mediaStream, + settings: mediaStream.getVideoTracks()[0].getSettings(), + tracks: videoStream?.getVideoTracks(), + }); + + setVideoStream(mediaStream); + + const track = mediaStream.getVideoTracks()[0]; + + if(videoStreamIdRef.current) { + console.log("Replacing with camera"); + + webrtc.replaceTrack(videoStreamIdRef.current, track, undefined, "unmute"); + } else { + console.log("Adding track") + + videoStreamIdRef.current = await webrtc.addTrack( + track, + mediaStream, + { goodTrack: "camera" }, + simulcastCheckbox + ? { + enabled: true, + activeEncodings: ["l", "m", "h"], + disabledEncodings: [], + } + : undefined, + ); + } + }; + + const stopCameraAndReplaceWithNull = () => { + videoStream?.getTracks().forEach((track) => { + track.stop(); + }); + + console.log("replacing with null", videoStreamIdRef.current); + + if(videoStreamIdRef.current) { + webrtc.replaceTrack(videoStreamIdRef.current, null, {goodTrack: "null"}, "mute") + } + }; + + const startCamera = async () => { + const mediaStream = await navigator.mediaDevices.getUserMedia({ video: VIDEO_TRACK_CONSTRAINTS, audio: false }); + console.log({ + mediaStream, + settings: mediaStream.getVideoTracks()[0].getSettings(), + tracks: videoStream?.getVideoTracks(), + }); + setVideoStream(mediaStream); + }; + + const stopCamera = () => { + videoStream?.getTracks().forEach((track) => { + track.stop(); + }); + }; + + const addCameraTrack = async () => { + if (!videoStream) throw Error("Video stream is null"); + const track = videoStream.getVideoTracks()[0]; + + videoStreamIdRef.current = await webrtc.addTrack( + track, + videoStream, + { source: "camera" }, + simulcastCheckbox + ? { + enabled: true, + activeEncodings: ["l", "m", "h"], + disabledEncodings: [], + } + : undefined, + ); + }; + + const toggleEnableCamera = () => { + if (!videoStream) throw Error("Video stream is null"); + const track = videoStream.getVideoTracks()[0]; + const prevState = track.enabled; + + videoStream.getVideoTracks().forEach((track) => { + track.enabled = !prevState; + }); + }; + + const removeCameraTrack = () => { + if (!videoStreamIdRef.current) throw Error("Track id is null"); + + webrtc.removeTrack(videoStreamIdRef.current); + }; + + const replaceWithDummyStaticStream = () => { + if (!videoStreamIdRef.current) throw Error("Track id is null"); + + const { track } = createDummyStream(); + webrtc.replaceTrack(videoStreamIdRef.current, track, { source: "dummy" }); + }; + + const replaceWithCamera = () => { + if (!videoStreamIdRef.current) throw Error("Track id is null"); + + const track = videoStream?.getVideoTracks()[0]; + + if (!track) throw Error("Track is null"); + + webrtc.replaceTrack(videoStreamIdRef.current, track, { source: "camera" }); + }; + + const replaceWithNull = () => { + if (!videoStreamIdRef.current) throw Error("Track id is null"); + + webrtc.replaceTrack(videoStreamIdRef.current, null, { source: "null" }); + }; + + return ( +
+
+ + setSimulcastCheckbox(!simulcastCheckbox)} + /> +
+
+ + +
+ +
+ + + + + + +
+
+ + +
+ {videoStream && } +
+ ); +}; diff --git a/src/webrtc/webRTCEndpoint.ts b/src/webrtc/webRTCEndpoint.ts index 6b2fce3f..bd24ab69 100644 --- a/src/webrtc/webRTCEndpoint.ts +++ b/src/webrtc/webRTCEndpoint.ts @@ -410,6 +410,7 @@ export class WebRTCEndpoint extends private readonly endpointMetadataParser: MetadataParser; private readonly trackMetadataParser: MetadataParser; + private trackIdToSender: Record = {}; constructor(config?: Config) { super(); @@ -975,6 +976,11 @@ export class WebRTCEndpoint extends this.localTrackIdToTrack.set(trackId, trackContext); + const trackContextNew = this.localTrackIdToTrack.get(trackId)!; + + console.log(`trackContextNew: ${trackContextNew}`); + console.log(trackContextNew); + if (this.connection) { this.addTrackToConnection(trackContext); @@ -1141,7 +1147,7 @@ export class WebRTCEndpoint extends * }) * ``` */ - public async replaceTrack(trackId: string, newTrack: MediaStreamTrack, newTrackMetadata?: any): Promise { + public async replaceTrack(trackId: string, newTrack: MediaStreamTrack, newTrackMetadata?: any, muteAction?: "mute" | "unmute"): Promise { const resolutionNotifier = new Deferred(); try { const newMetadata = newTrackMetadata !== undefined ? this.trackMetadataParser(newTrackMetadata) : undefined; @@ -1153,6 +1159,19 @@ export class WebRTCEndpoint extends newTrackMetadata: newMetadata, resolutionNotifier, }); + + if (muteAction == "mute") { + const mediaEvent = generateMediaEvent("muteTrack", { trackId: trackId }); + this.sendMediaEvent(mediaEvent); + console.log("sent mute event"); + } + + if (muteAction == "unmute") { + const mediaEvent = generateMediaEvent("unmuteTrack", { trackId: trackId }); + this.sendMediaEvent(mediaEvent); + console.log("sent unmute event"); + } + } catch (error) { resolutionNotifier.reject(error); } @@ -1169,7 +1188,19 @@ export class WebRTCEndpoint extends const { trackId, newTrack, newTrackMetadata } = command; const trackContext = this.localTrackIdToTrack.get(trackId)!; - const sender = this.findSender(trackContext.track!.id); + + console.log({ trackId, newTrack, newTrackMetadata, trackContext }); + + let sender: RTCRtpSender | null = null; + if (trackContext.track !== null) { + sender = this.findSender(trackContext.track!.id); + this.trackIdToSender[trackId] = sender; + } else { + sender = this.trackIdToSender[trackId]; + } + + if (!sender) throw Error("Sender is empty!"); + if (sender) { this.ongoingTrackReplacement = true; sender From 9c30f2dcb6488daa61ce34ea33158e7935f65675 Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Mon, 27 May 2024 19:15:44 +0200 Subject: [PATCH 02/23] POC --- e2e/app/package-lock.json | 5372 +++++++++++++++---- e2e/app/src/App.tsx | 3 +- e2e/app/src/ReplaceTrackWithDummyStream.tsx | 22 +- e2e/app/tsconfig.json | 22 +- protos | 2 +- src/webrtc/commands.ts | 2 +- src/webrtc/webRTCEndpoint.ts | 116 +- 7 files changed, 4312 insertions(+), 1227 deletions(-) diff --git a/e2e/app/package-lock.json b/e2e/app/package-lock.json index 4b7c28a8..94394286 100644 --- a/e2e/app/package-lock.json +++ b/e2e/app/package-lock.json @@ -31,7 +31,7 @@ }, "../..": { "name": "@fishjam-dev/ts-client", - "version": "0.4.0", + "version": "0.5.0", "license": "Apache-2.0", "dependencies": { "events": "^3.3.0", @@ -64,11 +64,18 @@ "zod": "^3.23.6" } }, - "node_modules/@ampproject/remapping": { + "../../node_modules/@aashutoshrathi/word-wrap": { + "version": "1.2.6", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "../../node_modules/@ampproject/remapping": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.3.0.tgz", - "integrity": "sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==", "dev": true, + "license": "Apache-2.0", "dependencies": { "@jridgewell/gen-mapping": "^0.3.5", "@jridgewell/trace-mapping": "^0.3.24" @@ -77,715 +84,4179 @@ "node": ">=6.0.0" } }, - "node_modules/@babel/code-frame": { - "version": "7.24.2", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.24.2.tgz", - "integrity": "sha512-y5+tLQyV8pg3fsiln67BVLD1P13Eg4lh5RW9mF0zUuvLrv9uIQ4MCL+CRT+FTsBlBjcIan6PGsLcBN0m3ClUyQ==", + "../../node_modules/@babel/helper-string-parser": { + "version": "7.24.1", "dev": true, - "dependencies": { - "@babel/highlight": "^7.24.2", - "picocolors": "^1.0.0" - }, + "license": "MIT", "engines": { "node": ">=6.9.0" } }, - "node_modules/@babel/compat-data": { - "version": "7.24.4", - "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.24.4.tgz", - "integrity": "sha512-vg8Gih2MLK+kOkHJp4gBEIkyaIi00jgWot2D9QOmmfLC8jINSOzmCLta6Bvz/JSBCqnegV0L80jhxkol5GWNfQ==", + "../../node_modules/@babel/helper-validator-identifier": { + "version": "7.24.5", "dev": true, + "license": "MIT", "engines": { "node": ">=6.9.0" } }, - "node_modules/@babel/core": { + "../../node_modules/@babel/parser": { "version": "7.24.5", - "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.24.5.tgz", - "integrity": "sha512-tVQRucExLQ02Boi4vdPp49svNGcfL2GhdTCT9aldhXgCJVAI21EtRfBettiuLUwce/7r6bFdgs6JFkcdTiFttA==", "dev": true, - "dependencies": { - "@ampproject/remapping": "^2.2.0", - "@babel/code-frame": "^7.24.2", - "@babel/generator": "^7.24.5", - "@babel/helper-compilation-targets": "^7.23.6", - "@babel/helper-module-transforms": "^7.24.5", - "@babel/helpers": "^7.24.5", - "@babel/parser": "^7.24.5", - "@babel/template": "^7.24.0", - "@babel/traverse": "^7.24.5", - "@babel/types": "^7.24.5", - "convert-source-map": "^2.0.0", - "debug": "^4.1.0", - "gensync": "^1.0.0-beta.2", - "json5": "^2.2.3", - "semver": "^6.3.1" + "license": "MIT", + "bin": { + "parser": "bin/babel-parser.js" }, "engines": { - "node": ">=6.9.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/babel" - } - }, - "node_modules/@babel/core/node_modules/semver": { - "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", - "dev": true, - "bin": { - "semver": "bin/semver.js" + "node": ">=6.0.0" } }, - "node_modules/@babel/generator": { + "../../node_modules/@babel/types": { "version": "7.24.5", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.24.5.tgz", - "integrity": "sha512-x32i4hEXvr+iI0NEoEfDKzlemF8AmtOP8CcrRaEcpzysWuoEb1KknpcvMsHKPONoKZiDuItklgWhB18xEhr9PA==", "dev": true, + "license": "MIT", "dependencies": { - "@babel/types": "^7.24.5", - "@jridgewell/gen-mapping": "^0.3.5", - "@jridgewell/trace-mapping": "^0.3.25", - "jsesc": "^2.5.1" + "@babel/helper-string-parser": "^7.24.1", + "@babel/helper-validator-identifier": "^7.24.5", + "to-fast-properties": "^2.0.0" }, "engines": { "node": ">=6.9.0" } }, - "node_modules/@babel/helper-compilation-targets": { - "version": "7.23.6", - "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.23.6.tgz", - "integrity": "sha512-9JB548GZoQVmzrFgp8o7KxdgkTGm6xs9DW0o/Pim72UDjzr5ObUQ6ZzYPqA+g9OTS2bBQoctLJrky0RDCAWRgQ==", + "../../node_modules/@balena/dockerignore": { + "version": "1.0.2", "dev": true, - "dependencies": { - "@babel/compat-data": "^7.23.5", - "@babel/helper-validator-option": "^7.23.5", - "browserslist": "^4.22.2", - "lru-cache": "^5.1.1", - "semver": "^6.3.1" - }, - "engines": { - "node": ">=6.9.0" - } + "license": "Apache-2.0" }, - "node_modules/@babel/helper-compilation-targets/node_modules/semver": { - "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "../../node_modules/@bcoe/v8-coverage": { + "version": "0.2.3", "dev": true, - "bin": { - "semver": "bin/semver.js" - } + "license": "MIT" }, - "node_modules/@babel/helper-environment-visitor": { - "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.22.20.tgz", - "integrity": "sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA==", + "../../node_modules/@esbuild/darwin-arm64": { + "version": "0.20.2", + "cpu": [ + "arm64" + ], "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], "engines": { - "node": ">=6.9.0" + "node": ">=12" } }, - "node_modules/@babel/helper-function-name": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.23.0.tgz", - "integrity": "sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==", + "../../node_modules/@eslint-community/eslint-utils": { + "version": "4.4.0", "dev": true, + "license": "MIT", "dependencies": { - "@babel/template": "^7.22.15", - "@babel/types": "^7.23.0" + "eslint-visitor-keys": "^3.3.0" }, "engines": { - "node": ">=6.9.0" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "peerDependencies": { + "eslint": "^6.0.0 || ^7.0.0 || >=8.0.0" } }, - "node_modules/@babel/helper-hoist-variables": { - "version": "7.22.5", - "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.22.5.tgz", - "integrity": "sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==", + "../../node_modules/@eslint-community/regexpp": { + "version": "4.10.0", "dev": true, - "dependencies": { - "@babel/types": "^7.22.5" - }, + "license": "MIT", "engines": { - "node": ">=6.9.0" + "node": "^12.0.0 || ^14.0.0 || >=16.0.0" } }, - "node_modules/@babel/helper-module-imports": { - "version": "7.24.3", - "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.24.3.tgz", - "integrity": "sha512-viKb0F9f2s0BCS22QSF308z/+1YWKV/76mwt61NBzS5izMzDPwdq1pTrzf+Li3npBWX9KdQbkeCt1jSAM7lZqg==", + "../../node_modules/@eslint/eslintrc": { + "version": "2.1.4", "dev": true, + "license": "MIT", "dependencies": { - "@babel/types": "^7.24.0" + "ajv": "^6.12.4", + "debug": "^4.3.2", + "espree": "^9.6.0", + "globals": "^13.19.0", + "ignore": "^5.2.0", + "import-fresh": "^3.2.1", + "js-yaml": "^4.1.0", + "minimatch": "^3.1.2", + "strip-json-comments": "^3.1.1" }, "engines": { - "node": ">=6.9.0" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" } }, - "node_modules/@babel/helper-module-transforms": { - "version": "7.24.5", - "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.24.5.tgz", - "integrity": "sha512-9GxeY8c2d2mdQUP1Dye0ks3VDyIMS98kt/llQ2nUId8IsWqTF0l1LkSX0/uP7l7MCDrzXS009Hyhe2gzTiGW8A==", + "../../node_modules/@eslint/eslintrc/node_modules/brace-expansion": { + "version": "1.1.11", "dev": true, + "license": "MIT", "dependencies": { - "@babel/helper-environment-visitor": "^7.22.20", - "@babel/helper-module-imports": "^7.24.3", - "@babel/helper-simple-access": "^7.24.5", - "@babel/helper-split-export-declaration": "^7.24.5", - "@babel/helper-validator-identifier": "^7.24.5" + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "../../node_modules/@eslint/eslintrc/node_modules/minimatch": { + "version": "3.1.2", + "dev": true, + "license": "ISC", + "dependencies": { + "brace-expansion": "^1.1.7" }, "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0" + "node": "*" } }, - "node_modules/@babel/helper-plugin-utils": { - "version": "7.24.5", - "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.24.5.tgz", - "integrity": "sha512-xjNLDopRzW2o6ba0gKbkZq5YWEBaK3PCyTOY1K2P/O07LGMhMqlMXPxwN4S5/RhWuCobT8z0jrlKGlYmeR1OhQ==", + "../../node_modules/@eslint/js": { + "version": "8.57.0", "dev": true, + "license": "MIT", "engines": { - "node": ">=6.9.0" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" } }, - "node_modules/@babel/helper-simple-access": { - "version": "7.24.5", - "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.24.5.tgz", - "integrity": "sha512-uH3Hmf5q5n7n8mz7arjUlDOCbttY/DW4DYhE6FUsjKJ/oYC1kQQUvwEQWxRwUpX9qQKRXeqLwWxrqilMrf32sQ==", + "../../node_modules/@humanwhocodes/config-array": { + "version": "0.11.14", "dev": true, + "license": "Apache-2.0", "dependencies": { - "@babel/types": "^7.24.5" + "@humanwhocodes/object-schema": "^2.0.2", + "debug": "^4.3.1", + "minimatch": "^3.0.5" }, "engines": { - "node": ">=6.9.0" + "node": ">=10.10.0" } }, - "node_modules/@babel/helper-split-export-declaration": { - "version": "7.24.5", - "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.24.5.tgz", - "integrity": "sha512-5CHncttXohrHk8GWOFCcCl4oRD9fKosWlIRgWm4ql9VYioKm52Mk2xsmoohvm7f3JoiLSM5ZgJuRaf5QZZYd3Q==", + "../../node_modules/@humanwhocodes/config-array/node_modules/brace-expansion": { + "version": "1.1.11", "dev": true, + "license": "MIT", "dependencies": { - "@babel/types": "^7.24.5" - }, - "engines": { - "node": ">=6.9.0" + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" } }, - "node_modules/@babel/helper-string-parser": { - "version": "7.24.1", - "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.24.1.tgz", - "integrity": "sha512-2ofRCjnnA9y+wk8b9IAREroeUP02KHp431N2mhKniy2yKIDKpbrHv9eXwm8cBeWQYcJmzv5qKCu65P47eCF7CQ==", + "../../node_modules/@humanwhocodes/config-array/node_modules/minimatch": { + "version": "3.1.2", "dev": true, + "license": "ISC", + "dependencies": { + "brace-expansion": "^1.1.7" + }, "engines": { - "node": ">=6.9.0" + "node": "*" } }, - "node_modules/@babel/helper-validator-identifier": { - "version": "7.24.5", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.24.5.tgz", - "integrity": "sha512-3q93SSKX2TWCG30M2G2kwaKeTYgEUp5Snjuj8qm729SObL6nbtUldAi37qbxkD5gg3xnBio+f9nqpSepGZMvxA==", + "../../node_modules/@humanwhocodes/module-importer": { + "version": "1.0.1", "dev": true, + "license": "Apache-2.0", "engines": { - "node": ">=6.9.0" + "node": ">=12.22" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/nzakas" } }, - "node_modules/@babel/helper-validator-option": { - "version": "7.23.5", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.23.5.tgz", - "integrity": "sha512-85ttAOMLsr53VgXkTbkx8oA6YTfT4q7/HzXSLEYmjcSTJPMPQtvq1BD79Byep5xMUYbGRzEpDsjUf3dyp54IKw==", + "../../node_modules/@humanwhocodes/object-schema": { + "version": "2.0.3", + "dev": true, + "license": "BSD-3-Clause" + }, + "../../node_modules/@istanbuljs/schema": { + "version": "0.1.3", "dev": true, + "license": "MIT", "engines": { - "node": ">=6.9.0" + "node": ">=8" } }, - "node_modules/@babel/helpers": { - "version": "7.24.5", - "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.24.5.tgz", - "integrity": "sha512-CiQmBMMpMQHwM5m01YnrM6imUG1ebgYJ+fAIW4FZe6m4qHTPaRHti+R8cggAwkdz4oXhtO4/K9JWlh+8hIfR2Q==", + "../../node_modules/@jest/schemas": { + "version": "29.6.3", "dev": true, + "license": "MIT", "dependencies": { - "@babel/template": "^7.24.0", - "@babel/traverse": "^7.24.5", - "@babel/types": "^7.24.5" + "@sinclair/typebox": "^0.27.8" }, "engines": { - "node": ">=6.9.0" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/@babel/highlight": { - "version": "7.24.5", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.24.5.tgz", - "integrity": "sha512-8lLmua6AVh/8SLJRRVD6V8p73Hir9w5mJrhE+IPpILG31KKlI9iz5zmBYKcWPS59qSfgP9RaSBQSHHE81WKuEw==", + "../../node_modules/@jridgewell/gen-mapping": { + "version": "0.3.5", "dev": true, + "license": "MIT", "dependencies": { - "@babel/helper-validator-identifier": "^7.24.5", - "chalk": "^2.4.2", - "js-tokens": "^4.0.0", - "picocolors": "^1.0.0" + "@jridgewell/set-array": "^1.2.1", + "@jridgewell/sourcemap-codec": "^1.4.10", + "@jridgewell/trace-mapping": "^0.3.24" }, "engines": { - "node": ">=6.9.0" + "node": ">=6.0.0" } }, - "node_modules/@babel/parser": { - "version": "7.24.5", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.24.5.tgz", - "integrity": "sha512-EOv5IK8arwh3LI47dz1b0tKUb/1uhHAnHJOrjgtQMIpu1uXd9mlFrJg9IUgGUgZ41Ch0K8REPTYpO7B76b4vJg==", + "../../node_modules/@jridgewell/resolve-uri": { + "version": "3.1.2", "dev": true, - "bin": { - "parser": "bin/babel-parser.js" - }, + "license": "MIT", "engines": { "node": ">=6.0.0" } }, - "node_modules/@babel/plugin-transform-react-jsx-self": { - "version": "7.24.5", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-self/-/plugin-transform-react-jsx-self-7.24.5.tgz", - "integrity": "sha512-RtCJoUO2oYrYwFPtR1/jkoBEcFuI1ae9a9IMxeyAVa3a1Ap4AnxmyIKG2b2FaJKqkidw/0cxRbWN+HOs6ZWd1w==", + "../../node_modules/@jridgewell/set-array": { + "version": "1.2.1", "dev": true, - "dependencies": { - "@babel/helper-plugin-utils": "^7.24.5" - }, + "license": "MIT", "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" + "node": ">=6.0.0" } }, - "node_modules/@babel/plugin-transform-react-jsx-source": { - "version": "7.24.1", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-source/-/plugin-transform-react-jsx-source-7.24.1.tgz", - "integrity": "sha512-1v202n7aUq4uXAieRTKcwPzNyphlCuqHHDcdSNc+vdhoTEZcFMh+L5yZuCmGaIO7bs1nJUNfHB89TZyoL48xNA==", + "../../node_modules/@jridgewell/sourcemap-codec": { + "version": "1.4.15", + "dev": true, + "license": "MIT" + }, + "../../node_modules/@jridgewell/trace-mapping": { + "version": "0.3.25", "dev": true, + "license": "MIT", "dependencies": { - "@babel/helper-plugin-utils": "^7.24.0" - }, - "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" } }, - "node_modules/@babel/template": { - "version": "7.24.0", - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.24.0.tgz", - "integrity": "sha512-Bkf2q8lMB0AFpX0NFEqSbx1OkTHf0f+0j82mkw+ZpzBnkk7e9Ql0891vlfgi+kHwOk8tQjiQHpqh4LaSa0fKEA==", + "../../node_modules/@nodelib/fs.scandir": { + "version": "2.1.5", "dev": true, + "license": "MIT", "dependencies": { - "@babel/code-frame": "^7.23.5", - "@babel/parser": "^7.24.0", - "@babel/types": "^7.24.0" + "@nodelib/fs.stat": "2.0.5", + "run-parallel": "^1.1.9" }, "engines": { - "node": ">=6.9.0" + "node": ">= 8" } }, - "node_modules/@babel/traverse": { + "../../node_modules/@nodelib/fs.stat": { + "version": "2.0.5", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 8" + } + }, + "../../node_modules/@nodelib/fs.walk": { + "version": "1.2.8", + "dev": true, + "license": "MIT", + "dependencies": { + "@nodelib/fs.scandir": "2.1.5", + "fastq": "^1.6.0" + }, + "engines": { + "node": ">= 8" + } + }, + "../../node_modules/@playwright/test": { + "version": "1.40.1", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "playwright": "1.40.1" + }, + "bin": { + "playwright": "cli.js" + }, + "engines": { + "node": ">=16" + } + }, + "../../node_modules/@protobufjs/aspromise": { + "version": "1.1.2", + "license": "BSD-3-Clause" + }, + "../../node_modules/@protobufjs/base64": { + "version": "1.1.2", + "license": "BSD-3-Clause" + }, + "../../node_modules/@protobufjs/codegen": { + "version": "2.0.4", + "license": "BSD-3-Clause" + }, + "../../node_modules/@protobufjs/eventemitter": { + "version": "1.1.0", + "license": "BSD-3-Clause" + }, + "../../node_modules/@protobufjs/fetch": { + "version": "1.1.0", + "license": "BSD-3-Clause", + "dependencies": { + "@protobufjs/aspromise": "^1.1.1", + "@protobufjs/inquire": "^1.1.0" + } + }, + "../../node_modules/@protobufjs/float": { + "version": "1.0.2", + "license": "BSD-3-Clause" + }, + "../../node_modules/@protobufjs/inquire": { + "version": "1.1.0", + "license": "BSD-3-Clause" + }, + "../../node_modules/@protobufjs/path": { + "version": "1.1.2", + "license": "BSD-3-Clause" + }, + "../../node_modules/@protobufjs/pool": { + "version": "1.1.0", + "license": "BSD-3-Clause" + }, + "../../node_modules/@protobufjs/utf8": { + "version": "1.1.0", + "license": "BSD-3-Clause" + }, + "../../node_modules/@rollup/rollup-darwin-arm64": { + "version": "4.17.2", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ] + }, + "../../node_modules/@sinclair/typebox": { + "version": "0.27.8", + "dev": true, + "license": "MIT" + }, + "../../node_modules/@types/docker-modem": { + "version": "3.0.6", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*", + "@types/ssh2": "*" + } + }, + "../../node_modules/@types/dockerode": { + "version": "3.3.23", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/docker-modem": "*", + "@types/node": "*" + } + }, + "../../node_modules/@types/estree": { + "version": "1.0.5", + "dev": true, + "license": "MIT" + }, + "../../node_modules/@types/events": { + "version": "3.0.3", + "dev": true, + "license": "MIT" + }, + "../../node_modules/@types/json-schema": { + "version": "7.0.15", + "dev": true, + "license": "MIT" + }, + "../../node_modules/@types/node": { + "version": "20.10.3", + "license": "MIT", + "dependencies": { + "undici-types": "~5.26.4" + } + }, + "../../node_modules/@types/semver": { + "version": "7.5.8", + "dev": true, + "license": "MIT" + }, + "../../node_modules/@types/ssh2": { + "version": "1.11.18", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "^18.11.18" + } + }, + "../../node_modules/@types/ssh2-streams": { + "version": "0.1.12", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*" + } + }, + "../../node_modules/@types/ssh2/node_modules/@types/node": { + "version": "18.19.2", + "dev": true, + "license": "MIT", + "dependencies": { + "undici-types": "~5.26.4" + } + }, + "../../node_modules/@types/uuid": { + "version": "9.0.8", + "dev": true, + "license": "MIT" + }, + "../../node_modules/@typescript-eslint/eslint-plugin": { + "version": "7.8.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@eslint-community/regexpp": "^4.10.0", + "@typescript-eslint/scope-manager": "7.8.0", + "@typescript-eslint/type-utils": "7.8.0", + "@typescript-eslint/utils": "7.8.0", + "@typescript-eslint/visitor-keys": "7.8.0", + "debug": "^4.3.4", + "graphemer": "^1.4.0", + "ignore": "^5.3.1", + "natural-compare": "^1.4.0", + "semver": "^7.6.0", + "ts-api-utils": "^1.3.0" + }, + "engines": { + "node": "^18.18.0 || >=20.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "@typescript-eslint/parser": "^7.0.0", + "eslint": "^8.56.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "../../node_modules/@typescript-eslint/parser": { + "version": "7.8.0", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "@typescript-eslint/scope-manager": "7.8.0", + "@typescript-eslint/types": "7.8.0", + "@typescript-eslint/typescript-estree": "7.8.0", + "@typescript-eslint/visitor-keys": "7.8.0", + "debug": "^4.3.4" + }, + "engines": { + "node": "^18.18.0 || >=20.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "eslint": "^8.56.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "../../node_modules/@typescript-eslint/scope-manager": { + "version": "7.8.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/types": "7.8.0", + "@typescript-eslint/visitor-keys": "7.8.0" + }, + "engines": { + "node": "^18.18.0 || >=20.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "../../node_modules/@typescript-eslint/type-utils": { + "version": "7.8.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/typescript-estree": "7.8.0", + "@typescript-eslint/utils": "7.8.0", + "debug": "^4.3.4", + "ts-api-utils": "^1.3.0" + }, + "engines": { + "node": "^18.18.0 || >=20.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "eslint": "^8.56.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "../../node_modules/@typescript-eslint/types": { + "version": "7.8.0", + "dev": true, + "license": "MIT", + "engines": { + "node": "^18.18.0 || >=20.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "../../node_modules/@typescript-eslint/typescript-estree": { + "version": "7.8.0", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "@typescript-eslint/types": "7.8.0", + "@typescript-eslint/visitor-keys": "7.8.0", + "debug": "^4.3.4", + "globby": "^11.1.0", + "is-glob": "^4.0.3", + "minimatch": "^9.0.4", + "semver": "^7.6.0", + "ts-api-utils": "^1.3.0" + }, + "engines": { + "node": "^18.18.0 || >=20.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "../../node_modules/@typescript-eslint/utils": { + "version": "7.8.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@eslint-community/eslint-utils": "^4.4.0", + "@types/json-schema": "^7.0.15", + "@types/semver": "^7.5.8", + "@typescript-eslint/scope-manager": "7.8.0", + "@typescript-eslint/types": "7.8.0", + "@typescript-eslint/typescript-estree": "7.8.0", + "semver": "^7.6.0" + }, + "engines": { + "node": "^18.18.0 || >=20.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "eslint": "^8.56.0" + } + }, + "../../node_modules/@typescript-eslint/visitor-keys": { + "version": "7.8.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/types": "7.8.0", + "eslint-visitor-keys": "^3.4.3" + }, + "engines": { + "node": "^18.18.0 || >=20.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "../../node_modules/@ungap/structured-clone": { + "version": "1.2.0", + "dev": true, + "license": "ISC" + }, + "../../node_modules/@vitest/coverage-v8": { + "version": "1.6.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@ampproject/remapping": "^2.2.1", + "@bcoe/v8-coverage": "^0.2.3", + "debug": "^4.3.4", + "istanbul-lib-coverage": "^3.2.2", + "istanbul-lib-report": "^3.0.1", + "istanbul-lib-source-maps": "^5.0.4", + "istanbul-reports": "^3.1.6", + "magic-string": "^0.30.5", + "magicast": "^0.3.3", + "picocolors": "^1.0.0", + "std-env": "^3.5.0", + "strip-literal": "^2.0.0", + "test-exclude": "^6.0.0" + }, + "funding": { + "url": "https://opencollective.com/vitest" + }, + "peerDependencies": { + "vitest": "1.6.0" + } + }, + "../../node_modules/@vitest/expect": { + "version": "1.6.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@vitest/spy": "1.6.0", + "@vitest/utils": "1.6.0", + "chai": "^4.3.10" + }, + "funding": { + "url": "https://opencollective.com/vitest" + } + }, + "../../node_modules/@vitest/runner": { + "version": "1.6.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@vitest/utils": "1.6.0", + "p-limit": "^5.0.0", + "pathe": "^1.1.1" + }, + "funding": { + "url": "https://opencollective.com/vitest" + } + }, + "../../node_modules/@vitest/runner/node_modules/p-limit": { + "version": "5.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "yocto-queue": "^1.0.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/@vitest/runner/node_modules/yocto-queue": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12.20" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/@vitest/snapshot": { + "version": "1.6.0", + "dev": true, + "license": "MIT", + "dependencies": { + "magic-string": "^0.30.5", + "pathe": "^1.1.1", + "pretty-format": "^29.7.0" + }, + "funding": { + "url": "https://opencollective.com/vitest" + } + }, + "../../node_modules/@vitest/spy": { + "version": "1.6.0", + "dev": true, + "license": "MIT", + "dependencies": { + "tinyspy": "^2.2.0" + }, + "funding": { + "url": "https://opencollective.com/vitest" + } + }, + "../../node_modules/@vitest/utils": { + "version": "1.6.0", + "dev": true, + "license": "MIT", + "dependencies": { + "diff-sequences": "^29.6.3", + "estree-walker": "^3.0.3", + "loupe": "^2.3.7", + "pretty-format": "^29.7.0" + }, + "funding": { + "url": "https://opencollective.com/vitest" + } + }, + "../../node_modules/acorn": { + "version": "8.11.3", + "dev": true, + "license": "MIT", + "bin": { + "acorn": "bin/acorn" + }, + "engines": { + "node": ">=0.4.0" + } + }, + "../../node_modules/acorn-jsx": { + "version": "5.3.2", + "dev": true, + "license": "MIT", + "peerDependencies": { + "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" + } + }, + "../../node_modules/acorn-walk": { + "version": "8.3.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.4.0" + } + }, + "../../node_modules/ajv": { + "version": "6.12.6", + "dev": true, + "license": "MIT", + "dependencies": { + "fast-deep-equal": "^3.1.1", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.4.1", + "uri-js": "^4.2.2" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" + } + }, + "../../node_modules/ansi-regex": { + "version": "5.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "../../node_modules/ansi-sequence-parser": { + "version": "1.1.1", + "dev": true, + "license": "MIT" + }, + "../../node_modules/ansi-styles": { + "version": "4.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "../../node_modules/archiver": { + "version": "5.3.2", + "dev": true, + "license": "MIT", + "dependencies": { + "archiver-utils": "^2.1.0", + "async": "^3.2.4", + "buffer-crc32": "^0.2.1", + "readable-stream": "^3.6.0", + "readdir-glob": "^1.1.2", + "tar-stream": "^2.2.0", + "zip-stream": "^4.1.0" + }, + "engines": { + "node": ">= 10" + } + }, + "../../node_modules/archiver-utils": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "glob": "^7.1.4", + "graceful-fs": "^4.2.0", + "lazystream": "^1.0.0", + "lodash.defaults": "^4.2.0", + "lodash.difference": "^4.5.0", + "lodash.flatten": "^4.4.0", + "lodash.isplainobject": "^4.0.6", + "lodash.union": "^4.6.0", + "normalize-path": "^3.0.0", + "readable-stream": "^2.0.0" + }, + "engines": { + "node": ">= 6" + } + }, + "../../node_modules/archiver-utils/node_modules/readable-stream": { + "version": "2.3.8", + "dev": true, + "license": "MIT", + "dependencies": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "../../node_modules/archiver-utils/node_modules/safe-buffer": { + "version": "5.1.2", + "dev": true, + "license": "MIT" + }, + "../../node_modules/archiver-utils/node_modules/string_decoder": { + "version": "1.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "../../node_modules/argparse": { + "version": "2.0.1", + "dev": true, + "license": "Python-2.0" + }, + "../../node_modules/array-union": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "../../node_modules/asn1": { + "version": "0.2.6", + "dev": true, + "license": "MIT", + "dependencies": { + "safer-buffer": "~2.1.0" + } + }, + "../../node_modules/assertion-error": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": "*" + } + }, + "../../node_modules/async": { + "version": "3.2.5", + "dev": true, + "license": "MIT" + }, + "../../node_modules/async-lock": { + "version": "1.4.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/b4a": { + "version": "1.6.4", + "dev": true, + "license": "ISC" + }, + "../../node_modules/balanced-match": { + "version": "1.0.2", + "dev": true, + "license": "MIT" + }, + "../../node_modules/base64-js": { + "version": "1.5.1", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT" + }, + "../../node_modules/bcrypt-pbkdf": { + "version": "1.0.2", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "tweetnacl": "^0.14.3" + } + }, + "../../node_modules/bl": { + "version": "4.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "buffer": "^5.5.0", + "inherits": "^2.0.4", + "readable-stream": "^3.4.0" + } + }, + "../../node_modules/brace-expansion": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0" + } + }, + "../../node_modules/braces": { + "version": "3.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "fill-range": "^7.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "../../node_modules/buffer": { + "version": "5.7.1", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, + "../../node_modules/buffer-crc32": { + "version": "0.2.13", + "dev": true, + "license": "MIT", + "engines": { + "node": "*" + } + }, + "../../node_modules/buildcheck": { + "version": "0.0.6", + "dev": true, + "optional": true, + "engines": { + "node": ">=10.0.0" + } + }, + "../../node_modules/byline": { + "version": "5.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "../../node_modules/cac": { + "version": "6.7.14", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "../../node_modules/callsites": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "../../node_modules/case-anything": { + "version": "2.1.13", + "license": "MIT", + "engines": { + "node": ">=12.13" + }, + "funding": { + "url": "https://github.com/sponsors/mesqueeb" + } + }, + "../../node_modules/chai": { + "version": "4.4.1", + "dev": true, + "license": "MIT", + "dependencies": { + "assertion-error": "^1.1.0", + "check-error": "^1.0.3", + "deep-eql": "^4.1.3", + "get-func-name": "^2.0.2", + "loupe": "^2.3.6", + "pathval": "^1.1.1", + "type-detect": "^4.0.8" + }, + "engines": { + "node": ">=4" + } + }, + "../../node_modules/chalk": { + "version": "4.1.2", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "../../node_modules/check-error": { + "version": "1.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "get-func-name": "^2.0.2" + }, + "engines": { + "node": "*" + } + }, + "../../node_modules/chownr": { + "version": "1.1.4", + "dev": true, + "license": "ISC" + }, + "../../node_modules/color-convert": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "../../node_modules/color-name": { + "version": "1.1.4", + "dev": true, + "license": "MIT" + }, + "../../node_modules/compress-commons": { + "version": "4.1.2", + "dev": true, + "license": "MIT", + "dependencies": { + "buffer-crc32": "^0.2.13", + "crc32-stream": "^4.0.2", + "normalize-path": "^3.0.0", + "readable-stream": "^3.6.0" + }, + "engines": { + "node": ">= 10" + } + }, + "../../node_modules/concat-map": { + "version": "0.0.1", + "dev": true, + "license": "MIT" + }, + "../../node_modules/confbox": { + "version": "0.1.7", + "dev": true, + "license": "MIT" + }, + "../../node_modules/core-util-is": { + "version": "1.0.3", + "dev": true, + "license": "MIT" + }, + "../../node_modules/cpu-features": { + "version": "0.0.9", + "dev": true, + "hasInstallScript": true, + "optional": true, + "dependencies": { + "buildcheck": "~0.0.6", + "nan": "^2.17.0" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "../../node_modules/crc-32": { + "version": "1.2.2", + "dev": true, + "license": "Apache-2.0", + "bin": { + "crc32": "bin/crc32.njs" + }, + "engines": { + "node": ">=0.8" + } + }, + "../../node_modules/crc32-stream": { + "version": "4.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "crc-32": "^1.2.0", + "readable-stream": "^3.4.0" + }, + "engines": { + "node": ">= 10" + } + }, + "../../node_modules/cross-spawn": { + "version": "7.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + }, + "engines": { + "node": ">= 8" + } + }, + "../../node_modules/debug": { + "version": "4.3.4", + "dev": true, + "license": "MIT", + "dependencies": { + "ms": "2.1.2" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "../../node_modules/deep-eql": { + "version": "4.1.3", + "dev": true, + "license": "MIT", + "dependencies": { + "type-detect": "^4.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "../../node_modules/deep-is": { + "version": "0.1.4", + "dev": true, + "license": "MIT" + }, + "../../node_modules/detect-libc": { + "version": "1.0.3", + "license": "Apache-2.0", + "bin": { + "detect-libc": "bin/detect-libc.js" + }, + "engines": { + "node": ">=0.10" + } + }, + "../../node_modules/diff-sequences": { + "version": "29.6.3", + "dev": true, + "license": "MIT", + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "../../node_modules/dir-glob": { + "version": "3.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "path-type": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "../../node_modules/docker-compose": { + "version": "0.24.3", + "dev": true, + "license": "MIT", + "dependencies": { + "yaml": "^2.2.2" + }, + "engines": { + "node": ">= 6.0.0" + } + }, + "../../node_modules/docker-modem": { + "version": "3.0.8", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "debug": "^4.1.1", + "readable-stream": "^3.5.0", + "split-ca": "^1.0.1", + "ssh2": "^1.11.0" + }, + "engines": { + "node": ">= 8.0" + } + }, + "../../node_modules/dockerode": { + "version": "3.3.5", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "@balena/dockerignore": "^1.0.2", + "docker-modem": "^3.0.0", + "tar-fs": "~2.0.1" + }, + "engines": { + "node": ">= 8.0" + } + }, + "../../node_modules/dockerode/node_modules/tar-fs": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "chownr": "^1.1.1", + "mkdirp-classic": "^0.5.2", + "pump": "^3.0.0", + "tar-stream": "^2.0.0" + } + }, + "../../node_modules/doctrine": { + "version": "3.0.0", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "esutils": "^2.0.2" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "../../node_modules/dprint-node": { + "version": "1.0.8", + "license": "MIT", + "dependencies": { + "detect-libc": "^1.0.3" + } + }, + "../../node_modules/end-of-stream": { + "version": "1.4.4", + "dev": true, + "license": "MIT", + "dependencies": { + "once": "^1.4.0" + } + }, + "../../node_modules/esbuild": { + "version": "0.20.2", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=12" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.20.2", + "@esbuild/android-arm": "0.20.2", + "@esbuild/android-arm64": "0.20.2", + "@esbuild/android-x64": "0.20.2", + "@esbuild/darwin-arm64": "0.20.2", + "@esbuild/darwin-x64": "0.20.2", + "@esbuild/freebsd-arm64": "0.20.2", + "@esbuild/freebsd-x64": "0.20.2", + "@esbuild/linux-arm": "0.20.2", + "@esbuild/linux-arm64": "0.20.2", + "@esbuild/linux-ia32": "0.20.2", + "@esbuild/linux-loong64": "0.20.2", + "@esbuild/linux-mips64el": "0.20.2", + "@esbuild/linux-ppc64": "0.20.2", + "@esbuild/linux-riscv64": "0.20.2", + "@esbuild/linux-s390x": "0.20.2", + "@esbuild/linux-x64": "0.20.2", + "@esbuild/netbsd-x64": "0.20.2", + "@esbuild/openbsd-x64": "0.20.2", + "@esbuild/sunos-x64": "0.20.2", + "@esbuild/win32-arm64": "0.20.2", + "@esbuild/win32-ia32": "0.20.2", + "@esbuild/win32-x64": "0.20.2" + } + }, + "../../node_modules/escape-string-regexp": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/eslint": { + "version": "8.57.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@eslint-community/eslint-utils": "^4.2.0", + "@eslint-community/regexpp": "^4.6.1", + "@eslint/eslintrc": "^2.1.4", + "@eslint/js": "8.57.0", + "@humanwhocodes/config-array": "^0.11.14", + "@humanwhocodes/module-importer": "^1.0.1", + "@nodelib/fs.walk": "^1.2.8", + "@ungap/structured-clone": "^1.2.0", + "ajv": "^6.12.4", + "chalk": "^4.0.0", + "cross-spawn": "^7.0.2", + "debug": "^4.3.2", + "doctrine": "^3.0.0", + "escape-string-regexp": "^4.0.0", + "eslint-scope": "^7.2.2", + "eslint-visitor-keys": "^3.4.3", + "espree": "^9.6.1", + "esquery": "^1.4.2", + "esutils": "^2.0.2", + "fast-deep-equal": "^3.1.3", + "file-entry-cache": "^6.0.1", + "find-up": "^5.0.0", + "glob-parent": "^6.0.2", + "globals": "^13.19.0", + "graphemer": "^1.4.0", + "ignore": "^5.2.0", + "imurmurhash": "^0.1.4", + "is-glob": "^4.0.0", + "is-path-inside": "^3.0.3", + "js-yaml": "^4.1.0", + "json-stable-stringify-without-jsonify": "^1.0.1", + "levn": "^0.4.1", + "lodash.merge": "^4.6.2", + "minimatch": "^3.1.2", + "natural-compare": "^1.4.0", + "optionator": "^0.9.3", + "strip-ansi": "^6.0.1", + "text-table": "^0.2.0" + }, + "bin": { + "eslint": "bin/eslint.js" + }, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + } + }, + "../../node_modules/eslint-config-prettier": { + "version": "9.1.0", + "dev": true, + "license": "MIT", + "bin": { + "eslint-config-prettier": "bin/cli.js" + }, + "peerDependencies": { + "eslint": ">=7.0.0" + } + }, + "../../node_modules/eslint-plugin-react-hooks": { + "version": "4.6.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "eslint": "^3.0.0 || ^4.0.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0-0" + } + }, + "../../node_modules/eslint-scope": { + "version": "7.2.2", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "esrecurse": "^4.3.0", + "estraverse": "^5.2.0" + }, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + } + }, + "../../node_modules/eslint-visitor-keys": { + "version": "3.4.3", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + } + }, + "../../node_modules/eslint/node_modules/brace-expansion": { + "version": "1.1.11", + "dev": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "../../node_modules/eslint/node_modules/minimatch": { + "version": "3.1.2", + "dev": true, + "license": "ISC", + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "../../node_modules/espree": { + "version": "9.6.1", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "acorn": "^8.9.0", + "acorn-jsx": "^5.3.2", + "eslint-visitor-keys": "^3.4.1" + }, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + } + }, + "../../node_modules/esquery": { + "version": "1.5.0", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "estraverse": "^5.1.0" + }, + "engines": { + "node": ">=0.10" + } + }, + "../../node_modules/esrecurse": { + "version": "4.3.0", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "estraverse": "^5.2.0" + }, + "engines": { + "node": ">=4.0" + } + }, + "../../node_modules/estraverse": { + "version": "5.3.0", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=4.0" + } + }, + "../../node_modules/estree-walker": { + "version": "3.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/estree": "^1.0.0" + } + }, + "../../node_modules/esutils": { + "version": "2.0.3", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=0.10.0" + } + }, + "../../node_modules/event-target-shim": { + "version": "6.0.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10.13.0" + }, + "funding": { + "url": "https://github.com/sponsors/mysticatea" + } + }, + "../../node_modules/events": { + "version": "3.3.0", + "license": "MIT", + "engines": { + "node": ">=0.8.x" + } + }, + "../../node_modules/execa": { + "version": "8.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "cross-spawn": "^7.0.3", + "get-stream": "^8.0.1", + "human-signals": "^5.0.0", + "is-stream": "^3.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^5.1.0", + "onetime": "^6.0.0", + "signal-exit": "^4.1.0", + "strip-final-newline": "^3.0.0" + }, + "engines": { + "node": ">=16.17" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" + } + }, + "../../node_modules/execa/node_modules/signal-exit": { + "version": "4.1.0", + "dev": true, + "license": "ISC", + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "../../node_modules/fake-mediastreamtrack": { + "version": "1.2.0", + "dev": true, + "license": "ISC", + "dependencies": { + "event-target-shim": "^6.0.2", + "uuid": "^9.0.0" + } + }, + "../../node_modules/fast-deep-equal": { + "version": "3.1.3", + "dev": true, + "license": "MIT" + }, + "../../node_modules/fast-fifo": { + "version": "1.3.2", + "dev": true, + "license": "MIT" + }, + "../../node_modules/fast-glob": { + "version": "3.3.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@nodelib/fs.stat": "^2.0.2", + "@nodelib/fs.walk": "^1.2.3", + "glob-parent": "^5.1.2", + "merge2": "^1.3.0", + "micromatch": "^4.0.4" + }, + "engines": { + "node": ">=8.6.0" + } + }, + "../../node_modules/fast-glob/node_modules/glob-parent": { + "version": "5.1.2", + "dev": true, + "license": "ISC", + "dependencies": { + "is-glob": "^4.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "../../node_modules/fast-json-stable-stringify": { + "version": "2.1.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/fast-levenshtein": { + "version": "2.0.6", + "dev": true, + "license": "MIT" + }, + "../../node_modules/fastq": { + "version": "1.15.0", + "dev": true, + "license": "ISC", + "dependencies": { + "reusify": "^1.0.4" + } + }, + "../../node_modules/file-entry-cache": { + "version": "6.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "flat-cache": "^3.0.4" + }, + "engines": { + "node": "^10.12.0 || >=12.0.0" + } + }, + "../../node_modules/fill-range": { + "version": "7.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "to-regex-range": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "../../node_modules/find-up": { + "version": "5.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "locate-path": "^6.0.0", + "path-exists": "^4.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/flat-cache": { + "version": "3.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "flatted": "^3.2.9", + "keyv": "^4.5.3", + "rimraf": "^3.0.2" + }, + "engines": { + "node": "^10.12.0 || >=12.0.0" + } + }, + "../../node_modules/flatted": { + "version": "3.2.9", + "dev": true, + "license": "ISC" + }, + "../../node_modules/fs-constants": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/fs.realpath": { + "version": "1.0.0", + "dev": true, + "license": "ISC" + }, + "../../node_modules/fsevents": { + "version": "2.3.2", + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "../../node_modules/get-func-name": { + "version": "2.0.2", + "dev": true, + "license": "MIT", + "engines": { + "node": "*" + } + }, + "../../node_modules/get-port": { + "version": "5.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/get-stream": { + "version": "8.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/glob": { + "version": "7.2.3", + "dev": true, + "license": "ISC", + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "../../node_modules/glob-parent": { + "version": "6.0.2", + "dev": true, + "license": "ISC", + "dependencies": { + "is-glob": "^4.0.3" + }, + "engines": { + "node": ">=10.13.0" + } + }, + "../../node_modules/glob/node_modules/brace-expansion": { + "version": "1.1.11", + "dev": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "../../node_modules/glob/node_modules/minimatch": { + "version": "3.1.2", + "dev": true, + "license": "ISC", + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "../../node_modules/globals": { + "version": "13.23.0", + "dev": true, + "license": "MIT", + "dependencies": { + "type-fest": "^0.20.2" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/globby": { + "version": "11.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "array-union": "^2.1.0", + "dir-glob": "^3.0.1", + "fast-glob": "^3.2.9", + "ignore": "^5.2.0", + "merge2": "^1.4.1", + "slash": "^3.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/graceful-fs": { + "version": "4.2.11", + "dev": true, + "license": "ISC" + }, + "../../node_modules/graphemer": { + "version": "1.4.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/has-flag": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "../../node_modules/html-escaper": { + "version": "2.0.2", + "dev": true, + "license": "MIT" + }, + "../../node_modules/human-signals": { + "version": "5.0.0", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=16.17.0" + } + }, + "../../node_modules/ieee754": { + "version": "1.2.1", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "BSD-3-Clause" + }, + "../../node_modules/ignore": { + "version": "5.3.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 4" + } + }, + "../../node_modules/import-fresh": { + "version": "3.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "parent-module": "^1.0.0", + "resolve-from": "^4.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/imurmurhash": { + "version": "0.1.4", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.19" + } + }, + "../../node_modules/inflight": { + "version": "1.0.6", + "dev": true, + "license": "ISC", + "dependencies": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "../../node_modules/inherits": { + "version": "2.0.4", + "dev": true, + "license": "ISC" + }, + "../../node_modules/is-extglob": { + "version": "2.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "../../node_modules/is-glob": { + "version": "4.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "is-extglob": "^2.1.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "../../node_modules/is-number": { + "version": "7.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.12.0" + } + }, + "../../node_modules/is-path-inside": { + "version": "3.0.3", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "../../node_modules/is-stream": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/isarray": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/isexe": { + "version": "2.0.0", + "dev": true, + "license": "ISC" + }, + "../../node_modules/istanbul-lib-coverage": { + "version": "3.2.2", + "dev": true, + "license": "BSD-3-Clause", + "engines": { + "node": ">=8" + } + }, + "../../node_modules/istanbul-lib-report": { + "version": "3.0.1", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "istanbul-lib-coverage": "^3.0.0", + "make-dir": "^4.0.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + } + }, + "../../node_modules/istanbul-lib-source-maps": { + "version": "5.0.4", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "@jridgewell/trace-mapping": "^0.3.23", + "debug": "^4.1.1", + "istanbul-lib-coverage": "^3.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "../../node_modules/istanbul-reports": { + "version": "3.1.7", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "html-escaper": "^2.0.0", + "istanbul-lib-report": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "../../node_modules/js-tokens": { + "version": "4.0.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/js-yaml": { + "version": "4.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "argparse": "^2.0.1" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } + }, + "../../node_modules/json-buffer": { + "version": "3.0.1", + "dev": true, + "license": "MIT" + }, + "../../node_modules/json-schema-traverse": { + "version": "0.4.1", + "dev": true, + "license": "MIT" + }, + "../../node_modules/json-stable-stringify-without-jsonify": { + "version": "1.0.1", + "dev": true, + "license": "MIT" + }, + "../../node_modules/jsonc-parser": { + "version": "3.2.1", + "dev": true, + "license": "MIT" + }, + "../../node_modules/keyv": { + "version": "4.5.4", + "dev": true, + "license": "MIT", + "dependencies": { + "json-buffer": "3.0.1" + } + }, + "../../node_modules/lazystream": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "readable-stream": "^2.0.5" + }, + "engines": { + "node": ">= 0.6.3" + } + }, + "../../node_modules/lazystream/node_modules/readable-stream": { + "version": "2.3.8", + "dev": true, + "license": "MIT", + "dependencies": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "../../node_modules/lazystream/node_modules/safe-buffer": { + "version": "5.1.2", + "dev": true, + "license": "MIT" + }, + "../../node_modules/lazystream/node_modules/string_decoder": { + "version": "1.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "../../node_modules/levn": { + "version": "0.4.1", + "dev": true, + "license": "MIT", + "dependencies": { + "prelude-ls": "^1.2.1", + "type-check": "~0.4.0" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "../../node_modules/local-pkg": { + "version": "0.5.0", + "dev": true, + "license": "MIT", + "dependencies": { + "mlly": "^1.4.2", + "pkg-types": "^1.0.3" + }, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/antfu" + } + }, + "../../node_modules/locate-path": { + "version": "6.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "p-locate": "^5.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/lodash.defaults": { + "version": "4.2.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/lodash.difference": { + "version": "4.5.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/lodash.flatten": { + "version": "4.4.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/lodash.isplainobject": { + "version": "4.0.6", + "dev": true, + "license": "MIT" + }, + "../../node_modules/lodash.merge": { + "version": "4.6.2", + "dev": true, + "license": "MIT" + }, + "../../node_modules/lodash.union": { + "version": "4.6.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/long": { + "version": "5.2.3", + "license": "Apache-2.0" + }, + "../../node_modules/loose-envify": { + "version": "1.4.0", + "dev": true, + "license": "MIT", + "dependencies": { + "js-tokens": "^3.0.0 || ^4.0.0" + }, + "bin": { + "loose-envify": "cli.js" + } + }, + "../../node_modules/loupe": { + "version": "2.3.7", + "dev": true, + "license": "MIT", + "dependencies": { + "get-func-name": "^2.0.1" + } + }, + "../../node_modules/lru-cache": { + "version": "6.0.0", + "dev": true, + "license": "ISC", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "../../node_modules/lunr": { + "version": "2.3.9", + "dev": true, + "license": "MIT" + }, + "../../node_modules/magic-string": { + "version": "0.30.10", + "dev": true, + "license": "MIT", + "dependencies": { + "@jridgewell/sourcemap-codec": "^1.4.15" + } + }, + "../../node_modules/magicast": { + "version": "0.3.4", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/parser": "^7.24.4", + "@babel/types": "^7.24.0", + "source-map-js": "^1.2.0" + } + }, + "../../node_modules/make-dir": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "semver": "^7.5.3" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/marked": { + "version": "4.3.0", + "dev": true, + "license": "MIT", + "bin": { + "marked": "bin/marked.js" + }, + "engines": { + "node": ">= 12" + } + }, + "../../node_modules/merge-stream": { + "version": "2.0.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/merge2": { + "version": "1.4.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 8" + } + }, + "../../node_modules/micromatch": { + "version": "4.0.5", + "dev": true, + "license": "MIT", + "dependencies": { + "braces": "^3.0.2", + "picomatch": "^2.3.1" + }, + "engines": { + "node": ">=8.6" + } + }, + "../../node_modules/mimic-fn": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/minimatch": { + "version": "9.0.4", + "dev": true, + "license": "ISC", + "dependencies": { + "brace-expansion": "^2.0.1" + }, + "engines": { + "node": ">=16 || 14 >=14.17" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "../../node_modules/mkdirp": { + "version": "1.0.4", + "dev": true, + "license": "MIT", + "bin": { + "mkdirp": "bin/cmd.js" + }, + "engines": { + "node": ">=10" + } + }, + "../../node_modules/mkdirp-classic": { + "version": "0.5.3", + "dev": true, + "license": "MIT" + }, + "../../node_modules/mlly": { + "version": "1.7.0", + "dev": true, + "license": "MIT", + "dependencies": { + "acorn": "^8.11.3", + "pathe": "^1.1.2", + "pkg-types": "^1.1.0", + "ufo": "^1.5.3" + } + }, + "../../node_modules/ms": { + "version": "2.1.2", + "dev": true, + "license": "MIT" + }, + "../../node_modules/nan": { + "version": "2.18.0", + "dev": true, + "license": "MIT", + "optional": true + }, + "../../node_modules/nanoid": { + "version": "3.3.7", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "bin": { + "nanoid": "bin/nanoid.cjs" + }, + "engines": { + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" + } + }, + "../../node_modules/natural-compare": { + "version": "1.4.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/node-fetch": { + "version": "2.7.0", + "dev": true, + "license": "MIT", + "dependencies": { + "whatwg-url": "^5.0.0" + }, + "engines": { + "node": "4.x || >=6.0.0" + }, + "peerDependencies": { + "encoding": "^0.1.0" + }, + "peerDependenciesMeta": { + "encoding": { + "optional": true + } + } + }, + "../../node_modules/normalize-path": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "../../node_modules/npm-run-path": { + "version": "5.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "path-key": "^4.0.0" + }, + "engines": { + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/npm-run-path/node_modules/path-key": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/once": { + "version": "1.4.0", + "dev": true, + "license": "ISC", + "dependencies": { + "wrappy": "1" + } + }, + "../../node_modules/onetime": { + "version": "6.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "mimic-fn": "^4.0.0" + }, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/optionator": { + "version": "0.9.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@aashutoshrathi/word-wrap": "^1.2.3", + "deep-is": "^0.1.3", + "fast-levenshtein": "^2.0.6", + "levn": "^0.4.1", + "prelude-ls": "^1.2.1", + "type-check": "^0.4.0" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "../../node_modules/p-limit": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "yocto-queue": "^0.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/p-locate": { + "version": "5.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "p-limit": "^3.0.2" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/parent-module": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "callsites": "^3.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "../../node_modules/path-exists": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "../../node_modules/path-is-absolute": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "../../node_modules/path-key": { + "version": "3.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "../../node_modules/path-type": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "../../node_modules/pathe": { + "version": "1.1.2", + "dev": true, + "license": "MIT" + }, + "../../node_modules/pathval": { + "version": "1.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": "*" + } + }, + "../../node_modules/picocolors": { + "version": "1.0.0", + "dev": true, + "license": "ISC" + }, + "../../node_modules/picomatch": { + "version": "2.3.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "../../node_modules/pkg-types": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "confbox": "^0.1.7", + "mlly": "^1.6.1", + "pathe": "^1.1.2" + } + }, + "../../node_modules/playwright": { + "version": "1.40.1", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "playwright-core": "1.40.1" + }, + "bin": { + "playwright": "cli.js" + }, + "engines": { + "node": ">=16" + }, + "optionalDependencies": { + "fsevents": "2.3.2" + } + }, + "../../node_modules/playwright-core": { + "version": "1.40.1", + "dev": true, + "license": "Apache-2.0", + "bin": { + "playwright-core": "cli.js" + }, + "engines": { + "node": ">=16" + } + }, + "../../node_modules/postcss": { + "version": "8.4.38", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "dependencies": { + "nanoid": "^3.3.7", + "picocolors": "^1.0.0", + "source-map-js": "^1.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "../../node_modules/prelude-ls": { + "version": "1.2.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.8.0" + } + }, + "../../node_modules/prettier": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "bin": { + "prettier": "bin/prettier.cjs" + }, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/prettier/prettier?sponsor=1" + } + }, + "../../node_modules/prettier-plugin-tailwindcss": { + "version": "0.5.7", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=14.21.3" + }, + "peerDependencies": { + "@ianvs/prettier-plugin-sort-imports": "*", + "@prettier/plugin-pug": "*", + "@shopify/prettier-plugin-liquid": "*", + "@shufo/prettier-plugin-blade": "*", + "@trivago/prettier-plugin-sort-imports": "*", + "prettier": "^3.0", + "prettier-plugin-astro": "*", + "prettier-plugin-css-order": "*", + "prettier-plugin-import-sort": "*", + "prettier-plugin-jsdoc": "*", + "prettier-plugin-organize-attributes": "*", + "prettier-plugin-organize-imports": "*", + "prettier-plugin-style-order": "*", + "prettier-plugin-svelte": "*" + }, + "peerDependenciesMeta": { + "@ianvs/prettier-plugin-sort-imports": { + "optional": true + }, + "@prettier/plugin-pug": { + "optional": true + }, + "@shopify/prettier-plugin-liquid": { + "optional": true + }, + "@shufo/prettier-plugin-blade": { + "optional": true + }, + "@trivago/prettier-plugin-sort-imports": { + "optional": true + }, + "prettier-plugin-astro": { + "optional": true + }, + "prettier-plugin-css-order": { + "optional": true + }, + "prettier-plugin-import-sort": { + "optional": true + }, + "prettier-plugin-jsdoc": { + "optional": true + }, + "prettier-plugin-marko": { + "optional": true + }, + "prettier-plugin-organize-attributes": { + "optional": true + }, + "prettier-plugin-organize-imports": { + "optional": true + }, + "prettier-plugin-style-order": { + "optional": true + }, + "prettier-plugin-svelte": { + "optional": true + }, + "prettier-plugin-twig-melody": { + "optional": true + } + } + }, + "../../node_modules/pretty-format": { + "version": "29.7.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/schemas": "^29.6.3", + "ansi-styles": "^5.0.0", + "react-is": "^18.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "../../node_modules/pretty-format/node_modules/ansi-styles": { + "version": "5.2.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "../../node_modules/process-nextick-args": { + "version": "2.0.1", + "dev": true, + "license": "MIT" + }, + "../../node_modules/proper-lockfile": { + "version": "4.1.2", + "dev": true, + "license": "MIT", + "dependencies": { + "graceful-fs": "^4.2.4", + "retry": "^0.12.0", + "signal-exit": "^3.0.2" + } + }, + "../../node_modules/properties-reader": { + "version": "2.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "mkdirp": "^1.0.4" + }, + "engines": { + "node": ">=14" + }, + "funding": { + "type": "github", + "url": "https://github.com/steveukx/properties?sponsor=1" + } + }, + "../../node_modules/protobufjs": { + "version": "7.2.5", + "hasInstallScript": true, + "license": "BSD-3-Clause", + "dependencies": { + "@protobufjs/aspromise": "^1.1.2", + "@protobufjs/base64": "^1.1.2", + "@protobufjs/codegen": "^2.0.4", + "@protobufjs/eventemitter": "^1.1.0", + "@protobufjs/fetch": "^1.1.0", + "@protobufjs/float": "^1.0.2", + "@protobufjs/inquire": "^1.1.0", + "@protobufjs/path": "^1.1.2", + "@protobufjs/pool": "^1.1.0", + "@protobufjs/utf8": "^1.1.0", + "@types/node": ">=13.7.0", + "long": "^5.0.0" + }, + "engines": { + "node": ">=12.0.0" + } + }, + "../../node_modules/pump": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "end-of-stream": "^1.1.0", + "once": "^1.3.1" + } + }, + "../../node_modules/punycode": { + "version": "2.3.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "../../node_modules/queue-microtask": { + "version": "1.2.3", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT" + }, + "../../node_modules/queue-tick": { + "version": "1.0.1", + "dev": true, + "license": "MIT" + }, + "../../node_modules/react": { + "version": "18.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "loose-envify": "^1.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "../../node_modules/react-is": { + "version": "18.3.1", + "dev": true, + "license": "MIT" + }, + "../../node_modules/readable-stream": { + "version": "3.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "../../node_modules/readdir-glob": { + "version": "1.1.3", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "minimatch": "^5.1.0" + } + }, + "../../node_modules/readdir-glob/node_modules/minimatch": { + "version": "5.1.6", + "dev": true, + "license": "ISC", + "dependencies": { + "brace-expansion": "^2.0.1" + }, + "engines": { + "node": ">=10" + } + }, + "../../node_modules/resolve-from": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "../../node_modules/retry": { + "version": "0.12.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 4" + } + }, + "../../node_modules/reusify": { + "version": "1.0.4", + "dev": true, + "license": "MIT", + "engines": { + "iojs": ">=1.0.0", + "node": ">=0.10.0" + } + }, + "../../node_modules/rimraf": { + "version": "3.0.2", + "dev": true, + "license": "ISC", + "dependencies": { + "glob": "^7.1.3" + }, + "bin": { + "rimraf": "bin.js" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "../../node_modules/rollup": { + "version": "4.17.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/estree": "1.0.5" + }, + "bin": { + "rollup": "dist/bin/rollup" + }, + "engines": { + "node": ">=18.0.0", + "npm": ">=8.0.0" + }, + "optionalDependencies": { + "@rollup/rollup-android-arm-eabi": "4.17.2", + "@rollup/rollup-android-arm64": "4.17.2", + "@rollup/rollup-darwin-arm64": "4.17.2", + "@rollup/rollup-darwin-x64": "4.17.2", + "@rollup/rollup-linux-arm-gnueabihf": "4.17.2", + "@rollup/rollup-linux-arm-musleabihf": "4.17.2", + "@rollup/rollup-linux-arm64-gnu": "4.17.2", + "@rollup/rollup-linux-arm64-musl": "4.17.2", + "@rollup/rollup-linux-powerpc64le-gnu": "4.17.2", + "@rollup/rollup-linux-riscv64-gnu": "4.17.2", + "@rollup/rollup-linux-s390x-gnu": "4.17.2", + "@rollup/rollup-linux-x64-gnu": "4.17.2", + "@rollup/rollup-linux-x64-musl": "4.17.2", + "@rollup/rollup-win32-arm64-msvc": "4.17.2", + "@rollup/rollup-win32-ia32-msvc": "4.17.2", + "@rollup/rollup-win32-x64-msvc": "4.17.2", + "fsevents": "~2.3.2" + } + }, + "../../node_modules/run-parallel": { + "version": "1.2.0", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "dependencies": { + "queue-microtask": "^1.2.2" + } + }, + "../../node_modules/rxjs": { + "version": "7.8.1", + "dev": true, + "license": "Apache-2.0", + "optional": true, + "dependencies": { + "tslib": "^2.1.0" + } + }, + "../../node_modules/safe-buffer": { + "version": "5.2.1", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT" + }, + "../../node_modules/safer-buffer": { + "version": "2.1.2", + "dev": true, + "license": "MIT" + }, + "../../node_modules/semver": { + "version": "7.6.0", + "dev": true, + "license": "ISC", + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "../../node_modules/shebang-command": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "shebang-regex": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "../../node_modules/shebang-regex": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "../../node_modules/shiki": { + "version": "0.14.7", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-sequence-parser": "^1.1.0", + "jsonc-parser": "^3.2.0", + "vscode-oniguruma": "^1.7.0", + "vscode-textmate": "^8.0.0" + } + }, + "../../node_modules/siginfo": { + "version": "2.0.0", + "dev": true, + "license": "ISC" + }, + "../../node_modules/signal-exit": { + "version": "3.0.7", + "dev": true, + "license": "ISC" + }, + "../../node_modules/slash": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "../../node_modules/source-map-js": { + "version": "1.2.0", + "dev": true, + "license": "BSD-3-Clause", + "engines": { + "node": ">=0.10.0" + } + }, + "../../node_modules/split-ca": { + "version": "1.0.1", + "dev": true, + "license": "ISC" + }, + "../../node_modules/ssh-remote-port-forward": { + "version": "1.0.4", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/ssh2": "^0.5.48", + "ssh2": "^1.4.0" + } + }, + "../../node_modules/ssh-remote-port-forward/node_modules/@types/ssh2": { + "version": "0.5.52", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*", + "@types/ssh2-streams": "*" + } + }, + "../../node_modules/ssh2": { + "version": "1.14.0", + "dev": true, + "hasInstallScript": true, + "dependencies": { + "asn1": "^0.2.6", + "bcrypt-pbkdf": "^1.0.2" + }, + "engines": { + "node": ">=10.16.0" + }, + "optionalDependencies": { + "cpu-features": "~0.0.8", + "nan": "^2.17.0" + } + }, + "../../node_modules/stackback": { + "version": "0.0.2", + "dev": true, + "license": "MIT" + }, + "../../node_modules/std-env": { + "version": "3.7.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/streamx": { + "version": "2.15.5", + "dev": true, + "license": "MIT", + "dependencies": { + "fast-fifo": "^1.1.0", + "queue-tick": "^1.0.1" + } + }, + "../../node_modules/string_decoder": { + "version": "1.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "safe-buffer": "~5.2.0" + } + }, + "../../node_modules/strip-ansi": { + "version": "6.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "../../node_modules/strip-final-newline": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/strip-json-comments": { + "version": "3.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/strip-literal": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "js-tokens": "^9.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/antfu" + } + }, + "../../node_modules/strip-literal/node_modules/js-tokens": { + "version": "9.0.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/supports-color": { + "version": "7.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "../../node_modules/tar-fs": { + "version": "3.0.4", + "dev": true, + "license": "MIT", + "dependencies": { + "mkdirp-classic": "^0.5.2", + "pump": "^3.0.0", + "tar-stream": "^3.1.5" + } + }, + "../../node_modules/tar-fs/node_modules/tar-stream": { + "version": "3.1.6", + "dev": true, + "license": "MIT", + "dependencies": { + "b4a": "^1.6.4", + "fast-fifo": "^1.2.0", + "streamx": "^2.15.0" + } + }, + "../../node_modules/tar-stream": { + "version": "2.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "bl": "^4.0.3", + "end-of-stream": "^1.4.1", + "fs-constants": "^1.0.0", + "inherits": "^2.0.3", + "readable-stream": "^3.1.1" + }, + "engines": { + "node": ">=6" + } + }, + "../../node_modules/test-exclude": { + "version": "6.0.0", + "dev": true, + "license": "ISC", + "dependencies": { + "@istanbuljs/schema": "^0.1.2", + "glob": "^7.1.4", + "minimatch": "^3.0.4" + }, + "engines": { + "node": ">=8" + } + }, + "../../node_modules/test-exclude/node_modules/brace-expansion": { + "version": "1.1.11", + "dev": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "../../node_modules/test-exclude/node_modules/minimatch": { + "version": "3.1.2", + "dev": true, + "license": "ISC", + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "../../node_modules/testcontainers": { + "version": "10.3.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@balena/dockerignore": "^1.0.2", + "@types/dockerode": "^3.3.21", + "archiver": "^5.3.2", + "async-lock": "^1.4.0", + "byline": "^5.0.0", + "debug": "^4.3.4", + "docker-compose": "^0.24.2", + "dockerode": "^3.3.5", + "get-port": "^5.1.1", + "node-fetch": "^2.7.0", + "proper-lockfile": "^4.1.2", + "properties-reader": "^2.3.0", + "ssh-remote-port-forward": "^1.0.4", + "tar-fs": "^3.0.4", + "tmp": "^0.2.1" + } + }, + "../../node_modules/text-table": { + "version": "0.2.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/tinybench": { + "version": "2.8.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/tinypool": { + "version": "0.8.4", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=14.0.0" + } + }, + "../../node_modules/tinyspy": { + "version": "2.2.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=14.0.0" + } + }, + "../../node_modules/tmp": { + "version": "0.2.1", + "dev": true, + "license": "MIT", + "dependencies": { + "rimraf": "^3.0.0" + }, + "engines": { + "node": ">=8.17.0" + } + }, + "../../node_modules/to-fast-properties": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "../../node_modules/to-regex-range": { + "version": "5.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "is-number": "^7.0.0" + }, + "engines": { + "node": ">=8.0" + } + }, + "../../node_modules/tr46": { + "version": "0.0.3", + "dev": true, + "license": "MIT" + }, + "../../node_modules/ts-api-utils": { + "version": "1.3.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=16" + }, + "peerDependencies": { + "typescript": ">=4.2.0" + } + }, + "../../node_modules/ts-poet": { + "version": "6.6.0", + "license": "Apache-2.0", + "dependencies": { + "dprint-node": "^1.0.7" + } + }, + "../../node_modules/ts-proto": { + "version": "1.165.0", + "license": "ISC", + "dependencies": { + "case-anything": "^2.1.13", + "protobufjs": "^7.2.4", + "ts-poet": "^6.5.0", + "ts-proto-descriptors": "1.15.0" + }, + "bin": { + "protoc-gen-ts_proto": "protoc-gen-ts_proto" + } + }, + "../../node_modules/ts-proto-descriptors": { + "version": "1.15.0", + "license": "ISC", + "dependencies": { + "long": "^5.2.3", + "protobufjs": "^7.2.4" + } + }, + "../../node_modules/tslib": { + "version": "2.6.2", + "dev": true, + "license": "0BSD", + "optional": true + }, + "../../node_modules/tweetnacl": { + "version": "0.14.5", + "dev": true, + "license": "Unlicense" + }, + "../../node_modules/type-check": { + "version": "0.4.0", + "dev": true, + "license": "MIT", + "dependencies": { + "prelude-ls": "^1.2.1" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "../../node_modules/type-detect": { + "version": "4.0.8", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "../../node_modules/type-fest": { + "version": "0.20.2", + "dev": true, + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/typed-emitter": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "optionalDependencies": { + "rxjs": "*" + } + }, + "../../node_modules/typedoc": { + "version": "0.25.13", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "lunr": "^2.3.9", + "marked": "^4.3.0", + "minimatch": "^9.0.3", + "shiki": "^0.14.7" + }, + "bin": { + "typedoc": "bin/typedoc" + }, + "engines": { + "node": ">= 16" + }, + "peerDependencies": { + "typescript": "4.6.x || 4.7.x || 4.8.x || 4.9.x || 5.0.x || 5.1.x || 5.2.x || 5.3.x || 5.4.x" + } + }, + "../../node_modules/typedoc-plugin-external-resolver": { + "version": "1.0.3", + "dev": true, + "license": "MIT", + "peerDependencies": { + "typedoc": "0.25.x", + "typescript": "4.x || 5.x" + } + }, + "../../node_modules/typedoc-plugin-mdn-links": { + "version": "3.1.6", + "dev": true, + "license": "MIT", + "peerDependencies": { + "typedoc": ">= 0.23.14 || 0.24.x || 0.25.x" + } + }, + "../../node_modules/typescript": { + "version": "4.9.5", + "dev": true, + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=4.2.0" + } + }, + "../../node_modules/ufo": { + "version": "1.5.3", + "dev": true, + "license": "MIT" + }, + "../../node_modules/undici-types": { + "version": "5.26.5", + "license": "MIT" + }, + "../../node_modules/uri-js": { + "version": "4.4.1", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "punycode": "^2.1.0" + } + }, + "../../node_modules/util-deprecate": { + "version": "1.0.2", + "dev": true, + "license": "MIT" + }, + "../../node_modules/uuid": { + "version": "9.0.1", + "funding": [ + "https://github.com/sponsors/broofa", + "https://github.com/sponsors/ctavan" + ], + "license": "MIT", + "bin": { + "uuid": "dist/bin/uuid" + } + }, + "../../node_modules/vite": { + "version": "5.2.11", + "dev": true, + "license": "MIT", + "dependencies": { + "esbuild": "^0.20.1", + "postcss": "^8.4.38", + "rollup": "^4.13.0" + }, + "bin": { + "vite": "bin/vite.js" + }, + "engines": { + "node": "^18.0.0 || >=20.0.0" + }, + "funding": { + "url": "https://github.com/vitejs/vite?sponsor=1" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + }, + "peerDependencies": { + "@types/node": "^18.0.0 || >=20.0.0", + "less": "*", + "lightningcss": "^1.21.0", + "sass": "*", + "stylus": "*", + "sugarss": "*", + "terser": "^5.4.0" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "less": { + "optional": true + }, + "lightningcss": { + "optional": true + }, + "sass": { + "optional": true + }, + "stylus": { + "optional": true + }, + "sugarss": { + "optional": true + }, + "terser": { + "optional": true + } + } + }, + "../../node_modules/vite-node": { + "version": "1.6.0", + "dev": true, + "license": "MIT", + "dependencies": { + "cac": "^6.7.14", + "debug": "^4.3.4", + "pathe": "^1.1.1", + "picocolors": "^1.0.0", + "vite": "^5.0.0" + }, + "bin": { + "vite-node": "vite-node.mjs" + }, + "engines": { + "node": "^18.0.0 || >=20.0.0" + }, + "funding": { + "url": "https://opencollective.com/vitest" + } + }, + "../../node_modules/vite/node_modules/fsevents": { + "version": "2.3.3", + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "../../node_modules/vitest": { + "version": "1.6.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@vitest/expect": "1.6.0", + "@vitest/runner": "1.6.0", + "@vitest/snapshot": "1.6.0", + "@vitest/spy": "1.6.0", + "@vitest/utils": "1.6.0", + "acorn-walk": "^8.3.2", + "chai": "^4.3.10", + "debug": "^4.3.4", + "execa": "^8.0.1", + "local-pkg": "^0.5.0", + "magic-string": "^0.30.5", + "pathe": "^1.1.1", + "picocolors": "^1.0.0", + "std-env": "^3.5.0", + "strip-literal": "^2.0.0", + "tinybench": "^2.5.1", + "tinypool": "^0.8.3", + "vite": "^5.0.0", + "vite-node": "1.6.0", + "why-is-node-running": "^2.2.2" + }, + "bin": { + "vitest": "vitest.mjs" + }, + "engines": { + "node": "^18.0.0 || >=20.0.0" + }, + "funding": { + "url": "https://opencollective.com/vitest" + }, + "peerDependencies": { + "@edge-runtime/vm": "*", + "@types/node": "^18.0.0 || >=20.0.0", + "@vitest/browser": "1.6.0", + "@vitest/ui": "1.6.0", + "happy-dom": "*", + "jsdom": "*" + }, + "peerDependenciesMeta": { + "@edge-runtime/vm": { + "optional": true + }, + "@types/node": { + "optional": true + }, + "@vitest/browser": { + "optional": true + }, + "@vitest/ui": { + "optional": true + }, + "happy-dom": { + "optional": true + }, + "jsdom": { + "optional": true + } + } + }, + "../../node_modules/vscode-oniguruma": { + "version": "1.7.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/vscode-textmate": { + "version": "8.0.0", + "dev": true, + "license": "MIT" + }, + "../../node_modules/webidl-conversions": { + "version": "3.0.1", + "dev": true, + "license": "BSD-2-Clause" + }, + "../../node_modules/whatwg-url": { + "version": "5.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "tr46": "~0.0.3", + "webidl-conversions": "^3.0.0" + } + }, + "../../node_modules/which": { + "version": "2.0.2", + "dev": true, + "license": "ISC", + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" + }, + "engines": { + "node": ">= 8" + } + }, + "../../node_modules/why-is-node-running": { + "version": "2.2.2", + "dev": true, + "license": "MIT", + "dependencies": { + "siginfo": "^2.0.0", + "stackback": "0.0.2" + }, + "bin": { + "why-is-node-running": "cli.js" + }, + "engines": { + "node": ">=8" + } + }, + "../../node_modules/wrappy": { + "version": "1.0.2", + "dev": true, + "license": "ISC" + }, + "../../node_modules/yallist": { + "version": "4.0.0", + "dev": true, + "license": "ISC" + }, + "../../node_modules/yaml": { + "version": "2.3.4", + "dev": true, + "license": "ISC", + "engines": { + "node": ">= 14" + } + }, + "../../node_modules/yocto-queue": { + "version": "0.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "../../node_modules/zip-stream": { + "version": "4.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "archiver-utils": "^3.0.4", + "compress-commons": "^4.1.2", + "readable-stream": "^3.6.0" + }, + "engines": { + "node": ">= 10" + } + }, + "../../node_modules/zip-stream/node_modules/archiver-utils": { + "version": "3.0.4", + "dev": true, + "license": "MIT", + "dependencies": { + "glob": "^7.2.3", + "graceful-fs": "^4.2.0", + "lazystream": "^1.0.0", + "lodash.defaults": "^4.2.0", + "lodash.difference": "^4.5.0", + "lodash.flatten": "^4.4.0", + "lodash.isplainobject": "^4.0.6", + "lodash.union": "^4.6.0", + "normalize-path": "^3.0.0", + "readable-stream": "^3.6.0" + }, + "engines": { + "node": ">= 10" + } + }, + "../../node_modules/zod": { + "version": "3.23.6", + "dev": true, + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/colinhacks" + } + }, + "node_modules/@ampproject/remapping": { + "version": "2.3.0", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.24" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@babel/code-frame": { + "version": "7.24.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/highlight": "^7.24.2", + "picocolors": "^1.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/compat-data": { + "version": "7.24.4", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/core": { "version": "7.24.5", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.24.5.tgz", - "integrity": "sha512-7aaBLeDQ4zYcUFDUD41lJc1fG8+5IU9DaNSJAgal866FGvmD5EbWQgnEC6kO1gGLsX0esNkfnJSndbTXA3r7UA==", "dev": true, + "license": "MIT", "dependencies": { + "@ampproject/remapping": "^2.2.0", "@babel/code-frame": "^7.24.2", "@babel/generator": "^7.24.5", - "@babel/helper-environment-visitor": "^7.22.20", - "@babel/helper-function-name": "^7.23.0", - "@babel/helper-hoist-variables": "^7.22.5", - "@babel/helper-split-export-declaration": "^7.24.5", + "@babel/helper-compilation-targets": "^7.23.6", + "@babel/helper-module-transforms": "^7.24.5", + "@babel/helpers": "^7.24.5", "@babel/parser": "^7.24.5", + "@babel/template": "^7.24.0", + "@babel/traverse": "^7.24.5", "@babel/types": "^7.24.5", - "debug": "^4.3.1", - "globals": "^11.1.0" + "convert-source-map": "^2.0.0", + "debug": "^4.1.0", + "gensync": "^1.0.0-beta.2", + "json5": "^2.2.3", + "semver": "^6.3.1" }, "engines": { "node": ">=6.9.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/babel" } }, - "node_modules/@babel/types": { + "node_modules/@babel/core/node_modules/semver": { + "version": "6.3.1", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/@babel/generator": { "version": "7.24.5", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.24.5.tgz", - "integrity": "sha512-6mQNsaLeXTw0nxYUYu+NSa4Hx4BlF1x1x8/PMFbiR+GBSr+2DkECc69b8hgy2frEodNcvPffeH8YfWd3LI6jhQ==", "dev": true, + "license": "MIT", "dependencies": { - "@babel/helper-string-parser": "^7.24.1", - "@babel/helper-validator-identifier": "^7.24.5", - "to-fast-properties": "^2.0.0" + "@babel/types": "^7.24.5", + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.25", + "jsesc": "^2.5.1" }, "engines": { "node": ">=6.9.0" } }, - "node_modules/@esbuild/aix-ppc64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.20.2.tgz", - "integrity": "sha512-D+EBOJHXdNZcLJRBkhENNG8Wji2kgc9AZ9KiPr1JuZjsNtyHzrsfLRrY0tk2H2aoFu6RANO1y1iPPUCDYWkb5g==", - "cpu": [ - "ppc64" - ], - "dev": true, - "optional": true, - "os": [ - "aix" - ], - "engines": { - "node": ">=12" - } - }, - "node_modules/@esbuild/android-arm": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.20.2.tgz", - "integrity": "sha512-t98Ra6pw2VaDhqNWO2Oph2LXbz/EJcnLmKLGBJwEwXX/JAN83Fym1rU8l0JUWK6HkIbWONCSSatf4sf2NBRx/w==", - "cpu": [ - "arm" - ], + "node_modules/@babel/helper-compilation-targets": { + "version": "7.23.6", "dev": true, - "optional": true, - "os": [ - "android" - ], + "license": "MIT", + "dependencies": { + "@babel/compat-data": "^7.23.5", + "@babel/helper-validator-option": "^7.23.5", + "browserslist": "^4.22.2", + "lru-cache": "^5.1.1", + "semver": "^6.3.1" + }, "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/android-arm64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.20.2.tgz", - "integrity": "sha512-mRzjLacRtl/tWU0SvD8lUEwb61yP9cqQo6noDZP/O8VkwafSYwZ4yWy24kan8jE/IMERpYncRt2dw438LP3Xmg==", - "cpu": [ - "arm64" - ], + "node_modules/@babel/helper-compilation-targets/node_modules/semver": { + "version": "6.3.1", "dev": true, - "optional": true, - "os": [ - "android" - ], - "engines": { - "node": ">=12" + "license": "ISC", + "bin": { + "semver": "bin/semver.js" } }, - "node_modules/@esbuild/android-x64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.20.2.tgz", - "integrity": "sha512-btzExgV+/lMGDDa194CcUQm53ncxzeBrWJcncOBxuC6ndBkKxnHdFJn86mCIgTELsooUmwUm9FkhSp5HYu00Rg==", - "cpu": [ - "x64" - ], + "node_modules/@babel/helper-environment-visitor": { + "version": "7.22.20", "dev": true, - "optional": true, - "os": [ - "android" - ], + "license": "MIT", "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/darwin-arm64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.20.2.tgz", - "integrity": "sha512-4J6IRT+10J3aJH3l1yzEg9y3wkTDgDk7TSDFX+wKFiWjqWp/iCfLIYzGyasx9l0SAFPT1HwSCR+0w/h1ES/MjA==", - "cpu": [ - "arm64" - ], + "node_modules/@babel/helper-function-name": { + "version": "7.23.0", "dev": true, - "optional": true, - "os": [ - "darwin" - ], + "license": "MIT", + "dependencies": { + "@babel/template": "^7.22.15", + "@babel/types": "^7.23.0" + }, "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/darwin-x64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.20.2.tgz", - "integrity": "sha512-tBcXp9KNphnNH0dfhv8KYkZhjc+H3XBkF5DKtswJblV7KlT9EI2+jeA8DgBjp908WEuYll6pF+UStUCfEpdysA==", - "cpu": [ - "x64" - ], + "node_modules/@babel/helper-hoist-variables": { + "version": "7.22.5", "dev": true, - "optional": true, - "os": [ - "darwin" - ], + "license": "MIT", + "dependencies": { + "@babel/types": "^7.22.5" + }, "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/freebsd-arm64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.20.2.tgz", - "integrity": "sha512-d3qI41G4SuLiCGCFGUrKsSeTXyWG6yem1KcGZVS+3FYlYhtNoNgYrWcvkOoaqMhwXSMrZRl69ArHsGJ9mYdbbw==", - "cpu": [ - "arm64" - ], + "node_modules/@babel/helper-module-imports": { + "version": "7.24.3", "dev": true, - "optional": true, - "os": [ - "freebsd" - ], + "license": "MIT", + "dependencies": { + "@babel/types": "^7.24.0" + }, "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/freebsd-x64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.20.2.tgz", - "integrity": "sha512-d+DipyvHRuqEeM5zDivKV1KuXn9WeRX6vqSqIDgwIfPQtwMP4jaDsQsDncjTDDsExT4lR/91OLjRo8bmC1e+Cw==", - "cpu": [ - "x64" - ], + "node_modules/@babel/helper-module-transforms": { + "version": "7.24.5", "dev": true, - "optional": true, - "os": [ - "freebsd" - ], + "license": "MIT", + "dependencies": { + "@babel/helper-environment-visitor": "^7.22.20", + "@babel/helper-module-imports": "^7.24.3", + "@babel/helper-simple-access": "^7.24.5", + "@babel/helper-split-export-declaration": "^7.24.5", + "@babel/helper-validator-identifier": "^7.24.5" + }, "engines": { - "node": ">=12" + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" } }, - "node_modules/@esbuild/linux-arm": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.20.2.tgz", - "integrity": "sha512-VhLPeR8HTMPccbuWWcEUD1Az68TqaTYyj6nfE4QByZIQEQVWBB8vup8PpR7y1QHL3CpcF6xd5WVBU/+SBEvGTg==", - "cpu": [ - "arm" - ], + "node_modules/@babel/helper-plugin-utils": { + "version": "7.24.5", "dev": true, - "optional": true, - "os": [ - "linux" - ], + "license": "MIT", "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/linux-arm64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.20.2.tgz", - "integrity": "sha512-9pb6rBjGvTFNira2FLIWqDk/uaf42sSyLE8j1rnUpuzsODBq7FvpwHYZxQ/It/8b+QOS1RYfqgGFNLRI+qlq2A==", - "cpu": [ - "arm64" - ], + "node_modules/@babel/helper-simple-access": { + "version": "7.24.5", "dev": true, - "optional": true, - "os": [ - "linux" - ], + "license": "MIT", + "dependencies": { + "@babel/types": "^7.24.5" + }, "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/linux-ia32": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.20.2.tgz", - "integrity": "sha512-o10utieEkNPFDZFQm9CoP7Tvb33UutoJqg3qKf1PWVeeJhJw0Q347PxMvBgVVFgouYLGIhFYG0UGdBumROyiig==", - "cpu": [ - "ia32" - ], + "node_modules/@babel/helper-split-export-declaration": { + "version": "7.24.5", "dev": true, - "optional": true, - "os": [ - "linux" - ], + "license": "MIT", + "dependencies": { + "@babel/types": "^7.24.5" + }, "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/linux-loong64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.20.2.tgz", - "integrity": "sha512-PR7sp6R/UC4CFVomVINKJ80pMFlfDfMQMYynX7t1tNTeivQ6XdX5r2XovMmha/VjR1YN/HgHWsVcTRIMkymrgQ==", - "cpu": [ - "loong64" - ], + "node_modules/@babel/helper-string-parser": { + "version": "7.24.1", "dev": true, - "optional": true, - "os": [ - "linux" - ], + "license": "MIT", "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/linux-mips64el": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.20.2.tgz", - "integrity": "sha512-4BlTqeutE/KnOiTG5Y6Sb/Hw6hsBOZapOVF6njAESHInhlQAghVVZL1ZpIctBOoTFbQyGW+LsVYZ8lSSB3wkjA==", - "cpu": [ - "mips64el" - ], + "node_modules/@babel/helper-validator-identifier": { + "version": "7.24.5", "dev": true, - "optional": true, - "os": [ - "linux" - ], + "license": "MIT", "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/linux-ppc64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.20.2.tgz", - "integrity": "sha512-rD3KsaDprDcfajSKdn25ooz5J5/fWBylaaXkuotBDGnMnDP1Uv5DLAN/45qfnf3JDYyJv/ytGHQaziHUdyzaAg==", - "cpu": [ - "ppc64" - ], + "node_modules/@babel/helper-validator-option": { + "version": "7.23.5", "dev": true, - "optional": true, - "os": [ - "linux" - ], + "license": "MIT", "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/linux-riscv64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.20.2.tgz", - "integrity": "sha512-snwmBKacKmwTMmhLlz/3aH1Q9T8v45bKYGE3j26TsaOVtjIag4wLfWSiZykXzXuE1kbCE+zJRmwp+ZbIHinnVg==", - "cpu": [ - "riscv64" - ], + "node_modules/@babel/helpers": { + "version": "7.24.5", "dev": true, - "optional": true, - "os": [ - "linux" - ], + "license": "MIT", + "dependencies": { + "@babel/template": "^7.24.0", + "@babel/traverse": "^7.24.5", + "@babel/types": "^7.24.5" + }, "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/linux-s390x": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.20.2.tgz", - "integrity": "sha512-wcWISOobRWNm3cezm5HOZcYz1sKoHLd8VL1dl309DiixxVFoFe/o8HnwuIwn6sXre88Nwj+VwZUvJf4AFxkyrQ==", - "cpu": [ - "s390x" - ], + "node_modules/@babel/highlight": { + "version": "7.24.5", "dev": true, - "optional": true, - "os": [ - "linux" - ], + "license": "MIT", + "dependencies": { + "@babel/helper-validator-identifier": "^7.24.5", + "chalk": "^2.4.2", + "js-tokens": "^4.0.0", + "picocolors": "^1.0.0" + }, "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/linux-x64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.20.2.tgz", - "integrity": "sha512-1MdwI6OOTsfQfek8sLwgyjOXAu+wKhLEoaOLTjbijk6E2WONYpH9ZU2mNtR+lZ2B4uwr+usqGuVfFT9tMtGvGw==", - "cpu": [ - "x64" - ], + "node_modules/@babel/parser": { + "version": "7.24.5", "dev": true, - "optional": true, - "os": [ - "linux" - ], + "license": "MIT", + "bin": { + "parser": "bin/babel-parser.js" + }, "engines": { - "node": ">=12" + "node": ">=6.0.0" } }, - "node_modules/@esbuild/netbsd-x64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.20.2.tgz", - "integrity": "sha512-K8/DhBxcVQkzYc43yJXDSyjlFeHQJBiowJ0uVL6Tor3jGQfSGHNNJcWxNbOI8v5k82prYqzPuwkzHt3J1T1iZQ==", - "cpu": [ - "x64" - ], + "node_modules/@babel/plugin-transform-react-jsx-self": { + "version": "7.24.5", "dev": true, - "optional": true, - "os": [ - "netbsd" - ], + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.5" + }, "engines": { - "node": ">=12" + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@esbuild/openbsd-x64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.20.2.tgz", - "integrity": "sha512-eMpKlV0SThJmmJgiVyN9jTPJ2VBPquf6Kt/nAoo6DgHAoN57K15ZghiHaMvqjCye/uU4X5u3YSMgVBI1h3vKrQ==", - "cpu": [ - "x64" - ], + "node_modules/@babel/plugin-transform-react-jsx-source": { + "version": "7.24.1", "dev": true, - "optional": true, - "os": [ - "openbsd" - ], + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.0" + }, "engines": { - "node": ">=12" + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@esbuild/sunos-x64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.20.2.tgz", - "integrity": "sha512-2UyFtRC6cXLyejf/YEld4Hajo7UHILetzE1vsRcGL3earZEW77JxrFjH4Ez2qaTiEfMgAXxfAZCm1fvM/G/o8w==", - "cpu": [ - "x64" - ], + "node_modules/@babel/template": { + "version": "7.24.0", "dev": true, - "optional": true, - "os": [ - "sunos" - ], + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.23.5", + "@babel/parser": "^7.24.0", + "@babel/types": "^7.24.0" + }, "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/win32-arm64": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.20.2.tgz", - "integrity": "sha512-GRibxoawM9ZCnDxnP3usoUDO9vUkpAxIIZ6GQI+IlVmr5kP3zUq+l17xELTHMWTWzjxa2guPNyrpq1GWmPvcGQ==", - "cpu": [ - "arm64" - ], + "node_modules/@babel/traverse": { + "version": "7.24.5", "dev": true, - "optional": true, - "os": [ - "win32" - ], + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.24.2", + "@babel/generator": "^7.24.5", + "@babel/helper-environment-visitor": "^7.22.20", + "@babel/helper-function-name": "^7.23.0", + "@babel/helper-hoist-variables": "^7.22.5", + "@babel/helper-split-export-declaration": "^7.24.5", + "@babel/parser": "^7.24.5", + "@babel/types": "^7.24.5", + "debug": "^4.3.1", + "globals": "^11.1.0" + }, "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/win32-ia32": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.20.2.tgz", - "integrity": "sha512-HfLOfn9YWmkSKRQqovpnITazdtquEW8/SoHW7pWpuEeguaZI4QnCRW6b+oZTztdBnZOS2hqJ6im/D5cPzBTTlQ==", - "cpu": [ - "ia32" - ], + "node_modules/@babel/types": { + "version": "7.24.5", "dev": true, - "optional": true, - "os": [ - "win32" - ], + "license": "MIT", + "dependencies": { + "@babel/helper-string-parser": "^7.24.1", + "@babel/helper-validator-identifier": "^7.24.5", + "to-fast-properties": "^2.0.0" + }, "engines": { - "node": ">=12" + "node": ">=6.9.0" } }, - "node_modules/@esbuild/win32-x64": { + "node_modules/@esbuild/darwin-arm64": { "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.20.2.tgz", - "integrity": "sha512-N49X4lJX27+l9jbLKSqZ6bKNjzQvHaT8IIFUy+YIqmXQdjYCToGWwOItDrfby14c78aDd5NHQl29xingXfCdLQ==", "cpu": [ - "x64" + "arm64" ], "dev": true, + "license": "MIT", "optional": true, "os": [ - "win32" + "darwin" ], "engines": { "node": ">=12" @@ -793,9 +4264,8 @@ }, "node_modules/@eslint-community/eslint-utils": { "version": "4.4.0", - "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz", - "integrity": "sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==", "dev": true, + "license": "MIT", "dependencies": { "eslint-visitor-keys": "^3.3.0" }, @@ -808,18 +4278,16 @@ }, "node_modules/@eslint-community/regexpp": { "version": "4.10.0", - "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.10.0.tgz", - "integrity": "sha512-Cu96Sd2By9mCNTx2iyKOmq10v22jUVQv0lQnlGNy16oE9589yE+QADPbrMGCkA51cKZSg3Pu/aTJVTGfL/qjUA==", "dev": true, + "license": "MIT", "engines": { "node": "^12.0.0 || ^14.0.0 || >=16.0.0" } }, "node_modules/@eslint/eslintrc": { "version": "2.1.4", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-2.1.4.tgz", - "integrity": "sha512-269Z39MS6wVJtsoUl10L60WdkhJVdPG24Q4eZTH3nnF6lpvSShEK3wQjDX9JRWAUPvPh7COouPpU9IrqaZFvtQ==", "dev": true, + "license": "MIT", "dependencies": { "ajv": "^6.12.4", "debug": "^4.3.2", @@ -840,9 +4308,8 @@ }, "node_modules/@eslint/eslintrc/node_modules/brace-expansion": { "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", "dev": true, + "license": "MIT", "dependencies": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" @@ -850,9 +4317,8 @@ }, "node_modules/@eslint/eslintrc/node_modules/globals": { "version": "13.24.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.24.0.tgz", - "integrity": "sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==", "dev": true, + "license": "MIT", "dependencies": { "type-fest": "^0.20.2" }, @@ -865,9 +4331,8 @@ }, "node_modules/@eslint/eslintrc/node_modules/minimatch": { "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", "dev": true, + "license": "ISC", "dependencies": { "brace-expansion": "^1.1.7" }, @@ -877,9 +4342,8 @@ }, "node_modules/@eslint/js": { "version": "8.57.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.57.0.tgz", - "integrity": "sha512-Ys+3g2TaW7gADOJzPt83SJtCDhMjndcDMFVQ/Tj9iA1BfJzFKD9mAUXT3OenpuPHbI6P/myECxRJrofUsDx/5g==", "dev": true, + "license": "MIT", "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" } @@ -890,9 +4354,8 @@ }, "node_modules/@humanwhocodes/config-array": { "version": "0.11.14", - "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.14.tgz", - "integrity": "sha512-3T8LkOmg45BV5FICb15QQMsyUSWrQ8AygVfC7ZG32zOalnqrilm018ZVCw0eapXux8FtA33q8PSRSstjee3jSg==", "dev": true, + "license": "Apache-2.0", "dependencies": { "@humanwhocodes/object-schema": "^2.0.2", "debug": "^4.3.1", @@ -904,9 +4367,8 @@ }, "node_modules/@humanwhocodes/config-array/node_modules/brace-expansion": { "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", "dev": true, + "license": "MIT", "dependencies": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" @@ -914,9 +4376,8 @@ }, "node_modules/@humanwhocodes/config-array/node_modules/minimatch": { "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", "dev": true, + "license": "ISC", "dependencies": { "brace-expansion": "^1.1.7" }, @@ -926,9 +4387,8 @@ }, "node_modules/@humanwhocodes/module-importer": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz", - "integrity": "sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==", "dev": true, + "license": "Apache-2.0", "engines": { "node": ">=12.22" }, @@ -939,15 +4399,13 @@ }, "node_modules/@humanwhocodes/object-schema": { "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@humanwhocodes/object-schema/-/object-schema-2.0.3.tgz", - "integrity": "sha512-93zYdMES/c1D69yZiKDBj0V24vqNzB/koF26KPaagAfd3P/4gUlh3Dys5ogAK+Exi9QyzlD8x/08Zt7wIKcDcA==", - "dev": true + "dev": true, + "license": "BSD-3-Clause" }, "node_modules/@jridgewell/gen-mapping": { "version": "0.3.5", - "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz", - "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==", "dev": true, + "license": "MIT", "dependencies": { "@jridgewell/set-array": "^1.2.1", "@jridgewell/sourcemap-codec": "^1.4.10", @@ -959,33 +4417,29 @@ }, "node_modules/@jridgewell/resolve-uri": { "version": "3.1.2", - "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", - "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.0.0" } }, "node_modules/@jridgewell/set-array": { "version": "1.2.1", - "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", - "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.0.0" } }, "node_modules/@jridgewell/sourcemap-codec": { "version": "1.4.15", - "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.15.tgz", - "integrity": "sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@jridgewell/trace-mapping": { "version": "0.3.25", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", - "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", "dev": true, + "license": "MIT", "dependencies": { "@jridgewell/resolve-uri": "^3.1.0", "@jridgewell/sourcemap-codec": "^1.4.14" @@ -993,9 +4447,8 @@ }, "node_modules/@nodelib/fs.scandir": { "version": "2.1.5", - "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", - "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", "dev": true, + "license": "MIT", "dependencies": { "@nodelib/fs.stat": "2.0.5", "run-parallel": "^1.1.9" @@ -1006,18 +4459,16 @@ }, "node_modules/@nodelib/fs.stat": { "version": "2.0.5", - "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", - "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", "dev": true, + "license": "MIT", "engines": { "node": ">= 8" } }, "node_modules/@nodelib/fs.walk": { "version": "1.2.8", - "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", - "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", "dev": true, + "license": "MIT", "dependencies": { "@nodelib/fs.scandir": "2.1.5", "fastq": "^1.6.0" @@ -1028,9 +4479,8 @@ }, "node_modules/@playwright/test": { "version": "1.44.0", - "resolved": "https://registry.npmjs.org/@playwright/test/-/test-1.44.0.tgz", - "integrity": "sha512-rNX5lbNidamSUorBhB4XZ9SQTjAqfe5M+p37Z8ic0jPFBMo5iCtQz1kRWkEMg+rYOKSlVycpQmpqjSFq7LXOfg==", "dev": true, + "license": "Apache-2.0", "dependencies": { "playwright": "1.44.0" }, @@ -1043,28 +4493,23 @@ }, "node_modules/@protobufjs/aspromise": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@protobufjs/aspromise/-/aspromise-1.1.2.tgz", - "integrity": "sha512-j+gKExEuLmKwvz3OgROXtrJ2UG2x8Ch2YZUxahh+s1F2HZ+wAceUNLkvy6zKCPVRkU++ZWQrdxsUeQXmcg4uoQ==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/base64": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@protobufjs/base64/-/base64-1.1.2.tgz", - "integrity": "sha512-AZkcAA5vnN/v4PDqKyMR5lx7hZttPDgClv83E//FMNhR2TMcLUhfRUBHCmSl0oi9zMgDDqRUJkSxO3wm85+XLg==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/codegen": { "version": "2.0.4", - "resolved": "https://registry.npmjs.org/@protobufjs/codegen/-/codegen-2.0.4.tgz", - "integrity": "sha512-YyFaikqM5sH0ziFZCN3xDC7zeGaB/d0IUb9CATugHWbd1FRFwWwt4ld4OYMPWu5a3Xe01mGAULCdqhMlPl29Jg==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/eventemitter": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@protobufjs/eventemitter/-/eventemitter-1.1.0.tgz", - "integrity": "sha512-j9ednRT81vYJ9OfVuXG6ERSTdEL1xVsNgqpkxMsbIabzSo3goCjDIveeGv5d03om39ML71RdmrGNjG5SReBP/Q==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/fetch": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@protobufjs/fetch/-/fetch-1.1.0.tgz", - "integrity": "sha512-lljVXpqXebpsijW71PZaCYeIcE5on1w5DlQy5WH6GLbFryLUrBD4932W/E2BSpfRJWseIL4v/KPgBFxDOIdKpQ==", + "license": "BSD-3-Clause", "dependencies": { "@protobufjs/aspromise": "^1.1.1", "@protobufjs/inquire": "^1.1.0" @@ -1072,242 +4517,40 @@ }, "node_modules/@protobufjs/float": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@protobufjs/float/-/float-1.0.2.tgz", - "integrity": "sha512-Ddb+kVXlXst9d+R9PfTIxh1EdNkgoRe5tOX6t01f1lYWOvJnSPDBlG241QLzcyPdoNTsblLUdujGSE4RzrTZGQ==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/inquire": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@protobufjs/inquire/-/inquire-1.1.0.tgz", - "integrity": "sha512-kdSefcPdruJiFMVSbn801t4vFK7KB/5gd2fYvrxhuJYg8ILrmn9SKSX2tZdV6V+ksulWqS7aXjBcRXl3wHoD9Q==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/path": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@protobufjs/path/-/path-1.1.2.tgz", - "integrity": "sha512-6JOcJ5Tm08dOHAbdR3GrvP+yUUfkjG5ePsHYczMFLq3ZmMkAD98cDgcT2iA1lJ9NVwFd4tH/iSSoe44YWkltEA==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/pool": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@protobufjs/pool/-/pool-1.1.0.tgz", - "integrity": "sha512-0kELaGSIDBKvcgS4zkjz1PeddatrjYcmMWOlAuAPwAeccUrPHdUqo/J6LiymHHEiJT5NrF1UVwxY14f+fy4WQw==" + "license": "BSD-3-Clause" }, "node_modules/@protobufjs/utf8": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@protobufjs/utf8/-/utf8-1.1.0.tgz", - "integrity": "sha512-Vvn3zZrhQZkkBE8LSuW3em98c0FwgO4nxzv6OdSxPKJIEKY2bGbHn+mhGIPerzI4twdxaP8/0+06HBpwf345Lw==" - }, - "node_modules/@rollup/rollup-android-arm-eabi": { - "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.17.2.tgz", - "integrity": "sha512-NM0jFxY8bB8QLkoKxIQeObCaDlJKewVlIEkuyYKm5An1tdVZ966w2+MPQ2l8LBZLjR+SgyV+nRkTIunzOYBMLQ==", - "cpu": [ - "arm" - ], - "dev": true, - "optional": true, - "os": [ - "android" - ] - }, - "node_modules/@rollup/rollup-android-arm64": { - "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.17.2.tgz", - "integrity": "sha512-yeX/Usk7daNIVwkq2uGoq2BYJKZY1JfyLTaHO/jaiSwi/lsf8fTFoQW/n6IdAsx5tx+iotu2zCJwz8MxI6D/Bw==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "android" - ] + "license": "BSD-3-Clause" }, "node_modules/@rollup/rollup-darwin-arm64": { "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.17.2.tgz", - "integrity": "sha512-kcMLpE6uCwls023+kknm71ug7MZOrtXo+y5p/tsg6jltpDtgQY1Eq5sGfHcQfb+lfuKwhBmEURDga9N0ol4YPw==", "cpu": [ "arm64" ], "dev": true, + "license": "MIT", "optional": true, "os": [ "darwin" ] }, - "node_modules/@rollup/rollup-darwin-x64": { - "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.17.2.tgz", - "integrity": "sha512-AtKwD0VEx0zWkL0ZjixEkp5tbNLzX+FCqGG1SvOu993HnSz4qDI6S4kGzubrEJAljpVkhRSlg5bzpV//E6ysTQ==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "darwin" - ] - }, - "node_modules/@rollup/rollup-linux-arm-gnueabihf": { - "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.17.2.tgz", - "integrity": "sha512-3reX2fUHqN7sffBNqmEyMQVj/CKhIHZd4y631duy0hZqI8Qoqf6lTtmAKvJFYa6bhU95B1D0WgzHkmTg33In0A==", - "cpu": [ - "arm" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-arm-musleabihf": { - "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.17.2.tgz", - "integrity": "sha512-uSqpsp91mheRgw96xtyAGP9FW5ChctTFEoXP0r5FAzj/3ZRv3Uxjtc7taRQSaQM/q85KEKjKsZuiZM3GyUivRg==", - "cpu": [ - "arm" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-arm64-gnu": { - "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.17.2.tgz", - "integrity": "sha512-EMMPHkiCRtE8Wdk3Qhtciq6BndLtstqZIroHiiGzB3C5LDJmIZcSzVtLRbwuXuUft1Cnv+9fxuDtDxz3k3EW2A==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-arm64-musl": { - "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.17.2.tgz", - "integrity": "sha512-NMPylUUZ1i0z/xJUIx6VUhISZDRT+uTWpBcjdv0/zkp7b/bQDF+NfnfdzuTiB1G6HTodgoFa93hp0O1xl+/UbA==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-powerpc64le-gnu": { - "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.17.2.tgz", - "integrity": "sha512-T19My13y8uYXPw/L/k0JYaX1fJKFT/PWdXiHr8mTbXWxjVF1t+8Xl31DgBBvEKclw+1b00Chg0hxE2O7bTG7GQ==", - "cpu": [ - "ppc64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-riscv64-gnu": { - "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.17.2.tgz", - "integrity": "sha512-BOaNfthf3X3fOWAB+IJ9kxTgPmMqPPH5f5k2DcCsRrBIbWnaJCgX2ll77dV1TdSy9SaXTR5iDXRL8n7AnoP5cg==", - "cpu": [ - "riscv64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-s390x-gnu": { - "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.17.2.tgz", - "integrity": "sha512-W0UP/x7bnn3xN2eYMql2T/+wpASLE5SjObXILTMPUBDB/Fg/FxC+gX4nvCfPBCbNhz51C+HcqQp2qQ4u25ok6g==", - "cpu": [ - "s390x" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-x64-gnu": { - "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.17.2.tgz", - "integrity": "sha512-Hy7pLwByUOuyaFC6mAr7m+oMC+V7qyifzs/nW2OJfC8H4hbCzOX07Ov0VFk/zP3kBsELWNFi7rJtgbKYsav9QQ==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-x64-musl": { - "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.17.2.tgz", - "integrity": "sha512-h1+yTWeYbRdAyJ/jMiVw0l6fOOm/0D1vNLui9iPuqgRGnXA0u21gAqOyB5iHjlM9MMfNOm9RHCQ7zLIzT0x11Q==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-win32-arm64-msvc": { - "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.17.2.tgz", - "integrity": "sha512-tmdtXMfKAjy5+IQsVtDiCfqbynAQE/TQRpWdVataHmhMb9DCoJxp9vLcCBjEQWMiUYxO1QprH/HbY9ragCEFLA==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "win32" - ] - }, - "node_modules/@rollup/rollup-win32-ia32-msvc": { - "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.17.2.tgz", - "integrity": "sha512-7II/QCSTAHuE5vdZaQEwJq2ZACkBpQDOmQsE6D6XUbnBHW8IAhm4eTufL6msLJorzrHDFv3CF8oCA/hSIRuZeQ==", - "cpu": [ - "ia32" - ], - "dev": true, - "optional": true, - "os": [ - "win32" - ] - }, - "node_modules/@rollup/rollup-win32-x64-msvc": { - "version": "4.17.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.17.2.tgz", - "integrity": "sha512-TGGO7v7qOq4CYmSBVEYpI1Y5xDuCEnbVC5Vth8mOsW0gDSzxNrVERPc790IGHsrT2dQSimgMr9Ub3Y1Jci5/8w==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "win32" - ] - }, "node_modules/@types/babel__core": { "version": "7.20.5", - "resolved": "https://registry.npmjs.org/@types/babel__core/-/babel__core-7.20.5.tgz", - "integrity": "sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==", "dev": true, + "license": "MIT", "dependencies": { "@babel/parser": "^7.20.7", "@babel/types": "^7.20.7", @@ -1318,18 +4561,16 @@ }, "node_modules/@types/babel__generator": { "version": "7.6.8", - "resolved": "https://registry.npmjs.org/@types/babel__generator/-/babel__generator-7.6.8.tgz", - "integrity": "sha512-ASsj+tpEDsEiFr1arWrlN6V3mdfjRMZt6LtK/Vp/kreFLnr5QH5+DhvD5nINYZXzwJvXeGq+05iUXcAzVrqWtw==", "dev": true, + "license": "MIT", "dependencies": { "@babel/types": "^7.0.0" } }, "node_modules/@types/babel__template": { "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@types/babel__template/-/babel__template-7.4.4.tgz", - "integrity": "sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A==", "dev": true, + "license": "MIT", "dependencies": { "@babel/parser": "^7.1.0", "@babel/types": "^7.0.0" @@ -1337,44 +4578,38 @@ }, "node_modules/@types/babel__traverse": { "version": "7.20.5", - "resolved": "https://registry.npmjs.org/@types/babel__traverse/-/babel__traverse-7.20.5.tgz", - "integrity": "sha512-WXCyOcRtH37HAUkpXhUduaxdm82b4GSlyTqajXviN4EfiuPgNYR109xMCKvpl6zPIpua0DGlMEDCq+g8EdoheQ==", "dev": true, + "license": "MIT", "dependencies": { "@babel/types": "^7.20.7" } }, "node_modules/@types/estree": { "version": "1.0.5", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz", - "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@types/json-schema": { "version": "7.0.15", - "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.15.tgz", - "integrity": "sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@types/node": { "version": "20.12.10", - "resolved": "https://registry.npmjs.org/@types/node/-/node-20.12.10.tgz", - "integrity": "sha512-Eem5pH9pmWBHoGAT8Dr5fdc5rYA+4NAovdM4EktRPVAAiJhmWWfQrA0cFhAbOsQdSfIHjAud6YdkbL69+zSKjw==", + "license": "MIT", "dependencies": { "undici-types": "~5.26.4" } }, "node_modules/@types/prop-types": { "version": "15.7.12", - "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.12.tgz", - "integrity": "sha512-5zvhXYtRNRluoE/jAp4GVsSduVUzNWKkOZrCDBWYtE7biZywwdC2AcEzg+cSMLFRfVgeAFqpfNabiPjxFddV1Q==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@types/react": { "version": "18.3.1", - "resolved": "https://registry.npmjs.org/@types/react/-/react-18.3.1.tgz", - "integrity": "sha512-V0kuGBX3+prX+DQ/7r2qsv1NsdfnCLnTgnRJ1pYnxykBhGMz+qj+box5lq7XsO5mtZsBqpjwwTu/7wszPfMBcw==", "dev": true, + "license": "MIT", "dependencies": { "@types/prop-types": "*", "csstype": "^3.0.2" @@ -1382,24 +4617,21 @@ }, "node_modules/@types/react-dom": { "version": "18.3.0", - "resolved": "https://registry.npmjs.org/@types/react-dom/-/react-dom-18.3.0.tgz", - "integrity": "sha512-EhwApuTmMBmXuFOikhQLIBUn6uFg81SwLMOAUgodJF14SOBOCMdU04gDoYi0WOJJHD144TL32z4yDqCW3dnkQg==", "dev": true, + "license": "MIT", "dependencies": { "@types/react": "*" } }, "node_modules/@types/semver": { "version": "7.5.8", - "resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.5.8.tgz", - "integrity": "sha512-I8EUhyrgfLrcTkzV3TSsGyl1tSuPrEDzr0yd5m90UgNxQkyDXULk3b6MlQqTCpZpNtWe1K0hzclnZkTcLBe2UQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/@typescript-eslint/eslint-plugin": { "version": "7.8.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-7.8.0.tgz", - "integrity": "sha512-gFTT+ezJmkwutUPmB0skOj3GZJtlEGnlssems4AjkVweUPGj7jRwwqg0Hhg7++kPGJqKtTYx+R05Ftww372aIg==", "dev": true, + "license": "MIT", "dependencies": { "@eslint-community/regexpp": "^4.10.0", "@typescript-eslint/scope-manager": "7.8.0", @@ -1432,9 +4664,8 @@ }, "node_modules/@typescript-eslint/parser": { "version": "7.8.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-7.8.0.tgz", - "integrity": "sha512-KgKQly1pv0l4ltcftP59uQZCi4HUYswCLbTqVZEJu7uLX8CTLyswqMLqLN+2QFz4jCptqWVV4SB7vdxcH2+0kQ==", "dev": true, + "license": "BSD-2-Clause", "dependencies": { "@typescript-eslint/scope-manager": "7.8.0", "@typescript-eslint/types": "7.8.0", @@ -1460,9 +4691,8 @@ }, "node_modules/@typescript-eslint/scope-manager": { "version": "7.8.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-7.8.0.tgz", - "integrity": "sha512-viEmZ1LmwsGcnr85gIq+FCYI7nO90DVbE37/ll51hjv9aG+YZMb4WDE2fyWpUR4O/UrhGRpYXK/XajcGTk2B8g==", "dev": true, + "license": "MIT", "dependencies": { "@typescript-eslint/types": "7.8.0", "@typescript-eslint/visitor-keys": "7.8.0" @@ -1477,9 +4707,8 @@ }, "node_modules/@typescript-eslint/type-utils": { "version": "7.8.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-7.8.0.tgz", - "integrity": "sha512-H70R3AefQDQpz9mGv13Uhi121FNMh+WEaRqcXTX09YEDky21km4dV1ZXJIp8QjXc4ZaVkXVdohvWDzbnbHDS+A==", "dev": true, + "license": "MIT", "dependencies": { "@typescript-eslint/typescript-estree": "7.8.0", "@typescript-eslint/utils": "7.8.0", @@ -1504,9 +4733,8 @@ }, "node_modules/@typescript-eslint/types": { "version": "7.8.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-7.8.0.tgz", - "integrity": "sha512-wf0peJ+ZGlcH+2ZS23aJbOv+ztjeeP8uQ9GgwMJGVLx/Nj9CJt17GWgWWoSmoRVKAX2X+7fzEnAjxdvK2gqCLw==", "dev": true, + "license": "MIT", "engines": { "node": "^18.18.0 || >=20.0.0" }, @@ -1517,9 +4745,8 @@ }, "node_modules/@typescript-eslint/typescript-estree": { "version": "7.8.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-7.8.0.tgz", - "integrity": "sha512-5pfUCOwK5yjPaJQNy44prjCwtr981dO8Qo9J9PwYXZ0MosgAbfEMB008dJ5sNo3+/BN6ytBPuSvXUg9SAqB0dg==", "dev": true, + "license": "BSD-2-Clause", "dependencies": { "@typescript-eslint/types": "7.8.0", "@typescript-eslint/visitor-keys": "7.8.0", @@ -1545,9 +4772,8 @@ }, "node_modules/@typescript-eslint/utils": { "version": "7.8.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-7.8.0.tgz", - "integrity": "sha512-L0yFqOCflVqXxiZyXrDr80lnahQfSOfc9ELAAZ75sqicqp2i36kEZZGuUymHNFoYOqxRT05up760b4iGsl02nQ==", "dev": true, + "license": "MIT", "dependencies": { "@eslint-community/eslint-utils": "^4.4.0", "@types/json-schema": "^7.0.15", @@ -1570,9 +4796,8 @@ }, "node_modules/@typescript-eslint/visitor-keys": { "version": "7.8.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-7.8.0.tgz", - "integrity": "sha512-q4/gibTNBQNA0lGyYQCmWRS5D15n8rXh4QjK3KV+MBPlTYHpfBUT3D3PaPR/HeNiI9W6R7FvlkcGhNyAoP+caA==", "dev": true, + "license": "MIT", "dependencies": { "@typescript-eslint/types": "7.8.0", "eslint-visitor-keys": "^3.4.3" @@ -1587,15 +4812,13 @@ }, "node_modules/@ungap/structured-clone": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@ungap/structured-clone/-/structured-clone-1.2.0.tgz", - "integrity": "sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/@vitejs/plugin-react": { "version": "4.2.1", - "resolved": "https://registry.npmjs.org/@vitejs/plugin-react/-/plugin-react-4.2.1.tgz", - "integrity": "sha512-oojO9IDc4nCUUi8qIR11KoQm0XFFLIwsRBwHRR4d/88IWghn1y6ckz/bJ8GHDCsYEJee8mDzqtJxh15/cisJNQ==", "dev": true, + "license": "MIT", "dependencies": { "@babel/core": "^7.23.5", "@babel/plugin-transform-react-jsx-self": "^7.23.3", @@ -1612,9 +4835,8 @@ }, "node_modules/acorn": { "version": "8.11.3", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.11.3.tgz", - "integrity": "sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg==", "dev": true, + "license": "MIT", "bin": { "acorn": "bin/acorn" }, @@ -1624,18 +4846,16 @@ }, "node_modules/acorn-jsx": { "version": "5.3.2", - "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz", - "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==", "dev": true, + "license": "MIT", "peerDependencies": { "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" } }, "node_modules/ajv": { "version": "6.12.6", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", - "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", "dev": true, + "license": "MIT", "dependencies": { "fast-deep-equal": "^3.1.1", "fast-json-stable-stringify": "^2.0.0", @@ -1649,18 +4869,16 @@ }, "node_modules/ansi-regex": { "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/ansi-styles": { "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^1.9.0" }, @@ -1670,39 +4888,34 @@ }, "node_modules/argparse": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", - "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", - "dev": true + "dev": true, + "license": "Python-2.0" }, "node_modules/array-union": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz", - "integrity": "sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/balanced-match": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", - "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/brace-expansion": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz", - "integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==", "dev": true, + "license": "MIT", "dependencies": { "balanced-match": "^1.0.0" } }, "node_modules/braces": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", - "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", "dev": true, + "license": "MIT", "dependencies": { "fill-range": "^7.0.1" }, @@ -1712,8 +4925,6 @@ }, "node_modules/browserslist": { "version": "4.23.0", - "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.23.0.tgz", - "integrity": "sha512-QW8HiM1shhT2GuzkvklfjcKDiWFXHOeFCIA/huJPwHsslwcydgk7X+z2zXpEijP98UCY7HbubZt5J2Zgvf0CaQ==", "dev": true, "funding": [ { @@ -1729,6 +4940,7 @@ "url": "https://github.com/sponsors/ai" } ], + "license": "MIT", "dependencies": { "caniuse-lite": "^1.0.30001587", "electron-to-chromium": "^1.4.668", @@ -1744,17 +4956,14 @@ }, "node_modules/callsites": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", - "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/caniuse-lite": { "version": "1.0.30001616", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001616.tgz", - "integrity": "sha512-RHVYKov7IcdNjVHJFNY/78RdG4oGVjbayxv8u5IO74Wv7Hlq4PnJE6mo/OjFijjVFNy5ijnCt6H3IIo4t+wfEw==", "dev": true, "funding": [ { @@ -1769,12 +4978,12 @@ "type": "github", "url": "https://github.com/sponsors/ai" } - ] + ], + "license": "CC-BY-4.0" }, "node_modules/case-anything": { "version": "2.1.13", - "resolved": "https://registry.npmjs.org/case-anything/-/case-anything-2.1.13.tgz", - "integrity": "sha512-zlOQ80VrQ2Ue+ymH5OuM/DlDq64mEm+B9UTdHULv5osUMD6HalNTblf2b1u/m6QecjsnOkBpqVZ+XPwIVsy7Ng==", + "license": "MIT", "engines": { "node": ">=12.13" }, @@ -1784,9 +4993,8 @@ }, "node_modules/chalk": { "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^3.2.1", "escape-string-regexp": "^1.0.5", @@ -1798,36 +5006,31 @@ }, "node_modules/color-convert": { "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "1.1.3" } }, "node_modules/color-name": { "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/concat-map": { "version": "0.0.1", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/convert-source-map": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", - "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/cross-spawn": { "version": "7.0.3", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", - "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", "dev": true, + "license": "MIT", "dependencies": { "path-key": "^3.1.0", "shebang-command": "^2.0.0", @@ -1839,15 +5042,13 @@ }, "node_modules/csstype": { "version": "3.1.3", - "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.3.tgz", - "integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/debug": { "version": "4.3.4", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", - "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", "dev": true, + "license": "MIT", "dependencies": { "ms": "2.1.2" }, @@ -1862,14 +5063,12 @@ }, "node_modules/deep-is": { "version": "0.1.4", - "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", - "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/detect-libc": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-1.0.3.tgz", - "integrity": "sha512-pGjwhsmsp4kL2RTz08wcOlGN83otlqHeD/Z5T8GXZB+/YcpQ/dgo+lbU8ZsGxV0HIvqqxo9l7mqYwyYMD9bKDg==", + "license": "Apache-2.0", "bin": { "detect-libc": "bin/detect-libc.js" }, @@ -1879,9 +5078,8 @@ }, "node_modules/dir-glob": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz", - "integrity": "sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==", "dev": true, + "license": "MIT", "dependencies": { "path-type": "^4.0.0" }, @@ -1891,9 +5089,8 @@ }, "node_modules/doctrine": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", - "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==", "dev": true, + "license": "Apache-2.0", "dependencies": { "esutils": "^2.0.2" }, @@ -1903,24 +5100,21 @@ }, "node_modules/dprint-node": { "version": "1.0.8", - "resolved": "https://registry.npmjs.org/dprint-node/-/dprint-node-1.0.8.tgz", - "integrity": "sha512-iVKnUtYfGrYcW1ZAlfR/F59cUVL8QIhWoBJoSjkkdua/dkWIgjZfiLMeTjiB06X0ZLkQ0M2C1VbUj/CxkIf1zg==", + "license": "MIT", "dependencies": { "detect-libc": "^1.0.3" } }, "node_modules/electron-to-chromium": { "version": "1.4.757", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.757.tgz", - "integrity": "sha512-jftDaCknYSSt/+KKeXzH3LX5E2CvRLm75P3Hj+J/dv3CL0qUYcOt13d5FN1NiL5IJbbhzHrb3BomeG2tkSlZmw==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/esbuild": { "version": "0.20.2", - "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.20.2.tgz", - "integrity": "sha512-WdOOppmUNU+IbZ0PaDiTst80zjnrOkyJNHoKupIcVyU8Lvla3Ugx94VzkQ32Ijqd7UhHJy75gNWDMUekcrSJ6g==", "dev": true, "hasInstallScript": true, + "license": "MIT", "bin": { "esbuild": "bin/esbuild" }, @@ -1955,27 +5149,24 @@ }, "node_modules/escalade": { "version": "3.1.2", - "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.2.tgz", - "integrity": "sha512-ErCHMCae19vR8vQGe50xIsVomy19rg6gFu3+r3jkEO46suLMWBksvVyoGgQV+jOfl84ZSOSlmv6Gxa89PmTGmA==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/escape-string-regexp": { "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.8.0" } }, "node_modules/eslint": { "version": "8.57.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.57.0.tgz", - "integrity": "sha512-dZ6+mexnaTIbSBZWgou51U6OmzIhYM2VcNdtiTtI7qPNZm35Akpr0f6vtw3w1Kmn5PYo+tZVfh13WrhpS6oLqQ==", "dev": true, + "license": "MIT", "dependencies": { "@eslint-community/eslint-utils": "^4.2.0", "@eslint-community/regexpp": "^4.6.1", @@ -2028,9 +5219,8 @@ }, "node_modules/eslint-plugin-react-hooks": { "version": "4.6.2", - "resolved": "https://registry.npmjs.org/eslint-plugin-react-hooks/-/eslint-plugin-react-hooks-4.6.2.tgz", - "integrity": "sha512-QzliNJq4GinDBcD8gPB5v0wh6g8q3SUi6EFF0x8N/BL9PoVs0atuGc47ozMRyOWAKdwaZ5OnbOEa3WR+dSGKuQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=10" }, @@ -2040,18 +5230,16 @@ }, "node_modules/eslint-plugin-react-refresh": { "version": "0.4.6", - "resolved": "https://registry.npmjs.org/eslint-plugin-react-refresh/-/eslint-plugin-react-refresh-0.4.6.tgz", - "integrity": "sha512-NjGXdm7zgcKRkKMua34qVO9doI7VOxZ6ancSvBELJSSoX97jyndXcSoa8XBh69JoB31dNz3EEzlMcizZl7LaMA==", "dev": true, + "license": "MIT", "peerDependencies": { "eslint": ">=7" } }, "node_modules/eslint-scope": { "version": "7.2.2", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.2.tgz", - "integrity": "sha512-dOt21O7lTMhDM+X9mB4GX+DZrZtCUJPL/wlcTqxyrx5IvO0IYtILdtrQGQp+8n5S0gwSVmOf9NQrjMOgfQZlIg==", "dev": true, + "license": "BSD-2-Clause", "dependencies": { "esrecurse": "^4.3.0", "estraverse": "^5.2.0" @@ -2065,9 +5253,8 @@ }, "node_modules/eslint-visitor-keys": { "version": "3.4.3", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz", - "integrity": "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==", "dev": true, + "license": "Apache-2.0", "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, @@ -2077,9 +5264,8 @@ }, "node_modules/eslint/node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -2092,9 +5278,8 @@ }, "node_modules/eslint/node_modules/brace-expansion": { "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", "dev": true, + "license": "MIT", "dependencies": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" @@ -2102,9 +5287,8 @@ }, "node_modules/eslint/node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -2118,9 +5302,8 @@ }, "node_modules/eslint/node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -2130,15 +5313,13 @@ }, "node_modules/eslint/node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/eslint/node_modules/escape-string-regexp": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", - "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", "dev": true, + "license": "MIT", "engines": { "node": ">=10" }, @@ -2148,9 +5329,8 @@ }, "node_modules/eslint/node_modules/globals": { "version": "13.24.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.24.0.tgz", - "integrity": "sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==", "dev": true, + "license": "MIT", "dependencies": { "type-fest": "^0.20.2" }, @@ -2163,18 +5343,16 @@ }, "node_modules/eslint/node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/eslint/node_modules/minimatch": { "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", "dev": true, + "license": "ISC", "dependencies": { "brace-expansion": "^1.1.7" }, @@ -2184,9 +5362,8 @@ }, "node_modules/eslint/node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -2196,9 +5373,8 @@ }, "node_modules/espree": { "version": "9.6.1", - "resolved": "https://registry.npmjs.org/espree/-/espree-9.6.1.tgz", - "integrity": "sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ==", "dev": true, + "license": "BSD-2-Clause", "dependencies": { "acorn": "^8.9.0", "acorn-jsx": "^5.3.2", @@ -2213,9 +5389,8 @@ }, "node_modules/esquery": { "version": "1.5.0", - "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.5.0.tgz", - "integrity": "sha512-YQLXUplAwJgCydQ78IMJywZCceoqk1oH01OERdSAJc/7U2AylwjhSCLDEtqwg811idIS/9fIU5GjG73IgjKMVg==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { "estraverse": "^5.1.0" }, @@ -2225,9 +5400,8 @@ }, "node_modules/esrecurse": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz", - "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==", "dev": true, + "license": "BSD-2-Clause", "dependencies": { "estraverse": "^5.2.0" }, @@ -2237,33 +5411,29 @@ }, "node_modules/estraverse": { "version": "5.3.0", - "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", - "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", "dev": true, + "license": "BSD-2-Clause", "engines": { "node": ">=4.0" } }, "node_modules/esutils": { "version": "2.0.3", - "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", - "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", "dev": true, + "license": "BSD-2-Clause", "engines": { "node": ">=0.10.0" } }, "node_modules/fast-deep-equal": { "version": "3.1.3", - "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", - "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/fast-glob": { "version": "3.3.2", - "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.2.tgz", - "integrity": "sha512-oX2ruAFQwf/Orj8m737Y5adxDQO0LAB7/S5MnxCdTNDd4p6BsyIVsv9JQsATbTSq8KHRpLwIHbVlUNatxd+1Ow==", "dev": true, + "license": "MIT", "dependencies": { "@nodelib/fs.stat": "^2.0.2", "@nodelib/fs.walk": "^1.2.3", @@ -2277,9 +5447,8 @@ }, "node_modules/fast-glob/node_modules/glob-parent": { "version": "5.1.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", - "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", "dev": true, + "license": "ISC", "dependencies": { "is-glob": "^4.0.1" }, @@ -2289,30 +5458,26 @@ }, "node_modules/fast-json-stable-stringify": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", - "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/fast-levenshtein": { "version": "2.0.6", - "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", - "integrity": "sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/fastq": { "version": "1.17.1", - "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.17.1.tgz", - "integrity": "sha512-sRVD3lWVIXWg6By68ZN7vho9a1pQcN/WBFaAAsDDFzlJjvoGx0P8z7V1t72grFJfJhu3YPZBuu25f7Kaw2jN1w==", "dev": true, + "license": "ISC", "dependencies": { "reusify": "^1.0.4" } }, "node_modules/file-entry-cache": { "version": "6.0.1", - "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-6.0.1.tgz", - "integrity": "sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==", "dev": true, + "license": "MIT", "dependencies": { "flat-cache": "^3.0.4" }, @@ -2322,9 +5487,8 @@ }, "node_modules/fill-range": { "version": "7.0.1", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", - "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", "dev": true, + "license": "MIT", "dependencies": { "to-regex-range": "^5.0.1" }, @@ -2334,9 +5498,8 @@ }, "node_modules/find-up": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", - "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", "dev": true, + "license": "MIT", "dependencies": { "locate-path": "^6.0.0", "path-exists": "^4.0.0" @@ -2350,9 +5513,8 @@ }, "node_modules/flat-cache": { "version": "3.2.0", - "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-3.2.0.tgz", - "integrity": "sha512-CYcENa+FtcUKLmhhqyctpclsq7QF38pKjZHsGNiSQF5r4FtoKDWabFDl3hzaEQMvT1LHEysw5twgLvpYYb4vbw==", "dev": true, + "license": "MIT", "dependencies": { "flatted": "^3.2.9", "keyv": "^4.5.3", @@ -2364,22 +5526,18 @@ }, "node_modules/flatted": { "version": "3.3.1", - "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.3.1.tgz", - "integrity": "sha512-X8cqMLLie7KsNUDSdzeN8FYK9rEt4Dt67OsG/DNGnYTSDBG4uFAJFBnUeiV+zCVAvwFy56IjM9sH51jVaEhNxw==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/fs.realpath": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", - "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/fsevents": { "version": "2.3.2", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz", - "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==", "dev": true, - "hasInstallScript": true, + "license": "MIT", "optional": true, "os": [ "darwin" @@ -2390,18 +5548,16 @@ }, "node_modules/gensync": { "version": "1.0.0-beta.2", - "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.2.tgz", - "integrity": "sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.9.0" } }, "node_modules/glob": { "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", "dev": true, + "license": "ISC", "dependencies": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", @@ -2419,9 +5575,8 @@ }, "node_modules/glob-parent": { "version": "6.0.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", - "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==", "dev": true, + "license": "ISC", "dependencies": { "is-glob": "^4.0.3" }, @@ -2431,9 +5586,8 @@ }, "node_modules/glob/node_modules/brace-expansion": { "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", "dev": true, + "license": "MIT", "dependencies": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" @@ -2441,9 +5595,8 @@ }, "node_modules/glob/node_modules/minimatch": { "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", "dev": true, + "license": "ISC", "dependencies": { "brace-expansion": "^1.1.7" }, @@ -2453,18 +5606,16 @@ }, "node_modules/globals": { "version": "11.12.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", - "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/globby": { "version": "11.1.0", - "resolved": "https://registry.npmjs.org/globby/-/globby-11.1.0.tgz", - "integrity": "sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==", "dev": true, + "license": "MIT", "dependencies": { "array-union": "^2.1.0", "dir-glob": "^3.0.1", @@ -2482,33 +5633,29 @@ }, "node_modules/graphemer": { "version": "1.4.0", - "resolved": "https://registry.npmjs.org/graphemer/-/graphemer-1.4.0.tgz", - "integrity": "sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/has-flag": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/ignore": { "version": "5.3.1", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.1.tgz", - "integrity": "sha512-5Fytz/IraMjqpwfd34ke28PTVMjZjJG2MPn5t7OE4eUCUNf8BAa7b5WUS9/Qvr6mwOQS7Mk6vdsMno5he+T8Xw==", "dev": true, + "license": "MIT", "engines": { "node": ">= 4" } }, "node_modules/import-fresh": { "version": "3.3.0", - "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz", - "integrity": "sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==", "dev": true, + "license": "MIT", "dependencies": { "parent-module": "^1.0.0", "resolve-from": "^4.0.0" @@ -2522,18 +5669,16 @@ }, "node_modules/imurmurhash": { "version": "0.1.4", - "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", - "integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.8.19" } }, "node_modules/inflight": { "version": "1.0.6", - "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", - "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", "dev": true, + "license": "ISC", "dependencies": { "once": "^1.3.0", "wrappy": "1" @@ -2541,24 +5686,21 @@ }, "node_modules/inherits": { "version": "2.0.4", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/is-extglob": { "version": "2.1.1", - "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", - "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/is-glob": { "version": "4.0.3", - "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", - "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", "dev": true, + "license": "MIT", "dependencies": { "is-extglob": "^2.1.1" }, @@ -2568,38 +5710,33 @@ }, "node_modules/is-number": { "version": "7.0.0", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", - "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.12.0" } }, "node_modules/is-path-inside": { "version": "3.0.3", - "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz", - "integrity": "sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/isexe": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/js-tokens": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", - "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==" + "license": "MIT" }, "node_modules/js-yaml": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", "dev": true, + "license": "MIT", "dependencies": { "argparse": "^2.0.1" }, @@ -2609,9 +5746,8 @@ }, "node_modules/jsesc": { "version": "2.5.2", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", - "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==", "dev": true, + "license": "MIT", "bin": { "jsesc": "bin/jsesc" }, @@ -2621,27 +5757,23 @@ }, "node_modules/json-buffer": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", - "integrity": "sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/json-schema-traverse": { "version": "0.4.1", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/json-stable-stringify-without-jsonify": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", - "integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/json5": { "version": "2.2.3", - "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", - "integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==", "dev": true, + "license": "MIT", "bin": { "json5": "lib/cli.js" }, @@ -2651,18 +5783,16 @@ }, "node_modules/keyv": { "version": "4.5.4", - "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.4.tgz", - "integrity": "sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==", "dev": true, + "license": "MIT", "dependencies": { "json-buffer": "3.0.1" } }, "node_modules/levn": { "version": "0.4.1", - "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", - "integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==", "dev": true, + "license": "MIT", "dependencies": { "prelude-ls": "^1.2.1", "type-check": "~0.4.0" @@ -2673,9 +5803,8 @@ }, "node_modules/locate-path": { "version": "6.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", - "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", "dev": true, + "license": "MIT", "dependencies": { "p-locate": "^5.0.0" }, @@ -2688,19 +5817,16 @@ }, "node_modules/lodash.merge": { "version": "4.6.2", - "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", - "integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/long": { "version": "5.2.3", - "resolved": "https://registry.npmjs.org/long/-/long-5.2.3.tgz", - "integrity": "sha512-lcHwpNoggQTObv5apGNCTdJrO69eHOZMi4BNC+rTLER8iHAqGrUVeLh/irVIM7zTw2bOXA8T6uNPeujwOLg/2Q==" + "license": "Apache-2.0" }, "node_modules/loose-envify": { "version": "1.4.0", - "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", - "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", + "license": "MIT", "dependencies": { "js-tokens": "^3.0.0 || ^4.0.0" }, @@ -2710,27 +5836,24 @@ }, "node_modules/lru-cache": { "version": "5.1.1", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz", - "integrity": "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==", "dev": true, + "license": "ISC", "dependencies": { "yallist": "^3.0.2" } }, "node_modules/merge2": { "version": "1.4.1", - "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", - "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", "dev": true, + "license": "MIT", "engines": { "node": ">= 8" } }, "node_modules/micromatch": { "version": "4.0.5", - "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.5.tgz", - "integrity": "sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==", "dev": true, + "license": "MIT", "dependencies": { "braces": "^3.0.2", "picomatch": "^2.3.1" @@ -2741,9 +5864,8 @@ }, "node_modules/minimatch": { "version": "9.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.4.tgz", - "integrity": "sha512-KqWh+VchfxcMNRAJjj2tnsSJdNbHsVgnkBhTNrW7AjVo6OvLtxw8zfT9oLw1JSohlFzJ8jCoTgaoXvJ+kHt6fw==", "dev": true, + "license": "ISC", "dependencies": { "brace-expansion": "^2.0.1" }, @@ -2756,14 +5878,11 @@ }, "node_modules/ms": { "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/nanoid": { "version": "3.3.7", - "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.7.tgz", - "integrity": "sha512-eSRppjcPIatRIMC1U6UngP8XFcz8MQWGQdt1MTBQ7NaAmvXDfvNxbvWV3x2y6CdEUciCSsDHDQZbhYaB8QEo2g==", "dev": true, "funding": [ { @@ -2771,6 +5890,7 @@ "url": "https://github.com/sponsors/ai" } ], + "license": "MIT", "bin": { "nanoid": "bin/nanoid.cjs" }, @@ -2780,30 +5900,26 @@ }, "node_modules/natural-compare": { "version": "1.4.0", - "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", - "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/node-releases": { "version": "2.0.14", - "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.14.tgz", - "integrity": "sha512-y10wOWt8yZpqXmOgRo77WaHEmhYQYGNA6y421PKsKYWEK8aW+cqAphborZDhqfyKrbZEN92CN1X2KbafY2s7Yw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/once": { "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", - "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", "dev": true, + "license": "ISC", "dependencies": { "wrappy": "1" } }, "node_modules/optionator": { "version": "0.9.4", - "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.4.tgz", - "integrity": "sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g==", "dev": true, + "license": "MIT", "dependencies": { "deep-is": "^0.1.3", "fast-levenshtein": "^2.0.6", @@ -2818,9 +5934,8 @@ }, "node_modules/p-limit": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", - "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", "dev": true, + "license": "MIT", "dependencies": { "yocto-queue": "^0.1.0" }, @@ -2833,9 +5948,8 @@ }, "node_modules/p-locate": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", - "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", "dev": true, + "license": "MIT", "dependencies": { "p-limit": "^3.0.2" }, @@ -2848,9 +5962,8 @@ }, "node_modules/parent-module": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", - "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==", "dev": true, + "license": "MIT", "dependencies": { "callsites": "^3.0.0" }, @@ -2860,51 +5973,45 @@ }, "node_modules/path-exists": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/path-is-absolute": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", - "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/path-key": { "version": "3.1.1", - "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", - "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/path-type": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz", - "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/picocolors": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", - "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/picomatch": { "version": "2.3.1", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", - "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", "dev": true, + "license": "MIT", "engines": { "node": ">=8.6" }, @@ -2914,9 +6021,8 @@ }, "node_modules/playwright": { "version": "1.44.0", - "resolved": "https://registry.npmjs.org/playwright/-/playwright-1.44.0.tgz", - "integrity": "sha512-F9b3GUCLQ3Nffrfb6dunPOkE5Mh68tR7zN32L4jCk4FjQamgesGay7/dAAe1WaMEGV04DkdJfcJzjoCKygUaRQ==", "dev": true, + "license": "Apache-2.0", "dependencies": { "playwright-core": "1.44.0" }, @@ -2932,9 +6038,8 @@ }, "node_modules/playwright-core": { "version": "1.44.0", - "resolved": "https://registry.npmjs.org/playwright-core/-/playwright-core-1.44.0.tgz", - "integrity": "sha512-ZTbkNpFfYcGWohvTTl+xewITm7EOuqIqex0c7dNZ+aXsbrLj0qI8XlGKfPpipjm0Wny/4Lt4CJsWJk1stVS5qQ==", "dev": true, + "license": "Apache-2.0", "bin": { "playwright-core": "cli.js" }, @@ -2944,8 +6049,6 @@ }, "node_modules/postcss": { "version": "8.4.38", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.38.tgz", - "integrity": "sha512-Wglpdk03BSfXkHoQa3b/oulrotAkwrlLDRSOb9D0bN86FdRyE9lppSp33aHNPgBa0JKCoB+drFLZkQoRRYae5A==", "dev": true, "funding": [ { @@ -2961,6 +6064,7 @@ "url": "https://github.com/sponsors/ai" } ], + "license": "MIT", "dependencies": { "nanoid": "^3.3.7", "picocolors": "^1.0.0", @@ -2972,18 +6076,16 @@ }, "node_modules/prelude-ls": { "version": "1.2.1", - "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", - "integrity": "sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==", "dev": true, + "license": "MIT", "engines": { "node": ">= 0.8.0" } }, "node_modules/protobufjs": { "version": "7.2.6", - "resolved": "https://registry.npmjs.org/protobufjs/-/protobufjs-7.2.6.tgz", - "integrity": "sha512-dgJaEDDL6x8ASUZ1YqWciTRrdOuYNzoOf27oHNfdyvKqHr5i0FV7FSLU+aIeFjyFgVxrpTOtQUi0BLLBymZaBw==", "hasInstallScript": true, + "license": "BSD-3-Clause", "dependencies": { "@protobufjs/aspromise": "^1.1.2", "@protobufjs/base64": "^1.1.2", @@ -3004,17 +6106,14 @@ }, "node_modules/punycode": { "version": "2.3.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", - "integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/queue-microtask": { "version": "1.2.3", - "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", - "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==", "dev": true, "funding": [ { @@ -3029,12 +6128,12 @@ "type": "consulting", "url": "https://feross.org/support" } - ] + ], + "license": "MIT" }, "node_modules/react": { "version": "18.3.1", - "resolved": "https://registry.npmjs.org/react/-/react-18.3.1.tgz", - "integrity": "sha512-wS+hAgJShR0KhEvPJArfuPVN1+Hz1t0Y6n5jLrGQbkb4urgPE/0Rve+1kMB1v/oWgHgm4WIcV+i7F2pTVj+2iQ==", + "license": "MIT", "dependencies": { "loose-envify": "^1.1.0" }, @@ -3044,8 +6143,7 @@ }, "node_modules/react-dom": { "version": "18.3.1", - "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-18.3.1.tgz", - "integrity": "sha512-5m4nQKp+rZRb09LNH59GM4BxTh9251/ylbKIbpe7TpGxfJ+9kv6BLkLBXIjjspbgbnIBNqlI23tRnTWT0snUIw==", + "license": "MIT", "dependencies": { "loose-envify": "^1.1.0", "scheduler": "^0.23.2" @@ -3056,27 +6154,24 @@ }, "node_modules/react-refresh": { "version": "0.14.2", - "resolved": "https://registry.npmjs.org/react-refresh/-/react-refresh-0.14.2.tgz", - "integrity": "sha512-jCvmsr+1IUSMUyzOkRcvnVbX3ZYC6g9TDrDbFuFmRDq7PD4yaGbLKNQL6k2jnArV8hjYxh7hVhAZB6s9HDGpZA==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/resolve-from": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", - "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/reusify": { "version": "1.0.4", - "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", - "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==", "dev": true, + "license": "MIT", "engines": { "iojs": ">=1.0.0", "node": ">=0.10.0" @@ -3084,9 +6179,8 @@ }, "node_modules/rimraf": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", - "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==", "dev": true, + "license": "ISC", "dependencies": { "glob": "^7.1.3" }, @@ -3099,9 +6193,8 @@ }, "node_modules/rollup": { "version": "4.17.2", - "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.17.2.tgz", - "integrity": "sha512-/9ClTJPByC0U4zNLowV1tMBe8yMEAxewtR3cUNX5BoEpGH3dQEWpJLr6CLp0fPdYRF/fzVOgvDb1zXuakwF5kQ==", "dev": true, + "license": "MIT", "dependencies": { "@types/estree": "1.0.5" }, @@ -3134,8 +6227,6 @@ }, "node_modules/run-parallel": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", - "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==", "dev": true, "funding": [ { @@ -3151,23 +6242,22 @@ "url": "https://feross.org/support" } ], + "license": "MIT", "dependencies": { "queue-microtask": "^1.2.2" } }, "node_modules/scheduler": { "version": "0.23.2", - "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.23.2.tgz", - "integrity": "sha512-UOShsPwz7NrMUqhR6t0hWjFduvOzbtv7toDH1/hIrfRNIDBnnBWd0CwJTGvTpngVlmwGCdP9/Zl/tVrDqcuYzQ==", + "license": "MIT", "dependencies": { "loose-envify": "^1.1.0" } }, "node_modules/semver": { "version": "7.6.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.0.tgz", - "integrity": "sha512-EnwXhrlwXMk9gKu5/flx5sv/an57AkRplG3hTK68W7FRDN+k+OWBj65M7719OkA82XLBxrcX0KSHj+X5COhOVg==", "dev": true, + "license": "ISC", "dependencies": { "lru-cache": "^6.0.0" }, @@ -3180,9 +6270,8 @@ }, "node_modules/semver/node_modules/lru-cache": { "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", "dev": true, + "license": "ISC", "dependencies": { "yallist": "^4.0.0" }, @@ -3192,15 +6281,13 @@ }, "node_modules/semver/node_modules/yallist": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/shebang-command": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", - "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", "dev": true, + "license": "MIT", "dependencies": { "shebang-regex": "^3.0.0" }, @@ -3210,36 +6297,32 @@ }, "node_modules/shebang-regex": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", - "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/slash": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", - "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/source-map-js": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.0.tgz", - "integrity": "sha512-itJW8lvSA0TXEphiRoawsCksnlf8SyvmFzIhltqAHluXd88pkCd+cXJVHTDwdCr0IzwptSm035IHQktUu1QUMg==", "dev": true, + "license": "BSD-3-Clause", "engines": { "node": ">=0.10.0" } }, "node_modules/strip-ansi": { "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", "dev": true, + "license": "MIT", "dependencies": { "ansi-regex": "^5.0.1" }, @@ -3249,9 +6332,8 @@ }, "node_modules/strip-json-comments": { "version": "3.1.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", - "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" }, @@ -3261,9 +6343,8 @@ }, "node_modules/supports-color": { "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, + "license": "MIT", "dependencies": { "has-flag": "^3.0.0" }, @@ -3273,24 +6354,21 @@ }, "node_modules/text-table": { "version": "0.2.0", - "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", - "integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/to-fast-properties": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", - "integrity": "sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog==", "dev": true, + "license": "MIT", "engines": { "node": ">=4" } }, "node_modules/to-regex-range": { "version": "5.0.1", - "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", - "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", "dev": true, + "license": "MIT", "dependencies": { "is-number": "^7.0.0" }, @@ -3300,9 +6378,8 @@ }, "node_modules/ts-api-utils": { "version": "1.3.0", - "resolved": "https://registry.npmjs.org/ts-api-utils/-/ts-api-utils-1.3.0.tgz", - "integrity": "sha512-UQMIo7pb8WRomKR1/+MFVLTroIvDVtMX3K6OUir8ynLyzB8Jeriont2bTAtmNPa1ekAgN7YPDyf6V+ygrdU+eQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=16" }, @@ -3312,16 +6389,14 @@ }, "node_modules/ts-poet": { "version": "6.9.0", - "resolved": "https://registry.npmjs.org/ts-poet/-/ts-poet-6.9.0.tgz", - "integrity": "sha512-roe6W6MeZmCjRmppyfOURklO5tQFQ6Sg7swURKkwYJvV7dbGCrK28um5+51iW3twdPRKtwarqFAVMU6G1mvnuQ==", + "license": "Apache-2.0", "dependencies": { "dprint-node": "^1.0.8" } }, "node_modules/ts-proto": { "version": "1.174.0", - "resolved": "https://registry.npmjs.org/ts-proto/-/ts-proto-1.174.0.tgz", - "integrity": "sha512-hptQp5Nu5Vj3Mrj70fx5ccw3rTwPPpKXpa5RJ/WlmWiliVMqNPGYzUuBvd9N/EKsxiSQHiw62aGlZezzF19fKA==", + "license": "ISC", "dependencies": { "case-anything": "^2.1.13", "protobufjs": "^7.2.4", @@ -3334,8 +6409,7 @@ }, "node_modules/ts-proto-descriptors": { "version": "1.15.0", - "resolved": "https://registry.npmjs.org/ts-proto-descriptors/-/ts-proto-descriptors-1.15.0.tgz", - "integrity": "sha512-TYyJ7+H+7Jsqawdv+mfsEpZPTIj9siDHS6EMCzG/z3b/PZiphsX+mWtqFfFVe5/N0Th6V3elK9lQqjnrgTOfrg==", + "license": "ISC", "dependencies": { "long": "^5.2.3", "protobufjs": "^7.2.4" @@ -3343,9 +6417,8 @@ }, "node_modules/type-check": { "version": "0.4.0", - "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz", - "integrity": "sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==", "dev": true, + "license": "MIT", "dependencies": { "prelude-ls": "^1.2.1" }, @@ -3355,9 +6428,8 @@ }, "node_modules/type-fest": { "version": "0.20.2", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", - "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", "dev": true, + "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=10" }, @@ -3367,9 +6439,8 @@ }, "node_modules/typescript": { "version": "5.3.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.3.3.tgz", - "integrity": "sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==", "dev": true, + "license": "Apache-2.0", "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" @@ -3380,13 +6451,10 @@ }, "node_modules/undici-types": { "version": "5.26.5", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-5.26.5.tgz", - "integrity": "sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==" + "license": "MIT" }, "node_modules/update-browserslist-db": { "version": "1.0.15", - "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.15.tgz", - "integrity": "sha512-K9HWH62x3/EalU1U6sjSZiylm9C8tgq2mSvshZpqc7QE69RaA2qjhkW2HlNA0tFpEbtyFz7HTqbSdN4MSwUodA==", "dev": true, "funding": [ { @@ -3402,6 +6470,7 @@ "url": "https://github.com/sponsors/ai" } ], + "license": "MIT", "dependencies": { "escalade": "^3.1.2", "picocolors": "^1.0.0" @@ -3415,18 +6484,16 @@ }, "node_modules/uri-js": { "version": "4.4.1", - "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz", - "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==", "dev": true, + "license": "BSD-2-Clause", "dependencies": { "punycode": "^2.1.0" } }, "node_modules/vite": { "version": "5.2.11", - "resolved": "https://registry.npmjs.org/vite/-/vite-5.2.11.tgz", - "integrity": "sha512-HndV31LWW05i1BLPMUCE1B9E9GFbOu1MbenhS58FuK6owSO5qHm7GiCotrNY1YE5rMeQSFBGmT5ZaLEjFizgiQ==", "dev": true, + "license": "MIT", "dependencies": { "esbuild": "^0.20.1", "postcss": "^8.4.38", @@ -3479,10 +6546,8 @@ }, "node_modules/vite/node_modules/fsevents": { "version": "2.3.3", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", - "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", "dev": true, - "hasInstallScript": true, + "license": "MIT", "optional": true, "os": [ "darwin" @@ -3493,9 +6558,8 @@ }, "node_modules/which": { "version": "2.0.2", - "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", - "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", "dev": true, + "license": "ISC", "dependencies": { "isexe": "^2.0.0" }, @@ -3508,30 +6572,26 @@ }, "node_modules/word-wrap": { "version": "1.2.5", - "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.5.tgz", - "integrity": "sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/wrappy": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/yallist": { "version": "3.1.1", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", - "integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/yocto-queue": { "version": "0.1.0", - "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", - "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", "dev": true, + "license": "MIT", "engines": { "node": ">=10" }, diff --git a/e2e/app/src/App.tsx b/e2e/app/src/App.tsx index 8cdebeaa..429997f4 100644 --- a/e2e/app/src/App.tsx +++ b/e2e/app/src/App.tsx @@ -15,7 +15,6 @@ import { MockComponent } from "./MockComponent.tsx"; import { VideoPlayerWithDetector } from "./VideoPlayerWithDetector.tsx"; import { ReplaceTrackWithDummyStream } from "./ReplaceTrackWithDummyStream.tsx"; - /* eslint-disable no-console */ export type EndpointMetadata = { @@ -234,7 +233,7 @@ export function App() {
{connected ? "true" : "false"}

- +
{Object.values(remoteTracks).map( ({ stream, trackId, endpoint, metadata, rawMetadata, metadataParsingError }) => ( diff --git a/e2e/app/src/ReplaceTrackWithDummyStream.tsx b/e2e/app/src/ReplaceTrackWithDummyStream.tsx index 4af4be83..9d9b195b 100644 --- a/e2e/app/src/ReplaceTrackWithDummyStream.tsx +++ b/e2e/app/src/ReplaceTrackWithDummyStream.tsx @@ -1,7 +1,9 @@ -import { VideoPlayer } from "./VideoPlayer.tsx"; +import { VideoPlayer } from "./VideoPlayer"; import { useRef, useState } from "react"; import { WebRTCEndpoint } from "@fishjam-dev/ts-client"; +/* eslint-disable no-console */ + /* * Looks like Jellyfish handles track without simulcast properly * @@ -79,12 +81,12 @@ export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { const track = mediaStream.getVideoTracks()[0]; - if(videoStreamIdRef.current) { + if (videoStreamIdRef.current) { console.log("Replacing with camera"); webrtc.replaceTrack(videoStreamIdRef.current, track, undefined, "unmute"); } else { - console.log("Adding track") + console.log("Adding track"); videoStreamIdRef.current = await webrtc.addTrack( track, @@ -92,10 +94,10 @@ export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { { goodTrack: "camera" }, simulcastCheckbox ? { - enabled: true, - activeEncodings: ["l", "m", "h"], - disabledEncodings: [], - } + enabled: true, + activeEncodings: ["l", "m", "h"], + disabledEncodings: [], + } : undefined, ); } @@ -108,8 +110,8 @@ export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { console.log("replacing with null", videoStreamIdRef.current); - if(videoStreamIdRef.current) { - webrtc.replaceTrack(videoStreamIdRef.current, null, {goodTrack: "null"}, "mute") + if (videoStreamIdRef.current) { + webrtc.replaceTrack(videoStreamIdRef.current, null, { goodTrack: "null" }, "mute"); } }; @@ -205,7 +207,7 @@ export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { gap: "8px", borderStyle: "dashed", borderColor: "blue", - borderWidth: "2px" + borderWidth: "2px", }} > diff --git a/e2e/app/tsconfig.json b/e2e/app/tsconfig.json index a7fc6fbf..8ab2eecd 100644 --- a/e2e/app/tsconfig.json +++ b/e2e/app/tsconfig.json @@ -2,23 +2,19 @@ "compilerOptions": { "target": "ES2020", "useDefineForClassFields": true, - "lib": ["ES2020", "DOM", "DOM.Iterable"], - "module": "ESNext", + "lib": ["DOM", "DOM.Iterable", "ES2020"], + "module": "ES2020", + "allowJs": false, "skipLibCheck": true, - - /* Bundler mode */ - "moduleResolution": "bundler", - "allowImportingTsExtensions": true, + "esModuleInterop": false, + "allowSyntheticDefaultImports": true, + "strict": true, + "forceConsistentCasingInFileNames": true, + "moduleResolution": "Node", "resolveJsonModule": true, "isolatedModules": true, "noEmit": true, - "jsx": "react-jsx", - - /* Linting */ - "strict": true, - "noUnusedLocals": true, - "noUnusedParameters": true, - "noFallthroughCasesInSwitch": true + "jsx": "react-jsx" }, "include": ["src"], "references": [{ "path": "./tsconfig.node.json" }] diff --git a/protos b/protos index 83aa1514..a6f69712 160000 --- a/protos +++ b/protos @@ -1 +1 @@ -Subproject commit 83aa151401f9cd03fe91029d4ef2f8175fcf58f2 +Subproject commit a6f69712da283d13ae8b6e828694b48fce92a9e5 diff --git a/src/webrtc/commands.ts b/src/webrtc/commands.ts index 9299f499..e9d0655b 100644 --- a/src/webrtc/commands.ts +++ b/src/webrtc/commands.ts @@ -21,7 +21,7 @@ export type RemoveTrackCommand = { export type ReplaceTackCommand = { commandType: "REPLACE-TRACK"; trackId: string; - newTrack: MediaStreamTrack; + newTrack: MediaStreamTrack | null; newTrackMetadata?: TrackMetadata; resolutionNotifier: Deferred; }; diff --git a/src/webrtc/webRTCEndpoint.ts b/src/webrtc/webRTCEndpoint.ts index bd24ab69..527d21c8 100644 --- a/src/webrtc/webRTCEndpoint.ts +++ b/src/webrtc/webRTCEndpoint.ts @@ -14,6 +14,8 @@ import { AddTrackCommand, Command, RemoveTrackCommand, ReplaceTackCommand } from import { Deferred } from "./deferred"; export type MetadataParser = (rawMetadata: unknown) => ParsedMetadata; +type LocalTrackId = string; +type RemoteTrackId = string; /** * Interface describing Endpoint. @@ -351,7 +353,7 @@ export interface WebRTCEndpointEvents { localTrackRemoved: (event: { trackId: string }) => void; - localTrackReplaced: (event: { trackId: string; track: MediaStreamTrack; metadata?: TrackMetadata }) => void; + localTrackReplaced: (event: { trackId: string; track: MediaStreamTrack | null; metadata?: TrackMetadata }) => void; localTrackBandwidthSet: (event: { trackId: string; bandwidth: BandwidthLimit }) => void; @@ -389,7 +391,16 @@ export class WebRTCEndpoint extends rawMetadata: undefined, tracks: new Map(), }; - private localTrackIdToTrack: Map> = new Map(); + // todo this is remote trackId + private localTrackIdToTrack: Map> = new Map(); + private trackIdToSth: Map< + RemoteTrackId, + { + remoteTrackId: RemoteTrackId; + localTrackId: LocalTrackId | null; + sender: RTCRtpSender | null; + } + > = new Map(); private midToTrackId: Map = new Map(); private disabledTrackEncodings: Map = new Map(); private rtcConfig: RTCConfiguration = { @@ -410,7 +421,6 @@ export class WebRTCEndpoint extends private readonly endpointMetadataParser: MetadataParser; private readonly trackMetadataParser: MetadataParser; - private trackIdToSender: Record = {}; constructor(config?: Config) { super(); @@ -556,7 +566,7 @@ export class WebRTCEndpoint extends return this.bandwidthEstimation; } - private handleMediaEvent = (deserializedMediaEvent: MediaEvent) => { + private handleMediaEvent = async (deserializedMediaEvent: MediaEvent) => { let endpoint: Endpoint; let data; switch (deserializedMediaEvent.type) { @@ -630,7 +640,7 @@ export class WebRTCEndpoint extends } } - this.onAnswer(deserializedMediaEvent.data); + await this.onAnswer(deserializedMediaEvent.data); this.ongoingRenegotiation = false; this.processNextCommand(); @@ -978,7 +988,7 @@ export class WebRTCEndpoint extends const trackContextNew = this.localTrackIdToTrack.get(trackId)!; - console.log(`trackContextNew: ${trackContextNew}`); + console.log(`trackContextNew1: ${trackContextNew}`); console.log(trackContextNew); if (this.connection) { @@ -992,6 +1002,7 @@ export class WebRTCEndpoint extends ); } + this.trackIdToSth.set(trackId, { remoteTrackId: trackId, localTrackId: track.id, sender: null }); const mediaEvent = generateCustomEvent({ type: "renegotiateTracks" }); this.sendMediaEvent(mediaEvent); } @@ -1147,7 +1158,7 @@ export class WebRTCEndpoint extends * }) * ``` */ - public async replaceTrack(trackId: string, newTrack: MediaStreamTrack, newTrackMetadata?: any, muteAction?: "mute" | "unmute"): Promise { + public async replaceTrack(trackId: string, newTrack: MediaStreamTrack | null, newTrackMetadata?: any): Promise { const resolutionNotifier = new Deferred(); try { const newMetadata = newTrackMetadata !== undefined ? this.trackMetadataParser(newTrackMetadata) : undefined; @@ -1159,19 +1170,6 @@ export class WebRTCEndpoint extends newTrackMetadata: newMetadata, resolutionNotifier, }); - - if (muteAction == "mute") { - const mediaEvent = generateMediaEvent("muteTrack", { trackId: trackId }); - this.sendMediaEvent(mediaEvent); - console.log("sent mute event"); - } - - if (muteAction == "unmute") { - const mediaEvent = generateMediaEvent("unmuteTrack", { trackId: trackId }); - this.sendMediaEvent(mediaEvent); - console.log("sent unmute event"); - } - } catch (error) { resolutionNotifier.reject(error); } @@ -1190,34 +1188,45 @@ export class WebRTCEndpoint extends const trackContext = this.localTrackIdToTrack.get(trackId)!; console.log({ trackId, newTrack, newTrackMetadata, trackContext }); + console.log({ + sendersCount: this.connection?.getSenders()?.length, + senders: this.connection?.getSenders(), + }); - let sender: RTCRtpSender | null = null; - if (trackContext.track !== null) { - sender = this.findSender(trackContext.track!.id); - this.trackIdToSender[trackId] = sender; - } else { - sender = this.trackIdToSender[trackId]; - } + const track = this.trackIdToSth.get(trackId); + const sender: RTCRtpSender | null = track?.sender ?? null; - if (!sender) throw Error("Sender is empty!"); + if (!track) throw Error(`There is no track with id: ${trackId}`); + if (!sender) throw Error("There is no RTCRtpSender for this track id!"); - if (sender) { - this.ongoingTrackReplacement = true; - sender - .replaceTrack(newTrack) - .then(() => { - trackContext.track = newTrack; + this.ongoingTrackReplacement = true; - if (newTrackMetadata) { - this.updateTrackMetadata(trackId, newTrackMetadata); - } - }) - .finally(() => { - this.resolvePreviousCommand(); - this.ongoingTrackReplacement = false; - this.processNextCommand(); - }); + if (trackContext.track && !newTrack) { + const mediaEvent = generateMediaEvent("muteTrack", { trackId: trackId }); + this.sendMediaEvent(mediaEvent); + console.log("sent mute event"); + } else if (!trackContext.track && newTrack) { + const mediaEvent = generateMediaEvent("unmuteTrack", { trackId: trackId }); + this.sendMediaEvent(mediaEvent); + console.log("sent unmute event"); } + + track.localTrackId = newTrack?.id ?? null; + + sender + .replaceTrack(newTrack) + .then(() => { + trackContext.track = newTrack; + + if (newTrackMetadata) { + this.updateTrackMetadata(trackId, newTrackMetadata); + } + }) + .finally(() => { + this.resolvePreviousCommand(); + this.ongoingTrackReplacement = false; + this.processNextCommand(); + }); } /** @@ -1676,7 +1685,7 @@ export class WebRTCEndpoint extends private getTrackBitrates = (trackId: string) => { const trackContext = this.localTrackIdToTrack.get(trackId); - if (!trackContext) throw "Track with id ${trackId} not present in 'localTrackIdToTrack'"; + if (!trackContext) throw "Track with id ${trackId} not present in 'remoteTrackIdToTrack'"; const kind = trackContext.track!.kind as "audio" | "video"; const sender = this.findSender(trackContext.track!.id); const encodings = sender.getParameters().encodings; @@ -1726,6 +1735,25 @@ export class WebRTCEndpoint extends this.connection.restartIce(); } + // this.localTrackIdToSender = this.connection!.getSenders() + // .filter(sender => sender.track) + // .reduce((acc, sender) => { + // acc[sender!.track!.id] = sender; + // return acc; + // }, {} as Record); + + this.trackIdToSth.forEach((sth) => { + if (sth.localTrackId) { + sth.sender = this.findSender(sth.localTrackId); + } + }); + + console.log({ + sendersCount: this.connection?.getSenders()?.length, + senders: this.connection?.getSenders(), + trackIdToSth: this.trackIdToSth, + }); + this.addTransceiversIfNeeded(offerData); await this.createAndSendOffer(); From 5b984f4f59edbda813230feccf96a88f5bb36fd7 Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Tue, 28 May 2024 11:53:04 +0200 Subject: [PATCH 03/23] Remove console.logs --- src/webrtc/webRTCEndpoint.ts | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/webrtc/webRTCEndpoint.ts b/src/webrtc/webRTCEndpoint.ts index 527d21c8..6fe86e7b 100644 --- a/src/webrtc/webRTCEndpoint.ts +++ b/src/webrtc/webRTCEndpoint.ts @@ -986,11 +986,6 @@ export class WebRTCEndpoint extends this.localTrackIdToTrack.set(trackId, trackContext); - const trackContextNew = this.localTrackIdToTrack.get(trackId)!; - - console.log(`trackContextNew1: ${trackContextNew}`); - console.log(trackContextNew); - if (this.connection) { this.addTrackToConnection(trackContext); From 91c02331585b68f3ecff69afa8442b0da958c86d Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Tue, 28 May 2024 11:54:47 +0200 Subject: [PATCH 04/23] Remove logs --- src/webrtc/webRTCEndpoint.ts | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/src/webrtc/webRTCEndpoint.ts b/src/webrtc/webRTCEndpoint.ts index 6fe86e7b..2273e2a1 100644 --- a/src/webrtc/webRTCEndpoint.ts +++ b/src/webrtc/webRTCEndpoint.ts @@ -1182,12 +1182,6 @@ export class WebRTCEndpoint extends const trackContext = this.localTrackIdToTrack.get(trackId)!; - console.log({ trackId, newTrack, newTrackMetadata, trackContext }); - console.log({ - sendersCount: this.connection?.getSenders()?.length, - senders: this.connection?.getSenders(), - }); - const track = this.trackIdToSth.get(trackId); const sender: RTCRtpSender | null = track?.sender ?? null; @@ -1730,25 +1724,12 @@ export class WebRTCEndpoint extends this.connection.restartIce(); } - // this.localTrackIdToSender = this.connection!.getSenders() - // .filter(sender => sender.track) - // .reduce((acc, sender) => { - // acc[sender!.track!.id] = sender; - // return acc; - // }, {} as Record); - this.trackIdToSth.forEach((sth) => { if (sth.localTrackId) { sth.sender = this.findSender(sth.localTrackId); } }); - console.log({ - sendersCount: this.connection?.getSenders()?.length, - senders: this.connection?.getSenders(), - trackIdToSth: this.trackIdToSth, - }); - this.addTransceiversIfNeeded(offerData); await this.createAndSendOffer(); From f5732c8351bba483cf72fcd3f78f92b0aefba1ed Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Tue, 28 May 2024 15:48:26 +0200 Subject: [PATCH 05/23] Add component in e2e tests --- e2e/app/src/App.tsx | 11 +++--- e2e/app/src/MockComponent.tsx | 12 ++++--- e2e/app/src/MuteTrackTest.tsx | 66 +++++++++++++++++++++++++++++++++++ 3 files changed, 81 insertions(+), 8 deletions(-) create mode 100644 e2e/app/src/MuteTrackTest.tsx diff --git a/e2e/app/src/App.tsx b/e2e/app/src/App.tsx index 429997f4..a780cb14 100644 --- a/e2e/app/src/App.tsx +++ b/e2e/app/src/App.tsx @@ -7,13 +7,14 @@ import { WebRTCEndpointEvents, TrackContextEvents, BandwidthLimit, - SimulcastConfig, + SimulcastConfig } from "@fishjam-dev/ts-client"; import { PeerMessage } from "./protos/fishjam/peer_notifications"; import { useEffect, useState, useSyncExternalStore } from "react"; import { MockComponent } from "./MockComponent.tsx"; import { VideoPlayerWithDetector } from "./VideoPlayerWithDetector.tsx"; import { ReplaceTrackWithDummyStream } from "./ReplaceTrackWithDummyStream.tsx"; +import { MuteTrackTest } from "./MuteTrackTest"; /* eslint-disable no-console */ @@ -47,7 +48,8 @@ class RemoteStore { > = {}; invalidateCache: boolean = false; - constructor(private webrtc: WebRTCEndpoint) {} + constructor(private webrtc: WebRTCEndpoint) { + } subscribe(callback: () => void) { const cb = () => { @@ -199,7 +201,7 @@ export function App() { const [remoteEndpoints, remoteTracks] = useSyncExternalStore( (callback) => remoteTracksStore.subscribe(callback), - () => remoteTracksStore.snapshot(), + () => remoteTracksStore.snapshot() ); const setEncoding = (trackId: string, encoding: TrackEncoding) => { @@ -234,6 +236,7 @@ export function App() {
+
{Object.values(remoteTracks).map( ({ stream, trackId, endpoint, metadata, rawMetadata, metadataParsingError }) => ( @@ -254,7 +257,7 @@ export function App() {
- ), + ) )}
diff --git a/e2e/app/src/MockComponent.tsx b/e2e/app/src/MockComponent.tsx index 25e3f8d0..13a56f16 100644 --- a/e2e/app/src/MockComponent.tsx +++ b/e2e/app/src/MockComponent.tsx @@ -3,11 +3,12 @@ import { VideoPlayer } from "./VideoPlayer.tsx"; import { useRef, useState } from "react"; import { EndpointMetadata, TrackMetadata } from "./App.tsx"; import { BandwidthLimit, SimulcastConfig, WebRTCEndpoint } from "@fishjam-dev/ts-client"; +import { MuteTrackTest } from "./MuteTrackTest"; -const brainMock = createStream("🧠", "white", "low", 24); -const brain2Mock = createStream("🤯", "#00ff00", "low", 24); -const heartMock = createStream("🫀", "white", "low", 24); -const heart2Mock = createStream("💝", "#FF0000", "low", 24); +export const brainMock = createStream("🧠", "white", "low", 24); +export const brain2Mock = createStream("🤯", "#00ff00", "low", 24); +export const heartMock = createStream("🫀", "white", "low", 24); +export const heart2Mock = createStream("💝", "#FF0000", "low", 24); type Props = { webrtc: WebRTCEndpoint; @@ -107,6 +108,9 @@ export const MockComponent = ({ webrtc }: Props) => { {replaceStatus} + + +
diff --git a/e2e/app/src/MuteTrackTest.tsx b/e2e/app/src/MuteTrackTest.tsx new file mode 100644 index 00000000..d53474d1 --- /dev/null +++ b/e2e/app/src/MuteTrackTest.tsx @@ -0,0 +1,66 @@ +import { WebRTCEndpoint } from "@fishjam-dev/ts-client"; +import { VIDEO_TRACK_CONSTRAINTS } from "./ReplaceTrackWithDummyStream"; +import { brain2Mock, heart2Mock } from "./MockComponent"; +import { useRef, useState } from "react"; +import { VideoPlayer } from "./VideoPlayer"; + +type Props = { + webrtc: WebRTCEndpoint; +}; + +// todo +// - remove stream from addTrack - it should only require track +// - add track status to client: muted / active +// - replace currentStream with stream from ts-client +export const MuteTrackTest = ({ webrtc }: Props) => { + const remoteTracIdRef = useRef(null); + const [currentStream, setCurrentStream] = useState(); + const [trackId, setTrackId] = useState(); + + const addTrack = async (stream: MediaStream) => { + const track = stream.getVideoTracks()[0]; + + if (!track) throw Error("Stream doesn't have any track"); + + remoteTracIdRef.current = await webrtc.addTrack( + track, + stream, + { goodTrack: "camera" }, + { enabled: true, activeEncodings: ["l", "m", "h"], disabledEncodings: [] } + ); + setTrackId(remoteTracIdRef.current); + setCurrentStream(stream); + }; + + const replaceTrack = async (trackId: string | null, stream: MediaStream | null, track: MediaStreamTrack | null) => { + if (!trackId) throw Error("Track id is null"); + + await webrtc.replaceTrack(trackId, track); + setCurrentStream(stream); + }; + + + return
+
+
trackId: {trackId}
+
+ +
+ + + + + +
+ +
+ {currentStream && } +
+
; +}; From 2d207ffc901301a3c27c908c0cf9e0226fb25e39 Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Tue, 28 May 2024 18:33:14 +0200 Subject: [PATCH 06/23] Extend e2e/app --- e2e/app/src/App.tsx | 6 +- e2e/app/src/MockComponent.tsx | 6 +- e2e/app/src/MuteTrackTest.tsx | 42 +++--- e2e/app/src/ReplaceTrackWithDummyStream.tsx | 2 - e2e/app/src/VideoPlayerWithDetector.tsx | 41 +++++- src/FishjamClient.ts | 51 ++++--- src/reconnection.ts | 3 +- src/webrtc/webRTCEndpoint.ts | 152 +++++++++++--------- tests/methods/addTrackMethod.test.ts | 10 +- 9 files changed, 185 insertions(+), 128 deletions(-) diff --git a/e2e/app/src/App.tsx b/e2e/app/src/App.tsx index a780cb14..bbe58f4d 100644 --- a/e2e/app/src/App.tsx +++ b/e2e/app/src/App.tsx @@ -182,7 +182,7 @@ async function addScreenshareTrack(): Promise { const simulcastConfig: SimulcastConfig = { enabled: false, activeEncodings: [], disabledEncodings: [] }; const maxBandwidth: BandwidthLimit = 0; - return webrtc.addTrack(track, stream, trackMetadata, simulcastConfig, maxBandwidth); + return webrtc.addTrack(track, trackMetadata, simulcastConfig, maxBandwidth); } export function App() { @@ -234,9 +234,11 @@ export function App() {
{connected ? "true" : "false"}

+ +
{Object.values(remoteTracks).map( ({ stream, trackId, endpoint, metadata, rawMetadata, metadataParsingError }) => ( @@ -248,7 +250,7 @@ export function App() {
Error: {metadataParsingError}
- +
{stream?.id}
diff --git a/e2e/app/src/MockComponent.tsx b/e2e/app/src/MockComponent.tsx index 13a56f16..46a3c237 100644 --- a/e2e/app/src/MockComponent.tsx +++ b/e2e/app/src/MockComponent.tsx @@ -24,7 +24,7 @@ export const MockComponent = ({ webrtc }: Props) => { const stream = heartMock.stream; const track = stream.getVideoTracks()[0]; - heartId.current = webrtc.addTrack(track, stream, JSON.parse(trackMetadataInput)); + heartId.current = webrtc.addTrack(track, JSON.parse(trackMetadataInput)); }; const removeHeart = async () => { @@ -65,7 +65,7 @@ export const MockComponent = ({ webrtc }: Props) => { const simulcastConfig: SimulcastConfig = { enabled: false, activeEncodings: [], disabledEncodings: [] }; const maxBandwidth: BandwidthLimit = 0; - brainId.current = webrtc.addTrack(track, stream, JSON.parse(trackMetadataInput), simulcastConfig, maxBandwidth); + brainId.current = webrtc.addTrack(track, JSON.parse(trackMetadataInput), simulcastConfig, maxBandwidth); }; const addBoth = () => { @@ -109,8 +109,6 @@ export const MockComponent = ({ webrtc }: Props) => {
- -
diff --git a/e2e/app/src/MuteTrackTest.tsx b/e2e/app/src/MuteTrackTest.tsx index d53474d1..abdad353 100644 --- a/e2e/app/src/MuteTrackTest.tsx +++ b/e2e/app/src/MuteTrackTest.tsx @@ -1,42 +1,50 @@ import { WebRTCEndpoint } from "@fishjam-dev/ts-client"; -import { VIDEO_TRACK_CONSTRAINTS } from "./ReplaceTrackWithDummyStream"; import { brain2Mock, heart2Mock } from "./MockComponent"; -import { useRef, useState } from "react"; +import { useEffect, useState } from "react"; import { VideoPlayer } from "./VideoPlayer"; +import { WebRTCEndpointEvents } from "../../../src"; +import { EndpointMetadata, TrackMetadata } from "./App"; type Props = { webrtc: WebRTCEndpoint; }; + // todo -// - remove stream from addTrack - it should only require track -// - add track status to client: muted / active -// - replace currentStream with stream from ts-client +// - add track status to client: muted / active - X export const MuteTrackTest = ({ webrtc }: Props) => { - const remoteTracIdRef = useRef(null); const [currentStream, setCurrentStream] = useState(); - const [trackId, setTrackId] = useState(); + const [trackId, setTrackId] = useState(null); + + useEffect(() => { + const handler: WebRTCEndpointEvents["localTrackAdded"] = (event) => { + setCurrentStream(event.stream); + setTrackId(event.trackId); + }; + + webrtc.on("localTrackAdded", handler); + + return () => { + webrtc.removeListener("localTrackAdded", handler); + }; + }, []); const addTrack = async (stream: MediaStream) => { const track = stream.getVideoTracks()[0]; if (!track) throw Error("Stream doesn't have any track"); - remoteTracIdRef.current = await webrtc.addTrack( + await webrtc.addTrack( track, - stream, { goodTrack: "camera" }, { enabled: true, activeEncodings: ["l", "m", "h"], disabledEncodings: [] } ); - setTrackId(remoteTracIdRef.current); - setCurrentStream(stream); }; const replaceTrack = async (trackId: string | null, stream: MediaStream | null, track: MediaStreamTrack | null) => { if (!trackId) throw Error("Track id is null"); await webrtc.replaceTrack(trackId, track); - setCurrentStream(stream); }; @@ -49,14 +57,14 @@ export const MuteTrackTest = ({ webrtc }: Props) => { - +
diff --git a/e2e/app/src/ReplaceTrackWithDummyStream.tsx b/e2e/app/src/ReplaceTrackWithDummyStream.tsx index 9d9b195b..74246510 100644 --- a/e2e/app/src/ReplaceTrackWithDummyStream.tsx +++ b/e2e/app/src/ReplaceTrackWithDummyStream.tsx @@ -90,7 +90,6 @@ export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { videoStreamIdRef.current = await webrtc.addTrack( track, - mediaStream, { goodTrack: "camera" }, simulcastCheckbox ? { @@ -137,7 +136,6 @@ export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { videoStreamIdRef.current = await webrtc.addTrack( track, - videoStream, { source: "camera" }, simulcastCheckbox ? { diff --git a/e2e/app/src/VideoPlayerWithDetector.tsx b/e2e/app/src/VideoPlayerWithDetector.tsx index 69671b8a..aeea4a93 100644 --- a/e2e/app/src/VideoPlayerWithDetector.tsx +++ b/e2e/app/src/VideoPlayerWithDetector.tsx @@ -1,9 +1,11 @@ +import { WebRTCEndpoint } from "@fishjam-dev/ts-client"; import { useEffect, useRef, useState } from "react"; import { getPixel, Pixel } from "./mocks.ts"; type Props = { stream?: MediaStream; id?: string; + webrtc: WebRTCEndpoint }; const rgbToText = (pixel: Pixel): string => { @@ -17,17 +19,51 @@ const rgbToText = (pixel: Pixel): string => { return "unknown"; }; -export const VideoPlayerWithDetector = ({ stream, id }: Props) => { +const getGroupedStats = (stats: RTCStatsReport, type: string): Record => { + const result: Record = {}; + + stats.forEach((report) => { + if(report.type === type) { + result[report.id] = report + } + }); + + return result +}; + +export const VideoPlayerWithDetector = ({ stream, id, webrtc }: Props) => { const videoElementRef = useRef(null); const [color, setColor] = useState(""); + const [decodedFrames, setDecodedFrames] = useState(""); useEffect(() => { if (!videoElementRef.current) return; videoElementRef.current.srcObject = stream || null; }, [stream]); + const getDecodedFrames = async () => { + const connection = webrtc["connection"]; + if (!connection) return 0; + + const inbound = getGroupedStats(await connection.getStats(), "inbound-rtp"); + + const track = stream?.getVideoTracks()?.[0]; + return Object.values(inbound).find((report) => report.trackIdentifier === track?.id) + ?.framesDecoded ?? 0; + }; + + useEffect(() => { + const id = setInterval(async () => { + setDecodedFrames(await getDecodedFrames()); + }, 100); + + return () => { + clearInterval(id); + }; + }, []); + useEffect(() => { - const id = setInterval(() => { + const id = setInterval(async () => { const videoElement = videoElementRef.current; if (!videoElement || videoElement.videoWidth === 0) return; @@ -51,6 +87,7 @@ export const VideoPlayerWithDetector = ({ stream, id }: Props) => { return (
{color}
+
Decoded frames: {decodedFrames}
); diff --git a/src/FishjamClient.ts b/src/FishjamClient.ts index 4c6479b8..fb387bc3 100644 --- a/src/FishjamClient.ts +++ b/src/FishjamClient.ts @@ -8,7 +8,7 @@ import { TrackContext, TrackEncoding, MetadataParser, - WebRTCEndpointEvents, + WebRTCEndpointEvents } from "./webrtc"; import TypedEmitter from "typed-emitter"; import { EventEmitter } from "events"; @@ -23,10 +23,10 @@ export type Component = Omit( - endpoint: Endpoint, + endpoint: Endpoint ): endpoint is Peer => endpoint.type === "webrtc"; const isComponent = ( - endpoint: Endpoint, + endpoint: Endpoint ): endpoint is Component => endpoint.type === "recording" || endpoint.type === "hls" || @@ -74,7 +74,7 @@ export interface MessageEvents { joined: ( peerId: string, peers: Peer[], - components: Component[], + components: Component[] ) => void; /** @@ -154,7 +154,7 @@ export interface MessageEvents { */ tracksPriorityChanged: ( enabledTracks: TrackContext[], - disabledTracks: TrackContext[], + disabledTracks: TrackContext[] ) => void; /** @@ -166,35 +166,35 @@ export interface MessageEvents { bandwidthEstimationChanged: (estimation: bigint) => void; targetTrackEncodingRequested: ( - event: Parameters["targetTrackEncodingRequested"]>[0], + event: Parameters["targetTrackEncodingRequested"]>[0] ) => void; localTrackAdded: (event: Parameters["localTrackAdded"]>[0]) => void; localTrackRemoved: ( - event: Parameters["localTrackRemoved"]>[0], + event: Parameters["localTrackRemoved"]>[0] ) => void; localTrackReplaced: ( - event: Parameters["localTrackReplaced"]>[0], + event: Parameters["localTrackReplaced"]>[0] ) => void; localTrackBandwidthSet: ( - event: Parameters["localTrackBandwidthSet"]>[0], + event: Parameters["localTrackBandwidthSet"]>[0] ) => void; localTrackEncodingBandwidthSet: ( - event: Parameters["localTrackEncodingBandwidthSet"]>[0], + event: Parameters["localTrackEncodingBandwidthSet"]>[0] ) => void; localTrackEncodingEnabled: ( - event: Parameters["localTrackEncodingEnabled"]>[0], + event: Parameters["localTrackEncodingEnabled"]>[0] ) => void; localTrackEncodingDisabled: ( - event: Parameters["localTrackEncodingDisabled"]>[0], + event: Parameters["localTrackEncodingDisabled"]>[0] ) => void; localEndpointMetadataChanged: ( - event: Parameters["localEndpointMetadataChanged"]>[0], + event: Parameters["localEndpointMetadataChanged"]>[0] ) => void; localTrackMetadataChanged: ( - event: Parameters["localTrackMetadataChanged"]>[0], + event: Parameters["localTrackMetadataChanged"]>[0] ) => void; disconnectRequested: ( - event: Parameters["disconnectRequested"]>[0], + event: Parameters["disconnectRequested"]>[0] ) => void; } @@ -270,7 +270,7 @@ export type CreateConfig = { * ``` */ export class FishjamClient extends (EventEmitter as { - new (): TypedEmitter>>; + new(): TypedEmitter>>; }) { private websocket: WebSocket | null = null; private webrtc: WebRTCEndpoint | null = null; @@ -292,7 +292,7 @@ export class FishjamClient extends (EventEmitter as this.reconnectManager = new ReconnectManager( this, (peerMetadata) => this.initConnection(peerMetadata), - config?.reconnect, + config?.reconnect ); } @@ -326,7 +326,7 @@ export class FishjamClient extends (EventEmitter as this.webrtc = new WebRTCEndpoint({ endpointMetadataParser: this.peerMetadataParser, - trackMetadataParser: this.trackMetadataParser, + trackMetadataParser: this.trackMetadataParser }); this.initWebsocket(peerMetadata); @@ -444,7 +444,7 @@ export class FishjamClient extends (EventEmitter as acc[id] = peer; return acc; }, - {} as Record>, + {} as Record> ); } @@ -456,7 +456,7 @@ export class FishjamClient extends (EventEmitter as acc[id] = component; return acc; }, - {} as Record>, + {} as Record> ); } @@ -597,7 +597,7 @@ export class FishjamClient extends (EventEmitter as */ public on>( event: E, - listener: Required>[E], + listener: Required>[E] ): this { return super.on(event, listener); } @@ -620,7 +620,7 @@ export class FishjamClient extends (EventEmitter as */ public off>( event: E, - listener: Required>[E], + listener: Required>[E] ): this { return super.off(event, listener); } @@ -675,14 +675,13 @@ export class FishjamClient extends (EventEmitter as */ public addTrack( track: MediaStreamTrack, - stream: MediaStream, trackMetadata?: TrackMetadata, simulcastConfig: SimulcastConfig = { enabled: false, activeEncodings: [], disabledEncodings: [] }, - maxBandwidth: TrackBandwidthLimit = 0, // unlimited bandwidth + maxBandwidth: TrackBandwidthLimit = 0 // unlimited bandwidth ): Promise { if (!this.webrtc) throw this.handleWebRTCNotInitialized(); - return this.webrtc.addTrack(track, stream, trackMetadata, simulcastConfig, maxBandwidth); + return this.webrtc.addTrack(track, trackMetadata, simulcastConfig, maxBandwidth); } /** @@ -736,7 +735,7 @@ export class FishjamClient extends (EventEmitter as public async replaceTrack( trackId: string, newTrack: MediaStreamTrack, - newTrackMetadata?: TrackMetadata, + newTrackMetadata?: TrackMetadata ): Promise { if (!this.webrtc) throw this.handleWebRTCNotInitialized(); diff --git a/src/reconnection.ts b/src/reconnection.ts index 4e17eab2..fe195aed 100644 --- a/src/reconnection.ts +++ b/src/reconnection.ts @@ -121,11 +121,10 @@ export class ReconnectManager { if (this.lastLocalEndpoint && this.reconnectConfig.addTracksOnReconnect) { this.lastLocalEndpoint.tracks.forEach(async (track) => { - if (!track.track || !track.stream) return; + if (!track.track) return; await this.client.addTrack( track.track, - track.stream, track.rawMetadata, track.simulcastConfig, track.maxBandwidth, diff --git a/src/webrtc/webRTCEndpoint.ts b/src/webrtc/webRTCEndpoint.ts index 2273e2a1..fd2d28bf 100644 --- a/src/webrtc/webRTCEndpoint.ts +++ b/src/webrtc/webRTCEndpoint.ts @@ -4,7 +4,7 @@ import { generateMediaEvent, MediaEvent, SerializedMediaEvent, - serializeMediaEvent, + serializeMediaEvent } from "./mediaEvent"; import { v4 as uuidv4 } from "uuid"; import EventEmitter from "events"; @@ -179,18 +179,18 @@ export interface TrackContextEvents { export interface TrackContext extends TrackContextFields, - TypedEmitter>> {} + TypedEmitter>> { +} type TrackNegotiationStatus = "awaiting" | "offered" | "done"; class TrackContextImpl extends (EventEmitter as { - new (): TypedEmitter< + new(): TypedEmitter< Required> >; }) - implements TrackContext -{ + implements TrackContext { endpoint: Endpoint; trackId: string; track: MediaStreamTrack | null = null; @@ -214,7 +214,7 @@ class TrackContextImpl trackId: string, metadata: any, simulcastConfig: SimulcastConfig, - metadataParser: MetadataParser, + metadataParser: MetadataParser ) { super(); this.endpoint = endpoint; @@ -317,7 +317,7 @@ export interface WebRTCEndpointEvents { */ tracksPriorityChanged: ( enabledTracks: TrackContext[], - disabledTracks: TrackContext[], + disabledTracks: TrackContext[] ) => void; /** @@ -377,7 +377,7 @@ export type Config = { * Main class that is responsible for connecting to the RTC Engine, sending and receiving media. */ export class WebRTCEndpoint extends (EventEmitter as { - new (): TypedEmitter< + new(): TypedEmitter< Required> >; }) { @@ -389,7 +389,7 @@ export class WebRTCEndpoint extends type: "webrtc", metadata: undefined, rawMetadata: undefined, - tracks: new Map(), + tracks: new Map() }; // todo this is remote trackId private localTrackIdToTrack: Map> = new Map(); @@ -406,7 +406,7 @@ export class WebRTCEndpoint extends private rtcConfig: RTCConfiguration = { bundlePolicy: "max-bundle", iceServers: [], - iceTransportPolicy: "relay", + iceTransportPolicy: "relay" }; private bandwidthEstimation: bigint = BigInt(0); @@ -452,7 +452,7 @@ export class WebRTCEndpoint extends } this.localEndpoint.rawMetadata = metadata; const mediaEvent = generateMediaEvent("connect", { - metadata: this.localEndpoint.metadata, + metadata: this.localEndpoint.metadata }); this.sendMediaEvent(mediaEvent); }; @@ -484,7 +484,7 @@ export class WebRTCEndpoint extends const otherEndpoints: Endpoint[] = endpoints.map((endpoint) => { const tracks = this.mapMediaEventTracksToTrackContextImpl( new Map(Object.entries(endpoint.tracks)), - endpoint, + endpoint ); try { @@ -494,7 +494,7 @@ export class WebRTCEndpoint extends metadata: this.endpointMetadataParser(endpoint.metadata), rawMetadata: endpoint.metadata, metadataParsingError: undefined, - tracks, + tracks } satisfies Endpoint; } catch (error) { return { @@ -503,7 +503,7 @@ export class WebRTCEndpoint extends metadata: undefined, rawMetadata: endpoint.metadata, metadataParsingError: error, - tracks, + tracks } satisfies Endpoint; } }); @@ -631,7 +631,7 @@ export class WebRTCEndpoint extends if (track.pendingMetadataUpdate) { const mediaEvent = generateMediaEvent("updateTrackMetadata", { trackId, - trackMetadata: track.metadata, + trackMetadata: track.metadata }); this.sendMediaEvent(mediaEvent); } @@ -761,11 +761,11 @@ export class WebRTCEndpoint extends case "tracksPriority": { const enabledTracks = (deserializedMediaEvent.data.tracks as string[]).map( - (trackId) => this.trackIdToTrack.get(trackId)!, + (trackId) => this.trackIdToTrack.get(trackId)! ); const disabledTracks = Array.from(this.trackIdToTrack.values()).filter( - (track) => !enabledTracks.includes(track), + (track) => !enabledTracks.includes(track) ); this.emit("tracksPriorityChanged", enabledTracks, disabledTracks); @@ -860,20 +860,23 @@ export class WebRTCEndpoint extends * .forEach((track) => webrtc.addTrack(track, localStream)); * ``` */ - public addTrack( + public async addTrack( track: MediaStreamTrack, - stream: MediaStream, trackMetadata?: TrackMetadata, simulcastConfig: SimulcastConfig = { enabled: false, activeEncodings: [], disabledEncodings: [] }, - maxBandwidth: TrackBandwidthLimit = 0, + maxBandwidth: TrackBandwidthLimit = 0 ): Promise { const resolutionNotifier = new Deferred(); const trackId = this.getTrackId(uuidv4()); + const stream = new MediaStream(); let metadata: any; try { const parsedMetadata = this.trackMetadataParser(trackMetadata); metadata = parsedMetadata; + + stream.addTrack(track); + this.pushCommand({ commandType: "ADD-TRACK", trackId, @@ -882,23 +885,21 @@ export class WebRTCEndpoint extends trackMetadata: parsedMetadata, simulcastConfig, maxBandwidth, - resolutionNotifier, + resolutionNotifier }); } catch (error) { resolutionNotifier.reject(error); } - - return resolutionNotifier.promise.then(() => { - this.emit("localTrackAdded", { - trackId, - track, - stream, - trackMetadata: metadata, - simulcastConfig, - maxBandwidth, - }); - return trackId; + await resolutionNotifier.promise; + this.emit("localTrackAdded", { + trackId, + track, + stream, + trackMetadata: metadata, + simulcastConfig, + maxBandwidth }); + return trackId; } private pushCommand(command: Command) { @@ -975,7 +976,7 @@ export class WebRTCEndpoint extends trackId, trackMetadata, simulcastConfig, - this.trackMetadataParser, + this.trackMetadataParser ); trackContext.track = track; @@ -993,7 +994,7 @@ export class WebRTCEndpoint extends .getTransceivers() .forEach( (transceiver) => - (transceiver.direction = transceiver.direction === "sendrecv" ? "sendonly" : transceiver.direction), + (transceiver.direction = transceiver.direction === "sendrecv" ? "sendonly" : transceiver.direction) ); } @@ -1021,13 +1022,13 @@ export class WebRTCEndpoint extends } private createAudioTransceiverConfig( - trackContext: TrackContext, + trackContext: TrackContext ): RTCRtpTransceiverInit { return { direction: "sendonly", streams: trackContext.stream ? [trackContext.stream] : [] }; } private createVideoTransceiverConfig( - trackContext: TrackContext, + trackContext: TrackContext ): RTCRtpTransceiverInit { let transceiverConfig: RTCRtpTransceiverInit; if (trackContext.simulcastConfig!.enabled) { @@ -1047,10 +1048,10 @@ export class WebRTCEndpoint extends direction: "sendonly", sendEncodings: [ { - active: true, - }, + active: true + } ], - streams: trackContext.stream ? [trackContext.stream] : [], + streams: trackContext.stream ? [trackContext.stream] : [] }; } @@ -1097,7 +1098,7 @@ export class WebRTCEndpoint extends const firstScaleDownBy = encodings![0].scaleResolutionDownBy || 1; const bitrate_parts = encodings.reduce( (acc, value) => acc + (firstScaleDownBy / (value.scaleResolutionDownBy || 1)) ** 2, - 0, + 0 ); const x = bandwidth / bitrate_parts; @@ -1163,7 +1164,7 @@ export class WebRTCEndpoint extends trackId, newTrack, newTrackMetadata: newMetadata, - resolutionNotifier, + resolutionNotifier }); } catch (error) { resolutionNotifier.reject(error); @@ -1172,7 +1173,7 @@ export class WebRTCEndpoint extends this.emit("localTrackReplaced", { trackId, track: newTrack, - metadata: newTrackMetadata, + metadata: newTrackMetadata }); }); } @@ -1189,6 +1190,19 @@ export class WebRTCEndpoint extends if (!sender) throw Error("There is no RTCRtpSender for this track id!"); this.ongoingTrackReplacement = true; + console.log({ name: "1", trackContext, trackCount: trackContext.stream?.getTracks().length }); + + trackContext.stream?.getTracks().forEach((track) => { + trackContext.stream?.removeTrack(track); + }); + + console.log({ name: "2", trackContext, trackCount: trackContext.stream?.getTracks().length }); + + if (newTrack) { + trackContext.stream?.addTrack(newTrack); + } + + console.log({ name: "3", trackContext, trackCount: trackContext.stream?.getTracks().length }); if (trackContext.track && !newTrack) { const mediaEvent = generateMediaEvent("muteTrack", { trackId: trackId }); @@ -1200,6 +1214,8 @@ export class WebRTCEndpoint extends console.log("sent unmute event"); } + trackContext.track = newTrack; + track.localTrackId = newTrack?.id ?? null; sender @@ -1251,14 +1267,14 @@ export class WebRTCEndpoint extends type: "trackVariantBitrates", data: { trackId: trackId, - variantBitrates: this.getTrackBitrates(trackId), - }, + variantBitrates: this.getTrackBitrates(trackId) + } }); this.sendMediaEvent(mediaEvent); this.emit("localTrackBandwidthSet", { trackId, - bandwidth, + bandwidth }); return true; }) @@ -1299,14 +1315,14 @@ export class WebRTCEndpoint extends type: "trackVariantBitrates", data: { trackId: trackId, - variantBitrates: this.getTrackBitrates(trackId), - }, + variantBitrates: this.getTrackBitrates(trackId) + } }); this.sendMediaEvent(mediaEvent); this.emit("localTrackEncodingBandwidthSet", { trackId, rid, - bandwidth, + bandwidth }); return true; }) @@ -1345,11 +1361,11 @@ export class WebRTCEndpoint extends this.pushCommand({ commandType: "REMOVE-TRACK", trackId, - resolutionNotifier, + resolutionNotifier }); return resolutionNotifier.promise.then(() => { this.emit("localTrackRemoved", { - trackId, + trackId }); }); } @@ -1392,14 +1408,14 @@ export class WebRTCEndpoint extends type: "setTargetTrackVariant", data: { trackId: trackId, - variant, - }, + variant + } }); this.sendMediaEvent(mediaEvent); this.emit("targetTrackEncodingRequested", { trackId, - variant, + variant }); } @@ -1429,7 +1445,7 @@ export class WebRTCEndpoint extends this.sendMediaEvent(mediaEvent); this.emit("localTrackEncodingEnabled", { trackId, - encoding, + encoding }); } @@ -1455,7 +1471,7 @@ export class WebRTCEndpoint extends this.sendMediaEvent(mediaEvent); this.emit("localTrackEncodingDisabled", { trackId, - encoding, + encoding }); } @@ -1475,11 +1491,11 @@ export class WebRTCEndpoint extends this.localEndpoint.rawMetadata = this.localEndpoint.metadata; this.localEndpoint.metadataParsingError = undefined; const mediaEvent = generateMediaEvent("updateEndpointMetadata", { - metadata: this.localEndpoint.metadata, + metadata: this.localEndpoint.metadata }); this.sendMediaEvent(mediaEvent); this.emit("localEndpointMetadataChanged", { - metadata, + metadata }); }; @@ -1511,7 +1527,7 @@ export class WebRTCEndpoint extends const mediaEvent = generateMediaEvent("updateTrackMetadata", { trackId, - trackMetadata: trackContext.metadata, + trackMetadata: trackContext.metadata }); switch (trackContext.negotiationStatus) { @@ -1520,7 +1536,7 @@ export class WebRTCEndpoint extends this.emit("localTrackMetadataChanged", { trackId, - metadata: trackMetadata, + metadata: trackMetadata }); break; @@ -1543,7 +1559,7 @@ export class WebRTCEndpoint extends const mid = transceiver.mid; if (localTrackId && mid) { const trackContext = Array.from(this.localTrackIdToTrack.values()).find( - (trackContext) => trackContext!.track!.id === localTrackId, + (trackContext) => trackContext!.track!.id === localTrackId )!; localTrackMidToTrackId[mid] = trackContext.trackId; } @@ -1651,8 +1667,8 @@ export class WebRTCEndpoint extends sdpOffer: offer, trackIdToTrackMetadata: this.getTrackIdToMetadata(), trackIdToTrackBitrates: this.getTrackIdToTrackBitrates(), - midToTrackId: this.getMidToTrackId(), - }, + midToTrackId: this.getMidToTrackId() + } }); this.sendMediaEvent(mediaEvent); @@ -1754,8 +1770,8 @@ export class WebRTCEndpoint extends type: "candidate", data: { candidate: event.candidate.candidate, - sdpMLineIndex: event.candidate.sdpMLineIndex, - }, + sdpMLineIndex: event.candidate.sdpMLineIndex + } }); this.sendMediaEvent(mediaEvent); } @@ -1842,7 +1858,7 @@ export class WebRTCEndpoint extends const rtcIceServer: RTCIceServer = { credential: turnServer.password, urls: uri.concat(":", turnServer.serverAddr, ":", turnServer.serverPort, "?transport=", transport), - username: turnServer.username, + username: turnServer.username }; this.rtcConfig.iceServers!.push(rtcIceServer); @@ -1880,13 +1896,13 @@ export class WebRTCEndpoint extends private mapMediaEventTracksToTrackContextImpl = ( tracks: Map, - endpoint: Endpoint, + endpoint: Endpoint ): Map> => { const mappedTracks: Array<[string, TrackContextImpl]> = Array.from(tracks).map( ([trackId, track]) => [ trackId, - new TrackContextImpl(endpoint, trackId, track.metadata, track.simulcastConfig, this.trackMetadataParser), - ], + new TrackContextImpl(endpoint, trackId, track.metadata, track.simulcastConfig, this.trackMetadataParser) + ] ); return new Map(mappedTracks); diff --git a/tests/methods/addTrackMethod.test.ts b/tests/methods/addTrackMethod.test.ts index 8e82e874..721aed2f 100644 --- a/tests/methods/addTrackMethod.test.ts +++ b/tests/methods/addTrackMethod.test.ts @@ -1,5 +1,5 @@ import { WebRTCEndpoint } from "../../src"; -import { createConnectedEventWithOneEndpoint, stream, mockTrack } from "../fixtures"; +import { createConnectedEventWithOneEndpoint, mockTrack } from "../fixtures"; import { mockRTCPeerConnection } from "../mocks"; import { deserializeMediaEvent } from "../../src/webrtc/mediaEvent"; import { expect, it } from "vitest"; @@ -25,7 +25,7 @@ it("Adding track invokes renegotiation", () => }); // When - webRTCEndpoint.addTrack(mockTrack, stream); + webRTCEndpoint.addTrack(mockTrack); })); it("Adding track updates internal state", () => { @@ -36,7 +36,7 @@ it("Adding track updates internal state", () => { webRTCEndpoint.receiveMediaEvent(JSON.stringify(createConnectedEventWithOneEndpoint())); // When - webRTCEndpoint.addTrack(mockTrack, stream); + webRTCEndpoint.addTrack(mockTrack); // Then const localTrackIdToTrack = webRTCEndpoint["localTrackIdToTrack"]; @@ -52,7 +52,7 @@ it("Adding track before being accepted by the server throws error", async () => const webRTCEndpoint = new WebRTCEndpoint(); // When - await expect(() => webRTCEndpoint.addTrack(mockTrack, stream)).rejects.toThrow( + await expect(() => webRTCEndpoint.addTrack(mockTrack)).rejects.toThrow( "Cannot add tracks before being accepted by the server", ); }); @@ -69,6 +69,6 @@ it("Adding track with invalid metadata throws error", async () => { // When await expect(() => - webRTCEndpoint.addTrack(mockTrack, stream, { validMetadata: false } as unknown as TrackMetadata), + webRTCEndpoint.addTrack(mockTrack, { validMetadata: false } as unknown as TrackMetadata), ).rejects.toThrow("Invalid"); }); From b3eb2ef4c2d87fa168c3a62650b62cff368aa6aa Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Tue, 28 May 2024 19:34:43 +0200 Subject: [PATCH 07/23] e2e test POC --- e2e/app/src/App.tsx | 6 +- e2e/app/src/MockComponent.tsx | 7 +- e2e/app/src/MuteTrackTest.tsx | 4 +- e2e/app/src/ReplaceTrackWithDummyStream.tsx | 9 +-- e2e/app/src/VideoPlayerWithDetector.tsx | 27 +++---- e2e/scenarios/raceCondition.spec.ts | 31 +++++++- e2e/scenarios/utils.ts | 80 ++++++++++++++++----- 7 files changed, 119 insertions(+), 45 deletions(-) diff --git a/e2e/app/src/App.tsx b/e2e/app/src/App.tsx index bbe58f4d..b59a0215 100644 --- a/e2e/app/src/App.tsx +++ b/e2e/app/src/App.tsx @@ -11,9 +11,9 @@ import { } from "@fishjam-dev/ts-client"; import { PeerMessage } from "./protos/fishjam/peer_notifications"; import { useEffect, useState, useSyncExternalStore } from "react"; -import { MockComponent } from "./MockComponent.tsx"; -import { VideoPlayerWithDetector } from "./VideoPlayerWithDetector.tsx"; -import { ReplaceTrackWithDummyStream } from "./ReplaceTrackWithDummyStream.tsx"; +import { MockComponent } from "./MockComponent"; +import { VideoPlayerWithDetector } from "./VideoPlayerWithDetector"; +import { ReplaceTrackWithDummyStream } from "./ReplaceTrackWithDummyStream"; import { MuteTrackTest } from "./MuteTrackTest"; /* eslint-disable no-console */ diff --git a/e2e/app/src/MockComponent.tsx b/e2e/app/src/MockComponent.tsx index 46a3c237..ddf55517 100644 --- a/e2e/app/src/MockComponent.tsx +++ b/e2e/app/src/MockComponent.tsx @@ -1,9 +1,8 @@ -import { createStream } from "./mocks.ts"; -import { VideoPlayer } from "./VideoPlayer.tsx"; +import { createStream } from "./mocks"; +import { VideoPlayer } from "./VideoPlayer"; import { useRef, useState } from "react"; -import { EndpointMetadata, TrackMetadata } from "./App.tsx"; +import { EndpointMetadata, TrackMetadata } from "./App"; import { BandwidthLimit, SimulcastConfig, WebRTCEndpoint } from "@fishjam-dev/ts-client"; -import { MuteTrackTest } from "./MuteTrackTest"; export const brainMock = createStream("🧠", "white", "low", 24); export const brain2Mock = createStream("🤯", "#00ff00", "low", 24); diff --git a/e2e/app/src/MuteTrackTest.tsx b/e2e/app/src/MuteTrackTest.tsx index abdad353..767926ec 100644 --- a/e2e/app/src/MuteTrackTest.tsx +++ b/e2e/app/src/MuteTrackTest.tsx @@ -54,8 +54,8 @@ export const MuteTrackTest = ({ webrtc }: Props) => {
- + - +
diff --git a/e2e/app/src/ReplaceTrackWithDummyStream.tsx b/e2e/app/src/ReplaceTrackWithDummyStream.tsx index 74246510..07d38c57 100644 --- a/e2e/app/src/ReplaceTrackWithDummyStream.tsx +++ b/e2e/app/src/ReplaceTrackWithDummyStream.tsx @@ -71,11 +71,6 @@ export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { const startAndAddCamera = async () => { const mediaStream = await navigator.mediaDevices.getUserMedia({ video: VIDEO_TRACK_CONSTRAINTS, audio: false }); - console.log({ - mediaStream, - settings: mediaStream.getVideoTracks()[0].getSettings(), - tracks: videoStream?.getVideoTracks(), - }); setVideoStream(mediaStream); @@ -84,7 +79,7 @@ export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { if (videoStreamIdRef.current) { console.log("Replacing with camera"); - webrtc.replaceTrack(videoStreamIdRef.current, track, undefined, "unmute"); + webrtc.replaceTrack(videoStreamIdRef.current, track, undefined); } else { console.log("Adding track"); @@ -110,7 +105,7 @@ export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { console.log("replacing with null", videoStreamIdRef.current); if (videoStreamIdRef.current) { - webrtc.replaceTrack(videoStreamIdRef.current, null, { goodTrack: "null" }, "mute"); + webrtc.replaceTrack(videoStreamIdRef.current, null, { goodTrack: "null" }); } }; diff --git a/e2e/app/src/VideoPlayerWithDetector.tsx b/e2e/app/src/VideoPlayerWithDetector.tsx index aeea4a93..5f1339a2 100644 --- a/e2e/app/src/VideoPlayerWithDetector.tsx +++ b/e2e/app/src/VideoPlayerWithDetector.tsx @@ -1,6 +1,6 @@ import { WebRTCEndpoint } from "@fishjam-dev/ts-client"; import { useEffect, useRef, useState } from "react"; -import { getPixel, Pixel } from "./mocks.ts"; +import { getPixel, Pixel } from "./mocks"; type Props = { stream?: MediaStream; @@ -19,16 +19,16 @@ const rgbToText = (pixel: Pixel): string => { return "unknown"; }; -const getGroupedStats = (stats: RTCStatsReport, type: string): Record => { +const getTrackIdentifierToInboundRtp = (stats: RTCStatsReport): Record => { const result: Record = {}; stats.forEach((report) => { - if(report.type === type) { - result[report.id] = report + if (report.type === "inbound-rtp") { + result[report.trackIdentifier] = report; } }); - return result + return result; }; export const VideoPlayerWithDetector = ({ stream, id, webrtc }: Props) => { @@ -45,22 +45,25 @@ export const VideoPlayerWithDetector = ({ stream, id, webrtc }: Props) => { const connection = webrtc["connection"]; if (!connection) return 0; - const inbound = getGroupedStats(await connection.getStats(), "inbound-rtp"); + const inbound = getTrackIdentifierToInboundRtp(await connection.getStats()); - const track = stream?.getVideoTracks()?.[0]; - return Object.values(inbound).find((report) => report.trackIdentifier === track?.id) - ?.framesDecoded ?? 0; + const trackId = stream?.getVideoTracks()?.[0]?.id ?? ""; + + return inbound[trackId]?.framesDecoded ?? 0; }; useEffect(() => { const id = setInterval(async () => { - setDecodedFrames(await getDecodedFrames()); - }, 100); + const decodedFrames1 = await getDecodedFrames(); + console.log({ decodedFrames1 }); + + setDecodedFrames(decodedFrames1); + }, 1000); return () => { clearInterval(id); }; - }, []); + }, [stream]); useEffect(() => { const id = setInterval(async () => { diff --git a/e2e/scenarios/raceCondition.spec.ts b/e2e/scenarios/raceCondition.spec.ts index e7c82187..964ce0ab 100644 --- a/e2e/scenarios/raceCondition.spec.ts +++ b/e2e/scenarios/raceCondition.spec.ts @@ -7,12 +7,14 @@ import { assertThatBothTrackAreDifferent, assertThatOtherVideoIsPlaying, assertThatTrackBackgroundColorIsOk, + assertThatTrackIsPlaying, assertThatTrackReplaceStatusIsSuccess, clickButton, createAndJoinPeer, createRoom, removeTrack, takeScreenshot, + waitForDecodedFrames } from "./utils"; /* @@ -158,6 +160,34 @@ test("Slowly add and replace tracks", async ({ page: senderPage, context }) => { await assertThatTrackReplaceStatusIsSuccess(senderPage, "success"); }); +test("Replace track with null", async ({ page: senderPage, context }) => { + // given + await senderPage.goto("/"); + const roomId = await createRoom(senderPage); + + const senderId = await createAndJoinPeer(senderPage, roomId); + + const receiverPage = await context.newPage(); + await receiverPage.goto("/"); + + await createAndJoinPeer(receiverPage, roomId); + + // when + await clickButton(senderPage, "Add brain"); + await assertThatTrackBackgroundColorIsOk(receiverPage, senderId, "green"); + // await waitForDecodedFrames(receiverPage, senderId) + await assertThatTrackIsPlaying(receiverPage, senderId); + + await senderPage.waitForTimeout(500); + await clickButton(senderPage, "Mute track"); + + // then + await receiverPage.waitForTimeout(200) + // await assertThatTrackIsPlaying(receiverPage, senderId); + + // await assertThatTrackReplaceStatusIsSuccess(senderPage, "success"); +}); + test("RC: Quickly add and replace a track", async ({ page: senderPage, context }, testInfo) => { // given await senderPage.goto("/"); @@ -210,7 +240,6 @@ test("Add, replace and remove a track", async ({ page: senderPage, context }, te await takeScreenshot(receiverPage, testInfo); }); -// replca test("replaceTrack blocks client", async ({ page: senderPage, context }) => { // given await senderPage.goto("/"); diff --git a/e2e/scenarios/utils.ts b/e2e/scenarios/utils.ts index 5022dc8f..44dba7b6 100644 --- a/e2e/scenarios/utils.ts +++ b/e2e/scenarios/utils.ts @@ -15,7 +15,7 @@ export const createAndJoinPeer = async (page: Page, roomId: string): Promise { @@ -34,14 +34,14 @@ export const joinRoom = async ( page: Page, roomId: string, metadata?: any, - waitForConnection: boolean = true, + waitForConnection: boolean = true ): Promise => test.step("Join room", async () => { const peerRequest = await createPeer(page, roomId); try { const { peer: { id: peerId }, - token: peerToken, + token: peerToken } = (await peerRequest.json()).data; await page.getByPlaceholder("token").fill(peerToken); @@ -67,7 +67,7 @@ export const joinRoomAndAddScreenShare = async (page: Page, roomId: string): Pro try { const { peer: { id: peerId }, - token: peerToken, + token: peerToken } = (await peerRequest.json()).data; await test.step("Join room", async () => { @@ -95,7 +95,7 @@ export const throwIfRemoteTracksAreNotPresent = async (page: Page, otherClientId export const assertThatRemoteTracksAreVisible = async (page: Page, otherClientIds: string[]) => { await test.step("Assert that remote tracks are visible", async () => { const responses = await Promise.allSettled( - otherClientIds.map((peerId) => page.locator(`css=video[data-peer-id="${peerId}"]`)), + otherClientIds.map((peerId) => page.locator(`css=video[data-peer-id="${peerId}"]`)) ); const isAnyRejected = responses.some((e) => e.status === "rejected"); expect(isAnyRejected).toBe(false); @@ -135,7 +135,7 @@ export const takeScreenshot = async (page: Page, testInfo: TestInfo, name?: stri export const createRoom = async (page: Page, maxPeers?: number) => await test.step("Create room", async () => { const data = { - ...(maxPeers ? { maxPeers } : {}), + ...(maxPeers ? { maxPeers } : {}) }; const roomRequest = await page.request.post("http://localhost:5002/room", { data }); @@ -148,9 +148,9 @@ export const createPeer = async (page: Page, roomId: string, enableSimulcast: bo data: { type: "webrtc", options: { - enableSimulcast, - }, - }, + enableSimulcast + } + } }); }); @@ -169,7 +169,7 @@ export const addAndReplaceTrack = async (page: Page) => await page .getByRole("button", { name: "Add and replace a heart", - exact: true, + exact: true }) .click()); @@ -178,7 +178,7 @@ export const addAndRemoveTrack = async (page: Page) => await page .getByRole("button", { name: "Add and remove a heart", - exact: true, + exact: true }) .click()); @@ -187,7 +187,7 @@ export const addBothMockTracks = async (page: Page) => await page .getByRole("button", { name: "Add both", - exact: true, + exact: true }) .click()); @@ -196,10 +196,58 @@ export const assertThatAllTracksAreReady = async (page: Page, otherClientId: str expectWithLongerTimeout(page.locator(`div[data-endpoint-id="${otherClientId}"]`)).toHaveCount(tracks)); export const assertThatTrackBackgroundColorIsOk = async (page: Page, otherClientId: string, color: string) => - await test.step(`Assert that track background color is ${color}`, () => - expectWithLongerTimeout( - page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//div[@data-color-name="${color}"]`), - ).toBeVisible()); + await test.step(`Assert that track background color is ${color}`, () => { + page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//div[@data-color-name="${color}"]`); + + return expectWithLongerTimeout( + page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//div[@data-color-name="${color}"]`) + ).toBeVisible(); + }); + +const DECODED_FRAMES = "data-decoded-frames"; + +export const waitForDecodedFrames = async (page: Page, otherClientId: string) => + await test.step(`Wait for decoded frames`, async () => { + return expectWithLongerTimeout.poll(async () => { + const locator = await page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//span[@${DECODED_FRAMES}]`); + + const decodedFrames = await locator.getAttribute(DECODED_FRAMES) ?? "unknown"; + + return Number.parseInt(decodedFrames); + }).toBeGreaterThan(0); + }); + +export const assertThatTrackIsPlaying = async (page: Page, otherClientId: string) => + await test.step(`Assert that track is playing`, () => + expectWithLongerTimeout.poll( + async () => { + const locator = await page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//span[@${DECODED_FRAMES}]`); + + const decodedFrames = await locator.getAttribute(DECODED_FRAMES) ?? "unknown"; + await page.waitForTimeout(300); + const decodedFrames2 = await locator.getAttribute(DECODED_FRAMES) ?? "unknown"; + + console.log({ decodedFrames, decodedFrames2 }); + return Number.parseInt(decodedFrames2) - Number.parseInt(decodedFrames); + } + ).toBeGreaterThan(0) + ); + +export const assertThatTrackStopped = async (page: Page, otherClientId: string) => + await test.step(`Assert that track stopped`, () => + expectWithLongerTimeout.poll( + async () => { + const locator = await page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//span[@${DECODED_FRAMES}]`); + + const decodedFrames = await locator.getAttribute(DECODED_FRAMES) ?? "unknown"; + await page.waitForTimeout(300); + const decodedFrames2 = await locator.getAttribute(DECODED_FRAMES) ?? "unknown"; + + console.log({ decodedFrames, decodedFrames2 }); + return Number.parseInt(decodedFrames2) - Number.parseInt(decodedFrames); + } + ).toBe(0) + ); export const assertThatTrackReplaceStatusIsSuccess = async (page: Page, replaceStatus: string) => await test.step(`Assert that track background color is ${replaceStatus}`, async () => From 35869c5837efc7c4bfa388463cc608d9c0b2771e Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Wed, 29 May 2024 13:44:43 +0200 Subject: [PATCH 08/23] Update e2e --- e2e/app/src/ReplaceTrackWithDummyStream.tsx | 24 ++++----- e2e/app/src/VideoPlayerWithDetector.tsx | 7 +-- e2e/scenarios/raceCondition.spec.ts | 30 ----------- e2e/scenarios/replaceTrack.spec.ts | 57 +++++++++++++++++++++ e2e/scenarios/utils.ts | 2 - 5 files changed, 71 insertions(+), 49 deletions(-) create mode 100644 e2e/scenarios/replaceTrack.spec.ts diff --git a/e2e/app/src/ReplaceTrackWithDummyStream.tsx b/e2e/app/src/ReplaceTrackWithDummyStream.tsx index 07d38c57..ad9f1331 100644 --- a/e2e/app/src/ReplaceTrackWithDummyStream.tsx +++ b/e2e/app/src/ReplaceTrackWithDummyStream.tsx @@ -20,17 +20,17 @@ export const VIDEO_TRACK_CONSTRAINTS: MediaTrackConstraints = { width: { max: 1280, ideal: 1280, - min: 640, + min: 640 }, height: { max: 720, ideal: 720, - min: 320, + min: 320 }, frameRate: { max: 30, - ideal: 24, - }, + ideal: 24 + } }; type Props = { @@ -39,7 +39,7 @@ type Props = { const createDummyStream = ( width: number = 1280, - height: number = 720, + height: number = 720 ): { stream: MediaStream; track: MediaStreamTrack; @@ -114,7 +114,7 @@ export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { console.log({ mediaStream, settings: mediaStream.getVideoTracks()[0].getSettings(), - tracks: videoStream?.getVideoTracks(), + tracks: videoStream?.getVideoTracks() }); setVideoStream(mediaStream); }; @@ -134,11 +134,11 @@ export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { { source: "camera" }, simulcastCheckbox ? { - enabled: true, - activeEncodings: ["l", "m", "h"], - disabledEncodings: [], - } - : undefined, + enabled: true, + activeEncodings: ["l", "m", "h"], + disabledEncodings: [] + } + : undefined ); }; @@ -200,7 +200,7 @@ export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { gap: "8px", borderStyle: "dashed", borderColor: "blue", - borderWidth: "2px", + borderWidth: "2px" }} > diff --git a/e2e/app/src/VideoPlayerWithDetector.tsx b/e2e/app/src/VideoPlayerWithDetector.tsx index 5f1339a2..2f1a70e8 100644 --- a/e2e/app/src/VideoPlayerWithDetector.tsx +++ b/e2e/app/src/VideoPlayerWithDetector.tsx @@ -54,11 +54,8 @@ export const VideoPlayerWithDetector = ({ stream, id, webrtc }: Props) => { useEffect(() => { const id = setInterval(async () => { - const decodedFrames1 = await getDecodedFrames(); - console.log({ decodedFrames1 }); - - setDecodedFrames(decodedFrames1); - }, 1000); + setDecodedFrames(await getDecodedFrames()); + }, 50); return () => { clearInterval(id); diff --git a/e2e/scenarios/raceCondition.spec.ts b/e2e/scenarios/raceCondition.spec.ts index 964ce0ab..3fa811f4 100644 --- a/e2e/scenarios/raceCondition.spec.ts +++ b/e2e/scenarios/raceCondition.spec.ts @@ -7,14 +7,12 @@ import { assertThatBothTrackAreDifferent, assertThatOtherVideoIsPlaying, assertThatTrackBackgroundColorIsOk, - assertThatTrackIsPlaying, assertThatTrackReplaceStatusIsSuccess, clickButton, createAndJoinPeer, createRoom, removeTrack, takeScreenshot, - waitForDecodedFrames } from "./utils"; /* @@ -160,34 +158,6 @@ test("Slowly add and replace tracks", async ({ page: senderPage, context }) => { await assertThatTrackReplaceStatusIsSuccess(senderPage, "success"); }); -test("Replace track with null", async ({ page: senderPage, context }) => { - // given - await senderPage.goto("/"); - const roomId = await createRoom(senderPage); - - const senderId = await createAndJoinPeer(senderPage, roomId); - - const receiverPage = await context.newPage(); - await receiverPage.goto("/"); - - await createAndJoinPeer(receiverPage, roomId); - - // when - await clickButton(senderPage, "Add brain"); - await assertThatTrackBackgroundColorIsOk(receiverPage, senderId, "green"); - // await waitForDecodedFrames(receiverPage, senderId) - await assertThatTrackIsPlaying(receiverPage, senderId); - - await senderPage.waitForTimeout(500); - await clickButton(senderPage, "Mute track"); - - // then - await receiverPage.waitForTimeout(200) - // await assertThatTrackIsPlaying(receiverPage, senderId); - - // await assertThatTrackReplaceStatusIsSuccess(senderPage, "success"); -}); - test("RC: Quickly add and replace a track", async ({ page: senderPage, context }, testInfo) => { // given await senderPage.goto("/"); diff --git a/e2e/scenarios/replaceTrack.spec.ts b/e2e/scenarios/replaceTrack.spec.ts new file mode 100644 index 00000000..165a0e98 --- /dev/null +++ b/e2e/scenarios/replaceTrack.spec.ts @@ -0,0 +1,57 @@ +import { test } from "@playwright/test"; +import { + assertThatTrackBackgroundColorIsOk, + assertThatTrackIsPlaying, + assertThatTrackStopped, + clickButton, + createAndJoinPeer, + createRoom, +} from "./utils"; + + +test("Replace track with null", async ({ page: senderPage, context }) => { + // given + await senderPage.goto("/"); + const roomId = await createRoom(senderPage); + + const senderId = await createAndJoinPeer(senderPage, roomId); + + const receiverPage = await context.newPage(); + await receiverPage.goto("/"); + + await createAndJoinPeer(receiverPage, roomId); + + // when + await clickButton(senderPage, "Add brain"); + await assertThatTrackBackgroundColorIsOk(receiverPage, senderId, "green"); + await assertThatTrackIsPlaying(receiverPage, senderId); + await clickButton(senderPage, "Mute track"); + + // then + await assertThatTrackStopped(receiverPage, senderId); +}); + +test("Mute and unmute track", async ({ page: senderPage, context }) => { + // given + await senderPage.goto("/"); + const roomId = await createRoom(senderPage); + + const senderId = await createAndJoinPeer(senderPage, roomId); + + const receiverPage = await context.newPage(); + await receiverPage.goto("/"); + + await createAndJoinPeer(receiverPage, roomId); + + // when + await clickButton(senderPage, "Add brain"); + await assertThatTrackBackgroundColorIsOk(receiverPage, senderId, "green"); + await assertThatTrackIsPlaying(receiverPage, senderId); + await clickButton(senderPage, "Mute track"); + await assertThatTrackStopped(receiverPage, senderId); + await clickButton(senderPage, "Replace with heart"); + + // then + await assertThatTrackBackgroundColorIsOk(receiverPage, senderId, "red"); + await assertThatTrackIsPlaying(receiverPage, senderId); +}); diff --git a/e2e/scenarios/utils.ts b/e2e/scenarios/utils.ts index 44dba7b6..0b20fcd4 100644 --- a/e2e/scenarios/utils.ts +++ b/e2e/scenarios/utils.ts @@ -227,7 +227,6 @@ export const assertThatTrackIsPlaying = async (page: Page, otherClientId: string await page.waitForTimeout(300); const decodedFrames2 = await locator.getAttribute(DECODED_FRAMES) ?? "unknown"; - console.log({ decodedFrames, decodedFrames2 }); return Number.parseInt(decodedFrames2) - Number.parseInt(decodedFrames); } ).toBeGreaterThan(0) @@ -243,7 +242,6 @@ export const assertThatTrackStopped = async (page: Page, otherClientId: string) await page.waitForTimeout(300); const decodedFrames2 = await locator.getAttribute(DECODED_FRAMES) ?? "unknown"; - console.log({ decodedFrames, decodedFrames2 }); return Number.parseInt(decodedFrames2) - Number.parseInt(decodedFrames); } ).toBe(0) From 6fb4f83b50f87774df718472f7264c52f72804cd Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Wed, 29 May 2024 14:13:32 +0200 Subject: [PATCH 09/23] Update test page --- e2e/app/package-lock.json | 39 +++++++++++++++++++++++++++++++++++ e2e/app/package.json | 1 + e2e/app/src/App.tsx | 2 +- e2e/app/src/MuteTrackTest.tsx | 29 ++++++++++++++++++-------- 4 files changed, 61 insertions(+), 10 deletions(-) diff --git a/e2e/app/package-lock.json b/e2e/app/package-lock.json index 94394286..5fe1c798 100644 --- a/e2e/app/package-lock.json +++ b/e2e/app/package-lock.json @@ -12,6 +12,7 @@ "protobufjs": "^7.2.6", "react": "^18.2.0", "react-dom": "^18.2.0", + "react-router-dom": "^6.23.1", "ts-proto": "^1.167.3" }, "devDependencies": { @@ -4535,6 +4536,14 @@ "version": "1.1.0", "license": "BSD-3-Clause" }, + "node_modules/@remix-run/router": { + "version": "1.16.1", + "resolved": "https://registry.npmjs.org/@remix-run/router/-/router-1.16.1.tgz", + "integrity": "sha512-es2g3dq6Nb07iFxGk5GuHN20RwBZOsuDQN7izWIisUcv9r+d2C5jQxqmgkdebXgReWfiyUabcki6Fg77mSNrig==", + "engines": { + "node": ">=14.0.0" + } + }, "node_modules/@rollup/rollup-darwin-arm64": { "version": "4.17.2", "cpu": [ @@ -6160,6 +6169,36 @@ "node": ">=0.10.0" } }, + "node_modules/react-router": { + "version": "6.23.1", + "resolved": "https://registry.npmjs.org/react-router/-/react-router-6.23.1.tgz", + "integrity": "sha512-fzcOaRF69uvqbbM7OhvQyBTFDVrrGlsFdS3AL+1KfIBtGETibHzi3FkoTRyiDJnWNc2VxrfvR+657ROHjaNjqQ==", + "dependencies": { + "@remix-run/router": "1.16.1" + }, + "engines": { + "node": ">=14.0.0" + }, + "peerDependencies": { + "react": ">=16.8" + } + }, + "node_modules/react-router-dom": { + "version": "6.23.1", + "resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-6.23.1.tgz", + "integrity": "sha512-utP+K+aSTtEdbWpC+4gxhdlPFwuEfDKq8ZrPFU65bbRJY+l706qjR7yaidBpo3MSeA/fzwbXWbKBI6ftOnP3OQ==", + "dependencies": { + "@remix-run/router": "1.16.1", + "react-router": "6.23.1" + }, + "engines": { + "node": ">=14.0.0" + }, + "peerDependencies": { + "react": ">=16.8", + "react-dom": ">=16.8" + } + }, "node_modules/resolve-from": { "version": "4.0.0", "dev": true, diff --git a/e2e/app/package.json b/e2e/app/package.json index bf0c1ec8..92cdcf67 100644 --- a/e2e/app/package.json +++ b/e2e/app/package.json @@ -14,6 +14,7 @@ "protobufjs": "^7.2.6", "react": "^18.2.0", "react-dom": "^18.2.0", + "react-router-dom": "^6.23.1", "ts-proto": "^1.167.3" }, "devDependencies": { diff --git a/e2e/app/src/App.tsx b/e2e/app/src/App.tsx index b59a0215..a8b57da7 100644 --- a/e2e/app/src/App.tsx +++ b/e2e/app/src/App.tsx @@ -236,7 +236,7 @@ export function App() {
- + {/**/}
diff --git a/e2e/app/src/MuteTrackTest.tsx b/e2e/app/src/MuteTrackTest.tsx index 767926ec..68939597 100644 --- a/e2e/app/src/MuteTrackTest.tsx +++ b/e2e/app/src/MuteTrackTest.tsx @@ -9,23 +9,28 @@ type Props = { webrtc: WebRTCEndpoint; }; - -// todo -// - add track status to client: muted / active - X export const MuteTrackTest = ({ webrtc }: Props) => { const [currentStream, setCurrentStream] = useState(); + const [currentTrack, setCurrentTrack] = useState(); const [trackId, setTrackId] = useState(null); useEffect(() => { - const handler: WebRTCEndpointEvents["localTrackAdded"] = (event) => { + const localTrackAdded: WebRTCEndpointEvents["localTrackAdded"] = (event) => { setCurrentStream(event.stream); + setCurrentTrack(event.track); setTrackId(event.trackId); }; - webrtc.on("localTrackAdded", handler); + const localTrackReplaced: WebRTCEndpointEvents["localTrackReplaced"] = (event) => { + setCurrentTrack(event.track); + }; + + webrtc.on("localTrackAdded", localTrackAdded); + webrtc.on("localTrackReplaced", localTrackReplaced); return () => { - webrtc.removeListener("localTrackAdded", handler); + webrtc.removeListener("localTrackAdded", localTrackAdded); + webrtc.removeListener("localTrackReplaced", localTrackReplaced); }; }, []); @@ -48,11 +53,17 @@ export const MuteTrackTest = ({ webrtc }: Props) => { }; - return
+ return
-
trackId: {trackId}
+ track: {currentTrack?.id ?? "null"}
-
From 065d75742f07b2b1c04c65deb86df6b6389ee2f9 Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Wed, 29 May 2024 14:16:11 +0200 Subject: [PATCH 10/23] Remove router --- e2e/app/package-lock.json | 39 --------------------------------------- e2e/app/package.json | 1 - 2 files changed, 40 deletions(-) diff --git a/e2e/app/package-lock.json b/e2e/app/package-lock.json index 5fe1c798..94394286 100644 --- a/e2e/app/package-lock.json +++ b/e2e/app/package-lock.json @@ -12,7 +12,6 @@ "protobufjs": "^7.2.6", "react": "^18.2.0", "react-dom": "^18.2.0", - "react-router-dom": "^6.23.1", "ts-proto": "^1.167.3" }, "devDependencies": { @@ -4536,14 +4535,6 @@ "version": "1.1.0", "license": "BSD-3-Clause" }, - "node_modules/@remix-run/router": { - "version": "1.16.1", - "resolved": "https://registry.npmjs.org/@remix-run/router/-/router-1.16.1.tgz", - "integrity": "sha512-es2g3dq6Nb07iFxGk5GuHN20RwBZOsuDQN7izWIisUcv9r+d2C5jQxqmgkdebXgReWfiyUabcki6Fg77mSNrig==", - "engines": { - "node": ">=14.0.0" - } - }, "node_modules/@rollup/rollup-darwin-arm64": { "version": "4.17.2", "cpu": [ @@ -6169,36 +6160,6 @@ "node": ">=0.10.0" } }, - "node_modules/react-router": { - "version": "6.23.1", - "resolved": "https://registry.npmjs.org/react-router/-/react-router-6.23.1.tgz", - "integrity": "sha512-fzcOaRF69uvqbbM7OhvQyBTFDVrrGlsFdS3AL+1KfIBtGETibHzi3FkoTRyiDJnWNc2VxrfvR+657ROHjaNjqQ==", - "dependencies": { - "@remix-run/router": "1.16.1" - }, - "engines": { - "node": ">=14.0.0" - }, - "peerDependencies": { - "react": ">=16.8" - } - }, - "node_modules/react-router-dom": { - "version": "6.23.1", - "resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-6.23.1.tgz", - "integrity": "sha512-utP+K+aSTtEdbWpC+4gxhdlPFwuEfDKq8ZrPFU65bbRJY+l706qjR7yaidBpo3MSeA/fzwbXWbKBI6ftOnP3OQ==", - "dependencies": { - "@remix-run/router": "1.16.1", - "react-router": "6.23.1" - }, - "engines": { - "node": ">=14.0.0" - }, - "peerDependencies": { - "react": ">=16.8", - "react-dom": ">=16.8" - } - }, "node_modules/resolve-from": { "version": "4.0.0", "dev": true, diff --git a/e2e/app/package.json b/e2e/app/package.json index 92cdcf67..bf0c1ec8 100644 --- a/e2e/app/package.json +++ b/e2e/app/package.json @@ -14,7 +14,6 @@ "protobufjs": "^7.2.6", "react": "^18.2.0", "react-dom": "^18.2.0", - "react-router-dom": "^6.23.1", "ts-proto": "^1.167.3" }, "devDependencies": { From a15ad23eb6b622b57dcd6e31ed4831d784317306 Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Wed, 29 May 2024 14:19:59 +0200 Subject: [PATCH 11/23] Fix prettier --- e2e/app/src/App.tsx | 11 +- e2e/app/src/MuteTrackTest.tsx | 61 ++++++----- e2e/app/src/ReplaceTrackWithDummyStream.tsx | 24 ++--- e2e/app/src/VideoPlayerWithDetector.tsx | 6 +- e2e/scenarios/replaceTrack.spec.ts | 1 - e2e/scenarios/utils.ts | 74 +++++++------ src/FishjamClient.ts | 48 ++++----- src/reconnection.ts | 7 +- src/webrtc/webRTCEndpoint.ts | 112 ++++++++++---------- 9 files changed, 174 insertions(+), 170 deletions(-) diff --git a/e2e/app/src/App.tsx b/e2e/app/src/App.tsx index a8b57da7..3390d399 100644 --- a/e2e/app/src/App.tsx +++ b/e2e/app/src/App.tsx @@ -7,7 +7,7 @@ import { WebRTCEndpointEvents, TrackContextEvents, BandwidthLimit, - SimulcastConfig + SimulcastConfig, } from "@fishjam-dev/ts-client"; import { PeerMessage } from "./protos/fishjam/peer_notifications"; import { useEffect, useState, useSyncExternalStore } from "react"; @@ -48,8 +48,7 @@ class RemoteStore { > = {}; invalidateCache: boolean = false; - constructor(private webrtc: WebRTCEndpoint) { - } + constructor(private webrtc: WebRTCEndpoint) {} subscribe(callback: () => void) { const cb = () => { @@ -201,7 +200,7 @@ export function App() { const [remoteEndpoints, remoteTracks] = useSyncExternalStore( (callback) => remoteTracksStore.subscribe(callback), - () => remoteTracksStore.snapshot() + () => remoteTracksStore.snapshot(), ); const setEncoding = (trackId: string, encoding: TrackEncoding) => { @@ -237,7 +236,7 @@ export function App() { {/**/} - +
{Object.values(remoteTracks).map( @@ -259,7 +258,7 @@ export function App() {
- ) + ), )}
diff --git a/e2e/app/src/MuteTrackTest.tsx b/e2e/app/src/MuteTrackTest.tsx index 68939597..e4dbe921 100644 --- a/e2e/app/src/MuteTrackTest.tsx +++ b/e2e/app/src/MuteTrackTest.tsx @@ -42,7 +42,7 @@ export const MuteTrackTest = ({ webrtc }: Props) => { await webrtc.addTrack( track, { goodTrack: "camera" }, - { enabled: true, activeEncodings: ["l", "m", "h"], disabledEncodings: [] } + { enabled: true, activeEncodings: ["l", "m", "h"], disabledEncodings: [] }, ); }; @@ -52,34 +52,37 @@ export const MuteTrackTest = ({ webrtc }: Props) => { await webrtc.replaceTrack(trackId, track); }; + return ( +
+
+ track: {currentTrack?.id ?? "null"} +
+
+ + + + + +
- return
-
- track: {currentTrack?.id ?? "null"} +
{currentStream && }
-
- - - - - -
- -
- {currentStream && } -
-
; + ); }; diff --git a/e2e/app/src/ReplaceTrackWithDummyStream.tsx b/e2e/app/src/ReplaceTrackWithDummyStream.tsx index ad9f1331..07d38c57 100644 --- a/e2e/app/src/ReplaceTrackWithDummyStream.tsx +++ b/e2e/app/src/ReplaceTrackWithDummyStream.tsx @@ -20,17 +20,17 @@ export const VIDEO_TRACK_CONSTRAINTS: MediaTrackConstraints = { width: { max: 1280, ideal: 1280, - min: 640 + min: 640, }, height: { max: 720, ideal: 720, - min: 320 + min: 320, }, frameRate: { max: 30, - ideal: 24 - } + ideal: 24, + }, }; type Props = { @@ -39,7 +39,7 @@ type Props = { const createDummyStream = ( width: number = 1280, - height: number = 720 + height: number = 720, ): { stream: MediaStream; track: MediaStreamTrack; @@ -114,7 +114,7 @@ export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { console.log({ mediaStream, settings: mediaStream.getVideoTracks()[0].getSettings(), - tracks: videoStream?.getVideoTracks() + tracks: videoStream?.getVideoTracks(), }); setVideoStream(mediaStream); }; @@ -134,11 +134,11 @@ export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { { source: "camera" }, simulcastCheckbox ? { - enabled: true, - activeEncodings: ["l", "m", "h"], - disabledEncodings: [] - } - : undefined + enabled: true, + activeEncodings: ["l", "m", "h"], + disabledEncodings: [], + } + : undefined, ); }; @@ -200,7 +200,7 @@ export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { gap: "8px", borderStyle: "dashed", borderColor: "blue", - borderWidth: "2px" + borderWidth: "2px", }} > diff --git a/e2e/app/src/VideoPlayerWithDetector.tsx b/e2e/app/src/VideoPlayerWithDetector.tsx index 2f1a70e8..599fba23 100644 --- a/e2e/app/src/VideoPlayerWithDetector.tsx +++ b/e2e/app/src/VideoPlayerWithDetector.tsx @@ -5,7 +5,7 @@ import { getPixel, Pixel } from "./mocks"; type Props = { stream?: MediaStream; id?: string; - webrtc: WebRTCEndpoint + webrtc: WebRTCEndpoint; }; const rgbToText = (pixel: Pixel): string => { @@ -87,7 +87,9 @@ export const VideoPlayerWithDetector = ({ stream, id, webrtc }: Props) => { return (
{color}
-
Decoded frames: {decodedFrames}
+
+ Decoded frames: {decodedFrames} +
); diff --git a/e2e/scenarios/replaceTrack.spec.ts b/e2e/scenarios/replaceTrack.spec.ts index 165a0e98..9b7bdee0 100644 --- a/e2e/scenarios/replaceTrack.spec.ts +++ b/e2e/scenarios/replaceTrack.spec.ts @@ -8,7 +8,6 @@ import { createRoom, } from "./utils"; - test("Replace track with null", async ({ page: senderPage, context }) => { // given await senderPage.goto("/"); diff --git a/e2e/scenarios/utils.ts b/e2e/scenarios/utils.ts index 0b20fcd4..73595b2e 100644 --- a/e2e/scenarios/utils.ts +++ b/e2e/scenarios/utils.ts @@ -15,7 +15,7 @@ export const createAndJoinPeer = async (page: Page, roomId: string): Promise { @@ -34,14 +34,14 @@ export const joinRoom = async ( page: Page, roomId: string, metadata?: any, - waitForConnection: boolean = true + waitForConnection: boolean = true, ): Promise => test.step("Join room", async () => { const peerRequest = await createPeer(page, roomId); try { const { peer: { id: peerId }, - token: peerToken + token: peerToken, } = (await peerRequest.json()).data; await page.getByPlaceholder("token").fill(peerToken); @@ -67,7 +67,7 @@ export const joinRoomAndAddScreenShare = async (page: Page, roomId: string): Pro try { const { peer: { id: peerId }, - token: peerToken + token: peerToken, } = (await peerRequest.json()).data; await test.step("Join room", async () => { @@ -95,7 +95,7 @@ export const throwIfRemoteTracksAreNotPresent = async (page: Page, otherClientId export const assertThatRemoteTracksAreVisible = async (page: Page, otherClientIds: string[]) => { await test.step("Assert that remote tracks are visible", async () => { const responses = await Promise.allSettled( - otherClientIds.map((peerId) => page.locator(`css=video[data-peer-id="${peerId}"]`)) + otherClientIds.map((peerId) => page.locator(`css=video[data-peer-id="${peerId}"]`)), ); const isAnyRejected = responses.some((e) => e.status === "rejected"); expect(isAnyRejected).toBe(false); @@ -135,7 +135,7 @@ export const takeScreenshot = async (page: Page, testInfo: TestInfo, name?: stri export const createRoom = async (page: Page, maxPeers?: number) => await test.step("Create room", async () => { const data = { - ...(maxPeers ? { maxPeers } : {}) + ...(maxPeers ? { maxPeers } : {}), }; const roomRequest = await page.request.post("http://localhost:5002/room", { data }); @@ -148,9 +148,9 @@ export const createPeer = async (page: Page, roomId: string, enableSimulcast: bo data: { type: "webrtc", options: { - enableSimulcast - } - } + enableSimulcast, + }, + }, }); }); @@ -169,7 +169,7 @@ export const addAndReplaceTrack = async (page: Page) => await page .getByRole("button", { name: "Add and replace a heart", - exact: true + exact: true, }) .click()); @@ -178,7 +178,7 @@ export const addAndRemoveTrack = async (page: Page) => await page .getByRole("button", { name: "Add and remove a heart", - exact: true + exact: true, }) .click()); @@ -187,7 +187,7 @@ export const addBothMockTracks = async (page: Page) => await page .getByRole("button", { name: "Add both", - exact: true + exact: true, }) .click()); @@ -200,7 +200,7 @@ export const assertThatTrackBackgroundColorIsOk = async (page: Page, otherClient page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//div[@data-color-name="${color}"]`); return expectWithLongerTimeout( - page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//div[@data-color-name="${color}"]`) + page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//div[@data-color-name="${color}"]`), ).toBeVisible(); }); @@ -208,44 +208,50 @@ const DECODED_FRAMES = "data-decoded-frames"; export const waitForDecodedFrames = async (page: Page, otherClientId: string) => await test.step(`Wait for decoded frames`, async () => { - return expectWithLongerTimeout.poll(async () => { - const locator = await page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//span[@${DECODED_FRAMES}]`); + return expectWithLongerTimeout + .poll(async () => { + const locator = await page.locator( + `xpath=//div[@data-endpoint-id="${otherClientId}"]//span[@${DECODED_FRAMES}]`, + ); - const decodedFrames = await locator.getAttribute(DECODED_FRAMES) ?? "unknown"; + const decodedFrames = (await locator.getAttribute(DECODED_FRAMES)) ?? "unknown"; - return Number.parseInt(decodedFrames); - }).toBeGreaterThan(0); + return Number.parseInt(decodedFrames); + }) + .toBeGreaterThan(0); }); export const assertThatTrackIsPlaying = async (page: Page, otherClientId: string) => await test.step(`Assert that track is playing`, () => - expectWithLongerTimeout.poll( - async () => { - const locator = await page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//span[@${DECODED_FRAMES}]`); + expectWithLongerTimeout + .poll(async () => { + const locator = await page.locator( + `xpath=//div[@data-endpoint-id="${otherClientId}"]//span[@${DECODED_FRAMES}]`, + ); - const decodedFrames = await locator.getAttribute(DECODED_FRAMES) ?? "unknown"; + const decodedFrames = (await locator.getAttribute(DECODED_FRAMES)) ?? "unknown"; await page.waitForTimeout(300); - const decodedFrames2 = await locator.getAttribute(DECODED_FRAMES) ?? "unknown"; + const decodedFrames2 = (await locator.getAttribute(DECODED_FRAMES)) ?? "unknown"; return Number.parseInt(decodedFrames2) - Number.parseInt(decodedFrames); - } - ).toBeGreaterThan(0) - ); + }) + .toBeGreaterThan(0)); export const assertThatTrackStopped = async (page: Page, otherClientId: string) => await test.step(`Assert that track stopped`, () => - expectWithLongerTimeout.poll( - async () => { - const locator = await page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//span[@${DECODED_FRAMES}]`); + expectWithLongerTimeout + .poll(async () => { + const locator = await page.locator( + `xpath=//div[@data-endpoint-id="${otherClientId}"]//span[@${DECODED_FRAMES}]`, + ); - const decodedFrames = await locator.getAttribute(DECODED_FRAMES) ?? "unknown"; + const decodedFrames = (await locator.getAttribute(DECODED_FRAMES)) ?? "unknown"; await page.waitForTimeout(300); - const decodedFrames2 = await locator.getAttribute(DECODED_FRAMES) ?? "unknown"; + const decodedFrames2 = (await locator.getAttribute(DECODED_FRAMES)) ?? "unknown"; return Number.parseInt(decodedFrames2) - Number.parseInt(decodedFrames); - } - ).toBe(0) - ); + }) + .toBe(0)); export const assertThatTrackReplaceStatusIsSuccess = async (page: Page, replaceStatus: string) => await test.step(`Assert that track background color is ${replaceStatus}`, async () => diff --git a/src/FishjamClient.ts b/src/FishjamClient.ts index fb387bc3..14c5dbfd 100644 --- a/src/FishjamClient.ts +++ b/src/FishjamClient.ts @@ -8,7 +8,7 @@ import { TrackContext, TrackEncoding, MetadataParser, - WebRTCEndpointEvents + WebRTCEndpointEvents, } from "./webrtc"; import TypedEmitter from "typed-emitter"; import { EventEmitter } from "events"; @@ -23,10 +23,10 @@ export type Component = Omit( - endpoint: Endpoint + endpoint: Endpoint, ): endpoint is Peer => endpoint.type === "webrtc"; const isComponent = ( - endpoint: Endpoint + endpoint: Endpoint, ): endpoint is Component => endpoint.type === "recording" || endpoint.type === "hls" || @@ -74,7 +74,7 @@ export interface MessageEvents { joined: ( peerId: string, peers: Peer[], - components: Component[] + components: Component[], ) => void; /** @@ -154,7 +154,7 @@ export interface MessageEvents { */ tracksPriorityChanged: ( enabledTracks: TrackContext[], - disabledTracks: TrackContext[] + disabledTracks: TrackContext[], ) => void; /** @@ -166,35 +166,35 @@ export interface MessageEvents { bandwidthEstimationChanged: (estimation: bigint) => void; targetTrackEncodingRequested: ( - event: Parameters["targetTrackEncodingRequested"]>[0] + event: Parameters["targetTrackEncodingRequested"]>[0], ) => void; localTrackAdded: (event: Parameters["localTrackAdded"]>[0]) => void; localTrackRemoved: ( - event: Parameters["localTrackRemoved"]>[0] + event: Parameters["localTrackRemoved"]>[0], ) => void; localTrackReplaced: ( - event: Parameters["localTrackReplaced"]>[0] + event: Parameters["localTrackReplaced"]>[0], ) => void; localTrackBandwidthSet: ( - event: Parameters["localTrackBandwidthSet"]>[0] + event: Parameters["localTrackBandwidthSet"]>[0], ) => void; localTrackEncodingBandwidthSet: ( - event: Parameters["localTrackEncodingBandwidthSet"]>[0] + event: Parameters["localTrackEncodingBandwidthSet"]>[0], ) => void; localTrackEncodingEnabled: ( - event: Parameters["localTrackEncodingEnabled"]>[0] + event: Parameters["localTrackEncodingEnabled"]>[0], ) => void; localTrackEncodingDisabled: ( - event: Parameters["localTrackEncodingDisabled"]>[0] + event: Parameters["localTrackEncodingDisabled"]>[0], ) => void; localEndpointMetadataChanged: ( - event: Parameters["localEndpointMetadataChanged"]>[0] + event: Parameters["localEndpointMetadataChanged"]>[0], ) => void; localTrackMetadataChanged: ( - event: Parameters["localTrackMetadataChanged"]>[0] + event: Parameters["localTrackMetadataChanged"]>[0], ) => void; disconnectRequested: ( - event: Parameters["disconnectRequested"]>[0] + event: Parameters["disconnectRequested"]>[0], ) => void; } @@ -270,7 +270,7 @@ export type CreateConfig = { * ``` */ export class FishjamClient extends (EventEmitter as { - new(): TypedEmitter>>; + new (): TypedEmitter>>; }) { private websocket: WebSocket | null = null; private webrtc: WebRTCEndpoint | null = null; @@ -292,7 +292,7 @@ export class FishjamClient extends (EventEmitter as this.reconnectManager = new ReconnectManager( this, (peerMetadata) => this.initConnection(peerMetadata), - config?.reconnect + config?.reconnect, ); } @@ -326,7 +326,7 @@ export class FishjamClient extends (EventEmitter as this.webrtc = new WebRTCEndpoint({ endpointMetadataParser: this.peerMetadataParser, - trackMetadataParser: this.trackMetadataParser + trackMetadataParser: this.trackMetadataParser, }); this.initWebsocket(peerMetadata); @@ -444,7 +444,7 @@ export class FishjamClient extends (EventEmitter as acc[id] = peer; return acc; }, - {} as Record> + {} as Record>, ); } @@ -456,7 +456,7 @@ export class FishjamClient extends (EventEmitter as acc[id] = component; return acc; }, - {} as Record> + {} as Record>, ); } @@ -597,7 +597,7 @@ export class FishjamClient extends (EventEmitter as */ public on>( event: E, - listener: Required>[E] + listener: Required>[E], ): this { return super.on(event, listener); } @@ -620,7 +620,7 @@ export class FishjamClient extends (EventEmitter as */ public off>( event: E, - listener: Required>[E] + listener: Required>[E], ): this { return super.off(event, listener); } @@ -677,7 +677,7 @@ export class FishjamClient extends (EventEmitter as track: MediaStreamTrack, trackMetadata?: TrackMetadata, simulcastConfig: SimulcastConfig = { enabled: false, activeEncodings: [], disabledEncodings: [] }, - maxBandwidth: TrackBandwidthLimit = 0 // unlimited bandwidth + maxBandwidth: TrackBandwidthLimit = 0, // unlimited bandwidth ): Promise { if (!this.webrtc) throw this.handleWebRTCNotInitialized(); @@ -735,7 +735,7 @@ export class FishjamClient extends (EventEmitter as public async replaceTrack( trackId: string, newTrack: MediaStreamTrack, - newTrackMetadata?: TrackMetadata + newTrackMetadata?: TrackMetadata, ): Promise { if (!this.webrtc) throw this.handleWebRTCNotInitialized(); diff --git a/src/reconnection.ts b/src/reconnection.ts index fe195aed..3646440d 100644 --- a/src/reconnection.ts +++ b/src/reconnection.ts @@ -123,12 +123,7 @@ export class ReconnectManager { this.lastLocalEndpoint.tracks.forEach(async (track) => { if (!track.track) return; - await this.client.addTrack( - track.track, - track.rawMetadata, - track.simulcastConfig, - track.maxBandwidth, - ); + await this.client.addTrack(track.track, track.rawMetadata, track.simulcastConfig, track.maxBandwidth); }); } diff --git a/src/webrtc/webRTCEndpoint.ts b/src/webrtc/webRTCEndpoint.ts index fd2d28bf..3ab5c451 100644 --- a/src/webrtc/webRTCEndpoint.ts +++ b/src/webrtc/webRTCEndpoint.ts @@ -4,7 +4,7 @@ import { generateMediaEvent, MediaEvent, SerializedMediaEvent, - serializeMediaEvent + serializeMediaEvent, } from "./mediaEvent"; import { v4 as uuidv4 } from "uuid"; import EventEmitter from "events"; @@ -179,18 +179,18 @@ export interface TrackContextEvents { export interface TrackContext extends TrackContextFields, - TypedEmitter>> { -} + TypedEmitter>> {} type TrackNegotiationStatus = "awaiting" | "offered" | "done"; class TrackContextImpl extends (EventEmitter as { - new(): TypedEmitter< + new (): TypedEmitter< Required> >; }) - implements TrackContext { + implements TrackContext +{ endpoint: Endpoint; trackId: string; track: MediaStreamTrack | null = null; @@ -214,7 +214,7 @@ class TrackContextImpl trackId: string, metadata: any, simulcastConfig: SimulcastConfig, - metadataParser: MetadataParser + metadataParser: MetadataParser, ) { super(); this.endpoint = endpoint; @@ -317,7 +317,7 @@ export interface WebRTCEndpointEvents { */ tracksPriorityChanged: ( enabledTracks: TrackContext[], - disabledTracks: TrackContext[] + disabledTracks: TrackContext[], ) => void; /** @@ -377,7 +377,7 @@ export type Config = { * Main class that is responsible for connecting to the RTC Engine, sending and receiving media. */ export class WebRTCEndpoint extends (EventEmitter as { - new(): TypedEmitter< + new (): TypedEmitter< Required> >; }) { @@ -389,7 +389,7 @@ export class WebRTCEndpoint extends type: "webrtc", metadata: undefined, rawMetadata: undefined, - tracks: new Map() + tracks: new Map(), }; // todo this is remote trackId private localTrackIdToTrack: Map> = new Map(); @@ -406,7 +406,7 @@ export class WebRTCEndpoint extends private rtcConfig: RTCConfiguration = { bundlePolicy: "max-bundle", iceServers: [], - iceTransportPolicy: "relay" + iceTransportPolicy: "relay", }; private bandwidthEstimation: bigint = BigInt(0); @@ -452,7 +452,7 @@ export class WebRTCEndpoint extends } this.localEndpoint.rawMetadata = metadata; const mediaEvent = generateMediaEvent("connect", { - metadata: this.localEndpoint.metadata + metadata: this.localEndpoint.metadata, }); this.sendMediaEvent(mediaEvent); }; @@ -484,7 +484,7 @@ export class WebRTCEndpoint extends const otherEndpoints: Endpoint[] = endpoints.map((endpoint) => { const tracks = this.mapMediaEventTracksToTrackContextImpl( new Map(Object.entries(endpoint.tracks)), - endpoint + endpoint, ); try { @@ -494,7 +494,7 @@ export class WebRTCEndpoint extends metadata: this.endpointMetadataParser(endpoint.metadata), rawMetadata: endpoint.metadata, metadataParsingError: undefined, - tracks + tracks, } satisfies Endpoint; } catch (error) { return { @@ -503,7 +503,7 @@ export class WebRTCEndpoint extends metadata: undefined, rawMetadata: endpoint.metadata, metadataParsingError: error, - tracks + tracks, } satisfies Endpoint; } }); @@ -631,7 +631,7 @@ export class WebRTCEndpoint extends if (track.pendingMetadataUpdate) { const mediaEvent = generateMediaEvent("updateTrackMetadata", { trackId, - trackMetadata: track.metadata + trackMetadata: track.metadata, }); this.sendMediaEvent(mediaEvent); } @@ -761,11 +761,11 @@ export class WebRTCEndpoint extends case "tracksPriority": { const enabledTracks = (deserializedMediaEvent.data.tracks as string[]).map( - (trackId) => this.trackIdToTrack.get(trackId)! + (trackId) => this.trackIdToTrack.get(trackId)!, ); const disabledTracks = Array.from(this.trackIdToTrack.values()).filter( - (track) => !enabledTracks.includes(track) + (track) => !enabledTracks.includes(track), ); this.emit("tracksPriorityChanged", enabledTracks, disabledTracks); @@ -864,7 +864,7 @@ export class WebRTCEndpoint extends track: MediaStreamTrack, trackMetadata?: TrackMetadata, simulcastConfig: SimulcastConfig = { enabled: false, activeEncodings: [], disabledEncodings: [] }, - maxBandwidth: TrackBandwidthLimit = 0 + maxBandwidth: TrackBandwidthLimit = 0, ): Promise { const resolutionNotifier = new Deferred(); const trackId = this.getTrackId(uuidv4()); @@ -885,7 +885,7 @@ export class WebRTCEndpoint extends trackMetadata: parsedMetadata, simulcastConfig, maxBandwidth, - resolutionNotifier + resolutionNotifier, }); } catch (error) { resolutionNotifier.reject(error); @@ -897,7 +897,7 @@ export class WebRTCEndpoint extends stream, trackMetadata: metadata, simulcastConfig, - maxBandwidth + maxBandwidth, }); return trackId; } @@ -976,7 +976,7 @@ export class WebRTCEndpoint extends trackId, trackMetadata, simulcastConfig, - this.trackMetadataParser + this.trackMetadataParser, ); trackContext.track = track; @@ -994,7 +994,7 @@ export class WebRTCEndpoint extends .getTransceivers() .forEach( (transceiver) => - (transceiver.direction = transceiver.direction === "sendrecv" ? "sendonly" : transceiver.direction) + (transceiver.direction = transceiver.direction === "sendrecv" ? "sendonly" : transceiver.direction), ); } @@ -1022,13 +1022,13 @@ export class WebRTCEndpoint extends } private createAudioTransceiverConfig( - trackContext: TrackContext + trackContext: TrackContext, ): RTCRtpTransceiverInit { return { direction: "sendonly", streams: trackContext.stream ? [trackContext.stream] : [] }; } private createVideoTransceiverConfig( - trackContext: TrackContext + trackContext: TrackContext, ): RTCRtpTransceiverInit { let transceiverConfig: RTCRtpTransceiverInit; if (trackContext.simulcastConfig!.enabled) { @@ -1048,10 +1048,10 @@ export class WebRTCEndpoint extends direction: "sendonly", sendEncodings: [ { - active: true - } + active: true, + }, ], - streams: trackContext.stream ? [trackContext.stream] : [] + streams: trackContext.stream ? [trackContext.stream] : [], }; } @@ -1098,7 +1098,7 @@ export class WebRTCEndpoint extends const firstScaleDownBy = encodings![0].scaleResolutionDownBy || 1; const bitrate_parts = encodings.reduce( (acc, value) => acc + (firstScaleDownBy / (value.scaleResolutionDownBy || 1)) ** 2, - 0 + 0, ); const x = bandwidth / bitrate_parts; @@ -1164,7 +1164,7 @@ export class WebRTCEndpoint extends trackId, newTrack, newTrackMetadata: newMetadata, - resolutionNotifier + resolutionNotifier, }); } catch (error) { resolutionNotifier.reject(error); @@ -1173,7 +1173,7 @@ export class WebRTCEndpoint extends this.emit("localTrackReplaced", { trackId, track: newTrack, - metadata: newTrackMetadata + metadata: newTrackMetadata, }); }); } @@ -1267,14 +1267,14 @@ export class WebRTCEndpoint extends type: "trackVariantBitrates", data: { trackId: trackId, - variantBitrates: this.getTrackBitrates(trackId) - } + variantBitrates: this.getTrackBitrates(trackId), + }, }); this.sendMediaEvent(mediaEvent); this.emit("localTrackBandwidthSet", { trackId, - bandwidth + bandwidth, }); return true; }) @@ -1315,14 +1315,14 @@ export class WebRTCEndpoint extends type: "trackVariantBitrates", data: { trackId: trackId, - variantBitrates: this.getTrackBitrates(trackId) - } + variantBitrates: this.getTrackBitrates(trackId), + }, }); this.sendMediaEvent(mediaEvent); this.emit("localTrackEncodingBandwidthSet", { trackId, rid, - bandwidth + bandwidth, }); return true; }) @@ -1361,11 +1361,11 @@ export class WebRTCEndpoint extends this.pushCommand({ commandType: "REMOVE-TRACK", trackId, - resolutionNotifier + resolutionNotifier, }); return resolutionNotifier.promise.then(() => { this.emit("localTrackRemoved", { - trackId + trackId, }); }); } @@ -1408,14 +1408,14 @@ export class WebRTCEndpoint extends type: "setTargetTrackVariant", data: { trackId: trackId, - variant - } + variant, + }, }); this.sendMediaEvent(mediaEvent); this.emit("targetTrackEncodingRequested", { trackId, - variant + variant, }); } @@ -1445,7 +1445,7 @@ export class WebRTCEndpoint extends this.sendMediaEvent(mediaEvent); this.emit("localTrackEncodingEnabled", { trackId, - encoding + encoding, }); } @@ -1471,7 +1471,7 @@ export class WebRTCEndpoint extends this.sendMediaEvent(mediaEvent); this.emit("localTrackEncodingDisabled", { trackId, - encoding + encoding, }); } @@ -1491,11 +1491,11 @@ export class WebRTCEndpoint extends this.localEndpoint.rawMetadata = this.localEndpoint.metadata; this.localEndpoint.metadataParsingError = undefined; const mediaEvent = generateMediaEvent("updateEndpointMetadata", { - metadata: this.localEndpoint.metadata + metadata: this.localEndpoint.metadata, }); this.sendMediaEvent(mediaEvent); this.emit("localEndpointMetadataChanged", { - metadata + metadata, }); }; @@ -1527,7 +1527,7 @@ export class WebRTCEndpoint extends const mediaEvent = generateMediaEvent("updateTrackMetadata", { trackId, - trackMetadata: trackContext.metadata + trackMetadata: trackContext.metadata, }); switch (trackContext.negotiationStatus) { @@ -1536,7 +1536,7 @@ export class WebRTCEndpoint extends this.emit("localTrackMetadataChanged", { trackId, - metadata: trackMetadata + metadata: trackMetadata, }); break; @@ -1559,7 +1559,7 @@ export class WebRTCEndpoint extends const mid = transceiver.mid; if (localTrackId && mid) { const trackContext = Array.from(this.localTrackIdToTrack.values()).find( - (trackContext) => trackContext!.track!.id === localTrackId + (trackContext) => trackContext!.track!.id === localTrackId, )!; localTrackMidToTrackId[mid] = trackContext.trackId; } @@ -1667,8 +1667,8 @@ export class WebRTCEndpoint extends sdpOffer: offer, trackIdToTrackMetadata: this.getTrackIdToMetadata(), trackIdToTrackBitrates: this.getTrackIdToTrackBitrates(), - midToTrackId: this.getMidToTrackId() - } + midToTrackId: this.getMidToTrackId(), + }, }); this.sendMediaEvent(mediaEvent); @@ -1770,8 +1770,8 @@ export class WebRTCEndpoint extends type: "candidate", data: { candidate: event.candidate.candidate, - sdpMLineIndex: event.candidate.sdpMLineIndex - } + sdpMLineIndex: event.candidate.sdpMLineIndex, + }, }); this.sendMediaEvent(mediaEvent); } @@ -1858,7 +1858,7 @@ export class WebRTCEndpoint extends const rtcIceServer: RTCIceServer = { credential: turnServer.password, urls: uri.concat(":", turnServer.serverAddr, ":", turnServer.serverPort, "?transport=", transport), - username: turnServer.username + username: turnServer.username, }; this.rtcConfig.iceServers!.push(rtcIceServer); @@ -1896,13 +1896,13 @@ export class WebRTCEndpoint extends private mapMediaEventTracksToTrackContextImpl = ( tracks: Map, - endpoint: Endpoint + endpoint: Endpoint, ): Map> => { const mappedTracks: Array<[string, TrackContextImpl]> = Array.from(tracks).map( ([trackId, track]) => [ trackId, - new TrackContextImpl(endpoint, trackId, track.metadata, track.simulcastConfig, this.trackMetadataParser) - ] + new TrackContextImpl(endpoint, trackId, track.metadata, track.simulcastConfig, this.trackMetadataParser), + ], ); return new Map(mappedTracks); From 1d42e3abc05d6d7f7b654697bab969de23d5548d Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Wed, 29 May 2024 14:32:16 +0200 Subject: [PATCH 12/23] Refactor e2e utils --- e2e/app/src/ReplaceTrackWithDummyStream.tsx | 225 -------------------- e2e/scenarios/utils.ts | 69 ++---- 2 files changed, 22 insertions(+), 272 deletions(-) delete mode 100644 e2e/app/src/ReplaceTrackWithDummyStream.tsx diff --git a/e2e/app/src/ReplaceTrackWithDummyStream.tsx b/e2e/app/src/ReplaceTrackWithDummyStream.tsx deleted file mode 100644 index 07d38c57..00000000 --- a/e2e/app/src/ReplaceTrackWithDummyStream.tsx +++ /dev/null @@ -1,225 +0,0 @@ -import { VideoPlayer } from "./VideoPlayer"; -import { useRef, useState } from "react"; -import { WebRTCEndpoint } from "@fishjam-dev/ts-client"; - -/* eslint-disable no-console */ - -/* - * Looks like Jellyfish handles track without simulcast properly - * - * Case oszczędzania bandwithu - * - użytkownik ma słaby upload, wyłącza kamerę żeby mieć więcej seici na mikrofon - * - poprzednio zaobserwowaliśmy, że jest dużo padding pakietów albo czarnych ramek - * https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpSender/setParameters - * - jak tworzymy tracka to z sendera można pobrać tracki i ich settingsy i potem - * na parametrach konkretne encodingi ustawić, trzeba sprawdzić, czy da sie zrobić takie encodingsy - * dla canvasa jak są dla kamerki czyli 3 warstwy encodingóws - */ - -export const VIDEO_TRACK_CONSTRAINTS: MediaTrackConstraints = { - width: { - max: 1280, - ideal: 1280, - min: 640, - }, - height: { - max: 720, - ideal: 720, - min: 320, - }, - frameRate: { - max: 30, - ideal: 24, - }, -}; - -type Props = { - webrtc: WebRTCEndpoint; -}; - -const createDummyStream = ( - width: number = 1280, - height: number = 720, -): { - stream: MediaStream; - track: MediaStreamTrack; -} => { - const canvas = document.createElement("canvas"); - canvas.height = height; - canvas.width = width; - const context = canvas.getContext("2d"); - - if (!context) throw Error("Canvas context is null"); - - context.fillRect(0, 0, width, height); - - const stream = canvas.captureStream(); - - const track = stream.getVideoTracks()[0]; - - if (!track) throw Error("Canvas track is null"); - - track.enabled = false; - - return { stream, track }; -}; - -export const ReplaceTrackWithDummyStream = ({ webrtc }: Props) => { - const [videoStream, setVideoStream] = useState(null); - const videoStreamIdRef = useRef(null); - const [simulcastCheckbox, setSimulcastCheckbox] = useState(true); - - const startAndAddCamera = async () => { - const mediaStream = await navigator.mediaDevices.getUserMedia({ video: VIDEO_TRACK_CONSTRAINTS, audio: false }); - - setVideoStream(mediaStream); - - const track = mediaStream.getVideoTracks()[0]; - - if (videoStreamIdRef.current) { - console.log("Replacing with camera"); - - webrtc.replaceTrack(videoStreamIdRef.current, track, undefined); - } else { - console.log("Adding track"); - - videoStreamIdRef.current = await webrtc.addTrack( - track, - { goodTrack: "camera" }, - simulcastCheckbox - ? { - enabled: true, - activeEncodings: ["l", "m", "h"], - disabledEncodings: [], - } - : undefined, - ); - } - }; - - const stopCameraAndReplaceWithNull = () => { - videoStream?.getTracks().forEach((track) => { - track.stop(); - }); - - console.log("replacing with null", videoStreamIdRef.current); - - if (videoStreamIdRef.current) { - webrtc.replaceTrack(videoStreamIdRef.current, null, { goodTrack: "null" }); - } - }; - - const startCamera = async () => { - const mediaStream = await navigator.mediaDevices.getUserMedia({ video: VIDEO_TRACK_CONSTRAINTS, audio: false }); - console.log({ - mediaStream, - settings: mediaStream.getVideoTracks()[0].getSettings(), - tracks: videoStream?.getVideoTracks(), - }); - setVideoStream(mediaStream); - }; - - const stopCamera = () => { - videoStream?.getTracks().forEach((track) => { - track.stop(); - }); - }; - - const addCameraTrack = async () => { - if (!videoStream) throw Error("Video stream is null"); - const track = videoStream.getVideoTracks()[0]; - - videoStreamIdRef.current = await webrtc.addTrack( - track, - { source: "camera" }, - simulcastCheckbox - ? { - enabled: true, - activeEncodings: ["l", "m", "h"], - disabledEncodings: [], - } - : undefined, - ); - }; - - const toggleEnableCamera = () => { - if (!videoStream) throw Error("Video stream is null"); - const track = videoStream.getVideoTracks()[0]; - const prevState = track.enabled; - - videoStream.getVideoTracks().forEach((track) => { - track.enabled = !prevState; - }); - }; - - const removeCameraTrack = () => { - if (!videoStreamIdRef.current) throw Error("Track id is null"); - - webrtc.removeTrack(videoStreamIdRef.current); - }; - - const replaceWithDummyStaticStream = () => { - if (!videoStreamIdRef.current) throw Error("Track id is null"); - - const { track } = createDummyStream(); - webrtc.replaceTrack(videoStreamIdRef.current, track, { source: "dummy" }); - }; - - const replaceWithCamera = () => { - if (!videoStreamIdRef.current) throw Error("Track id is null"); - - const track = videoStream?.getVideoTracks()[0]; - - if (!track) throw Error("Track is null"); - - webrtc.replaceTrack(videoStreamIdRef.current, track, { source: "camera" }); - }; - - const replaceWithNull = () => { - if (!videoStreamIdRef.current) throw Error("Track id is null"); - - webrtc.replaceTrack(videoStreamIdRef.current, null, { source: "null" }); - }; - - return ( -
-
- - setSimulcastCheckbox(!simulcastCheckbox)} - /> -
-
- - -
- -
- - - - - - -
-
- - -
- {videoStream && } -
- ); -}; diff --git a/e2e/scenarios/utils.ts b/e2e/scenarios/utils.ts index 73595b2e..11e3a065 100644 --- a/e2e/scenarios/utils.ts +++ b/e2e/scenarios/utils.ts @@ -15,7 +15,7 @@ export const createAndJoinPeer = async (page: Page, roomId: string): Promise { @@ -34,14 +34,14 @@ export const joinRoom = async ( page: Page, roomId: string, metadata?: any, - waitForConnection: boolean = true, + waitForConnection: boolean = true ): Promise => test.step("Join room", async () => { const peerRequest = await createPeer(page, roomId); try { const { peer: { id: peerId }, - token: peerToken, + token: peerToken } = (await peerRequest.json()).data; await page.getByPlaceholder("token").fill(peerToken); @@ -67,7 +67,7 @@ export const joinRoomAndAddScreenShare = async (page: Page, roomId: string): Pro try { const { peer: { id: peerId }, - token: peerToken, + token: peerToken } = (await peerRequest.json()).data; await test.step("Join room", async () => { @@ -95,7 +95,7 @@ export const throwIfRemoteTracksAreNotPresent = async (page: Page, otherClientId export const assertThatRemoteTracksAreVisible = async (page: Page, otherClientIds: string[]) => { await test.step("Assert that remote tracks are visible", async () => { const responses = await Promise.allSettled( - otherClientIds.map((peerId) => page.locator(`css=video[data-peer-id="${peerId}"]`)), + otherClientIds.map((peerId) => page.locator(`css=video[data-peer-id="${peerId}"]`)) ); const isAnyRejected = responses.some((e) => e.status === "rejected"); expect(isAnyRejected).toBe(false); @@ -135,7 +135,7 @@ export const takeScreenshot = async (page: Page, testInfo: TestInfo, name?: stri export const createRoom = async (page: Page, maxPeers?: number) => await test.step("Create room", async () => { const data = { - ...(maxPeers ? { maxPeers } : {}), + ...(maxPeers ? { maxPeers } : {}) }; const roomRequest = await page.request.post("http://localhost:5002/room", { data }); @@ -148,9 +148,9 @@ export const createPeer = async (page: Page, roomId: string, enableSimulcast: bo data: { type: "webrtc", options: { - enableSimulcast, - }, - }, + enableSimulcast + } + } }); }); @@ -169,7 +169,7 @@ export const addAndReplaceTrack = async (page: Page) => await page .getByRole("button", { name: "Add and replace a heart", - exact: true, + exact: true }) .click()); @@ -178,7 +178,7 @@ export const addAndRemoveTrack = async (page: Page) => await page .getByRole("button", { name: "Add and remove a heart", - exact: true, + exact: true }) .click()); @@ -187,7 +187,7 @@ export const addBothMockTracks = async (page: Page) => await page .getByRole("button", { name: "Add both", - exact: true, + exact: true }) .click()); @@ -200,57 +200,32 @@ export const assertThatTrackBackgroundColorIsOk = async (page: Page, otherClient page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//div[@data-color-name="${color}"]`); return expectWithLongerTimeout( - page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//div[@data-color-name="${color}"]`), + page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//div[@data-color-name="${color}"]`) ).toBeVisible(); }); const DECODED_FRAMES = "data-decoded-frames"; -export const waitForDecodedFrames = async (page: Page, otherClientId: string) => - await test.step(`Wait for decoded frames`, async () => { - return expectWithLongerTimeout - .poll(async () => { - const locator = await page.locator( - `xpath=//div[@data-endpoint-id="${otherClientId}"]//span[@${DECODED_FRAMES}]`, - ); +const getDecodedFrameDifference = async (page: Page, otherClientId: string) => { + const locator = page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//span[@${DECODED_FRAMES}]`); - const decodedFrames = (await locator.getAttribute(DECODED_FRAMES)) ?? "unknown"; + const decodedFrames = (await locator.getAttribute(DECODED_FRAMES)) ?? "unknown"; + await page.waitForTimeout(300); + const decodedFrames2 = (await locator.getAttribute(DECODED_FRAMES)) ?? "unknown"; - return Number.parseInt(decodedFrames); - }) - .toBeGreaterThan(0); - }); + return Number.parseInt(decodedFrames2) - Number.parseInt(decodedFrames); +}; export const assertThatTrackIsPlaying = async (page: Page, otherClientId: string) => await test.step(`Assert that track is playing`, () => expectWithLongerTimeout - .poll(async () => { - const locator = await page.locator( - `xpath=//div[@data-endpoint-id="${otherClientId}"]//span[@${DECODED_FRAMES}]`, - ); - - const decodedFrames = (await locator.getAttribute(DECODED_FRAMES)) ?? "unknown"; - await page.waitForTimeout(300); - const decodedFrames2 = (await locator.getAttribute(DECODED_FRAMES)) ?? "unknown"; - - return Number.parseInt(decodedFrames2) - Number.parseInt(decodedFrames); - }) + .poll(() => getDecodedFrameDifference(page, otherClientId)) .toBeGreaterThan(0)); export const assertThatTrackStopped = async (page: Page, otherClientId: string) => await test.step(`Assert that track stopped`, () => expectWithLongerTimeout - .poll(async () => { - const locator = await page.locator( - `xpath=//div[@data-endpoint-id="${otherClientId}"]//span[@${DECODED_FRAMES}]`, - ); - - const decodedFrames = (await locator.getAttribute(DECODED_FRAMES)) ?? "unknown"; - await page.waitForTimeout(300); - const decodedFrames2 = (await locator.getAttribute(DECODED_FRAMES)) ?? "unknown"; - - return Number.parseInt(decodedFrames2) - Number.parseInt(decodedFrames); - }) + .poll(() => getDecodedFrameDifference(page, otherClientId)) .toBe(0)); export const assertThatTrackReplaceStatusIsSuccess = async (page: Page, replaceStatus: string) => From 32eb40297c7a583a55b4dfbcd17faf2943dabf09 Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Mon, 3 Jun 2024 10:59:29 +0200 Subject: [PATCH 13/23] Remove protos dependency --- e2e/app/src/App.tsx | 4 +- .../src/protos/fishjam/peer_notifications.ts | 300 ------------------ 2 files changed, 1 insertion(+), 303 deletions(-) delete mode 100644 e2e/app/src/protos/fishjam/peer_notifications.ts diff --git a/e2e/app/src/App.tsx b/e2e/app/src/App.tsx index 3390d399..248571ee 100644 --- a/e2e/app/src/App.tsx +++ b/e2e/app/src/App.tsx @@ -9,12 +9,11 @@ import { BandwidthLimit, SimulcastConfig, } from "@fishjam-dev/ts-client"; -import { PeerMessage } from "./protos/fishjam/peer_notifications"; import { useEffect, useState, useSyncExternalStore } from "react"; import { MockComponent } from "./MockComponent"; import { VideoPlayerWithDetector } from "./VideoPlayerWithDetector"; -import { ReplaceTrackWithDummyStream } from "./ReplaceTrackWithDummyStream"; import { MuteTrackTest } from "./MuteTrackTest"; +import { PeerMessage } from "../../../src/protos/fishjam/peer_notifications"; /* eslint-disable no-console */ @@ -235,7 +234,6 @@ export function App() {
- {/**/}
diff --git a/e2e/app/src/protos/fishjam/peer_notifications.ts b/e2e/app/src/protos/fishjam/peer_notifications.ts deleted file mode 100644 index 7aa7091d..00000000 --- a/e2e/app/src/protos/fishjam/peer_notifications.ts +++ /dev/null @@ -1,300 +0,0 @@ -/* eslint-disable */ -import * as _m0 from "protobufjs/minimal"; - -export const protobufPackage = "fishjam"; - -/** Defines any type of message sent between FJ and a peer */ -export interface PeerMessage { - authenticated?: PeerMessage_Authenticated | undefined; - authRequest?: PeerMessage_AuthRequest | undefined; - mediaEvent?: PeerMessage_MediaEvent | undefined; -} - -/** Response sent by FJ, confirming successfull authentication */ -export interface PeerMessage_Authenticated {} - -/** Request sent by peer, to authenticate to FJ server */ -export interface PeerMessage_AuthRequest { - token: string; -} - -/** Any type of WebRTC messages passed betweend FJ and peer */ -export interface PeerMessage_MediaEvent { - data: string; -} - -function createBasePeerMessage(): PeerMessage { - return { authenticated: undefined, authRequest: undefined, mediaEvent: undefined }; -} - -export const PeerMessage = { - encode(message: PeerMessage, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer { - if (message.authenticated !== undefined) { - PeerMessage_Authenticated.encode(message.authenticated, writer.uint32(10).fork()).ldelim(); - } - if (message.authRequest !== undefined) { - PeerMessage_AuthRequest.encode(message.authRequest, writer.uint32(18).fork()).ldelim(); - } - if (message.mediaEvent !== undefined) { - PeerMessage_MediaEvent.encode(message.mediaEvent, writer.uint32(26).fork()).ldelim(); - } - return writer; - }, - - decode(input: _m0.Reader | Uint8Array, length?: number): PeerMessage { - const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input); - let end = length === undefined ? reader.len : reader.pos + length; - const message = createBasePeerMessage(); - while (reader.pos < end) { - const tag = reader.uint32(); - switch (tag >>> 3) { - case 1: - if (tag !== 10) { - break; - } - - message.authenticated = PeerMessage_Authenticated.decode(reader, reader.uint32()); - continue; - case 2: - if (tag !== 18) { - break; - } - - message.authRequest = PeerMessage_AuthRequest.decode(reader, reader.uint32()); - continue; - case 3: - if (tag !== 26) { - break; - } - - message.mediaEvent = PeerMessage_MediaEvent.decode(reader, reader.uint32()); - continue; - } - if ((tag & 7) === 4 || tag === 0) { - break; - } - reader.skipType(tag & 7); - } - return message; - }, - - fromJSON(object: any): PeerMessage { - return { - authenticated: isSet(object.authenticated) ? PeerMessage_Authenticated.fromJSON(object.authenticated) : undefined, - authRequest: isSet(object.authRequest) ? PeerMessage_AuthRequest.fromJSON(object.authRequest) : undefined, - mediaEvent: isSet(object.mediaEvent) ? PeerMessage_MediaEvent.fromJSON(object.mediaEvent) : undefined, - }; - }, - - toJSON(message: PeerMessage): unknown { - const obj: any = {}; - if (message.authenticated !== undefined) { - obj.authenticated = PeerMessage_Authenticated.toJSON(message.authenticated); - } - if (message.authRequest !== undefined) { - obj.authRequest = PeerMessage_AuthRequest.toJSON(message.authRequest); - } - if (message.mediaEvent !== undefined) { - obj.mediaEvent = PeerMessage_MediaEvent.toJSON(message.mediaEvent); - } - return obj; - }, - - create, I>>(base?: I): PeerMessage { - return PeerMessage.fromPartial(base ?? ({} as any)); - }, - fromPartial, I>>(object: I): PeerMessage { - const message = createBasePeerMessage(); - message.authenticated = - object.authenticated !== undefined && object.authenticated !== null - ? PeerMessage_Authenticated.fromPartial(object.authenticated) - : undefined; - message.authRequest = - object.authRequest !== undefined && object.authRequest !== null - ? PeerMessage_AuthRequest.fromPartial(object.authRequest) - : undefined; - message.mediaEvent = - object.mediaEvent !== undefined && object.mediaEvent !== null - ? PeerMessage_MediaEvent.fromPartial(object.mediaEvent) - : undefined; - return message; - }, -}; - -function createBasePeerMessage_Authenticated(): PeerMessage_Authenticated { - return {}; -} - -export const PeerMessage_Authenticated = { - encode(_: PeerMessage_Authenticated, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer { - return writer; - }, - - decode(input: _m0.Reader | Uint8Array, length?: number): PeerMessage_Authenticated { - const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input); - let end = length === undefined ? reader.len : reader.pos + length; - const message = createBasePeerMessage_Authenticated(); - while (reader.pos < end) { - const tag = reader.uint32(); - switch (tag >>> 3) { - } - if ((tag & 7) === 4 || tag === 0) { - break; - } - reader.skipType(tag & 7); - } - return message; - }, - - fromJSON(_: any): PeerMessage_Authenticated { - return {}; - }, - - toJSON(_: PeerMessage_Authenticated): unknown { - const obj: any = {}; - return obj; - }, - - create, I>>(base?: I): PeerMessage_Authenticated { - return PeerMessage_Authenticated.fromPartial(base ?? ({} as any)); - }, - fromPartial, I>>(_: I): PeerMessage_Authenticated { - const message = createBasePeerMessage_Authenticated(); - return message; - }, -}; - -function createBasePeerMessage_AuthRequest(): PeerMessage_AuthRequest { - return { token: "" }; -} - -export const PeerMessage_AuthRequest = { - encode(message: PeerMessage_AuthRequest, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer { - if (message.token !== "") { - writer.uint32(10).string(message.token); - } - return writer; - }, - - decode(input: _m0.Reader | Uint8Array, length?: number): PeerMessage_AuthRequest { - const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input); - let end = length === undefined ? reader.len : reader.pos + length; - const message = createBasePeerMessage_AuthRequest(); - while (reader.pos < end) { - const tag = reader.uint32(); - switch (tag >>> 3) { - case 1: - if (tag !== 10) { - break; - } - - message.token = reader.string(); - continue; - } - if ((tag & 7) === 4 || tag === 0) { - break; - } - reader.skipType(tag & 7); - } - return message; - }, - - fromJSON(object: any): PeerMessage_AuthRequest { - return { token: isSet(object.token) ? globalThis.String(object.token) : "" }; - }, - - toJSON(message: PeerMessage_AuthRequest): unknown { - const obj: any = {}; - if (message.token !== "") { - obj.token = message.token; - } - return obj; - }, - - create, I>>(base?: I): PeerMessage_AuthRequest { - return PeerMessage_AuthRequest.fromPartial(base ?? ({} as any)); - }, - fromPartial, I>>(object: I): PeerMessage_AuthRequest { - const message = createBasePeerMessage_AuthRequest(); - message.token = object.token ?? ""; - return message; - }, -}; - -function createBasePeerMessage_MediaEvent(): PeerMessage_MediaEvent { - return { data: "" }; -} - -export const PeerMessage_MediaEvent = { - encode(message: PeerMessage_MediaEvent, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer { - if (message.data !== "") { - writer.uint32(10).string(message.data); - } - return writer; - }, - - decode(input: _m0.Reader | Uint8Array, length?: number): PeerMessage_MediaEvent { - const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input); - let end = length === undefined ? reader.len : reader.pos + length; - const message = createBasePeerMessage_MediaEvent(); - while (reader.pos < end) { - const tag = reader.uint32(); - switch (tag >>> 3) { - case 1: - if (tag !== 10) { - break; - } - - message.data = reader.string(); - continue; - } - if ((tag & 7) === 4 || tag === 0) { - break; - } - reader.skipType(tag & 7); - } - return message; - }, - - fromJSON(object: any): PeerMessage_MediaEvent { - return { data: isSet(object.data) ? globalThis.String(object.data) : "" }; - }, - - toJSON(message: PeerMessage_MediaEvent): unknown { - const obj: any = {}; - if (message.data !== "") { - obj.data = message.data; - } - return obj; - }, - - create, I>>(base?: I): PeerMessage_MediaEvent { - return PeerMessage_MediaEvent.fromPartial(base ?? ({} as any)); - }, - fromPartial, I>>(object: I): PeerMessage_MediaEvent { - const message = createBasePeerMessage_MediaEvent(); - message.data = object.data ?? ""; - return message; - }, -}; - -type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined; - -export type DeepPartial = T extends Builtin - ? T - : T extends globalThis.Array - ? globalThis.Array> - : T extends ReadonlyArray - ? ReadonlyArray> - : T extends {} - ? { [K in keyof T]?: DeepPartial } - : Partial; - -type KeysOfUnion = T extends T ? keyof T : never; -export type Exact = P extends Builtin - ? P - : P & { [K in keyof P]: Exact } & { [K in Exclude>]: never }; - -function isSet(value: any): boolean { - return value !== null && value !== undefined; -} From 153cde3e3e802a4669edabf6516ba975fc4ea7fd Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Mon, 3 Jun 2024 16:47:15 +0200 Subject: [PATCH 14/23] Add mute and unmute events --- e2e/scenarios/utils.ts | 34 +++++++++++++++------------------- src/FishjamClient.ts | 12 +++++++++++- src/webrtc/const.ts | 5 ++++- src/webrtc/webRTCEndpoint.ts | 20 ++++++++++---------- 4 files changed, 40 insertions(+), 31 deletions(-) diff --git a/e2e/scenarios/utils.ts b/e2e/scenarios/utils.ts index 11e3a065..ecb9707f 100644 --- a/e2e/scenarios/utils.ts +++ b/e2e/scenarios/utils.ts @@ -15,7 +15,7 @@ export const createAndJoinPeer = async (page: Page, roomId: string): Promise { @@ -34,14 +34,14 @@ export const joinRoom = async ( page: Page, roomId: string, metadata?: any, - waitForConnection: boolean = true + waitForConnection: boolean = true, ): Promise => test.step("Join room", async () => { const peerRequest = await createPeer(page, roomId); try { const { peer: { id: peerId }, - token: peerToken + token: peerToken, } = (await peerRequest.json()).data; await page.getByPlaceholder("token").fill(peerToken); @@ -67,7 +67,7 @@ export const joinRoomAndAddScreenShare = async (page: Page, roomId: string): Pro try { const { peer: { id: peerId }, - token: peerToken + token: peerToken, } = (await peerRequest.json()).data; await test.step("Join room", async () => { @@ -95,7 +95,7 @@ export const throwIfRemoteTracksAreNotPresent = async (page: Page, otherClientId export const assertThatRemoteTracksAreVisible = async (page: Page, otherClientIds: string[]) => { await test.step("Assert that remote tracks are visible", async () => { const responses = await Promise.allSettled( - otherClientIds.map((peerId) => page.locator(`css=video[data-peer-id="${peerId}"]`)) + otherClientIds.map((peerId) => page.locator(`css=video[data-peer-id="${peerId}"]`)), ); const isAnyRejected = responses.some((e) => e.status === "rejected"); expect(isAnyRejected).toBe(false); @@ -135,7 +135,7 @@ export const takeScreenshot = async (page: Page, testInfo: TestInfo, name?: stri export const createRoom = async (page: Page, maxPeers?: number) => await test.step("Create room", async () => { const data = { - ...(maxPeers ? { maxPeers } : {}) + ...(maxPeers ? { maxPeers } : {}), }; const roomRequest = await page.request.post("http://localhost:5002/room", { data }); @@ -148,9 +148,9 @@ export const createPeer = async (page: Page, roomId: string, enableSimulcast: bo data: { type: "webrtc", options: { - enableSimulcast - } - } + enableSimulcast, + }, + }, }); }); @@ -169,7 +169,7 @@ export const addAndReplaceTrack = async (page: Page) => await page .getByRole("button", { name: "Add and replace a heart", - exact: true + exact: true, }) .click()); @@ -178,7 +178,7 @@ export const addAndRemoveTrack = async (page: Page) => await page .getByRole("button", { name: "Add and remove a heart", - exact: true + exact: true, }) .click()); @@ -187,7 +187,7 @@ export const addBothMockTracks = async (page: Page) => await page .getByRole("button", { name: "Add both", - exact: true + exact: true, }) .click()); @@ -200,7 +200,7 @@ export const assertThatTrackBackgroundColorIsOk = async (page: Page, otherClient page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//div[@data-color-name="${color}"]`); return expectWithLongerTimeout( - page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//div[@data-color-name="${color}"]`) + page.locator(`xpath=//div[@data-endpoint-id="${otherClientId}"]//div[@data-color-name="${color}"]`), ).toBeVisible(); }); @@ -218,15 +218,11 @@ const getDecodedFrameDifference = async (page: Page, otherClientId: string) => { export const assertThatTrackIsPlaying = async (page: Page, otherClientId: string) => await test.step(`Assert that track is playing`, () => - expectWithLongerTimeout - .poll(() => getDecodedFrameDifference(page, otherClientId)) - .toBeGreaterThan(0)); + expectWithLongerTimeout.poll(() => getDecodedFrameDifference(page, otherClientId)).toBeGreaterThan(0)); export const assertThatTrackStopped = async (page: Page, otherClientId: string) => await test.step(`Assert that track stopped`, () => - expectWithLongerTimeout - .poll(() => getDecodedFrameDifference(page, otherClientId)) - .toBe(0)); + expectWithLongerTimeout.poll(() => getDecodedFrameDifference(page, otherClientId)).toBe(0)); export const assertThatTrackReplaceStatusIsSuccess = async (page: Page, replaceStatus: string) => await test.step(`Assert that track background color is ${replaceStatus}`, async () => diff --git a/src/FishjamClient.ts b/src/FishjamClient.ts index 14c5dbfd..c611d8a0 100644 --- a/src/FishjamClient.ts +++ b/src/FishjamClient.ts @@ -175,6 +175,10 @@ export interface MessageEvents { localTrackReplaced: ( event: Parameters["localTrackReplaced"]>[0], ) => void; + localTrackMuted: (event: Parameters["localTrackMuted"]>[0]) => void; + localTrackUnmuted: ( + event: Parameters["localTrackUnmuted"]>[0], + ) => void; localTrackBandwidthSet: ( event: Parameters["localTrackBandwidthSet"]>[0], ) => void; @@ -557,6 +561,12 @@ export class FishjamClient extends (EventEmitter as this.webrtc?.on("localTrackReplaced", (event) => { this.emit("localTrackReplaced", event); }); + this.webrtc?.on("localTrackMuted", (event) => { + this.emit("localTrackMuted", event); + }); + this.webrtc?.on("localTrackUnmuted", (event) => { + this.emit("localTrackUnmuted", event); + }); this.webrtc?.on("localTrackBandwidthSet", (event) => { this.emit("localTrackBandwidthSet", event); }); @@ -734,7 +744,7 @@ export class FishjamClient extends (EventEmitter as */ public async replaceTrack( trackId: string, - newTrack: MediaStreamTrack, + newTrack: MediaStreamTrack | null, newTrackMetadata?: TrackMetadata, ): Promise { if (!this.webrtc) throw this.handleWebRTCNotInitialized(); diff --git a/src/webrtc/const.ts b/src/webrtc/const.ts index 9a7ca0e8..a79ef2be 100644 --- a/src/webrtc/const.ts +++ b/src/webrtc/const.ts @@ -28,7 +28,10 @@ export const simulcastTransceiverConfig: RTCRtpTransceiverInit = { ], }; -export const defaultBitrates: { audio: BandwidthLimit; video: BandwidthLimit } = { audio: 50_000, video: 2_500_000 }; +export const defaultBitrates: { audio: BandwidthLimit; video: BandwidthLimit } = { + audio: 50_000, + video: 2_500_000, +}; export const defaultSimulcastBitrates: { [key in TrackEncoding]: BandwidthLimit; diff --git a/src/webrtc/webRTCEndpoint.ts b/src/webrtc/webRTCEndpoint.ts index 3ab5c451..a1c0293b 100644 --- a/src/webrtc/webRTCEndpoint.ts +++ b/src/webrtc/webRTCEndpoint.ts @@ -355,6 +355,10 @@ export interface WebRTCEndpointEvents { localTrackReplaced: (event: { trackId: string; track: MediaStreamTrack | null; metadata?: TrackMetadata }) => void; + localTrackMuted: (event: { trackId: string }) => void; + + localTrackUnmuted: (event: { trackId: string }) => void; + localTrackBandwidthSet: (event: { trackId: string; bandwidth: BandwidthLimit }) => void; localTrackEncodingBandwidthSet: (event: { trackId: string; rid: string; bandwidth: BandwidthLimit }) => void; @@ -1190,28 +1194,23 @@ export class WebRTCEndpoint extends if (!sender) throw Error("There is no RTCRtpSender for this track id!"); this.ongoingTrackReplacement = true; - console.log({ name: "1", trackContext, trackCount: trackContext.stream?.getTracks().length }); trackContext.stream?.getTracks().forEach((track) => { trackContext.stream?.removeTrack(track); }); - console.log({ name: "2", trackContext, trackCount: trackContext.stream?.getTracks().length }); - if (newTrack) { trackContext.stream?.addTrack(newTrack); } - console.log({ name: "3", trackContext, trackCount: trackContext.stream?.getTracks().length }); - if (trackContext.track && !newTrack) { const mediaEvent = generateMediaEvent("muteTrack", { trackId: trackId }); this.sendMediaEvent(mediaEvent); - console.log("sent mute event"); + this.emit("localTrackMuted", { trackId: trackId }); } else if (!trackContext.track && newTrack) { const mediaEvent = generateMediaEvent("unmuteTrack", { trackId: trackId }); this.sendMediaEvent(mediaEvent); - console.log("sent unmute event"); + this.emit("localTrackUnmuted", { trackId: trackId }); } trackContext.track = newTrack; @@ -1691,12 +1690,13 @@ export class WebRTCEndpoint extends private getTrackBitrates = (trackId: string) => { const trackContext = this.localTrackIdToTrack.get(trackId); if (!trackContext) throw "Track with id ${trackId} not present in 'remoteTrackIdToTrack'"; - const kind = trackContext.track!.kind as "audio" | "video"; + const kind = trackContext.track?.kind as "audio" | "video" | undefined; const sender = this.findSender(trackContext.track!.id); const encodings = sender.getParameters().encodings; - if (encodings.length == 1 && !encodings[0].rid) return encodings[0].maxBitrate || defaultBitrates[kind]; - else if (kind == "audio") throw "Audio track cannot have multiple encodings"; + if (encodings.length === 1 && !encodings[0].rid) { + return encodings[0].maxBitrate || (kind ? defaultBitrates[kind] : 0); + } else if (kind == "audio") throw "Audio track cannot have multiple encodings"; const bitrates = {} as any; From 305f7f7864d69abfdf9975caf86388de8c63c079 Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Mon, 3 Jun 2024 16:49:27 +0200 Subject: [PATCH 15/23] Fix format --- src/webrtc/const.ts | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/webrtc/const.ts b/src/webrtc/const.ts index a79ef2be..9a7ca0e8 100644 --- a/src/webrtc/const.ts +++ b/src/webrtc/const.ts @@ -28,10 +28,7 @@ export const simulcastTransceiverConfig: RTCRtpTransceiverInit = { ], }; -export const defaultBitrates: { audio: BandwidthLimit; video: BandwidthLimit } = { - audio: 50_000, - video: 2_500_000, -}; +export const defaultBitrates: { audio: BandwidthLimit; video: BandwidthLimit } = { audio: 50_000, video: 2_500_000 }; export const defaultSimulcastBitrates: { [key in TrackEncoding]: BandwidthLimit; From e473008e745381740e56e25f395deb93e1a6f100 Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Mon, 3 Jun 2024 17:02:25 +0200 Subject: [PATCH 16/23] Fix prettier and linter --- e2e/app/src/MuteTrackTest.tsx | 93 +++++++++++++++++-------- e2e/app/src/VideoPlayerWithDetector.tsx | 17 +++-- e2e/scenarios/replaceTrack.spec.ts | 32 ++++----- e2e/scenarios/utils.ts | 44 +++++++++--- src/FishjamClient.ts | 10 ++- src/reconnection.ts | 7 +- src/webrtc/webRTCEndpoint.ts | 31 ++++++--- 7 files changed, 158 insertions(+), 76 deletions(-) diff --git a/e2e/app/src/MuteTrackTest.tsx b/e2e/app/src/MuteTrackTest.tsx index e4dbe921..a5334d3d 100644 --- a/e2e/app/src/MuteTrackTest.tsx +++ b/e2e/app/src/MuteTrackTest.tsx @@ -1,9 +1,9 @@ -import { WebRTCEndpoint } from "@fishjam-dev/ts-client"; -import { brain2Mock, heart2Mock } from "./MockComponent"; -import { useEffect, useState } from "react"; -import { VideoPlayer } from "./VideoPlayer"; -import { WebRTCEndpointEvents } from "../../../src"; -import { EndpointMetadata, TrackMetadata } from "./App"; +import { WebRTCEndpoint } from '@fishjam-dev/ts-client'; +import { brain2Mock, heart2Mock } from './MockComponent'; +import { useEffect, useState } from 'react'; +import { VideoPlayer } from './VideoPlayer'; +import { WebRTCEndpointEvents } from '../../../src'; +import { EndpointMetadata, TrackMetadata } from './App'; type Props = { webrtc: WebRTCEndpoint; @@ -15,22 +15,28 @@ export const MuteTrackTest = ({ webrtc }: Props) => { const [trackId, setTrackId] = useState(null); useEffect(() => { - const localTrackAdded: WebRTCEndpointEvents["localTrackAdded"] = (event) => { + const localTrackAdded: WebRTCEndpointEvents< + EndpointMetadata, + TrackMetadata + >['localTrackAdded'] = (event) => { setCurrentStream(event.stream); setCurrentTrack(event.track); setTrackId(event.trackId); }; - const localTrackReplaced: WebRTCEndpointEvents["localTrackReplaced"] = (event) => { + const localTrackReplaced: WebRTCEndpointEvents< + EndpointMetadata, + TrackMetadata + >['localTrackReplaced'] = (event) => { setCurrentTrack(event.track); }; - webrtc.on("localTrackAdded", localTrackAdded); - webrtc.on("localTrackReplaced", localTrackReplaced); + webrtc.on('localTrackAdded', localTrackAdded); + webrtc.on('localTrackReplaced', localTrackReplaced); return () => { - webrtc.removeListener("localTrackAdded", localTrackAdded); - webrtc.removeListener("localTrackReplaced", localTrackReplaced); + webrtc.removeListener('localTrackAdded', localTrackAdded); + webrtc.removeListener('localTrackReplaced', localTrackReplaced); }; }, []); @@ -41,13 +47,21 @@ export const MuteTrackTest = ({ webrtc }: Props) => { await webrtc.addTrack( track, - { goodTrack: "camera" }, - { enabled: true, activeEncodings: ["l", "m", "h"], disabledEncodings: [] }, + { goodTrack: 'camera' }, + { + enabled: true, + activeEncodings: ['l', 'm', 'h'], + disabledEncodings: [], + }, ); }; - const replaceTrack = async (trackId: string | null, stream: MediaStream | null, track: MediaStreamTrack | null) => { - if (!trackId) throw Error("Track id is null"); + const replaceTrack = async ( + trackId: string | null, + stream: MediaStream | null, + track: MediaStreamTrack | null, + ) => { + if (!trackId) throw Error('Track id is null'); await webrtc.replaceTrack(trackId, track); }; @@ -55,31 +69,50 @@ export const MuteTrackTest = ({ webrtc }: Props) => { return (
+ display: 'flex', + flexDirection: 'column', + padding: '8px', + borderStyle: 'dotted', + borderWidth: '1px', + borderColor: 'black', + }}>
- track: {currentTrack?.id ?? "null"} + track: {currentTrack?.id ?? 'null'}
- - - - - +
{currentStream && }
diff --git a/e2e/app/src/VideoPlayerWithDetector.tsx b/e2e/app/src/VideoPlayerWithDetector.tsx index a129d639..ae8a1fd5 100644 --- a/e2e/app/src/VideoPlayerWithDetector.tsx +++ b/e2e/app/src/VideoPlayerWithDetector.tsx @@ -18,11 +18,13 @@ const rgbToText = (pixel: Pixel): string => { return 'unknown'; }; -const getTrackIdentifierToInboundRtp = (stats: RTCStatsReport): Record => { +const getTrackIdentifierToInboundRtp = ( + stats: RTCStatsReport, +): Record => { const result: Record = {}; stats.forEach((report) => { - if (report.type === "inbound-rtp") { + if (report.type === 'inbound-rtp') { result[report.trackIdentifier] = report; } }); @@ -32,8 +34,8 @@ const getTrackIdentifierToInboundRtp = (stats: RTCStatsReport): Record { const videoElementRef = useRef(null); - const [color, setColor] = useState(""); - const [decodedFrames, setDecodedFrames] = useState(""); + const [color, setColor] = useState(''); + const [decodedFrames, setDecodedFrames] = useState(''); useEffect(() => { if (!videoElementRef.current) return; @@ -41,12 +43,12 @@ export const VideoPlayerWithDetector = ({ stream, id, webrtc }: Props) => { }, [stream]); const getDecodedFrames = async () => { - const connection = webrtc["connection"]; + const connection = webrtc['connection']; if (!connection) return 0; const inbound = getTrackIdentifierToInboundRtp(await connection.getStats()); - const trackId = stream?.getVideoTracks()?.[0]?.id ?? ""; + const trackId = stream?.getVideoTracks()?.[0]?.id ?? ''; return inbound[trackId]?.framesDecoded ?? 0; }; @@ -87,7 +89,8 @@ export const VideoPlayerWithDetector = ({ stream, id, webrtc }: Props) => {
{color}
- Decoded frames: {decodedFrames} + Decoded frames:{' '} + {decodedFrames}
{stream?.id}
diff --git a/e2e/app/src/MockComponent.tsx b/e2e/app/src/MockComponent.tsx index 7908d124..f76586ed 100644 --- a/e2e/app/src/MockComponent.tsx +++ b/e2e/app/src/MockComponent.tsx @@ -33,7 +33,6 @@ export const MockComponent = ({ webrtc }: Props) => { heartId.current = webrtc.addTrack( track, - stream, JSON.parse(trackMetadataInput), ); }; @@ -90,7 +89,6 @@ export const MockComponent = ({ webrtc }: Props) => { brainId.current = webrtc.addTrack( track, - stream, JSON.parse(trackMetadataInput), simulcastConfig, maxBandwidth, diff --git a/e2e/app/src/VideoPlayerWithDetector.tsx b/e2e/app/src/VideoPlayerWithDetector.tsx index ae8a1fd5..ce452422 100644 --- a/e2e/app/src/VideoPlayerWithDetector.tsx +++ b/e2e/app/src/VideoPlayerWithDetector.tsx @@ -89,7 +89,7 @@ export const VideoPlayerWithDetector = ({ stream, id, webrtc }: Props) => {
{color}
- Decoded frames:{' '} + Decoded frames: {decodedFrames}
); }; diff --git a/e2e/app/src/VideoPlayerWithDetector.tsx b/e2e/app/src/VideoPlayerWithDetector.tsx index ce452422..c486f430 100644 --- a/e2e/app/src/VideoPlayerWithDetector.tsx +++ b/e2e/app/src/VideoPlayerWithDetector.tsx @@ -1,5 +1,6 @@ import { useEffect, useRef, useState } from 'react'; import { getPixel, Pixel } from './mocks'; +import { WebRTCEndpoint } from "@fishjam-dev/ts-client"; type Props = { stream?: MediaStream; From df44d92f2ba612968b156b746927ad728722ab7a Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Tue, 4 Jun 2024 12:32:38 +0200 Subject: [PATCH 19/23] Fix format --- README.md | 4 +--- e2e/app/src/App.tsx | 9 ++------- e2e/app/src/MockComponent.tsx | 9 +++------ e2e/app/src/VideoPlayerWithDetector.tsx | 2 +- examples/minimal/src/main.ts | 4 +--- tests/methods/addTrackMethod.test.ts | 11 ++++------- 6 files changed, 12 insertions(+), 27 deletions(-) diff --git a/README.md b/README.md index cdfbc829..8eb66628 100644 --- a/README.md +++ b/README.md @@ -111,9 +111,7 @@ async function startScreenSharing(webrtc: WebRTCEndpoint) { // Add local MediaStream to webrtc screenStream .getTracks() - .forEach((track) => - webrtc.addTrack(track, { type: 'screen' }), - ); + .forEach((track) => webrtc.addTrack(track, { type: 'screen' })); } ``` diff --git a/e2e/app/src/App.tsx b/e2e/app/src/App.tsx index d381095a..4b44203d 100644 --- a/e2e/app/src/App.tsx +++ b/e2e/app/src/App.tsx @@ -12,7 +12,7 @@ import { import { useEffect, useState, useSyncExternalStore } from 'react'; import { MockComponent } from './MockComponent'; import { VideoPlayerWithDetector } from './VideoPlayerWithDetector'; -import { PeerMessage } from "../../../src/protos/fishjam/peer_notifications"; +import { PeerMessage } from '../../../src/protos/fishjam/peer_notifications'; /* eslint-disable no-console */ @@ -217,12 +217,7 @@ async function addScreenshareTrack(): Promise { }; const maxBandwidth: BandwidthLimit = 0; - return webrtc.addTrack( - track, - trackMetadata, - simulcastConfig, - maxBandwidth, - ); + return webrtc.addTrack(track, trackMetadata, simulcastConfig, maxBandwidth); } export function App() { diff --git a/e2e/app/src/MockComponent.tsx b/e2e/app/src/MockComponent.tsx index 91936207..a1a0c872 100644 --- a/e2e/app/src/MockComponent.tsx +++ b/e2e/app/src/MockComponent.tsx @@ -7,7 +7,7 @@ import { SimulcastConfig, WebRTCEndpoint, } from '@fishjam-dev/ts-client'; -import { MuteTrackTest } from "./MuteTrackTest"; +import { MuteTrackTest } from './MuteTrackTest'; export const brainMock = createStream('🧠', 'white', 'low', 24); export const brain2Mock = createStream('🤯', '#00ff00', 'low', 24); @@ -32,10 +32,7 @@ export const MockComponent = ({ webrtc }: Props) => { const stream = heartMock.stream; const track = stream.getVideoTracks()[0]; - heartId.current = webrtc.addTrack( - track, - JSON.parse(trackMetadataInput), - ); + heartId.current = webrtc.addTrack(track, JSON.parse(trackMetadataInput)); }; const removeHeart = async () => { @@ -150,7 +147,7 @@ export const MockComponent = ({ webrtc }: Props) => { - +
); }; diff --git a/e2e/app/src/VideoPlayerWithDetector.tsx b/e2e/app/src/VideoPlayerWithDetector.tsx index c486f430..bf914b84 100644 --- a/e2e/app/src/VideoPlayerWithDetector.tsx +++ b/e2e/app/src/VideoPlayerWithDetector.tsx @@ -1,6 +1,6 @@ import { useEffect, useRef, useState } from 'react'; import { getPixel, Pixel } from './mocks'; -import { WebRTCEndpoint } from "@fishjam-dev/ts-client"; +import { WebRTCEndpoint } from '@fishjam-dev/ts-client'; type Props = { stream?: MediaStream; diff --git a/examples/minimal/src/main.ts b/examples/minimal/src/main.ts index 4974d6d5..be027cc6 100644 --- a/examples/minimal/src/main.ts +++ b/examples/minimal/src/main.ts @@ -80,7 +80,5 @@ async function startScreenSharing() { // Add local MediaStream to the client screenStream .getTracks() - .forEach((track) => - client.addTrack(track, { type: 'screen' }), - ); + .forEach((track) => client.addTrack(track, { type: 'screen' })); } diff --git a/tests/methods/addTrackMethod.test.ts b/tests/methods/addTrackMethod.test.ts index e2b9a0c5..cb7e28a7 100644 --- a/tests/methods/addTrackMethod.test.ts +++ b/tests/methods/addTrackMethod.test.ts @@ -1,8 +1,5 @@ import { WebRTCEndpoint } from '../../src'; -import { - createConnectedEventWithOneEndpoint, - mockTrack, -} from '../fixtures'; +import { createConnectedEventWithOneEndpoint, mockTrack } from '../fixtures'; import { mockRTCPeerConnection } from '../mocks'; import { deserializeMediaEvent } from '../../src/webrtc/mediaEvent'; import { expect, it } from 'vitest'; @@ -59,9 +56,9 @@ it('Adding track before being accepted by the server throws error', async () => const webRTCEndpoint = new WebRTCEndpoint(); // When - await expect(() => - webRTCEndpoint.addTrack(mockTrack), - ).rejects.toThrow('Cannot add tracks before being accepted by the server'); + await expect(() => webRTCEndpoint.addTrack(mockTrack)).rejects.toThrow( + 'Cannot add tracks before being accepted by the server', + ); }); it('Adding track with invalid metadata throws error', async () => { From 1c19a7cb097eb8c4edc57836ac33a69143747ae0 Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Wed, 5 Jun 2024 16:57:59 +0200 Subject: [PATCH 20/23] Fix format and unit tests --- src/webrtc/webRTCEndpoint.ts | 8 ++++---- tests/events/encodingSwitchedEvent.test.ts | 17 ++++++++-------- tests/events/endpointUpdatedEvent.test.ts | 11 ++++++++--- tests/events/trackUpdatedEvent.test.ts | 23 +++++++++++++--------- tests/methods/addTrackMethod.test.ts | 11 ++++++++++- tests/mocks.ts | 8 ++++++++ 6 files changed, 53 insertions(+), 25 deletions(-) diff --git a/src/webrtc/webRTCEndpoint.ts b/src/webrtc/webRTCEndpoint.ts index c895ed11..050687b0 100644 --- a/src/webrtc/webRTCEndpoint.ts +++ b/src/webrtc/webRTCEndpoint.ts @@ -541,7 +541,7 @@ export class WebRTCEndpoint< * webrtcChannel.on("mediaEvent", (event) => webrtc.receiveMediaEvent(event.data)); * ``` */ - public receiveMediaEvent = (mediaEvent: SerializedMediaEvent) => { + public async receiveMediaEvent(mediaEvent: SerializedMediaEvent) { const deserializedMediaEvent = deserializeMediaEvent(mediaEvent); switch (deserializedMediaEvent.type) { case 'connected': { @@ -594,9 +594,9 @@ export class WebRTCEndpoint< } default: if (this.localEndpoint.id != null) - this.handleMediaEvent(deserializedMediaEvent); + await this.handleMediaEvent(deserializedMediaEvent); } - }; + } /** * Retrieves statistics related to the RTCPeerConnection. @@ -892,7 +892,7 @@ export class WebRTCEndpoint< break; } case 'custom': - this.handleMediaEvent(deserializedMediaEvent.data as MediaEvent); + await this.handleMediaEvent(deserializedMediaEvent.data as MediaEvent); break; case 'error': diff --git a/tests/events/encodingSwitchedEvent.test.ts b/tests/events/encodingSwitchedEvent.test.ts index 87d02fda..132fce4f 100644 --- a/tests/events/encodingSwitchedEvent.test.ts +++ b/tests/events/encodingSwitchedEvent.test.ts @@ -43,16 +43,17 @@ it('Changing track encoding when endpoint exist but track does not exist', () => expect(initialTrackEncoding).toBe(undefined); // When - expect(() => { - const encodingUpdatedEvent = createEncodingSwitchedEvent( - endpointId, - notExistingTrackId, - 'm', - ); - webRTCEndpoint.receiveMediaEvent(JSON.stringify(encodingUpdatedEvent)); + const encodingUpdatedEvent = createEncodingSwitchedEvent( + endpointId, + notExistingTrackId, + 'm', + ); + expect(() => + webRTCEndpoint.receiveMediaEvent(JSON.stringify(encodingUpdatedEvent)), + ) // todo change this error in production code - }).toThrow("Cannot set properties of undefined (setting 'encoding')"); + .rejects.toThrow("Cannot set properties of undefined (setting 'encoding')"); }); it('Changing track encoding when endpoint does not exist but track exist in other endpoint', () => { diff --git a/tests/events/endpointUpdatedEvent.test.ts b/tests/events/endpointUpdatedEvent.test.ts index 64c8d8a2..d8e07c17 100644 --- a/tests/events/endpointUpdatedEvent.test.ts +++ b/tests/events/endpointUpdatedEvent.test.ts @@ -87,20 +87,23 @@ it('Update endpoint that not exist', () => { newField: 'new field value', }; - expect(() => { + expect(() => webRTCEndpoint.receiveMediaEvent( JSON.stringify(createEndpointUpdated(notExistingEndpointId, metadata)), - ); + ), + ) // todo change this error in production code - }).toThrow("Cannot set properties of undefined (setting 'metadata')"); + .rejects.toThrow("Cannot set properties of undefined (setting 'metadata')"); }); it('Parse metadata on endpoint update', () => { // Given type EndpointMetadata = { goodStuff: string }; + function endpointMetadataParser(data: any): EndpointMetadata { return { goodStuff: data.goodStuff }; } + mockRTCPeerConnection(); const webRTCEndpoint = new WebRTCEndpoint({ endpointMetadataParser }); @@ -131,10 +134,12 @@ it('Parse metadata on endpoint update', () => { it('Correctly handle incorrect metadata on endpoint update', () => { // Given type EndpointMetadata = { validMetadata: true }; + function endpointMetadataParser(data: any): EndpointMetadata { if (!data?.validMetadata) throw 'Invalid'; return { validMetadata: true }; } + mockRTCPeerConnection(); const webRTCEndpoint = new WebRTCEndpoint({ endpointMetadataParser }); diff --git a/tests/events/trackUpdatedEvent.test.ts b/tests/events/trackUpdatedEvent.test.ts index 2de8f493..23870aab 100644 --- a/tests/events/trackUpdatedEvent.test.ts +++ b/tests/events/trackUpdatedEvent.test.ts @@ -52,9 +52,11 @@ it(`Updating existing track changes track metadata`, () => { it('Correctly parses track metadata', () => { // Given type TrackMetadata = { goodStuff: string }; + function trackMetadataParser(data: any): TrackMetadata { return { goodStuff: data.goodStuff }; } + const webRTCEndpoint = new WebRTCEndpoint({ trackMetadataParser }); setupRoom(webRTCEndpoint, endpointId, trackId); @@ -78,10 +80,12 @@ it('Correctly parses track metadata', () => { it('Correctly handles incorrect metadata', () => { // Given type TrackMetadata = { validMetadata: true }; + function trackMetadataParser(data: any): TrackMetadata { if (!data.validMetadata) throw 'Invalid'; return { validMetadata: true }; } + const webRTCEndpoint = new WebRTCEndpoint({ trackMetadataParser }); setupRoom(webRTCEndpoint, endpointId, trackId); @@ -134,15 +138,16 @@ it(`Updating track with invalid endpoint id throws error`, () => { name: 'New name', }; - expect(() => { - // When - const trackUpdated = createTrackUpdatedEvent( - trackId, - notExistingEndpointId, - metadata, - ); - webRTCEndpoint.receiveMediaEvent(JSON.stringify(trackUpdated)); + // When + const trackUpdated = createTrackUpdatedEvent( + trackId, + notExistingEndpointId, + metadata, + ); + expect(() => webRTCEndpoint.receiveMediaEvent(JSON.stringify(trackUpdated))) // Then - }).toThrow(`Endpoint with id: ${notExistingEndpointId} doesn't exist`); + .rejects.toThrow( + `Endpoint with id: ${notExistingEndpointId} doesn't exist`, + ); }); diff --git a/tests/methods/addTrackMethod.test.ts b/tests/methods/addTrackMethod.test.ts index cb7e28a7..6e21e37d 100644 --- a/tests/methods/addTrackMethod.test.ts +++ b/tests/methods/addTrackMethod.test.ts @@ -1,6 +1,6 @@ import { WebRTCEndpoint } from '../../src'; import { createConnectedEventWithOneEndpoint, mockTrack } from '../fixtures'; -import { mockRTCPeerConnection } from '../mocks'; +import { mockMediaStream, mockRTCPeerConnection } from '../mocks'; import { deserializeMediaEvent } from '../../src/webrtc/mediaEvent'; import { expect, it } from 'vitest'; @@ -8,6 +8,7 @@ it('Adding track invokes renegotiation', () => new Promise((done) => { // Given const webRTCEndpoint = new WebRTCEndpoint(); + mockMediaStream(); webRTCEndpoint.receiveMediaEvent( JSON.stringify(createConnectedEventWithOneEndpoint()), @@ -33,6 +34,8 @@ it('Adding track invokes renegotiation', () => it('Adding track updates internal state', () => { // Given mockRTCPeerConnection(); + mockMediaStream(); + const webRTCEndpoint = new WebRTCEndpoint(); webRTCEndpoint.receiveMediaEvent( @@ -53,6 +56,8 @@ it('Adding track updates internal state', () => { it('Adding track before being accepted by the server throws error', async () => { // Given mockRTCPeerConnection(); + mockMediaStream(); + const webRTCEndpoint = new WebRTCEndpoint(); // When @@ -64,11 +69,15 @@ it('Adding track before being accepted by the server throws error', async () => it('Adding track with invalid metadata throws error', async () => { // Given type TrackMetadata = { validMetadata: true }; + function trackMetadataParser(data: any): TrackMetadata { if (!data?.trackMetadataParser) throw 'Invalid'; return { validMetadata: true }; } + mockRTCPeerConnection(); + mockMediaStream(); + const webRTCEndpoint = new WebRTCEndpoint({ trackMetadataParser }); // When diff --git a/tests/mocks.ts b/tests/mocks.ts index c7349dda..5a4158c0 100644 --- a/tests/mocks.ts +++ b/tests/mocks.ts @@ -1,6 +1,14 @@ import { undefined } from 'zod'; import { vi } from 'vitest'; +export const mockMediaStream = () => { + (global as any).MediaStream = vi.fn().mockImplementation(() => { + return { + addTrack: () => {}, + }; + }); +}; + export const mockRTCPeerConnection = (): { addTransceiverCallback: any; runOnTrack: (ev: RTCTrackEvent) => void; From 8c5a0971ee625e209f6b3910782055eeadda5f83 Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Wed, 5 Jun 2024 17:11:05 +0200 Subject: [PATCH 21/23] Revert async await changes --- src/webrtc/webRTCEndpoint.ts | 34 ++++++++++++---------- tests/events/encodingSwitchedEvent.test.ts | 2 +- tests/events/endpointUpdatedEvent.test.ts | 2 +- tests/events/trackUpdatedEvent.test.ts | 4 +-- 4 files changed, 21 insertions(+), 21 deletions(-) diff --git a/src/webrtc/webRTCEndpoint.ts b/src/webrtc/webRTCEndpoint.ts index 050687b0..c3ce60a9 100644 --- a/src/webrtc/webRTCEndpoint.ts +++ b/src/webrtc/webRTCEndpoint.ts @@ -541,7 +541,7 @@ export class WebRTCEndpoint< * webrtcChannel.on("mediaEvent", (event) => webrtc.receiveMediaEvent(event.data)); * ``` */ - public async receiveMediaEvent(mediaEvent: SerializedMediaEvent) { + public receiveMediaEvent = (mediaEvent: SerializedMediaEvent) => { const deserializedMediaEvent = deserializeMediaEvent(mediaEvent); switch (deserializedMediaEvent.type) { case 'connected': { @@ -594,9 +594,9 @@ export class WebRTCEndpoint< } default: if (this.localEndpoint.id != null) - await this.handleMediaEvent(deserializedMediaEvent); + this.handleMediaEvent(deserializedMediaEvent); } - } + }; /** * Retrieves statistics related to the RTCPeerConnection. @@ -646,7 +646,7 @@ export class WebRTCEndpoint< return this.bandwidthEstimation; } - private handleMediaEvent = async (deserializedMediaEvent: MediaEvent) => { + private handleMediaEvent = (deserializedMediaEvent: MediaEvent) => { let endpoint: Endpoint; let data; switch (deserializedMediaEvent.type) { @@ -729,7 +729,7 @@ export class WebRTCEndpoint< } } - await this.onAnswer(deserializedMediaEvent.data); + this.onAnswer(deserializedMediaEvent.data); this.ongoingRenegotiation = false; this.processNextCommand(); @@ -892,7 +892,7 @@ export class WebRTCEndpoint< break; } case 'custom': - await this.handleMediaEvent(deserializedMediaEvent.data as MediaEvent); + this.handleMediaEvent(deserializedMediaEvent.data as MediaEvent); break; case 'error': @@ -974,7 +974,7 @@ export class WebRTCEndpoint< * .forEach((track) => webrtc.addTrack(track, localStream)); * ``` */ - public async addTrack( + public addTrack( track: MediaStreamTrack, trackMetadata?: TrackMetadata, simulcastConfig: SimulcastConfig = { @@ -1008,16 +1008,18 @@ export class WebRTCEndpoint< } catch (error) { resolutionNotifier.reject(error); } - await resolutionNotifier.promise; - this.emit('localTrackAdded', { - trackId, - track, - stream, - trackMetadata: metadata, - simulcastConfig, - maxBandwidth, + + return resolutionNotifier.promise.then(() => { + this.emit('localTrackAdded', { + trackId, + track, + stream, + trackMetadata: metadata, + simulcastConfig, + maxBandwidth, + }); + return trackId; }); - return trackId; } private pushCommand(command: Command) { diff --git a/tests/events/encodingSwitchedEvent.test.ts b/tests/events/encodingSwitchedEvent.test.ts index 132fce4f..07a4e956 100644 --- a/tests/events/encodingSwitchedEvent.test.ts +++ b/tests/events/encodingSwitchedEvent.test.ts @@ -53,7 +53,7 @@ it('Changing track encoding when endpoint exist but track does not exist', () => webRTCEndpoint.receiveMediaEvent(JSON.stringify(encodingUpdatedEvent)), ) // todo change this error in production code - .rejects.toThrow("Cannot set properties of undefined (setting 'encoding')"); + .toThrow("Cannot set properties of undefined (setting 'encoding')"); }); it('Changing track encoding when endpoint does not exist but track exist in other endpoint', () => { diff --git a/tests/events/endpointUpdatedEvent.test.ts b/tests/events/endpointUpdatedEvent.test.ts index d8e07c17..2310f621 100644 --- a/tests/events/endpointUpdatedEvent.test.ts +++ b/tests/events/endpointUpdatedEvent.test.ts @@ -93,7 +93,7 @@ it('Update endpoint that not exist', () => { ), ) // todo change this error in production code - .rejects.toThrow("Cannot set properties of undefined (setting 'metadata')"); + .toThrow("Cannot set properties of undefined (setting 'metadata')"); }); it('Parse metadata on endpoint update', () => { diff --git a/tests/events/trackUpdatedEvent.test.ts b/tests/events/trackUpdatedEvent.test.ts index 23870aab..02d2f602 100644 --- a/tests/events/trackUpdatedEvent.test.ts +++ b/tests/events/trackUpdatedEvent.test.ts @@ -147,7 +147,5 @@ it(`Updating track with invalid endpoint id throws error`, () => { expect(() => webRTCEndpoint.receiveMediaEvent(JSON.stringify(trackUpdated))) // Then - .rejects.toThrow( - `Endpoint with id: ${notExistingEndpointId} doesn't exist`, - ); + .toThrow(`Endpoint with id: ${notExistingEndpointId} doesn't exist`); }); From 472d145f312e83d3a62d068302a9c88bff06e37c Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Mon, 10 Jun 2024 12:16:53 +0200 Subject: [PATCH 22/23] Apply PR suggestions --- e2e/app/src/App.tsx | 2 +- e2e/app/src/MuteTrackTest.tsx | 2 +- package.json | 3 ++- src/protos/index.ts | 1 + src/webrtc/webRTCEndpoint.ts | 32 +++++++++++++++++--------------- 5 files changed, 22 insertions(+), 18 deletions(-) create mode 100644 src/protos/index.ts diff --git a/e2e/app/src/App.tsx b/e2e/app/src/App.tsx index 4b44203d..bb770081 100644 --- a/e2e/app/src/App.tsx +++ b/e2e/app/src/App.tsx @@ -9,10 +9,10 @@ import { BandwidthLimit, SimulcastConfig, } from '@fishjam-dev/ts-client'; +import { PeerMessage } from "@fishjam-dev/ts-client/protos"; import { useEffect, useState, useSyncExternalStore } from 'react'; import { MockComponent } from './MockComponent'; import { VideoPlayerWithDetector } from './VideoPlayerWithDetector'; -import { PeerMessage } from '../../../src/protos/fishjam/peer_notifications'; /* eslint-disable no-console */ diff --git a/e2e/app/src/MuteTrackTest.tsx b/e2e/app/src/MuteTrackTest.tsx index a5334d3d..02f4dca6 100644 --- a/e2e/app/src/MuteTrackTest.tsx +++ b/e2e/app/src/MuteTrackTest.tsx @@ -38,7 +38,7 @@ export const MuteTrackTest = ({ webrtc }: Props) => { webrtc.removeListener('localTrackAdded', localTrackAdded); webrtc.removeListener('localTrackReplaced', localTrackReplaced); }; - }, []); + }, [webrtc]); const addTrack = async (stream: MediaStream) => { const track = stream.getVideoTracks()[0]; diff --git a/package.json b/package.json index 5c907252..eb2ab941 100644 --- a/package.json +++ b/package.json @@ -18,7 +18,8 @@ "dist/src" ], "exports": { - ".": "./dist/src/index.js" + ".": "./dist/src/index.js", + "./protos": "./dist/src/protos/index.js" }, "scripts": { "build": "tsc", diff --git a/src/protos/index.ts b/src/protos/index.ts new file mode 100644 index 00000000..feb504cb --- /dev/null +++ b/src/protos/index.ts @@ -0,0 +1 @@ +export * from './fishjam/peer_notifications'; diff --git a/src/webrtc/webRTCEndpoint.ts b/src/webrtc/webRTCEndpoint.ts index c3ce60a9..ef5ca4e7 100644 --- a/src/webrtc/webRTCEndpoint.ts +++ b/src/webrtc/webRTCEndpoint.ts @@ -1351,13 +1351,15 @@ export class WebRTCEndpoint< }); } - private replaceTrackHandler(command: ReplaceTackCommand) { + private async replaceTrackHandler( + command: ReplaceTackCommand, + ) { const { trackId, newTrack, newTrackMetadata } = command; const trackContext = this.localTrackIdToTrack.get(trackId)!; const track = this.trackIdToSender.get(trackId); - const sender: RTCRtpSender | null = track?.sender ?? null; + const sender = track?.sender ?? null; if (!track) throw Error(`There is no track with id: ${trackId}`); if (!sender) throw Error('There is no RTCRtpSender for this track id!'); @@ -1388,20 +1390,20 @@ export class WebRTCEndpoint< track.localTrackId = newTrack?.id ?? null; - sender - .replaceTrack(newTrack) - .then(() => { - trackContext.track = newTrack; + try { + await sender.replaceTrack(newTrack); + trackContext.track = newTrack; - if (newTrackMetadata) { - this.updateTrackMetadata(trackId, newTrackMetadata); - } - }) - .finally(() => { - this.resolvePreviousCommand(); - this.ongoingTrackReplacement = false; - this.processNextCommand(); - }); + if (newTrackMetadata) { + this.updateTrackMetadata(trackId, newTrackMetadata); + } + } catch (error) { + // ignore + } finally { + this.resolvePreviousCommand(); + this.ongoingTrackReplacement = false; + this.processNextCommand(); + } } /** From b5c8f01c85f830b09023e1b59faf8ec07d392871 Mon Sep 17 00:00:00 2001 From: Kamil Stasiak Date: Mon, 10 Jun 2024 12:20:29 +0200 Subject: [PATCH 23/23] Apply PR suggestions --- e2e/app/src/App.tsx | 2 +- e2e/app/src/VideoPlayerWithDetector.tsx | 2 +- src/FishjamClient.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/e2e/app/src/App.tsx b/e2e/app/src/App.tsx index bb770081..ec3f48d4 100644 --- a/e2e/app/src/App.tsx +++ b/e2e/app/src/App.tsx @@ -9,7 +9,7 @@ import { BandwidthLimit, SimulcastConfig, } from '@fishjam-dev/ts-client'; -import { PeerMessage } from "@fishjam-dev/ts-client/protos"; +import { PeerMessage } from '@fishjam-dev/ts-client/protos'; import { useEffect, useState, useSyncExternalStore } from 'react'; import { MockComponent } from './MockComponent'; import { VideoPlayerWithDetector } from './VideoPlayerWithDetector'; diff --git a/e2e/app/src/VideoPlayerWithDetector.tsx b/e2e/app/src/VideoPlayerWithDetector.tsx index bf914b84..0629a89b 100644 --- a/e2e/app/src/VideoPlayerWithDetector.tsx +++ b/e2e/app/src/VideoPlayerWithDetector.tsx @@ -65,7 +65,7 @@ export const VideoPlayerWithDetector = ({ stream, id, webrtc }: Props) => { }, [stream]); useEffect(() => { - const id = setInterval(async () => { + const id = setInterval(() => { const videoElement = videoElementRef.current; if (!videoElement || videoElement.videoWidth === 0) return; diff --git a/src/FishjamClient.ts b/src/FishjamClient.ts index abe8e69a..2b11426e 100644 --- a/src/FishjamClient.ts +++ b/src/FishjamClient.ts @@ -12,7 +12,7 @@ import { } from './webrtc'; import TypedEmitter from 'typed-emitter'; import { EventEmitter } from 'events'; -import { PeerMessage } from './protos/fishjam/peer_notifications'; +import { PeerMessage } from './protos'; import { ReconnectConfig, ReconnectManager } from './reconnection'; import { AuthErrorReason, isAuthError } from './auth';